(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4693],{7610:(e,t)=>{t.read=function(e,t,n,r,o){var i,l,a=8*o-r-1,s=(1<>1,c=-7,f=n?o-1:0,p=n?-1:1,h=e[t+f];for(f+=p,i=h&(1<<-c)-1,h>>=-c,c+=a;c>0;i=256*i+e[t+f],f+=p,c-=8);for(l=i&(1<<-c)-1,i>>=-c,c+=r;c>0;l=256*l+e[t+f],f+=p,c-=8);if(0===i)i=1-u;else{if(i===s)return l?NaN:1/0*(h?-1:1);l+=Math.pow(2,r),i-=u}return(h?-1:1)*l*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var l,a,s,u=8*i-o-1,c=(1<>1,p=5960464477539062e-23*(23===o),h=r?0:i-1,d=r?1:-1,g=+(t<0||0===t&&1/t<0);for(isNaN(t=Math.abs(t))||t===1/0?(a=+!!isNaN(t),l=c):(l=Math.floor(Math.log(t)/Math.LN2),t*(s=Math.pow(2,-l))<1&&(l--,s*=2),l+f>=1?t+=p/s:t+=p*Math.pow(2,1-f),t*s>=2&&(l++,s/=2),l+f>=c?(a=0,l=c):l+f>=1?(a=(t*s-1)*Math.pow(2,o),l+=f):(a=t*Math.pow(2,f-1)*Math.pow(2,o),l=0));o>=8;e[n+h]=255&a,h+=d,a/=256,o-=8);for(l=l<0;e[n+h]=255&l,h+=d,l/=256,u-=8);e[n+h-d]|=128*g}},10255:(e,t,n)=>{"use strict";function r(e){let{moduleIds:t}=e;return null}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"PreloadChunks",{enumerable:!0,get:function(){return r}}),n(95155),n(47650),n(85744),n(20589)},17828:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"workAsyncStorageInstance",{enumerable:!0,get:function(){return r}});let r=(0,n(64054).createAsyncLocalStorage)()},21649:e=>{e.exports=function(e,t){let n;if("function"!=typeof e)throw TypeError(`Expected the first argument to be a \`function\`, got \`${typeof e}\`.`);let r=0;return function(...o){clearTimeout(n);let i=Date.now(),l=t-(i-r);l<=0?(r=i,e.apply(this,o)):n=setTimeout(()=>{r=Date.now(),e.apply(this,o)},l)}}},31300:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.camelCase=void 0;var n=/^--[a-zA-Z0-9_-]+$/,r=/-([a-z])/g,o=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,l=/^-(ms)-/,a=function(e,t){return t.toUpperCase()},s=function(e,t){return"".concat(t,"-")};t.camelCase=function(e,t){var u;return(void 0===t&&(t={}),!(u=e)||o.test(u)||n.test(u))?e:(e=e.toLowerCase(),(e=t.reactCompat?e.replace(l,s):e.replace(i,s)).replace(r,a))}},36301:e=>{var t=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,n=/\n/g,r=/^\s*/,o=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,i=/^:\s*/,l=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,a=/^[;\s]*/,s=/^\s+|\s+$/g;function u(e){return e?e.replace(s,""):""}e.exports=function(e,s){if("string"!=typeof e)throw TypeError("First argument must be a string");if(!e)return[];s=s||{};var c=1,f=1;function p(e){var t=e.match(n);t&&(c+=t.length);var r=e.lastIndexOf("\n");f=~r?e.length-r:f+e.length}function h(){var e={line:c,column:f};return function(t){return t.position=new d(e),y(r),t}}function d(e){this.start=e,this.end={line:c,column:f},this.source=s.source}d.prototype.content=e;var g=[];function m(t){var n=Error(s.source+":"+c+":"+f+": "+t);if(n.reason=t,n.filename=s.source,n.line=c,n.column=f,n.source=e,s.silent)g.push(n);else throw n}function y(t){var n=t.exec(e);if(n){var r=n[0];return p(r),e=e.slice(r.length),n}}function v(e){var t;for(e=e||[];t=b();)!1!==t&&e.push(t);return e}function b(){var t=h();if("/"==e.charAt(0)&&"*"==e.charAt(1)){for(var n=2;""!=e.charAt(n)&&("*"!=e.charAt(n)||"/"!=e.charAt(n+1));)++n;if(n+=2,""===e.charAt(n-1))return m("End of comment missing");var r=e.slice(2,n-2);return f+=2,p(r),e=e.slice(n),f+=2,t({type:"comment",comment:r})}}y(r);var x,k=[];for(v(k);x=function(){var e=h(),n=y(o);if(n){if(b(),!y(i))return m("property missing ':'");var r=y(l),s=e({type:"declaration",property:u(n[0].replace(t,"")),value:r?u(r[0].replace(t,"")):""});return y(a),s}}();)!1!==x&&(k.push(x),v(k));return k}},36645:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return o}});let r=n(88229)._(n(67357));function o(e,t){var n;let o={};"function"==typeof e&&(o.loader=e);let i={...o,...t};return(0,r.default)({...i,modules:null==(n=i.loadableGenerated)?void 0:n.modules})}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},44134:(e,t,n)=>{"use strict";var r=n(57719),o=n(7610),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function l(e){if(e>0x7fffffff)throw RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,a.prototype),t}function a(e,t,n){if("number"==typeof e){if("string"==typeof t)throw TypeError('The "string" argument must be of type string. Received type number');return c(e)}return s(e,t,n)}function s(e,t,n){if("string"==typeof e){var r=e,o=t;if(("string"!=typeof o||""===o)&&(o="utf8"),!a.isEncoding(o))throw TypeError("Unknown encoding: "+o);var i=0|d(r,o),s=l(i),u=s.write(r,o);return u!==i&&(s=s.slice(0,u)),s}if(ArrayBuffer.isView(e)){var c=e;if(C(c,Uint8Array)){var g=new Uint8Array(c);return p(g.buffer,g.byteOffset,g.byteLength)}return f(c)}if(null==e)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(C(e,ArrayBuffer)||e&&C(e.buffer,ArrayBuffer)||"undefined"!=typeof SharedArrayBuffer&&(C(e,SharedArrayBuffer)||e&&C(e.buffer,SharedArrayBuffer)))return p(e,t,n);if("number"==typeof e)throw TypeError('The "value" argument must not be of type number. Received type number');var m=e.valueOf&&e.valueOf();if(null!=m&&m!==e)return a.from(m,t,n);var y=function(e){if(a.isBuffer(e)){var t=0|h(e.length),n=l(t);return 0===n.length||e.copy(n,0,0,t),n}return void 0!==e.length?"number"!=typeof e.length||function(e){return e!=e}(e.length)?l(0):f(e):"Buffer"===e.type&&Array.isArray(e.data)?f(e.data):void 0}(e);if(y)return y;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return a.from(e[Symbol.toPrimitive]("string"),t,n);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function u(e){if("number"!=typeof e)throw TypeError('"size" argument must be of type number');if(e<0)throw RangeError('The value "'+e+'" is invalid for option "size"')}function c(e){return u(e),l(e<0?0:0|h(e))}function f(e){for(var t=e.length<0?0:0|h(e.length),n=l(t),r=0;r=0x7fffffff)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|e}function d(e,t){if(a.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||C(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var n=e.length,r=arguments.length>2&&!0===arguments[2];if(!r&&0===n)return 0;for(var o=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return A(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return T(e).length;default:if(o)return r?-1:A(e).length;t=(""+t).toLowerCase(),o=!0}}function g(e,t,n){var o,i,l,a=!1;if((void 0===t||t<0)&&(t=0),t>this.length||((void 0===n||n>this.length)&&(n=this.length),n<=0||(n>>>=0)<=(t>>>=0)))return"";for(e||(e="utf8");;)switch(e){case"hex":return function(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i0x7fffffff?n=0x7fffffff:n<-0x80000000&&(n=-0x80000000),(i=n*=1)!=i&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length)if(o)return -1;else n=e.length-1;else if(n<0)if(!o)return -1;else n=0;if("string"==typeof t&&(t=a.from(t,r)),a.isBuffer(t))return 0===t.length?-1:v(e,t,n,r,o);if("number"==typeof t){if(t&=255,"function"==typeof Uint8Array.prototype.indexOf)if(o)return Uint8Array.prototype.indexOf.call(e,t,n);else return Uint8Array.prototype.lastIndexOf.call(e,t,n);return v(e,[t],n,r,o)}throw TypeError("val must be string, number or Buffer")}function v(e,t,n,r,o){var i,l=1,a=e.length,s=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return -1;l=2,a/=2,s/=2,n/=2}function u(e,t){return 1===l?e[t]:e.readUInt16BE(t*l)}if(o){var c=-1;for(i=n;ia&&(n=a-s),i=n;i>=0;i--){for(var f=!0,p=0;p239?4:u>223?3:u>191?2:1;if(o+f<=n)switch(f){case 1:u<128&&(c=u);break;case 2:(192&(i=e[o+1]))==128&&(s=(31&u)<<6|63&i)>127&&(c=s);break;case 3:i=e[o+1],l=e[o+2],(192&i)==128&&(192&l)==128&&(s=(15&u)<<12|(63&i)<<6|63&l)>2047&&(s<55296||s>57343)&&(c=s);break;case 4:i=e[o+1],l=e[o+2],a=e[o+3],(192&i)==128&&(192&l)==128&&(192&a)==128&&(s=(15&u)<<18|(63&i)<<12|(63&l)<<6|63&a)>65535&&s<1114112&&(c=s)}null===c?(c=65533,f=1):c>65535&&(c-=65536,r.push(c>>>10&1023|55296),c=56320|1023&c),r.push(c),o+=f}var p=r,h=p.length;if(h<=4096)return String.fromCharCode.apply(String,p);for(var d="",g=0;gn)throw RangeError("Trying to access beyond buffer length")}function k(e,t,n,r,o,i){if(!a.isBuffer(e))throw TypeError('"buffer" argument must be a Buffer instance');if(t>o||te.length)throw RangeError("Index out of range")}function w(e,t,n,r,o,i){if(n+r>e.length||n<0)throw RangeError("Index out of range")}function E(e,t,n,r,i){return t*=1,n>>>=0,i||w(e,t,n,4,34028234663852886e22,-34028234663852886e22),o.write(e,t,n,r,23,4),n+4}function S(e,t,n,r,i){return t*=1,n>>>=0,i||w(e,t,n,8,17976931348623157e292,-17976931348623157e292),o.write(e,t,n,r,52,8),n+8}t.hp=a,t.IS=50,a.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){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(e,t,n){return s(e,t,n)},Object.setPrototypeOf(a.prototype,Uint8Array.prototype),Object.setPrototypeOf(a,Uint8Array),a.alloc=function(e,t,n){return(u(e),e<=0)?l(e):void 0!==t?"string"==typeof n?l(e).fill(t,n):l(e).fill(t):l(e)},a.allocUnsafe=function(e){return c(e)},a.allocUnsafeSlow=function(e){return c(e)},a.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==a.prototype},a.compare=function(e,t){if(C(e,Uint8Array)&&(e=a.from(e,e.offset,e.byteLength)),C(t,Uint8Array)&&(t=a.from(t,t.offset,t.byteLength)),!a.isBuffer(e)||!a.isBuffer(t))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);or.length?a.from(i).copy(r,o):Uint8Array.prototype.set.call(r,i,o);else if(a.isBuffer(i))i.copy(r,o);else throw TypeError('"list" argument must be an Array of Buffers');o+=i.length}return r},a.byteLength=d,a.prototype._isBuffer=!0,a.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;tn&&(e+=" ... "),""},i&&(a.prototype[i]=a.prototype.inspect),a.prototype.compare=function(e,t,n,r,o){if(C(e,Uint8Array)&&(e=a.from(e,e.offset,e.byteLength)),!a.isBuffer(e))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return -1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,o>>>=0,this===e)return 0;for(var i=o-r,l=n-t,s=Math.min(i,l),u=this.slice(r,o),c=e.slice(t,n),f=0;f>>=0,isFinite(n)?(n>>>=0,void 0===r&&(r="utf8")):(r=n,n=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var o,i,l,a,s,u,c,f,p=this.length-t;if((void 0===n||n>p)&&(n=p),e.length>0&&(n<0||t<0)||t>this.length)throw RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var h=!1;;)switch(r){case"hex":return function(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;r>i/2&&(r=i/2);for(var l=0;l>8,o.push(n%256),o.push(r);return o}(e,this.length-c),this,c,f);default:if(h)throw TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),h=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},a.prototype.slice=function(e,t){var n=this.length;e=~~e,t=void 0===t?n:~~t,e<0?(e+=n)<0&&(e=0):e>n&&(e=n),t<0?(t+=n)<0&&(t=0):t>n&&(t=n),t>>=0,t>>>=0,n||x(e,t,this.length);for(var r=this[e],o=1,i=0;++i>>=0,t>>>=0,n||x(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},a.prototype.readUint8=a.prototype.readUInt8=function(e,t){return e>>>=0,t||x(e,1,this.length),this[e]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(e,t){return e>>>=0,t||x(e,2,this.length),this[e]|this[e+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(e,t){return e>>>=0,t||x(e,2,this.length),this[e]<<8|this[e+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(e,t){return e>>>=0,t||x(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+0x1000000*this[e+3]},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(e,t){return e>>>=0,t||x(e,4,this.length),0x1000000*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},a.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||x(e,t,this.length);for(var r=this[e],o=1,i=0;++i=(o*=128)&&(r-=Math.pow(2,8*t)),r},a.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||x(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},a.prototype.readInt8=function(e,t){return(e>>>=0,t||x(e,1,this.length),128&this[e])?-((255-this[e]+1)*1):this[e]},a.prototype.readInt16LE=function(e,t){e>>>=0,t||x(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?0xffff0000|n:n},a.prototype.readInt16BE=function(e,t){e>>>=0,t||x(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?0xffff0000|n:n},a.prototype.readInt32LE=function(e,t){return e>>>=0,t||x(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},a.prototype.readInt32BE=function(e,t){return e>>>=0,t||x(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},a.prototype.readFloatLE=function(e,t){return e>>>=0,t||x(e,4,this.length),o.read(this,e,!0,23,4)},a.prototype.readFloatBE=function(e,t){return e>>>=0,t||x(e,4,this.length),o.read(this,e,!1,23,4)},a.prototype.readDoubleLE=function(e,t){return e>>>=0,t||x(e,8,this.length),o.read(this,e,!0,52,8)},a.prototype.readDoubleBE=function(e,t){return e>>>=0,t||x(e,8,this.length),o.read(this,e,!1,52,8)},a.prototype.writeUintLE=a.prototype.writeUIntLE=function(e,t,n,r){if(e*=1,t>>>=0,n>>>=0,!r){var o=Math.pow(2,8*n)-1;k(this,e,t,n,o,0)}var i=1,l=0;for(this[t]=255&e;++l>>=0,n>>>=0,!r){var o=Math.pow(2,8*n)-1;k(this,e,t,n,o,0)}var i=n-1,l=1;for(this[t+i]=255&e;--i>=0&&(l*=256);)this[t+i]=e/l&255;return t+n},a.prototype.writeUint8=a.prototype.writeUInt8=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,1,255,0),this[t]=255&e,t+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,4,0xffffffff,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,4,0xffffffff,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},a.prototype.writeIntLE=function(e,t,n,r){if(e*=1,t>>>=0,!r){var o=Math.pow(2,8*n-1);k(this,e,t,n,o-1,-o)}var i=0,l=1,a=0;for(this[t]=255&e;++i>>=0,!r){var o=Math.pow(2,8*n-1);k(this,e,t,n,o-1,-o)}var i=n-1,l=1,a=0;for(this[t+i]=255&e;--i>=0&&(l*=256);)e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/l|0)-a&255;return t+n},a.prototype.writeInt8=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},a.prototype.writeInt16LE=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},a.prototype.writeInt16BE=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},a.prototype.writeInt32LE=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,4,0x7fffffff,-0x80000000),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},a.prototype.writeInt32BE=function(e,t,n){return e*=1,t>>>=0,n||k(this,e,t,4,0x7fffffff,-0x80000000),e<0&&(e=0xffffffff+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},a.prototype.writeFloatLE=function(e,t,n){return E(this,e,t,!0,n)},a.prototype.writeFloatBE=function(e,t,n){return E(this,e,t,!1,n)},a.prototype.writeDoubleLE=function(e,t,n){return S(this,e,t,!0,n)},a.prototype.writeDoubleBE=function(e,t,n){return S(this,e,t,!1,n)},a.prototype.copy=function(e,t,n,r){if(!a.isBuffer(e))throw TypeError("argument should be a Buffer");if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw RangeError("Index out of range");if(r<0)throw RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(o=t;o55295&&n<57344){if(!o){if(n>56319||l+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=(o-55296<<10|n-56320)+65536}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else if(n<1114112){if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}else throw Error("Invalid code point")}return i}function T(e){return r.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(I,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function _(e,t,n,r){for(var o=0;o=t.length)&&!(o>=e.length);++o)t[o+n]=e[o];return o}function C(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}var O=function(){for(var e="0123456789abcdef",t=Array(256),n=0;n<16;++n)for(var r=16*n,o=0;o<16;++o)t[r+o]=e[n]+e[o];return t}()},53360:e=>{"use strict";var t=Object.prototype.hasOwnProperty,n=Object.prototype.toString,r=Object.defineProperty,o=Object.getOwnPropertyDescriptor,i=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===n.call(e)},l=function(e){if(!e||"[object Object]"!==n.call(e))return!1;var r,o=t.call(e,"constructor"),i=e.constructor&&e.constructor.prototype&&t.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!o&&!i)return!1;for(r in e);return void 0===r||t.call(e,r)},a=function(e,t){r&&"__proto__"===t.name?r(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},s=function(e,n){if("__proto__"===n){if(!t.call(e,n))return;else if(o)return o(e,n).value}return e[n]};e.exports=function e(){var t,n,r,o,u,c,f=arguments[0],p=1,h=arguments.length,d=!1;for("boolean"==typeof f&&(d=f,f=arguments[1]||{},p=2),(null==f||"object"!=typeof f&&"function"!=typeof f)&&(f={});p{"use strict";n.d(t,{default:()=>o.a});var r=n(36645),o=n.n(r)},55605:(e,t,n)=>{"use strict";let r;n.d(t,{Y_:()=>eY});var o,i,l,a,s=n(12115),u="vercel.ai.error",c=Symbol.for(u),f=class e extends Error{constructor({name:e,message:t,cause:n}){super(t),this[o]=!0,this.name=e,this.cause=n}static isInstance(t){return e.hasMarker(t,u)}static hasMarker(e,t){let n=Symbol.for(t);return null!=e&&"object"==typeof e&&n in e&&"boolean"==typeof e[n]&&!0===e[n]}};o=c;var p=f;function h(e){return null==e?"unknown error":"string"==typeof e?e:e instanceof Error?e.message:JSON.stringify(e)}Symbol.for("vercel.ai.error.AI_APICallError"),Symbol.for("vercel.ai.error.AI_EmptyResponseBodyError");var d="AI_InvalidArgumentError",g=`vercel.ai.error.${d}`,m=Symbol.for(g),y=class extends p{constructor({message:e,cause:t,argument:n}){super({name:d,message:e,cause:t}),this[i]=!0,this.argument=n}static isInstance(e){return p.hasMarker(e,g)}};i=m,Symbol.for("vercel.ai.error.AI_InvalidPromptError"),Symbol.for("vercel.ai.error.AI_InvalidResponseDataError");var v="AI_JSONParseError",b=`vercel.ai.error.${v}`,x=Symbol.for(b),k=class extends p{constructor({text:e,cause:t}){super({name:v,message:`JSON parsing failed: Text: ${e}.
Error message: ${h(t)}`,cause:t}),this[l]=!0,this.text=e}static isInstance(e){return p.hasMarker(e,b)}};l=x,Symbol.for("vercel.ai.error.AI_LoadAPIKeyError"),Symbol.for("vercel.ai.error.AI_LoadSettingError"),Symbol.for("vercel.ai.error.AI_NoContentGeneratedError"),Symbol.for("vercel.ai.error.AI_NoSuchModelError"),Symbol.for("vercel.ai.error.AI_TooManyEmbeddingValuesForCallError");var w="AI_TypeValidationError",E=`vercel.ai.error.${w}`,S=Symbol.for(E),I=class e extends p{constructor({value:e,cause:t}){super({name:w,message:`Type validation failed: Value: ${JSON.stringify(e)}.
Error message: ${h(t)}`,cause:t}),this[a]=!0,this.value=e}static isInstance(e){return p.hasMarker(e,E)}static wrap({value:t,cause:n}){return e.isInstance(n)&&n.value===t?n:new e({value:t,cause:n})}};a=S,Symbol.for("vercel.ai.error.AI_UnsupportedFunctionalityError");var A=n(83082);n(49509);var T=(({prefix:e,size:t=16,alphabet:n="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",separator:r="-"}={})=>{let o=((e,t=21)=>(n=t)=>{let r="",o=0|n;for(;o--;)r+=e[Math.random()*e.length|0];return r})(n,t);if(null==e)return o;if(n.includes(r))throw new y({argument:"separator",message:`The separator "${r}" must not be part of the alphabet "${n}".`});return t=>`${e}${r}${o(t)}`})(),_=Symbol.for("vercel.ai.validator");function C({text:e,schema:t}){try{let n=A.parse(e);if(null==t)return{success:!0,value:n,rawValue:n};let r=function({value:e,schema:t}){var n;let r="object"==typeof t&&null!==t&&_ in t&&!0===t[_]&&"validate"in t?t:(n=t,{[_]:!0,validate:e=>{let t=n.safeParse(e);return t.success?{success:!0,value:t.data}:{success:!1,error:t.error}}});try{if(null==r.validate)return{success:!0,value:e};let t=r.validate(e);if(t.success)return t;return{success:!1,error:I.wrap({value:e,cause:t.error})}}catch(t){return{success:!1,error:I.wrap({value:e,cause:t})}}}({value:n,schema:t});return r.success?{...r,rawValue:n}:r}catch(t){return{success:!1,error:k.isInstance(t)?t:new k({text:e,cause:t})}}}var{btoa:O,atob:R}=globalThis;Symbol("Let zodToJsonSchema decide on which parser to use");var P={code:"0",name:"text",parse:e=>{if("string"!=typeof e)throw Error('"text" parts expect a string value.');return{type:"text",value:e}}},L={code:"3",name:"error",parse:e=>{if("string"!=typeof e)throw Error('"error" parts expect a string value.');return{type:"error",value:e}}},D={code:"4",name:"assistant_message",parse:e=>{if(null==e||"object"!=typeof e||!("id"in e)||!("role"in e)||!("content"in e)||"string"!=typeof e.id||"string"!=typeof e.role||"assistant"!==e.role||!Array.isArray(e.content)||!e.content.every(e=>null!=e&&"object"==typeof e&&"type"in e&&"text"===e.type&&"text"in e&&null!=e.text&&"object"==typeof e.text&&"value"in e.text&&"string"==typeof e.text.value))throw Error('"assistant_message" parts expect an object with an "id", "role", and "content" property.');return{type:"assistant_message",value:e}}},M={code:"5",name:"assistant_control_data",parse:e=>{if(null==e||"object"!=typeof e||!("threadId"in e)||!("messageId"in e)||"string"!=typeof e.threadId||"string"!=typeof e.messageId)throw Error('"assistant_control_data" parts expect an object with a "threadId" and "messageId" property.');return{type:"assistant_control_data",value:{threadId:e.threadId,messageId:e.messageId}}}},N={code:"6",name:"data_message",parse:e=>{if(null==e||"object"!=typeof e||!("role"in e)||!("data"in e)||"string"!=typeof e.role||"data"!==e.role)throw Error('"data_message" parts expect an object with a "role" and "data" property.');return{type:"data_message",value:e}}},j=[P,L,D,M,N];P.code,L.code,D.code,M.code,N.code,P.name,P.code,L.name,L.code,D.name,D.code,M.name,M.code,N.name,N.code,j.map(e=>e.code);var F=[{code:"0",name:"text",parse:e=>{if("string"!=typeof e)throw Error('"text" parts expect a string value.');return{type:"text",value:e}}},{code:"2",name:"data",parse:e=>{if(!Array.isArray(e))throw Error('"data" parts expect an array value.');return{type:"data",value:e}}},{code:"3",name:"error",parse:e=>{if("string"!=typeof e)throw Error('"error" parts expect a string value.');return{type:"error",value:e}}},{code:"8",name:"message_annotations",parse:e=>{if(!Array.isArray(e))throw Error('"message_annotations" parts expect an array value.');return{type:"message_annotations",value:e}}},{code:"9",name:"tool_call",parse:e=>{if(null==e||"object"!=typeof e||!("toolCallId"in e)||"string"!=typeof e.toolCallId||!("toolName"in e)||"string"!=typeof e.toolName||!("args"in e)||"object"!=typeof e.args)throw Error('"tool_call" parts expect an object with a "toolCallId", "toolName", and "args" property.');return{type:"tool_call",value:e}}},{code:"a",name:"tool_result",parse:e=>{if(null==e||"object"!=typeof e||!("toolCallId"in e)||"string"!=typeof e.toolCallId||!("result"in e))throw Error('"tool_result" parts expect an object with a "toolCallId" and a "result" property.');return{type:"tool_result",value:e}}},{code:"b",name:"tool_call_streaming_start",parse:e=>{if(null==e||"object"!=typeof e||!("toolCallId"in e)||"string"!=typeof e.toolCallId||!("toolName"in e)||"string"!=typeof e.toolName)throw Error('"tool_call_streaming_start" parts expect an object with a "toolCallId" and "toolName" property.');return{type:"tool_call_streaming_start",value:e}}},{code:"c",name:"tool_call_delta",parse:e=>{if(null==e||"object"!=typeof e||!("toolCallId"in e)||"string"!=typeof e.toolCallId||!("argsTextDelta"in e)||"string"!=typeof e.argsTextDelta)throw Error('"tool_call_delta" parts expect an object with a "toolCallId" and "argsTextDelta" property.');return{type:"tool_call_delta",value:e}}},{code:"d",name:"finish_message",parse:e=>{if(null==e||"object"!=typeof e||!("finishReason"in e)||"string"!=typeof e.finishReason)throw Error('"finish_message" parts expect an object with a "finishReason" property.');let t={finishReason:e.finishReason};return"usage"in e&&null!=e.usage&&"object"==typeof e.usage&&"promptTokens"in e.usage&&"completionTokens"in e.usage&&(t.usage={promptTokens:"number"==typeof e.usage.promptTokens?e.usage.promptTokens:NaN,completionTokens:"number"==typeof e.usage.completionTokens?e.usage.completionTokens:NaN}),{type:"finish_message",value:t}}},{code:"e",name:"finish_step",parse:e=>{if(null==e||"object"!=typeof e||!("finishReason"in e)||"string"!=typeof e.finishReason)throw Error('"finish_step" parts expect an object with a "finishReason" property.');let t={finishReason:e.finishReason,isContinued:!1};return"usage"in e&&null!=e.usage&&"object"==typeof e.usage&&"promptTokens"in e.usage&&"completionTokens"in e.usage&&(t.usage={promptTokens:"number"==typeof e.usage.promptTokens?e.usage.promptTokens:NaN,completionTokens:"number"==typeof e.usage.completionTokens?e.usage.completionTokens:NaN}),"isContinued"in e&&"boolean"==typeof e.isContinued&&(t.isContinued=e.isContinued),{type:"finish_step",value:t}}},{code:"f",name:"start_step",parse:e=>{if(null==e||"object"!=typeof e||!("messageId"in e)||"string"!=typeof e.messageId)throw Error('"start_step" parts expect an object with an "id" property.');return{type:"start_step",value:{messageId:e.messageId}}}},{code:"g",name:"reasoning",parse:e=>{if("string"!=typeof e)throw Error('"reasoning" parts expect a string value.');return{type:"reasoning",value:e}}},{code:"h",name:"source",parse:e=>{if(null==e||"object"!=typeof e)throw Error('"source" parts expect a Source object.');return{type:"source",value:e}}},{code:"i",name:"redacted_reasoning",parse:e=>{if(null==e||"object"!=typeof e||!("data"in e)||"string"!=typeof e.data)throw Error('"redacted_reasoning" parts expect an object with a "data" property.');return{type:"redacted_reasoning",value:{data:e.data}}}},{code:"j",name:"reasoning_signature",parse:e=>{if(null==e||"object"!=typeof e||!("signature"in e)||"string"!=typeof e.signature)throw Error('"reasoning_signature" parts expect an object with a "signature" property.');return{type:"reasoning_signature",value:{signature:e.signature}}}},{code:"k",name:"file",parse:e=>{if(null==e||"object"!=typeof e||!("data"in e)||"string"!=typeof e.data||!("mimeType"in e)||"string"!=typeof e.mimeType)throw Error('"file" parts expect an object with a "data" and "mimeType" property.');return{type:"file",value:e}}}],B=Object.fromEntries(F.map(e=>[e.code,e]));Object.fromEntries(F.map(e=>[e.name,e.code]));var z=F.map(e=>e.code),U=e=>{let t=e.indexOf(":");if(-1===t)throw Error("Failed to parse stream string. No separator found.");let n=e.slice(0,t);if(!z.includes(n))throw Error(`Failed to parse stream string. Invalid code ${n}.`);let r=JSON.parse(e.slice(t+1));return B[n].parse(r)};async function V({stream:e,onTextPart:t,onReasoningPart:n,onReasoningSignaturePart:r,onRedactedReasoningPart:o,onSourcePart:i,onFilePart:l,onDataPart:a,onErrorPart:s,onToolCallStreamingStartPart:u,onToolCallDeltaPart:c,onToolCallPart:f,onToolResultPart:p,onMessageAnnotationsPart:h,onFinishMessagePart:d,onFinishStepPart:g,onStartStepPart:m}){let y=e.getReader(),v=new TextDecoder,b=[],x=0;for(;;){let{value:e}=await y.read();if(e&&(b.push(e),x+=e.length,10!==e[e.length-1]))continue;if(0===b.length)break;let k=function(e,t){let n=new Uint8Array(t),r=0;for(let t of e)n.set(t,r),r+=t.length;return e.length=0,n}(b,x);for(let{type:e,value:y}of(x=0,v.decode(k,{stream:!0}).split("\n").filter(e=>""!==e).map(U)))switch(e){case"text":await (null==t?void 0:t(y));break;case"reasoning":await (null==n?void 0:n(y));break;case"reasoning_signature":await (null==r?void 0:r(y));break;case"redacted_reasoning":await (null==o?void 0:o(y));break;case"file":await (null==l?void 0:l(y));break;case"source":await (null==i?void 0:i(y));break;case"data":await (null==a?void 0:a(y));break;case"error":await (null==s?void 0:s(y));break;case"message_annotations":await (null==h?void 0:h(y));break;case"tool_call_streaming_start":await (null==u?void 0:u(y));break;case"tool_call_delta":await (null==c?void 0:c(y));break;case"tool_call":await (null==f?void 0:f(y));break;case"tool_result":await (null==p?void 0:p(y));break;case"finish_message":await (null==d?void 0:d(y));break;case"finish_step":await (null==g?void 0:g(y));break;case"start_step":await (null==m?void 0:m(y));break;default:throw Error(`Unknown stream part type: ${e}`)}}}async function H({stream:e,update:t,onToolCall:n,onFinish:r,generateId:o=T,getCurrentDate:i=()=>new Date,lastMessage:l}){var a,s;let u,c,f,p=(null==l?void 0:l.role)==="assistant",h=p?1+(null!=(s=null==(a=l.toolInvocations)?void 0:a.reduce((e,t)=>{var n;return Math.max(e,null!=(n=t.step)?n:0)},0))?s:0):0,d=p?structuredClone(l):{id:o(),createdAt:i(),role:"assistant",content:"",parts:[]};function g(e,t){let n=d.parts.find(t=>"tool-invocation"===t.type&&t.toolInvocation.toolCallId===e);null!=n?n.toolInvocation=t:d.parts.push({type:"tool-invocation",toolInvocation:t})}let m=[],y=p?null==l?void 0:l.annotations:void 0,v={},b={completionTokens:NaN,promptTokens:NaN,totalTokens:NaN},x="unknown";function k(){let e=[...m];(null==y?void 0:y.length)&&(d.annotations=y),t({message:{...structuredClone(d),revisionId:o()},data:e,replaceLastMessage:p})}await V({stream:e,onTextPart(e){null==u?(u={type:"text",text:e},d.parts.push(u)):u.text+=e,d.content+=e,k()},onReasoningPart(e){var t;null==f?(f={type:"text",text:e},null!=c&&c.details.push(f)):f.text+=e,null==c?(c={type:"reasoning",reasoning:e,details:[f]},d.parts.push(c)):c.reasoning+=e,d.reasoning=(null!=(t=d.reasoning)?t:"")+e,k()},onReasoningSignaturePart(e){null!=f&&(f.signature=e.signature)},onRedactedReasoningPart(e){null==c&&(c={type:"reasoning",reasoning:"",details:[]},d.parts.push(c)),c.details.push({type:"redacted",data:e.data}),f=void 0,k()},onFilePart(e){d.parts.push({type:"file",mimeType:e.mimeType,data:e.data}),k()},onSourcePart(e){d.parts.push({type:"source",source:e}),k()},onToolCallStreamingStartPart(e){null==d.toolInvocations&&(d.toolInvocations=[]),v[e.toolCallId]={text:"",step:h,toolName:e.toolName,index:d.toolInvocations.length};let t={state:"partial-call",step:h,toolCallId:e.toolCallId,toolName:e.toolName,args:void 0};d.toolInvocations.push(t),g(e.toolCallId,t),k()},onToolCallDeltaPart(e){let t=v[e.toolCallId];t.text+=e.argsTextDelta;let{value:n}=function(e){if(void 0===e)return{value:void 0,state:"undefined-input"};let t=C({text:e});return t.success?{value:t.value,state:"successful-parse"}:(t=C({text:function(e){let t=["ROOT"],n=-1,r=null;function o(e,o,i){switch(e){case'"':n=o,t.pop(),t.push(i),t.push("INSIDE_STRING");break;case"f":case"t":case"n":n=o,r=o,t.pop(),t.push(i),t.push("INSIDE_LITERAL");break;case"-":t.pop(),t.push(i),t.push("INSIDE_NUMBER");break;case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":n=o,t.pop(),t.push(i),t.push("INSIDE_NUMBER");break;case"{":n=o,t.pop(),t.push(i),t.push("INSIDE_OBJECT_START");break;case"[":n=o,t.pop(),t.push(i),t.push("INSIDE_ARRAY_START")}}function i(e,r){switch(e){case",":t.pop(),t.push("INSIDE_OBJECT_AFTER_COMMA");break;case"}":n=r,t.pop()}}function l(e,r){switch(e){case",":t.pop(),t.push("INSIDE_ARRAY_AFTER_COMMA");break;case"]":n=r,t.pop()}}for(let a=0;a=0;n--)switch(t[n]){case"INSIDE_STRING":a+='"';break;case"INSIDE_OBJECT_KEY":case"INSIDE_OBJECT_AFTER_KEY":case"INSIDE_OBJECT_AFTER_COMMA":case"INSIDE_OBJECT_START":case"INSIDE_OBJECT_BEFORE_VALUE":case"INSIDE_OBJECT_AFTER_VALUE":a+="}";break;case"INSIDE_ARRAY_START":case"INSIDE_ARRAY_AFTER_COMMA":case"INSIDE_ARRAY_AFTER_VALUE":a+="]";break;case"INSIDE_LITERAL":{let t=e.substring(r,e.length);"true".startsWith(t)?a+="true".slice(t.length):"false".startsWith(t)?a+="false".slice(t.length):"null".startsWith(t)&&(a+="null".slice(t.length))}}return a}(e)})).success?{value:t.value,state:"repaired-parse"}:{value:void 0,state:"failed-parse"}}(t.text),r={state:"partial-call",step:t.step,toolCallId:e.toolCallId,toolName:t.toolName,args:n};d.toolInvocations[t.index]=r,g(e.toolCallId,r),k()},async onToolCallPart(e){let t={state:"call",step:h,...e};if(null!=v[e.toolCallId]?d.toolInvocations[v[e.toolCallId].index]=t:(null==d.toolInvocations&&(d.toolInvocations=[]),d.toolInvocations.push(t)),g(e.toolCallId,t),k(),n){let t=await n({toolCall:e});if(null!=t){let n={state:"result",step:h,...e,result:t};d.toolInvocations[d.toolInvocations.length-1]=n,g(e.toolCallId,n),k()}}},onToolResultPart(e){let t=d.toolInvocations;if(null==t)throw Error("tool_result must be preceded by a tool_call");let n=t.findIndex(t=>t.toolCallId===e.toolCallId);if(-1===n)throw Error("tool_result must be preceded by a tool_call with the same toolCallId");let r={...t[n],state:"result",...e};t[n]=r,g(e.toolCallId,r),k()},onDataPart(e){m.push(...e),k()},onMessageAnnotationsPart(e){null==y?y=[...e]:y.push(...e),k()},onFinishStepPart(e){h+=1,u=e.isContinued?u:void 0,c=void 0,f=void 0},onStartStepPart(e){p||(d.id=e.messageId),d.parts.push({type:"step-start"}),k()},onFinishMessagePart(e){x=e.finishReason,null!=e.usage&&(b=function({promptTokens:e,completionTokens:t}){return{promptTokens:e,completionTokens:t,totalTokens:e+t}}(e.usage))},onErrorPart(e){throw Error(e)}}),null==r||r({message:d,finishReason:x,usage:b})}async function q({stream:e,onTextPart:t}){let n=e.pipeThrough(new TextDecoderStream).getReader();for(;;){let{done:e,value:r}=await n.read();if(e)break;await t(r)}}async function J({stream:e,update:t,onFinish:n,getCurrentDate:r=()=>new Date,generateId:o=T}){let i={type:"text",text:""},l={id:o(),createdAt:r(),role:"assistant",content:"",parts:[i]};await q({stream:e,onTextPart:e=>{l.content+=e,i.text+=e,t({message:{...l},data:[],replaceLastMessage:!1})}}),null==n||n(l,{usage:{completionTokens:NaN,promptTokens:NaN,totalTokens:NaN},finishReason:"unknown"})}async function W({api:e,body:t,streamProtocol:n="data",credentials:r,headers:o,abortController:i,restoreMessagesOnFailure:l,onResponse:a,onUpdate:s,onFinish:u,onToolCall:c,generateId:f,fetch:p=fetch,lastMessage:h,requestType:d="generate"}){var g,m,y;let v="resume"===d?p(`${e}?chatId=${t.id}`,{method:"GET",headers:{"Content-Type":"application/json",...o},signal:null==(g=null==i?void 0:i())?void 0:g.signal,credentials:r}):p(e,{method:"POST",body:JSON.stringify(t),headers:{"Content-Type":"application/json",...o},signal:null==(m=null==i?void 0:i())?void 0:m.signal,credentials:r}),b=await v.catch(e=>{throw l(),e});if(a)try{await a(b)}catch(e){throw e}if(!b.ok)throw l(),Error(null!=(y=await b.text())?y:"Failed to fetch the chat response.");if(!b.body)throw Error("The response body is empty.");switch(n){case"text":return void await J({stream:b.body,update:s,onFinish:u,generateId:f});case"data":return void await H({stream:b.body,update:s,lastMessage:h,onToolCall:c,onFinish({message:e,finishReason:t,usage:n}){u&&null!=e&&u(e,{usage:n,finishReason:t})},generateId:f});default:throw Error(`Unknown stream protocol: ${n}`)}}function Y(e){return null==e?void 0:e.reduce((e,t)=>{var n;return Math.max(e,null!=(n=t.step)?n:0)},0)}function $(e){var t;return null!=(t=e.parts)?t:[...e.toolInvocations?e.toolInvocations.map(e=>({type:"tool-invocation",toolInvocation:e})):[],...e.reasoning?[{type:"reasoning",reasoning:e.reasoning,details:[{type:"text",text:e.reasoning}]}]:[],...e.content?[{type:"text",text:e.content}]:[]]}function K(e){return e.map(e=>({...e,parts:$(e)}))}async function Q(e){if(!e)return[];if(globalThis.FileList&&e instanceof globalThis.FileList)return Promise.all(Array.from(e).map(async e=>{let{name:t,type:n}=e;return{name:t,contentType:n,url:await new Promise((t,n)=>{let r=new FileReader;r.onload=e=>{var n;t(null==(n=e.target)?void 0:n.result)},r.onerror=e=>n(e),r.readAsDataURL(e)})}}));if(Array.isArray(e))return e;throw Error("Invalid attachments type")}function X(e){if("assistant"!==e.role)return!1;let t=e.parts.reduce((e,t,n)=>"step-start"===t.type?n:e,-1),n=e.parts.slice(t+1).filter(e=>"tool-invocation"===e.type);return n.length>0&&n.every(e=>"result"in e.toolInvocation)}Symbol.for("vercel.ai.schema");var Z=n(49033),G=Object.prototype.hasOwnProperty;let ee=new WeakMap,et=()=>{},en=et(),er=Object,eo=e=>e===en,ei=(e,t)=>({...e,...t}),el={},ea={},es="undefined",eu=typeof window!=es,ec=typeof document!=es,ef=eu&&"Deno"in window,ep=(e,t)=>{let n=ee.get(e);return[()=>!eo(t)&&e.get(t)||el,r=>{if(!eo(t)){let o=e.get(t);t in ea||(ea[t]=o),n[5](t,ei(o,r),o||el)}},n[6],()=>!eo(t)&&t in ea?ea[t]:!eo(t)&&e.get(t)||el]},eh=!0,[ed,eg]=eu&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[et,et],em={initFocus:e=>(ec&&document.addEventListener("visibilitychange",e),ed("focus",e),()=>{ec&&document.removeEventListener("visibilitychange",e),eg("focus",e)}),initReconnect:e=>{let t=()=>{eh=!0,e()},n=()=>{eh=!1};return ed("online",t),ed("offline",n),()=>{eg("online",t),eg("offline",n)}}},ey=!s.useId,ev=!eu||ef,eb=ev?s.useEffect:s.useLayoutEffect,ex="undefined"!=typeof navigator&&navigator.connection,ek=!ev&&ex&&(["slow-2g","2g"].includes(ex.effectiveType)||ex.saveData),ew=new WeakMap,eE=(e,t)=>e==="[object ".concat(t,"]"),eS=0,eI=e=>{let t,n,r=typeof e,o=er.prototype.toString.call(e),i=eE(o,"Date"),l=eE(o,"RegExp"),a=eE(o,"Object");if(er(e)!==e||i||l)t=i?e.toJSON():"symbol"==r?e.toString():"string"==r?JSON.stringify(e):""+e;else{if(t=ew.get(e))return t;if(t=++eS+"~",ew.set(e,t),Array.isArray(e)){for(n=0,t="@";n{if("function"==typeof e)try{e=e()}catch(t){e=""}let t=e;return[e="string"==typeof e?e:(Array.isArray(e)?e.length:e)?eI(e):"",t]},eT=0,e_=()=>++eT;async function eC(){for(var e=arguments.length,t=Array(e),n=0;n{let t=h[o];return("function"==typeof a.revalidate?a.revalidate(l().data,e):!1!==a.revalidate)&&(delete g[o],delete m[o],t&&t[0])?t[0](2).then(()=>l().data):l().data};if(t.length<3)return y();let v=i,b=!1,x=e_();d[o]=[x,0];let k=!eo(c),w=l(),E=w.data,S=w._c,I=eo(S)?E:S;if(k&&p({data:c="function"==typeof c?c(I,E):c,_c:I}),"function"==typeof v)try{v=v(I)}catch(e){n=e,b=!0}if(v&&"function"==typeof v.then){let e;if(v=await v.catch(e=>{n=e,b=!0}),x!==d[o][0]){if(b)throw n;return v}b&&k&&(e=n,"function"==typeof u?u(e):!1!==u)&&(s=!0,p({data:I,_c:en}))}if(s&&!b&&("function"==typeof s?p({data:s(v,I),error:en,_c:en}):p({data:v,error:en,_c:en})),d[o][1]=e_(),Promise.resolve(y()).then(()=>{p({_c:en})}),b){if(f)throw n;return}return v}}let eO=(e,t)=>{for(let n in e)e[n][0]&&e[n][0](t)},eR=(e,t)=>{if(!ee.has(e)){let n=ei(em,t),r=Object.create(null),o=eC.bind(en,e),i=et,l=Object.create(null),a=(e,t)=>{let n=l[e]||[];return l[e]=n,n.push(t),()=>n.splice(n.indexOf(t),1)},s=(t,n,r)=>{e.set(t,n);let o=l[t];if(o)for(let e of o)e(n,r)},u=()=>{if(!ee.has(e)&&(ee.set(e,[r,Object.create(null),Object.create(null),Object.create(null),o,s,a]),!ev)){let t=n.initFocus(setTimeout.bind(en,eO.bind(en,r,0))),o=n.initReconnect(setTimeout.bind(en,eO.bind(en,r,1)));i=()=>{t&&t(),o&&o(),ee.delete(e)}}};return u(),[e,o,u,i]}return[e,ee.get(e)[4]]},[eP,eL]=eR(new Map),eD=ei({onLoadingSlow:et,onSuccess:et,onError:et,onErrorRetry:(e,t,n,r,o)=>{let i=n.errorRetryCount,l=o.retryCount,a=~~((Math.random()+.5)*(1<<(l<8?l:8)))*n.errorRetryInterval;(eo(i)||!(l>i))&&setTimeout(r,a,o)},onDiscarded:et,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:ek?1e4:5e3,focusThrottleInterval:5e3,dedupingInterval:2e3,loadingTimeout:ek?5e3:3e3,compare:function e(t,n){var r,o;if(t===n)return!0;if(t&&n&&(r=t.constructor)===n.constructor){if(r===Date)return t.getTime()===n.getTime();if(r===RegExp)return t.toString()===n.toString();if(r===Array){if((o=t.length)===n.length)for(;o--&&e(t[o],n[o]););return -1===o}if(!r||"object"==typeof t){for(r in o=0,t)if(G.call(t,r)&&++o&&!G.call(n,r)||!(r in n)||!e(t[r],n[r]))return!1;return Object.keys(n).length===o}}return t!=t&&n!=n},isPaused:()=>!1,cache:eP,mutate:eL,fallback:{}},{isOnline:()=>eh,isVisible:()=>{let e=ec&&document.visibilityState;return eo(e)||"hidden"!==e}}),eM=(e,t)=>{let n=ei(e,t);if(t){let{use:r,fallback:o}=e,{use:i,fallback:l}=t;r&&i&&(n.use=r.concat(i)),o&&l&&(n.fallback=ei(o,l))}return n},eN=(0,s.createContext)({}),ej=eu&&window.__SWR_DEVTOOLS_USE__,eF=(ej?window.__SWR_DEVTOOLS_USE__:[]).concat(e=>(t,n,r)=>{let o=n&&((...e)=>{let[r]=eA(t),[,,,o]=ee.get(eP);if(r.startsWith("$inf$"))return n(...e);let i=o[r];return eo(i)?n(...e):(delete o[r],i)});return e(t,o,r)});ej&&(window.__SWR_DEVTOOLS_REACT__=s);let eB=()=>{},ez=eB();new WeakMap;let eU=s.use||(e=>{switch(e.status){case"pending":throw e;case"fulfilled":return e.value;case"rejected":throw e.reason;default:throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}}),eV={dedupe:!0},eH=Promise.resolve(en);er.defineProperty(e=>{let{value:t}=e,n=(0,s.useContext)(eN),r="function"==typeof t,o=(0,s.useMemo)(()=>r?t(n):t,[r,n,t]),i=(0,s.useMemo)(()=>r?o:eM(n,o),[r,n,o]),l=o&&o.provider,a=(0,s.useRef)(en);l&&!a.current&&(a.current=eR(l(i.cache||eP),o));let u=a.current;return u&&(i.cache=u[0],i.mutate=u[1]),eb(()=>{if(u)return u[2]&&u[2](),u[3]},[]),(0,s.createElement)(eN.Provider,ei(e,{value:i}))},"defaultValue",{value:eD});let eq=(r=(e,t,n)=>{let{cache:r,compare:o,suspense:i,fallbackData:l,revalidateOnMount:a,revalidateIfStale:u,refreshInterval:c,refreshWhenHidden:f,refreshWhenOffline:p,keepPreviousData:h}=n,[d,g,m,y]=ee.get(r),[v,b]=eA(e),x=(0,s.useRef)(!1),k=(0,s.useRef)(!1),w=(0,s.useRef)(v),E=(0,s.useRef)(t),S=(0,s.useRef)(n),I=()=>S.current.isVisible()&&S.current.isOnline(),[A,T,_,C]=ep(r,v),O=(0,s.useRef)({}).current,R=eo(l)?eo(n.fallback)?en:n.fallback[v]:l,P=(e,t)=>{for(let n in O)if("data"===n){if(!o(e[n],t[n])&&(!eo(e[n])||!o(U,t[n])))return!1}else if(t[n]!==e[n])return!1;return!0},L=(0,s.useMemo)(()=>{let e=!!v&&!!t&&(eo(a)?!S.current.isPaused()&&!i&&!1!==u:a),n=t=>{let n=ei(t);return(delete n._k,e)?{isValidating:!0,isLoading:!0,...n}:n},r=A(),o=C(),l=n(r),s=r===o?l:n(o),c=l;return[()=>{let e=n(A());return P(e,c)?(c.data=e.data,c.isLoading=e.isLoading,c.isValidating=e.isValidating,c.error=e.error,c):(c=e,e)},()=>s]},[r,v]),D=(0,Z.useSyncExternalStore)((0,s.useCallback)(e=>_(v,(t,n)=>{P(n,t)||e()}),[r,v]),L[0],L[1]),M=!x.current,N=d[v]&&d[v].length>0,j=D.data,F=eo(j)?R&&"function"==typeof R.then?eU(R):R:j,B=D.error,z=(0,s.useRef)(F),U=h?eo(j)?eo(z.current)?F:z.current:j:F,V=(!N||!!eo(B))&&(M&&!eo(a)?a:!S.current.isPaused()&&(i?!eo(F)&&u:eo(F)||u)),H=!!(v&&t&&M&&V),q=eo(D.isValidating)?H:D.isValidating,J=eo(D.isLoading)?H:D.isLoading,W=(0,s.useCallback)(async e=>{let t,r,i=E.current;if(!v||!i||k.current||S.current.isPaused())return!1;let l=!0,a=e||{},s=!m[v]||!a.dedupe,u=()=>ey?!k.current&&v===w.current&&x.current:v===w.current,c={isValidating:!1,isLoading:!1},f=()=>{T(c)},p=()=>{let e=m[v];e&&e[1]===r&&delete m[v]},h={isValidating:!0};eo(A().data)&&(h.isLoading=!0);try{if(s&&(T(h),n.loadingTimeout&&eo(A().data)&&setTimeout(()=>{l&&u()&&S.current.onLoadingSlow(v,n)},n.loadingTimeout),m[v]=[i(b),e_()]),[t,r]=m[v],t=await t,s&&setTimeout(p,n.dedupingInterval),!m[v]||m[v][1]!==r)return s&&u()&&S.current.onDiscarded(v),!1;c.error=en;let e=g[v];if(!eo(e)&&(r<=e[0]||r<=e[1]||0===e[1]))return f(),s&&u()&&S.current.onDiscarded(v),!1;let a=A().data;c.data=o(a,t)?a:t,s&&u()&&S.current.onSuccess(t,v,n)}catch(n){p();let e=S.current,{shouldRetryOnError:t}=e;!e.isPaused()&&(c.error=n,s&&u())&&(e.onError(n,v,e),(!0===t||"function"==typeof t&&t(n))&&(!S.current.revalidateOnFocus||!S.current.revalidateOnReconnect||I())&&e.onErrorRetry(n,v,e,e=>{let t=d[v];t&&t[0]&&t[0](3,e)},{retryCount:(a.retryCount||0)+1,dedupe:!0}))}return l=!1,f(),!0},[v,r]),Y=(0,s.useCallback)((...e)=>eC(r,w.current,...e),[]);if(eb(()=>{E.current=t,S.current=n,eo(j)||(z.current=j)}),eb(()=>{if(!v)return;let e=W.bind(en,eV),t=0;S.current.revalidateOnFocus&&(t=Date.now()+S.current.focusThrottleInterval);let n=((e,t,n)=>{let r=t[e]||(t[e]=[]);return r.push(n),()=>{let e=r.indexOf(n);e>=0&&(r[e]=r[r.length-1],r.pop())}})(v,d,(n,r={})=>{if(0==n){let n=Date.now();S.current.revalidateOnFocus&&n>t&&I()&&(t=n+S.current.focusThrottleInterval,e())}else if(1==n)S.current.revalidateOnReconnect&&I()&&e();else if(2==n)return W();else if(3==n)return W(r)});return k.current=!1,w.current=v,x.current=!0,T({_k:b}),V&&!m[v]&&(eo(F)||ev?e():(e=>eu&&typeof window.requestAnimationFrame!=es?window.requestAnimationFrame(e):setTimeout(e,1))(e)),()=>{k.current=!0,n()}},[v]),eb(()=>{let e;function t(){let t="function"==typeof c?c(A().data):c;t&&-1!==e&&(e=setTimeout(n,t))}function n(){!A().error&&(f||S.current.isVisible())&&(p||S.current.isOnline())?W(eV).then(t):t()}return t(),()=>{e&&(clearTimeout(e),e=-1)}},[c,f,p,v]),(0,s.useDebugValue)(U),i){let e=v&&eo(F);if(!ey&&ev&&e)throw Error("Fallback data is required when using Suspense in SSR.");e&&(E.current=t,S.current=n,k.current=!1);let r=y[v];if(eU(!eo(r)&&e?Y(r):eH),!eo(B)&&e)throw B;let o=e?W(eV):eH;!eo(U)&&e&&(o.status="fulfilled",o.value=!0),eU(o)}return{mutate:Y,get data(){return O.data=!0,U},get error(){return O.error=!0,B},get isValidating(){return O.isValidating=!0,q},get isLoading(){return O.isLoading=!0,J}}},function(...e){let t=(()=>{let e=(0,s.useContext)(eN);return(0,s.useMemo)(()=>ei(eD,e),[e])})(),[n,o,i]="function"==typeof e[1]?[e[0],e[1],e[2]||{}]:[e[0],null,(null===e[1]?e[2]:e[1])||{}],l=eM(t,i),a=r,{use:u}=l,c=(u||[]).concat(eF);for(let e=c.length;e--;)a=c[e](a);return a(n,o||l.fetcher||null,l)});var eJ=n(21649);function eW(e,t){return null!=t?eJ(e,t):e}var eY=function({api:e="/api/chat",id:t,initialMessages:n,initialInput:r="",sendExtraMessageFields:o,onToolCall:i,experimental_prepareRequestBody:l,maxSteps:a=1,streamProtocol:u="data",onResponse:c,onFinish:f,onError:p,credentials:h,headers:d,body:g,generateId:m=T,fetch:y,keepLastMessageOnError:v=!0,experimental_throttle:b}={}){let[x]=(0,s.useState)(m),k=null!=t?t:x,w="string"==typeof e?[e,k]:k,E=function(e){let[t,n]=(0,s.useState)(e);return(0,s.useEffect)(()=>{!function e(t,n){if(t===n)return!0;if(null==t||null==n)return!1;if("object"!=typeof t&&"object"!=typeof n)return t===n;if(t.constructor!==n.constructor)return!1;if(t instanceof Date&&n instanceof Date)return t.getTime()===n.getTime();if(Array.isArray(t)){if(t.length!==n.length)return!1;for(let r=0;rK(E),[E])}),A=(0,s.useRef)(S||[]);(0,s.useEffect)(()=>{A.current=S||[]},[S]);let{data:_,mutate:C}=eq([w,"streamData"],null),O=(0,s.useRef)(_);(0,s.useEffect)(()=>{O.current=_},[_]);let{data:R="ready",mutate:P}=eq([w,"status"],null),{data:L,mutate:D}=eq([w,"error"],null),M=(0,s.useRef)(null),N=(0,s.useRef)({credentials:h,headers:d,body:g});(0,s.useEffect)(()=>{N.current={credentials:h,headers:d,body:g}},[h,d,g]);let j=(0,s.useCallback)(async(t,n="generate")=>{var r,s;P("submitted"),D(void 0);let h=K(t.messages),d=h.length,g=Y(null==(r=h[h.length-1])?void 0:r.toolInvocations);try{M.current=new AbortController;let r=eW(I,b),a=eW(C,b),p=A.current;r(h,!1);let d=o?h:h.map(({role:e,content:t,experimental_attachments:n,data:r,annotations:o,toolInvocations:i,parts:l})=>({role:e,content:t,...void 0!==n&&{experimental_attachments:n},...void 0!==r&&{data:r},...void 0!==o&&{annotations:o},...void 0!==i&&{toolInvocations:i},...void 0!==l&&{parts:l}})),g=O.current;await W({api:e,body:null!=(s=null==l?void 0:l({id:k,messages:h,requestData:t.data,requestBody:t.body}))?s:{id:k,messages:d,data:t.data,...N.current.body,...t.body},streamProtocol:u,credentials:N.current.credentials,headers:{...N.current.headers,...t.headers},abortController:()=>M.current,restoreMessagesOnFailure(){v||r(p,!1)},onResponse:c,onUpdate({message:e,data:t,replaceLastMessage:n}){P("streaming"),r([...n?h.slice(0,h.length-1):h,e],!1),(null==t?void 0:t.length)&&a([...null!=g?g:[],...t],!1)},onToolCall:i,onFinish:f,generateId:m,fetch:y,lastMessage:h[h.length-1],requestType:n}),M.current=null,P("ready")}catch(e){if("AbortError"===e.name)return M.current=null,P("ready"),null;p&&e instanceof Error&&p(e),D(e),P("error")}let x=A.current;(function({originalMaxToolInvocationStep:e,originalMessageCount:t,maxSteps:n,messages:r}){var o;let i=r[r.length-1];return n>1&&null!=i&&(r.length>t||Y(i.toolInvocations)!==e)&&X(i)&&(null!=(o=Y(i.toolInvocations))?o:0){var i,l;let a=await Q(o);return j({messages:A.current.concat({...e,id:null!=(i=e.id)?i:m(),createdAt:null!=(l=e.createdAt)?l:new Date,experimental_attachments:a.length>0?a:void 0,parts:$(e)}),headers:n,body:r,data:t})},[j,m]),B=(0,s.useCallback)(async({data:e,headers:t,body:n}={})=>{let r=A.current;return 0===r.length?null:j({messages:"assistant"===r[r.length-1].role?r.slice(0,-1):r,headers:t,body:n,data:e})},[j]),z=(0,s.useCallback)(()=>{M.current&&(M.current.abort(),M.current=null)},[]),U=(0,s.useCallback)(async()=>{j({messages:A.current},"resume")},[j]),V=(0,s.useCallback)(e=>{"function"==typeof e&&(e=e(A.current));let t=K(e);I(t,!1),A.current=t},[I]),H=(0,s.useCallback)(e=>{"function"==typeof e&&(e=e(O.current)),C(e,!1),O.current=e},[C]),[q,J]=(0,s.useState)(r),Z=(0,s.useCallback)(async(e,t={},n)=>{var r;if(null==(r=null==e?void 0:e.preventDefault)||r.call(e),!q&&!t.allowEmptySubmit)return;n&&(N.current={...N.current,...n});let o=await Q(t.experimental_attachments);j({messages:A.current.concat({id:m(),createdAt:new Date,role:"user",content:q,experimental_attachments:o.length>0?o:void 0,parts:[{type:"text",text:q}]}),headers:t.headers,body:t.body,data:t.data}),J("")},[q,m,j]),G=(0,s.useCallback)(({toolCallId:e,result:t})=>{let n=A.current;!function({messages:e,toolCallId:t,toolResult:n}){var r;let o=e[e.length-1],i=o.parts.find(e=>"tool-invocation"===e.type&&e.toolInvocation.toolCallId===t);if(null==i)return;let l={...i.toolInvocation,state:"result",result:n};i.toolInvocation=l,o.toolInvocations=null==(r=o.toolInvocations)?void 0:r.map(e=>e.toolCallId===t?l:e)}({messages:n,toolCallId:e,toolResult:t}),I([...n.slice(0,n.length-1),{...n[n.length-1]}],!1),"submitted"!==R&&"streaming"!==R&&X(n[n.length-1])&&j({messages:n})},[I,R,j]);return{messages:null!=S?S:[],id:k,setMessages:V,data:_,setData:H,error:L,append:F,reload:B,stop:z,experimental_resume:U,input:q,setInput:J,handleInputChange:e=>{J(e.target.value)},handleSubmit:Z,isLoading:"submitted"===R||"streaming"===R,status:R,addToolResult:G}}},57719:(e,t)=>{"use strict";t.byteLength=function(e){var t=s(e),n=t[0],r=t[1];return(n+r)*3/4-r},t.toByteArray=function(e){var t,n,i=s(e),l=i[0],a=i[1],u=new o((l+a)*3/4-a),c=0,f=a>0?l-4:l;for(n=0;n>16&255,u[c++]=t>>8&255,u[c++]=255&t;return 2===a&&(t=r[e.charCodeAt(n)]<<2|r[e.charCodeAt(n+1)]>>4,u[c++]=255&t),1===a&&(t=r[e.charCodeAt(n)]<<10|r[e.charCodeAt(n+1)]<<4|r[e.charCodeAt(n+2)]>>2,u[c++]=t>>8&255,u[c++]=255&t),u},t.fromByteArray=function(e){for(var t,r=e.length,o=r%3,i=[],l=0,a=r-o;l>18&63]+n[o>>12&63]+n[o>>6&63]+n[63&o]);return i.join("")}(e,l,l+16383>a?a:l+16383));return 1===o?i.push(n[(t=e[r-1])>>2]+n[t<<4&63]+"=="):2===o&&i.push(n[(t=(e[r-2]<<8)+e[r-1])>>10]+n[t>>4&63]+n[t<<2&63]+"="),i.join("")};for(var n=[],r=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",l=0,a=i.length;l0)throw Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");-1===n&&(n=t);var r=n===t?0:4-n%4;return[n,r]}r[45]=62,r[95]=63},62146:(e,t,n)=>{"use strict";function r(e){let{reason:t,children:n}=e;return n}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"BailoutToCSR",{enumerable:!0,get:function(){return r}}),n(45262)},64054:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var n in t)Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}(t,{bindSnapshot:function(){return l},createAsyncLocalStorage:function(){return i},createSnapshot:function(){return a}});let n=Object.defineProperty(Error("Invariant: AsyncLocalStorage accessed in runtime where it is not available"),"__NEXT_ERROR_CODE",{value:"E504",enumerable:!1,configurable:!0});class r{disable(){throw n}getStore(){}run(){throw n}exit(){throw n}enterWith(){throw n}static bind(e){return e}}let o="undefined"!=typeof globalThis&&globalThis.AsyncLocalStorage;function i(){return o?new o:new r}function l(e){return o?o.bind(e):r.bind(e)}function a(){return o?o.snapshot():function(e,...t){return e(...t)}}},67357:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return s}});let r=n(95155),o=n(12115),i=n(62146);function l(e){return{default:e&&"default"in e?e.default:e}}n(10255);let a={loader:()=>Promise.resolve(l(()=>null)),loading:null,ssr:!0},s=function(e){let t={...a,...e},n=(0,o.lazy)(()=>t.loader().then(l)),s=t.loading;function u(e){let l=s?(0,r.jsx)(s,{isLoading:!0,pastDelay:!0,error:null}):null,a=!t.ssr||!!t.loading,u=a?o.Suspense:o.Fragment,c=t.ssr?(0,r.jsxs)(r.Fragment,{children:[null,(0,r.jsx)(n,{...e})]}):(0,r.jsx)(i.BailoutToCSR,{reason:"next/dynamic",children:(0,r.jsx)(n,{...e})});return(0,r.jsx)(u,{...a?{fallback:l}:{},children:c})}return u.displayName="LoadableComponent",u}},83082:(e,t,n)=>{"use strict";var r=n(44134).hp;let o=void 0!==r,i=/"(?:_|\\u005[Ff])(?:_|\\u005[Ff])(?:p|\\u0070)(?:r|\\u0072)(?:o|\\u006[Ff])(?:t|\\u0074)(?:o|\\u006[Ff])(?:_|\\u005[Ff])(?:_|\\u005[Ff])"\s*:/,l=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/;function a(e,t,n){null==n&&null!==t&&"object"==typeof t&&(n=t,t=void 0),o&&r.isBuffer(e)&&(e=e.toString()),e&&65279===e.charCodeAt(0)&&(e=e.slice(1));let a=JSON.parse(e,t);if(null===a||"object"!=typeof a)return a;let u=n&&n.protoAction||"error",c=n&&n.constructorAction||"error";if("ignore"===u&&"ignore"===c)return a;if("ignore"!==u&&"ignore"!==c){if(!1===i.test(e)&&!1===l.test(e))return a}else if("ignore"!==u&&"ignore"===c){if(!1===i.test(e))return a}else if(!1===l.test(e))return a;return s(a,{protoAction:u,constructorAction:c,safe:n&&n.safe})}function s(e,{protoAction:t="error",constructorAction:n="error",safe:r}={}){let o=[e];for(;o.length;){let e=o;for(let i of(o=[],e)){if("ignore"!==t&&Object.prototype.hasOwnProperty.call(i,"__proto__")){if(!0===r)return null;if("error"===t)throw SyntaxError("Object contains forbidden prototype property");delete i.__proto__}if("ignore"!==n&&Object.prototype.hasOwnProperty.call(i,"constructor")&&Object.prototype.hasOwnProperty.call(i.constructor,"prototype")){if(!0===r)return null;if("error"===n)throw SyntaxError("Object contains forbidden prototype property");delete i.constructor}for(let e in i){let t=i[e];t&&"object"==typeof t&&o.push(t)}}}return e}function u(e,t,n){let r=Error.stackTraceLimit;Error.stackTraceLimit=0;try{return a(e,t,n)}finally{Error.stackTraceLimit=r}}e.exports=u,e.exports.default=u,e.exports.parse=u,e.exports.safeParse=function(e,t){let n=Error.stackTraceLimit;Error.stackTraceLimit=0;try{return a(e,t,{safe:!0})}catch(e){return null}finally{Error.stackTraceLimit=n}},e.exports.scan=s},85744:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"workAsyncStorage",{enumerable:!0,get:function(){return r.workAsyncStorageInstance}});let r=n(17828)},87924:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=null;if(!e||"string"!=typeof e)return n;var r=(0,o.default)(e),i="function"==typeof t;return r.forEach(function(e){if("declaration"===e.type){var r=e.property,o=e.value;i?t(r,o,e):o&&((n=n||{})[r]=o)}}),n};var o=r(n(36301))},90792:(e,t,n)=>{"use strict";n.d(t,{oz:()=>n_});var r={};n.r(r),n.d(r,{boolean:()=>m,booleanish:()=>y,commaOrSpaceSeparated:()=>w,commaSeparated:()=>k,number:()=>b,overloadedBoolean:()=>v,spaceSeparated:()=>x});var o={};n.r(o),n.d(o,{attentionMarkers:()=>tT,contentInitial:()=>tk,disable:()=>t_,document:()=>tx,flow:()=>tE,flowInitial:()=>tw,insideSpan:()=>tA,string:()=>tS,text:()=>tI});let i=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,l=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,a={};function s(e,t){return((t||a).jsx?l:i).test(e)}let u=/[ \t\n\f\r]/g;function c(e){return""===e.replace(u,"")}class f{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}}function p(e,t){let n={},r={};for(let t of e)Object.assign(n,t.property),Object.assign(r,t.normal);return new f(n,r,t)}function h(e){return e.toLowerCase()}f.prototype.normal={},f.prototype.property={},f.prototype.space=void 0;class d{constructor(e,t){this.attribute=t,this.property=e}}d.prototype.attribute="",d.prototype.booleanish=!1,d.prototype.boolean=!1,d.prototype.commaOrSpaceSeparated=!1,d.prototype.commaSeparated=!1,d.prototype.defined=!1,d.prototype.mustUseProperty=!1,d.prototype.number=!1,d.prototype.overloadedBoolean=!1,d.prototype.property="",d.prototype.spaceSeparated=!1,d.prototype.space=void 0;let g=0,m=E(),y=E(),v=E(),b=E(),x=E(),k=E(),w=E();function E(){return 2**++g}let S=Object.keys(r);class I extends d{constructor(e,t,n,o){let i=-1;if(super(e,t),function(e,t,n){n&&(e[t]=n)}(this,"space",o),"number"==typeof n)for(;++i"role"===t?t:"aria-"+t.slice(4).toLowerCase()});function _(e,t){return t in e?e[t]:t}function C(e,t){return _(e,t.toLowerCase())}let O=A({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:k,acceptCharset:x,accessKey:x,action:null,allow:null,allowFullScreen:m,allowPaymentRequest:m,allowUserMedia:m,alt:null,as:null,async:m,autoCapitalize:null,autoComplete:x,autoFocus:m,autoPlay:m,blocking:x,capture:null,charSet:null,checked:m,cite:null,className:x,cols:b,colSpan:null,content:null,contentEditable:y,controls:m,controlsList:x,coords:b|k,crossOrigin:null,data:null,dateTime:null,decoding:null,default:m,defer:m,dir:null,dirName:null,disabled:m,download:v,draggable:y,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:m,formTarget:null,headers:x,height:b,hidden:v,high:b,href:null,hrefLang:null,htmlFor:x,httpEquiv:x,id:null,imageSizes:null,imageSrcSet:null,inert:m,inputMode:null,integrity:null,is:null,isMap:m,itemId:null,itemProp:x,itemRef:x,itemScope:m,itemType:x,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:m,low:b,manifest:null,max:null,maxLength:b,media:null,method:null,min:null,minLength:b,multiple:m,muted:m,name:null,nonce:null,noModule:m,noValidate:m,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:m,optimum:b,pattern:null,ping:x,placeholder:null,playsInline:m,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:m,referrerPolicy:null,rel:x,required:m,reversed:m,rows:b,rowSpan:b,sandbox:x,scope:null,scoped:m,seamless:m,selected:m,shadowRootClonable:m,shadowRootDelegatesFocus:m,shadowRootMode:null,shape:null,size:b,sizes:null,slot:null,span:b,spellCheck:y,src:null,srcDoc:null,srcLang:null,srcSet:null,start:b,step:null,style:null,tabIndex:b,target:null,title:null,translate:null,type:null,typeMustMatch:m,useMap:null,value:y,width:b,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:x,axis:null,background:null,bgColor:null,border:b,borderColor:null,bottomMargin:b,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:m,declare:m,event:null,face:null,frame:null,frameBorder:null,hSpace:b,leftMargin:b,link:null,longDesc:null,lowSrc:null,marginHeight:b,marginWidth:b,noResize:m,noHref:m,noShade:m,noWrap:m,object:null,profile:null,prompt:null,rev:null,rightMargin:b,rules:null,scheme:null,scrolling:y,standby:null,summary:null,text:null,topMargin:b,valueType:null,version:null,vAlign:null,vLink:null,vSpace:b,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:m,disableRemotePlayback:m,prefix:null,property:null,results:b,security:null,unselectable:null},space:"html",transform:C}),R=A({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:w,accentHeight:b,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:b,amplitude:b,arabicForm:null,ascent:b,attributeName:null,attributeType:null,azimuth:b,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:b,by:null,calcMode:null,capHeight:b,className:x,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:b,diffuseConstant:b,direction:null,display:null,dur:null,divisor:b,dominantBaseline:null,download:m,dx:null,dy:null,edgeMode:null,editable:null,elevation:b,enableBackground:null,end:null,event:null,exponent:b,externalResourcesRequired:null,fill:null,fillOpacity:b,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:k,g2:k,glyphName:k,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:b,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:b,horizOriginX:b,horizOriginY:b,id:null,ideographic:b,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:b,k:b,k1:b,k2:b,k3:b,k4:b,kernelMatrix:w,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:b,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:b,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:b,overlineThickness:b,paintOrder:null,panose1:null,path:null,pathLength:b,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:x,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:b,pointsAtY:b,pointsAtZ:b,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:w,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:w,rev:w,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:w,requiredFeatures:w,requiredFonts:w,requiredFormats:w,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:b,specularExponent:b,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:b,strikethroughThickness:b,string:null,stroke:null,strokeDashArray:w,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:b,strokeOpacity:b,strokeWidth:null,style:null,surfaceScale:b,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:w,tabIndex:b,tableValues:null,target:null,targetX:b,targetY:b,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:w,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:b,underlineThickness:b,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:b,values:null,vAlphabetic:b,vMathematical:b,vectorEffect:null,vHanging:b,vIdeographic:b,version:null,vertAdvY:b,vertOriginX:b,vertOriginY:b,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:b,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:_}),P=A({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform:(e,t)=>"xlink:"+t.slice(5).toLowerCase()}),L=A({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:C}),D=A({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform:(e,t)=>"xml:"+t.slice(3).toLowerCase()}),M=p([T,O,P,L,D],"html"),N=p([T,R,P,L,D],"svg"),j=/[A-Z]/g,F=/-[a-z]/g,B=/^data[-\w.:]+$/i;function z(e){return"-"+e.toLowerCase()}function U(e){return e.charAt(1).toUpperCase()}let V={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"};var H=n(53724);let q=W("end"),J=W("start");function W(e){return function(t){let n=t&&t.position&&t.position[e]||{};if("number"==typeof n.line&&n.line>0&&"number"==typeof n.column&&n.column>0)return{line:n.line,column:n.column,offset:"number"==typeof n.offset&&n.offset>-1?n.offset:void 0}}}function Y(e){return e&&"object"==typeof e?"position"in e||"type"in e?K(e.position):"start"in e||"end"in e?K(e):"line"in e||"column"in e?$(e):"":""}function $(e){return Q(e&&e.line)+":"+Q(e&&e.column)}function K(e){return $(e&&e.start)+"-"+$(e&&e.end)}function Q(e){return e&&"number"==typeof e?e:1}class X extends Error{constructor(e,t,n){super(),"string"==typeof t&&(n=t,t=void 0);let r="",o={},i=!1;if(t&&(o="line"in t&&"column"in t||"start"in t&&"end"in t?{place:t}:"type"in t?{ancestors:[t],place:t.position}:{...t}),"string"==typeof e?r=e:!o.cause&&e&&(i=!0,r=e.message,o.cause=e),!o.ruleId&&!o.source&&"string"==typeof n){let e=n.indexOf(":");-1===e?o.ruleId=n:(o.source=n.slice(0,e),o.ruleId=n.slice(e+1))}if(!o.place&&o.ancestors&&o.ancestors){let e=o.ancestors[o.ancestors.length-1];e&&(o.place=e.position)}let l=o.place&&"start"in o.place?o.place.start:o.place;this.ancestors=o.ancestors||void 0,this.cause=o.cause||void 0,this.column=l?l.column:void 0,this.fatal=void 0,this.file="",this.message=r,this.line=l?l.line:void 0,this.name=Y(o.place)||"1:1",this.place=o.place||void 0,this.reason=this.message,this.ruleId=o.ruleId||void 0,this.source=o.source||void 0,this.stack=i&&o.cause&&"string"==typeof o.cause.stack?o.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}X.prototype.file="",X.prototype.name="",X.prototype.reason="",X.prototype.message="",X.prototype.stack="",X.prototype.column=void 0,X.prototype.line=void 0,X.prototype.ancestors=void 0,X.prototype.cause=void 0,X.prototype.fatal=void 0,X.prototype.place=void 0,X.prototype.ruleId=void 0,X.prototype.source=void 0;let Z={}.hasOwnProperty,G=new Map,ee=/[A-Z]/g,et=new Set(["table","tbody","thead","tfoot","tr"]),en=new Set(["td","th"]),er="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function eo(e,t,n){return"element"===t.type?function(e,t,n){let r=e.schema;"svg"===t.tagName.toLowerCase()&&"html"===r.space&&(e.schema=N),e.ancestors.push(t);let o=es(e,t.tagName,!1),i=function(e,t){let n,r,o={};for(r in t.properties)if("children"!==r&&Z.call(t.properties,r)){let i=function(e,t,n){let r=function(e,t){let n=h(t),r=t,o=d;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&"data"===n.slice(0,4)&&B.test(t)){if("-"===t.charAt(4)){let e=t.slice(5).replace(F,U);r="data"+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!F.test(e)){let n=e.replace(j,z);"-"!==n.charAt(0)&&(n="-"+n),t="data"+n}}o=I}return new o(r,t)}(e.schema,t);if(!(null==n||"number"==typeof n&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?function(e,t){let n={};return(""===e[e.length-1]?[...e,""]:e).join((n.padRight?" ":"")+","+(!1===n.padLeft?"":" ")).trim()}(n):n.join(" ").trim()),"style"===r.property){let t="object"==typeof n?n:function(e,t){try{return H(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};let t=new X("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:n,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw t.file=e.filePath||void 0,t.url=er+"#cannot-parse-style-attribute",t}}(e,String(n));return"css"===e.stylePropertyNameCase&&(t=function(e){let t,n={};for(t in e)Z.call(e,t)&&(n[function(e){let t=e.replace(ee,ec);return"ms-"===t.slice(0,3)&&(t="-"+t),t}(t)]=e[t]);return n}(t)),["style",t]}return["react"===e.elementAttributeNameCase&&r.space?V[r.property]||r.property:r.attribute,n]}}(e,r,t.properties[r]);if(i){let[r,l]=i;e.tableCellAlignToStyle&&"align"===r&&"string"==typeof l&&en.has(t.tagName)?n=l:o[r]=l}}return n&&((o.style||(o.style={}))["css"===e.stylePropertyNameCase?"text-align":"textAlign"]=n),o}(e,t),l=ea(e,t);return et.has(t.tagName)&&(l=l.filter(function(e){return"string"!=typeof e||!("object"==typeof e?"text"===e.type&&c(e.value):c(e))})),ei(e,i,o,t),el(i,l),e.ancestors.pop(),e.schema=r,e.create(t,o,i,n)}(e,t,n):"mdxFlowExpression"===t.type||"mdxTextExpression"===t.type?function(e,t){if(t.data&&t.data.estree&&e.evaluater){let n=t.data.estree.body[0];return n.type,e.evaluater.evaluateExpression(n.expression)}eu(e,t.position)}(e,t):"mdxJsxFlowElement"===t.type||"mdxJsxTextElement"===t.type?function(e,t,n){let r=e.schema;"svg"===t.name&&"html"===r.space&&(e.schema=N),e.ancestors.push(t);let o=null===t.name?e.Fragment:es(e,t.name,!0),i=function(e,t){let n={};for(let r of t.attributes)if("mdxJsxExpressionAttribute"===r.type)if(r.data&&r.data.estree&&e.evaluater){let t=r.data.estree.body[0];t.type;let o=t.expression;o.type;let i=o.properties[0];i.type,Object.assign(n,e.evaluater.evaluateExpression(i.argument))}else eu(e,t.position);else{let o,i=r.name;if(r.value&&"object"==typeof r.value)if(r.value.data&&r.value.data.estree&&e.evaluater){let t=r.value.data.estree.body[0];t.type,o=e.evaluater.evaluateExpression(t.expression)}else eu(e,t.position);else o=null===r.value||r.value;n[i]=o}return n}(e,t),l=ea(e,t);return ei(e,i,o,t),el(i,l),e.ancestors.pop(),e.schema=r,e.create(t,o,i,n)}(e,t,n):"mdxjsEsm"===t.type?function(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);eu(e,t.position)}(e,t):"root"===t.type?function(e,t,n){let r={};return el(r,ea(e,t)),e.create(t,e.Fragment,r,n)}(e,t,n):"text"===t.type?t.value:void 0}function ei(e,t,n,r){"string"!=typeof n&&n!==e.Fragment&&e.passNode&&(t.node=r)}function el(e,t){if(t.length>0){let n=t.length>1?t:t[0];n&&(e.children=n)}}function ea(e,t){let n=[],r=-1,o=e.passKeys?new Map:G;for(;++ri?0:i+t:t>i?i:t,n=n>0?n:0,r.length<1e4)(o=Array.from(r)).unshift(t,n),e.splice(...o);else for(n&&e.splice(t,n);l0?(em(e,e.length,0,t),e):t}class ev{constructor(e){this.left=e?[...e]:[],this.right=[]}get(e){if(e<0||e>=this.left.length+this.right.length)throw RangeError("Cannot access index `"+e+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return ethis.left.length?this.right.slice(this.right.length-n+this.left.length,this.right.length-e+this.left.length).reverse():this.left.slice(e).concat(this.right.slice(this.right.length-n+this.left.length).reverse())}splice(e,t,n){this.setCursor(Math.trunc(e));let r=this.right.splice(this.right.length-(t||0),1/0);return n&&eb(this.left,n),r.reverse()}pop(){return this.setCursor(1/0),this.left.pop()}push(e){this.setCursor(1/0),this.left.push(e)}pushMany(e){this.setCursor(1/0),eb(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),eb(this.right,e.reverse())}setCursor(e){if(e!==this.left.length&&(!(e>this.left.length)||0!==this.right.length)&&(!(e<0)||0!==this.left.length))if(e-1&&e.test(String.fromCharCode(t))}}function eM(e,t,n,r){let o=r?r-1:1/0,i=0;return function(r){return eR(r)?(e.enter(n),function r(l){return eR(l)&&i++r))return;let a=o.events.length,s=a;for(;s--;)if("exit"===o.events[s][0]&&"chunkFlow"===o.events[s][1].type){if(e){n=o.events[s][1].end;break}e=!0}for(m(l),i=a;it;){let t=i[n];o.containerState=t[1],t[0].exit.call(o,e)}i.length=t}function y(){t.write([null]),n=void 0,t=void 0,o.containerState._closeFlow=void 0}}},eF={tokenize:function(e,t,n){return eM(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}},eB={partial:!0,tokenize:function(e,t,n){return function(t){return eR(t)?eM(e,r,"linePrefix")(t):r(t)};function r(e){return null===e||eC(e)?t(e):n(e)}}},ez={resolve:function(e){return ex(e),e},tokenize:function(e,t){let n;return function(t){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),r(t)};function r(t){return null===t?o(t):eC(t)?e.check(eU,i,o)(t):(e.consume(t),r)}function o(n){return e.exit("chunkContent"),e.exit("content"),t(n)}function i(t){return e.consume(t),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,r}}},eU={partial:!0,tokenize:function(e,t,n){let r=this;return function(t){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),eM(e,o,"linePrefix")};function o(o){if(null===o||eC(o))return n(o);let i=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&i&&"linePrefix"===i[1].type&&i[2].sliceSerialize(i[1],!0).length>=4?t(o):e.interrupt(r.parser.constructs.flow,n,t)(o)}}},eV={tokenize:function(e){let t=this,n=e.attempt(eB,function(r){return null===r?void e.consume(r):(e.enter("lineEndingBlank"),e.consume(r),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n)},e.attempt(this.parser.constructs.flowInitial,r,eM(e,e.attempt(this.parser.constructs.flow,r,e.attempt(ez,r)),"linePrefix")));return n;function r(r){return null===r?void e.consume(r):(e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),t.currentConstruct=void 0,n)}}},eH={resolveAll:eY()},eq=eW("string"),eJ=eW("text");function eW(e){return{resolveAll:eY("text"===e?e$:void 0),tokenize:function(t){let n=this,r=this.parser.constructs[e],o=t.attempt(r,i,l);return i;function i(e){return s(e)?o(e):l(e)}function l(e){return null===e?void t.consume(e):(t.enter("data"),t.consume(e),a)}function a(e){return s(e)?(t.exit("data"),o(e)):(t.consume(e),a)}function s(e){if(null===e)return!0;let t=r[e],o=-1;if(t)for(;++o=3&&(null===l||eC(l))?(e.exit("thematicBreak"),t(l)):n(l)}(l)}}},eQ={continuation:{tokenize:function(e,t,n){let r=this;return r.containerState._closeFlow=void 0,e.check(eB,function(n){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,eM(e,t,"listItemIndent",r.containerState.size+1)(n)},function(n){return r.containerState.furtherBlankLines||!eR(n)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(n)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(eZ,t,o)(n))});function o(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,eM(e,e.attempt(eQ,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o)}}},exit:function(e){e.exit(this.containerState.type)},name:"list",tokenize:function(e,t,n){let r=this,o=r.events[r.events.length-1],i=o&&"linePrefix"===o[1].type?o[2].sliceSerialize(o[1],!0).length:0,l=0;return function(t){let o=r.containerState.type||(42===t||43===t||45===t?"listUnordered":"listOrdered");if("listUnordered"===o?!r.containerState.marker||t===r.containerState.marker:eA(t)){if(r.containerState.type||(r.containerState.type=o,e.enter(o,{_container:!0})),"listUnordered"===o)return e.enter("listItemPrefix"),42===t||45===t?e.check(eK,n,a)(t):a(t);if(!r.interrupt||49===t)return e.enter("listItemPrefix"),e.enter("listItemValue"),function t(o){return eA(o)&&++l<10?(e.consume(o),t):(!r.interrupt||l<2)&&(r.containerState.marker?o===r.containerState.marker:41===o||46===o)?(e.exit("listItemValue"),a(o)):n(o)}(t)}return n(t)};function a(t){return e.enter("listItemMarker"),e.consume(t),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||t,e.check(eB,r.interrupt?n:s,e.attempt(eX,c,u))}function s(e){return r.containerState.initialBlankLine=!0,i++,c(e)}function u(t){return eR(t)?(e.enter("listItemPrefixWhitespace"),e.consume(t),e.exit("listItemPrefixWhitespace"),c):n(t)}function c(n){return r.containerState.size=i+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(n)}}},eX={partial:!0,tokenize:function(e,t,n){let r=this;return eM(e,function(e){let o=r.events[r.events.length-1];return!eR(e)&&o&&"listItemPrefixWhitespace"===o[1].type?t(e):n(e)},"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5)}},eZ={partial:!0,tokenize:function(e,t,n){let r=this;return eM(e,function(e){let o=r.events[r.events.length-1];return o&&"listItemIndent"===o[1].type&&o[2].sliceSerialize(o[1],!0).length===r.containerState.size?t(e):n(e)},"listItemIndent",r.containerState.size+1)}},eG={continuation:{tokenize:function(e,t,n){let r=this;return function(t){return eR(t)?eM(e,o,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):o(t)};function o(r){return e.attempt(eG,t,n)(r)}}},exit:function(e){e.exit("blockQuote")},name:"blockQuote",tokenize:function(e,t,n){let r=this;return function(t){if(62===t){let n=r.containerState;return n.open||(e.enter("blockQuote",{_container:!0}),n.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(t),e.exit("blockQuoteMarker"),o}return n(t)};function o(n){return eR(n)?(e.enter("blockQuotePrefixWhitespace"),e.consume(n),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(n))}}};function e0(e,t,n,r,o,i,l,a,s){let u=s||1/0,c=0;return function(t){return 60===t?(e.enter(r),e.enter(o),e.enter(i),e.consume(t),e.exit(i),f):null===t||32===t||41===t||eI(t)?n(t):(e.enter(r),e.enter(l),e.enter(a),e.enter("chunkString",{contentType:"string"}),d(t))};function f(n){return 62===n?(e.enter(i),e.consume(n),e.exit(i),e.exit(o),e.exit(r),t):(e.enter(a),e.enter("chunkString",{contentType:"string"}),p(n))}function p(t){return 62===t?(e.exit("chunkString"),e.exit(a),f(t)):null===t||60===t||eC(t)?n(t):(e.consume(t),92===t?h:p)}function h(t){return 60===t||62===t||92===t?(e.consume(t),p):p(t)}function d(o){return!c&&(null===o||41===o||eO(o))?(e.exit("chunkString"),e.exit(a),e.exit(l),e.exit(r),t(o)):c999||null===f||91===f||93===f&&!l||94===f&&!s&&"_hiddenFootnoteSupport"in a.parser.constructs?n(f):93===f?(e.exit(i),e.enter(o),e.consume(f),e.exit(o),e.exit(r),t):eC(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),u):(e.enter("chunkString",{contentType:"string"}),c(f))}function c(t){return null===t||91===t||93===t||eC(t)||s++>999?(e.exit("chunkString"),u(t)):(e.consume(t),l||(l=!eR(t)),92===t?f:c)}function f(t){return 91===t||92===t||93===t?(e.consume(t),s++,c):c(t)}}function e2(e,t,n,r,o,i){let l;return function(t){return 34===t||39===t||40===t?(e.enter(r),e.enter(o),e.consume(t),e.exit(o),l=40===t?41:t,a):n(t)};function a(n){return n===l?(e.enter(o),e.consume(n),e.exit(o),e.exit(r),t):(e.enter(i),s(n))}function s(t){return t===l?(e.exit(i),a(l)):null===t?n(t):eC(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),eM(e,s,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),u(t))}function u(t){return t===l||null===t||eC(t)?(e.exit("chunkString"),s(t)):(e.consume(t),92===t?c:u)}function c(t){return t===l||92===t?(e.consume(t),u):u(t)}}function e5(e,t){let n;return function r(o){return eC(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):eR(o)?eM(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}function e6(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}let e4={partial:!0,tokenize:function(e,t,n){return function(t){return eO(t)?e5(e,r)(t):n(t)};function r(t){return e2(e,o,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(t)}function o(t){return eR(t)?eM(e,i,"whitespace")(t):i(t)}function i(e){return null===e||eC(e)?t(e):n(e)}}},e3={name:"codeIndented",tokenize:function(e,t,n){let r=this;return function(t){return e.enter("codeIndented"),eM(e,o,"linePrefix",5)(t)};function o(t){let o=r.events[r.events.length-1];return o&&"linePrefix"===o[1].type&&o[2].sliceSerialize(o[1],!0).length>=4?function t(n){return null===n?i(n):eC(n)?e.attempt(e8,t,i)(n):(e.enter("codeFlowValue"),function n(r){return null===r||eC(r)?(e.exit("codeFlowValue"),t(r)):(e.consume(r),n)}(n))}(t):n(t)}function i(n){return e.exit("codeIndented"),t(n)}}},e8={partial:!0,tokenize:function(e,t,n){let r=this;return o;function o(t){return r.parser.lazy[r.now().line]?n(t):eC(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),o):eM(e,i,"linePrefix",5)(t)}function i(e){let i=r.events[r.events.length-1];return i&&"linePrefix"===i[1].type&&i[2].sliceSerialize(i[1],!0).length>=4?t(e):eC(e)?o(e):n(e)}}},e9={name:"setextUnderline",resolveTo:function(e,t){let n,r,o,i=e.length;for(;i--;)if("enter"===e[i][0]){if("content"===e[i][1].type){n=i;break}"paragraph"===e[i][1].type&&(r=i)}else"content"===e[i][1].type&&e.splice(i,1),o||"definition"!==e[i][1].type||(o=i);let l={type:"setextHeading",start:{...e[n][1].start},end:{...e[e.length-1][1].end}};return e[r][1].type="setextHeadingText",o?(e.splice(r,0,["enter",l,t]),e.splice(o+1,0,["exit",e[n][1],t]),e[n][1].end={...e[o][1].end}):e[n][1]=l,e.push(["exit",l,t]),e},tokenize:function(e,t,n){let r,o=this;return function(t){var l;let a,s=o.events.length;for(;s--;)if("lineEnding"!==o.events[s][1].type&&"linePrefix"!==o.events[s][1].type&&"content"!==o.events[s][1].type){a="paragraph"===o.events[s][1].type;break}return!o.parser.lazy[o.now().line]&&(o.interrupt||a)?(e.enter("setextHeadingLine"),r=t,l=t,e.enter("setextHeadingLineSequence"),function t(n){return n===r?(e.consume(n),t):(e.exit("setextHeadingLineSequence"),eR(n)?eM(e,i,"lineSuffix")(n):i(n))}(l)):n(t)};function i(r){return null===r||eC(r)?(e.exit("setextHeadingLine"),t(r)):n(r)}}},e7=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],te=["pre","script","style","textarea"],tt={partial:!0,tokenize:function(e,t,n){return function(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),e.attempt(eB,t,n)}}},tn={partial:!0,tokenize:function(e,t,n){let r=this;return function(t){return eC(t)?(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),o):n(t)};function o(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}},tr={partial:!0,tokenize:function(e,t,n){let r=this;return function(t){return null===t?n(t):(e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),o)};function o(e){return r.parser.lazy[r.now().line]?n(e):t(e)}}},to={concrete:!0,name:"codeFenced",tokenize:function(e,t,n){let r,o=this,i={partial:!0,tokenize:function(e,t,n){let i=0;return function(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),l};function l(t){return e.enter("codeFencedFence"),eR(t)?eM(e,s,"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):s(t)}function s(t){return t===r?(e.enter("codeFencedFenceSequence"),function t(o){return o===r?(i++,e.consume(o),t):i>=a?(e.exit("codeFencedFenceSequence"),eR(o)?eM(e,u,"whitespace")(o):u(o)):n(o)}(t)):n(t)}function u(r){return null===r||eC(r)?(e.exit("codeFencedFence"),t(r)):n(r)}}},l=0,a=0;return function(t){var i=t;let u=o.events[o.events.length-1];return l=u&&"linePrefix"===u[1].type?u[2].sliceSerialize(u[1],!0).length:0,r=i,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),function t(o){return o===r?(a++,e.consume(o),t):a<3?n(o):(e.exit("codeFencedFenceSequence"),eR(o)?eM(e,s,"whitespace")(o):s(o))}(i)};function s(i){return null===i||eC(i)?(e.exit("codeFencedFence"),o.interrupt?t(i):e.check(tr,c,d)(i)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),function t(o){return null===o||eC(o)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),s(o)):eR(o)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),eM(e,u,"whitespace")(o)):96===o&&o===r?n(o):(e.consume(o),t)}(i))}function u(t){return null===t||eC(t)?s(t):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),function t(o){return null===o||eC(o)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),s(o)):96===o&&o===r?n(o):(e.consume(o),t)}(t))}function c(t){return e.attempt(i,d,f)(t)}function f(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),p}function p(t){return l>0&&eR(t)?eM(e,h,"linePrefix",l+1)(t):h(t)}function h(t){return null===t||eC(t)?e.check(tr,c,d)(t):(e.enter("codeFlowValue"),function t(n){return null===n||eC(n)?(e.exit("codeFlowValue"),h(n)):(e.consume(n),t)}(t))}function d(n){return e.exit("codeFenced"),t(n)}}},ti=document.createElement("i");function tl(e){let t="&"+e+";";ti.innerHTML=t;let n=ti.textContent;return(59!==n.charCodeAt(n.length-1)||"semi"===e)&&n!==t&&n}let ta={name:"characterReference",tokenize:function(e,t,n){let r,o,i=this,l=0;return function(t){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(t),e.exit("characterReferenceMarker"),a};function a(t){return 35===t?(e.enter("characterReferenceMarkerNumeric"),e.consume(t),e.exit("characterReferenceMarkerNumeric"),s):(e.enter("characterReferenceValue"),r=31,o=eE,u(t))}function s(t){return 88===t||120===t?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(t),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),r=6,o=eT,u):(e.enter("characterReferenceValue"),r=7,o=eA,u(t))}function u(a){if(59===a&&l){let r=e.exit("characterReferenceValue");return o!==eE||tl(i.sliceSerialize(r))?(e.enter("characterReferenceMarker"),e.consume(a),e.exit("characterReferenceMarker"),e.exit("characterReference"),t):n(a)}return o(a)&&l++1&&e[c][1].end.offset-e[c][1].start.offset>1?2:1;let f={...e[n][1].end},p={...e[c][1].start};tv(f,-a),tv(p,a),i={type:a>1?"strongSequence":"emphasisSequence",start:f,end:{...e[n][1].end}},l={type:a>1?"strongSequence":"emphasisSequence",start:{...e[c][1].start},end:p},o={type:a>1?"strongText":"emphasisText",start:{...e[n][1].end},end:{...e[c][1].start}},r={type:a>1?"strong":"emphasis",start:{...i.start},end:{...l.end}},e[n][1].end={...i.start},e[c][1].start={...l.end},s=[],e[n][1].end.offset-e[n][1].start.offset&&(s=ey(s,[["enter",e[n][1],t],["exit",e[n][1],t]])),s=ey(s,[["enter",r,t],["enter",i,t],["exit",i,t],["enter",o,t]]),s=ey(s,tc(t.parser.constructs.insideSpan.null,e.slice(n+1,c),t)),s=ey(s,[["exit",o,t],["enter",l,t],["exit",l,t],["exit",r,t]]),e[c][1].end.offset-e[c][1].start.offset?(u=2,s=ey(s,[["enter",e[c][1],t],["exit",e[c][1],t]])):u=0,em(e,n-1,c-n+3,s),c=n+s.length-u-2;break}}for(c=-1;++ci&&"whitespace"===e[o][1].type&&(o-=2),"atxHeadingSequence"===e[o][1].type&&(i===o-1||o-4>i&&"whitespace"===e[o-2][1].type)&&(o-=i+1===o?2:4),o>i&&(n={type:"atxHeadingText",start:e[i][1].start,end:e[o][1].end},r={type:"chunkText",start:e[i][1].start,end:e[o][1].end,contentType:"text"},em(e,i,o-i+1,[["enter",n,t],["enter",r,t],["exit",r,t],["exit",n,t]])),e},tokenize:function(e,t,n){let r=0;return function(o){var i;return e.enter("atxHeading"),i=o,e.enter("atxHeadingSequence"),function o(i){return 35===i&&r++<6?(e.consume(i),o):null===i||eO(i)?(e.exit("atxHeadingSequence"),function n(r){return 35===r?(e.enter("atxHeadingSequence"),function t(r){return 35===r?(e.consume(r),t):(e.exit("atxHeadingSequence"),n(r))}(r)):null===r||eC(r)?(e.exit("atxHeading"),t(r)):eR(r)?eM(e,n,"whitespace")(r):(e.enter("atxHeadingText"),function t(r){return null===r||35===r||eO(r)?(e.exit("atxHeadingText"),n(r)):(e.consume(r),t)}(r))}(i)):n(i)}(i)}}},42:eK,45:[e9,eK],60:{concrete:!0,name:"htmlFlow",resolveTo:function(e){let t=e.length;for(;t--&&("enter"!==e[t][0]||"htmlFlow"!==e[t][1].type););return t>1&&"linePrefix"===e[t-2][1].type&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e},tokenize:function(e,t,n){let r,o,i,l,a,s=this;return function(t){var n;return n=t,e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(n),u};function u(l){return 33===l?(e.consume(l),c):47===l?(e.consume(l),o=!0,h):63===l?(e.consume(l),r=3,s.interrupt?t:P):ew(l)?(e.consume(l),i=String.fromCharCode(l),d):n(l)}function c(o){return 45===o?(e.consume(o),r=2,f):91===o?(e.consume(o),r=5,l=0,p):ew(o)?(e.consume(o),r=4,s.interrupt?t:P):n(o)}function f(r){return 45===r?(e.consume(r),s.interrupt?t:P):n(r)}function p(r){let o="CDATA[";return r===o.charCodeAt(l++)?(e.consume(r),l===o.length)?s.interrupt?t:S:p:n(r)}function h(t){return ew(t)?(e.consume(t),i=String.fromCharCode(t),d):n(t)}function d(l){if(null===l||47===l||62===l||eO(l)){let a=47===l,u=i.toLowerCase();return!a&&!o&&te.includes(u)?(r=1,s.interrupt?t(l):S(l)):e7.includes(i.toLowerCase())?(r=6,a)?(e.consume(l),g):s.interrupt?t(l):S(l):(r=7,s.interrupt&&!s.parser.lazy[s.now().line]?n(l):o?function t(n){return eR(n)?(e.consume(n),t):w(n)}(l):m(l))}return 45===l||eE(l)?(e.consume(l),i+=String.fromCharCode(l),d):n(l)}function g(r){return 62===r?(e.consume(r),s.interrupt?t:S):n(r)}function m(t){return 47===t?(e.consume(t),w):58===t||95===t||ew(t)?(e.consume(t),y):eR(t)?(e.consume(t),m):w(t)}function y(t){return 45===t||46===t||58===t||95===t||eE(t)?(e.consume(t),y):v(t)}function v(t){return 61===t?(e.consume(t),b):eR(t)?(e.consume(t),v):m(t)}function b(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),a=t,x):eR(t)?(e.consume(t),b):function t(n){return null===n||34===n||39===n||47===n||60===n||61===n||62===n||96===n||eO(n)?v(n):(e.consume(n),t)}(t)}function x(t){return t===a?(e.consume(t),a=null,k):null===t||eC(t)?n(t):(e.consume(t),x)}function k(e){return 47===e||62===e||eR(e)?m(e):n(e)}function w(t){return 62===t?(e.consume(t),E):n(t)}function E(t){return null===t||eC(t)?S(t):eR(t)?(e.consume(t),E):n(t)}function S(t){return 45===t&&2===r?(e.consume(t),_):60===t&&1===r?(e.consume(t),C):62===t&&4===r?(e.consume(t),L):63===t&&3===r?(e.consume(t),P):93===t&&5===r?(e.consume(t),R):eC(t)&&(6===r||7===r)?(e.exit("htmlFlowData"),e.check(tt,D,I)(t)):null===t||eC(t)?(e.exit("htmlFlowData"),I(t)):(e.consume(t),S)}function I(t){return e.check(tn,A,D)(t)}function A(t){return e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),T}function T(t){return null===t||eC(t)?I(t):(e.enter("htmlFlowData"),S(t))}function _(t){return 45===t?(e.consume(t),P):S(t)}function C(t){return 47===t?(e.consume(t),i="",O):S(t)}function O(t){if(62===t){let n=i.toLowerCase();return te.includes(n)?(e.consume(t),L):S(t)}return ew(t)&&i.length<8?(e.consume(t),i+=String.fromCharCode(t),O):S(t)}function R(t){return 93===t?(e.consume(t),P):S(t)}function P(t){return 62===t?(e.consume(t),L):45===t&&2===r?(e.consume(t),P):S(t)}function L(t){return null===t||eC(t)?(e.exit("htmlFlowData"),D(t)):(e.consume(t),L)}function D(n){return e.exit("htmlFlow"),t(n)}}},61:e9,95:eK,96:to,126:to},tS={38:ta,92:ts},tI={[-5]:tu,[-4]:tu,[-3]:tu,33:tg,38:ta,42:ty,60:[{name:"autolink",tokenize:function(e,t,n){let r=0;return function(t){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(t),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),o};function o(t){return ew(t)?(e.consume(t),i):64===t?n(t):a(t)}function i(t){return 43===t||45===t||46===t||eE(t)?(r=1,function t(n){return 58===n?(e.consume(n),r=0,l):(43===n||45===n||46===n||eE(n))&&r++<32?(e.consume(n),t):(r=0,a(n))}(t)):a(t)}function l(r){return 62===r?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(r),e.exit("autolinkMarker"),e.exit("autolink"),t):null===r||32===r||60===r||eI(r)?n(r):(e.consume(r),l)}function a(t){return 64===t?(e.consume(t),s):eS(t)?(e.consume(t),a):n(t)}function s(o){return eE(o)?function o(i){return 46===i?(e.consume(i),r=0,s):62===i?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(i),e.exit("autolinkMarker"),e.exit("autolink"),t):function t(i){if((45===i||eE(i))&&r++<63){let n=45===i?t:o;return e.consume(i),n}return n(i)}(i)}(o):n(o)}}},{name:"htmlText",tokenize:function(e,t,n){let r,o,i,l=this;return function(t){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(t),a};function a(t){return 33===t?(e.consume(t),s):47===t?(e.consume(t),x):63===t?(e.consume(t),v):ew(t)?(e.consume(t),w):n(t)}function s(t){return 45===t?(e.consume(t),u):91===t?(e.consume(t),o=0,h):ew(t)?(e.consume(t),y):n(t)}function u(t){return 45===t?(e.consume(t),p):n(t)}function c(t){return null===t?n(t):45===t?(e.consume(t),f):eC(t)?(i=c,O(t)):(e.consume(t),c)}function f(t){return 45===t?(e.consume(t),p):c(t)}function p(e){return 62===e?C(e):45===e?f(e):c(e)}function h(t){let r="CDATA[";return t===r.charCodeAt(o++)?(e.consume(t),o===r.length?d:h):n(t)}function d(t){return null===t?n(t):93===t?(e.consume(t),g):eC(t)?(i=d,O(t)):(e.consume(t),d)}function g(t){return 93===t?(e.consume(t),m):d(t)}function m(t){return 62===t?C(t):93===t?(e.consume(t),m):d(t)}function y(t){return null===t||62===t?C(t):eC(t)?(i=y,O(t)):(e.consume(t),y)}function v(t){return null===t?n(t):63===t?(e.consume(t),b):eC(t)?(i=v,O(t)):(e.consume(t),v)}function b(e){return 62===e?C(e):v(e)}function x(t){return ew(t)?(e.consume(t),k):n(t)}function k(t){return 45===t||eE(t)?(e.consume(t),k):function t(n){return eC(n)?(i=t,O(n)):eR(n)?(e.consume(n),t):C(n)}(t)}function w(t){return 45===t||eE(t)?(e.consume(t),w):47===t||62===t||eO(t)?E(t):n(t)}function E(t){return 47===t?(e.consume(t),C):58===t||95===t||ew(t)?(e.consume(t),S):eC(t)?(i=E,O(t)):eR(t)?(e.consume(t),E):C(t)}function S(t){return 45===t||46===t||58===t||95===t||eE(t)?(e.consume(t),S):function t(n){return 61===n?(e.consume(n),I):eC(n)?(i=t,O(n)):eR(n)?(e.consume(n),t):E(n)}(t)}function I(t){return null===t||60===t||61===t||62===t||96===t?n(t):34===t||39===t?(e.consume(t),r=t,A):eC(t)?(i=I,O(t)):eR(t)?(e.consume(t),I):(e.consume(t),T)}function A(t){return t===r?(e.consume(t),r=void 0,_):null===t?n(t):eC(t)?(i=A,O(t)):(e.consume(t),A)}function T(t){return null===t||34===t||39===t||60===t||61===t||96===t?n(t):47===t||62===t||eO(t)?E(t):(e.consume(t),T)}function _(e){return 47===e||62===e||eO(e)?E(e):n(e)}function C(r){return 62===r?(e.consume(r),e.exit("htmlTextData"),e.exit("htmlText"),t):n(r)}function O(t){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(t),e.exit("lineEnding"),R}function R(t){return eR(t)?eM(e,P,"linePrefix",l.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(t):P(t)}function P(t){return e.enter("htmlTextData"),i(t)}}}],91:tb,92:[{name:"hardBreakEscape",tokenize:function(e,t,n){return function(t){return e.enter("hardBreakEscape"),e.consume(t),r};function r(r){return eC(r)?(e.exit("hardBreakEscape"),t(r)):n(r)}}},ts],93:tf,95:ty,96:{name:"codeText",previous:function(e){return 96!==e||"characterEscape"===this.events[this.events.length-1][1].type},resolve:function(e){let t,n,r=e.length-4,o=3;if(("lineEnding"===e[3][1].type||"space"===e[o][1].type)&&("lineEnding"===e[r][1].type||"space"===e[r][1].type)){for(t=o;++t13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(65535&n)==65535||(65535&n)==65534||n>1114111?"�":String.fromCodePoint(n)}let tR=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function tP(e,t,n){if(t)return t;if(35===n.charCodeAt(0)){let e=n.charCodeAt(1),t=120===e||88===e;return tO(n.slice(t?2:1),t?16:10)}return tl(n)||e}let tL={}.hasOwnProperty;function tD(e){return{line:e.line,column:e.column,offset:e.offset}}function tM(e,t){if(e)throw Error("Cannot close `"+e.type+"` ("+Y({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Y({start:t.start,end:t.end})+") is open");throw Error("Cannot close document, a token (`"+t.type+"`, "+Y({start:t.start,end:t.end})+") is still open")}function tN(e){let t=this;t.parser=function(n){var r,i;let l,a,s,u;return"string"!=typeof(r={...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})&&(i=r,r=void 0),(function(e){let t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:r(y),autolinkProtocol:u,autolinkEmail:u,atxHeading:r(d),blockQuote:r(function(){return{type:"blockquote",children:[]}}),characterEscape:u,characterReference:u,codeFenced:r(h),codeFencedFenceInfo:o,codeFencedFenceMeta:o,codeIndented:r(h,o),codeText:r(function(){return{type:"inlineCode",value:""}},o),codeTextData:u,data:u,codeFlowValue:u,definition:r(function(){return{type:"definition",identifier:"",label:null,title:null,url:""}}),definitionDestinationString:o,definitionLabelString:o,definitionTitleString:o,emphasis:r(function(){return{type:"emphasis",children:[]}}),hardBreakEscape:r(g),hardBreakTrailing:r(g),htmlFlow:r(m,o),htmlFlowData:u,htmlText:r(m,o),htmlTextData:u,image:r(function(){return{type:"image",title:null,url:"",alt:null}}),label:o,link:r(y),listItem:r(function(e){return{type:"listItem",spread:e._spread,checked:null,children:[]}}),listItemValue:function(e){this.data.expectingFirstListItemValue&&(this.stack[this.stack.length-2].start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0)},listOrdered:r(v,function(){this.data.expectingFirstListItemValue=!0}),listUnordered:r(v),paragraph:r(function(){return{type:"paragraph",children:[]}}),reference:function(){this.data.referenceType="collapsed"},referenceString:o,resourceDestinationString:o,resourceTitleString:o,setextHeading:r(d),strong:r(function(){return{type:"strong",children:[]}}),thematicBreak:r(function(){return{type:"thematicBreak"}})},exit:{atxHeading:l(),atxHeadingSequence:function(e){let t=this.stack[this.stack.length-1];t.depth||(t.depth=this.sliceSerialize(e).length)},autolink:l(),autolinkEmail:function(e){c.call(this,e),this.stack[this.stack.length-1].url="mailto:"+this.sliceSerialize(e)},autolinkProtocol:function(e){c.call(this,e),this.stack[this.stack.length-1].url=this.sliceSerialize(e)},blockQuote:l(),characterEscapeValue:c,characterReferenceMarkerHexadecimal:p,characterReferenceMarkerNumeric:p,characterReferenceValue:function(e){let t,n=this.sliceSerialize(e),r=this.data.characterReferenceType;r?(t=tO(n,"characterReferenceMarkerNumeric"===r?10:16),this.data.characterReferenceType=void 0):t=tl(n);let o=this.stack[this.stack.length-1];o.value+=t},characterReference:function(e){this.stack.pop().position.end=tD(e.end)},codeFenced:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}),codeFencedFence:function(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)},codeFencedFenceInfo:function(){let e=this.resume();this.stack[this.stack.length-1].lang=e},codeFencedFenceMeta:function(){let e=this.resume();this.stack[this.stack.length-1].meta=e},codeFlowValue:c,codeIndented:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e.replace(/(\r?\n|\r)$/g,"")}),codeText:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e}),codeTextData:c,data:c,definition:l(),definitionDestinationString:function(){let e=this.resume();this.stack[this.stack.length-1].url=e},definitionLabelString:function(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=e6(this.sliceSerialize(e)).toLowerCase()},definitionTitleString:function(){let e=this.resume();this.stack[this.stack.length-1].title=e},emphasis:l(),hardBreakEscape:l(f),hardBreakTrailing:l(f),htmlFlow:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e}),htmlFlowData:c,htmlText:l(function(){let e=this.resume();this.stack[this.stack.length-1].value=e}),htmlTextData:c,image:l(function(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}),label:function(){let e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];this.data.inReference=!0,"link"===n.type?n.children=e.children:n.alt=t},labelText:function(e){let t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=t.replace(tR,tP),n.identifier=e6(t).toLowerCase()},lineEnding:function(e){let n=this.stack[this.stack.length-1];if(this.data.atHardBreak){n.children[n.children.length-1].position.end=tD(e.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.type)&&(u.call(this,e),c.call(this,e))},link:l(function(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}),listItem:l(),listOrdered:l(),listUnordered:l(),paragraph:l(),referenceString:function(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=e6(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType="full"},resourceDestinationString:function(){let e=this.resume();this.stack[this.stack.length-1].url=e},resourceTitleString:function(){let e=this.resume();this.stack[this.stack.length-1].title=e},resource:function(){this.data.inReference=void 0},setextHeading:l(function(){this.data.setextHeadingSlurpLineEnding=void 0}),setextHeadingLineSequence:function(e){this.stack[this.stack.length-1].depth=61===this.sliceSerialize(e).codePointAt(0)?1:2},setextHeadingText:function(){this.data.setextHeadingSlurpLineEnding=!0},strong:l(),thematicBreak:l()}};!function e(t,n){let r=-1;for(;++r0){let e=l.tokenStack[l.tokenStack.length-1];(e[1]||tM).call(l,void 0,e[0])}for(r.position={start:tD(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:tD(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},c=-1;++c-1){let e=n[0];"string"==typeof e?n[0]=e.slice(o):n.shift()}l>0&&n.push(e[i].slice(0,l))}return n}(l,e)}function p(){let{_bufferIndex:e,_index:t,line:n,column:o,offset:i}=r;return{_bufferIndex:e,_index:t,line:n,column:o,offset:i}}function h(e,t){t.restore()}function d(e,t){return function(n,o,i){var l;let c,f,h,d;return Array.isArray(n)?g(n):"tokenize"in n?g([n]):(l=n,function(e){let t=null!==e&&l[e],n=null!==e&&l.null;return g([...Array.isArray(t)?t:t?[t]:[],...Array.isArray(n)?n:n?[n]:[]])(e)});function g(e){return(c=e,f=0,0===e.length)?i:y(e[f])}function y(e){return function(n){return(d=function(){let e=p(),t=u.previous,n=u.currentConstruct,o=u.events.length,i=Array.from(a);return{from:o,restore:function(){r=e,u.previous=t,u.currentConstruct=n,u.events.length=o,a=i,m()}}}(),h=e,e.partial||(u.currentConstruct=e),e.name&&u.parser.constructs.disable.null.includes(e.name))?b(n):e.tokenize.call(t?Object.assign(Object.create(u),t):u,s,v,b)(n)}}function v(t){return e(h,d),o}function b(e){return(d.restore(),++f((e,t)=>{let n=(t,n)=>(e.set(n,t),t),r=o=>{if(e.has(o))return e.get(o);let[i,l]=t[o];switch(i){case 0:case -1:return n(l,o);case 1:{let e=n([],o);for(let t of l)e.push(r(t));return e}case 2:{let e=n({},o);for(let[t,n]of l)e[r(t)]=r(n);return e}case 3:return n(new Date(l),o);case 4:{let{source:e,flags:t}=l;return n(new RegExp(e,t),o)}case 5:{let e=n(new Map,o);for(let[t,n]of l)e.set(r(t),r(n));return e}case 6:{let e=n(new Set,o);for(let t of l)e.add(r(t));return e}case 7:{let{name:e,message:t}=l;return n(new tj[e](t),o)}case 8:return n(BigInt(l),o);case"BigInt":return n(Object(BigInt(l)),o);case"ArrayBuffer":return n(new Uint8Array(l).buffer,l);case"DataView":{let{buffer:e}=new Uint8Array(l);return n(new DataView(e),l)}}return n(new tj[i](l),o)};return r})(new Map,e)(0),{toString:tB}={},{keys:tz}=Object,tU=e=>{let t=typeof e;if("object"!==t||!e)return[0,t];let n=tB.call(e).slice(8,-1);switch(n){case"Array":return[1,""];case"Object":return[2,""];case"Date":return[3,""];case"RegExp":return[4,""];case"Map":return[5,""];case"Set":return[6,""];case"DataView":return[1,n]}return n.includes("Array")?[1,n]:n.includes("Error")?[7,n]:[2,n]},tV=([e,t])=>0===e&&("function"===t||"symbol"===t),tH=(e,{json:t,lossy:n}={})=>{let r=[];return((e,t,n,r)=>{let o=(e,t)=>{let o=r.push(e)-1;return n.set(t,o),o},i=r=>{if(n.has(r))return n.get(r);let[l,a]=tU(r);switch(l){case 0:{let t=r;switch(a){case"bigint":l=8,t=r.toString();break;case"function":case"symbol":if(e)throw TypeError("unable to serialize "+a);t=null;break;case"undefined":return o([-1],r)}return o([l,t],r)}case 1:{if(a){let e=r;return"DataView"===a?e=new Uint8Array(r.buffer):"ArrayBuffer"===a&&(e=new Uint8Array(r)),o([a,[...e]],r)}let e=[],t=o([l,e],r);for(let t of r)e.push(i(t));return t}case 2:{if(a)switch(a){case"BigInt":return o([a,r.toString()],r);case"Boolean":case"Number":case"String":return o([a,r.valueOf()],r)}if(t&&"toJSON"in r)return i(r.toJSON());let n=[],s=o([l,n],r);for(let t of tz(r))(e||!tV(tU(r[t])))&&n.push([i(t),i(r[t])]);return s}case 3:return o([l,r.toISOString()],r);case 4:{let{source:e,flags:t}=r;return o([l,{source:e,flags:t}],r)}case 5:{let t=[],n=o([l,t],r);for(let[n,o]of r)(e||!(tV(tU(n))||tV(tU(o))))&&t.push([i(n),i(o)]);return n}case 6:{let t=[],n=o([l,t],r);for(let n of r)(e||!tV(tU(n)))&&t.push(i(n));return n}}let{message:s}=r;return o([l,{name:a,message:s}],r)};return i})(!(t||n),!!t,new Map,r)(e),r},tq="function"==typeof structuredClone?(e,t)=>t&&("json"in t||"lossy"in t)?tF(tH(e,t)):structuredClone(e):(e,t)=>tF(tH(e,t));function tJ(e){let t=[],n=-1,r=0,o=0;for(;++n55295&&i<57344){let t=e.charCodeAt(n+1);i<56320&&t>56319&&t<57344?(l=String.fromCharCode(i,t),o=1):l="�"}else l=String.fromCharCode(i);l&&(t.push(e.slice(r,n),encodeURIComponent(l)),r=n+o+1,l=""),o&&(n+=o,o=0)}return t.join("")+e.slice(r)}function tW(e,t){let n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function tY(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}let t$=function(e){var t,n;if(null==e)return tQ;if("function"==typeof e)return tK(e);if("object"==typeof e){return Array.isArray(e)?function(e){let t=[],n=-1;for(;++n":"")+")"})}return i;function i(){var o;let i,l,a,h=tX;if((!s||f(t,n,r[r.length-1]||void 0))&&!1===(h=Array.isArray(o=u(t,r))?o:"number"==typeof o?[!0,o]:null==o?tX:[o])[0])return h;if("children"in t&&t.children&&t.children&&"skip"!==h[0])for(l=(c?t.children.length:-1)+p,a=r.concat(t);l>-1&&l1:t}function t1(e,t,n){let r=0,o=e.length;if(t){let t=e.codePointAt(r);for(;9===t||32===t;)r++,t=e.codePointAt(r)}if(n){let t=e.codePointAt(o-1);for(;9===t||32===t;)o--,t=e.codePointAt(o-1)}return o>r?e.slice(r,o):""}let t2={blockquote:function(e,t){let n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)},break:function(e,t){let n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:"\n"}]},code:function(e,t){let n=t.value?t.value+"\n":"",r={};t.lang&&(r.className=["language-"+t.lang]);let o={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(o.data={meta:t.meta}),e.patch(t,o),o={type:"element",tagName:"pre",properties:{},children:[o=e.applyData(t,o)]},e.patch(t,o),o},delete:function(e,t){let n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},emphasis:function(e,t){let n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},footnoteReference:function(e,t){let n,r="string"==typeof e.options.clobberPrefix?e.options.clobberPrefix:"user-content-",o=String(t.identifier).toUpperCase(),i=tJ(o.toLowerCase()),l=e.footnoteOrder.indexOf(o),a=e.footnoteCounts.get(o);void 0===a?(a=0,e.footnoteOrder.push(o),n=e.footnoteOrder.length):n=l+1,a+=1,e.footnoteCounts.set(o,a);let s={type:"element",tagName:"a",properties:{href:"#"+r+"fn-"+i,id:r+"fnref-"+i+(a>1?"-"+a:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(n)}]};e.patch(t,s);let u={type:"element",tagName:"sup",properties:{},children:[s]};return e.patch(t,u),e.applyData(t,u)},heading:function(e,t){let n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},html:function(e,t){if(e.options.allowDangerousHtml){let n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}},imageReference:function(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return tG(e,t);let o={src:tJ(r.url||""),alt:t.alt};null!==r.title&&void 0!==r.title&&(o.title=r.title);let i={type:"element",tagName:"img",properties:o,children:[]};return e.patch(t,i),e.applyData(t,i)},image:function(e,t){let n={src:tJ(t.url)};null!==t.alt&&void 0!==t.alt&&(n.alt=t.alt),null!==t.title&&void 0!==t.title&&(n.title=t.title);let r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)},inlineCode:function(e,t){let n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);let r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)},linkReference:function(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return tG(e,t);let o={href:tJ(r.url||"")};null!==r.title&&void 0!==r.title&&(o.title=r.title);let i={type:"element",tagName:"a",properties:o,children:e.all(t)};return e.patch(t,i),e.applyData(t,i)},link:function(e,t){let n={href:tJ(t.url)};null!==t.title&&void 0!==t.title&&(n.title=t.title);let r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)},listItem:function(e,t,n){let r=e.all(t),o=n?function(e){let t=!1;if("list"===e.type){t=e.spread||!1;let n=e.children,r=-1;for(;!t&&++r0&&e.children.unshift({type:"text",value:" "}),e.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),i.className=["task-list-item"]}let a=-1;for(;++a0){let r={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},i=J(t.children[1]),l=q(t.children[t.children.length-1]);i&&l&&(r.position={start:i,end:l}),o.push(r)}let i={type:"element",tagName:"table",properties:{},children:e.wrap(o,!0)};return e.patch(t,i),e.applyData(t,i)},tableCell:function(e,t){let n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)},tableRow:function(e,t,n){let r=n?n.children:void 0,o=0===(r?r.indexOf(t):1)?"th":"td",i=n&&"table"===n.type?n.align:void 0,l=i?i.length:t.children.length,a=-1,s=[];for(;++a0,!0),r[0]),o=r.index+r[0].length,r=n.exec(t);return i.push(t1(t.slice(o),o>0,!1)),i.join("")}(String(t.value))};return e.patch(t,n),e.applyData(t,n)},thematicBreak:function(e,t){let n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)},toml:t5,yaml:t5,definition:t5,footnoteDefinition:t5};function t5(){}let t6={}.hasOwnProperty,t4={};function t3(e,t){e.position&&(t.position=function(e){let t=J(e),n=q(e);if(t&&n)return{start:t,end:n}}(e))}function t8(e,t){let n=t;if(e&&e.data){let t=e.data.hName,r=e.data.hChildren,o=e.data.hProperties;"string"==typeof t&&("element"===n.type?n.tagName=t:n={type:"element",tagName:t,properties:{},children:"children"in n?n.children:[n]}),"element"===n.type&&o&&Object.assign(n.properties,tq(o)),"children"in n&&n.children&&null!=r&&(n.children=r)}return n}function t9(e,t){let n=[],r=-1;for(t&&n.push({type:"text",value:"\n"});++r0&&n.push({type:"text",value:"\n"}),n}function t7(e){let t=0,n=e.charCodeAt(t);for(;9===n||32===n;)t++,n=e.charCodeAt(t);return e.slice(t)}function ne(e,t){let n=function(e,t){let n=t||t4,r=new Map,o=new Map,i={all:function(e){let t=[];if("children"in e){let n=e.children,r=-1;for(;++r0&&f.push({type:"text",value:" "});let e="string"==typeof n?n:n(s,c);"string"==typeof e&&(e={type:"text",value:e}),f.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+u+(c>1?"-"+c:""),dataFootnoteBackref:"",ariaLabel:"string"==typeof r?r:r(s,c),className:["data-footnote-backref"]},children:Array.isArray(e)?e:[e]})}let h=i[i.length-1];if(h&&"element"===h.type&&"p"===h.tagName){let e=h.children[h.children.length-1];e&&"text"===e.type?e.value+=" ":h.children.push({type:"text",value:" "}),h.children.push(...f)}else i.push(...f);let d={type:"element",tagName:"li",properties:{id:t+"fn-"+u},children:e.wrap(i,!0)};e.patch(o,d),a.push(d)}if(0!==a.length)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:i,properties:{...tq(l),id:"footnote-label"},children:[{type:"text",value:o}]},{type:"text",value:"\n"},{type:"element",tagName:"ol",properties:{},children:e.wrap(a,!0)},{type:"text",value:"\n"}]}}(n),i=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return o&&i.children.push({type:"text",value:"\n"},o),i}function nt(e,t){return e&&"run"in e?async function(n,r){let o=ne(n,{file:r,...t});await e.run(o,r)}:function(n,r){return ne(n,{file:r,...e||t})}}function nn(e){if(e)throw e}var nr=n(53360);function no(e){if("object"!=typeof e||null===e)return!1;let t=Object.getPrototypeOf(e);return(null===t||t===Object.prototype||null===Object.getPrototypeOf(t))&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}let ni={basename:function(e,t){let n;if(void 0!==t&&"string"!=typeof t)throw TypeError('"ext" argument must be a string');nl(e);let r=0,o=-1,i=e.length;if(void 0===t||0===t.length||t.length>e.length){for(;i--;)if(47===e.codePointAt(i)){if(n){r=i+1;break}}else o<0&&(n=!0,o=i+1);return o<0?"":e.slice(r,o)}if(t===e)return"";let l=-1,a=t.length-1;for(;i--;)if(47===e.codePointAt(i)){if(n){r=i+1;break}}else l<0&&(n=!0,l=i+1),a>-1&&(e.codePointAt(i)===t.codePointAt(a--)?a<0&&(o=i):(a=-1,o=l));return r===o?o=l:o<0&&(o=e.length),e.slice(r,o)},dirname:function(e){let t;if(nl(e),0===e.length)return".";let n=-1,r=e.length;for(;--r;)if(47===e.codePointAt(r)){if(t){n=r;break}}else t||(t=!0);return n<0?47===e.codePointAt(0)?"/":".":1===n&&47===e.codePointAt(0)?"//":e.slice(0,n)},extname:function(e){let t;nl(e);let n=e.length,r=-1,o=0,i=-1,l=0;for(;n--;){let a=e.codePointAt(n);if(47===a){if(t){o=n+1;break}continue}r<0&&(t=!0,r=n+1),46===a?i<0?i=n:1!==l&&(l=1):i>-1&&(l=-1)}return i<0||r<0||0===l||1===l&&i===r-1&&i===o+1?"":e.slice(i,r)},join:function(...e){let t,n=-1;for(;++n2){if((r=o.lastIndexOf("/"))!==o.length-1){r<0?(o="",i=0):i=(o=o.slice(0,r)).length-1-o.lastIndexOf("/"),l=s,a=0;continue}}else if(o.length>0){o="",i=0,l=s,a=0;continue}}t&&(o=o.length>0?o+"/..":"..",i=2)}else o.length>0?o+="/"+e.slice(l+1,s):o=e.slice(l+1,s),i=s-l-1;l=s,a=0}else 46===n&&a>-1?a++:a=-1}return o}(e,!t);return 0!==n.length||t||(n="."),n.length>0&&47===e.codePointAt(e.length-1)&&(n+="/"),t?"/"+n:n}(t)},sep:"/"};function nl(e){if("string"!=typeof e)throw TypeError("Path must be a string. Received "+JSON.stringify(e))}let na={cwd:function(){return"/"}};function ns(e){return!!(null!==e&&"object"==typeof e&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&void 0===e.auth)}let nu=["history","path","basename","stem","extname","dirname"];class nc{constructor(e){let t,n;t=e?ns(e)?{path:e}:"string"==typeof e||function(e){return!!(e&&"object"==typeof e&&"byteLength"in e&&"byteOffset"in e)}(e)?{value:e}:e:{},this.cwd="cwd"in t?"":na.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++rt.length;l&&t.push(r);try{i=e.apply(this,t)}catch(e){if(l&&n)throw e;return r(e)}l||(i&&i.then&&"function"==typeof i.then?i.then(o,r):i instanceof Error?r(i):o(i))};function r(e,...o){n||(n=!0,t(e,...o))}function o(e){r(null,e)}})(a,o)(...l):r(null,...l)}(null,...t)},use:function(n){if("function"!=typeof n)throw TypeError("Expected `middelware` to be a function, not "+n);return e.push(n),t}};return t}()}copy(){let e=new nm,t=-1;for(;++t0){let[r,...i]=t,l=n[o][1];no(l)&&no(r)&&(r=nr(!0,l,r)),n[o]=[e,r,...i]}}}}let ny=new nm().freeze();function nv(e,t){if("function"!=typeof t)throw TypeError("Cannot `"+e+"` without `parser`")}function nb(e,t){if("function"!=typeof t)throw TypeError("Cannot `"+e+"` without `compiler`")}function nx(e,t){if(t)throw Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function nk(e){if(!no(e)||"string"!=typeof e.type)throw TypeError("Expected node, got `"+e+"`")}function nw(e,t,n){if(!n)throw Error("`"+e+"` finished async. Use `"+t+"` instead")}function nE(e){var t;return(t=e)&&"object"==typeof t&&"message"in t&&"messages"in t?e:new nc(e)}let nS=[],nI={allowDangerousHtml:!0},nA=/^(https?|ircs?|mailto|xmpp)$/i,nT=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function n_(e){let t=function(e){let t=e.rehypePlugins||nS,n=e.remarkPlugins||nS,r=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...nI}:nI;return ny().use(tN).use(n).use(nt,r).use(t)}(e),n=function(e){let t=e.children||"",n=new nc;return"string"==typeof t&&(n.value=t),n}(e);return function(e,t){let n=t.allowedElements,r=t.allowElement,o=t.components,i=t.disallowedElements,l=t.skipHtml,a=t.unwrapDisallowed,s=t.urlTransform||nC;for(let e of nT)Object.hasOwn(t,e.from)&&(e.from,e.to&&e.to,e.id);return tZ(e,function(e,t,o){if("raw"===e.type&&o&&"number"==typeof t)return l?o.children.splice(t,1):o.children[t]={type:"text",value:e.value},t;if("element"===e.type){let t;for(t in ef)if(Object.hasOwn(ef,t)&&Object.hasOwn(e.properties,t)){let n=e.properties[t],r=ef[t];(null===r||r.includes(e.tagName))&&(e.properties[t]=s(String(n||""),t,e))}}if("element"===e.type){let l=n?!n.includes(e.tagName):!!i&&i.includes(e.tagName);if(!l&&r&&"number"==typeof t&&(l=!r(e,t,o)),l&&o&&"number"==typeof t)return a&&e.children?o.children.splice(t,1,...e.children):o.children.splice(t,1),t}}),function(e,t){var n,r,o,i;let l;if(!t||void 0===t.Fragment)throw TypeError("Expected `Fragment` in options");let a=t.filePath||void 0;if(t.development){if("function"!=typeof t.jsxDEV)throw TypeError("Expected `jsxDEV` in options when `development: true`");n=a,r=t.jsxDEV,l=function(e,t,o,i){let l=Array.isArray(o.children),a=J(e);return r(t,o,i,l,{columnNumber:a?a.column-1:void 0,fileName:n,lineNumber:a?a.line:void 0},void 0)}}else{if("function"!=typeof t.jsx)throw TypeError("Expected `jsx` in production options");if("function"!=typeof t.jsxs)throw TypeError("Expected `jsxs` in production options");o=t.jsx,i=t.jsxs,l=function(e,t,n,r){let l=Array.isArray(n.children)?i:o;return r?l(t,n,r):l(t,n)}}let s={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:l,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:a,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:!1!==t.passKeys,passNode:t.passNode||!1,schema:"svg"===t.space?N:M,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:!1!==t.tableCellAlignToStyle},u=eo(s,e,void 0);return u&&"string"!=typeof u?u:s.create(e,s.Fragment,{children:u||void 0},void 0)}(e,{Fragment:ep.Fragment,components:o,ignoreInvalidStyle:!0,jsx:ep.jsx,jsxs:ep.jsxs,passKeys:!0,passNode:!0})}(t.runSync(t.parse(n),n),e)}function nC(e){let t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),o=e.indexOf("/");return -1===t||-1!==o&&t>o||-1!==n&&t>n||-1!==r&&t>r||nA.test(e.slice(0,t))?e:""}}}]);
//# sourceMappingURL=4693-3bebdafac8528e2d.js.map