diff --git a/dist/cmlconsent.html b/dist/cmlconsent.html
index 68f766c..59347cd 100644
--- a/dist/cmlconsent.html
+++ b/dist/cmlconsent.html
@@ -249,22 +249,25 @@
This project is still working in progress so that some improvements and changes mighe be taken in place in the future.
- You are very welcome to comment or contribute to the project.
+ You are very welcome to comment or contribute to the project by email Chang Sun (chang.sun@maastrichtuniversity.nl).
diff --git a/dist/cmlparticipate.html b/dist/cmlparticipate.html
index d54d18d..5c9ef17 100644
--- a/dist/cmlparticipate.html
+++ b/dist/cmlparticipate.html
@@ -210,7 +210,7 @@
Home
Contribute to studies
- Ask for Consent [Researcher portal]
+
diff --git a/dist/main.js b/dist/main.js
index 6a3e820..b971ac1 100644
--- a/dist/main.js
+++ b/dist/main.js
@@ -1,2 +1,2 @@
/*! For license information please see main.js.LICENSE.txt */
-(()=>{var e={825:(e,t,r)=>{const n=r(295);e.exports=n},225:e=>{class t{constructor(e){this.value=e||"b"+ ++t.nextId}equals(e){return!!e&&e.termType===this.termType&&e.value===this.value}}t.prototype.termType="BlankNode",t.nextId=0,e.exports=t},295:(e,t,r)=>{const n=r(225),o=r(805),i=r(542),a=r(694),s=r(358),c=r(790),h=r(895),u={namedNode:function(e){return new s(e)},blankNode:function(e){return new n(e)},literal:function(e,t){return"string"==typeof t?-1===t.indexOf(":")?new a(e,t):new a(e,null,u.namedNode(t)):new a(e,null,t)},variable:function(e){return new h(e)},defaultGraph:function(){return u.defaultGraphInstance},triple:function(e,t,r){return u.quad(e,t,r)},quad:function(e,t,r,n){return new c(e,t,r,n||u.defaultGraphInstance)},fromTerm:function(e){return i.call(u,e)},fromQuad:function(e){return i.call(u,e)},defaultGraphInstance:new o};e.exports=u},805:e=>{class t{equals(e){return!!e&&e.termType===this.termType}}t.prototype.termType="DefaultGraph",t.prototype.value="",e.exports=t},694:(e,t,r)=>{const n=r(358);class o{constructor(e,t,r){this.value=e,this.datatype=o.stringDatatype,this.language="",t?(this.language=t,this.datatype=o.langStringDatatype):r&&(this.datatype=r)}equals(e){return!!e&&e.termType===this.termType&&e.value===this.value&&e.language===this.language&&e.datatype.equals(this.datatype)}}o.prototype.termType="Literal",o.langStringDatatype=new n("http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"),o.stringDatatype=new n("http://www.w3.org/2001/XMLSchema#string"),e.exports=o},358:e=>{class t{constructor(e){this.value=e}equals(e){return!!e&&e.termType===this.termType&&e.value===this.value}}t.prototype.termType="NamedNode",e.exports=t},790:(e,t,r)=>{const n=r(805);class o{constructor(e,t,r,o){this.subject=e,this.predicate=t,this.object=r,this.graph=o||new n}equals(e){return!!e&&("Quad"===e.termType||!e.termType)&&e.subject.equals(this.subject)&&e.predicate.equals(this.predicate)&&e.object.equals(this.object)&&e.graph.equals(this.graph)}}o.prototype.termType="Quad",o.prototype.value="",e.exports=o},895:e=>{class t{constructor(e){this.value=e}equals(e){return!!e&&e.termType===this.termType&&e.value===this.value}}t.prototype.termType="Variable",e.exports=t},542:e=>{e.exports=function(e){if(!e)return null;if("BlankNode"===e.termType)return this.blankNode(e.value);if("DefaultGraph"===e.termType)return this.defaultGraph();if("Literal"===e.termType)return this.literal(e.value,e.language||this.namedNode(e.datatype.value));if("NamedNode"===e.termType)return this.namedNode(e.value);if("Quad"===e.termType){const t=this.fromTerm(e.subject),r=this.fromTerm(e.predicate),n=this.fromTerm(e.object),o=this.fromTerm(e.graph);return this.quad(t,r,n,o)}if("Variable"===e.termType)return this.variable(e.value);throw new Error(`unknown termType ${e.termType}`)}},599:e=>{"use strict";const{AbortController:t,AbortSignal:r}="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0;e.exports=t,e.exports.AbortSignal=r,e.exports.default=t},742:(e,t)=>{"use strict";t.byteLength=function(e){var t=c(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,i=c(e),a=i[0],s=i[1],h=new o(function(e,t,r){return 3*(t+r)/4-r}(0,a,s)),u=0,l=s>0?a-4:a;for(r=0;r>16&255,h[u++]=t>>8&255,h[u++]=255&t;return 2===s&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,h[u++]=255&t),1===s&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,h[u++]=t>>8&255,h[u++]=255&t),h},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],a=16383,s=0,c=n-o;sc?c:s+a));return 1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),i.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=i.length;a0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function h(e,t,n){for(var o,i,a=[],s=t;s>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},764:(e,t,r)=>{"use strict";const n=r(742),o=r(645),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=c,t.SlowBuffer=function(e){return+e!=e&&(e=0),c.alloc(+e)},t.INSPECT_MAX_BYTES=50;const a=2147483647;function s(e){if(e>a)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,c.prototype),t}function c(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return l(e)}return h(e,t,r)}function h(e,t,r){if("string"==typeof e)return function(e,t){if("string"==typeof t&&""!==t||(t="utf8"),!c.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const r=0|g(e,t);let n=s(r);const o=n.write(e,t);return o!==r&&(n=n.slice(0,o)),n}(e,t);if(ArrayBuffer.isView(e))return function(e){if(Y(e,Uint8Array)){const t=new Uint8Array(e);return d(t.buffer,t.byteOffset,t.byteLength)}return p(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(Y(e,ArrayBuffer)||e&&Y(e.buffer,ArrayBuffer))return d(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(Y(e,SharedArrayBuffer)||e&&Y(e.buffer,SharedArrayBuffer)))return d(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=e.valueOf&&e.valueOf();if(null!=n&&n!==e)return c.from(n,t,r);const o=function(e){if(c.isBuffer(e)){const t=0|f(e.length),r=s(t);return 0===r.length||e.copy(r,0,0,t),r}return void 0!==e.length?"number"!=typeof e.length||Q(e.length)?s(0):p(e):"Buffer"===e.type&&Array.isArray(e.data)?p(e.data):void 0}(e);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return c.from(e[Symbol.toPrimitive]("string"),t,r);throw new 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 new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function l(e){return u(e),s(e<0?0:0|f(e))}function p(e){const t=e.length<0?0:0|f(e.length),r=s(t);for(let n=0;n=a)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a.toString(16)+" bytes");return 0|e}function g(e,t){if(c.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||Y(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const r=e.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let o=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return z(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return K(e).length;default:if(o)return n?-1:z(e).length;t=(""+t).toLowerCase(),o=!0}}function m(e,t,r){let n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return P(this,t,r);case"utf8":case"utf-8":return R(this,t,r);case"ascii":return T(this,t,r);case"latin1":case"binary":return O(this,t,r);case"base64":return x(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function y(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function w(e,t,r,n,o){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),Q(r=+r)&&(r=o?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(o)return-1;r=e.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof t&&(t=c.from(t,n)),c.isBuffer(t))return 0===t.length?-1:b(e,t,r,n,o);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):b(e,[t],r,n,o);throw new TypeError("val must be string, number or Buffer")}function b(e,t,r,n,o){let i,a=1,s=e.length,c=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,c/=2,r/=2}function h(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){let n=-1;for(i=r;is&&(r=s-c),i=r;i>=0;i--){let r=!0;for(let n=0;no&&(n=o):n=o;const i=t.length;let a;for(n>i/2&&(n=i/2),a=0;a>8,o=r%256,i.push(o),i.push(n);return i}(t,e.length-r),e,r,n)}function x(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function R(e,t,r){r=Math.min(e.length,r);const n=[];let o=t;for(;o239?4:t>223?3:t>191?2:1;if(o+a<=r){let r,n,s,c;switch(a){case 1:t<128&&(i=t);break;case 2:r=e[o+1],128==(192&r)&&(c=(31&t)<<6|63&r,c>127&&(i=c));break;case 3:r=e[o+1],n=e[o+2],128==(192&r)&&128==(192&n)&&(c=(15&t)<<12|(63&r)<<6|63&n,c>2047&&(c<55296||c>57343)&&(i=c));break;case 4:r=e[o+1],n=e[o+2],s=e[o+3],128==(192&r)&&128==(192&n)&&128==(192&s)&&(c=(15&t)<<18|(63&r)<<12|(63&n)<<6|63&s,c>65535&&c<1114112&&(i=c))}}null===i?(i=65533,a=1):i>65535&&(i-=65536,n.push(i>>>10&1023|55296),i=56320|1023&i),n.push(i),o+=a}return function(e){const t=e.length;if(t<=C)return String.fromCharCode.apply(String,e);let r="",n=0;for(;nn.length?(c.isBuffer(t)||(t=c.from(t)),t.copy(n,o)):Uint8Array.prototype.set.call(n,t,o);else{if(!c.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(n,o)}o+=t.length}return n},c.byteLength=g,c.prototype._isBuffer=!0,c.prototype.swap16=function(){const e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;tr&&(e+=" ... "),""},i&&(c.prototype[i]=c.prototype.inspect),c.prototype.compare=function(e,t,r,n,o){if(Y(e,Uint8Array)&&(e=c.from(e,e.offset,e.byteLength)),!c.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),t<0||r>e.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&t>=r)return 0;if(n>=o)return-1;if(t>=r)return 1;if(this===e)return 0;let i=(o>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0);const s=Math.min(i,a),h=this.slice(n,o),u=e.slice(t,r);for(let e=0;e>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const o=this.length-t;if((void 0===r||r>o)&&(r=o),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let i=!1;for(;;)switch(n){case"hex":return v(this,e,t,r);case"utf8":case"utf-8":return _(this,e,t,r);case"ascii":case"latin1":case"binary":return S(this,e,t,r);case"base64":return A(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const C=4096;function T(e,t,r){let n="";r=Math.min(e.length,r);for(let o=t;on)&&(r=n);let o="";for(let n=t;nr)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,r,n,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||te.length)throw new RangeError("Index out of range")}function D(e,t,r,n,o){$(t,n,o,e,r,7);let i=Number(t&BigInt(4294967295));e[r++]=i,i>>=8,e[r++]=i,i>>=8,e[r++]=i,i>>=8,e[r++]=i;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,r}function B(e,t,r,n,o){$(t,n,o,e,r,7);let i=Number(t&BigInt(4294967295));e[r+7]=i,i>>=8,e[r+6]=i,i>>=8,e[r+5]=i,i>>=8,e[r+4]=i;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r+3]=a,a>>=8,e[r+2]=a,a>>=8,e[r+1]=a,a>>=8,e[r]=a,r+8}function N(e,t,r,n,o,i){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function L(e,t,r,n,i){return t=+t,r>>>=0,i||N(e,0,r,4),o.write(e,t,r,n,23,4),r+4}function M(e,t,r,n,i){return t=+t,r>>>=0,i||N(e,0,r,8),o.write(e,t,r,n,52,8),r+8}c.prototype.slice=function(e,t){const r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t>>=0,t>>>=0,r||k(e,t,this.length);let n=this[e],o=1,i=0;for(;++i>>=0,t>>>=0,r||k(e,t,this.length);let n=this[e+--t],o=1;for(;t>0&&(o*=256);)n+=this[e+--t]*o;return n},c.prototype.readUint8=c.prototype.readUInt8=function(e,t){return e>>>=0,t||k(e,1,this.length),this[e]},c.prototype.readUint16LE=c.prototype.readUInt16LE=function(e,t){return e>>>=0,t||k(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUint16BE=c.prototype.readUInt16BE=function(e,t){return e>>>=0,t||k(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUint32LE=c.prototype.readUInt32LE=function(e,t){return e>>>=0,t||k(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUint32BE=c.prototype.readUInt32BE=function(e,t){return e>>>=0,t||k(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readBigUInt64LE=Z((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||W(e,this.length-8);const n=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,o=this[++e]+256*this[++e]+65536*this[++e]+r*2**24;return BigInt(n)+(BigInt(o)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||W(e,this.length-8);const n=t*2**24+65536*this[++e]+256*this[++e]+this[++e],o=this[++e]*2**24+65536*this[++e]+256*this[++e]+r;return(BigInt(n)<>>=0,t>>>=0,r||k(e,t,this.length);let n=this[e],o=1,i=0;for(;++i=o&&(n-=Math.pow(2,8*t)),n},c.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||k(e,t,this.length);let n=t,o=1,i=this[e+--n];for(;n>0&&(o*=256);)i+=this[e+--n]*o;return o*=128,i>=o&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return e>>>=0,t||k(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){e>>>=0,t||k(e,2,this.length);const r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt16BE=function(e,t){e>>>=0,t||k(e,2,this.length);const r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt32LE=function(e,t){return e>>>=0,t||k(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return e>>>=0,t||k(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readBigInt64LE=Z((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||W(e,this.length-8);const n=this[e+4]+256*this[e+5]+65536*this[e+6]+(r<<24);return(BigInt(n)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||W(e,this.length-8);const n=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(n)<>>=0,t||k(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return e>>>=0,t||k(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return e>>>=0,t||k(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return e>>>=0,t||k(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUintLE=c.prototype.writeUIntLE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||j(this,e,t,r,Math.pow(2,8*r)-1,0);let o=1,i=0;for(this[t]=255&e;++i>>=0,r>>>=0,n||j(this,e,t,r,Math.pow(2,8*r)-1,0);let o=r-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+r},c.prototype.writeUint8=c.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,1,255,0),this[t]=255&e,t+1},c.prototype.writeUint16LE=c.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},c.prototype.writeUint16BE=c.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},c.prototype.writeUint32LE=c.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},c.prototype.writeUint32BE=c.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},c.prototype.writeBigUInt64LE=Z((function(e,t=0){return D(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),c.prototype.writeBigUInt64BE=Z((function(e,t=0){return B(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),c.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);j(this,e,t,r,n-1,-n)}let o=0,i=1,a=0;for(this[t]=255&e;++o>0)-a&255;return t+r},c.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);j(this,e,t,r,n-1,-n)}let o=r-1,i=1,a=0;for(this[t+o]=255&e;--o>=0&&(i*=256);)e<0&&0===a&&0!==this[t+o+1]&&(a=1),this[t+o]=(e/i>>0)-a&255;return t+r},c.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},c.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},c.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},c.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},c.prototype.writeBigInt64LE=Z((function(e,t=0){return D(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),c.prototype.writeBigInt64BE=Z((function(e,t=0){return B(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),c.prototype.writeFloatLE=function(e,t,r){return L(this,e,t,!0,r)},c.prototype.writeFloatBE=function(e,t,r){return L(this,e,t,!1,r)},c.prototype.writeDoubleLE=function(e,t,r){return M(this,e,t,!0,r)},c.prototype.writeDoubleBE=function(e,t,r){return M(this,e,t,!1,r)},c.prototype.copy=function(e,t,r,n){if(!c.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o=n+4;r-=3)t=`_${e.slice(r-3,r)}${t}`;return`${e.slice(0,r)}${t}`}function $(e,t,r,n,o,i){if(e>r||e3?0===t||t===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(i+1)}${n}`:`>= -(2${n} ** ${8*(i+1)-1}${n}) and < 2 ** ${8*(i+1)-1}${n}`:`>= ${t}${n} and <= ${r}${n}`,new U.ERR_OUT_OF_RANGE("value",o,e)}!function(e,t,r){H(t,"offset"),void 0!==e[t]&&void 0!==e[t+r]||W(t,e.length-(r+1))}(n,o,i)}function H(e,t){if("number"!=typeof e)throw new U.ERR_INVALID_ARG_TYPE(t,"number",e)}function W(e,t,r){if(Math.floor(e)!==e)throw H(e,r),new U.ERR_OUT_OF_RANGE(r||"offset","an integer",e);if(t<0)throw new U.ERR_BUFFER_OUT_OF_BOUNDS;throw new U.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${t}`,e)}F("ERR_BUFFER_OUT_OF_BOUNDS",(function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),F("ERR_INVALID_ARG_TYPE",(function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`}),TypeError),F("ERR_OUT_OF_RANGE",(function(e,t,r){let n=`The value of "${e}" is out of range.`,o=r;return Number.isInteger(r)&&Math.abs(r)>2**32?o=q(String(r)):"bigint"==typeof r&&(o=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(o=q(o)),o+="n"),n+=` It must be ${t}. Received ${o}`,n}),RangeError);const G=/[^+/0-9A-Za-z-_]/g;function z(e,t){let r;t=t||1/0;const n=e.length;let o=null;const i=[];for(let a=0;a55295&&r<57344){if(!o){if(r>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(t-=3)>-1&&i.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((t-=1)<0)break;i.push(r)}else if(r<2048){if((t-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function K(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(G,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function V(e,t,r,n){let o;for(o=0;o=t.length||o>=e.length);++o)t[o+r]=e[o];return o}function Y(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function Q(e){return e!=e}const J=function(){const e="0123456789abcdef",t=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let o=0;o<16;++o)t[n+o]=e[r]+e[o]}return t}();function Z(e){return"undefined"==typeof BigInt?X:e}function X(){throw new Error("BigInt not supported")}},187:e=>{"use strict";var t,r="object"==typeof Reflect?Reflect:null,n=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var o=Number.isNaN||function(e){return e!=e};function i(){i.init.call(this)}e.exports=i,e.exports.once=function(e,t){return new Promise((function(r,n){function o(r){e.removeListener(t,i),n(r)}function i(){"function"==typeof e.removeListener&&e.removeListener("error",o),r([].slice.call(arguments))}g(e,t,i,{once:!0}),"error"!==t&&function(e,t,r){"function"==typeof e.on&&g(e,"error",t,{once:!0})}(e,o)}))},i.EventEmitter=i,i.prototype._events=void 0,i.prototype._eventsCount=0,i.prototype._maxListeners=void 0;var a=10;function s(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function c(e){return void 0===e._maxListeners?i.defaultMaxListeners:e._maxListeners}function h(e,t,r,n){var o,i,a,h;if(s(r),void 0===(i=e._events)?(i=e._events=Object.create(null),e._eventsCount=0):(void 0!==i.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),i=e._events),a=i[t]),void 0===a)a=i[t]=r,++e._eventsCount;else if("function"==typeof a?a=i[t]=n?[r,a]:[a,r]:n?a.unshift(r):a.push(r),(o=c(e))>0&&a.length>o&&!a.warned){a.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=e,u.type=t,u.count=a.length,h=u,console&&console.warn&&console.warn(h)}return e}function u(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function l(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},o=u.bind(n);return o.listener=r,n.wrapFn=o,o}function p(e,t,r){var n=e._events;if(void 0===n)return[];var o=n[t];return void 0===o?[]:"function"==typeof o?r?[o.listener||o]:[o]:r?function(e){for(var t=new Array(e.length),r=0;r0&&(a=t[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var c=i[e];if(void 0===c)return!1;if("function"==typeof c)n(c,this,t);else{var h=c.length,u=f(c,h);for(r=0;r=0;i--)if(r[i]===t||r[i].listener===t){a=r[i].listener,o=i;break}if(o<0)return this;0===o?r.shift():function(e,t){for(;t+1=0;n--)this.removeListener(e,t[n]);return this},i.prototype.listeners=function(e){return p(this,e,!0)},i.prototype.rawListeners=function(e){return p(this,e,!1)},i.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},i.prototype.listenerCount=d,i.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},475:e=>{"use strict";var t=/^utf-?8|ascii|utf-?16-?le|ucs-?2|base-?64|latin-?1$/i,r=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,n=/\s|\uFEFF|\xA0/,o=/\r?\n[\x20\x09]+/g,i=/[;,"]/,a=/[;,"]|\s/,s=/^[!#$%&'*+\-\.^_`|~\da-zA-Z]+$/;function c(e){return e.replace(r,"")}function h(e){return n.test(e)}function u(e,t){for(;h(e[t]);)t++;return t}function l(e){return a.test(e)||!s.test(e)}class p{constructor(e){this.refs=[],e&&this.parse(e)}rel(e){for(var t=[],r=e.toLowerCase(),n=0;n{return r=t,n=e,Object.keys(r).length===Object.keys(n).length&&Object.keys(r).every((e=>e in n&&r[e]===n[e]));var r,n}))||this.refs.push(e),this}has(e,t){e=e.toLowerCase();for(var r=0;r",t)))throw new Error("Expected end of URI delimiter at offset "+t);a={uri:e.slice(t+1,d)},t=d,r=2,t++}else if(2===r){if(h(e[t])){t++;continue}if(";"===e[t])r=4,t++;else{if(","!==e[t])throw new Error('Unexpected character "'+e[t]+'" at offset '+t);r=1,t++}}else{if(4!==r)throw new Error('Unknown parser state "'+r+'"');if(";"===e[t]||h(e[t])){t++;continue}if(-1===(d=e.indexOf("=",t)))throw new Error("Expected attribute delimiter at offset "+t);var s=c(e.slice(t,d)).toLowerCase(),l="";if('"'===e[t=u(e,t=d+1)])for(t++;t"),e.push(t);return e.join(", ")}}p.isCompatibleEncoding=function(e){return t.test(e)},p.parse=function(e,t){return(new p).parse(e,t)},p.isSingleOccurenceAttr=function(e){return"rel"===e||"type"===e||"media"===e||"title"===e||"title*"===e},p.isTokenAttr=function(e){return"rel"===e||"type"===e||"anchor"===e},p.escapeQuotes=function(e){return e.replace(/"/g,'\\"')},p.expandRelations=function(e){return e.rel.split(" ").map((function(t){var r=Object.assign({},e);return r.rel=t,r}))},p.parseExtendedValue=function(e){var t=/([^']+)?(?:'([^']*)')?(.+)/.exec(e);return{language:t[2].toLowerCase(),encoding:p.isCompatibleEncoding(t[1])?null:t[1].toLowerCase(),value:p.isCompatibleEncoding(t[1])?decodeURIComponent(t[3]):t[3]}},p.formatExtendedAttribute=function(e,t){var r=(t.encoding||"utf-8").toUpperCase();return e+"="+r+"'"+(t.language||"en")+"'"+(Buffer.isBuffer(t.value)&&p.isCompatibleEncoding(r)?t.value.toString(r):Buffer.isBuffer(t.value)?t.value.toString("hex").replace(/[0-9a-f]{2}/gi,"%$1"):encodeURIComponent(t.value))},p.formatAttribute=function(e,t){return Array.isArray(t)?t.map((t=>p.formatAttribute(e,t))).join("; "):"*"===e[e.length-1]||"string"!=typeof t?p.formatExtendedAttribute(e,t):(p.isTokenAttr(e)?t=l(t)?'"'+p.escapeQuotes(t)+'"':p.escapeQuotes(t):l(t)&&(t='"'+(t=(t=encodeURIComponent(t)).replace(/%20/g," ").replace(/%2C/g,",").replace(/%3B/g,";"))+'"'),e+"="+t)},e.exports=p},645:(e,t)=>{t.read=function(e,t,r,n,o){var i,a,s=8*o-n-1,c=(1<>1,u=-7,l=r?o-1:0,p=r?-1:1,d=e[t+l];for(l+=p,i=d&(1<<-u)-1,d>>=-u,u+=s;u>0;i=256*i+e[t+l],l+=p,u-=8);for(a=i&(1<<-u)-1,i>>=-u,u+=n;u>0;a=256*a+e[t+l],l+=p,u-=8);if(0===i)i=1-h;else{if(i===c)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),i-=h}return(d?-1:1)*a*Math.pow(2,i-n)},t.write=function(e,t,r,n,o,i){var a,s,c,h=8*i-o-1,u=(1<>1,p=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:i-1,f=n?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=u):(a=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-a))<1&&(a--,c*=2),(t+=a+l>=1?p/c:p*Math.pow(2,1-l))*c>=2&&(a++,c/=2),a+l>=u?(s=0,a=u):a+l>=1?(s=(t*c-1)*Math.pow(2,o),a+=l):(s=t*Math.pow(2,l-1)*Math.pow(2,o),a=0));o>=8;e[r+d]=255&s,d+=f,s/=256,o-=8);for(a=a<0;e[r+d]=255&a,d+=f,a/=256,h-=8);e[r+d-f]|=128*g}},300:(e,t,r)=>{"use strict";var n=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==r.g)return r.g;throw new Error("unable to locate global object")}();e.exports=t=n.fetch,n.fetch&&(t.default=n.fetch.bind(n)),t.Headers=n.Headers,t.Request=n.Request,t.Response=n.Response},155:e=>{var t,r,n=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===o||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(r){try{return t.call(null,e,0)}catch(r){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:o}catch(e){t=o}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(e){r=i}}();var s,c=[],h=!1,u=-1;function l(){h&&s&&(h=!1,s.length?c=s.concat(c):u=-1,c.length&&p())}function p(){if(!h){var e=a(l);h=!0;for(var t=c.length;t;){for(s=c,c=[];++u1)for(var r=1;r{let n;e.exports="function"==typeof queueMicrotask?queueMicrotask.bind("undefined"!=typeof window?window:r.g):e=>(n||(n=Promise.resolve())).then(e).catch((e=>setTimeout((()=>{throw e}),0)))},196:(e,t,r)=>{"use strict";const{AbortError:n,codes:o}=r(381),i=r(610),{ERR_INVALID_ARG_TYPE:a}=o;e.exports.addAbortSignal=function(t,r){if(((e,t)=>{if("object"!=typeof e||!("aborted"in e))throw new a("signal","AbortSignal",e)})(t),!(n=r)||"function"!=typeof n.pipe)throw new a("stream","stream.Stream",r);var n;return e.exports.addAbortSignalNoValidate(t,r)},e.exports.addAbortSignalNoValidate=function(e,t){if("object"!=typeof e||!("aborted"in e))return t;const r=()=>{t.destroy(new n(void 0,{cause:e.reason}))};return e.aborted?r():(e.addEventListener("abort",r),i(t,(()=>e.removeEventListener("abort",r)))),t}},327:(e,t,r)=>{"use strict";const{StringPrototypeSlice:n,SymbolIterator:o,TypedArrayPrototypeSet:i,Uint8Array:a}=r(61),{Buffer:s}=r(764),{inspect:c}=r(87);e.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(e){const t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length}unshift(e){const t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}shift(){if(0===this.length)return;const e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}clear(){this.head=this.tail=null,this.length=0}join(e){if(0===this.length)return"";let t=this.head,r=""+t.data;for(;null!==(t=t.next);)r+=e+t.data;return r}concat(e){if(0===this.length)return s.alloc(0);const t=s.allocUnsafe(e>>>0);let r=this.head,n=0;for(;r;)i(t,r.data,n),n+=r.data.length,r=r.next;return t}consume(e,t){const r=this.head.data;if(ei.length)){e===i.length?(t+=i,++o,r.next?this.head=r.next:this.head=this.tail=null):(t+=n(i,0,e),this.head=r,r.data=n(i,e));break}t+=i,e-=i.length,++o}while(null!==(r=r.next));return this.length-=o,t}_getBuffer(e){const t=s.allocUnsafe(e),r=e;let n=this.head,o=0;do{const s=n.data;if(!(e>s.length)){e===s.length?(i(t,s,r-e),++o,n.next?this.head=n.next:this.head=this.tail=null):(i(t,new a(s.buffer,s.byteOffset,e),r-e),this.head=n,n.data=s.slice(e));break}i(t,s,r-e),e-=s.length,++o}while(null!==(n=n.next));return this.length-=o,t}[Symbol.for("nodejs.util.inspect.custom")](e,t){return c(this,{...t,depth:0,customInspect:!1})}}},299:(e,t,r)=>{"use strict";const{pipeline:n}=r(946),o=r(672),{destroyer:i}=r(195),{isNodeStream:a,isReadable:s,isWritable:c}=r(874),{AbortError:h,codes:{ERR_INVALID_ARG_VALUE:u,ERR_MISSING_ARGS:l}}=r(381);e.exports=function(...e){if(0===e.length)throw new l("streams");if(1===e.length)return o.from(e[0]);const t=[...e];if("function"==typeof e[0]&&(e[0]=o.from(e[0])),"function"==typeof e[e.length-1]){const t=e.length-1;e[t]=o.from(e[t])}for(let r=0;r0&&!c(e[r]))throw new u(`streams[${r}]`,t[r],"must be writable")}let r,p,d,f,g;const m=e[0],y=n(e,(function(e){const t=f;f=null,t?t(e):e?g.destroy(e):b||w||g.destroy()})),w=!!c(m),b=!!s(y);return g=new o({writableObjectMode:!(null==m||!m.writableObjectMode),readableObjectMode:!(null==y||!y.writableObjectMode),writable:w,readable:b}),w&&(g._write=function(e,t,n){m.write(e,t)?n():r=n},g._final=function(e){m.end(),p=e},m.on("drain",(function(){if(r){const e=r;r=null,e()}})),y.on("finish",(function(){if(p){const e=p;p=null,e()}}))),b&&(y.on("readable",(function(){if(d){const e=d;d=null,e()}})),y.on("end",(function(){g.push(null)})),g._read=function(){for(;;){const e=y.read();if(null===e)return void(d=g._read);if(!g.push(e))return}}),g._destroy=function(e,t){e||null===f||(e=new h),d=null,r=null,p=null,null===f?t(e):(f=t,i(y,e))},g}},195:(e,t,r)=>{"use strict";const n=r(155),{aggregateTwoErrors:o,codes:{ERR_MULTIPLE_CALLBACK:i},AbortError:a}=r(381),{Symbol:s}=r(61),{kDestroyed:c,isDestroyed:h,isFinished:u,isServerRequest:l}=r(874),p=s("kDestroy"),d=s("kConstruct");function f(e,t,r){e&&(e.stack,t&&!t.errored&&(t.errored=e),r&&!r.errored&&(r.errored=e))}function g(e,t,r){let o=!1;function i(t){if(o)return;o=!0;const i=e._readableState,a=e._writableState;f(t,a,i),a&&(a.closed=!0),i&&(i.closed=!0),"function"==typeof r&&r(t),t?n.nextTick(m,e,t):n.nextTick(y,e)}try{e._destroy(t||null,i)}catch(t){i(t)}}function m(e,t){w(e,t),y(e)}function y(e){const t=e._readableState,r=e._writableState;r&&(r.closeEmitted=!0),t&&(t.closeEmitted=!0),(r&&r.emitClose||t&&t.emitClose)&&e.emit("close")}function w(e,t){const r=e._readableState,n=e._writableState;n&&n.errorEmitted||r&&r.errorEmitted||(n&&(n.errorEmitted=!0),r&&(r.errorEmitted=!0),e.emit("error",t))}function b(e,t,r){const o=e._readableState,i=e._writableState;if(i&&i.destroyed||o&&o.destroyed)return this;o&&o.autoDestroy||i&&i.autoDestroy?e.destroy(t):t&&(t.stack,i&&!i.errored&&(i.errored=t),o&&!o.errored&&(o.errored=t),r?n.nextTick(w,e,t):w(e,t))}function v(e){let t=!1;function r(r){if(t)return void b(e,null!=r?r:new i);t=!0;const o=e._readableState,a=e._writableState,s=a||o;o&&(o.constructed=!0),a&&(a.constructed=!0),s.destroyed?e.emit(p,r):r?b(e,r,!0):n.nextTick(_,e)}try{e._construct(r)}catch(e){r(e)}}function _(e){e.emit(d)}function S(e){return e&&e.setHeader&&"function"==typeof e.abort}function A(e){e.emit("close")}function E(e,t){e.emit("error",t),n.nextTick(A,e)}e.exports={construct:function(e,t){if("function"!=typeof e._construct)return;const r=e._readableState,o=e._writableState;r&&(r.constructed=!1),o&&(o.constructed=!1),e.once(d,t),e.listenerCount(d)>1||n.nextTick(v,e)},destroyer:function(e,t){e&&!h(e)&&(t||u(e)||(t=new a),l(e)?(e.socket=null,e.destroy(t)):S(e)?e.abort():S(e.req)?e.req.abort():"function"==typeof e.destroy?e.destroy(t):"function"==typeof e.close?e.close():t?n.nextTick(E,e,t):n.nextTick(A,e),e.destroyed||(e[c]=!0))},destroy:function(e,t){const r=this._readableState,n=this._writableState,i=n||r;return n&&n.destroyed||r&&r.destroyed?("function"==typeof t&&t(),this):(f(e,n,r),n&&(n.destroyed=!0),r&&(r.destroyed=!0),i.constructed?g(this,e,t):this.once(p,(function(r){g(this,o(r,e),t)})),this)},undestroy:function(){const e=this._readableState,t=this._writableState;e&&(e.constructed=!0,e.closed=!1,e.closeEmitted=!1,e.destroyed=!1,e.errored=null,e.errorEmitted=!1,e.reading=!1,e.ended=!1===e.readable,e.endEmitted=!1===e.readable),t&&(t.constructed=!0,t.destroyed=!1,t.closed=!1,t.closeEmitted=!1,t.errored=null,t.errorEmitted=!1,t.finalCalled=!1,t.prefinished=!1,t.ended=!1===t.writable,t.ending=!1===t.writable,t.finished=!1===t.writable)},errorOrDestroy:b}},672:(e,t,r)=>{"use strict";const{ObjectDefineProperties:n,ObjectGetOwnPropertyDescriptor:o,ObjectKeys:i,ObjectSetPrototypeOf:a}=r(61);e.exports=h;const s=r(911),c=r(304);a(h.prototype,s.prototype),a(h,s);{const e=i(c.prototype);for(let t=0;t{const n=r(155),o=r(764),{isReadable:i,isWritable:a,isIterable:s,isNodeStream:c,isReadableNodeStream:h,isWritableNodeStream:u,isDuplexNodeStream:l}=r(874),p=r(610),{AbortError:d,codes:{ERR_INVALID_ARG_TYPE:f,ERR_INVALID_RETURN_VALUE:g}}=r(381),{destroyer:m}=r(195),y=r(672),w=r(911),{createDeferredPromise:b}=r(87),v=r(307),_=globalThis.Blob||o.Blob,S=void 0!==_?function(e){return e instanceof _}:function(e){return!1},A=globalThis.AbortController||r(599).AbortController,{FunctionPrototypeCall:E}=r(61);class x extends y{constructor(e){super(e),!1===(null==e?void 0:e.readable)&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),!1===(null==e?void 0:e.writable)&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}}function R(e){const t=e.readable&&"function"!=typeof e.readable.read?w.wrap(e.readable):e.readable,r=e.writable;let n,o,s,c,h,u=!!i(t),l=!!a(r);function f(e){const t=c;c=null,t?t(e):e?h.destroy(e):u||l||h.destroy()}return h=new x({readableObjectMode:!(null==t||!t.readableObjectMode),writableObjectMode:!(null==r||!r.writableObjectMode),readable:u,writable:l}),l&&(p(r,(e=>{l=!1,e&&m(t,e),f(e)})),h._write=function(e,t,o){r.write(e,t)?o():n=o},h._final=function(e){r.end(),o=e},r.on("drain",(function(){if(n){const e=n;n=null,e()}})),r.on("finish",(function(){if(o){const e=o;o=null,e()}}))),u&&(p(t,(e=>{u=!1,e&&m(t,e),f(e)})),t.on("readable",(function(){if(s){const e=s;s=null,e()}})),t.on("end",(function(){h.push(null)})),h._read=function(){for(;;){const e=t.read();if(null===e)return void(s=h._read);if(!h.push(e))return}}),h._destroy=function(e,i){e||null===c||(e=new d),s=null,n=null,o=null,null===c?i(e):(c=i,m(r,e),m(t,e))},h}e.exports=function e(t,r){if(l(t))return t;if(h(t))return R({readable:t});if(u(t))return R({writable:t});if(c(t))return R({writable:!1,readable:!1});if("function"==typeof t){const{value:e,write:o,final:i,destroy:a}=function(e){let{promise:t,resolve:r}=b();const o=new A,i=o.signal;return{value:e(async function*(){for(;;){const e=t;t=null;const{chunk:o,done:a,cb:s}=await e;if(n.nextTick(s),a)return;if(i.aborted)throw new d(void 0,{cause:i.reason});({promise:t,resolve:r}=b()),yield o}}(),{signal:i}),write(e,t,n){const o=r;r=null,o({chunk:e,done:!1,cb:n})},final(e){const t=r;r=null,t({done:!0,cb:e})},destroy(e,t){o.abort(),t(e)}}}(t);if(s(e))return v(x,e,{objectMode:!0,write:o,final:i,destroy:a});const c=null==e?void 0:e.then;if("function"==typeof c){let t;const r=E(c,e,(e=>{if(null!=e)throw new g("nully","body",e)}),(e=>{m(t,e)}));return t=new x({objectMode:!0,readable:!1,write:o,final(e){i((async()=>{try{await r,n.nextTick(e,null)}catch(t){n.nextTick(e,t)}}))},destroy:a})}throw new g("Iterable, AsyncIterable or AsyncFunction",r,e)}if(S(t))return e(t.arrayBuffer());if(s(t))return v(x,t,{objectMode:!0,writable:!1});if("object"==typeof(null==t?void 0:t.writable)||"object"==typeof(null==t?void 0:t.readable))return R({readable:null!=t&&t.readable?h(null==t?void 0:t.readable)?null==t?void 0:t.readable:e(t.readable):void 0,writable:null!=t&&t.writable?u(null==t?void 0:t.writable)?null==t?void 0:t.writable:e(t.writable):void 0});const o=null==t?void 0:t.then;if("function"==typeof o){let e;return E(o,t,(t=>{null!=t&&e.push(t),e.push(null)}),(t=>{m(e,t)})),e=new x({objectMode:!0,writable:!1,read(){}})}throw new f(r,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],t)}},610:(e,t,r)=>{const n=r(155),{AbortError:o,codes:i}=r(381),{ERR_INVALID_ARG_TYPE:a,ERR_STREAM_PREMATURE_CLOSE:s}=i,{kEmptyObject:c,once:h}=r(87),{validateAbortSignal:u,validateFunction:l,validateObject:p}=r(547),{Promise:d}=r(61),{isClosed:f,isReadable:g,isReadableNodeStream:m,isReadableFinished:y,isReadableErrored:w,isWritable:b,isWritableNodeStream:v,isWritableFinished:_,isWritableErrored:S,isNodeStream:A,willEmitClose:E}=r(874),x=()=>{};function R(e,t,r){var i,d;2===arguments.length?(r=t,t=c):null==t?t=c:p(t,"options"),l(r,"callback"),u(t.signal,"options.signal"),r=h(r);const R=null!==(i=t.readable)&&void 0!==i?i:m(e),C=null!==(d=t.writable)&&void 0!==d?d:v(e);if(!A(e))throw new a("stream","Stream",e);const T=e._writableState,O=e._readableState,P=()=>{e.writable||j()};let I=E(e)&&m(e)===R&&v(e)===C,k=_(e,!1);const j=()=>{k=!0,e.destroyed&&(I=!1),(!I||e.readable&&!R)&&(R&&!D||r.call(e))};let D=y(e,!1);const B=()=>{D=!0,e.destroyed&&(I=!1),(!I||e.writable&&!C)&&(C&&!k||r.call(e))},N=t=>{r.call(e,t)};let L=f(e);const M=()=>{L=!0;const t=S(e)||w(e);return t&&"boolean"!=typeof t?r.call(e,t):R&&!D&&m(e,!0)&&!y(e,!1)?r.call(e,new s):!C||k||_(e,!1)?void r.call(e):r.call(e,new s)},U=()=>{e.req.on("finish",j)};!function(e){return e.setHeader&&"function"==typeof e.abort}(e)?C&&!T&&(e.on("end",P),e.on("close",P)):(e.on("complete",j),I||e.on("abort",M),e.req?U():e.on("request",U)),I||"boolean"!=typeof e.aborted||e.on("aborted",M),e.on("end",B),e.on("finish",j),!1!==t.error&&e.on("error",N),e.on("close",M),L?n.nextTick(M):null!=T&&T.errorEmitted||null!=O&&O.errorEmitted?I||n.nextTick(M):(R||I&&!g(e)||!k&&!1!==b(e))&&(C||I&&!b(e)||!D&&!1!==g(e))?O&&e.req&&e.aborted&&n.nextTick(M):n.nextTick(M);const F=()=>{r=x,e.removeListener("aborted",M),e.removeListener("complete",j),e.removeListener("abort",M),e.removeListener("request",U),e.req&&e.req.removeListener("finish",j),e.removeListener("end",P),e.removeListener("close",P),e.removeListener("finish",j),e.removeListener("end",B),e.removeListener("error",N),e.removeListener("close",M)};if(t.signal&&!L){const i=()=>{const n=r;F(),n.call(e,new o(void 0,{cause:t.signal.reason}))};if(t.signal.aborted)n.nextTick(i);else{const n=r;r=h(((...r)=>{t.signal.removeEventListener("abort",i),n.apply(e,r)})),t.signal.addEventListener("abort",i)}}return F}e.exports=R,e.exports.finished=function(e,t){return new d(((r,n)=>{R(e,t,(e=>{e?n(e):r()}))}))}},307:(e,t,r)=>{"use strict";const n=r(155),{PromisePrototypeThen:o,SymbolAsyncIterator:i,SymbolIterator:a}=r(61),{Buffer:s}=r(764),{ERR_INVALID_ARG_TYPE:c,ERR_STREAM_NULL_VALUES:h}=r(381).codes;e.exports=function(e,t,r){let u,l;if("string"==typeof t||t instanceof s)return new e({objectMode:!0,...r,read(){this.push(t),this.push(null)}});if(t&&t[i])l=!0,u=t[i]();else{if(!t||!t[a])throw new c("iterable",["Iterable"],t);l=!1,u=t[a]()}const p=new e({objectMode:!0,highWaterMark:1,...r});let d=!1;return p._read=function(){d||(d=!0,async function(){for(;;){try{const{value:e,done:t}=l?await u.next():u.next();if(t)p.push(null);else{const t=e&&"function"==typeof e.then?await e:e;if(null===t)throw d=!1,new h;if(p.push(t))continue;d=!1}}catch(e){p.destroy(e)}break}}())},p._destroy=function(e,t){o(async function(e){const t=null!=e,r="function"==typeof u.throw;if(t&&r){const{value:t,done:r}=await u.throw(e);if(await t,r)return}if("function"==typeof u.return){const{value:e}=await u.return();await e}}(e),(()=>n.nextTick(t,e)),(r=>n.nextTick(t,r||e)))},p}},870:(e,t,r)=>{"use strict";const{ArrayIsArray:n,ObjectSetPrototypeOf:o}=r(61),{EventEmitter:i}=r(187);function a(e){i.call(this,e)}function s(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?n(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}o(a.prototype,i.prototype),o(a,i),a.prototype.pipe=function(e,t){const r=this;function n(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",n),e.on("drain",o),e._isStdio||t&&!1===t.end||(r.on("end",c),r.on("close",h));let a=!1;function c(){a||(a=!0,e.end())}function h(){a||(a=!0,"function"==typeof e.destroy&&e.destroy())}function u(e){l(),0===i.listenerCount(this,"error")&&this.emit("error",e)}function l(){r.removeListener("data",n),e.removeListener("drain",o),r.removeListener("end",c),r.removeListener("close",h),r.removeListener("error",u),e.removeListener("error",u),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return s(r,"error",u),s(e,"error",u),r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e},e.exports={Stream:a,prependListener:s}},382:(e,t,r)=>{"use strict";const n=globalThis.AbortController||r(599).AbortController,{codes:{ERR_INVALID_ARG_TYPE:o,ERR_MISSING_ARGS:i,ERR_OUT_OF_RANGE:a},AbortError:s}=r(381),{validateAbortSignal:c,validateInteger:h,validateObject:u}=r(547),l=r(61).Symbol("kWeak"),{finished:p}=r(610),{ArrayPrototypePush:d,MathFloor:f,Number:g,NumberIsNaN:m,Promise:y,PromiseReject:w,PromisePrototypeThen:b,Symbol:v}=r(61),_=v("kEmpty"),S=v("kEof");function A(e,t){if("function"!=typeof e)throw new o("fn",["Function","AsyncFunction"],e);null!=t&&u(t,"options"),null!=(null==t?void 0:t.signal)&&c(t.signal,"options.signal");let r=1;return null!=(null==t?void 0:t.concurrency)&&(r=f(t.concurrency)),h(r,"concurrency",1),async function*(){var o,i;const a=new n,c=this,h=[],u=a.signal,l={signal:u},p=()=>a.abort();let d,f;null!=t&&null!==(o=t.signal)&&void 0!==o&&o.aborted&&p(),null==t||null===(i=t.signal)||void 0===i||i.addEventListener("abort",p);let g=!1;function m(){g=!0}!async function(){try{for await(let t of c){var n;if(g)return;if(u.aborted)throw new s;try{t=e(t,l)}catch(e){t=w(e)}t!==_&&("function"==typeof(null===(n=t)||void 0===n?void 0:n.catch)&&t.catch(m),h.push(t),d&&(d(),d=null),!g&&h.length&&h.length>=r&&await new y((e=>{f=e})))}h.push(S)}catch(e){const t=w(e);b(t,void 0,m),h.push(t)}finally{var o;g=!0,d&&(d(),d=null),null==t||null===(o=t.signal)||void 0===o||o.removeEventListener("abort",p)}}();try{for(;;){for(;h.length>0;){const e=await h[0];if(e===S)return;if(u.aborted)throw new s;e!==_&&(yield e),h.shift(),f&&(f(),f=null)}await new y((e=>{d=e}))}}finally{a.abort(),g=!0,f&&(f(),f=null)}}.call(this)}async function E(e,t){for await(const r of x.call(this,e,t))return!0;return!1}function x(e,t){if("function"!=typeof e)throw new o("fn",["Function","AsyncFunction"],e);return A.call(this,(async function(t,r){return await e(t,r)?t:_}),t)}class R extends i{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}}function C(e){if(e=g(e),m(e))return 0;if(e<0)throw new a("number",">= 0",e);return e}e.exports.streamReturningOperators={asIndexedPairs:function(e){return null!=e&&u(e,"options"),null!=(null==e?void 0:e.signal)&&c(e.signal,"options.signal"),async function*(){let t=0;for await(const n of this){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new s({cause:e.signal.reason});yield[t++,n]}}.call(this)},drop:function(e,t){return null!=t&&u(t,"options"),null!=(null==t?void 0:t.signal)&&c(t.signal,"options.signal"),e=C(e),async function*(){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new s;for await(const r of this){var n;if(null!=t&&null!==(n=t.signal)&&void 0!==n&&n.aborted)throw new s;e--<=0&&(yield r)}}.call(this)},filter:x,flatMap:function(e,t){const r=A.call(this,e,t);return async function*(){for await(const e of r)yield*e}.call(this)},map:A,take:function(e,t){return null!=t&&u(t,"options"),null!=(null==t?void 0:t.signal)&&c(t.signal,"options.signal"),e=C(e),async function*(){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new s;for await(const r of this){var n;if(null!=t&&null!==(n=t.signal)&&void 0!==n&&n.aborted)throw new s;if(!(e-- >0))return;yield r}}.call(this)}},e.exports.promiseReturningOperators={every:async function(e,t){if("function"!=typeof e)throw new o("fn",["Function","AsyncFunction"],e);return!await E.call(this,(async(...t)=>!await e(...t)),t)},forEach:async function(e,t){if("function"!=typeof e)throw new o("fn",["Function","AsyncFunction"],e);for await(const r of A.call(this,(async function(t,r){return await e(t,r),_}),t));},reduce:async function(e,t,r){var i;if("function"!=typeof e)throw new o("reducer",["Function","AsyncFunction"],e);null!=r&&u(r,"options"),null!=(null==r?void 0:r.signal)&&c(r.signal,"options.signal");let a=arguments.length>1;if(null!=r&&null!==(i=r.signal)&&void 0!==i&&i.aborted){const e=new s(void 0,{cause:r.signal.reason});throw this.once("error",(()=>{})),await p(this.destroy(e)),e}const h=new n,d=h.signal;if(null!=r&&r.signal){const e={once:!0,[l]:this};r.signal.addEventListener("abort",(()=>h.abort()),e)}let f=!1;try{for await(const n of this){var g;if(f=!0,null!=r&&null!==(g=r.signal)&&void 0!==g&&g.aborted)throw new s;a?t=await e(t,n,{signal:d}):(t=n,a=!0)}if(!f&&!a)throw new R}finally{h.abort()}return t},toArray:async function(e){null!=e&&u(e,"options"),null!=(null==e?void 0:e.signal)&&c(e.signal,"options.signal");const t=[];for await(const n of this){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new s(void 0,{cause:e.signal.reason});d(t,n)}return t},some:E,find:async function(e,t){for await(const r of x.call(this,e,t))return r}}},917:(e,t,r)=>{"use strict";const{ObjectSetPrototypeOf:n}=r(61);e.exports=i;const o=r(161);function i(e){if(!(this instanceof i))return new i(e);o.call(this,e)}n(i.prototype,o.prototype),n(i,o),i.prototype._transform=function(e,t,r){r(null,e)}},946:(e,t,r)=>{const n=r(155),{ArrayIsArray:o,Promise:i,SymbolAsyncIterator:a}=r(61),s=r(610),{once:c}=r(87),h=r(195),u=r(672),{aggregateTwoErrors:l,codes:{ERR_INVALID_ARG_TYPE:p,ERR_INVALID_RETURN_VALUE:d,ERR_MISSING_ARGS:f,ERR_STREAM_DESTROYED:g,ERR_STREAM_PREMATURE_CLOSE:m},AbortError:y}=r(381),{validateFunction:w,validateAbortSignal:b}=r(547),{isIterable:v,isReadable:_,isReadableNodeStream:S,isNodeStream:A}=r(874),E=globalThis.AbortController||r(599).AbortController;let x,R;function C(e,t,r){let n=!1;return e.on("close",(()=>{n=!0})),{destroy:t=>{n||(n=!0,h.destroyer(e,t||new g("pipe")))},cleanup:s(e,{readable:t,writable:r},(e=>{n=!e}))}}function T(e){if(v(e))return e;if(S(e))return async function*(e){R||(R=r(911)),yield*R.prototype[a].call(e)}(e);throw new p("val",["Readable","Iterable","AsyncIterable"],e)}async function O(e,t,r,{end:n}){let o,a=null;const c=e=>{if(e&&(o=e),a){const e=a;a=null,e()}},h=()=>new i(((e,t)=>{o?t(o):a=()=>{o?t(o):e()}}));t.on("drain",c);const u=s(t,{readable:!1},c);try{t.writableNeedDrain&&await h();for await(const r of e)t.write(r)||await h();n&&t.end(),await h(),r()}catch(e){r(o!==e?l(o,e):e)}finally{u(),t.off("drain",c)}}function P(e,t,i){if(1===e.length&&o(e[0])&&(e=e[0]),e.length<2)throw new f("streams");const a=new E,s=a.signal,c=null==i?void 0:i.signal,h=[];function l(){j(new y)}let g,m;b(c,"options.signal"),null==c||c.addEventListener("abort",l);const w=[];let R,P=0;function k(e){j(e,0==--P)}function j(e,r){if(!e||g&&"ERR_STREAM_PREMATURE_CLOSE"!==g.code||(g=e),g||r){for(;w.length;)w.shift()(g);null==c||c.removeEventListener("abort",l),a.abort(),r&&(g||h.forEach((e=>e())),n.nextTick(t,g,m))}}for(let N=0;N0,F=M||!1!==(null==i?void 0:i.end),q=N===e.length-1;if(A(L)){if(F){const{destroy:$,cleanup:H}=C(L,M,U);w.push($),_(L)&&q&&h.push(H)}function D(e){e&&"AbortError"!==e.name&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code&&k(e)}L.on("error",D),_(L)&&q&&h.push((()=>{L.removeListener("error",D)}))}if(0===N)if("function"==typeof L){if(R=L({signal:s}),!v(R))throw new d("Iterable, AsyncIterable or Stream","source",R)}else R=v(L)||S(L)?L:u.from(L);else if("function"==typeof L)if(R=T(R),R=L(R,{signal:s}),M){if(!v(R,!0))throw new d("AsyncIterable",`transform[${N-1}]`,R)}else{var B;x||(x=r(917));const W=new x({objectMode:!0}),G=null===(B=R)||void 0===B?void 0:B.then;if("function"==typeof G)P++,G.call(R,(e=>{m=e,null!=e&&W.write(e),F&&W.end(),n.nextTick(k)}),(e=>{W.destroy(e),n.nextTick(k,e)}));else{if(!v(R,!0))throw new d("AsyncIterable or Promise","destination",R);P++,O(R,W,k,{end:F})}R=W;const{destroy:z,cleanup:K}=C(R,!1,!0);w.push(z),q&&h.push(K)}else if(A(L)){if(S(R)){P+=2;const V=I(R,L,k,{end:F});_(L)&&q&&h.push(V)}else{if(!v(R))throw new p("val",["Readable","Iterable","AsyncIterable"],R);P++,O(R,L,k,{end:F})}R=L}else R=u.from(L)}return(null!=s&&s.aborted||null!=c&&c.aborted)&&n.nextTick(l),R}function I(e,t,r,{end:n}){let o=!1;return t.on("close",(()=>{o||r(new m)})),e.pipe(t,{end:n}),n?e.once("end",(()=>{o=!0,t.end()})):r(),s(e,{readable:!0,writable:!1},(t=>{const n=e._readableState;t&&"ERR_STREAM_PREMATURE_CLOSE"===t.code&&n&&n.ended&&!n.errored&&!n.errorEmitted?e.once("end",r).once("error",r):r(t)})),s(t,{readable:!1,writable:!0},r)}e.exports={pipelineImpl:P,pipeline:function(...e){return P(e,c(function(e){return w(e[e.length-1],"streams[stream.length - 1]"),e.pop()}(e)))}}},911:(e,t,r)=>{const n=r(155),{ArrayPrototypeIndexOf:o,NumberIsInteger:i,NumberIsNaN:a,NumberParseInt:s,ObjectDefineProperties:c,ObjectKeys:h,ObjectSetPrototypeOf:u,Promise:l,SafeSet:p,SymbolAsyncIterator:d,Symbol:f}=r(61);e.exports=U,U.ReadableState=M;const{EventEmitter:g}=r(187),{Stream:m,prependListener:y}=r(870),{Buffer:w}=r(764),{addAbortSignal:b}=r(196),v=r(610);let _=r(87).debuglog("stream",(e=>{_=e}));const S=r(327),A=r(195),{getHighWaterMark:E,getDefaultHighWaterMark:x}=r(457),{aggregateTwoErrors:R,codes:{ERR_INVALID_ARG_TYPE:C,ERR_METHOD_NOT_IMPLEMENTED:T,ERR_OUT_OF_RANGE:O,ERR_STREAM_PUSH_AFTER_EOF:P,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:I}}=r(381),{validateObject:k}=r(547),j=f("kPaused"),{StringDecoder:D}=r(553),B=r(307);u(U.prototype,m.prototype),u(U,m);const N=()=>{},{errorOrDestroy:L}=A;function M(e,t,n){"boolean"!=typeof n&&(n=t instanceof r(672)),this.objectMode=!(!e||!e.objectMode),n&&(this.objectMode=this.objectMode||!(!e||!e.readableObjectMode)),this.highWaterMark=e?E(this,e,"readableHighWaterMark",n):x(!1),this.buffer=new S,this.length=0,this.pipes=[],this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.constructed=!0,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this[j]=null,this.errorEmitted=!1,this.emitClose=!e||!1!==e.emitClose,this.autoDestroy=!e||!1!==e.autoDestroy,this.destroyed=!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this.defaultEncoding=e&&e.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.multiAwaitDrain=!1,this.readingMore=!1,this.dataEmitted=!1,this.decoder=null,this.encoding=null,e&&e.encoding&&(this.decoder=new D(e.encoding),this.encoding=e.encoding)}function U(e){if(!(this instanceof U))return new U(e);const t=this instanceof r(672);this._readableState=new M(e,this,t),e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.construct&&(this._construct=e.construct),e.signal&&!t&&b(e.signal,this)),m.call(this,e),A.construct(this,(()=>{this._readableState.needReadable&&G(this,this._readableState)}))}function F(e,t,r,n){_("readableAddChunk",t);const o=e._readableState;let i;if(o.objectMode||("string"==typeof t?(r=r||o.defaultEncoding,o.encoding!==r&&(n&&o.encoding?t=w.from(t,r).toString(o.encoding):(t=w.from(t,r),r=""))):t instanceof w?r="":m._isUint8Array(t)?(t=m._uint8ArrayToBuffer(t),r=""):null!=t&&(i=new C("chunk",["string","Buffer","Uint8Array"],t))),i)L(e,i);else if(null===t)o.reading=!1,function(e,t){if(_("onEofChunk"),!t.ended){if(t.decoder){const e=t.decoder.end();e&&e.length&&(t.buffer.push(e),t.length+=t.objectMode?1:e.length)}t.ended=!0,t.sync?H(e):(t.needReadable=!1,t.emittedReadable=!0,W(e))}}(e,o);else if(o.objectMode||t&&t.length>0)if(n)if(o.endEmitted)L(e,new I);else{if(o.destroyed||o.errored)return!1;q(e,o,t,!0)}else if(o.ended)L(e,new P);else{if(o.destroyed||o.errored)return!1;o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||0!==t.length?q(e,o,t,!1):G(e,o)):q(e,o,t,!1)}else n||(o.reading=!1,G(e,o));return!o.ended&&(o.length0?(t.multiAwaitDrain?t.awaitDrainWriters.clear():t.awaitDrainWriters=null,t.dataEmitted=!0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&H(e)),G(e,t)}U.prototype.destroy=A.destroy,U.prototype._undestroy=A.undestroy,U.prototype._destroy=function(e,t){t(e)},U.prototype[g.captureRejectionSymbol]=function(e){this.destroy(e)},U.prototype.push=function(e,t){return F(this,e,t,!1)},U.prototype.unshift=function(e,t){return F(this,e,t,!0)},U.prototype.isPaused=function(){const e=this._readableState;return!0===e[j]||!1===e.flowing},U.prototype.setEncoding=function(e){const t=new D(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;const r=this._readableState.buffer;let n="";for(const e of r)n+=t.write(e);return r.clear(),""!==n&&r.push(n),this._readableState.length=n.length,this};function $(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:a(e)?t.flowing&&t.length?t.buffer.first().length:t.length:e<=t.length?e:t.ended?t.length:0}function H(e){const t=e._readableState;_("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(_("emitReadable",t.flowing),t.emittedReadable=!0,n.nextTick(W,e))}function W(e){const t=e._readableState;_("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||t.errored||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,Q(e)}function G(e,t){!t.readingMore&&t.constructed&&(t.readingMore=!0,n.nextTick(z,e,t))}function z(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!1===t[j]?t.flowing=!0:e.listenerCount("data")>0?e.resume():t.readableListening||(t.flowing=null)}function V(e){_("readable nexttick read 0"),e.read(0)}function Y(e,t){_("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),Q(e),t.flowing&&!t.reading&&e.read(0)}function Q(e){const t=e._readableState;for(_("flow",t.flowing);t.flowing&&null!==e.read(););}function J(e,t){"function"!=typeof e.read&&(e=U.wrap(e,{objectMode:!0}));const r=async function*(e,t){let r,n=N;function o(t){this===e?(n(),n=N):n=t}e.on("readable",o);const i=v(e,{writable:!1},(e=>{r=e?R(r,e):null,n(),n=N}));try{for(;;){const t=e.destroyed?null:e.read();if(null!==t)yield t;else{if(r)throw r;if(null===r)return;await new l(o)}}}catch(e){throw r=R(r,e),r}finally{!r&&!1===(null==t?void 0:t.destroyOnReturn)||void 0!==r&&!e._readableState.autoDestroy?(e.off("readable",o),i()):A.destroyer(e,null)}}(e,t);return r.stream=e,r}function Z(e,t){if(0===t.length)return null;let r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r}function X(e){const t=e._readableState;_("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,n.nextTick(ee,t,e))}function ee(e,t){if(_("endReadableNT",e.endEmitted,e.length),!e.errored&&!e.closeEmitted&&!e.endEmitted&&0===e.length)if(e.endEmitted=!0,t.emit("end"),t.writable&&!1===t.allowHalfOpen)n.nextTick(te,t);else if(e.autoDestroy){const e=t._writableState;(!e||e.autoDestroy&&(e.finished||!1===e.writable))&&t.destroy()}}function te(e){e.writable&&!e.writableEnded&&!e.destroyed&&e.end()}let re;function ne(){return void 0===re&&(re={}),re}U.prototype.read=function(e){_("read",e),void 0===e?e=NaN:i(e)||(e=s(e,10));const t=this._readableState,r=e;if(e>t.highWaterMark&&(t.highWaterMark=function(e){if(e>1073741824)throw new O("size","<= 1GiB",e);return e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,++e}(e)),0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&((0!==t.highWaterMark?t.length>=t.highWaterMark:t.length>0)||t.ended))return _("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?X(this):H(this),null;if(0===(e=$(e,t))&&t.ended)return 0===t.length&&X(this),null;let n,o=t.needReadable;if(_("need readable",o),(0===t.length||t.length-e0?Z(e,t):null,null===n?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.multiAwaitDrain?t.awaitDrainWriters.clear():t.awaitDrainWriters=null),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&X(this)),null===n||t.errorEmitted||t.closeEmitted||(t.dataEmitted=!0,this.emit("data",n)),n},U.prototype._read=function(e){throw new T("_read()")},U.prototype.pipe=function(e,t){const r=this,o=this._readableState;1===o.pipes.length&&(o.multiAwaitDrain||(o.multiAwaitDrain=!0,o.awaitDrainWriters=new p(o.awaitDrainWriters?[o.awaitDrainWriters]:[]))),o.pipes.push(e),_("pipe count=%d opts=%j",o.pipes.length,t);const i=t&&!1===t.end||e===n.stdout||e===n.stderr?g:a;function a(){_("onend"),e.end()}let s;o.endEmitted?n.nextTick(i):r.once("end",i),e.on("unpipe",(function t(n,i){_("onunpipe"),n===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,_("cleanup"),e.removeListener("close",d),e.removeListener("finish",f),s&&e.removeListener("drain",s),e.removeListener("error",l),e.removeListener("unpipe",t),r.removeListener("end",a),r.removeListener("end",g),r.removeListener("data",u),c=!0,s&&o.awaitDrainWriters&&(!e._writableState||e._writableState.needDrain)&&s())}));let c=!1;function h(){c||(1===o.pipes.length&&o.pipes[0]===e?(_("false write response, pause",0),o.awaitDrainWriters=e,o.multiAwaitDrain=!1):o.pipes.length>1&&o.pipes.includes(e)&&(_("false write response, pause",o.awaitDrainWriters.size),o.awaitDrainWriters.add(e)),r.pause()),s||(s=function(e,t){return function(){const r=e._readableState;r.awaitDrainWriters===t?(_("pipeOnDrain",1),r.awaitDrainWriters=null):r.multiAwaitDrain&&(_("pipeOnDrain",r.awaitDrainWriters.size),r.awaitDrainWriters.delete(t)),r.awaitDrainWriters&&0!==r.awaitDrainWriters.size||!e.listenerCount("data")||e.resume()}}(r,e),e.on("drain",s))}function u(t){_("ondata");const r=e.write(t);_("dest.write",r),!1===r&&h()}function l(t){if(_("onerror",t),g(),e.removeListener("error",l),0===e.listenerCount("error")){const r=e._writableState||e._readableState;r&&!r.errorEmitted?L(e,t):e.emit("error",t)}}function d(){e.removeListener("finish",f),g()}function f(){_("onfinish"),e.removeListener("close",d),g()}function g(){_("unpipe"),r.unpipe(e)}return r.on("data",u),y(e,"error",l),e.once("close",d),e.once("finish",f),e.emit("pipe",r),!0===e.writableNeedDrain?o.flowing&&h():o.flowing||(_("pipe resume"),r.resume()),e},U.prototype.unpipe=function(e){const t=this._readableState;if(0===t.pipes.length)return this;if(!e){const e=t.pipes;t.pipes=[],this.pause();for(let t=0;t0,!1!==o.flowing&&this.resume()):"readable"===e&&(o.endEmitted||o.readableListening||(o.readableListening=o.needReadable=!0,o.flowing=!1,o.emittedReadable=!1,_("on readable",o.length,o.reading),o.length?H(this):o.reading||n.nextTick(V,this))),r},U.prototype.addListener=U.prototype.on,U.prototype.removeListener=function(e,t){const r=m.prototype.removeListener.call(this,e,t);return"readable"===e&&n.nextTick(K,this),r},U.prototype.off=U.prototype.removeListener,U.prototype.removeAllListeners=function(e){const t=m.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||n.nextTick(K,this),t},U.prototype.resume=function(){const e=this._readableState;return e.flowing||(_("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,n.nextTick(Y,e,t))}(this,e)),e[j]=!1,this},U.prototype.pause=function(){return _("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(_("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[j]=!0,this},U.prototype.wrap=function(e){let t=!1;e.on("data",(r=>{!this.push(r)&&e.pause&&(t=!0,e.pause())})),e.on("end",(()=>{this.push(null)})),e.on("error",(e=>{L(this,e)})),e.on("close",(()=>{this.destroy()})),e.on("destroy",(()=>{this.destroy()})),this._read=()=>{t&&e.resume&&(t=!1,e.resume())};const r=h(e);for(let t=1;t{"use strict";const{MathFloor:n,NumberIsInteger:o}=r(61),{ERR_INVALID_ARG_VALUE:i}=r(381).codes;function a(e){return e?16:16384}e.exports={getHighWaterMark:function(e,t,r,s){const c=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,s,r);if(null!=c){if(!o(c)||c<0)throw new i(s?`options.${r}`:"options.highWaterMark",c);return n(c)}return a(e.objectMode)},getDefaultHighWaterMark:a}},161:(e,t,r)=>{"use strict";const{ObjectSetPrototypeOf:n,Symbol:o}=r(61);e.exports=h;const{ERR_METHOD_NOT_IMPLEMENTED:i}=r(381).codes,a=r(672),{getHighWaterMark:s}=r(457);n(h.prototype,a.prototype),n(h,a);const c=o("kCallback");function h(e){if(!(this instanceof h))return new h(e);const t=e?s(this,e,"readableHighWaterMark",!0):null;0===t&&(e={...e,highWaterMark:null,readableHighWaterMark:t,writableHighWaterMark:e.writableHighWaterMark||0}),a.call(this,e),this._readableState.sync=!1,this[c]=null,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",l)}function u(e){"function"!=typeof this._flush||this.destroyed?(this.push(null),e&&e()):this._flush(((t,r)=>{t?e?e(t):this.destroy(t):(null!=r&&this.push(r),this.push(null),e&&e())}))}function l(){this._final!==u&&u.call(this)}h.prototype._final=u,h.prototype._transform=function(e,t,r){throw new i("_transform()")},h.prototype._write=function(e,t,r){const n=this._readableState,o=this._writableState,i=n.length;this._transform(e,t,((e,t)=>{e?r(e):(null!=t&&this.push(t),o.ended||i===n.length||n.length{"use strict";const{Symbol:n,SymbolAsyncIterator:o,SymbolIterator:i}=r(61),a=n("kDestroyed"),s=n("kIsErrored"),c=n("kIsReadable"),h=n("kIsDisturbed");function u(e,t=!1){var r;return!(!e||"function"!=typeof e.pipe||"function"!=typeof e.on||t&&("function"!=typeof e.pause||"function"!=typeof e.resume)||e._writableState&&!1===(null===(r=e._readableState)||void 0===r?void 0:r.readable)||e._writableState&&!e._readableState)}function l(e){var t;return!(!e||"function"!=typeof e.write||"function"!=typeof e.on||e._readableState&&!1===(null===(t=e._writableState)||void 0===t?void 0:t.writable))}function p(e){return e&&(e._readableState||e._writableState||"function"==typeof e.write&&"function"==typeof e.on||"function"==typeof e.pipe&&"function"==typeof e.on)}function d(e){if(!p(e))return null;const t=e._writableState,r=e._readableState,n=t||r;return!!(e.destroyed||e[a]||null!=n&&n.destroyed)}function f(e){if(!l(e))return null;if(!0===e.writableEnded)return!0;const t=e._writableState;return(null==t||!t.errored)&&("boolean"!=typeof(null==t?void 0:t.ended)?null:t.ended)}function g(e,t){if(!u(e))return null;const r=e._readableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.endEmitted)?null:!!(r.endEmitted||!1===t&&!0===r.ended&&0===r.length))}function m(e){return e&&null!=e[c]?e[c]:"boolean"!=typeof(null==e?void 0:e.readable)?null:!d(e)&&u(e)&&e.readable&&!g(e)}function y(e){return"boolean"!=typeof(null==e?void 0:e.writable)?null:!d(e)&&l(e)&&e.writable&&!f(e)}function w(e){return"boolean"==typeof e._closed&&"boolean"==typeof e._defaultKeepAlive&&"boolean"==typeof e._removedConnection&&"boolean"==typeof e._removedContLen}function b(e){return"boolean"==typeof e._sent100&&w(e)}e.exports={kDestroyed:a,isDisturbed:function(e){var t;return!(!e||!(null!==(t=e[h])&&void 0!==t?t:e.readableDidRead||e.readableAborted))},kIsDisturbed:h,isErrored:function(e){var t,r,n,o,i,a,c,h,u,l;return!(!e||!(null!==(t=null!==(r=null!==(n=null!==(o=null!==(i=null!==(a=e[s])&&void 0!==a?a:e.readableErrored)&&void 0!==i?i:e.writableErrored)&&void 0!==o?o:null===(c=e._readableState)||void 0===c?void 0:c.errorEmitted)&&void 0!==n?n:null===(h=e._writableState)||void 0===h?void 0:h.errorEmitted)&&void 0!==r?r:null===(u=e._readableState)||void 0===u?void 0:u.errored)&&void 0!==t?t:null===(l=e._writableState)||void 0===l?void 0:l.errored))},kIsErrored:s,isReadable:m,kIsReadable:c,isClosed:function(e){if(!p(e))return null;if("boolean"==typeof e.closed)return e.closed;const t=e._writableState,r=e._readableState;return"boolean"==typeof(null==t?void 0:t.closed)||"boolean"==typeof(null==r?void 0:r.closed)?(null==t?void 0:t.closed)||(null==r?void 0:r.closed):"boolean"==typeof e._closed&&w(e)?e._closed:null},isDestroyed:d,isDuplexNodeStream:function(e){return!(!e||"function"!=typeof e.pipe||!e._readableState||"function"!=typeof e.on||"function"!=typeof e.write)},isFinished:function(e,t){return p(e)?!(!d(e)&&(!1!==(null==t?void 0:t.readable)&&m(e)||!1!==(null==t?void 0:t.writable)&&y(e))):null},isIterable:function(e,t){return null!=e&&(!0===t?"function"==typeof e[o]:!1===t?"function"==typeof e[i]:"function"==typeof e[o]||"function"==typeof e[i])},isReadableNodeStream:u,isReadableEnded:function(e){if(!u(e))return null;if(!0===e.readableEnded)return!0;const t=e._readableState;return!(!t||t.errored)&&("boolean"!=typeof(null==t?void 0:t.ended)?null:t.ended)},isReadableFinished:g,isReadableErrored:function(e){var t,r;return p(e)?e.readableErrored?e.readableErrored:null!==(t=null===(r=e._readableState)||void 0===r?void 0:r.errored)&&void 0!==t?t:null:null},isNodeStream:p,isWritable:y,isWritableNodeStream:l,isWritableEnded:f,isWritableFinished:function(e,t){if(!l(e))return null;if(!0===e.writableFinished)return!0;const r=e._writableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.finished)?null:!!(r.finished||!1===t&&!0===r.ended&&0===r.length))},isWritableErrored:function(e){var t,r;return p(e)?e.writableErrored?e.writableErrored:null!==(t=null===(r=e._writableState)||void 0===r?void 0:r.errored)&&void 0!==t?t:null:null},isServerRequest:function(e){var t;return"boolean"==typeof e._consuming&&"boolean"==typeof e._dumped&&void 0===(null===(t=e.req)||void 0===t?void 0:t.upgradeOrConnect)},isServerResponse:b,willEmitClose:function(e){if(!p(e))return null;const t=e._writableState,r=e._readableState,n=t||r;return!n&&b(e)||!!(n&&n.autoDestroy&&n.emitClose&&!1===n.closed)}}},304:(e,t,r)=>{const n=r(155),{ArrayPrototypeSlice:o,Error:i,FunctionPrototypeSymbolHasInstance:a,ObjectDefineProperty:s,ObjectDefineProperties:c,ObjectSetPrototypeOf:h,StringPrototypeToLowerCase:u,Symbol:l,SymbolHasInstance:p}=r(61);e.exports=D,D.WritableState=k;const{EventEmitter:d}=r(187),f=r(870).Stream,{Buffer:g}=r(764),m=r(195),{addAbortSignal:y}=r(196),{getHighWaterMark:w,getDefaultHighWaterMark:b}=r(457),{ERR_INVALID_ARG_TYPE:v,ERR_METHOD_NOT_IMPLEMENTED:_,ERR_MULTIPLE_CALLBACK:S,ERR_STREAM_CANNOT_PIPE:A,ERR_STREAM_DESTROYED:E,ERR_STREAM_ALREADY_FINISHED:x,ERR_STREAM_NULL_VALUES:R,ERR_STREAM_WRITE_AFTER_END:C,ERR_UNKNOWN_ENCODING:T}=r(381).codes,{errorOrDestroy:O}=m;function P(){}h(D.prototype,f.prototype),h(D,f);const I=l("kOnFinished");function k(e,t,n){"boolean"!=typeof n&&(n=t instanceof r(672)),this.objectMode=!(!e||!e.objectMode),n&&(this.objectMode=this.objectMode||!(!e||!e.writableObjectMode)),this.highWaterMark=e?w(this,e,"writableHighWaterMark",n):b(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;const o=!(!e||!1!==e.decodeStrings);this.decodeStrings=!o,this.defaultEncoding=e&&e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=M.bind(void 0,t),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,j(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!e||!1!==e.emitClose,this.autoDestroy=!e||!1!==e.autoDestroy,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[I]=[]}function j(e){e.buffered=[],e.bufferedIndex=0,e.allBuffers=!0,e.allNoop=!0}function D(e){const t=this instanceof r(672);if(!t&&!a(D,this))return new D(e);this._writableState=new k(e,this,t),e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final),"function"==typeof e.construct&&(this._construct=e.construct),e.signal&&y(e.signal,this)),f.call(this,e),m.construct(this,(()=>{const e=this._writableState;e.writing||$(this,e),W(this,e)}))}function B(e,t,r,o){const i=e._writableState;if("function"==typeof r)o=r,r=i.defaultEncoding;else{if(r){if("buffer"!==r&&!g.isEncoding(r))throw new T(r)}else r=i.defaultEncoding;"function"!=typeof o&&(o=P)}if(null===t)throw new R;if(!i.objectMode)if("string"==typeof t)!1!==i.decodeStrings&&(t=g.from(t,r),r="buffer");else if(t instanceof g)r="buffer";else{if(!f._isUint8Array(t))throw new v("chunk",["string","Buffer","Uint8Array"],t);t=f._uint8ArrayToBuffer(t),r="buffer"}let a;return i.ending?a=new C:i.destroyed&&(a=new E("write")),a?(n.nextTick(o,a),O(e,a,!0),a):(i.pendingcb++,function(e,t,r,n,o){const i=t.objectMode?1:r.length;t.length+=i;const a=t.lengthr.bufferedIndex&&$(e,r),o?null!==r.afterWriteTickInfo&&r.afterWriteTickInfo.cb===i?r.afterWriteTickInfo.count++:(r.afterWriteTickInfo={count:1,cb:i,stream:e,state:r},n.nextTick(U,r.afterWriteTickInfo)):F(e,r,1,i))):O(e,new S)}function U({stream:e,state:t,count:r,cb:n}){return t.afterWriteTickInfo=null,F(e,t,r,n)}function F(e,t,r,n){for(!t.ending&&!e.destroyed&&0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"));r-- >0;)t.pendingcb--,n();t.destroyed&&q(t),W(e,t)}function q(e){if(e.writing)return;for(let r=e.bufferedIndex;r1&&e._writev){t.pendingcb-=a-1;const n=t.allNoop?P:e=>{for(let t=s;t256?(r.splice(0,s),t.bufferedIndex=0):t.bufferedIndex=s}t.bufferProcessing=!1}function H(e){return e.ending&&!e.destroyed&&e.constructed&&0===e.length&&!e.errored&&0===e.buffered.length&&!e.finished&&!e.writing&&!e.errorEmitted&&!e.closeEmitted}function W(e,t,r){H(t)&&(function(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.finalCalled=!0,function(e,t){let r=!1;function o(o){if(r)O(e,null!=o?o:S());else if(r=!0,t.pendingcb--,o){const r=t[I].splice(0);for(let e=0;e{H(t)?G(e,t):t.pendingcb--}),e,t)):H(t)&&(t.pendingcb++,G(e,t))))}function G(e,t){t.pendingcb--,t.finished=!0;const r=t[I].splice(0);for(let e=0;e{"use strict";const{ArrayIsArray:n,ArrayPrototypeIncludes:o,ArrayPrototypeJoin:i,ArrayPrototypeMap:a,NumberIsInteger:s,NumberIsNaN:c,NumberMAX_SAFE_INTEGER:h,NumberMIN_SAFE_INTEGER:u,NumberParseInt:l,ObjectPrototypeHasOwnProperty:p,RegExpPrototypeExec:d,String:f,StringPrototypeToUpperCase:g,StringPrototypeTrim:m}=r(61),{hideStackFrames:y,codes:{ERR_SOCKET_BAD_PORT:w,ERR_INVALID_ARG_TYPE:b,ERR_INVALID_ARG_VALUE:v,ERR_OUT_OF_RANGE:_,ERR_UNKNOWN_SIGNAL:S}}=r(381),{normalizeEncoding:A}=r(87),{isAsyncFunction:E,isArrayBufferView:x}=r(87).types,R={},C=/^[0-7]+$/,T=y(((e,t,r=u,n=h)=>{if("number"!=typeof e)throw new b(t,"number",e);if(!s(e))throw new _(t,"an integer",e);if(en)throw new _(t,`>= ${r} && <= ${n}`,e)})),O=y(((e,t,r=-2147483648,n=2147483647)=>{if("number"!=typeof e)throw new b(t,"number",e);if(!s(e))throw new _(t,"an integer",e);if(en)throw new _(t,`>= ${r} && <= ${n}`,e)})),P=y(((e,t,r=!1)=>{if("number"!=typeof e)throw new b(t,"number",e);if(!s(e))throw new _(t,"an integer",e);const n=r?1:0,o=4294967295;if(eo)throw new _(t,`>= ${n} && <= ${o}`,e)}));function I(e,t){if("string"!=typeof e)throw new b(t,"string",e)}const k=y(((e,t,r)=>{if(!o(r,e)){const n=i(a(r,(e=>"string"==typeof e?`'${e}'`:f(e))),", ");throw new v(t,e,"must be one of: "+n)}}));function j(e,t,r){return null!=e&&p(e,t)?e[t]:r}const D=y(((e,t,r=null)=>{const o=j(r,"allowArray",!1),i=j(r,"allowFunction",!1);if(!j(r,"nullable",!1)&&null===e||!o&&n(e)||"object"!=typeof e&&(!i||"function"!=typeof e))throw new b(t,"Object",e)})),B=y(((e,t,r=0)=>{if(!n(e))throw new b(t,"Array",e);if(e.length{if(!x(e))throw new b(t,["Buffer","TypedArray","DataView"],e)})),L=y(((e,t)=>{if(void 0!==e&&(null===e||"object"!=typeof e||!("aborted"in e)))throw new b(t,"AbortSignal",e)})),M=y(((e,t)=>{if("function"!=typeof e)throw new b(t,"Function",e)})),U=y(((e,t)=>{if("function"!=typeof e||E(e))throw new b(t,"Function",e)})),F=y(((e,t)=>{if(void 0!==e)throw new b(t,"undefined",e)}));e.exports={isInt32:function(e){return e===(0|e)},isUint32:function(e){return e===e>>>0},parseFileMode:function(e,t,r){if(void 0===e&&(e=r),"string"==typeof e){if(null===d(C,e))throw new v(t,e,"must be a 32-bit unsigned integer or an octal string");e=l(e,8)}return P(e,t),e},validateArray:B,validateBoolean:function(e,t){if("boolean"!=typeof e)throw new b(t,"boolean",e)},validateBuffer:N,validateEncoding:function(e,t){const r=A(t),n=e.length;if("hex"===r&&n%2!=0)throw new v("encoding",t,`is invalid for data of length ${n}`)},validateFunction:M,validateInt32:O,validateInteger:T,validateNumber:function(e,t,r,n){if("number"!=typeof e)throw new b(t,"number",e);if(null!=r&&en||(null!=r||null!=n)&&c(e))throw new _(t,`${null!=r?`>= ${r}`:""}${null!=r&&null!=n?" && ":""}${null!=n?`<= ${n}`:""}`,e)},validateObject:D,validateOneOf:k,validatePlainFunction:U,validatePort:function(e,t="Port",r=!0){if("number"!=typeof e&&"string"!=typeof e||"string"==typeof e&&0===m(e).length||+e!=+e>>>0||e>65535||0===e&&!r)throw new w(t,e,r);return 0|e},validateSignalName:function(e,t="signal"){if(I(e,t),void 0===R[e]){if(void 0!==R[g(e)])throw new S(e+" (signals must use all capital letters)");throw new S(e)}},validateString:I,validateUint32:P,validateUndefined:F,validateUnion:function(e,t,r){if(!o(r,e))throw new b(t,`('${i(r,"|")}')`,e)},validateAbortSignal:L}},827:(e,t,r)=>{"use strict";const n=r(99),o=r(854),i=n.Readable.destroy;e.exports=n.Readable,e.exports._uint8ArrayToBuffer=n._uint8ArrayToBuffer,e.exports._isUint8Array=n._isUint8Array,e.exports.isDisturbed=n.isDisturbed,e.exports.isErrored=n.isErrored,e.exports.isReadable=n.isReadable,e.exports.Readable=n.Readable,e.exports.Writable=n.Writable,e.exports.Duplex=n.Duplex,e.exports.Transform=n.Transform,e.exports.PassThrough=n.PassThrough,e.exports.addAbortSignal=n.addAbortSignal,e.exports.finished=n.finished,e.exports.destroy=n.destroy,e.exports.destroy=i,e.exports.pipeline=n.pipeline,e.exports.compose=n.compose,Object.defineProperty(n,"promises",{configurable:!0,enumerable:!0,get:()=>o}),e.exports.Stream=n.Stream,e.exports.default=e.exports},381:(e,t,r)=>{"use strict";const{format:n,inspect:o,AggregateError:i}=r(87),a=globalThis.AggregateError||i,s=Symbol("kIsNodeError"),c=["string","function","number","object","Function","Object","boolean","bigint","symbol"],h=/^([A-Z][a-z0-9]*)+$/,u="__node_internal_",l={};function p(e,t){if(!e)throw new l.ERR_INTERNAL_ASSERTION(t)}function d(e){let t="",r=e.length;const n="-"===e[0]?1:0;for(;r>=n+4;r-=3)t=`_${e.slice(r-3,r)}${t}`;return`${e.slice(0,r)}${t}`}function f(e,t,r){r||(r=Error);class o extends r{constructor(...r){super(function(e,t,r){if("function"==typeof t)return p(t.length<=r.length,`Code: ${e}; The provided arguments length (${r.length}) does not match the required ones (${t.length}).`),t(...r);const o=(t.match(/%[dfijoOs]/g)||[]).length;return p(o===r.length,`Code: ${e}; The provided arguments length (${r.length}) does not match the required ones (${o}).`),0===r.length?t:n(t,...r)}(e,t,r))}toString(){return`${this.name} [${e}]: ${this.message}`}}Object.defineProperties(o.prototype,{name:{value:r.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${e}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),o.prototype.code=e,o.prototype[s]=!0,l[e]=o}function g(e){const t=u+e.name;return Object.defineProperty(e,"name",{value:t}),e}class m extends Error{constructor(e="The operation was aborted",t){if(void 0!==t&&"object"!=typeof t)throw new l.ERR_INVALID_ARG_TYPE("options","Object",t);super(e,t),this.code="ABORT_ERR",this.name="AbortError"}}f("ERR_ASSERTION","%s",Error),f("ERR_INVALID_ARG_TYPE",((e,t,r)=>{p("string"==typeof e,"'name' must be a string"),Array.isArray(t)||(t=[t]);let n="The ";e.endsWith(" argument")?n+=`${e} `:n+=`"${e}" ${e.includes(".")?"property":"argument"} `,n+="must be ";const i=[],a=[],s=[];for(const e of t)p("string"==typeof e,"All expected entries have to be of type string"),c.includes(e)?i.push(e.toLowerCase()):h.test(e)?a.push(e):(p("object"!==e,'The value "object" should be written as "Object"'),s.push(e));if(a.length>0){const e=i.indexOf("object");-1!==e&&(i.splice(i,e,1),a.push("Object"))}if(i.length>0){switch(i.length){case 1:n+=`of type ${i[0]}`;break;case 2:n+=`one of type ${i[0]} or ${i[1]}`;break;default:{const e=i.pop();n+=`one of type ${i.join(", ")}, or ${e}`}}(a.length>0||s.length>0)&&(n+=" or ")}if(a.length>0){switch(a.length){case 1:n+=`an instance of ${a[0]}`;break;case 2:n+=`an instance of ${a[0]} or ${a[1]}`;break;default:{const e=a.pop();n+=`an instance of ${a.join(", ")}, or ${e}`}}s.length>0&&(n+=" or ")}switch(s.length){case 0:break;case 1:s[0].toLowerCase()!==s[0]&&(n+="an "),n+=`${s[0]}`;break;case 2:n+=`one of ${s[0]} or ${s[1]}`;break;default:{const e=s.pop();n+=`one of ${s.join(", ")}, or ${e}`}}if(null==r)n+=`. Received ${r}`;else if("function"==typeof r&&r.name)n+=`. Received function ${r.name}`;else if("object"==typeof r){var u;null!==(u=r.constructor)&&void 0!==u&&u.name?n+=`. Received an instance of ${r.constructor.name}`:n+=`. Received ${o(r,{depth:-1})}`}else{let e=o(r,{colors:!1});e.length>25&&(e=`${e.slice(0,25)}...`),n+=`. Received type ${typeof r} (${e})`}return n}),TypeError),f("ERR_INVALID_ARG_VALUE",((e,t,r="is invalid")=>{let n=o(t);return n.length>128&&(n=n.slice(0,128)+"..."),`The ${e.includes(".")?"property":"argument"} '${e}' ${r}. Received ${n}`}),TypeError),f("ERR_INVALID_RETURN_VALUE",((e,t,r)=>{var n;return`Expected ${e} to be returned from the "${t}" function but got ${null!=r&&null!==(n=r.constructor)&&void 0!==n&&n.name?`instance of ${r.constructor.name}`:"type "+typeof r}.`}),TypeError),f("ERR_MISSING_ARGS",((...e)=>{let t;p(e.length>0,"At least one arg needs to be specified");const r=e.length;switch(e=(Array.isArray(e)?e:[e]).map((e=>`"${e}"`)).join(" or "),r){case 1:t+=`The ${e[0]} argument`;break;case 2:t+=`The ${e[0]} and ${e[1]} arguments`;break;default:{const r=e.pop();t+=`The ${e.join(", ")}, and ${r} arguments`}}return`${t} must be specified`}),TypeError),f("ERR_OUT_OF_RANGE",((e,t,r)=>{let n;return p(t,'Missing "range" argument'),Number.isInteger(r)&&Math.abs(r)>2**32?n=d(String(r)):"bigint"==typeof r?(n=String(r),(r>2n**32n||r<-(2n**32n))&&(n=d(n)),n+="n"):n=o(r),`The value of "${e}" is out of range. It must be ${t}. Received ${n}`}),RangeError),f("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),f("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),f("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),f("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),f("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),f("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),f("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),f("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),f("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),f("ERR_STREAM_WRITE_AFTER_END","write after end",Error),f("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),e.exports={AbortError:m,aggregateTwoErrors:g((function(e,t){if(e&&t&&e!==t){if(Array.isArray(t.errors))return t.errors.push(e),t;const r=new a([t,e],t.message);return r.code=t.code,r}return e||t})),hideStackFrames:g,codes:l}},61:e=>{"use strict";e.exports={ArrayIsArray:e=>Array.isArray(e),ArrayPrototypeIncludes:(e,t)=>e.includes(t),ArrayPrototypeIndexOf:(e,t)=>e.indexOf(t),ArrayPrototypeJoin:(e,t)=>e.join(t),ArrayPrototypeMap:(e,t)=>e.map(t),ArrayPrototypePop:(e,t)=>e.pop(t),ArrayPrototypePush:(e,t)=>e.push(t),ArrayPrototypeSlice:(e,t,r)=>e.slice(t,r),Error,FunctionPrototypeCall:(e,t,...r)=>e.call(t,...r),FunctionPrototypeSymbolHasInstance:(e,t)=>Function.prototype[Symbol.hasInstance].call(e,t),MathFloor:Math.floor,Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties:(e,t)=>Object.defineProperties(e,t),ObjectDefineProperty:(e,t,r)=>Object.defineProperty(e,t,r),ObjectGetOwnPropertyDescriptor:(e,t)=>Object.getOwnPropertyDescriptor(e,t),ObjectKeys:e=>Object.keys(e),ObjectSetPrototypeOf:(e,t)=>Object.setPrototypeOf(e,t),Promise,PromisePrototypeCatch:(e,t)=>e.catch(t),PromisePrototypeThen:(e,t,r)=>e.then(t,r),PromiseReject:e=>Promise.reject(e),ReflectApply:Reflect.apply,RegExpPrototypeTest:(e,t)=>e.test(t),SafeSet:Set,String,StringPrototypeSlice:(e,t,r)=>e.slice(t,r),StringPrototypeToLowerCase:e=>e.toLowerCase(),StringPrototypeToUpperCase:e=>e.toUpperCase(),StringPrototypeTrim:e=>e.trim(),Symbol,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,TypedArrayPrototypeSet:(e,t,r)=>e.set(t,r),Uint8Array}},87:(e,t,r)=>{"use strict";const n=r(764),o=Object.getPrototypeOf((async function(){})).constructor,i=globalThis.Blob||n.Blob,a=void 0!==i?function(e){return e instanceof i}:function(e){return!1};class s extends Error{constructor(e){if(!Array.isArray(e))throw new TypeError("Expected input to be an Array, got "+typeof e);let t="";for(let r=0;r{e=r,t=n})),resolve:e,reject:t}},promisify:e=>new Promise(((t,r)=>{e(((e,...n)=>e?r(e):t(...n)))})),debuglog:()=>function(){},format:(e,...t)=>e.replace(/%([sdifj])/g,(function(...[e,r]){const n=t.shift();return"f"===r?n.toFixed(6):"j"===r?JSON.stringify(n):"s"===r&&"object"==typeof n?`${n.constructor!==Object?n.constructor.name:""} {}`.trim():n.toString()})),inspect(e){switch(typeof e){case"string":if(e.includes("'")){if(!e.includes('"'))return`"${e}"`;if(!e.includes("`")&&!e.includes("${"))return`\`${e}\``}return`'${e}'`;case"number":return isNaN(e)?"NaN":Object.is(e,-0)?String(e):e;case"bigint":return`${String(e)}n`;case"boolean":case"undefined":return String(e);case"object":return"{}"}},types:{isAsyncFunction:e=>e instanceof o,isArrayBufferView:e=>ArrayBuffer.isView(e)},isBlob:a},e.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")},99:(e,t,r)=>{const{Buffer:n}=r(764),{ObjectDefineProperty:o,ObjectKeys:i,ReflectApply:a}=r(61),{promisify:{custom:s}}=r(87),{streamReturningOperators:c,promiseReturningOperators:h}=r(382),{codes:{ERR_ILLEGAL_CONSTRUCTOR:u}}=r(381),l=r(299),{pipeline:p}=r(946),{destroyer:d}=r(195),f=r(610),g=r(854),m=r(874),y=e.exports=r(870).Stream;y.isDisturbed=m.isDisturbed,y.isErrored=m.isErrored,y.isReadable=m.isReadable,y.Readable=r(911);for(const v of i(c)){const _=c[v];function w(...e){if(new.target)throw u();return y.Readable.from(a(_,this,e))}o(w,"name",{__proto__:null,value:_.name}),o(w,"length",{__proto__:null,value:_.length}),o(y.Readable.prototype,v,{__proto__:null,value:w,enumerable:!1,configurable:!0,writable:!0})}for(const S of i(h)){const A=h[S];function w(...e){if(new.target)throw u();return a(A,this,e)}o(w,"name",{__proto__:null,value:A.name}),o(w,"length",{__proto__:null,value:A.length}),o(y.Readable.prototype,S,{__proto__:null,value:w,enumerable:!1,configurable:!0,writable:!0})}y.Writable=r(304),y.Duplex=r(672),y.Transform=r(161),y.PassThrough=r(917),y.pipeline=p;const{addAbortSignal:b}=r(196);y.addAbortSignal=b,y.finished=f,y.destroy=d,y.compose=l,o(y,"promises",{__proto__:null,configurable:!0,enumerable:!0,get:()=>g}),o(p,s,{__proto__:null,enumerable:!0,get:()=>g.pipeline}),o(f,s,{__proto__:null,enumerable:!0,get:()=>g.finished}),y.Stream=y,y._isUint8Array=function(e){return e instanceof Uint8Array},y._uint8ArrayToBuffer=function(e){return n.from(e.buffer,e.byteOffset,e.byteLength)}},854:(e,t,r)=>{"use strict";const{ArrayPrototypePop:n,Promise:o}=r(61),{isIterable:i,isNodeStream:a}=r(874),{pipelineImpl:s}=r(946),{finished:c}=r(610);e.exports={finished:c,pipeline:function(...e){return new o(((t,r)=>{let o,c;const h=e[e.length-1];if(h&&"object"==typeof h&&!a(h)&&!i(h)){const t=n(e);o=t.signal,c=t.end}s(e,((e,n)=>{e?r(e):t(n)}),{signal:o,end:c})}))}}},998:(e,t)=>{var r;e.exports=function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=0)}([function(e,t,r){"use strict";r.r(t);var n=r(1);const o=new n.default;if(t.default=o,Object.getOwnPropertyNames(n.default.prototype).forEach((e=>{const t=o[e];"function"==typeof t&&(o[e]=t.bind(o))})),"undefined"!=typeof window)if("SolidAuthClient"in window)console.warn("Caution: multiple versions of solid-auth-client active.");else{let e=!1;Object.defineProperty(window,"SolidAuthClient",{enumerable:!0,get:()=>(e||(e=!0,console.warn("window.SolidAuthClient has been deprecated."),console.warn("Please use window.solid.auth instead.")),o)})}},function(e,t,r){"use strict";r.r(t),r.d(t,"default",(function(){return m}));var n=r(2),o=r.n(n),i=r(3),a=r.n(i),s=r(4),c=r(65),h=r(8),u=r(9),l=r(6),p=r(11);function d(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function f(e){for(var t=1;t0&&a.length>o&&!a.warned){a.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=a.length,s=c,console&&console.warn&&console.warn(s)}return e}function p(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function d(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},o=p.bind(n);return o.listener=r,n.wrapFn=o,o}function f(e,t,r){var n=e._events;if(void 0===n)return[];var o=n[t];return void 0===o?[]:"function"==typeof o?r?[o.listener||o]:[o]:r?function(e){for(var t=new Array(e.length),r=0;r0&&(a=t[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var c=o[e];if(void 0===c)return!1;if("function"==typeof c)i(c,this,t);else{var h=c.length,u=m(c,h);for(r=0;r=0;i--)if(r[i]===t||r[i].listener===t){a=r[i].listener,o=i;break}if(o<0)return this;0===o?r.shift():function(e,t){for(;t+1=0;n--)this.removeListener(e,t[n]);return this},s.prototype.listeners=function(e){return f(this,e,!0)},s.prototype.rawListeners=function(e){return f(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):g.call(e,t)},s.prototype.listenerCount=g,s.prototype.eventNames=function(){return this._eventsCount>0?n(this._events):[]}},function(e,t,r){"use strict";r.r(t),r.d(t,"authnFetch",(function(){return l}));var n=r(2),o=r.n(n),i=(r(5),r(6)),a=r(7),s=r(8),c=r(11);function h(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function u(e){for(var t=1;t{t[r]=e}));else for(const r in e)t[r]=e[r];return t}(n.headers);n=u(u({},n),{},{headers:e})}const o=await Object(s.getSession)(e);if(!o)return t(r,n);if(await p(e,r))return Object(c.fetchWithCredentials)(o,t,r,n);let i=await t(r,n);return 401===i.status&&(await Object(a.updateHostFromResponse)(e)(i),await p(e,r)&&(i=Object(c.fetchWithCredentials)(o,t,r,n))),i}async function p(e,t){const r=await Object(a.getHost)(e)(Object(i.toUrlString)(t));return null!=r&&r.requiresAuth}},function(e,t){e.exports=window.fetch},function(e,t,r){"use strict";function n(){return"undefined"!=typeof window?window.location:{href:"https://example.org/",pathname:"/",origin:"example.org"}}r.r(t),r.d(t,"currentUrl",(function(){return o})),r.d(t,"currentUrlNoParams",(function(){return i})),r.d(t,"navigateTo",(function(){return a})),r.d(t,"originOf",(function(){return s})),r.d(t,"toUrlString",(function(){return c}));const o=()=>n().href,i=()=>n().origin+n().pathname,a=e=>{n().href=e},s=e=>new URL(e).origin,c=e=>("string"!=typeof e&&(e="url"in e?e.url:e.toString()),new URL(e,o()).toString())},function(e,t,r){"use strict";r.r(t),r.d(t,"getHost",(function(){return u})),r.d(t,"saveHost",(function(){return l})),r.d(t,"updateHostFromResponse",(function(){return p}));var n=r(2),o=r.n(n),i=r(8),a=r(9),s=r(11);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function h(e){for(var t=1;t{const{host:r}=new URL(t),n=await Object(i.getSession)(e);if(n&&r===new URL(n.idp).host)return{url:r,requiresAuth:!0};const{hosts:o}=await Object(a.getData)(e);return o&&o[r]}}function l(e){return async({url:t,requiresAuth:r})=>{await Object(a.updateStorage)(e,(e=>h(h({},e),{},{hosts:h(h({},e.hosts),{},{[t]:{requiresAuth:r}})})))}}function p(e){return async t=>{if(s.requiresAuth(t)){const{host:r}=new URL(t.url);await l(e)({url:r,requiresAuth:!0})}}}},function(e,t,r){"use strict";r.r(t),r.d(t,"getSession",(function(){return c})),r.d(t,"saveSession",(function(){return h})),r.d(t,"clearSession",(function(){return u}));var n=r(2),o=r.n(n),i=r(9);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function s(e){for(var t=1;t(await Object(i.updateStorage)(e,(e=>s(s({},e),{},{session:t})))).session}async function u(e){await Object(i.updateStorage)(e,(e=>s(s({},e),{},{session:null})))}},function(e,t,r){"use strict";r.r(t),r.d(t,"NAMESPACE",(function(){return n})),r.d(t,"defaultStorage",(function(){return o})),r.d(t,"getData",(function(){return i})),r.d(t,"updateStorage",(function(){return a})),r.d(t,"asyncStorage",(function(){return s})),r.d(t,"memStorage",(function(){return c})),r.d(t,"ipcStorage",(function(){return h})),r(10);const n="solid-auth-client",o=()=>s("undefined"!=typeof window&&"localStorage"in window?window.localStorage:c());async function i(e){let t,r;try{t=await e.getItem(n),r=JSON.parse(t||"{}")}catch(e){console.warn("Could not deserialize data:",t),console.error(e),r={}}return r}async function a(e,t){const r=t(await i(e));return await e.setItem(n,JSON.stringify(r)),r}function s(e){return{getItem:t=>Promise.resolve(e.getItem(t)),setItem:(t,r)=>Promise.resolve(e.setItem(t,r)),removeItem:t=>Promise.resolve(e.removeItem(t))}}const c=()=>{const e={};return{getItem:t=>void 0===e[t]?null:e[t],setItem:(t,r)=>{e[t]=r},removeItem:t=>{delete e[t]}}};function h(e){return{getItem:t=>e.request("storage/getItem",t),setItem:(t,r)=>e.request("storage/setItem",t,r),removeItem:t=>e.request("storage/removeItem",t)}}},function(e,t,r){"use strict";r.r(t),r.d(t,"Server",(function(){return a})),r.d(t,"Client",(function(){return s}));var n=r(2),o=r.n(n);const i="solid-auth-client";class a{constructor(e,t,r){o()(this,"_clientWindow",void 0),o()(this,"_clientOrigin",void 0),o()(this,"_handler",void 0),o()(this,"_messageListener",void 0),this._clientWindow=e,this._clientOrigin=t,this._handler=r,this._messageListener=e=>this._handleMessage(e)}async _handleMessage({data:e,origin:t}){if(t!==this._clientOrigin)return void console.warn("solid-auth-client is listening to ".concat(this._clientOrigin," ")+"so ignored a message received from ".concat(t,"."));const r=e&&e[i];if(r&&r.method){const{id:e,method:t,args:n}=r,o=await this._handler(t,...n);this._clientWindow.postMessage({[i]:{id:e,ret:o}},this._clientOrigin)}}start(){window.addEventListener("message",this._messageListener)}stop(){window.removeEventListener("message",this._messageListener)}}class s{constructor(e,t){o()(this,"_serverWindow",void 0),o()(this,"_serverOrigin",void 0),this._serverWindow=e,this._serverOrigin=t}request(e,...t){const r=Math.random();return this._serverWindow.postMessage({[i]:{id:r,method:e,args:t}},this._serverOrigin),new Promise(((e,t)=>{window.addEventListener("message",o);const n=setTimeout((()=>{t(new Error("Could not connect to main window.")),window.removeEventListener("message",o)}),2e3);function o({data:t}){const a=t&&t[i];a&&a.id===r&&a.hasOwnProperty("ret")&&(e(a.ret),clearTimeout(n),window.removeEventListener("message",o))}}))}}},function(e,t,r){"use strict";r.r(t),r.d(t,"login",(function(){return m})),r.d(t,"currentSession",(function(){return y})),r.d(t,"logout",(function(){return w})),r.d(t,"getRegisteredRp",(function(){return b})),r.d(t,"requiresAuth",(function(){return _})),r.d(t,"fetchWithCredentials",(function(){return S}));var n=r(12),o=r.n(n),i=r(2),a=r.n(i),s=r(14),c=r(18),h=r.n(c),u=r(61),l=r.n(u),p=r(6),d=r(9);function f(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function g(e){for(var t=1;tg(g({},e),{},{appHashFragment:window.location.hash})))}(t.storage),async function(e,{callbackUri:t,storage:r}){const n=await Object(d.getData)(r),o=await e.createRequest({redirect_uri:t},n);return await Object(d.updateStorage)(r,(()=>n)),Object(p.navigateTo)(o)}(r,t)}catch(e){return console.warn("Error logging in with WebID-OIDC"),console.error(e),null}}async function y(e=Object(d.defaultStorage)()){try{const t=await v(e);if(!t)return null;const r=Object(p.currentUrl)();if(!/#(.*&)?access_token=/.test(r))return null;window.location.hash="",await async function(e){await Object(d.updateStorage)(e,(e=>{let{appHashFragment:t=""}=e,r=o()(e,["appHashFragment"]);return window.location.hash=t,r}))}(e);const n=await Object(d.getData)(e),i=await t.validateResponse(r,n);return i?g(g({},i),{},{webId:i.idClaims.sub,idp:i.issuer}):null}catch(e){return console.warn("Error finding a WebID-OIDC session"),console.error(e),null}}async function w(e,t){const r=await v(e);if(r)try{await r.logout();try{await t("/.well-known/solid/logout",{credentials:"include"})}catch(e){console.info("Couldn't find /.well-known/solid/logout, this is harmless.")}}catch(e){console.warn("Error logging out of the WebID-OIDC session"),console.error(e)}}async function b(e,t){let r=await v(t.storage);return r&&r.provider.url===e&&r.registration.redirect_uris.includes(t.callbackUri)||(r=await function(e,t){const{storage:r,callbackUri:n}=t,o="id_token token",i={};Object.entries(t).filter((([e,t])=>e.startsWith("clientName#"))).forEach((([e,t])=>i[e.replace("clientName#","client_name#")]=t));const a={logo_uri:t.logoUri,contacts:t.contacts,client_name:t.clientName},s=g(g({issuer:e,grant_types:["implicit"],redirect_uris:[n],response_types:[o],scope:"openid profile"},i),a),c={defaults:{authenticate:{redirect_uri:n,response_type:o,display:"page",scope:["openid"]}},store:r};return h.a.register(e,s,c)}(e,t),await async function(e,t,r){return await Object(d.updateStorage)(e,(e=>g(g({},e),{},{rpConfig:r}))),r}(t.storage,0,r)),r}async function v(e){const t=await Object(d.getData)(e),{rpConfig:r}=t;return r?(r.store=e,h.a.from(r)):null}function _(e){if(401!==e.status)return!1;const t=e.headers.get("www-authenticate");if(!t)return!1;const r=s.parse(t);return"Bearer"===r.scheme&&r.params&&"openid webid"===r.params.scope}async function S(e,t,r,n){const o=(n?n.headers:r.headers)||{},i=await l.a.issueFor(Object(p.toUrlString)(r),e);return o.authorization="Bearer ".concat(i),t(r,g(g({},n),{},{credentials:"include",headers:o}))}},function(e,t,r){var n=r(13);e.exports=function(e,t){if(null==e)return{};var r,o,i=n(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}},function(e,t){e.exports=function(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n=0||(o[r]=e[r]);return o}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"format",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return o.default}});var n=i(r(15)),o=i(r(17));function i(e){return e&&e.__esModule?e:{default:e}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(16);function o(e){return function(e){if(Array.isArray(e)){for(var t=0,r=new Array(e.length);t@,;:\\"/?={}\[\]\u0020\u0009]+$/,o=function(e){return"string"==typeof e&&n.test(e)};t.isToken=o;var i=o;t.isScheme=i,t.quote=function(e){return`"${e.replace(/"/g,'\\"')}"`},t.unquote=function(e){return e.substr(1,e.length-2).replace(/\\"/g,'"')}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(16),o=/((?:[a-zA-Z0-9._~+\/-]+=*(?:\s+|$))|[^\u0000-\u001F\u007F()<>@,;:\\"/?={}\[\]\u0020\u0009]+)(?:=([^\\"=\s,]+|"(?:[^"\\]|\\.)*"))?/g,i=function(e,t){var r='"'===t.charAt(0)?(0,n.unquote)(t):t.trim();return Array.isArray(e)?e.concat(r):"string"==typeof e?[e,r]:r};t.default=function(e){if("string"!=typeof e)throw new TypeError("Header value must be a string.");var t=e.indexOf(" "),r=e.substr(0,t);if(!(0,n.isScheme)(r))throw new TypeError(`Invalid scheme ${r}`);return function(e,t){for(var r=null,n={};;){var a=o.exec(t);if(null===a)break;a[2]?n[a[1]]=i(n[a[1]],a[2]):r=i(r,a[1])}return{scheme:e,params:n,token:r}}(r,e.substr(t))}},function(e,t,r){"use strict";e.exports=r(19)},function(e,t,r){(function(t){const n=r(21),o=r(5),{URL:i}=r(27),a=o.Headers?o.Headers:t.Headers,{JWKSet:s}=r(28),c=r(55),h=r(57),u=r(60),l=r(56);class p{constructor({provider:e={},defaults:t,registration:r={},store:n={}}={}){this.provider=e,this.defaults=t||{popToken:!1,authenticate:{response_type:"id_token token",display:"page",scope:["openid"]}},this.registration=r,this.store=n}static async from(e){const t=new p(e),r=t.validate();if(!r.valid)throw r.error;const n=t.provider.jwks;return n?s.importKeys(n).then((e=>(t.provider.jwks=e,t))):t.jwks().then((()=>t))}static register(e,t,r,o,i){const a=new p({provider:{url:e},defaults:Object.assign({},r.defaults),store:r.store});return Promise.resolve().then((()=>a.discover())).then((()=>a.jwks())).then((()=>(n(a.provider.configuration,"OpenID Configuration is not initialized."),a.provider.configuration.registration_endpoint?a.register(t):a.getRegistration(t,o,i)))).then((()=>a))}validate(){return this.provider&&this.provider.url?{valid:!0}:{valid:!1,error:new Error("Provider url is required.")}}discover(){try{let e=this.provider.url;n(e,'RelyingParty provider must define "url"');let t=new i(e);return t.pathname=".well-known/openid-configuration",o(t.toString()).then(u("Error fetching openid configuration")).then((e=>e.json().then((e=>this.provider.configuration=e))))}catch(e){return Promise.reject(e)}}register(e){try{let t=this.provider.configuration;n(t,"OpenID Configuration is not initialized."),n(t.registration_endpoint,"OpenID Configuration is missing registration_endpoint.");let r=t.registration_endpoint,i="post",s=new a({"Content-Type":"application/json"}),c=this.defaults.register,h=JSON.stringify(Object.assign({},c,e));return o(r,{method:i,headers:s,body:h}).then(u("Error registering client")).then((e=>e.json().then((e=>this.registration=e))))}catch(e){return Promise.reject(e)}}serialize(){return JSON.stringify(this)}getRegistration(e,t,r){return Promise.resolve().then((()=>this.registration=r.getRegistration(t))).catch((e=>{throw e}))}jwks(){try{let e=this.provider.configuration;n(e,"OpenID Configuration is not initialized."),n(e.jwks_uri,"OpenID Configuration is missing jwks_uri.");let t=e.jwks_uri;return o(t).then(u("Error resolving provider keys")).then((e=>e.json().then((e=>s.importKeys(e))).then((e=>this.provider.jwks=e))))}catch(e){return Promise.reject(e)}}createRequest(e,t){return c.create(this,e,t||this.store)}validateResponse(e,t=this.store){let r;r=e.match(/^http(s?):\/\//)?{rp:this,redirect:e,session:t}:{rp:this,body:e,session:t};const n=new h(r);return h.validateResponse(n)}userinfo(e){try{let t=this.provider.configuration;n(t,"OpenID Configuration is not initialized."),n(t.userinfo_endpoint,"OpenID Configuration is missing userinfo_endpoint."),e=e||this.store.access_token,n(e,"Missing access token.");let r=t.userinfo_endpoint,i=new a({"Content-Type":"application/json",Authorization:`Bearer ${e}`});return o(r,{headers:i}).then(u("Error fetching userinfo")).then((e=>e.json()))}catch(e){return Promise.reject(e)}}logoutRequest(e={}){const{id_token_hint:t,post_logout_redirect_uri:r,state:o}=e;let a;if(n(this.provider,"OpenID Configuration is not initialized"),a=this.provider.configuration,n(a,"OpenID Configuration is not initialized"),!a.end_session_endpoint)return console.log(`OpenId Configuration for ${a.issuer} is missing end_session_endpoint`),null;if(r&&!t)throw new Error("id_token_hint is required when using post_logout_redirect_uri");const s={};t&&(s.id_token_hint=t),r&&(s.post_logout_redirect_uri=r),o&&(s.state=o);const c=new i(a.end_session_endpoint);return c.search=l.encode(s),c.href}logout(){let e;try{n(this.provider,"OpenID Configuration is not initialized."),e=this.provider.configuration,n(e,"OpenID Configuration is not initialized.")}catch(e){return Promise.reject(e)}if(!e.end_session_endpoint)return this.clearSession(),Promise.resolve(void 0);let t=e.end_session_endpoint;return o(t,{method:"get",credentials:"include"}).then(u("Error logging out")).then((()=>this.clearSession()))}clearSession(){let e=this.store;e&&delete e[d]}popTokenFor(e,t){return PoPToken.issueFor(e,t)}}const d="oidc.session.privateKey";p.SESSION_PRIVATE_KEY=d,e.exports=p}).call(this,r(20))},function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){"use strict";(function(t){var n=r(22);function o(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,o=0,i=Math.min(r,n);o=0;h--)if(u[h]!==l[h])return!1;for(h=u.length-1;h>=0;h--)if(!b(e[s=u[h]],t[s],r,n))return!1;return!0}(e,t,r,n))}return r?e===t:e==t}function v(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function _(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function S(e,t,r,n){var o;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof r&&(n=r,r=null),o=function(e){var t;try{e()}catch(e){t=e}return t}(t),n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!o&&y(o,r,"Missing expected exception"+n);var i="string"==typeof n,s=!e&&o&&!r;if((!e&&a.isError(o)&&i&&_(o,r)||s)&&y(o,r,"Got unwanted exception"+n),e&&o&&r&&!_(o,r)||!e&&o)throw o}p.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return g(m(e.actual),128)+" "+e.operator+" "+g(m(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||y;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var n=r.stack,o=f(t),i=n.indexOf("\n"+o);if(i>=0){var a=n.indexOf("\n",i+1);n=n.substring(a+1)}this.stack=n}}},a.inherits(p.AssertionError,Error),p.fail=y,p.ok=w,p.equal=function(e,t,r){e!=t&&y(e,t,r,"==",p.equal)},p.notEqual=function(e,t,r){e==t&&y(e,t,r,"!=",p.notEqual)},p.deepEqual=function(e,t,r){b(e,t,!1)||y(e,t,r,"deepEqual",p.deepEqual)},p.deepStrictEqual=function(e,t,r){b(e,t,!0)||y(e,t,r,"deepStrictEqual",p.deepStrictEqual)},p.notDeepEqual=function(e,t,r){b(e,t,!1)&&y(e,t,r,"notDeepEqual",p.notDeepEqual)},p.notDeepStrictEqual=function e(t,r,n){b(t,r,!0)&&y(t,r,n,"notDeepStrictEqual",e)},p.strictEqual=function(e,t,r){e!==t&&y(e,t,r,"===",p.strictEqual)},p.notStrictEqual=function(e,t,r){e===t&&y(e,t,r,"!==",p.notStrictEqual)},p.throws=function(e,t,r){S(!0,e,t,r)},p.doesNotThrow=function(e,t,r){S(!1,e,t,r)},p.ifError=function(e){if(e)throw e},p.strict=n((function e(t,r){t||y(t,!0,r,"==",e)}),p,{equal:p.strictEqual,deepEqual:p.deepStrictEqual,notEqual:p.notStrictEqual,notDeepEqual:p.notDeepStrictEqual}),p.strict.strict=p.strict;var A=Object.keys||function(e){var t=[];for(var r in e)s.call(e,r)&&t.push(r);return t}}).call(this,r(20))},function(e,t,r){"use strict";var n=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var r,a,s=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(e),c=1;c=i)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}})),c=n[r];r=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),f(r)?n.showHidden=r:r&&t._extend(n,r),w(n.showHidden)&&(n.showHidden=!1),w(n.depth)&&(n.depth=2),w(n.colors)&&(n.colors=!1),w(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=c),u(n,e,n.depth)}function c(e,t){var r=s.styles[t];return r?"["+s.colors[r][0]+"m"+e+"["+s.colors[r][1]+"m":e}function h(e,t){return e}function u(e,r,n){if(e.customInspect&&r&&A(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var o=r.inspect(n,e);return y(o)||(o=u(e,o,n)),o}var i=function(e,t){if(w(t))return e.stylize("undefined","undefined");if(y(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return m(t)?e.stylize(""+t,"number"):f(t)?e.stylize(""+t,"boolean"):g(t)?e.stylize("null","null"):void 0}(e,r);if(i)return i;var a=Object.keys(r),s=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),S(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return l(r);if(0===a.length){if(A(r)){var c=r.name?": "+r.name:"";return e.stylize("[Function"+c+"]","special")}if(b(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(_(r))return e.stylize(Date.prototype.toString.call(r),"date");if(S(r))return l(r)}var h,v="",E=!1,x=["{","}"];return d(r)&&(E=!0,x=["[","]"]),A(r)&&(v=" [Function"+(r.name?": "+r.name:"")+"]"),b(r)&&(v=" "+RegExp.prototype.toString.call(r)),_(r)&&(v=" "+Date.prototype.toUTCString.call(r)),S(r)&&(v=" "+l(r)),0!==a.length||E&&0!=r.length?n<0?b(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),h=E?function(e,t,r,n,o){for(var i=[],a=0,s=t.length;a60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}(h,v,x)):x[0]+v+x[1]}function l(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,t,r,n,o,i){var a,s,c;if((c=Object.getOwnPropertyDescriptor(t,o)||{value:t[o]}).get?s=c.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):c.set&&(s=e.stylize("[Setter]","special")),C(n,o)||(a="["+o+"]"),s||(e.seen.indexOf(c.value)<0?(s=g(r)?u(e,c.value,null):u(e,c.value,r-1)).indexOf("\n")>-1&&(s=i?s.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+s.split("\n").map((function(e){return" "+e})).join("\n")):s=e.stylize("[Circular]","special")),w(a)){if(i&&o.match(/^\d+$/))return s;(a=JSON.stringify(""+o)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function d(e){return Array.isArray(e)}function f(e){return"boolean"==typeof e}function g(e){return null===e}function m(e){return"number"==typeof e}function y(e){return"string"==typeof e}function w(e){return void 0===e}function b(e){return v(e)&&"[object RegExp]"===E(e)}function v(e){return"object"==typeof e&&null!==e}function _(e){return v(e)&&"[object Date]"===E(e)}function S(e){return v(e)&&("[object Error]"===E(e)||e instanceof Error)}function A(e){return"function"==typeof e}function E(e){return Object.prototype.toString.call(e)}function x(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(r){if(w(i)&&(i=e.env.NODE_DEBUG||""),r=r.toUpperCase(),!a[r])if(new RegExp("\\b"+r+"\\b","i").test(i)){var n=e.pid;a[r]=function(){var e=t.format.apply(t,arguments);console.error("%s %d: %s",r,n,e)}}else a[r]=function(){};return a[r]},t.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=d,t.isBoolean=f,t.isNull=g,t.isNullOrUndefined=function(e){return null==e},t.isNumber=m,t.isString=y,t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=w,t.isRegExp=b,t.isObject=v,t.isDate=_,t.isError=S,t.isFunction=A,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(25);var R=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function C(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){var e,r;console.log("%s - %s",(r=[x((e=new Date).getHours()),x(e.getMinutes()),x(e.getSeconds())].join(":"),[e.getDate(),R[e.getMonth()],r].join(" ")),t.format.apply(t,arguments))},t.inherits=r(26),t._extend=function(e,t){if(!t||!v(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var T="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function O(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(T&&e[T]){var t;if("function"!=typeof(t=e[T]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,T,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise((function(e,n){t=e,r=n})),o=[],i=0;i1)for(var r=1;r-1),a=!!e.msCrypto&&!i,s=!t.subtle&&!!t.webkitSubtle;if(a||s){var c={KoZIhvcNAQEB:"1.2.840.113549.1.1.1"},h={"1.2.840.113549.1.1.1":"KoZIhvcNAQEB"};if(["generateKey","importKey","unwrapKey"].forEach((function(e){var n=r[e];r[e]=function(o,i,c){var h,u,b,A,E,x=[].slice.call(arguments);switch(e){case"generateKey":h=g(o),u=i,b=c;break;case"importKey":h=g(c),u=x[3],b=x[4],"jwk"===o&&((i=y(i)).alg||(i.alg=m(h)),i.key_ops||(i.key_ops="oct"!==i.kty?"d"in i?b.filter(S):b.filter(_):b.slice()),x[1]=(E=y(i),a&&(E.extractable=E.ext,delete E.ext),d(unescape(encodeURIComponent(JSON.stringify(E)))).buffer));break;case"unwrapKey":h=x[4],u=x[5],b=x[6],x[2]=c._key}if("generateKey"===e&&"HMAC"===h.name&&h.hash)return h.length=h.length||{"SHA-1":512,"SHA-256":512,"SHA-384":1024,"SHA-512":1024}[h.hash.name],r.importKey("raw",t.getRandomValues(new Uint8Array(h.length+7>>3)),h,u,b);if(s&&"generateKey"===e&&"RSASSA-PKCS1-v1_5"===h.name&&(!h.modulusLength||h.modulusLength>=2048))return(o=g(o)).name="RSAES-PKCS1-v1_5",delete o.hash,r.generateKey(o,!0,["encrypt","decrypt"]).then((function(e){return Promise.all([r.exportKey("jwk",e.publicKey),r.exportKey("jwk",e.privateKey)])})).then((function(e){return e[0].alg=e[1].alg=m(h),e[0].key_ops=b.filter(_),e[1].key_ops=b.filter(S),Promise.all([r.importKey("jwk",e[0],h,!0,e[0].key_ops),r.importKey("jwk",e[1],h,u,e[1].key_ops)])})).then((function(e){return{publicKey:e[0],privateKey:e[1]}}));if((s||a&&"SHA-1"===(h.hash||{}).name)&&"importKey"===e&&"jwk"===o&&"HMAC"===h.name&&"oct"===i.kty)return r.importKey("raw",d(p(i.k)),c,x[3],x[4]);if(s&&"importKey"===e&&("spki"===o||"pkcs8"===o))return r.importKey("jwk",function(e){var t=w(e),r=!1;t.length>2&&(r=!0,t.shift());var n={ext:!0};if("1.2.840.113549.1.1.1"!==t[0][0])throw new TypeError("Unsupported key type");var o=["n","e","d","p","q","dp","dq","qi"],i=w(t[1]);r&&i.shift();for(var a=0;a2&&(n=!0,i.unshift(new Uint8Array([0]))),r[0][0]="1.2.840.113549.1.1.1",t=i,r.push(new Uint8Array(b(t)).buffer),n?r.unshift(new Uint8Array([0])):r[1]={tag:3,value:r[1]},new Uint8Array(b(r)).buffer}(y(e))}))),c}})),["encrypt","decrypt","sign","verify"].forEach((function(e){var t=r[e];r[e]=function(n,o,i,s){if(a&&(!i.byteLength||s&&!s.byteLength))throw new Error("Empy input is not allowed");var c,h=[].slice.call(arguments),u=g(n);if(a&&"decrypt"===e&&"AES-GCM"===u.name){var l=n.tagLength>>3;h[2]=(i.buffer||i).slice(0,i.byteLength-l),n.tag=(i.buffer||i).slice(i.byteLength-l)}h[1]=o._key;try{c=t.apply(r,h)}catch(e){return Promise.reject(e)}return a&&(c=new Promise((function(t,r){c.onabort=c.onerror=function(e){r(e)},c.oncomplete=function(r){if(r=r.target.result,"encrypt"===e&&r instanceof AesGcmEncryptResult){var n=r.ciphertext,o=r.tag;(r=new Uint8Array(n.byteLength+o.byteLength)).set(new Uint8Array(n),0),r.set(new Uint8Array(o),n.byteLength),r=r.buffer}t(r)}}))),c}})),a){var u=r.digest;r.digest=function(e,t){if(!t.byteLength)throw new Error("Empy input is not allowed");var n;try{n=u.call(r,e,t)}catch(e){return Promise.reject(e)}return n=new Promise((function(e,t){n.onabort=n.onerror=function(e){t(e)},n.oncomplete=function(t){e(t.target.result)}}))},e.crypto=Object.create(t,{getRandomValues:{value:function(e){return t.getRandomValues(e)}},subtle:{value:r}}),e.CryptoKey=v}s&&(t.subtle=r,e.Crypto=n,e.SubtleCrypto=o,e.CryptoKey=v)}}}function l(e){return btoa(e).replace(/\=+$/,"").replace(/\+/g,"-").replace(/\//g,"_")}function p(e){return e=(e+="===").slice(0,-e.length%4),atob(e.replace(/-/g,"+").replace(/_/g,"/"))}function d(e){for(var t=new Uint8Array(e.length),r=0;re.length)throw new RangeError("Malformed DER");var r,n=e[t.pos++],o=e[t.pos++];if(o>=128){if(o&=127,t.end-t.pos=128){var s=n;for(n=4,t.splice(o,0,s>>24&255,s>>16&255,s>>8&255,255&s);n>1&&!(s>>24);)s<<=8,n--;n<4&&t.splice(o,4-n),n|=128}return t.splice(o-2,2,r,n),t}function v(e,t,r,n){Object.defineProperties(this,{_key:{value:e},type:{value:e.type,enumerable:!0},extractable:{value:void 0===r?e.extractable:r,enumerable:!0},algorithm:{value:void 0===t?e.algorithm:t,enumerable:!0},usages:{value:void 0===n?e.usages:n,enumerable:!0}})}function _(e){return"verify"===e||"encrypt"===e||"wrapKey"===e}function S(e){return"sign"===e||"decrypt"===e||"unwrapKey"===e}}(a)}.apply(t,[]),void 0===r||(e.exports=r),o.default={}},function(e,t,r){const n=r(33),{NotSupportedError:o}=r(48);e.exports=class{static async sign(e,t,r){let i=n.normalize("sign",e);return i instanceof Error?Promise.reject(new o(e)):i.sign(t,r)}static async verify(e,t,r,i){let a=n.normalize("verify",e);return a instanceof Error?Promise.reject(new o(e)):a.verify(t,r,i)}static async importKey(e){return n.normalize("importKey",e.alg).importKey(e)}}},function(e,t,r){const n=r(34),o=r(35),i=r(45),a=new(r(46));a.define("HS256","sign",new o({name:"HMAC",hash:{name:"SHA-256"}})),a.define("HS384","sign",new o({name:"HMAC",hash:{name:"SHA-384"}})),a.define("HS512","sign",new o({name:"HMAC",hash:{name:"SHA-512"}})),a.define("RS256","sign",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}})),a.define("RS384","sign",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-384"}})),a.define("RS512","sign",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-512"}})),a.define("none","sign",new n({})),a.define("HS256","verify",new o({name:"HMAC",hash:{name:"SHA-256"}})),a.define("HS384","verify",new o({name:"HMAC",hash:{name:"SHA-384"}})),a.define("HS512","verify",new o({name:"HMAC",hash:{name:"SHA-512"}})),a.define("RS256","verify",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}})),a.define("RS384","verify",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-384"}})),a.define("RS512","verify",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-512"}})),a.define("none","verify",new n({})),a.define("RS256","importKey",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}})),a.define("RS384","importKey",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-384"}})),a.define("RS512","importKey",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-512"}})),e.exports=a},function(e,t){e.exports=class{sign(){return Promise.resolve("")}verify(){}}},function(e,t,r){"use strict";(function(t){const n=r(40),o=r(30),i=r(43);e.exports=class{constructor(e){this.params=e}sign(e,r){let a=this.params;return r=(new i).encode(r),o.subtle.sign(a,e,r).then((e=>n(t.from(e))))}verify(e,t,r){let a=this.params;return"string"==typeof t&&(t=Uint8Array.from(n.toBuffer(t))),"string"==typeof r&&(r=(new i).encode(r)),o.subtle.verify(a,e,t,r)}assertSufficientKeyLength(e){if(e.length=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function f(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return q(e).length;default:if(n)return F(e).length;t=(""+t).toLowerCase(),n=!0}}function g(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return P(this,t,r);case"utf8":case"utf-8":return R(this,t,r);case"ascii":return T(this,t,r);case"latin1":case"binary":return O(this,t,r);case"base64":return x(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function m(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function y(e,t,r,n,o){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=o?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(o)return-1;r=e.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof t&&(t=c.from(t,n)),c.isBuffer(t))return 0===t.length?-1:w(e,t,r,n,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):w(e,[t],r,n,o);throw new TypeError("val must be string, number or Buffer")}function w(e,t,r,n,o){var i,a=1,s=e.length,c=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,c/=2,r/=2}function h(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){var u=-1;for(i=r;is&&(r=s-c),i=r;i>=0;i--){for(var l=!0,p=0;po&&(n=o):n=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");n>i/2&&(n=i/2);for(var a=0;a>8,o=r%256,i.push(o),i.push(n);return i}(t,e.length-r),e,r,n)}function x(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function R(e,t,r){r=Math.min(e.length,r);for(var n=[],o=t;o239?4:h>223?3:h>191?2:1;if(o+l<=r)switch(l){case 1:h<128&&(u=h);break;case 2:128==(192&(i=e[o+1]))&&(c=(31&h)<<6|63&i)>127&&(u=c);break;case 3:i=e[o+1],a=e[o+2],128==(192&i)&&128==(192&a)&&(c=(15&h)<<12|(63&i)<<6|63&a)>2047&&(c<55296||c>57343)&&(u=c);break;case 4:i=e[o+1],a=e[o+2],s=e[o+3],128==(192&i)&&128==(192&a)&&128==(192&s)&&(c=(15&h)<<18|(63&i)<<12|(63&a)<<6|63&s)>65535&&c<1114112&&(u=c)}null===u?(u=65533,l=1):u>65535&&(u-=65536,n.push(u>>>10&1023|55296),u=56320|1023&u),n.push(u),o+=l}return function(e){var t=e.length;if(t<=C)return String.fromCharCode.apply(String,e);for(var r="",n=0;n0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),""},c.prototype.compare=function(e,t,r,n,o){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),t<0||r>e.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&t>=r)return 0;if(n>=o)return-1;if(t>=r)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0),s=Math.min(i,a),h=this.slice(n,o),u=e.slice(t,r),l=0;lo)&&(r=o),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var i=!1;;)switch(n){case"hex":return b(this,e,t,r);case"utf8":case"utf-8":return v(this,e,t,r);case"ascii":return _(this,e,t,r);case"latin1":case"binary":return S(this,e,t,r);case"base64":return A(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var C=4096;function T(e,t,r){var n="";r=Math.min(e.length,r);for(var o=t;oo)&&(r=o);for(var i="",a=t;ar)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,r,n,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||te.length)throw new RangeError("Index out of range")}function D(e,t,r,n){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-r,2);o>>8*(n?o:1-o)}function B(e,t,r,n){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-r,4);o>>8*(n?o:3-o)&255}function N(e,t,r,n,o,i){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function L(e,t,r,n,i){return i||N(e,0,r,4),o.write(e,t,r,n,23,4),r+4}function M(e,t,r,n,i){return i||N(e,0,r,8),o.write(e,t,r,n,52,8),r+8}c.prototype.slice=function(e,t){var r,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t0&&(o*=256);)n+=this[e+--t]*o;return n},c.prototype.readUInt8=function(e,t){return t||k(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||k(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||k(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||k(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||k(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,r){e|=0,t|=0,r||k(e,t,this.length);for(var n=this[e],o=1,i=0;++i=(o*=128)&&(n-=Math.pow(2,8*t)),n},c.prototype.readIntBE=function(e,t,r){e|=0,t|=0,r||k(e,t,this.length);for(var n=t,o=1,i=this[e+--n];n>0&&(o*=256);)i+=this[e+--n]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return t||k(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||k(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt16BE=function(e,t){t||k(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt32LE=function(e,t){return t||k(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||k(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||k(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||k(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||k(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||k(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,r,n){e=+e,t|=0,r|=0,n||j(this,e,t,r,Math.pow(2,8*r)-1,0);var o=1,i=0;for(this[t]=255&e;++i=0&&(i*=256);)this[t+o]=e/i&255;return t+r},c.prototype.writeUInt8=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):D(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):D(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):B(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):B(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t|=0,!n){var o=Math.pow(2,8*r-1);j(this,e,t,r,o-1,-o)}var i=0,a=1,s=0;for(this[t]=255&e;++i>0)-s&255;return t+r},c.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t|=0,!n){var o=Math.pow(2,8*r-1);j(this,e,t,r,o-1,-o)}var i=r-1,a=1,s=0;for(this[t+i]=255&e;--i>=0&&(a*=256);)e<0&&0===s&&0!==this[t+i+1]&&(s=1),this[t+i]=(e/a>>0)-s&255;return t+r},c.prototype.writeInt8=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):D(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):D(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):B(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):B(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,r){return L(this,e,t,!0,r)},c.prototype.writeFloatBE=function(e,t,r){return L(this,e,t,!1,r)},c.prototype.writeDoubleLE=function(e,t,r){return M(this,e,t,!0,r)},c.prototype.writeDoubleBE=function(e,t,r){return M(this,e,t,!1,r)},c.prototype.copy=function(e,t,r,n){if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t=0;--o)e[o+t]=this[o+r];else if(i<1e3||!c.TYPED_ARRAY_SUPPORT)for(o=0;o>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(i=t;i55295&&r<57344){if(!o){if(r>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(t-=3)>-1&&i.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((t-=1)<0)break;i.push(r)}else if(r<2048){if((t-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function q(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(U,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function $(e,t,r,n){for(var o=0;o=t.length||o>=e.length);++o)t[o+r]=e[o];return o}}).call(this,r(20))},function(e,t,r){"use strict";t.byteLength=function(e){var t=h(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,n=h(e),a=n[0],s=n[1],c=new i(function(e,t,r){return 3*(t+r)/4-r}(0,a,s)),u=0,l=s>0?a-4:a;for(r=0;r>16&255,c[u++]=t>>8&255,c[u++]=255&t;return 2===s&&(t=o[e.charCodeAt(r)]<<2|o[e.charCodeAt(r+1)]>>4,c[u++]=255&t),1===s&&(t=o[e.charCodeAt(r)]<<10|o[e.charCodeAt(r+1)]<<4|o[e.charCodeAt(r+2)]>>2,c[u++]=t>>8&255,c[u++]=255&t),c},t.fromByteArray=function(e){for(var t,r=e.length,o=r%3,i=[],a=16383,s=0,c=r-o;sc?c:s+a));return 1===o?(t=e[r-1],i.push(n[t>>2]+n[t<<4&63]+"==")):2===o&&(t=(e[r-2]<<8)+e[r-1],i.push(n[t>>10]+n[t>>4&63]+n[t<<2&63]+"=")),i.join("")};for(var n=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,c=a.length;s0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function u(e,t,r){for(var o,i,a=[],s=t;s>18&63]+n[i>>12&63]+n[i>>6&63]+n[63&i]);return a.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){t.read=function(e,t,r,n,o){var i,a,s=8*o-n-1,c=(1<>1,u=-7,l=r?o-1:0,p=r?-1:1,d=e[t+l];for(l+=p,i=d&(1<<-u)-1,d>>=-u,u+=s;u>0;i=256*i+e[t+l],l+=p,u-=8);for(a=i&(1<<-u)-1,i>>=-u,u+=n;u>0;a=256*a+e[t+l],l+=p,u-=8);if(0===i)i=1-h;else{if(i===c)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),i-=h}return(d?-1:1)*a*Math.pow(2,i-n)},t.write=function(e,t,r,n,o,i){var a,s,c,h=8*i-o-1,u=(1<>1,p=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:i-1,f=n?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=u):(a=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-a))<1&&(a--,c*=2),(t+=a+l>=1?p/c:p*Math.pow(2,1-l))*c>=2&&(a++,c/=2),a+l>=u?(s=0,a=u):a+l>=1?(s=(t*c-1)*Math.pow(2,o),a+=l):(s=t*Math.pow(2,l-1)*Math.pow(2,o),a=0));o>=8;e[r+d]=255&s,d+=f,s/=256,o-=8);for(a=a<0;e[r+d]=255&a,d+=f,a/=256,h-=8);e[r+d-f]|=128*g}},function(e,t){var r={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==r.call(e)}},function(e,t,r){e.exports=r(41).default,e.exports.default=e.exports},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});var n=r(42);function o(t,r){return void 0===r&&(r="utf8"),e.isBuffer(t)?a(t.toString("base64")):a(e.from(t,r).toString("base64"))}function i(e){return e=e.toString(),n.default(e).replace(/\-/g,"+").replace(/_/g,"/")}function a(e){return e.replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}var s=o;s.encode=o,s.decode=function(t,r){return void 0===r&&(r="utf8"),e.from(i(t),"base64").toString(r)},s.toBase64=i,s.fromBase64=a,s.toBuffer=function(t){return e.from(i(t),"base64")},t.default=s}).call(this,r(36).Buffer)},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(t){var r=t.length,n=r%4;if(!n)return t;var o=r,i=4-n,a=r+i,s=e.alloc(a);for(s.write(t);i--;)s.write("=",o++);return s.toString()}}).call(this,r(36).Buffer)},function(e,t,r){(function(t){const n=t.TextEncoder?t.TextEncoder:r(44).TextEncoder;e.exports=n}).call(this,r(20))},function(e,t){},function(e,t,r){"use strict";(function(t){const n=r(40);let o=r(29);const i=r(43);e.exports=class{constructor(e){this.params=e}sign(e,r){let a=this.params;return r=(new i).encode(r),o.subtle.sign(a,e,r).then((e=>n(t.from(e))))}verify(e,t,r){let a=this.params;return"string"==typeof t&&(t=Uint8Array.from(n.toBuffer(t))),"string"==typeof r&&(r=(new i).encode(r)),o.subtle.verify(a,e,t,r)}async importKey(e){let t=Object.assign({},e),r=this.params,n=e.key_ops||[];return"sig"===e.use&&n.push("verify"),"enc"===e.use?Promise.resolve(e):(e.key_ops&&(n=e.key_ops),o.subtle.importKey("jwk",t,r,!0,n).then((e=>(Object.defineProperty(t,"cryptoKey",{enumerable:!1,value:e}),t))))}}}).call(this,r(36).Buffer)},function(e,t,r){const n=r(47),o=["sign","verify","encrypt","decrypt","importKey"];e.exports=class{constructor(){o.forEach((e=>{this[e]={}}))}static get operations(){return o}define(e,t,r){this[t][e]=r}normalize(e,t){let r=this[e];return r?r[t]||new n(t):new SyntaxError}}},function(e,t){class r extends Error{constructor(e){super(),this.message=`${e} is not a supported algorithm`}}e.exports=r},function(e,t,r){e.exports={DataError:r(49),NotSupportedError:r(47)}},function(e,t){class r extends Error{constructor(e){super(e)}}e.exports=r},function(e,t,r){"use strict";const n=r(32);e.exports=class{constructor({kty:e,use:t,key_ops:r,alg:n,kid:o,x5u:i,x5c:a,x5t:s}={}){this.kty=e,this.use=t,this.key_ops=r,this.alg=n,this.kid=o,this.x5u=i,this.x5c=a,this.x5t=s}static async importKey(e){return n.importKey(e)}}},function(e,t,r){"use strict";const n=r(50);class o{constructor({keys:e}={}){this.keys=e}static async importKeys(e){if(!e.keys)return Promise.reject(new Error("Cannot import JWKSet: keys property is empty"));let t,r;try{t=new o(e),r=e.keys.map((e=>n.importKey(e)))}catch(e){return Promise.reject(e)}return Promise.all(r).then((e=>(t.keys=e,t)))}}e.exports=o},function(e,t,r){const n=r(40),o=r(53),i=r(49),a=r(54);class s{constructor(e={}){this.type=e.type,this.segments=e.segments,this.header=new a(e.header),this.protected=e.protected,this.unprotected=e.unprotected,this.iv=e.iv,this.aad=e.aad,this.ciphertext=e.ciphertext,this.tag=e.tag,this.recipients=e.recipients,this.payload=e.payload,this.signatures=e.signatures,this.signature=e.signature,this.key=e.key,this.serialization=e.serialization||"compact"}static decode(e){let t,r=this;if("string"!=typeof e)throw new i("JWT must be a string");if(e.startsWith("{")){try{e=JSON.parse(e,(()=>{}))}catch(e){throw new i("Invalid JWT serialization")}e.signatures||e.recipients?e.serialization="json":e.serialization="flattened",t=new r(e,{filter:!1})}else try{let o="compact",i=e.split("."),a=i.length;if(3!==a&&5!==a)throw new Error("Malformed JWT");let s=JSON.parse(n.decode(i[0]));3===a&&(t=new r({type:"JWS",segments:i,header:s,payload:JSON.parse(n.decode(i[1])),signature:i[2],serialization:o},{filter:!1}))}catch(e){throw new i("Invalid JWT compact serialization")}return t}static encode(e,t,r){return new s(e,t).encode(r)}static async verify(e,t){let r=s.decode(t);return r.key=e,r.verify().then((e=>r))}isJWE(){return!!this.header.enc}resolveKeys(e){let t,r,n=this.header.kid;if(Array.isArray(e)&&(t=e),e.keys&&(t=e.keys),e.keys||"object"!=typeof e||(t=[e]),!t)throw new i("Invalid JWK argument");return r=n?t.find((e=>e.kid===n)):t.find((e=>"sig"===e.use)),!!r&&(this.key=r.cryptoKey,!0)}async encode(){return this.isJWE()?JWE.encrypt(this):o.sign(this)}async verify(){return o.verify(this)}}e.exports=s},function(e,t,r){const n=r(40),o=r(32),{DataError:i}=r(48),a=r(54);e.exports=class{constructor(e={}){this.header=new a(e.header),this.payload=e.payload||{},this.signature=e.signature,this.protected=e.protected,this.signatures=e.signatures,this.verified=!1}static async sign(e){let t=n(JSON.stringify(e.payload));if("compact"===e.serialization){let{key:r,header:{alg:i}}=e,a=`${n(JSON.stringify(e.header))}.${t}`;return o.sign(i,r,a).then((e=>`${a}.${e}`))}return e.serialization,e.serialization,Promise.reject(new i("Unsupported serialization"))}static async verify(e){e.signatures;let{key:t,signature:r,header:{alg:n}}=e;if(e.signature){let[a,s]=e.segments,c=`${a}.${s}`;return"none"===n?Promise.reject(new i("Signature provided to verify with alg: none")):o.verify(n,t,r,c).then((t=>(e.verified=t,t)))}if("none"===n){if(!t&&!r)return e.verified=!0,Promise.resolve(!0);if(t)return Promise.reject(new i("Key provided to verify signature with alg: none"))}return Promise.reject(new i("Missing signature(s)"))}}},function(e,t){e.exports=class{constructor({typ:e,cty:t,alg:r,jku:n,kid:o,x5u:i,x5c:a,x5t:s,crit:c,enc:h,zip:u}={}){this.typ=e,this.cty=t,this.alg=r,this.jku=n,this.kid=o,this.x5u=i,this.x5c=a,this.x5t=s,this.crit=c,this.enc=h,this.zip=u}isJWS(){}isJWE(){}}},function(e,t,r){(function(t){const n=r(21),o=r(40),{crypto:i,JWT:a}=r(28),s=r(56),{URL:c}=r(27);class h{static create(e,r,a){const{provider:u,defaults:l,registration:p}=e;let d,f,g,m;return Promise.resolve().then((()=>(n(u.configuration,"RelyingParty provider OpenID Configuration is missing"),n(l.authenticate,"RelyingParty default authentication parameters are missing"),n(p,"RelyingParty client registration is missing"),d=u.configuration.issuer,f=u.configuration.authorization_endpoint,g={client_id:p.client_id},m=Object.assign(l.authenticate,g,r),n(d,"Missing issuer in provider OpenID Configuration"),n(f,"Missing authorization_endpoint in provider OpenID Configuration"),n(m.scope,"Missing scope parameter in authentication request"),n(m.response_type,"Missing response_type parameter in authentication request"),n(m.client_id,"Missing client_id parameter in authentication request"),n(m.redirect_uri,"Missing redirect_uri parameter in authentication request"),m.state=Array.from(i.getRandomValues(new Uint8Array(16))),m.nonce=Array.from(i.getRandomValues(new Uint8Array(16))),Promise.all([i.subtle.digest({name:"SHA-256"},new Uint8Array(m.state)),i.subtle.digest({name:"SHA-256"},new Uint8Array(m.nonce))])))).then((e=>{let r=o(t.from(e[0])),n=o(t.from(e[1]));a[`${d}/requestHistory/${r}`]=JSON.stringify(m),m.state=r,m.nonce=n})).then((()=>h.generateSessionKeys())).then((e=>{h.storeSessionKeys(e,m,a)})).then((()=>{if(u.configuration.request_parameter_supported)return h.encodeRequestParams(m).then((e=>{m=e}))})).then((()=>{let e=new c(f);return e.search=s.encode(m),e.href}))}static generateSessionKeys(){return i.subtle.generateKey({name:"RSASSA-PKCS1-v1_5",modulusLength:2048,publicExponent:new Uint8Array([1,0,1]),hash:{name:"SHA-256"}},!0,["sign","verify"]).then((e=>Promise.all([i.subtle.exportKey("jwk",e.publicKey),i.subtle.exportKey("jwk",e.privateKey)]))).then((e=>{let[t,r]=e;return{public:t,private:r}}))}static storeSessionKeys(e,t,r){r["oidc.session.privateKey"]=JSON.stringify(e.private),t.key=e.public}static encodeRequestParams(e){const t=["scope","client_id","response_type","state"],r=Object.keys(e).filter((e=>!t.includes(e)));let n={};return r.forEach((t=>{n[t]=e[t]})),new a({header:{alg:"none"},payload:n},{filter:!1}).encode().then((t=>({scope:e.scope,client_id:e.client_id,response_type:e.response_type,request:t,state:e.state})))}}e.exports=h}).call(this,r(36).Buffer)},function(e,t){e.exports=class{static encode(e){let t=[];return Object.keys(e).forEach((function(r){t.push(encodeURIComponent(r)+"="+encodeURIComponent(e[r]))})),t.join("&")}static decode(e){let t={};return e.split("&").forEach((function(e){let r=e.split("="),n=decodeURIComponent(r[0]),o=decodeURIComponent(r[1]);t[n]=o})),t}}},function(e,t,r){(function(t,n){const{URL:o}=r(27),i=r(21),{crypto:a}=r(28),s=r(40),c=r(5),h=c.Headers?c.Headers:t.Headers,u=r(56),l=r(58),p=r(59),d=r(60),f=r(62);class g{constructor({rp:e,redirect:t,body:r,session:n,mode:o,params:i={}}){this.rp=e,this.redirect=t,this.body=r,this.session=n,this.mode=o,this.params=i}static validateResponse(e){return Promise.resolve(e).then(this.parseResponse).then(this.errorResponse).then(this.matchRequest).then(this.validateStateParam).then(this.validateResponseMode).then(this.validateResponseParams).then(this.exchangeAuthorizationCode).then(this.validateIDToken).then(p.fromAuthResponse)}static parseResponse(e){let{redirect:t,body:r}=e;if(t&&r||!t&&!r)throw new f(400,"Invalid response mode");if(t){let r=new o(t),{search:n,hash:i}=r;if(n&&i||!n&&!i)throw new f(400,"Invalid response mode");n&&(e.params=u.decode(n.substring(1)),e.mode="query"),i&&(e.params=u.decode(i.substring(1)),e.mode="fragment")}return r&&(e.params=u.decode(r),e.mode="form_post"),e}static errorResponse(e){const t=e.params.error;if(t){const r={};r.error=t,r.error_description=e.params.error_description,r.error_uri=e.params.error_uri,r.state=e.params.state;const n=new Error(`AuthenticationResponse error: ${t}`);throw n.info=r,n}return e}static matchRequest(e){let{rp:t,params:r,session:n}=e,o=r.state,i=t.provider.configuration.issuer;if(!o)throw new Error("Missing state parameter in authentication response");let a=n[`${i}/requestHistory/${o}`];if(!a)throw new Error("Mismatching state parameter in authentication response");return e.request=JSON.parse(a),e}static validateStateParam(e){let t=new Uint8Array(e.request.state),r=e.params.state;return a.subtle.digest({name:"SHA-256"},t).then((t=>{if(r!==s(n.from(t)))throw new Error("Mismatching state parameter in authentication response");return e}))}static validateResponseMode(e){if("code"!==e.request.response_type&&"query"===e.mode)throw new Error("Invalid response mode");return e}static validateResponseParams(e){let{request:t,params:r}=e,n=t.response_type.split(" ");return n.includes("code")&&i(r.code,"Missing authorization code in authentication response"),n.includes("id_token")&&i(r.id_token,"Missing id_token in authentication response"),n.includes("token")&&(i(r.access_token,"Missing access_token in authentication response"),i(r.token_type,"Missing token_type in authentication response")),e}static exchangeAuthorizationCode(e){let{rp:t,params:r,request:o}=e,a=r.code;if(!a||"code"!==o.response_type)return Promise.resolve(e);let{provider:s,registration:l}=t,p=l.client_id,f=l.client_secret;if(!f)return Promise.reject(new Error("Client cannot exchange authorization code because it is not a confidential client"));let g=s.configuration.token_endpoint,m=new h({"Content-Type":"application/x-www-form-urlencoded"}),y={grant_type:"authorization_code",code:a,redirect_uri:o.redirect_uri},w=l.token_endpoint_auth_method||"client_secret_basic";if("client_secret_basic"===w){let e=new n(`${p}:${f}`).toString("base64");m.set("Authorization",`Basic ${e}`)}"client_secret_post"===w&&(y.client_id=p,y.client_secret=f);let b=u.encode(y);return c(g,{method:"POST",headers:m,body:b}).then(d("Error exchanging authorization code")).then((e=>e.json())).then((t=>(i(t.access_token,"Missing access_token in token response"),i(t.token_type,"Missing token_type in token response"),i(t.id_token,"Missing id_token in token response"),e.params=Object.assign(e.params,t),e)))}static validateIDToken(e){return e.params.id_token?Promise.resolve(e).then(g.decryptIDToken).then(g.decodeIDToken).then(g.validateIssuer).then(g.validateAudience).then(g.resolveKeys).then(g.verifySignature).then(g.validateExpires).then(g.verifyNonce).then(g.validateAcr).then(g.validateAuthTime).then(g.validateAccessTokenHash).then(g.validateAuthorizationCodeHash):Promise.resolve(e)}static decryptIDToken(e){return Promise.resolve(e)}static decodeIDToken(e){let t=e.params.id_token;try{e.decoded=l.decode(t)}catch(e){const r=new f(400,"Error decoding ID Token");throw r.cause=e,r.info={id_token:t},r}return e}static validateIssuer(e){let t=e.rp.provider.configuration;if(e.decoded.payload.iss!==t.issuer)throw new Error("Mismatching issuer in ID Token");return e}static validateAudience(e){let t=e.rp.registration,{aud:r,azp:n}=e.decoded.payload;if("string"==typeof r&&r!==t.client_id)throw new Error("Mismatching audience in id_token");if(Array.isArray(r)&&!r.includes(t.client_id))throw new Error("Mismatching audience in id_token");if(Array.isArray(r)&&!n)throw new Error("Missing azp claim in id_token");if(n&&n!==t.client_id)throw new Error("Mismatching azp claim in id_token");return e}static resolveKeys(e){let t=e.rp,r=t.provider,n=e.decoded,o=!1;return Promise.resolve(r.jwks).then((e=>e||(o=!0,t.jwks()))).then((r=>{if(n.resolveKeys(r))return Promise.resolve(e);if(!o)return t.jwks().then((t=>{if(n.resolveKeys(t))return Promise.resolve(e);throw new Error("Cannot resolve signing key for ID Token")}));throw new Error("Cannot resolve signing key for ID Token")}))}static verifySignature(e){let t=e.decoded.header.alg,r=e.rp.registration.id_token_signed_response_alg||"RS256";if(t!==r)throw new Error(`Expected ID Token to be signed with ${r}`);return e.decoded.verify().then((t=>{if(!t)throw new Error("Invalid ID Token signature");return e}))}static validateExpires(e){if(e.decoded.payload.exp<=Math.floor(Date.now()/1e3))throw new Error("Expired ID Token");return e}static verifyNonce(e){let t=new Uint8Array(e.request.nonce),r=e.decoded.payload.nonce;if(!r)throw new Error("Missing nonce in ID Token");return a.subtle.digest({name:"SHA-256"},t).then((t=>{if(r!==s(n.from(t)))throw new Error("Mismatching nonce in ID Token");return e}))}static validateAcr(e){return e}static validateAuthTime(e){return e}static validateAccessTokenHash(e){return e}static validateAuthorizationCodeHash(e){return e}}e.exports=g}).call(this,r(20),r(36).Buffer)},function(e,t,r){const{JWT:n}=r(28),o=["iss","sub","aud","exp","iat"];class i{constructor({iss:e,sub:t,aud:r,exp:n,iat:o,nbf:i,jti:a,auth_time:s,nonce:c,acr:h,amr:u}={}){this.iss=e,this.sub=t,this.aud=r,this.exp=n,this.iat=o,this.nbf=i,this.jti=a,this.auth_time=s,this.nonce=c,this.acr=h,this.amr=u}validate(){let e,t=!0;try{for(const e of o)if(!this[e])throw t=!1,new Error(`Required claim ${e} is missing.`)}catch(t){e=t}return{valid:t,error:e}}}e.exports=class extends n{constructor(e={}){super(e),this.payload=new i(e.payload)}validate(){const e=this.payload.validate();return e.valid?{valid:!0,error:void 0}:e}},e.exports.TokenClaimsSet=i},function(e,t,r){"use strict";const n=r(5),o=r(60),i=r(61);class a{constructor(e){this.credentialType=e.credentialType||"access_token",this.issuer=e.issuer,this.authorization=e.authorization||{},this.sessionKey=e.sessionKey,this.idClaims=e.idClaims,this.accessClaims=e.accessClaims}static from(e){return new a(e)}static fromAuthResponse(e){const t=r(19);let n=e.decoded&&e.decoded.payload||{},{rp:o}=e,i=o.registration,s={credentialType:(o.defaults.authenticate||{}).credential_type||o.defaults.popToken?"pop_token":"access_token",sessionKey:e.session[t.SESSION_PRIVATE_KEY],issuer:n.iss,idClaims:n,authorization:{client_id:i.client_id,access_token:e.params.access_token,id_token:e.params.id_token,refresh_token:e.params.refresh_token}};return a.from(s)}get fetch(){return(e,t)=>Promise.resolve().then((()=>this.hasCredentials()?this.fetchWithCredentials(e,t):n(e,t))).then(o("Error while fetching resource"))}bearerTokenFor(e){return"pop_token"===this.credentialType?i.issueFor(e,this):Promise.resolve(this.authorization[this.credentialType])}hasCredentials(){return"pop_token"===this.credentialType?!!this.authorization.id_token:!!this.authorization[this.credentialType]}fetchWithCredentials(e,t={}){return t.headers=t.headers||{},this.bearerTokenFor(e).then((r=>(t.headers.authorization=`Bearer ${r}`,n(e,t))))}}e.exports=a},function(e,t,r){"use strict";e.exports=function(e="fetch error"){return t=>{if(t.status>=200&&t.status<300)return t;let r=`${e}: ${t.status} ${t.statusText}`,n=new Error(r);throw n.response=t,n.statusCode=t.status,n}}},function(e,t,r){"use strict";const{URL:n}=r(27),{JWT:o,JWK:i}=r(28);class a extends o{static issueFor(e,t){if(!e)throw new Error("Cannot issue PoPToken - missing resource server URI");if(!t.sessionKey)throw new Error("Cannot issue PoPToken - missing session key");if(!t.authorization.id_token)throw new Error("Cannot issue PoPToken - missing id token");let r=JSON.parse(t.sessionKey);return i.importKey(r).then((r=>{let o={aud:new n(e).origin,key:r,iss:t.authorization.client_id,id_token:t.authorization.id_token};return a.issue(o)})).then((e=>e.encode()))}static issue(e){let{aud:t,iss:r,key:n}=e,o=n.alg,i=e.iat||Math.floor(Date.now()/1e3),s={alg:o},c={iss:r,aud:t,exp:i+(e.max||3600),iat:i,id_token:e.id_token,token_type:"pop"};return new a({header:s,payload:c,key:n.cryptoKey},{filter:!1})}}e.exports=a},function(e,t,r){t=e.exports=a;var n=r(63),o=r(64),i=t;function a(e,t,r){if("string"==typeof e&&(e=i[e]),"number"!=typeof e)throw new TypeError("Non-numeric HTTP code");"object"==typeof t&&null!=t&&(r=t,t=null),n.call(this,t||o[e],r),this.code=e}for(var s in a.prototype=Object.create(n.prototype,{constructor:{value:a,configurable:!0,writable:!0}}),a.prototype.name="HttpError",Object.defineProperties(a.prototype,{statusCode:c("code"),statusMessage:c("message"),status:{configurable:!0,get:function(){return this.code},set:function(e){Object.defineProperty(this,"status",{value:e,configurable:!0,enumerable:!0,writable:!0})}}}),a.prototype.toString=function(){return this.name+": "+this.code+" "+this.message},o)t[o[s].replace("'","").replace(/[- ]/g,"_").toUpperCase()]=+s;function c(e){return{configurable:!0,get:function(){return this[e]},set:function(t){return this[e]=t}}}},function(e,t){var r=Object.hasOwnProperty,n=Object.getPrototypeOf,o=Error.captureStackTrace;function i(e,t){if(e&&"object"==typeof e?(t=e,e=void 0):this.message=e,t)for(var i in t)this[i]=t[i];r.call(this,"name")||(this.name=r.call(n(this),"name")?this.name:this.constructor.name),o&&!("stack"in this)&&o(this,this.constructor)}e.exports=i,i.prototype=Object.create(Error.prototype,{constructor:{value:i,configurable:!0,writable:!0}}),i.prototype.name="StandardError"},function(e){e.exports=JSON.parse('{"100":"Continue","101":"Switching Protocols","102":"Processing","200":"OK","201":"Created","202":"Accepted","203":"Non-Authoritative Information","204":"No Content","205":"Reset Content","206":"Partial Content","207":"Multi-Status","208":"Already Reported","226":"IM Used","300":"Multiple Choices","301":"Moved Permanently","302":"Found","303":"See Other","304":"Not Modified","305":"Use Proxy","307":"Temporary Redirect","308":"Permanent Redirect","400":"Bad Request","401":"Unauthorized","402":"Payment Required","403":"Forbidden","404":"Not Found","405":"Method Not Allowed","406":"Not Acceptable","407":"Proxy Authentication Required","408":"Request Timeout","409":"Conflict","410":"Gone","411":"Length Required","412":"Precondition Failed","413":"Payload Too Large","414":"URI Too Long","415":"Unsupported Media Type","416":"Range Not Satisfiable","417":"Expectation Failed","418":"I\'m a teapot","421":"Misdirected Request","422":"Unprocessable Entity","423":"Locked","424":"Failed Dependency","425":"Unordered Collection","426":"Upgrade Required","428":"Precondition Required","429":"Too Many Requests","431":"Request Header Fields Too Large","500":"Internal Server Error","501":"Not Implemented","502":"Bad Gateway","503":"Service Unavailable","504":"Gateway Timeout","505":"HTTP Version Not Supported","506":"Variant Also Negotiates","507":"Insufficient Storage","508":"Loop Detected","509":"Bandwidth Limit Exceeded","510":"Not Extended","511":"Network Authentication Required"}')},function(e,t,r){"use strict";r.r(t),r.d(t,"openIdpPopup",(function(){return i})),r.d(t,"obtainSession",(function(){return a})),r.d(t,"popupHandler",(function(){return s}));var n=r(10),o=r(6);function i(e){const t=window.screenX+(window.innerWidth-650)/2,r=window.screenY+(window.innerHeight-400)/2,n="width=".concat(650,",height=").concat(400,",left=").concat(t,",top=").concat(r);return window.open(e,"solid-auth-client",n)}function a(e,t,r){return new Promise(((i,a)=>{const c=new n.Server(t,Object(o.originOf)(r.popupUri||""),s(e,r,(e=>{c.stop(),i(e)})));c.start()}))}function s(e,{popupUri:t,callbackUri:r},n){return async(o,...i)=>{switch(o){case"getAppOrigin":return window.location.origin;case"storage/getItem":return e.getItem(...i);case"storage/setItem":return e.setItem(...i);case"storage/removeItem":return e.removeItem(...i);case"getLoginOptions":return{popupUri:t,callbackUri:r};case"foundSession":n(...i)}}}}]).default},553:(e,t,r)=>{"use strict";var n=r(396).Buffer,o=n.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function i(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(n.isEncoding===o||!o(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=c,this.end=h,t=4;break;case"utf8":this.fillLast=s,t=4;break;case"base64":this.text=u,this.end=l,t=3;break;default:return this.write=p,void(this.end=d)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function a(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function c(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function h(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function u(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function l(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function p(e){return e.toString(this.encoding)}function d(e){return e&&e.length?this.write(e):""}t.StringDecoder=i,i.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0?(o>0&&(e.lastNeed=o-1),o):--n=0?(o>0&&(e.lastNeed=o-2),o):--n=0?(o>0&&(2===o?o=0:e.lastNeed=o-3),o):0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},i.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},396:(e,t,r)=>{var n=r(764),o=n.Buffer;function i(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return o(e,t,r)}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?e.exports=n:(i(n,t),t.Buffer=a),a.prototype=Object.create(o.prototype),i(o,a),a.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return o(e,t,r)},a.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=o(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},a.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return o(e)},a.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},885:function(e){!function(t,r){"use strict";e.exports?e.exports=r():(t.nacl||(t.nacl={}),t.nacl.util=r())}(this,(function(){"use strict";var e={};function t(e){if(!/^(?:[A-Za-z0-9+\/]{2}[A-Za-z0-9+\/]{2})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=)?$/.test(e))throw new TypeError("invalid encoding")}return e.decodeUTF8=function(e){if("string"!=typeof e)throw new TypeError("expected string");var t,r=unescape(encodeURIComponent(e)),n=new Uint8Array(r.length);for(t=0;t{!function(e){"use strict";var t=function(e){var t,r=new Float64Array(16);if(e)for(t=0;t>24&255,e[t+1]=r>>16&255,e[t+2]=r>>8&255,e[t+3]=255&r,e[t+4]=n>>24&255,e[t+5]=n>>16&255,e[t+6]=n>>8&255,e[t+7]=255&n}function g(e,t,r,n,o){var i,a=0;for(i=0;i>>8)-1}function m(e,t,r,n){return g(e,t,r,n,16)}function y(e,t,r,n){return g(e,t,r,n,32)}function w(e,t,r,n){!function(e,t,r,n){for(var o,i=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,a=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,s=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,c=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,h=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,u=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,l=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,p=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,d=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,f=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,g=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,m=255&r[16]|(255&r[17])<<8|(255&r[18])<<16|(255&r[19])<<24,y=255&r[20]|(255&r[21])<<8|(255&r[22])<<16|(255&r[23])<<24,w=255&r[24]|(255&r[25])<<8|(255&r[26])<<16|(255&r[27])<<24,b=255&r[28]|(255&r[29])<<8|(255&r[30])<<16|(255&r[31])<<24,v=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,_=i,S=a,A=s,E=c,x=h,R=u,C=l,T=p,O=d,P=f,I=g,k=m,j=y,D=w,B=b,N=v,L=0;L<20;L+=2)_^=(o=(j^=(o=(O^=(o=(x^=(o=_+j|0)<<7|o>>>25)+_|0)<<9|o>>>23)+x|0)<<13|o>>>19)+O|0)<<18|o>>>14,R^=(o=(S^=(o=(D^=(o=(P^=(o=R+S|0)<<7|o>>>25)+R|0)<<9|o>>>23)+P|0)<<13|o>>>19)+D|0)<<18|o>>>14,I^=(o=(C^=(o=(A^=(o=(B^=(o=I+C|0)<<7|o>>>25)+I|0)<<9|o>>>23)+B|0)<<13|o>>>19)+A|0)<<18|o>>>14,N^=(o=(k^=(o=(T^=(o=(E^=(o=N+k|0)<<7|o>>>25)+N|0)<<9|o>>>23)+E|0)<<13|o>>>19)+T|0)<<18|o>>>14,_^=(o=(E^=(o=(A^=(o=(S^=(o=_+E|0)<<7|o>>>25)+_|0)<<9|o>>>23)+S|0)<<13|o>>>19)+A|0)<<18|o>>>14,R^=(o=(x^=(o=(T^=(o=(C^=(o=R+x|0)<<7|o>>>25)+R|0)<<9|o>>>23)+C|0)<<13|o>>>19)+T|0)<<18|o>>>14,I^=(o=(P^=(o=(O^=(o=(k^=(o=I+P|0)<<7|o>>>25)+I|0)<<9|o>>>23)+k|0)<<13|o>>>19)+O|0)<<18|o>>>14,N^=(o=(B^=(o=(D^=(o=(j^=(o=N+B|0)<<7|o>>>25)+N|0)<<9|o>>>23)+j|0)<<13|o>>>19)+D|0)<<18|o>>>14;_=_+i|0,S=S+a|0,A=A+s|0,E=E+c|0,x=x+h|0,R=R+u|0,C=C+l|0,T=T+p|0,O=O+d|0,P=P+f|0,I=I+g|0,k=k+m|0,j=j+y|0,D=D+w|0,B=B+b|0,N=N+v|0,e[0]=_>>>0&255,e[1]=_>>>8&255,e[2]=_>>>16&255,e[3]=_>>>24&255,e[4]=S>>>0&255,e[5]=S>>>8&255,e[6]=S>>>16&255,e[7]=S>>>24&255,e[8]=A>>>0&255,e[9]=A>>>8&255,e[10]=A>>>16&255,e[11]=A>>>24&255,e[12]=E>>>0&255,e[13]=E>>>8&255,e[14]=E>>>16&255,e[15]=E>>>24&255,e[16]=x>>>0&255,e[17]=x>>>8&255,e[18]=x>>>16&255,e[19]=x>>>24&255,e[20]=R>>>0&255,e[21]=R>>>8&255,e[22]=R>>>16&255,e[23]=R>>>24&255,e[24]=C>>>0&255,e[25]=C>>>8&255,e[26]=C>>>16&255,e[27]=C>>>24&255,e[28]=T>>>0&255,e[29]=T>>>8&255,e[30]=T>>>16&255,e[31]=T>>>24&255,e[32]=O>>>0&255,e[33]=O>>>8&255,e[34]=O>>>16&255,e[35]=O>>>24&255,e[36]=P>>>0&255,e[37]=P>>>8&255,e[38]=P>>>16&255,e[39]=P>>>24&255,e[40]=I>>>0&255,e[41]=I>>>8&255,e[42]=I>>>16&255,e[43]=I>>>24&255,e[44]=k>>>0&255,e[45]=k>>>8&255,e[46]=k>>>16&255,e[47]=k>>>24&255,e[48]=j>>>0&255,e[49]=j>>>8&255,e[50]=j>>>16&255,e[51]=j>>>24&255,e[52]=D>>>0&255,e[53]=D>>>8&255,e[54]=D>>>16&255,e[55]=D>>>24&255,e[56]=B>>>0&255,e[57]=B>>>8&255,e[58]=B>>>16&255,e[59]=B>>>24&255,e[60]=N>>>0&255,e[61]=N>>>8&255,e[62]=N>>>16&255,e[63]=N>>>24&255}(e,t,r,n)}function b(e,t,r,n){!function(e,t,r,n){for(var o,i=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,a=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,s=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,c=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,h=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,u=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,l=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,p=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,d=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,f=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,g=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,m=255&r[16]|(255&r[17])<<8|(255&r[18])<<16|(255&r[19])<<24,y=255&r[20]|(255&r[21])<<8|(255&r[22])<<16|(255&r[23])<<24,w=255&r[24]|(255&r[25])<<8|(255&r[26])<<16|(255&r[27])<<24,b=255&r[28]|(255&r[29])<<8|(255&r[30])<<16|(255&r[31])<<24,v=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,_=0;_<20;_+=2)i^=(o=(y^=(o=(d^=(o=(h^=(o=i+y|0)<<7|o>>>25)+i|0)<<9|o>>>23)+h|0)<<13|o>>>19)+d|0)<<18|o>>>14,u^=(o=(a^=(o=(w^=(o=(f^=(o=u+a|0)<<7|o>>>25)+u|0)<<9|o>>>23)+f|0)<<13|o>>>19)+w|0)<<18|o>>>14,g^=(o=(l^=(o=(s^=(o=(b^=(o=g+l|0)<<7|o>>>25)+g|0)<<9|o>>>23)+b|0)<<13|o>>>19)+s|0)<<18|o>>>14,v^=(o=(m^=(o=(p^=(o=(c^=(o=v+m|0)<<7|o>>>25)+v|0)<<9|o>>>23)+c|0)<<13|o>>>19)+p|0)<<18|o>>>14,i^=(o=(c^=(o=(s^=(o=(a^=(o=i+c|0)<<7|o>>>25)+i|0)<<9|o>>>23)+a|0)<<13|o>>>19)+s|0)<<18|o>>>14,u^=(o=(h^=(o=(p^=(o=(l^=(o=u+h|0)<<7|o>>>25)+u|0)<<9|o>>>23)+l|0)<<13|o>>>19)+p|0)<<18|o>>>14,g^=(o=(f^=(o=(d^=(o=(m^=(o=g+f|0)<<7|o>>>25)+g|0)<<9|o>>>23)+m|0)<<13|o>>>19)+d|0)<<18|o>>>14,v^=(o=(b^=(o=(w^=(o=(y^=(o=v+b|0)<<7|o>>>25)+v|0)<<9|o>>>23)+y|0)<<13|o>>>19)+w|0)<<18|o>>>14;e[0]=i>>>0&255,e[1]=i>>>8&255,e[2]=i>>>16&255,e[3]=i>>>24&255,e[4]=u>>>0&255,e[5]=u>>>8&255,e[6]=u>>>16&255,e[7]=u>>>24&255,e[8]=g>>>0&255,e[9]=g>>>8&255,e[10]=g>>>16&255,e[11]=g>>>24&255,e[12]=v>>>0&255,e[13]=v>>>8&255,e[14]=v>>>16&255,e[15]=v>>>24&255,e[16]=l>>>0&255,e[17]=l>>>8&255,e[18]=l>>>16&255,e[19]=l>>>24&255,e[20]=p>>>0&255,e[21]=p>>>8&255,e[22]=p>>>16&255,e[23]=p>>>24&255,e[24]=d>>>0&255,e[25]=d>>>8&255,e[26]=d>>>16&255,e[27]=d>>>24&255,e[28]=f>>>0&255,e[29]=f>>>8&255,e[30]=f>>>16&255,e[31]=f>>>24&255}(e,t,r,n)}var v=new Uint8Array([101,120,112,97,110,100,32,51,50,45,98,121,116,101,32,107]);function _(e,t,r,n,o,i,a){var s,c,h=new Uint8Array(16),u=new Uint8Array(64);for(c=0;c<16;c++)h[c]=0;for(c=0;c<8;c++)h[c]=i[c];for(;o>=64;){for(w(u,h,a,v),c=0;c<64;c++)e[t+c]=r[n+c]^u[c];for(s=1,c=8;c<16;c++)s=s+(255&h[c])|0,h[c]=255&s,s>>>=8;o-=64,t+=64,n+=64}if(o>0)for(w(u,h,a,v),c=0;c=64;){for(w(c,s,o,v),a=0;a<64;a++)e[t+a]=c[a];for(i=1,a=8;a<16;a++)i=i+(255&s[a])|0,s[a]=255&i,i>>>=8;r-=64,t+=64}if(r>0)for(w(c,s,o,v),a=0;a>>13|r<<3),n=255&e[4]|(255&e[5])<<8,this.r[2]=7939&(r>>>10|n<<6),o=255&e[6]|(255&e[7])<<8,this.r[3]=8191&(n>>>7|o<<9),i=255&e[8]|(255&e[9])<<8,this.r[4]=255&(o>>>4|i<<12),this.r[5]=i>>>1&8190,a=255&e[10]|(255&e[11])<<8,this.r[6]=8191&(i>>>14|a<<2),s=255&e[12]|(255&e[13])<<8,this.r[7]=8065&(a>>>11|s<<5),c=255&e[14]|(255&e[15])<<8,this.r[8]=8191&(s>>>8|c<<8),this.r[9]=c>>>5&127,this.pad[0]=255&e[16]|(255&e[17])<<8,this.pad[1]=255&e[18]|(255&e[19])<<8,this.pad[2]=255&e[20]|(255&e[21])<<8,this.pad[3]=255&e[22]|(255&e[23])<<8,this.pad[4]=255&e[24]|(255&e[25])<<8,this.pad[5]=255&e[26]|(255&e[27])<<8,this.pad[6]=255&e[28]|(255&e[29])<<8,this.pad[7]=255&e[30]|(255&e[31])<<8};function R(e,t,r,n,o,i){var a=new x(i);return a.update(r,n,o),a.finish(e,t),0}function C(e,t,r,n,o,i){var a=new Uint8Array(16);return R(a,0,r,n,o,i),m(e,t,a,0)}function T(e,t,r,n,o){var i;if(r<32)return-1;for(E(e,0,t,0,r,n,o),R(e,16,e,32,r-32,e),i=0;i<16;i++)e[i]=0;return 0}function O(e,t,r,n,o){var i,a=new Uint8Array(32);if(r<32)return-1;if(A(a,0,32,n,o),0!==C(t,16,t,32,r-32,a))return-1;for(E(e,0,t,0,r,n,o),i=0;i<32;i++)e[i]=0;return 0}function P(e,t){var r;for(r=0;r<16;r++)e[r]=0|t[r]}function I(e){var t,r,n=1;for(t=0;t<16;t++)r=e[t]+n+65535,n=Math.floor(r/65536),e[t]=r-65536*n;e[0]+=n-1+37*(n-1)}function k(e,t,r){for(var n,o=~(r-1),i=0;i<16;i++)n=o&(e[i]^t[i]),e[i]^=n,t[i]^=n}function j(e,r){var n,o,i,a=t(),s=t();for(n=0;n<16;n++)s[n]=r[n];for(I(s),I(s),I(s),o=0;o<2;o++){for(a[0]=s[0]-65517,n=1;n<15;n++)a[n]=s[n]-65535-(a[n-1]>>16&1),a[n-1]&=65535;a[15]=s[15]-32767-(a[14]>>16&1),i=a[15]>>16&1,a[14]&=65535,k(s,a,1-i)}for(n=0;n<16;n++)e[2*n]=255&s[n],e[2*n+1]=s[n]>>8}function D(e,t){var r=new Uint8Array(32),n=new Uint8Array(32);return j(r,e),j(n,t),y(r,0,n,0)}function B(e){var t=new Uint8Array(32);return j(t,e),1&t[0]}function N(e,t){var r;for(r=0;r<16;r++)e[r]=t[2*r]+(t[2*r+1]<<8);e[15]&=32767}function L(e,t,r){for(var n=0;n<16;n++)e[n]=t[n]+r[n]}function M(e,t,r){for(var n=0;n<16;n++)e[n]=t[n]-r[n]}function U(e,t,r){var n,o,i=0,a=0,s=0,c=0,h=0,u=0,l=0,p=0,d=0,f=0,g=0,m=0,y=0,w=0,b=0,v=0,_=0,S=0,A=0,E=0,x=0,R=0,C=0,T=0,O=0,P=0,I=0,k=0,j=0,D=0,B=0,N=r[0],L=r[1],M=r[2],U=r[3],F=r[4],q=r[5],$=r[6],H=r[7],W=r[8],G=r[9],z=r[10],K=r[11],V=r[12],Y=r[13],Q=r[14],J=r[15];i+=(n=t[0])*N,a+=n*L,s+=n*M,c+=n*U,h+=n*F,u+=n*q,l+=n*$,p+=n*H,d+=n*W,f+=n*G,g+=n*z,m+=n*K,y+=n*V,w+=n*Y,b+=n*Q,v+=n*J,a+=(n=t[1])*N,s+=n*L,c+=n*M,h+=n*U,u+=n*F,l+=n*q,p+=n*$,d+=n*H,f+=n*W,g+=n*G,m+=n*z,y+=n*K,w+=n*V,b+=n*Y,v+=n*Q,_+=n*J,s+=(n=t[2])*N,c+=n*L,h+=n*M,u+=n*U,l+=n*F,p+=n*q,d+=n*$,f+=n*H,g+=n*W,m+=n*G,y+=n*z,w+=n*K,b+=n*V,v+=n*Y,_+=n*Q,S+=n*J,c+=(n=t[3])*N,h+=n*L,u+=n*M,l+=n*U,p+=n*F,d+=n*q,f+=n*$,g+=n*H,m+=n*W,y+=n*G,w+=n*z,b+=n*K,v+=n*V,_+=n*Y,S+=n*Q,A+=n*J,h+=(n=t[4])*N,u+=n*L,l+=n*M,p+=n*U,d+=n*F,f+=n*q,g+=n*$,m+=n*H,y+=n*W,w+=n*G,b+=n*z,v+=n*K,_+=n*V,S+=n*Y,A+=n*Q,E+=n*J,u+=(n=t[5])*N,l+=n*L,p+=n*M,d+=n*U,f+=n*F,g+=n*q,m+=n*$,y+=n*H,w+=n*W,b+=n*G,v+=n*z,_+=n*K,S+=n*V,A+=n*Y,E+=n*Q,x+=n*J,l+=(n=t[6])*N,p+=n*L,d+=n*M,f+=n*U,g+=n*F,m+=n*q,y+=n*$,w+=n*H,b+=n*W,v+=n*G,_+=n*z,S+=n*K,A+=n*V,E+=n*Y,x+=n*Q,R+=n*J,p+=(n=t[7])*N,d+=n*L,f+=n*M,g+=n*U,m+=n*F,y+=n*q,w+=n*$,b+=n*H,v+=n*W,_+=n*G,S+=n*z,A+=n*K,E+=n*V,x+=n*Y,R+=n*Q,C+=n*J,d+=(n=t[8])*N,f+=n*L,g+=n*M,m+=n*U,y+=n*F,w+=n*q,b+=n*$,v+=n*H,_+=n*W,S+=n*G,A+=n*z,E+=n*K,x+=n*V,R+=n*Y,C+=n*Q,T+=n*J,f+=(n=t[9])*N,g+=n*L,m+=n*M,y+=n*U,w+=n*F,b+=n*q,v+=n*$,_+=n*H,S+=n*W,A+=n*G,E+=n*z,x+=n*K,R+=n*V,C+=n*Y,T+=n*Q,O+=n*J,g+=(n=t[10])*N,m+=n*L,y+=n*M,w+=n*U,b+=n*F,v+=n*q,_+=n*$,S+=n*H,A+=n*W,E+=n*G,x+=n*z,R+=n*K,C+=n*V,T+=n*Y,O+=n*Q,P+=n*J,m+=(n=t[11])*N,y+=n*L,w+=n*M,b+=n*U,v+=n*F,_+=n*q,S+=n*$,A+=n*H,E+=n*W,x+=n*G,R+=n*z,C+=n*K,T+=n*V,O+=n*Y,P+=n*Q,I+=n*J,y+=(n=t[12])*N,w+=n*L,b+=n*M,v+=n*U,_+=n*F,S+=n*q,A+=n*$,E+=n*H,x+=n*W,R+=n*G,C+=n*z,T+=n*K,O+=n*V,P+=n*Y,I+=n*Q,k+=n*J,w+=(n=t[13])*N,b+=n*L,v+=n*M,_+=n*U,S+=n*F,A+=n*q,E+=n*$,x+=n*H,R+=n*W,C+=n*G,T+=n*z,O+=n*K,P+=n*V,I+=n*Y,k+=n*Q,j+=n*J,b+=(n=t[14])*N,v+=n*L,_+=n*M,S+=n*U,A+=n*F,E+=n*q,x+=n*$,R+=n*H,C+=n*W,T+=n*G,O+=n*z,P+=n*K,I+=n*V,k+=n*Y,j+=n*Q,D+=n*J,v+=(n=t[15])*N,a+=38*(S+=n*M),s+=38*(A+=n*U),c+=38*(E+=n*F),h+=38*(x+=n*q),u+=38*(R+=n*$),l+=38*(C+=n*H),p+=38*(T+=n*W),d+=38*(O+=n*G),f+=38*(P+=n*z),g+=38*(I+=n*K),m+=38*(k+=n*V),y+=38*(j+=n*Y),w+=38*(D+=n*Q),b+=38*(B+=n*J),i=(n=(i+=38*(_+=n*L))+(o=1)+65535)-65536*(o=Math.floor(n/65536)),a=(n=a+o+65535)-65536*(o=Math.floor(n/65536)),s=(n=s+o+65535)-65536*(o=Math.floor(n/65536)),c=(n=c+o+65535)-65536*(o=Math.floor(n/65536)),h=(n=h+o+65535)-65536*(o=Math.floor(n/65536)),u=(n=u+o+65535)-65536*(o=Math.floor(n/65536)),l=(n=l+o+65535)-65536*(o=Math.floor(n/65536)),p=(n=p+o+65535)-65536*(o=Math.floor(n/65536)),d=(n=d+o+65535)-65536*(o=Math.floor(n/65536)),f=(n=f+o+65535)-65536*(o=Math.floor(n/65536)),g=(n=g+o+65535)-65536*(o=Math.floor(n/65536)),m=(n=m+o+65535)-65536*(o=Math.floor(n/65536)),y=(n=y+o+65535)-65536*(o=Math.floor(n/65536)),w=(n=w+o+65535)-65536*(o=Math.floor(n/65536)),b=(n=b+o+65535)-65536*(o=Math.floor(n/65536)),v=(n=v+o+65535)-65536*(o=Math.floor(n/65536)),i=(n=(i+=o-1+37*(o-1))+(o=1)+65535)-65536*(o=Math.floor(n/65536)),a=(n=a+o+65535)-65536*(o=Math.floor(n/65536)),s=(n=s+o+65535)-65536*(o=Math.floor(n/65536)),c=(n=c+o+65535)-65536*(o=Math.floor(n/65536)),h=(n=h+o+65535)-65536*(o=Math.floor(n/65536)),u=(n=u+o+65535)-65536*(o=Math.floor(n/65536)),l=(n=l+o+65535)-65536*(o=Math.floor(n/65536)),p=(n=p+o+65535)-65536*(o=Math.floor(n/65536)),d=(n=d+o+65535)-65536*(o=Math.floor(n/65536)),f=(n=f+o+65535)-65536*(o=Math.floor(n/65536)),g=(n=g+o+65535)-65536*(o=Math.floor(n/65536)),m=(n=m+o+65535)-65536*(o=Math.floor(n/65536)),y=(n=y+o+65535)-65536*(o=Math.floor(n/65536)),w=(n=w+o+65535)-65536*(o=Math.floor(n/65536)),b=(n=b+o+65535)-65536*(o=Math.floor(n/65536)),v=(n=v+o+65535)-65536*(o=Math.floor(n/65536)),i+=o-1+37*(o-1),e[0]=i,e[1]=a,e[2]=s,e[3]=c,e[4]=h,e[5]=u,e[6]=l,e[7]=p,e[8]=d,e[9]=f,e[10]=g,e[11]=m,e[12]=y,e[13]=w,e[14]=b,e[15]=v}function F(e,t){U(e,t,t)}function q(e,r){var n,o=t();for(n=0;n<16;n++)o[n]=r[n];for(n=253;n>=0;n--)F(o,o),2!==n&&4!==n&&U(o,o,r);for(n=0;n<16;n++)e[n]=o[n]}function $(e,r){var n,o=t();for(n=0;n<16;n++)o[n]=r[n];for(n=250;n>=0;n--)F(o,o),1!==n&&U(o,o,r);for(n=0;n<16;n++)e[n]=o[n]}function H(e,r,n){var o,i,a=new Uint8Array(32),s=new Float64Array(80),h=t(),u=t(),l=t(),p=t(),d=t(),f=t();for(i=0;i<31;i++)a[i]=r[i];for(a[31]=127&r[31]|64,a[0]&=248,N(s,n),i=0;i<16;i++)u[i]=s[i],p[i]=h[i]=l[i]=0;for(h[0]=p[0]=1,i=254;i>=0;--i)k(h,u,o=a[i>>>3]>>>(7&i)&1),k(l,p,o),L(d,h,l),M(h,h,l),L(l,u,p),M(u,u,p),F(p,d),F(f,h),U(h,l,h),U(l,u,d),L(d,h,l),M(h,h,l),F(u,h),M(l,p,f),U(h,l,c),L(h,h,p),U(l,l,h),U(h,p,f),U(p,u,s),F(u,d),k(h,u,o),k(l,p,o);for(i=0;i<16;i++)s[i+16]=h[i],s[i+32]=l[i],s[i+48]=u[i],s[i+64]=p[i];var g=s.subarray(32),m=s.subarray(16);return q(g,g),U(m,m,g),j(e,m),0}function W(e,t){return H(e,t,i)}function G(e,t){return n(t,32),W(e,t)}function z(e,t,r){var n=new Uint8Array(32);return H(n,r,t),b(e,o,n,v)}x.prototype.blocks=function(e,t,r){for(var n,o,i,a,s,c,h,u,l,p,d,f,g,m,y,w,b,v,_,S=this.fin?0:2048,A=this.h[0],E=this.h[1],x=this.h[2],R=this.h[3],C=this.h[4],T=this.h[5],O=this.h[6],P=this.h[7],I=this.h[8],k=this.h[9],j=this.r[0],D=this.r[1],B=this.r[2],N=this.r[3],L=this.r[4],M=this.r[5],U=this.r[6],F=this.r[7],q=this.r[8],$=this.r[9];r>=16;)p=l=0,p+=(A+=8191&(n=255&e[t+0]|(255&e[t+1])<<8))*j,p+=(E+=8191&(n>>>13|(o=255&e[t+2]|(255&e[t+3])<<8)<<3))*(5*$),p+=(x+=8191&(o>>>10|(i=255&e[t+4]|(255&e[t+5])<<8)<<6))*(5*q),p+=(R+=8191&(i>>>7|(a=255&e[t+6]|(255&e[t+7])<<8)<<9))*(5*F),l=(p+=(C+=8191&(a>>>4|(s=255&e[t+8]|(255&e[t+9])<<8)<<12))*(5*U))>>>13,p&=8191,p+=(T+=s>>>1&8191)*(5*M),p+=(O+=8191&(s>>>14|(c=255&e[t+10]|(255&e[t+11])<<8)<<2))*(5*L),p+=(P+=8191&(c>>>11|(h=255&e[t+12]|(255&e[t+13])<<8)<<5))*(5*N),p+=(I+=8191&(h>>>8|(u=255&e[t+14]|(255&e[t+15])<<8)<<8))*(5*B),d=l+=(p+=(k+=u>>>5|S)*(5*D))>>>13,d+=A*D,d+=E*j,d+=x*(5*$),d+=R*(5*q),l=(d+=C*(5*F))>>>13,d&=8191,d+=T*(5*U),d+=O*(5*M),d+=P*(5*L),d+=I*(5*N),l+=(d+=k*(5*B))>>>13,d&=8191,f=l,f+=A*B,f+=E*D,f+=x*j,f+=R*(5*$),l=(f+=C*(5*q))>>>13,f&=8191,f+=T*(5*F),f+=O*(5*U),f+=P*(5*M),f+=I*(5*L),g=l+=(f+=k*(5*N))>>>13,g+=A*N,g+=E*B,g+=x*D,g+=R*j,l=(g+=C*(5*$))>>>13,g&=8191,g+=T*(5*q),g+=O*(5*F),g+=P*(5*U),g+=I*(5*M),m=l+=(g+=k*(5*L))>>>13,m+=A*L,m+=E*N,m+=x*B,m+=R*D,l=(m+=C*j)>>>13,m&=8191,m+=T*(5*$),m+=O*(5*q),m+=P*(5*F),m+=I*(5*U),y=l+=(m+=k*(5*M))>>>13,y+=A*M,y+=E*L,y+=x*N,y+=R*B,l=(y+=C*D)>>>13,y&=8191,y+=T*j,y+=O*(5*$),y+=P*(5*q),y+=I*(5*F),w=l+=(y+=k*(5*U))>>>13,w+=A*U,w+=E*M,w+=x*L,w+=R*N,l=(w+=C*B)>>>13,w&=8191,w+=T*D,w+=O*j,w+=P*(5*$),w+=I*(5*q),b=l+=(w+=k*(5*F))>>>13,b+=A*F,b+=E*U,b+=x*M,b+=R*L,l=(b+=C*N)>>>13,b&=8191,b+=T*B,b+=O*D,b+=P*j,b+=I*(5*$),v=l+=(b+=k*(5*q))>>>13,v+=A*q,v+=E*F,v+=x*U,v+=R*M,l=(v+=C*L)>>>13,v&=8191,v+=T*N,v+=O*B,v+=P*D,v+=I*j,_=l+=(v+=k*(5*$))>>>13,_+=A*$,_+=E*q,_+=x*F,_+=R*U,l=(_+=C*M)>>>13,_&=8191,_+=T*L,_+=O*N,_+=P*B,_+=I*D,A=p=8191&(l=(l=((l+=(_+=k*j)>>>13)<<2)+l|0)+(p&=8191)|0),E=d+=l>>>=13,x=f&=8191,R=g&=8191,C=m&=8191,T=y&=8191,O=w&=8191,P=b&=8191,I=v&=8191,k=_&=8191,t+=16,r-=16;this.h[0]=A,this.h[1]=E,this.h[2]=x,this.h[3]=R,this.h[4]=C,this.h[5]=T,this.h[6]=O,this.h[7]=P,this.h[8]=I,this.h[9]=k},x.prototype.finish=function(e,t){var r,n,o,i,a=new Uint16Array(10);if(this.leftover){for(i=this.leftover,this.buffer[i++]=1;i<16;i++)this.buffer[i]=0;this.fin=1,this.blocks(this.buffer,0,16)}for(r=this.h[1]>>>13,this.h[1]&=8191,i=2;i<10;i++)this.h[i]+=r,r=this.h[i]>>>13,this.h[i]&=8191;for(this.h[0]+=5*r,r=this.h[0]>>>13,this.h[0]&=8191,this.h[1]+=r,r=this.h[1]>>>13,this.h[1]&=8191,this.h[2]+=r,a[0]=this.h[0]+5,r=a[0]>>>13,a[0]&=8191,i=1;i<10;i++)a[i]=this.h[i]+r,r=a[i]>>>13,a[i]&=8191;for(a[9]-=8192,n=(1^r)-1,i=0;i<10;i++)a[i]&=n;for(n=~n,i=0;i<10;i++)this.h[i]=this.h[i]&n|a[i];for(this.h[0]=65535&(this.h[0]|this.h[1]<<13),this.h[1]=65535&(this.h[1]>>>3|this.h[2]<<10),this.h[2]=65535&(this.h[2]>>>6|this.h[3]<<7),this.h[3]=65535&(this.h[3]>>>9|this.h[4]<<4),this.h[4]=65535&(this.h[4]>>>12|this.h[5]<<1|this.h[6]<<14),this.h[5]=65535&(this.h[6]>>>2|this.h[7]<<11),this.h[6]=65535&(this.h[7]>>>5|this.h[8]<<8),this.h[7]=65535&(this.h[8]>>>8|this.h[9]<<5),o=this.h[0]+this.pad[0],this.h[0]=65535&o,i=1;i<8;i++)o=(this.h[i]+this.pad[i]|0)+(o>>>16)|0,this.h[i]=65535&o;e[t+0]=this.h[0]>>>0&255,e[t+1]=this.h[0]>>>8&255,e[t+2]=this.h[1]>>>0&255,e[t+3]=this.h[1]>>>8&255,e[t+4]=this.h[2]>>>0&255,e[t+5]=this.h[2]>>>8&255,e[t+6]=this.h[3]>>>0&255,e[t+7]=this.h[3]>>>8&255,e[t+8]=this.h[4]>>>0&255,e[t+9]=this.h[4]>>>8&255,e[t+10]=this.h[5]>>>0&255,e[t+11]=this.h[5]>>>8&255,e[t+12]=this.h[6]>>>0&255,e[t+13]=this.h[6]>>>8&255,e[t+14]=this.h[7]>>>0&255,e[t+15]=this.h[7]>>>8&255},x.prototype.update=function(e,t,r){var n,o;if(this.leftover){for((o=16-this.leftover)>r&&(o=r),n=0;n=16&&(o=r-r%16,this.blocks(e,t,o),t+=o,r-=o),r){for(n=0;n=128;){for(S=0;S<16;S++)A=8*S+V,P[S]=r[A+0]<<24|r[A+1]<<16|r[A+2]<<8|r[A+3],I[S]=r[A+4]<<24|r[A+5]<<16|r[A+6]<<8|r[A+7];for(S=0;S<80;S++)if(o=k,i=j,a=D,s=B,c=N,h=L,u=M,p=F,d=q,f=$,g=H,m=W,y=G,w=z,R=65535&(x=K),C=x>>>16,T=65535&(E=U),O=E>>>16,R+=65535&(x=(W>>>14|N<<18)^(W>>>18|N<<14)^(N>>>9|W<<23)),C+=x>>>16,T+=65535&(E=(N>>>14|W<<18)^(N>>>18|W<<14)^(W>>>9|N<<23)),O+=E>>>16,R+=65535&(x=W&G^~W&z),C+=x>>>16,T+=65535&(E=N&L^~N&M),O+=E>>>16,E=Y[2*S],R+=65535&(x=Y[2*S+1]),C+=x>>>16,T+=65535&E,O+=E>>>16,E=P[S%16],C+=(x=I[S%16])>>>16,T+=65535&E,O+=E>>>16,T+=(C+=(R+=65535&x)>>>16)>>>16,R=65535&(x=_=65535&R|C<<16),C=x>>>16,T=65535&(E=v=65535&T|(O+=T>>>16)<<16),O=E>>>16,R+=65535&(x=(F>>>28|k<<4)^(k>>>2|F<<30)^(k>>>7|F<<25)),C+=x>>>16,T+=65535&(E=(k>>>28|F<<4)^(F>>>2|k<<30)^(F>>>7|k<<25)),O+=E>>>16,C+=(x=F&q^F&$^q&$)>>>16,T+=65535&(E=k&j^k&D^j&D),O+=E>>>16,l=65535&(T+=(C+=(R+=65535&x)>>>16)>>>16)|(O+=T>>>16)<<16,b=65535&R|C<<16,R=65535&(x=g),C=x>>>16,T=65535&(E=s),O=E>>>16,C+=(x=_)>>>16,T+=65535&(E=v),O+=E>>>16,j=o,D=i,B=a,N=s=65535&(T+=(C+=(R+=65535&x)>>>16)>>>16)|(O+=T>>>16)<<16,L=c,M=h,U=u,k=l,q=p,$=d,H=f,W=g=65535&R|C<<16,G=m,z=y,K=w,F=b,S%16==15)for(A=0;A<16;A++)E=P[A],R=65535&(x=I[A]),C=x>>>16,T=65535&E,O=E>>>16,E=P[(A+9)%16],R+=65535&(x=I[(A+9)%16]),C+=x>>>16,T+=65535&E,O+=E>>>16,v=P[(A+1)%16],R+=65535&(x=((_=I[(A+1)%16])>>>1|v<<31)^(_>>>8|v<<24)^(_>>>7|v<<25)),C+=x>>>16,T+=65535&(E=(v>>>1|_<<31)^(v>>>8|_<<24)^v>>>7),O+=E>>>16,v=P[(A+14)%16],C+=(x=((_=I[(A+14)%16])>>>19|v<<13)^(v>>>29|_<<3)^(_>>>6|v<<26))>>>16,T+=65535&(E=(v>>>19|_<<13)^(_>>>29|v<<3)^v>>>6),O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,P[A]=65535&T|O<<16,I[A]=65535&R|C<<16;R=65535&(x=F),C=x>>>16,T=65535&(E=k),O=E>>>16,E=e[0],C+=(x=t[0])>>>16,T+=65535&E,O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,e[0]=k=65535&T|O<<16,t[0]=F=65535&R|C<<16,R=65535&(x=q),C=x>>>16,T=65535&(E=j),O=E>>>16,E=e[1],C+=(x=t[1])>>>16,T+=65535&E,O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,e[1]=j=65535&T|O<<16,t[1]=q=65535&R|C<<16,R=65535&(x=$),C=x>>>16,T=65535&(E=D),O=E>>>16,E=e[2],C+=(x=t[2])>>>16,T+=65535&E,O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,e[2]=D=65535&T|O<<16,t[2]=$=65535&R|C<<16,R=65535&(x=H),C=x>>>16,T=65535&(E=B),O=E>>>16,E=e[3],C+=(x=t[3])>>>16,T+=65535&E,O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,e[3]=B=65535&T|O<<16,t[3]=H=65535&R|C<<16,R=65535&(x=W),C=x>>>16,T=65535&(E=N),O=E>>>16,E=e[4],C+=(x=t[4])>>>16,T+=65535&E,O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,e[4]=N=65535&T|O<<16,t[4]=W=65535&R|C<<16,R=65535&(x=G),C=x>>>16,T=65535&(E=L),O=E>>>16,E=e[5],C+=(x=t[5])>>>16,T+=65535&E,O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,e[5]=L=65535&T|O<<16,t[5]=G=65535&R|C<<16,R=65535&(x=z),C=x>>>16,T=65535&(E=M),O=E>>>16,E=e[6],C+=(x=t[6])>>>16,T+=65535&E,O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,e[6]=M=65535&T|O<<16,t[6]=z=65535&R|C<<16,R=65535&(x=K),C=x>>>16,T=65535&(E=U),O=E>>>16,E=e[7],C+=(x=t[7])>>>16,T+=65535&E,O+=E>>>16,O+=(T+=(C+=(R+=65535&x)>>>16)>>>16)>>>16,e[7]=U=65535&T|O<<16,t[7]=K=65535&R|C<<16,V+=128,n-=128}return n}function J(e,t,r){var n,o=new Int32Array(8),i=new Int32Array(8),a=new Uint8Array(256),s=r;for(o[0]=1779033703,o[1]=3144134277,o[2]=1013904242,o[3]=2773480762,o[4]=1359893119,o[5]=2600822924,o[6]=528734635,o[7]=1541459225,i[0]=4089235720,i[1]=2227873595,i[2]=4271175723,i[3]=1595750129,i[4]=2917565137,i[5]=725511199,i[6]=4215389547,i[7]=327033209,Q(o,i,t,r),r%=128,n=0;n=0;--o)X(e,t,n=r[o/8|0]>>(7&o)&1),Z(t,e),Z(e,e),X(e,t,n)}function re(e,r){var n=[t(),t(),t(),t()];P(n[0],l),P(n[1],p),P(n[2],s),U(n[3],l,p),te(e,n,r)}function ne(e,r,o){var i,a=new Uint8Array(64),s=[t(),t(),t(),t()];for(o||n(r,32),J(a,r,32),a[0]&=248,a[31]&=127,a[31]|=64,re(s,a),ee(e,s),i=0;i<32;i++)r[i+32]=e[i];return 0}var oe=new Float64Array([237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16]);function ie(e,t){var r,n,o,i;for(n=63;n>=32;--n){for(r=0,o=n-32,i=n-12;o>4)*oe[o],r=t[o]>>8,t[o]&=255;for(o=0;o<32;o++)t[o]-=r*oe[o];for(n=0;n<32;n++)t[n+1]+=t[n]>>8,e[n]=255&t[n]}function ae(e){var t,r=new Float64Array(64);for(t=0;t<64;t++)r[t]=e[t];for(t=0;t<64;t++)e[t]=0;ie(e,r)}function se(e,r,n,o){var i,a,s=new Uint8Array(64),c=new Uint8Array(64),h=new Uint8Array(64),u=new Float64Array(64),l=[t(),t(),t(),t()];J(s,o,32),s[0]&=248,s[31]&=127,s[31]|=64;var p=n+64;for(i=0;i>7&&M(e[0],a,e[0]),U(e[3],e[0],e[1]),0)}(p,o))return-1;for(i=0;i=0},e.sign.keyPair=function(){var e=new Uint8Array(fe),t=new Uint8Array(ge);return ne(e,t),{publicKey:e,secretKey:t}},e.sign.keyPair.fromSecretKey=function(e){if(ye(e),e.length!==ge)throw new Error("bad secret key size");for(var t=new Uint8Array(fe),r=0;r{}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={exports:{}};return e[n].call(i.exports,i,i.exports,r),i.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";var e=r(998),t=r.n(e),n=r(475),o=r.n(n);const i="http://www.w3.org/1999/02/22-rdf-syntax-ns#",a="http://www.w3.org/2001/XMLSchema#",s="http://www.w3.org/2000/10/swap/",c={xsd:{decimal:`${a}decimal`,boolean:`${a}boolean`,double:`${a}double`,integer:`${a}integer`,string:`${a}string`},rdf:{type:`${i}type`,nil:`${i}nil`,first:`${i}first`,rest:`${i}rest`,langString:`${i}langString`},owl:{sameAs:"http://www.w3.org/2002/07/owl#sameAs"},r:{forSome:`${s}reify#forSome`,forAll:`${s}reify#forAll`},log:{implies:`${s}log#implies`}};function h(e){return!!e&&"DefaultGraph"===e.termType}const{rdf:u,xsd:l}=c;let p,d=0;const f=/^"(.*".*)(?="[^"]*$)/,g=/^<<("(?:""|[^"])*"[^ ]*|[^ ]+) ("(?:""|[^"])*"[^ ]*|[^ ]+) ("(?:""|[^"])*"[^ ]*|[^ ]+) ?("(?:""|[^"])*"[^ ]*|[^ ]+)?>>$/,m={namedNode:function(e){return new b(e)},blankNode:function(e){return new _(e||"n3-"+d++)},variable:function(e){return new S(e)},literal:function(e,t){if("string"==typeof t)return new v(`"${e}"@${t.toLowerCase()}`);let r=t?t.value:"";return""===r&&("boolean"==typeof e?r=l.boolean:"number"==typeof e&&(Number.isFinite(e)?r=Number.isInteger(e)?l.integer:l.double:(r=l.double,Number.isNaN(e)||(e=e>0?"INF":"-INF")))),""===r||r===l.string?new v(`"${e}"`):new v(`"${e}"^^${r}`)},defaultGraph:function(){return p},quad:T,triple:T},y=m;class w{constructor(e){this.id=e}get value(){return this.id}equals(e){return e instanceof w?this.id===e.id:!!e&&this.termType===e.termType&&this.value===e.value}hashCode(){return 0}toJSON(){return{termType:this.termType,value:this.value}}}class b extends w{get termType(){return"NamedNode"}}class v extends w{get termType(){return"Literal"}get value(){return this.id.substring(1,this.id.lastIndexOf('"'))}get language(){const e=this.id;let t=e.lastIndexOf('"')+1;return t>`;default:throw new Error(`Unexpected termType: ${e.termType}`)}}p=new class extends w{constructor(){return super(""),p||this}get termType(){return"DefaultGraph"}equals(e){return this===e||!!e&&this.termType===e.termType}};class x extends w{constructor(e,t,r,n){super(""),this._subject=e,this._predicate=t,this._object=r,this._graph=n||p}get termType(){return"Quad"}get subject(){return this._subject}get predicate(){return this._predicate}get object(){return this._object}get graph(){return this._graph}toJSON(){return{termType:this.termType,subject:this._subject.toJSON(),predicate:this._predicate.toJSON(),object:this._object.toJSON(),graph:this._graph.toJSON()}}equals(e){return!!e&&this._subject.equals(e.subject)&&this._predicate.equals(e.predicate)&&this._object.equals(e.object)&&this._graph.equals(e.graph)}}function R(e){return e.replace(f,((e,t)=>`"${t.replace(/"/g,'""')}`))}function C(e){return e.replace(f,((e,t)=>`"${t.replace(/""/g,'"')}`))}function T(e,t,r,n){return new x(e,t,r,n)}const O=y.defaultGraph(),{rdf:P,xsd:I}=c,k=/["\\\t\n\r\b\f\u0000-\u0019\ud800-\udbff]/,j=/["\\\t\n\r\b\f\u0000-\u0019]|[\ud800-\udbff][\udc00-\udfff]/g,D={"\\":"\\\\",'"':'\\"',"\t":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"};class B extends w{equals(){return!1}}class N{constructor(e,t){if(this._prefixRegex=/$0^/,e&&"function"!=typeof e.write&&(t=e,e=null),t=t||{},this._lists=t.lists,e)this._outputStream=e,this._endStream=void 0===t.end||!!t.end;else{let e="";this._outputStream={write(t,r,n){e+=t,n&&n()},end:t=>{t&&t(null,e)}},this._endStream=!0}this._subject=null,/triple|quad/i.test(t.format)?(this._lineMode=!0,this._writeQuad=this._writeQuadLine):(this._lineMode=!1,this._graph=O,this._prefixIRIs=Object.create(null),t.prefixes&&this.addPrefixes(t.prefixes),t.baseIRI&&(this._baseMatcher=new RegExp(`^${M(t.baseIRI)}${t.baseIRI.endsWith("/")?"":"[#?]"}`),this._baseLength=t.baseIRI.length))}get _inDefaultGraph(){return O.equals(this._graph)}_write(e,t){this._outputStream.write(e,"utf8",t)}_writeQuad(e,t,r,n,o){try{n.equals(this._graph)||(this._write((null===this._subject?"":this._inDefaultGraph?".\n":"\n}\n")+(O.equals(n)?"":`${this._encodeIriOrBlank(n)} {\n`)),this._graph=n,this._subject=null),e.equals(this._subject)?t.equals(this._predicate)?this._write(`, ${this._encodeObject(r)}`,o):this._write(`;\n ${this._encodePredicate(this._predicate=t)} ${this._encodeObject(r)}`,o):this._write(`${(null===this._subject?"":".\n")+this._encodeSubject(this._subject=e)} ${this._encodePredicate(this._predicate=t)} ${this._encodeObject(r)}`,o)}catch(e){o&&o(e)}}_writeQuadLine(e,t,r,n,o){delete this._prefixMatch,this._write(this.quadToString(e,t,r,n),o)}quadToString(e,t,r,n){return`${this._encodeSubject(e)} ${this._encodeIriOrBlank(t)} ${this._encodeObject(r)}${n&&n.value?` ${this._encodeIriOrBlank(n)} .\n`:" .\n"}`}quadsToString(e){return e.map((e=>this.quadToString(e.subject,e.predicate,e.object,e.graph))).join("")}_encodeSubject(e){return"Quad"===e.termType?this._encodeQuad(e):this._encodeIriOrBlank(e)}_encodeIriOrBlank(e){if("NamedNode"!==e.termType)return this._lists&&e.value in this._lists&&(e=this.list(this._lists[e.value])),"id"in e?e.id:`_:${e.value}`;let t=e.value;this._baseMatcher&&this._baseMatcher.test(t)&&(t=t.substr(this._baseLength)),k.test(t)&&(t=t.replace(j,L));const r=this._prefixRegex.exec(t);return r?r[1]?this._prefixIRIs[r[1]]+r[2]:t:`<${t}>`}_encodeLiteral(e){let t=e.value;if(k.test(t)&&(t=t.replace(j,L)),e.language)return`"${t}"@${e.language}`;if(this._lineMode){if(e.datatype.value===I.string)return`"${t}"`}else switch(e.datatype.value){case I.string:return`"${t}"`;case I.boolean:if("true"===t||"false"===t)return t;break;case I.integer:if(/^[+-]?\d+$/.test(t))return t;break;case I.decimal:if(/^[+-]?\d*\.\d+$/.test(t))return t;break;case I.double:if(/^[+-]?(?:\d+\.\d*|\.?\d+)[eE][+-]?\d+$/.test(t))return t}return`"${t}"^^${this._encodeIriOrBlank(e.datatype)}`}_encodePredicate(e){return e.value===P.type?"a":this._encodeIriOrBlank(e)}_encodeObject(e){switch(e.termType){case"Quad":return this._encodeQuad(e);case"Literal":return this._encodeLiteral(e);default:return this._encodeIriOrBlank(e)}}_encodeQuad({subject:e,predicate:t,object:r,graph:n}){return`<<${this._encodeSubject(e)} ${this._encodePredicate(t)} ${this._encodeObject(r)}${h(n)?"":` ${this._encodeIriOrBlank(n)}`}>>`}_blockedWrite(){throw new Error("Cannot write because the writer has been closed.")}addQuad(e,t,r,n,o){void 0===r?this._writeQuad(e.subject,e.predicate,e.object,e.graph,t):"function"==typeof n?this._writeQuad(e,t,r,O,n):this._writeQuad(e,t,r,n||O,o)}addQuads(e){for(let t=0;t.\n`)}if(r){let e="",t="";for(const r in this._prefixIRIs)e+=e?`|${r}`:r,t+=(t?"|":"")+this._prefixIRIs[r];e=M(e),this._prefixRegex=new RegExp(`^(?:${t})[^/]*$|^(${e})([_a-zA-Z][\\-_a-zA-Z0-9]*)$`)}this._write(r?"\n":"",t)}blank(e,t){let r,n,o=e;switch(void 0===e?o=[]:e.termType?o=[{predicate:e,object:t}]:"length"in e||(o=[e]),n=o.length){case 0:return new B("[]");case 1:if(r=o[0],!(r.object instanceof B))return new B(`[ ${this._encodePredicate(r.predicate)} ${this._encodeObject(r.object)} ]`);default:let t="[";for(let i=0;i{t=null,e(r,n)});if(this._endStream)try{return this._outputStream.end(t)}catch(e){}t&&t()}}function L(e){let t=D[e];return void 0===t&&(1===e.length?(t=e.charCodeAt(0).toString(16),t="\\u0000".substr(0,6-t.length)+t):(t=(1024*(e.charCodeAt(0)-55296)+e.charCodeAt(1)+9216).toString(16),t="\\U00000000".substr(0,10-t.length)+t)),t}function M(e){return e.replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&")}var U=r(375),F=r.n(U);const{xsd:q}=c,H=/\\u([a-fA-F0-9]{4})|\\U([a-fA-F0-9]{8})|\\([^])/g,W={"\\":"\\","'":"'",'"':'"',n:"\n",r:"\r",t:"\t",f:"\f",b:"\b",_:"_","~":"~",".":".","-":"-","!":"!",$:"$","&":"&","(":"(",")":")","*":"*","+":"+",",":",",";":";","=":"=","/":"/","?":"?","#":"#","@":"@","%":"%"},G=/[\x00-\x20<>\\"\{\}\|\^\`]/,z={_iri:!0,_unescapedIri:!0,_simpleQuotedString:!0,_langcode:!0,_blank:!0,_newline:!0,_comment:!0,_whitespace:!0,_endOfFile:!0},K=/$0^/;class V{constructor(e){if(this._iri=/^<((?:[^ <>{}\\]|\\[uU])+)>[ \t]*/,this._unescapedIri=/^<([^\x00-\x20<>\\"\{\}\|\^\`]*)>[ \t]*/,this._simpleQuotedString=/^"([^"\\\r\n]*)"(?=[^"])/,this._simpleApostropheString=/^'([^'\\\r\n]*)'(?=[^'])/,this._langcode=/^@([a-z]+(?:-[a-z0-9]+)*)(?=[^a-z0-9\-])/i,this._prefix=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:(?=[#\s<])/,this._prefixed=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:((?:(?:[0-:A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])(?:(?:[\.\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])*(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~]))?)?)(?:[ \t]+|(?=\.?[,;!\^\s#()\[\]\{\}"'<>]))/,this._variable=/^\?(?:(?:[A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?=[.,;!\^\s#()\[\]\{\}"'<>])/,this._blank=/^_:((?:[0-9A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?:[ \t]+|(?=\.?[,;:\s#()\[\]\{\}"'<>]))/,this._number=/^[\-+]?(?:(\d+\.\d*|\.?\d+)[eE][\-+]?|\d*(\.)?)\d+(?=\.?[,;:\s#()\[\]\{\}"'<>])/,this._boolean=/^(?:true|false)(?=[.,;\s#()\[\]\{\}"'<>])/,this._keyword=/^@[a-z]+(?=[\s#<:])/i,this._sparqlKeyword=/^(?:PREFIX|BASE|GRAPH)(?=[\s#<])/i,this._shortPredicates=/^a(?=[\s#()\[\]\{\}"'<>])/,this._newline=/^[ \t]*(?:#[^\n\r]*)?(?:\r\n|\n|\r)[ \t]*/,this._comment=/#([^\n\r]*)/,this._whitespace=/^[ \t]+/,this._endOfFile=/^(?:#[^\n\r]*)?$/,e=e||{},this._lineMode=!!e.lineMode){this._n3Mode=!1;for(const e in this)!(e in z)&&this[e]instanceof RegExp&&(this[e]=K)}else this._n3Mode=!1!==e.n3;this._comments=!!e.comments,this._literalClosingPos=0}_tokenizeToEnd(e,t){let r=this._input,n=r.length;for(;;){let e,a;for(;e=this._newline.exec(r);)this._comments&&(a=this._comment.exec(e[0]))&&o("comment",a[1],"",this._line,e[0].length),r=r.substr(e[0].length,r.length),n=r.length,this._line++;if(!e&&(e=this._whitespace.exec(r))&&(r=r.substr(e[0].length,r.length)),this._endOfFile.test(r))return t&&(this._comments&&(a=this._comment.exec(r))&&o("comment",a[1],"",this._line,r.length),r=null,o("eof","","",this._line,0)),this._input=r;const s=this._line,c=r[0];let h="",u="",l="",p=null,d=0,f=!1;switch(c){case"^":if(r.length<3)break;if("^"!==r[1]){this._n3Mode&&(d=1,h="^");break}if(this._previousMarker="^^",r=r.substr(2),"<"!==r[0]){f=!0;break}case"<":if(p=this._unescapedIri.exec(r))h="IRI",u=p[1];else if(p=this._iri.exec(r)){if(u=this._unescape(p[1]),null===u||G.test(u))return i(this);h="IRI"}else r.length>1&&"<"===r[1]?(h="<<",d=2):this._n3Mode&&r.length>1&&"="===r[1]&&(h="inverse",d=2,u=">");break;case">":r.length>1&&">"===r[1]&&(h=">>",d=2);break;case"_":((p=this._blank.exec(r))||t&&(p=this._blank.exec(`${r} `)))&&(h="blank",l="_",u=p[1]);break;case'"':if(p=this._simpleQuotedString.exec(r))u=p[1];else if(({value:u,matchLength:d}=this._parseLiteral(r)),null===u)return i(this);null===p&&0===d||(h="literal",this._literalClosingPos=0);break;case"'":if(!this._lineMode){if(p=this._simpleApostropheString.exec(r))u=p[1];else if(({value:u,matchLength:d}=this._parseLiteral(r)),null===u)return i(this);null===p&&0===d||(h="literal",this._literalClosingPos=0)}break;case"?":this._n3Mode&&(p=this._variable.exec(r))&&(h="var",u=p[0]);break;case"@":"literal"===this._previousMarker&&(p=this._langcode.exec(r))?(h="langcode",u=p[1]):(p=this._keyword.exec(r))&&(h=p[0]);break;case".":if(1===r.length?t:r[1]<"0"||r[1]>"9"){h=".",d=1;break}case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"+":case"-":(p=this._number.exec(r)||t&&(p=this._number.exec(`${r} `)))&&(h="literal",u=p[0],l="string"==typeof p[1]?q.double:"string"==typeof p[2]?q.decimal:q.integer);break;case"B":case"b":case"p":case"P":case"G":case"g":(p=this._sparqlKeyword.exec(r))?h=p[0].toUpperCase():f=!0;break;case"f":case"t":(p=this._boolean.exec(r))?(h="literal",u=p[0],l=q.boolean):f=!0;break;case"a":(p=this._shortPredicates.exec(r))?(h="abbreviation",u="a"):f=!0;break;case"=":this._n3Mode&&r.length>1&&(h="abbreviation",">"!==r[1]?(d=1,u="="):(d=2,u=">"));break;case"!":if(!this._n3Mode)break;case",":case";":case"[":case"]":case"(":case")":case"{":case"}":this._lineMode||(d=1,h=c);break;default:f=!0}if(f&&("@prefix"!==this._previousMarker&&"PREFIX"!==this._previousMarker||!(p=this._prefix.exec(r))?((p=this._prefixed.exec(r))||t&&(p=this._prefixed.exec(`${r} `)))&&(h="prefixed",l=p[1]||"",u=this._unescape(p[2])):(h="prefix",u=p[1]||"")),"^^"===this._previousMarker)switch(h){case"prefixed":h="type";break;case"IRI":h="typeIRI";break;default:h=""}if(!h)return t||!/^'''|^"""/.test(r)&&/\n|\r/.test(r)?i(this):this._input=r;const g=d||p[0].length,m=o(h,u,l,s,g);this.previousToken=m,this._previousMarker=h,r=r.substr(g,r.length)}function o(t,o,i,a,s){const c=r?n-r.length:n,h={type:t,value:o,prefix:i,line:a,start:c,end:c+s};return e(null,h),h}function i(t){e(t._syntaxError(/^\S*/.exec(r)[0]))}}_unescape(e){let t=!1;const r=e.replace(H,((e,r,n,o)=>{if("string"==typeof r)return String.fromCharCode(Number.parseInt(r,16));if("string"==typeof n){let e=Number.parseInt(n,16);return e<=65535?String.fromCharCode(Number.parseInt(n,16)):String.fromCharCode(55296+((e-=65536)>>10),56320+(1023&e))}return o in W?W[o]:(t=!0,"")}));return t?null:r}_parseLiteral(e){if(e.length>=3){const t=e.match(/^(?:"""|"|'''|'|)/)[0],r=t.length;let n=Math.max(this._literalClosingPos,r);for(;(n=e.indexOf(t,n))>0;){let t=0;for(;"\\"===e[n-t-1];)t++;if(t%2==0){const t=e.substring(r,n),o=t.split(/\r\n|\r|\n/).length-1,i=n+r;if(1===r&&0!==o||3===r&&this._lineMode)break;return this._line+=o,{value:this._unescape(t),matchLength:i}}n++}this._literalClosingPos=e.length-r+1}return{value:"",matchLength:0}}_syntaxError(e){this._input=null;const t=new Error(`Unexpected "${e}" on line ${this._line}.`);return t.context={token:void 0,line:this._line,previousToken:this.previousToken},t}_readStartingBom(e){return e.startsWith("\ufeff")?e.substr(1):e}tokenize(e,t){if(this._line=1,"string"==typeof e){if(this._input=this._readStartingBom(e),"function"!=typeof t){const e=[];let t;if(this._tokenizeToEnd(((r,n)=>r?t=r:e.push(n)),!0),t)throw t;return e}F()((()=>this._tokenizeToEnd(t,!0)))}else this._pendingBuffer=null,"function"==typeof e.setEncoding&&e.setEncoding("utf8"),e.on("data",(e=>{null!==this._input&&0!==e.length&&(this._pendingBuffer&&(e=Buffer.concat([this._pendingBuffer,e]),this._pendingBuffer=null),128&e[e.length-1]?this._pendingBuffer=e:(void 0===this._input?this._input=this._readStartingBom("string"==typeof e?e:e.toString()):this._input+=e,this._tokenizeToEnd(t,!1)))})),e.on("end",(()=>{"string"==typeof this._input&&this._tokenizeToEnd(t,!0)})),e.on("error",t)}}let Y=0;class Q{constructor(e){this._contextStack=[],this._graph=null,e=e||{},this._setBase(e.baseIRI),e.factory&&Z(this,e.factory);const t="string"==typeof e.format?e.format.match(/\w*$/)[0].toLowerCase():"",r=/turtle/.test(t),n=/trig/.test(t),o=/triple/.test(t),i=/quad/.test(t),a=this._n3Mode=/n3/.test(t),s=o||i;(this._supportsNamedGraphs=!(r||a))||(this._readPredicateOrNamedGraph=this._readPredicate),this._supportsQuads=!(r||n||o||a),this._supportsRDFStar=""===t||/star|\*$/.test(t),s&&(this._resolveRelativeIRI=e=>null),this._blankNodePrefix="string"!=typeof e.blankNodePrefix?"":e.blankNodePrefix.replace(/^(?!_:)/,"_:"),this._lexer=e.lexer||new V({lineMode:s,n3:a}),this._explicitQuantifiers=!!e.explicitQuantifiers}static _resetBlankNodePrefix(){Y=0}_setBase(e){if(e){const t=e.indexOf("#");t>=0&&(e=e.substr(0,t)),this._base=e,this._basePath=e.indexOf("/")<0?e:e.replace(/[^\/?]*(?:\?.*)?$/,""),e=e.match(/^(?:([a-z][a-z0-9+.-]*:))?(?:\/\/[^\/]*)?/i),this._baseRoot=e[0],this._baseScheme=e[1]}else this._base="",this._basePath=""}_saveContext(e,t,r,n,o){const i=this._n3Mode;this._contextStack.push({type:e,subject:r,predicate:n,object:o,graph:t,inverse:!!i&&this._inversePredicate,blankPrefix:i?this._prefixes._:"",quantified:i?this._quantified:null}),i&&(this._inversePredicate=!1,this._prefixes._=this._graph?`${this._graph.id.substr(2)}.`:".",this._quantified=Object.create(this._quantified))}_restoreContext(e,t){const r=this._contextStack.pop();if(!r||r.type!==e)return this._error(`Unexpected ${t.type}`,t);this._subject=r.subject,this._predicate=r.predicate,this._object=r.object,this._graph=r.graph,this._n3Mode&&(this._inversePredicate=r.inverse,this._prefixes._=r.blankPrefix,this._quantified=r.quantified)}_readInTopContext(e){switch(e.type){case"eof":return null!==this._graph?this._error("Unclosed graph",e):(delete this._prefixes._,this._callback(null,null,this._prefixes));case"PREFIX":this._sparqlStyle=!0;case"@prefix":return this._readPrefix;case"BASE":this._sparqlStyle=!0;case"@base":return this._readBaseIRI;case"{":if(this._supportsNamedGraphs)return this._graph="",this._subject=null,this._readSubject;case"GRAPH":if(this._supportsNamedGraphs)return this._readNamedGraphLabel;default:return this._readSubject(e)}}_readEntity(e,t){let r;switch(e.type){case"IRI":case"typeIRI":const t=this._resolveIRI(e.value);if(null===t)return this._error("Invalid IRI",e);r=this._namedNode(t);break;case"type":case"prefixed":const n=this._prefixes[e.prefix];if(void 0===n)return this._error(`Undefined prefix "${e.prefix}:"`,e);r=this._namedNode(n+e.value);break;case"blank":r=this._blankNode(this._prefixes[e.prefix]+e.value);break;case"var":r=this._variable(e.value.substr(1));break;default:return this._error(`Expected entity but got ${e.type}`,e)}return!t&&this._n3Mode&&r.id in this._quantified&&(r=this._quantified[r.id]),r}_readSubject(e){switch(this._predicate=null,e.type){case"[":return this._saveContext("blank",this._graph,this._subject=this._blankNode(),null,null),this._readBlankNodeHead;case"(":return this._saveContext("list",this._graph,this.RDF_NIL,null,null),this._subject=null,this._readListItem;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._graph=this._blankNode(),null,null),this._readSubject):this._error("Unexpected graph",e);case"}":return this._readPunctuation(e);case"@forSome":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORSOME,this._quantifier=this._blankNode,this._readQuantifierList):this._error('Unexpected "@forSome"',e);case"@forAll":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORALL,this._quantifier=this._variable,this._readQuantifierList):this._error('Unexpected "@forAll"',e);case"literal":if(!this._n3Mode)return this._error("Unexpected literal",e);if(0===e.prefix.length)return this._literalValue=e.value,this._completeSubjectLiteral;this._subject=this._literal(e.value,this._namedNode(e.prefix));break;case"<<":return this._supportsRDFStar?(this._saveContext("<<",this._graph,null,null,null),this._graph=null,this._readSubject):this._error("Unexpected RDF* syntax",e);default:if(void 0===(this._subject=this._readEntity(e)))return;if(this._n3Mode)return this._getPathReader(this._readPredicateOrNamedGraph)}return this._readPredicateOrNamedGraph}_readPredicate(e){const t=e.type;switch(t){case"inverse":this._inversePredicate=!0;case"abbreviation":this._predicate=this.ABBREVIATIONS[e.value];break;case".":case"]":case"}":return null===this._predicate?this._error(`Unexpected ${t}`,e):(this._subject=null,"]"===t?this._readBlankNodeTail(e):this._readPunctuation(e));case";":return null!==this._predicate?this._readPredicate:this._error("Expected predicate but got ;",e);case"[":if(this._n3Mode)return this._saveContext("blank",this._graph,this._subject,this._subject=this._blankNode(),null),this._readBlankNodeHead;case"blank":if(!this._n3Mode)return this._error("Disallowed blank node as predicate",e);default:if(void 0===(this._predicate=this._readEntity(e)))return}return this._readObject}_readObject(e){switch(e.type){case"literal":if(0===e.prefix.length)return this._literalValue=e.value,this._readDataTypeOrLang;this._object=this._literal(e.value,this._namedNode(e.prefix));break;case"[":return this._saveContext("blank",this._graph,this._subject,this._predicate,this._subject=this._blankNode()),this._readBlankNodeHead;case"(":return this._saveContext("list",this._graph,this._subject,this._predicate,this.RDF_NIL),this._subject=null,this._readListItem;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._blankNode()),this._readSubject):this._error("Unexpected graph",e);case"<<":return this._supportsRDFStar?(this._saveContext("<<",this._graph,this._subject,this._predicate,null),this._graph=null,this._readSubject):this._error("Unexpected RDF* syntax",e);default:if(void 0===(this._object=this._readEntity(e)))return;if(this._n3Mode)return this._getPathReader(this._getContextEndReader())}return this._getContextEndReader()}_readPredicateOrNamedGraph(e){return"{"===e.type?this._readGraph(e):this._readPredicate(e)}_readGraph(e){return"{"!==e.type?this._error(`Expected graph but got ${e.type}`,e):(this._graph=this._subject,this._subject=null,this._readSubject)}_readBlankNodeHead(e){return"]"===e.type?(this._subject=null,this._readBlankNodeTail(e)):(this._predicate=null,this._readPredicate(e))}_readBlankNodeTail(e){if("]"!==e.type)return this._readBlankNodePunctuation(e);null!==this._subject&&this._emit(this._subject,this._predicate,this._object,this._graph);const t=null===this._predicate;return this._restoreContext("blank",e),null!==this._object?this._getContextEndReader():null!==this._predicate?this._readObject:t?this._readPredicateOrNamedGraph:this._readPredicateAfterBlank}_readPredicateAfterBlank(e){switch(e.type){case".":case"}":return this._subject=null,this._readPunctuation(e);default:return this._readPredicate(e)}}_readListItem(e){let t=null,r=null,n=this._readListItem;const o=this._subject,i=this._contextStack,a=i[i.length-1];switch(e.type){case"[":this._saveContext("blank",this._graph,r=this._blankNode(),this.RDF_FIRST,this._subject=t=this._blankNode()),n=this._readBlankNodeHead;break;case"(":this._saveContext("list",this._graph,r=this._blankNode(),this.RDF_FIRST,this.RDF_NIL),this._subject=null;break;case")":if(this._restoreContext("list",e),0!==i.length&&"list"===i[i.length-1].type&&this._emit(this._subject,this._predicate,this._object,this._graph),null===this._predicate){if(n=this._readPredicate,this._subject===this.RDF_NIL)return n}else if(n=this._getContextEndReader(),this._object===this.RDF_NIL)return n;r=this.RDF_NIL;break;case"literal":0===e.prefix.length?(this._literalValue=e.value,n=this._readListItemDataTypeOrLang):(t=this._literal(e.value,this._namedNode(e.prefix)),n=this._getContextEndReader());break;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._blankNode()),this._readSubject):this._error("Unexpected graph",e);default:if(void 0===(t=this._readEntity(e)))return}if(null===r&&(this._subject=r=this._blankNode()),null===o?null===a.predicate?a.subject=r:a.object=r:this._emit(o,this.RDF_REST,r,this._graph),null!==t){if(this._n3Mode&&("IRI"===e.type||"prefixed"===e.type))return this._saveContext("item",this._graph,r,this.RDF_FIRST,t),this._subject=t,this._predicate=null,this._getPathReader(this._readListItem);this._emit(r,this.RDF_FIRST,t,this._graph)}return n}_readDataTypeOrLang(e){return this._completeObjectLiteral(e,!1)}_readListItemDataTypeOrLang(e){return this._completeObjectLiteral(e,!0)}_completeLiteral(e){let t=this._literal(this._literalValue);switch(e.type){case"type":case"typeIRI":const r=this._readEntity(e);if(void 0===r)return;t=this._literal(this._literalValue,r),e=null;break;case"langcode":t=this._literal(this._literalValue,e.value),e=null}return{token:e,literal:t}}_completeSubjectLiteral(e){return this._subject=this._completeLiteral(e).literal,this._readPredicateOrNamedGraph}_completeObjectLiteral(e,t){const r=this._completeLiteral(e);if(r)return this._object=r.literal,t&&this._emit(this._subject,this.RDF_FIRST,this._object,this._graph),null===r.token?this._getContextEndReader():(this._readCallback=this._getContextEndReader(),this._readCallback(r.token))}_readFormulaTail(e){return"}"!==e.type?this._readPunctuation(e):(null!==this._subject&&this._emit(this._subject,this._predicate,this._object,this._graph),this._restoreContext("formula",e),null===this._object?this._readPredicate:this._getContextEndReader())}_readPunctuation(e){let t,r=this._graph;const n=this._subject,o=this._inversePredicate;switch(e.type){case"}":if(null===this._graph)return this._error("Unexpected graph closing",e);if(this._n3Mode)return this._readFormulaTail(e);this._graph=null;case".":this._subject=null,t=this._contextStack.length?this._readSubject:this._readInTopContext,o&&(this._inversePredicate=!1);break;case";":t=this._readPredicate;break;case",":t=this._readObject;break;default:if(this._supportsQuads&&null===this._graph&&void 0!==(r=this._readEntity(e))){t=this._readQuadPunctuation;break}return this._error(`Expected punctuation to follow "${this._object.id}"`,e)}if(null!==n){const e=this._predicate,t=this._object;o?this._emit(t,e,n,r):this._emit(n,e,t,r)}return t}_readBlankNodePunctuation(e){let t;switch(e.type){case";":t=this._readPredicate;break;case",":t=this._readObject;break;default:return this._error(`Expected punctuation to follow "${this._object.id}"`,e)}return this._emit(this._subject,this._predicate,this._object,this._graph),t}_readQuadPunctuation(e){return"."!==e.type?this._error("Expected dot to follow quad",e):this._readInTopContext}_readPrefix(e){return"prefix"!==e.type?this._error("Expected prefix to follow @prefix",e):(this._prefix=e.value,this._readPrefixIRI)}_readPrefixIRI(e){if("IRI"!==e.type)return this._error(`Expected IRI to follow prefix "${this._prefix}:"`,e);const t=this._readEntity(e);return this._prefixes[this._prefix]=t.value,this._prefixCallback(this._prefix,t),this._readDeclarationPunctuation}_readBaseIRI(e){const t="IRI"===e.type&&this._resolveIRI(e.value);return t?(this._setBase(t),this._readDeclarationPunctuation):this._error("Expected valid IRI to follow base declaration",e)}_readNamedGraphLabel(e){switch(e.type){case"IRI":case"blank":case"prefixed":return this._readSubject(e),this._readGraph;case"[":return this._readNamedGraphBlankLabel;default:return this._error("Invalid graph label",e)}}_readNamedGraphBlankLabel(e){return"]"!==e.type?this._error("Invalid graph label",e):(this._subject=this._blankNode(),this._readGraph)}_readDeclarationPunctuation(e){return this._sparqlStyle?(this._sparqlStyle=!1,this._readInTopContext(e)):"."!==e.type?this._error("Expected declaration to end with a dot",e):this._readInTopContext}_readQuantifierList(e){let t;switch(e.type){case"IRI":case"prefixed":if(void 0!==(t=this._readEntity(e,!0)))break;default:return this._error(`Unexpected ${e.type}`,e)}return this._explicitQuantifiers?(null===this._subject?this._emit(this._graph||this.DEFAULTGRAPH,this._predicate,this._subject=this._blankNode(),this.QUANTIFIERS_GRAPH):this._emit(this._subject,this.RDF_REST,this._subject=this._blankNode(),this.QUANTIFIERS_GRAPH),this._emit(this._subject,this.RDF_FIRST,t,this.QUANTIFIERS_GRAPH)):this._quantified[t.id]=this._quantifier(this._blankNode().value),this._readQuantifierPunctuation}_readQuantifierPunctuation(e){return","===e.type?this._readQuantifierList:(this._explicitQuantifiers&&(this._emit(this._subject,this.RDF_REST,this.RDF_NIL,this.QUANTIFIERS_GRAPH),this._subject=null),this._readCallback=this._getContextEndReader(),this._readCallback(e))}_getPathReader(e){return this._afterPath=e,this._readPath}_readPath(e){switch(e.type){case"!":return this._readForwardPath;case"^":return this._readBackwardPath;default:const t=this._contextStack,r=t.length&&t[t.length-1];if(r&&"item"===r.type){const t=this._subject;this._restoreContext("item",e),this._emit(this._subject,this.RDF_FIRST,t,this._graph)}return this._afterPath(e)}}_readForwardPath(e){let t,r;const n=this._blankNode();if(void 0!==(r=this._readEntity(e)))return null===this._predicate?(t=this._subject,this._subject=n):(t=this._object,this._object=n),this._emit(t,r,n,this._graph),this._readPath}_readBackwardPath(e){const t=this._blankNode();let r,n;if(void 0!==(r=this._readEntity(e)))return null===this._predicate?(n=this._subject,this._subject=t):(n=this._object,this._object=t),this._emit(t,r,n,this._graph),this._readPath}_readRDFStarTailOrGraph(e){return">>"!==e.type?this._supportsQuads&&null===this._graph&&void 0!==(this._graph=this._readEntity(e))?this._readRDFStarTail:this._error(`Expected >> to follow "${this._object.id}"`,e):this._readRDFStarTail(e)}_readRDFStarTail(e){if(">>"!==e.type)return this._error(`Expected >> but got ${e.type}`,e);const t=this._quad(this._subject,this._predicate,this._object,this._graph||this.DEFAULTGRAPH);return this._restoreContext("<<",e),null===this._subject?(this._subject=t,this._readPredicate):(this._object=t,this._getContextEndReader())}_getContextEndReader(){const e=this._contextStack;if(!e.length)return this._readPunctuation;switch(e[e.length-1].type){case"blank":return this._readBlankNodeTail;case"list":return this._readListItem;case"formula":return this._readFormulaTail;case"<<":return this._readRDFStarTailOrGraph}}_emit(e,t,r,n){this._callback(null,this._quad(e,t,r,n||this.DEFAULTGRAPH))}_error(e,t){const r=new Error(`${e} on line ${t.line}.`);r.context={token:t,line:t.line,previousToken:this._lexer.previousToken},this._callback(r),this._callback=J}_resolveIRI(e){return/^[a-z][a-z0-9+.-]*:/i.test(e)?e:this._resolveRelativeIRI(e)}_resolveRelativeIRI(e){if(!e.length)return this._base;switch(e[0]){case"#":return this._base+e;case"?":return this._base.replace(/(?:\?.*)?$/,e);case"/":return("/"===e[1]?this._baseScheme:this._baseRoot)+this._removeDotSegments(e);default:return/^[^/:]*:/.test(e)?null:this._removeDotSegments(this._basePath+e)}}_removeDotSegments(e){if(!/(^|\/)\.\.?($|[/#?])/.test(e))return e;const t=e.length;let r="",n=-1,o=-1,i=0,a="/";for(;n=o&&(r=r.substr(0,i)),"/"!==a)return`${r}/${e.substr(n+1)}`;i=n+1}}}a=e[++n]}return r+e.substring(i)}parse(e,t,r){if(this._readCallback=this._readInTopContext,this._sparqlStyle=!1,this._prefixes=Object.create(null),this._prefixes._=this._blankNodePrefix?this._blankNodePrefix.substr(2):`b${Y++}_`,this._prefixCallback=r||J,this._inversePredicate=!1,this._quantified=Object.create(null),!t){const t=[];let r;if(this._callback=(e,n)=>{e?r=e:n&&t.push(n)},this._lexer.tokenize(e).every((e=>this._readCallback=this._readCallback(e))),r)throw r;return t}this._callback=t,this._lexer.tokenize(e,((e,t)=>{null!==e?(this._callback(e),this._callback=J):this._readCallback&&(this._readCallback=this._readCallback(t))}))}}function J(){}function Z(e,t){const r=t.namedNode;e._namedNode=r,e._blankNode=t.blankNode,e._literal=t.literal,e._variable=t.variable,e._quad=t.quad,e.DEFAULTGRAPH=t.defaultGraph(),e.RDF_FIRST=r(c.rdf.first),e.RDF_REST=r(c.rdf.rest),e.RDF_NIL=r(c.rdf.nil),e.N3_FORALL=r(c.r.forAll),e.N3_FORSOME=r(c.r.forSome),e.ABBREVIATIONS={a:r(c.rdf.type),"=":r(c.owl.sameAs),">":r(c.log.implies)},e.QUANTIFIERS_GRAPH=r("urn:n3:quantifiers")}Z(Q.prototype,y);var X=r(827);class ee{constructor(e,t){this._size=0,this._graphs=Object.create(null),this._id=0,this._ids=Object.create(null),this._ids["><"]=0,this._entities=Object.create(null),this._blankNodeIndex=0,t||!e||e[0]||(t=e,e=null),t=t||{},this._factory=t.factory||y,e&&this.addQuads(e)}get size(){let e=this._size;if(null!==e)return e;e=0;const t=this._graphs;let r,n;for(const o in t)for(const i in r=t[o].subjects)for(const t in n=r[i])e+=Object.keys(n[t]).length;return this._size=e}_addToIndex(e,t,r,n){const o=e[t]||(e[t]={}),i=o[r]||(o[r]={}),a=n in i;return a||(i[n]=null),!a}_removeFromIndex(e,t,r,n){const o=e[t],i=o[r];delete i[n];for(const e in i)return;delete o[r];for(const e in o)return;delete e[t]}*_findInIndex(e,t,r,n,o,i,a,s){let c,h,u;const l=this._entities,p=A(s,this._factory),d={subject:null,predicate:null,object:null};t&&((c=e,e={})[t]=c[t]);for(const t in e)if(h=e[t]){d[o]=A(l[t],this._factory),r&&((c=h,h={})[r]=c[r]);for(const e in h)if(u=h[e]){d[i]=A(l[e],this._factory);const t=n?n in u?[n]:[]:Object.keys(u);for(let e=0;e{r in t||(t[r]=!0,e(A(this._entities[r],this._factory)))}}add(e){return this.addQuad(e),this}addQuad(e,t,r,n){t||(n=e.graph,r=e.object,t=e.predicate,e=e.subject),e=E(e),t=E(t),r=E(r),n=E(n);let o=this._graphs[n];o||(o=this._graphs[n]={subjects:{},predicates:{},objects:{}},Object.freeze(o));const i=this._ids,a=this._entities;e=i[e]||(i[a[++this._id]=e]=this._id),t=i[t]||(i[a[++this._id]=t]=this._id),r=i[r]||(i[a[++this._id]=r]=this._id);const s=this._addToIndex(o.subjects,e,t,r);return this._addToIndex(o.predicates,t,r,e),this._addToIndex(o.objects,r,e,t),this._size=null,s}addQuads(e){for(let t=0;t{this.addQuad(e)})),e}removeQuad(e,t,r,n){t||(n=e.graph,r=e.object,t=e.predicate,e=e.subject),e=E(e),t=E(t),r=E(r),n=E(n);const o=this._ids,i=this._graphs;let a,s,c;if(!((e=o[e])&&(t=o[t])&&(r=o[r])&&(a=i[n])&&(s=a.subjects[e])&&(c=s[t])&&r in c))return!1;for(e in this._removeFromIndex(a.subjects,e,t,r),this._removeFromIndex(a.predicates,t,r,e),this._removeFromIndex(a.objects,r,e,t),null!==this._size&&this._size--,a.subjects)return!0;return delete i[n],!0}removeQuads(e){for(let t=0;t{this.removeQuad(e)})),e}removeMatches(e,t,r,n){const o=new X.Readable({objectMode:!0});return o._read=()=>{for(const i of this.readQuads(e,t,r,n))o.push(i);o.push(null)},this.remove(o)}deleteGraph(e){return this.removeMatches(null,null,null,e)}getQuads(e,t,r,n){return[...this.readQuads(e,t,r,n)]}*readQuads(e,t,r,n){e=e&&E(e),t=t&&E(t),r=r&&E(r),n=n&&E(n);const o=this._getGraphs(n),i=this._ids;let a,s,c,h;if(!(te(e)&&!(s=i[e])||te(t)&&!(c=i[t])||te(r)&&!(h=i[r])))for(const e in o)(a=o[e])&&(s?h?yield*this._findInIndex(a.objects,h,s,c,"object","subject","predicate",e):yield*this._findInIndex(a.subjects,s,c,null,"subject","predicate","object",e):c?yield*this._findInIndex(a.predicates,c,h,null,"predicate","object","subject",e):h?yield*this._findInIndex(a.objects,h,null,null,"object","subject","predicate",e):yield*this._findInIndex(a.subjects,null,null,null,"subject","predicate","object",e))}match(e,t,r,n){return new re(this,e,t,r,n)}countQuads(e,t,r,n){e=e&&E(e),t=t&&E(t),r=r&&E(r),n=n&&E(n);const o=this._getGraphs(n),i=this._ids;let a,s,c,h,u=0;if(te(e)&&!(s=i[e])||te(t)&&!(c=i[t])||te(r)&&!(h=i[r]))return 0;for(const n in o)(a=o[n])&&(u+=e?r?this._countInIndex(a.objects,h,s,c):this._countInIndex(a.subjects,s,c,h):t?this._countInIndex(a.predicates,c,h,s):this._countInIndex(a.objects,h,s,c));return u}forEach(e,t,r,n,o){this.some((t=>(e(t),!1)),t,r,n,o)}every(e,t,r,n,o){let i=!1;const a=!this.some((t=>(i=!0,!e(t))),t,r,n,o);return i&&a}some(e,t,r,n,o){for(const i of this.readQuads(t,r,n,o))if(e(i))return!0;return!1}getSubjects(e,t,r){const n=[];return this.forSubjects((e=>{n.push(e)}),e,t,r),n}forSubjects(e,t,r,n){t=t&&E(t),r=r&&E(r),n=n&&E(n);const o=this._ids,i=this._getGraphs(n);let a,s,c;if(e=this._uniqueEntities(e),!(te(t)&&!(s=o[t])||te(r)&&!(c=o[r])))for(n in i)(a=i[n])&&(s?c?this._loopBy2Keys(a.predicates,s,c,e):this._loopByKey1(a.subjects,s,e):c?this._loopByKey0(a.objects,c,e):this._loop(a.subjects,e))}getPredicates(e,t,r){const n=[];return this.forPredicates((e=>{n.push(e)}),e,t,r),n}forPredicates(e,t,r,n){t=t&&E(t),r=r&&E(r),n=n&&E(n);const o=this._ids,i=this._getGraphs(n);let a,s,c;if(e=this._uniqueEntities(e),!(te(t)&&!(s=o[t])||te(r)&&!(c=o[r])))for(n in i)(a=i[n])&&(s?c?this._loopBy2Keys(a.objects,c,s,e):this._loopByKey0(a.subjects,s,e):c?this._loopByKey1(a.predicates,c,e):this._loop(a.predicates,e))}getObjects(e,t,r){const n=[];return this.forObjects((e=>{n.push(e)}),e,t,r),n}forObjects(e,t,r,n){t=t&&E(t),r=r&&E(r),n=n&&E(n);const o=this._ids,i=this._getGraphs(n);let a,s,c;if(e=this._uniqueEntities(e),!(te(t)&&!(s=o[t])||te(r)&&!(c=o[r])))for(n in i)(a=i[n])&&(s?c?this._loopBy2Keys(a.subjects,s,c,e):this._loopByKey1(a.objects,s,e):c?this._loopByKey0(a.predicates,c,e):this._loop(a.objects,e))}getGraphs(e,t,r){const n=[];return this.forGraphs((e=>{n.push(e)}),e,t,r),n}forGraphs(e,t,r,n){for(const o in this._graphs)this.some((t=>(e(t.graph),!0)),t,r,n,o)}createBlankNode(e){let t,r;if(e)for(t=e=`_:${e}`,r=1;this._ids[t];)t=e+r++;else do{t="_:b"+this._blankNodeIndex++}while(this._ids[t]);return this._ids[t]=++this._id,this._entities[this._id]=t,this._factory.blankNode(t.substr(2))}extractLists({remove:e=!1,ignoreErrors:t=!1}={}){const r={},n=t?()=>!0:(e,t)=>{throw new Error(`${e.value} ${t}`)},o=this.getQuads(null,c.rdf.rest,c.rdf.nil,null),i=e?[...o]:[];return o.forEach((t=>{const o=[];let a,s,h=!1;const u=t.graph;let l=t.subject;for(;l&&!h;){const e=this.getQuads(null,null,l,null),t=this.getQuads(l,null,null,null);let r,p=null,d=null,f=null;for(let o=0;o0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]0?"DELETE DATA {"+o+"};":"",s=n.length>0?"INSERT DATA {"+i+"};":"",[4,t().fetch(e,{method:"PATCH",body:a+" "+s,headers:{"Content-Type":"application/sparql-update"}})];case 3:return[2,c.sent()]}}))}))}function le(e,r){return oe(this,void 0,void 0,(function(){var n;return ie(this,(function(o){switch(o.label){case 0:return[4,ae(r)];case 1:return n=o.sent(),[4,t().fetch(e,{method:"PUT",body:n,headers:{"Content-Type":"text/turtle","If-None-Match":"*"}})];case 2:return[2,o.sent()]}}))}))}function pe(e,r,n){return void 0===n&&(n={}),oe(this,void 0,void 0,(function(){var o,i;return ie(this,(function(a){switch(a.label){case 0:return[4,ae(r)];case 1:return o=a.sent(),i={"Content-Type":"text/turtle"},n.slugSuggestion&&(i.slug=n.slugSuggestion),[4,t().fetch(e,{method:"POST",body:o,headers:i})];case 2:return[2,a.sent()]}}))}))}function de(){return e=new ee,t={addAll:function(r){var n=Array.isArray(r)?r:r.toArray();return e.addQuads(n),t},match:function(t,r,n,o){var i=void 0===t?null:t,a=void 0===r?null:r,s=void 0===n?null:n,c=void 0===o?null:o;return{toArray:function(){return e.getQuads(i,a,s,c)}}},toArray:function(){return e.getQuads(null,null,null,null)}};var e,t}var fe=y,ge=function(e,t,r){return function(e,t,r,n,o){var i=n?be(n):null,a=o?be(o):null,s=e.match(null,i,a,null).toArray().find((function(e){return void 0!==e[t]}));return void 0!==s?ve(s[t]):null}(e,"subject",0,t,r)},me=function(e,t,r){return we(e,"subject",null,t,r)},ye=function(e,t,r){return we(e,"object",t,r,null)};function we(e,t,r,n,o){var i=r?be(r):null,a=n?be(n):null,s=o?be(o):null;return e.match(i,a,s,null).toArray().filter((function(e){return void 0!==e[t]})).map((function(e){return ve(e[t])})).filter(_e)}function be(e){return"string"==typeof e?fe.namedNode(e):e}function ve(e){return"BlankNode"===e.termType?e:"NamedNode"===e.termType?e.value:$e(e)?e:null}function _e(e){return null!==e}function Se(e,t){var r=Ye(t)?t:fe.namedNode(t),n=function(e){return"function"==typeof e.getTriples}(e)?e.getStore().match(r,null,null,null).toArray():[],o=de();o.addAll(n);var i=[],a=[],s=function(e){return ye(o,t,e)},c=function(e){var t=s(e).find(Ve);return void 0===t?null:t},h=function(e){return s(e).filter(Ve)},u=function(e,t){i.push(fe.triple(r,fe.namedNode(e),Pe(t)))},l=function(e,t){if("string"!=typeof t)throw new Error("The given value is not a string.");return u(e,t)},p=function(e,t,n){if("string"!=typeof t)throw new Error("The given value is not a string.");i.push(fe.triple(r,fe.namedNode(e),fe.literal(t,n)))},d=function(e,t){if("number"!=typeof t||!Number.isInteger(t))throw new Error("The given value is not an integer.");return u(e,t)},f=function(e,t){if("number"!=typeof t)throw new Error("The given value is not a decimal.");i.push(fe.triple(r,fe.namedNode(e),fe.literal(t.toString(),fe.namedNode("http://www.w3.org/2001/XMLSchema#decimal"))))},g=function(e,t){if(t instanceof Date==0)throw new Error("The given value is not a DateTime.");return u(e,t)},m=function(e,t){i.push(fe.triple(r,fe.namedNode(e),fe.namedNode(t)))},y=function(e,t){a.push(fe.triple(r,fe.namedNode(e),fe.namedNode(t)))},w=function(e,t){a.push(fe.triple(r,fe.namedNode(e),Pe(t)))},b=function(e){a.push.apply(a,o.match(r,fe.namedNode(e),null,null).toArray())},v=function(e,t){b(e),m(e,t)},_=function(){return o.match(r,null,null,null).toArray()},S=function(){return Ye(t)?t.value:t};return{getDocument:function(){return e},getTriples:_,getString:function(e){var t=s(e).find(He);return void 0===t?null:t.value},getLocaleString:function(e,t){var r=s(e).find(We(t));return void 0===r?null:r.value},getInteger:function(e){var t=s(e).find(Ge);return void 0===t?null:Ee(t)},getDecimal:function(e){var t=s(e).find(ze);return void 0===t?null:xe(t)},getDateTime:function(e){var t=s(e).find(Ke);return void 0===t?null:Ae(t)},getLiteral:function(e){var t=s(e).find($e);return void 0===t?null:Oe(t)},getAllStrings:function(e){return s(e).filter(He).map(Re)},getAllLocaleStrings:function(e,t){var r=s(e);return t?r.filter(We(t)).map(Re):r.filter(Ce).map(Te)},getAllIntegers:function(e){return s(e).filter(Ge).map(Ee)},getAllDecimals:function(e){return s(e).filter(ze).map(xe)},getAllDateTimes:function(e){return s(e).filter(Ke).map(Ae)},getAllLiterals:function(e){return s(e).filter($e).map(Oe)},getLocalSubject:function(t){var r=s(t).find(Ye);return void 0===r?null:Se(e,r)},getAllLocalSubjects:function(t){return s(t).filter(Ye).map((function(t){return Se(e,t)}))},getRef:c,getAllRefs:h,getType:function(){return c("http://www.w3.org/1999/02/22-rdf-syntax-ns#type")},addString:l,addLocaleString:p,addInteger:d,addDecimal:f,addDateTime:g,addRef:m,removeAll:b,removeString:function(e,t){if("string"!=typeof t)throw new Error("The given value is not a string.");return w(e,t)},removeLocaleString:function(e,t,n){if("string"!=typeof t)throw new Error("The given value is not a string.");a.push(fe.triple(r,fe.namedNode(e),fe.literal(t,n)))},removeInteger:function(e,t){if("number"!=typeof t||!Number.isInteger(t))throw new Error("The given value is not an integer.");return w(e,t)},removeDecimal:function(e,t){if("number"!=typeof t)throw new Error("The given value is not a decimal.");a.push(fe.triple(r,fe.namedNode(e),fe.literal(t.toString(),fe.namedNode("http://www.w3.org/2001/XMLSchema#decimal"))))},removeDateTime:function(e,t){if(t instanceof Date==0)throw new Error("The given value is not a DateTime.");return w(e,t)},removeRef:y,setRef:v,setString:function(e,t){b(e),l(e,t)},setLocaleString:function(e,t,r){b(e),p(e,t,r)},setInteger:function(e,t){b(e),d(e,t)},setDecimal:function(e,t){b(e),f(e,t)},setDateTime:function(e,t){b(e),g(e,t)},clear:function(){a.push.apply(a,_())},getPendingTriples:function(){return[a,i]},asRef:S,getNodeRef:c,getAllNodeRefs:h,addNodeRef:m,addLiteral:u,removeNodeRef:y,removeLiteral:w,setNodeRef:v,setLiteral:function(e,t){b(e),u(e,t)},asNodeRef:S}}function Ae(e){var t=parseInt(e.value.substring(0,4),10),r=parseInt(e.value.substring(5,7),10)-1,n=parseInt(e.value.substring(8,10),10),o=parseInt(e.value.substring(11,13),10),i=parseInt(e.value.substring(14,16),10),a=parseInt(e.value.substring(17,e.value.indexOf("Z")),10),s=new Date(0);return s.setUTCFullYear(t),s.setUTCMonth(r),s.setUTCDate(n),s.setUTCHours(o),s.setUTCMinutes(i),s.setUTCSeconds(a),s}function Ee(e){return parseInt(e.value,10)}function xe(e){return parseFloat(e.value)}function Re(e){return e.value}function Ce(e){return!!$e(e)&&e.language.length>0}function Te(e){return{locale:e.language,value:e.value}}function Oe(e){return Ke(e)?Ae(e):Ge(e)?Ee(e):ze(e)?xe(e):e.value}function Pe(e){if(e instanceof Date){var t=new Date(Date.UTC(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),0)).toISOString().replace(/\.000Z$/,"Z");return fe.literal(t,fe.namedNode("http://www.w3.org/2001/XMLSchema#dateTime"))}return"number"==typeof e&&Number.isInteger(e)?fe.literal(e.toString(),fe.namedNode("http://www.w3.org/2001/XMLSchema#integer")):"number"!=typeof e||Number.isInteger(e)?fe.literal(e.toString()):fe.literal(e.toString(),fe.namedNode("http://www.w3.org/2001/XMLSchema#decimal"))}function Ie(e,t,r){var n=this,o=Ue(t,r),i=function(){return r.documentRef},a=ne(ne({},o),{save:function(o){return void 0===o&&(o=Object.values(t.getAccessedSubjects())),oe(n,void 0,void 0,(function(){var t,n,i,s,c,h;return ie(this,(function(u){switch(u.label){case 0:return t=Fe(o,a,e),[4,le(r.documentRef,t.allAdditions)];case 1:return(i=u.sent()).ok?[3,3]:[4,i.text()];case 2:throw s=u.sent(),new Error(s);case 3:return n=ne(ne({},r),{existsOnPod:!0}),(c=Ne(i,r.documentRef))&&(n.aclRef=c),(h=i.headers.get("Updates-Via"))&&(n.webSocketRef=h),[2,Me(t.newTriples,n)]}}))}))},asRef:i,asNodeRef:i});return t.setDocument(a),a}var ke=function(e,t){return function(r,n){return e(t,r,n)}},je=function(e,t){return function(r,n){return e(t,r,n)}};function De(e){return Me([],{documentRef:e,existsOnPod:!1})}function Be(e){return oe(this,void 0,void 0,(function(){var t,r,n,o,i,a;return ie(this,(function(s){switch(s.label){case 0:return t=new URL(e),[4,ce(r=t.origin+t.pathname+t.search)];case 1:if(!1===(n=s.sent()).ok)throw new Error("Fetching the Document failed: "+n.status+" "+n.statusText+".");return[4,n.text()];case 2:return[4,se(s.sent(),r)];case 3:return o=s.sent(),i=Ne(n,r),a=n.headers.get("Updates-Via"),[2,Me(o,{aclRef:i,documentRef:r,webSocketRef:a||void 0,existsOnPod:!0})]}}))}))}function Ne(e,t){var r,n=e.headers.get("Link");if(n&&o()){var i=o().parse(n).get("rel","acl");1===i.length&&(r=new URL(i[0].uri,t).href)}return r}function Le(e){return"string"==typeof e.documentRef}function Me(e,t){var r=de();r.addAll(e);var n,o,i=(o={},{getSubject:function(e){return e=function(e){return"function"==typeof e.asRef}(n)?new URL(e,n.asRef()).href:e,o[e]||(o[e]=Se(n,e)),o[e]},setDocument:function(e){n=e},getAccessedSubjects:function(){return o}});return Le(t)?function(e){return!0===e.existsOnPod}(t)?function(e,t,r){var n=this,o=Ie(e,t,r),i=function(){return r.aclRef||null},a=function(r,n){return je(me,e)(r,n).filter(Ve).map(t.getSubject)},s=function(e){return a("http://www.w3.org/1999/02/22-rdf-syntax-ns#type",e)},c=function(){return e.toArray()},h=ne(ne({},o),{save:function(o){return void 0===o&&(o=Object.values(t.getAccessedSubjects())),oe(n,void 0,void 0,(function(){var t,n,i,a;return ie(this,(function(s){switch(s.label){case 0:return t=Fe(o,h,e),[4,ue(r.documentRef,t.allDeletions,t.allAdditions)];case 1:return(i=s.sent()).ok?[3,3]:[4,i.text()];case 2:throw a=s.sent(),new Error(a);case 3:return n=ne(ne({},r),{existsOnPod:!0}),[2,Me(t.newTriples,n)]}}))}))},removeSubject:function(e){return t.getSubject(e).clear()},getSubject:t.getSubject,getAllSubjectsOfType:s,findSubject:function(r,n){var o=ke(ge,e)(r,n);return o&&Ve(o)?t.getSubject(o):null},findSubjects:a,getAclRef:i,getWebSocketRef:function(){return r.webSocketRef||null},experimental_getAllSubjects:function(){var r=we(e,"subject",null,null,null).filter(Ve);return Array.from(new Set(r)).map((function(e){return t.getSubject(e)}))},getStore:function(){return e},getTriples:c,getAcl:i,getStatements:c,getSubjectsOfType:s});return t.setDocument(h),h}(r,i,t):Ie(r,i,t):function(e,t,r){var n=this,o=Ue(t,r),i=ne(ne({},o),{save:function(o){return void 0===o&&(o=Object.values(t.getAccessedSubjects())),oe(n,void 0,void 0,(function(){var t,n,a,s,c,h,u,l,p;return ie(this,(function(d){switch(d.label){case 0:return t=Fe(o,i,e),[4,pe(r.containerRef,t.allAdditions)];case 1:return a=d.sent(),s=a.headers.get("Location"),a.ok&&null!==s?[3,3]:[4,a.text()];case 2:throw c=d.sent(),new Error(c);case 3:return h=new URL(s,new URL(r.containerRef).origin).href,n=ne(ne({},r),{containerRef:void 0,documentRef:h,existsOnPod:!0}),[4,he(h)];case 4:return u=d.sent(),(l=Ne(u,h))&&(n.aclRef=l),(p=u.headers.get("Updates-Via"))&&(n.webSocketRef=p),[2,Me(t.newTriples,n)]}}))}))}});return t.setDocument(i),i}(r,i,t)}function Ue(e,t){return{addSubject:function(r){var n=void 0===r?{}:r,o=n.identifier,i=void 0===o?qe():o,a=n.identifierPrefix,s=void 0===a?"":a,c=(Le(t)?t.documentRef:"")+"#"+s+i;return e.getSubject(c)}}}function Fe(e,t,r){var n=e.filter((function(e){return e.getDocument()===t})).reduce((function(e,t){var r=e[0],n=e[1],o=t.getPendingTriples(),i=o[0],a=o[1];return[r.concat(i),n.concat(a)]}),[[],[]]),o=n[0],i=n[1],a=r.toArray().concat(i).filter((function(e){return-1===o.findIndex((function(t){return t.equals(e)}))}));return{allAdditions:i,allDeletions:o,newTriples:a}}var qe=function(){return Date.now().toString()+Math.random().toString().substring("0.".length)};function $e(e){return"object"==typeof e&&null!==e&&"string"==typeof e.termType&&"Literal"===e.termType}function He(e){return $e(e)&&"http://www.w3.org/2001/XMLSchema#string"===e.datatype.value}function We(e){return function(t){return function(e,t){return $e(e)&&"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"===e.datatype.value&&e.language.toLowerCase()===t.toLowerCase()}(t,e)}}function Ge(e){return $e(e)&&"http://www.w3.org/2001/XMLSchema#integer"===e.datatype.value}function ze(e){return $e(e)&&"http://www.w3.org/2001/XMLSchema#decimal"===e.datatype.value}function Ke(e){return $e(e)&&"http://www.w3.org/2001/XMLSchema#dateTime"===e.datatype.value}function Ve(e){return"string"==typeof e&&!$e(e)}function Ye(e){return"object"==typeof e&&null!==e&&"string"==typeof e.termType&&"BlankNode"===e.termType}var Qe=Object.freeze({mbox:"http://xmlns.com/foaf/0.1/mbox",mbox_sha1sum:"http://xmlns.com/foaf/0.1/mbox_sha1sum",gender:"http://xmlns.com/foaf/0.1/gender",geekcode:"http://xmlns.com/foaf/0.1/geekcode",dnaChecksum:"http://xmlns.com/foaf/0.1/dnaChecksum",sha1:"http://xmlns.com/foaf/0.1/sha1",based_near:"http://xmlns.com/foaf/0.1/based_near",title:"http://xmlns.com/foaf/0.1/title",nick:"http://xmlns.com/foaf/0.1/nick",jabberID:"http://xmlns.com/foaf/0.1/jabberID",aimChatID:"http://xmlns.com/foaf/0.1/aimChatID",skypeID:"http://xmlns.com/foaf/0.1/skypeID",icqChatID:"http://xmlns.com/foaf/0.1/icqChatID",yahooChatID:"http://xmlns.com/foaf/0.1/yahooChatID",msnChatID:"http://xmlns.com/foaf/0.1/msnChatID",name:"http://xmlns.com/foaf/0.1/name",firstName:"http://xmlns.com/foaf/0.1/firstName",lastName:"http://xmlns.com/foaf/0.1/lastName",givenName:"http://xmlns.com/foaf/0.1/givenName",givenname:"http://xmlns.com/foaf/0.1/givenname",surname:"http://xmlns.com/foaf/0.1/surname",family_name:"http://xmlns.com/foaf/0.1/family_name",familyName:"http://xmlns.com/foaf/0.1/familyName",phone:"http://xmlns.com/foaf/0.1/phone",homepage:"http://xmlns.com/foaf/0.1/homepage",weblog:"http://xmlns.com/foaf/0.1/weblog",openid:"http://xmlns.com/foaf/0.1/openid",tipjar:"http://xmlns.com/foaf/0.1/tipjar",plan:"http://xmlns.com/foaf/0.1/plan",made:"http://xmlns.com/foaf/0.1/made",maker:"http://xmlns.com/foaf/0.1/maker",img:"http://xmlns.com/foaf/0.1/img",depiction:"http://xmlns.com/foaf/0.1/depiction",depicts:"http://xmlns.com/foaf/0.1/depicts",thumbnail:"http://xmlns.com/foaf/0.1/thumbnail",myersBriggs:"http://xmlns.com/foaf/0.1/myersBriggs",workplaceHomepage:"http://xmlns.com/foaf/0.1/workplaceHomepage",workInfoHomepage:"http://xmlns.com/foaf/0.1/workInfoHomepage",schoolHomepage:"http://xmlns.com/foaf/0.1/schoolHomepage",knows:"http://xmlns.com/foaf/0.1/knows",interest:"http://xmlns.com/foaf/0.1/interest",topic_interest:"http://xmlns.com/foaf/0.1/topic_interest",publications:"http://xmlns.com/foaf/0.1/publications",currentProject:"http://xmlns.com/foaf/0.1/currentProject",pastProject:"http://xmlns.com/foaf/0.1/pastProject",fundedBy:"http://xmlns.com/foaf/0.1/fundedBy",logo:"http://xmlns.com/foaf/0.1/logo",topic:"http://xmlns.com/foaf/0.1/topic",primaryTopic:"http://xmlns.com/foaf/0.1/primaryTopic",focus:"http://xmlns.com/foaf/0.1/focus",isPrimaryTopicOf:"http://xmlns.com/foaf/0.1/isPrimaryTopicOf",page:"http://xmlns.com/foaf/0.1/page",theme:"http://xmlns.com/foaf/0.1/theme",account:"http://xmlns.com/foaf/0.1/account",holdsAccount:"http://xmlns.com/foaf/0.1/holdsAccount",accountServiceHomepage:"http://xmlns.com/foaf/0.1/accountServiceHomepage",accountName:"http://xmlns.com/foaf/0.1/accountName",member:"http://xmlns.com/foaf/0.1/member",membershipClass:"http://xmlns.com/foaf/0.1/membershipClass",birthday:"http://xmlns.com/foaf/0.1/birthday",age:"http://xmlns.com/foaf/0.1/age",status:"http://xmlns.com/foaf/0.1/status",LabelProperty:"http://xmlns.com/foaf/0.1/LabelProperty",Person:"http://xmlns.com/foaf/0.1/Person",Document:"http://xmlns.com/foaf/0.1/Document",Organization:"http://xmlns.com/foaf/0.1/Organization",Group:"http://xmlns.com/foaf/0.1/Group",Agent:"http://xmlns.com/foaf/0.1/Agent",Project:"http://xmlns.com/foaf/0.1/Project",Image:"http://xmlns.com/foaf/0.1/Image",PersonalProfileDocument:"http://xmlns.com/foaf/0.1/PersonalProfileDocument",OnlineAccount:"http://xmlns.com/foaf/0.1/OnlineAccount",OnlineGamingAccount:"http://xmlns.com/foaf/0.1/OnlineGamingAccount",OnlineEcommerceAccount:"http://xmlns.com/foaf/0.1/OnlineEcommerceAccount",OnlineChatAccount:"http://xmlns.com/foaf/0.1/OnlineChatAccount"}),Je=Object.freeze({type:"http://www.w3.org/1999/02/22-rdf-syntax-ns#type",subject:"http://www.w3.org/1999/02/22-rdf-syntax-ns#subject",predicate:"http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate",object:"http://www.w3.org/1999/02/22-rdf-syntax-ns#object",value:"http://www.w3.org/1999/02/22-rdf-syntax-ns#value",first:"http://www.w3.org/1999/02/22-rdf-syntax-ns#first",rest:"http://www.w3.org/1999/02/22-rdf-syntax-ns#rest",language:"http://www.w3.org/1999/02/22-rdf-syntax-ns#language",direction:"http://www.w3.org/1999/02/22-rdf-syntax-ns#direction",Property:"http://www.w3.org/1999/02/22-rdf-syntax-ns#Property",Statement:"http://www.w3.org/1999/02/22-rdf-syntax-ns#Statement",Bag:"http://www.w3.org/1999/02/22-rdf-syntax-ns#Bag",Seq:"http://www.w3.org/1999/02/22-rdf-syntax-ns#Seq",Alt:"http://www.w3.org/1999/02/22-rdf-syntax-ns#Alt",List:"http://www.w3.org/1999/02/22-rdf-syntax-ns#List",CompoundLiteral:"http://www.w3.org/1999/02/22-rdf-syntax-ns#CompoundLiteral",HTML:"http://www.w3.org/1999/02/22-rdf-syntax-ns#HTML",langString:"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString",PlainLiteral:"http://www.w3.org/1999/02/22-rdf-syntax-ns#PlainLiteral",XMLLiteral:"http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral",JSON__workaround:"http://www.w3.org/1999/02/22-rdf-syntax-ns#JSON"}),Ze=Object.freeze({acceptedAnswer:"http://schema.org/acceptedAnswer",acceptedOffer:"http://schema.org/acceptedOffer",acceptedPaymentMethod:"http://schema.org/acceptedPaymentMethod",acceptsReservations:"http://schema.org/acceptsReservations",accessCode:"http://schema.org/accessCode",accessMode:"http://schema.org/accessMode",accessModeSufficient:"http://schema.org/accessModeSufficient",accessibilityAPI:"http://schema.org/accessibilityAPI",accessibilityControl:"http://schema.org/accessibilityControl",accessibilityFeature:"http://schema.org/accessibilityFeature",accessibilityHazard:"http://schema.org/accessibilityHazard",accessibilitySummary:"http://schema.org/accessibilitySummary",accountId:"http://schema.org/accountId",accountablePerson:"http://schema.org/accountablePerson",acquiredFrom:"http://schema.org/acquiredFrom",actionAccessibilityRequirement:"http://schema.org/actionAccessibilityRequirement",actionPlatform:"http://schema.org/actionPlatform",actionStatus:"http://schema.org/actionStatus",actors:"http://schema.org/actors",addOn:"http://schema.org/addOn",additionalName:"http://schema.org/additionalName",additionalNumberOfGuests:"http://schema.org/additionalNumberOfGuests",additionalProperty:"http://schema.org/additionalProperty",additionalType:"http://schema.org/additionalType",address:"http://schema.org/address",addressCountry:"http://schema.org/addressCountry",addressLocality:"http://schema.org/addressLocality",addressRegion:"http://schema.org/addressRegion",advanceBookingRequirement:"http://schema.org/advanceBookingRequirement",affiliation:"http://schema.org/affiliation",afterMedia:"http://schema.org/afterMedia",agent:"http://schema.org/agent",aggregateRating:"http://schema.org/aggregateRating",aircraft:"http://schema.org/aircraft",albumProductionType:"http://schema.org/albumProductionType",albumReleaseType:"http://schema.org/albumReleaseType",albums:"http://schema.org/albums",alignmentType:"http://schema.org/alignmentType",alternateName:"http://schema.org/alternateName",alternativeHeadline:"http://schema.org/alternativeHeadline",amenityFeature:"http://schema.org/amenityFeature",amount:"http://schema.org/amount",amountOfThisGood:"http://schema.org/amountOfThisGood",annualPercentageRate:"http://schema.org/annualPercentageRate",answerCount:"http://schema.org/answerCount",application:"http://schema.org/application",applicationCategory:"http://schema.org/applicationCategory",applicationSubCategory:"http://schema.org/applicationSubCategory",applicationSuite:"http://schema.org/applicationSuite",appliesToDeliveryMethod:"http://schema.org/appliesToDeliveryMethod",appliesToPaymentMethod:"http://schema.org/appliesToPaymentMethod",area:"http://schema.org/area",arrivalAirport:"http://schema.org/arrivalAirport",arrivalBusStop:"http://schema.org/arrivalBusStop",arrivalGate:"http://schema.org/arrivalGate",arrivalPlatform:"http://schema.org/arrivalPlatform",arrivalStation:"http://schema.org/arrivalStation",arrivalTerminal:"http://schema.org/arrivalTerminal",arrivalTime:"http://schema.org/arrivalTime",artEdition:"http://schema.org/artEdition",artMedium:"http://schema.org/artMedium",artform:"http://schema.org/artform",articleBody:"http://schema.org/articleBody",articleSection:"http://schema.org/articleSection",assembly:"http://schema.org/assembly",assemblyVersion:"http://schema.org/assemblyVersion",associatedArticle:"http://schema.org/associatedArticle",associatedMedia:"http://schema.org/associatedMedia",athlete:"http://schema.org/athlete",attendees:"http://schema.org/attendees",audienceType:"http://schema.org/audienceType",audio:"http://schema.org/audio",authenticator:"http://schema.org/authenticator",author:"http://schema.org/author",availability:"http://schema.org/availability",availabilityEnds:"http://schema.org/availabilityEnds",availabilityStarts:"http://schema.org/availabilityStarts",availableAtOrFrom:"http://schema.org/availableAtOrFrom",availableChannel:"http://schema.org/availableChannel",availableDeliveryMethod:"http://schema.org/availableDeliveryMethod",availableFrom:"http://schema.org/availableFrom",availableLanguage:"http://schema.org/availableLanguage",availableThrough:"http://schema.org/availableThrough",awards:"http://schema.org/awards",awayTeam:"http://schema.org/awayTeam",baseSalary:"http://schema.org/baseSalary",bccRecipient:"http://schema.org/bccRecipient",bed:"http://schema.org/bed",beforeMedia:"http://schema.org/beforeMedia",benefits:"http://schema.org/benefits",bestRating:"http://schema.org/bestRating",billingAddress:"http://schema.org/billingAddress",billingIncrement:"http://schema.org/billingIncrement",billingPeriod:"http://schema.org/billingPeriod",birthDate:"http://schema.org/birthDate",birthPlace:"http://schema.org/birthPlace",bitrate:"http://schema.org/bitrate",blogPosts:"http://schema.org/blogPosts",boardingGroup:"http://schema.org/boardingGroup",boardingPolicy:"http://schema.org/boardingPolicy",bookEdition:"http://schema.org/bookEdition",bookFormat:"http://schema.org/bookFormat",bookingAgent:"http://schema.org/bookingAgent",bookingTime:"http://schema.org/bookingTime",borrower:"http://schema.org/borrower",box:"http://schema.org/box",branchCode:"http://schema.org/branchCode",branchOf:"http://schema.org/branchOf",brand:"http://schema.org/brand",breadcrumb:"http://schema.org/breadcrumb",broadcastAffiliateOf:"http://schema.org/broadcastAffiliateOf",broadcastChannelId:"http://schema.org/broadcastChannelId",broadcastDisplayName:"http://schema.org/broadcastDisplayName",broadcastFrequency:"http://schema.org/broadcastFrequency",broadcastFrequencyValue:"http://schema.org/broadcastFrequencyValue",broadcastOfEvent:"http://schema.org/broadcastOfEvent",broadcastServiceTier:"http://schema.org/broadcastServiceTier",broadcastTimezone:"http://schema.org/broadcastTimezone",broadcaster:"http://schema.org/broadcaster",browserRequirements:"http://schema.org/browserRequirements",busName:"http://schema.org/busName",busNumber:"http://schema.org/busNumber",businessFunction:"http://schema.org/businessFunction",buyer:"http://schema.org/buyer",byArtist:"http://schema.org/byArtist",calories:"http://schema.org/calories",candidate:"http://schema.org/candidate",caption:"http://schema.org/caption",carbohydrateContent:"http://schema.org/carbohydrateContent",cargoVolume:"http://schema.org/cargoVolume",carrier:"http://schema.org/carrier",carrierRequirements:"http://schema.org/carrierRequirements",catalog:"http://schema.org/catalog",catalogNumber:"http://schema.org/catalogNumber",category:"http://schema.org/category",ccRecipient:"http://schema.org/ccRecipient",character:"http://schema.org/character",characterAttribute:"http://schema.org/characterAttribute",characterName:"http://schema.org/characterName",cheatCode:"http://schema.org/cheatCode",checkinTime:"http://schema.org/checkinTime",checkoutTime:"http://schema.org/checkoutTime",childMaxAge:"http://schema.org/childMaxAge",childMinAge:"http://schema.org/childMinAge",children:"http://schema.org/children",cholesterolContent:"http://schema.org/cholesterolContent",circle:"http://schema.org/circle",citation:"http://schema.org/citation",claimReviewed:"http://schema.org/claimReviewed",clipNumber:"http://schema.org/clipNumber",closes:"http://schema.org/closes",coach:"http://schema.org/coach",codeRepository:"http://schema.org/codeRepository",colleagues:"http://schema.org/colleagues",collection:"http://schema.org/collection",color:"http://schema.org/color",comment:"http://schema.org/comment",commentCount:"http://schema.org/commentCount",commentText:"http://schema.org/commentText",commentTime:"http://schema.org/commentTime",composer:"http://schema.org/composer",confirmationNumber:"http://schema.org/confirmationNumber",contactOption:"http://schema.org/contactOption",contactPoints:"http://schema.org/contactPoints",contactType:"http://schema.org/contactType",containedIn:"http://schema.org/containedIn",contentRating:"http://schema.org/contentRating",contentSize:"http://schema.org/contentSize",contentType:"http://schema.org/contentType",contentUrl:"http://schema.org/contentUrl",contributor:"http://schema.org/contributor",cookTime:"http://schema.org/cookTime",cookingMethod:"http://schema.org/cookingMethod",copyrightHolder:"http://schema.org/copyrightHolder",copyrightYear:"http://schema.org/copyrightYear",countriesNotSupported:"http://schema.org/countriesNotSupported",countriesSupported:"http://schema.org/countriesSupported",countryOfOrigin:"http://schema.org/countryOfOrigin",course:"http://schema.org/course",courseCode:"http://schema.org/courseCode",courseMode:"http://schema.org/courseMode",coursePrerequisites:"http://schema.org/coursePrerequisites",coverageEndTime:"http://schema.org/coverageEndTime",coverageStartTime:"http://schema.org/coverageStartTime",creator:"http://schema.org/creator",creditedTo:"http://schema.org/creditedTo",cssSelector:"http://schema.org/cssSelector",currenciesAccepted:"http://schema.org/currenciesAccepted",currency:"http://schema.org/currency",customer:"http://schema.org/customer",dataFeedElement:"http://schema.org/dataFeedElement",datasetTimeInterval:"http://schema.org/datasetTimeInterval",dateCreated:"http://schema.org/dateCreated",dateDeleted:"http://schema.org/dateDeleted",dateIssued:"http://schema.org/dateIssued",dateModified:"http://schema.org/dateModified",datePosted:"http://schema.org/datePosted",datePublished:"http://schema.org/datePublished",dateRead:"http://schema.org/dateRead",dateReceived:"http://schema.org/dateReceived",dateSent:"http://schema.org/dateSent",dateVehicleFirstRegistered:"http://schema.org/dateVehicleFirstRegistered",dateline:"http://schema.org/dateline",dayOfWeek:"http://schema.org/dayOfWeek",deathDate:"http://schema.org/deathDate",deathPlace:"http://schema.org/deathPlace",defaultValue:"http://schema.org/defaultValue",deliveryAddress:"http://schema.org/deliveryAddress",deliveryLeadTime:"http://schema.org/deliveryLeadTime",deliveryMethod:"http://schema.org/deliveryMethod",deliveryStatus:"http://schema.org/deliveryStatus",department:"http://schema.org/department",departureAirport:"http://schema.org/departureAirport",departureBusStop:"http://schema.org/departureBusStop",departureGate:"http://schema.org/departureGate",departurePlatform:"http://schema.org/departurePlatform",departureStation:"http://schema.org/departureStation",departureTerminal:"http://schema.org/departureTerminal",departureTime:"http://schema.org/departureTime",dependencies:"http://schema.org/dependencies",depth:"http://schema.org/depth",device:"http://schema.org/device",directors:"http://schema.org/directors",disambiguatingDescription:"http://schema.org/disambiguatingDescription",discount:"http://schema.org/discount",discountCode:"http://schema.org/discountCode",discountCurrency:"http://schema.org/discountCurrency",discusses:"http://schema.org/discusses",discussionUrl:"http://schema.org/discussionUrl",dissolutionDate:"http://schema.org/dissolutionDate",distance:"http://schema.org/distance",distribution:"http://schema.org/distribution",doorTime:"http://schema.org/doorTime",downloadUrl:"http://schema.org/downloadUrl",downvoteCount:"http://schema.org/downvoteCount",driveWheelConfiguration:"http://schema.org/driveWheelConfiguration",dropoffLocation:"http://schema.org/dropoffLocation",dropoffTime:"http://schema.org/dropoffTime",duns:"http://schema.org/duns",durationOfWarranty:"http://schema.org/durationOfWarranty",duringMedia:"http://schema.org/duringMedia",editor:"http://schema.org/editor",educationalAlignment:"http://schema.org/educationalAlignment",educationalCredentialAwarded:"http://schema.org/educationalCredentialAwarded",educationalFramework:"http://schema.org/educationalFramework",educationalRole:"http://schema.org/educationalRole",educationalUse:"http://schema.org/educationalUse",elevation:"http://schema.org/elevation",eligibleCustomerType:"http://schema.org/eligibleCustomerType",eligibleDuration:"http://schema.org/eligibleDuration",eligibleQuantity:"http://schema.org/eligibleQuantity",eligibleRegion:"http://schema.org/eligibleRegion",eligibleTransactionVolume:"http://schema.org/eligibleTransactionVolume",email:"http://schema.org/email",embedUrl:"http://schema.org/embedUrl",employees:"http://schema.org/employees",employmentType:"http://schema.org/employmentType",encodingType:"http://schema.org/encodingType",encodings:"http://schema.org/encodings",endDate:"http://schema.org/endDate",endTime:"http://schema.org/endTime",endorsee:"http://schema.org/endorsee",entertainmentBusiness:"http://schema.org/entertainmentBusiness",episodeNumber:"http://schema.org/episodeNumber",episodes:"http://schema.org/episodes",equal:"http://schema.org/equal",error:"http://schema.org/error",estimatedCost:"http://schema.org/estimatedCost",estimatedFlightDuration:"http://schema.org/estimatedFlightDuration",estimatedSalary:"http://schema.org/estimatedSalary",eventStatus:"http://schema.org/eventStatus",events:"http://schema.org/events",exifData:"http://schema.org/exifData",expectedArrivalFrom:"http://schema.org/expectedArrivalFrom",expectedArrivalUntil:"http://schema.org/expectedArrivalUntil",expectsAcceptanceOf:"http://schema.org/expectsAcceptanceOf",experienceRequirements:"http://schema.org/experienceRequirements",expires:"http://schema.org/expires",familyName:"http://schema.org/familyName",fatContent:"http://schema.org/fatContent",faxNumber:"http://schema.org/faxNumber",featureList:"http://schema.org/featureList",feesAndCommissionsSpecification:"http://schema.org/feesAndCommissionsSpecification",fiberContent:"http://schema.org/fiberContent",fileFormat:"http://schema.org/fileFormat",fileSize:"http://schema.org/fileSize",firstPerformance:"http://schema.org/firstPerformance",flightDistance:"http://schema.org/flightDistance",flightNumber:"http://schema.org/flightNumber",floorSize:"http://schema.org/floorSize",followee:"http://schema.org/followee",follows:"http://schema.org/follows",foodEstablishment:"http://schema.org/foodEstablishment",foodEvent:"http://schema.org/foodEvent",founders:"http://schema.org/founders",foundingDate:"http://schema.org/foundingDate",foundingLocation:"http://schema.org/foundingLocation",free:"http://schema.org/free",fromLocation:"http://schema.org/fromLocation",fuelConsumption:"http://schema.org/fuelConsumption",fuelEfficiency:"http://schema.org/fuelEfficiency",fuelType:"http://schema.org/fuelType",funder:"http://schema.org/funder",gameItem:"http://schema.org/gameItem",gameLocation:"http://schema.org/gameLocation",gamePlatform:"http://schema.org/gamePlatform",gameTip:"http://schema.org/gameTip",gender:"http://schema.org/gender",genre:"http://schema.org/genre",geo:"http://schema.org/geo",geoContains:"http://schema.org/geoContains",geoCoveredBy:"http://schema.org/geoCoveredBy",geoCovers:"http://schema.org/geoCovers",geoCrosses:"http://schema.org/geoCrosses",geoDisjoint:"http://schema.org/geoDisjoint",geoEquals:"http://schema.org/geoEquals",geoIntersects:"http://schema.org/geoIntersects",geoMidpoint:"http://schema.org/geoMidpoint",geoOverlaps:"http://schema.org/geoOverlaps",geoRadius:"http://schema.org/geoRadius",geoTouches:"http://schema.org/geoTouches",geoWithin:"http://schema.org/geoWithin",geographicArea:"http://schema.org/geographicArea",givenName:"http://schema.org/givenName",globalLocationNumber:"http://schema.org/globalLocationNumber",grantee:"http://schema.org/grantee",greater:"http://schema.org/greater",greaterOrEqual:"http://schema.org/greaterOrEqual",gtin12:"http://schema.org/gtin12",gtin13:"http://schema.org/gtin13",gtin14:"http://schema.org/gtin14",gtin8:"http://schema.org/gtin8",hasCourseInstance:"http://schema.org/hasCourseInstance",hasDeliveryMethod:"http://schema.org/hasDeliveryMethod",hasDigitalDocumentPermission:"http://schema.org/hasDigitalDocumentPermission",hasMenuItem:"http://schema.org/hasMenuItem",hasMenuSection:"http://schema.org/hasMenuSection",hasOccupation:"http://schema.org/hasOccupation",hasOfferCatalog:"http://schema.org/hasOfferCatalog",hasPOS:"http://schema.org/hasPOS",headline:"http://schema.org/headline",height:"http://schema.org/height",highPrice:"http://schema.org/highPrice",hiringOrganization:"http://schema.org/hiringOrganization",homeLocation:"http://schema.org/homeLocation",homeTeam:"http://schema.org/homeTeam",honorificPrefix:"http://schema.org/honorificPrefix",honorificSuffix:"http://schema.org/honorificSuffix",hostingOrganization:"http://schema.org/hostingOrganization",hoursAvailable:"http://schema.org/hoursAvailable",httpMethod:"http://schema.org/httpMethod",iataCode:"http://schema.org/iataCode",icaoCode:"http://schema.org/icaoCode",illustrator:"http://schema.org/illustrator",inAlbum:"http://schema.org/inAlbum",inBroadcastLineup:"http://schema.org/inBroadcastLineup",inPlaylist:"http://schema.org/inPlaylist",incentives:"http://schema.org/incentives",includedComposition:"http://schema.org/includedComposition",includedDataCatalog:"http://schema.org/includedDataCatalog",includesObject:"http://schema.org/includesObject",industry:"http://schema.org/industry",ineligibleRegion:"http://schema.org/ineligibleRegion",ingredients:"http://schema.org/ingredients",installUrl:"http://schema.org/installUrl",instructor:"http://schema.org/instructor",interactionCount:"http://schema.org/interactionCount",interactionService:"http://schema.org/interactionService",interactionType:"http://schema.org/interactionType",interactivityType:"http://schema.org/interactivityType",interestRate:"http://schema.org/interestRate",inventoryLevel:"http://schema.org/inventoryLevel",isAccessoryOrSparePartFor:"http://schema.org/isAccessoryOrSparePartFor",isBasedOnUrl:"http://schema.org/isBasedOnUrl",isConsumableFor:"http://schema.org/isConsumableFor",isFamilyFriendly:"http://schema.org/isFamilyFriendly",isGift:"http://schema.org/isGift",isLiveBroadcast:"http://schema.org/isLiveBroadcast",isRelatedTo:"http://schema.org/isRelatedTo",isSimilarTo:"http://schema.org/isSimilarTo",isVariantOf:"http://schema.org/isVariantOf",isbn:"http://schema.org/isbn",isicV4:"http://schema.org/isicV4",isrcCode:"http://schema.org/isrcCode",issn:"http://schema.org/issn",issueNumber:"http://schema.org/issueNumber",issuedBy:"http://schema.org/issuedBy",issuedThrough:"http://schema.org/issuedThrough",iswcCode:"http://schema.org/iswcCode",item:"http://schema.org/item",itemCondition:"http://schema.org/itemCondition",itemListElement:"http://schema.org/itemListElement",itemListOrder:"http://schema.org/itemListOrder",itemOffered:"http://schema.org/itemOffered",itemReviewed:"http://schema.org/itemReviewed",itemShipped:"http://schema.org/itemShipped",jobLocation:"http://schema.org/jobLocation",keywords:"http://schema.org/keywords",knownVehicleDamages:"http://schema.org/knownVehicleDamages",knows:"http://schema.org/knows",landlord:"http://schema.org/landlord",language:"http://schema.org/language",lastReviewed:"http://schema.org/lastReviewed",latitude:"http://schema.org/latitude",learningResourceType:"http://schema.org/learningResourceType",legalName:"http://schema.org/legalName",leiCode:"http://schema.org/leiCode",lender:"http://schema.org/lender",lesser:"http://schema.org/lesser",lesserOrEqual:"http://schema.org/lesserOrEqual",license:"http://schema.org/license",line:"http://schema.org/line",liveBlogUpdate:"http://schema.org/liveBlogUpdate",loanTerm:"http://schema.org/loanTerm",locationCreated:"http://schema.org/locationCreated",lodgingUnitDescription:"http://schema.org/lodgingUnitDescription",lodgingUnitType:"http://schema.org/lodgingUnitType",logo:"http://schema.org/logo",longitude:"http://schema.org/longitude",loser:"http://schema.org/loser",lowPrice:"http://schema.org/lowPrice",lyricist:"http://schema.org/lyricist",lyrics:"http://schema.org/lyrics",mainContentOfPage:"http://schema.org/mainContentOfPage",manufacturer:"http://schema.org/manufacturer",map:"http://schema.org/map",mapType:"http://schema.org/mapType",maps:"http://schema.org/maps",maxPrice:"http://schema.org/maxPrice",maxValue:"http://schema.org/maxValue",maximumAttendeeCapacity:"http://schema.org/maximumAttendeeCapacity",mealService:"http://schema.org/mealService",median:"http://schema.org/median",members:"http://schema.org/members",membershipNumber:"http://schema.org/membershipNumber",memoryRequirements:"http://schema.org/memoryRequirements",mentions:"http://schema.org/mentions",menu:"http://schema.org/menu",menuAddOn:"http://schema.org/menuAddOn",merchant:"http://schema.org/merchant",messageAttachment:"http://schema.org/messageAttachment",mileageFromOdometer:"http://schema.org/mileageFromOdometer",minPrice:"http://schema.org/minPrice",minValue:"http://schema.org/minValue",minimumPaymentDue:"http://schema.org/minimumPaymentDue",model:"http://schema.org/model",modifiedTime:"http://schema.org/modifiedTime",mpn:"http://schema.org/mpn",multipleValues:"http://schema.org/multipleValues",musicArrangement:"http://schema.org/musicArrangement",musicBy:"http://schema.org/musicBy",musicCompositionForm:"http://schema.org/musicCompositionForm",musicGroupMember:"http://schema.org/musicGroupMember",musicReleaseFormat:"http://schema.org/musicReleaseFormat",musicalKey:"http://schema.org/musicalKey",naics:"http://schema.org/naics",name:"http://schema.org/name",namedPosition:"http://schema.org/namedPosition",nationality:"http://schema.org/nationality",netWorth:"http://schema.org/netWorth",nextItem:"http://schema.org/nextItem",nonEqual:"http://schema.org/nonEqual",numAdults:"http://schema.org/numAdults",numChildren:"http://schema.org/numChildren",numTracks:"http://schema.org/numTracks",numberOfAirbags:"http://schema.org/numberOfAirbags",numberOfAxles:"http://schema.org/numberOfAxles",numberOfBeds:"http://schema.org/numberOfBeds",numberOfDoors:"http://schema.org/numberOfDoors",numberOfEmployees:"http://schema.org/numberOfEmployees",numberOfEpisodes:"http://schema.org/numberOfEpisodes",numberOfForwardGears:"http://schema.org/numberOfForwardGears",numberOfItems:"http://schema.org/numberOfItems",numberOfPages:"http://schema.org/numberOfPages",numberOfPlayers:"http://schema.org/numberOfPlayers",numberOfPreviousOwners:"http://schema.org/numberOfPreviousOwners",numberOfRooms:"http://schema.org/numberOfRooms",numberOfSeasons:"http://schema.org/numberOfSeasons",numberedPosition:"http://schema.org/numberedPosition",nutrition:"http://schema.org/nutrition",occupancy:"http://schema.org/occupancy",occupationLocation:"http://schema.org/occupationLocation",occupationalCategory:"http://schema.org/occupationalCategory",offerCount:"http://schema.org/offerCount",offers:"http://schema.org/offers",openingHours:"http://schema.org/openingHours",openingHoursSpecification:"http://schema.org/openingHoursSpecification",opens:"http://schema.org/opens",operatingSystem:"http://schema.org/operatingSystem",opponent:"http://schema.org/opponent",option:"http://schema.org/option",orderDate:"http://schema.org/orderDate",orderDelivery:"http://schema.org/orderDelivery",orderItemNumber:"http://schema.org/orderItemNumber",orderItemStatus:"http://schema.org/orderItemStatus",orderNumber:"http://schema.org/orderNumber",orderQuantity:"http://schema.org/orderQuantity",orderStatus:"http://schema.org/orderStatus",orderedItem:"http://schema.org/orderedItem",organizer:"http://schema.org/organizer",originAddress:"http://schema.org/originAddress",ownedFrom:"http://schema.org/ownedFrom",ownedThrough:"http://schema.org/ownedThrough",owns:"http://schema.org/owns",pageEnd:"http://schema.org/pageEnd",pageStart:"http://schema.org/pageStart",pagination:"http://schema.org/pagination",parentItem:"http://schema.org/parentItem",parentService:"http://schema.org/parentService",parents:"http://schema.org/parents",partOfEpisode:"http://schema.org/partOfEpisode",partOfInvoice:"http://schema.org/partOfInvoice",partOfOrder:"http://schema.org/partOfOrder",partOfSeason:"http://schema.org/partOfSeason",partOfTVSeries:"http://schema.org/partOfTVSeries",partySize:"http://schema.org/partySize",passengerPriorityStatus:"http://schema.org/passengerPriorityStatus",passengerSequenceNumber:"http://schema.org/passengerSequenceNumber",paymentAccepted:"http://schema.org/paymentAccepted",paymentDue:"http://schema.org/paymentDue",paymentMethod:"http://schema.org/paymentMethod",paymentMethodId:"http://schema.org/paymentMethodId",paymentStatus:"http://schema.org/paymentStatus",paymentUrl:"http://schema.org/paymentUrl",percentile10:"http://schema.org/percentile10",percentile25:"http://schema.org/percentile25",percentile75:"http://schema.org/percentile75",percentile90:"http://schema.org/percentile90",performerIn:"http://schema.org/performerIn",performers:"http://schema.org/performers",permissionType:"http://schema.org/permissionType",permissions:"http://schema.org/permissions",permitAudience:"http://schema.org/permitAudience",permittedUsage:"http://schema.org/permittedUsage",petsAllowed:"http://schema.org/petsAllowed",photos:"http://schema.org/photos",pickupLocation:"http://schema.org/pickupLocation",pickupTime:"http://schema.org/pickupTime",playMode:"http://schema.org/playMode",playerType:"http://schema.org/playerType",playersOnline:"http://schema.org/playersOnline",polygon:"http://schema.org/polygon",postOfficeBoxNumber:"http://schema.org/postOfficeBoxNumber",postalCode:"http://schema.org/postalCode",potentialAction:"http://schema.org/potentialAction",predecessorOf:"http://schema.org/predecessorOf",prepTime:"http://schema.org/prepTime",previousItem:"http://schema.org/previousItem",previousStartDate:"http://schema.org/previousStartDate",price:"http://schema.org/price",priceComponent:"http://schema.org/priceComponent",priceCurrency:"http://schema.org/priceCurrency",priceRange:"http://schema.org/priceRange",priceSpecification:"http://schema.org/priceSpecification",priceType:"http://schema.org/priceType",priceValidUntil:"http://schema.org/priceValidUntil",primaryImageOfPage:"http://schema.org/primaryImageOfPage",printColumn:"http://schema.org/printColumn",printEdition:"http://schema.org/printEdition",printPage:"http://schema.org/printPage",printSection:"http://schema.org/printSection",processingTime:"http://schema.org/processingTime",processorRequirements:"http://schema.org/processorRequirements",producer:"http://schema.org/producer",produces:"http://schema.org/produces",productID:"http://schema.org/productID",productSupported:"http://schema.org/productSupported",productionCompany:"http://schema.org/productionCompany",productionDate:"http://schema.org/productionDate",proficiencyLevel:"http://schema.org/proficiencyLevel",programMembershipUsed:"http://schema.org/programMembershipUsed",programName:"http://schema.org/programName",programmingLanguage:"http://schema.org/programmingLanguage",programmingModel:"http://schema.org/programmingModel",propertyID:"http://schema.org/propertyID",proteinContent:"http://schema.org/proteinContent",providerMobility:"http://schema.org/providerMobility",providesService:"http://schema.org/providesService",publicAccess:"http://schema.org/publicAccess",publication:"http://schema.org/publication",publishedOn:"http://schema.org/publishedOn",publisher:"http://schema.org/publisher",publishingPrinciples:"http://schema.org/publishingPrinciples",purchaseDate:"http://schema.org/purchaseDate",query:"http://schema.org/query",quest:"http://schema.org/quest",question:"http://schema.org/question",ratingCount:"http://schema.org/ratingCount",ratingValue:"http://schema.org/ratingValue",readonlyValue:"http://schema.org/readonlyValue",realEstateAgent:"http://schema.org/realEstateAgent",recipe:"http://schema.org/recipe",recipeCategory:"http://schema.org/recipeCategory",recipeCuisine:"http://schema.org/recipeCuisine",recipeInstructions:"http://schema.org/recipeInstructions",recipeYield:"http://schema.org/recipeYield",recordLabel:"http://schema.org/recordLabel",referenceQuantity:"http://schema.org/referenceQuantity",referencesOrder:"http://schema.org/referencesOrder",regionsAllowed:"http://schema.org/regionsAllowed",relatedLink:"http://schema.org/relatedLink",relatedTo:"http://schema.org/relatedTo",releaseDate:"http://schema.org/releaseDate",releaseNotes:"http://schema.org/releaseNotes",releasedEvent:"http://schema.org/releasedEvent",relevantOccupation:"http://schema.org/relevantOccupation",remainingAttendeeCapacity:"http://schema.org/remainingAttendeeCapacity",replacee:"http://schema.org/replacee",replacer:"http://schema.org/replacer",replyToUrl:"http://schema.org/replyToUrl",reportNumber:"http://schema.org/reportNumber",representativeOfPage:"http://schema.org/representativeOfPage",requiredCollateral:"http://schema.org/requiredCollateral",requiredGender:"http://schema.org/requiredGender",requiredMaxAge:"http://schema.org/requiredMaxAge",requiredMinAge:"http://schema.org/requiredMinAge",requiredQuantity:"http://schema.org/requiredQuantity",requirements:"http://schema.org/requirements",requiresSubscription:"http://schema.org/requiresSubscription",reservationFor:"http://schema.org/reservationFor",reservationId:"http://schema.org/reservationId",reservationStatus:"http://schema.org/reservationStatus",reservedTicket:"http://schema.org/reservedTicket",responsibilities:"http://schema.org/responsibilities",resultComment:"http://schema.org/resultComment",resultReview:"http://schema.org/resultReview",reviewAspect:"http://schema.org/reviewAspect",reviewBody:"http://schema.org/reviewBody",reviewCount:"http://schema.org/reviewCount",reviewRating:"http://schema.org/reviewRating",reviewedBy:"http://schema.org/reviewedBy",reviews:"http://schema.org/reviews",rsvpResponse:"http://schema.org/rsvpResponse",runtime:"http://schema.org/runtime",salaryCurrency:"http://schema.org/salaryCurrency",sameAs:"http://schema.org/sameAs",sampleType:"http://schema.org/sampleType",saturatedFatContent:"http://schema.org/saturatedFatContent",scheduledPaymentDate:"http://schema.org/scheduledPaymentDate",scheduledTime:"http://schema.org/scheduledTime",schemaVersion:"http://schema.org/schemaVersion",screenCount:"http://schema.org/screenCount",screenshot:"http://schema.org/screenshot",seasonNumber:"http://schema.org/seasonNumber",seasons:"http://schema.org/seasons",seatNumber:"http://schema.org/seatNumber",seatRow:"http://schema.org/seatRow",seatSection:"http://schema.org/seatSection",seatingType:"http://schema.org/seatingType",securityScreening:"http://schema.org/securityScreening",seeks:"http://schema.org/seeks",sender:"http://schema.org/sender",serverStatus:"http://schema.org/serverStatus",servesCuisine:"http://schema.org/servesCuisine",serviceAudience:"http://schema.org/serviceAudience",serviceLocation:"http://schema.org/serviceLocation",serviceOperator:"http://schema.org/serviceOperator",servicePhone:"http://schema.org/servicePhone",servicePostalAddress:"http://schema.org/servicePostalAddress",serviceSmsNumber:"http://schema.org/serviceSmsNumber",serviceType:"http://schema.org/serviceType",serviceUrl:"http://schema.org/serviceUrl",servingSize:"http://schema.org/servingSize",sharedContent:"http://schema.org/sharedContent",siblings:"http://schema.org/siblings",significantLinks:"http://schema.org/significantLinks",skills:"http://schema.org/skills",sku:"http://schema.org/sku",slogan:"http://schema.org/slogan",smokingAllowed:"http://schema.org/smokingAllowed",sodiumContent:"http://schema.org/sodiumContent",softwareAddOn:"http://schema.org/softwareAddOn",softwareHelp:"http://schema.org/softwareHelp",softwareVersion:"http://schema.org/softwareVersion",sourceOrganization:"http://schema.org/sourceOrganization",spatial:"http://schema.org/spatial",spatialCoverage:"http://schema.org/spatialCoverage",speakable:"http://schema.org/speakable",specialCommitments:"http://schema.org/specialCommitments",specialOpeningHoursSpecification:"http://schema.org/specialOpeningHoursSpecification",specialty:"http://schema.org/specialty",sport:"http://schema.org/sport",sportsActivityLocation:"http://schema.org/sportsActivityLocation",sportsEvent:"http://schema.org/sportsEvent",sportsTeam:"http://schema.org/sportsTeam",spouse:"http://schema.org/spouse",starRating:"http://schema.org/starRating",startDate:"http://schema.org/startDate",startTime:"http://schema.org/startTime",steeringPosition:"http://schema.org/steeringPosition",stepValue:"http://schema.org/stepValue",steps:"http://schema.org/steps",storageRequirements:"http://schema.org/storageRequirements",streetAddress:"http://schema.org/streetAddress",subEvents:"http://schema.org/subEvents",subReservation:"http://schema.org/subReservation",subtitleLanguage:"http://schema.org/subtitleLanguage",successorOf:"http://schema.org/successorOf",sugarContent:"http://schema.org/sugarContent",suggestedGender:"http://schema.org/suggestedGender",suggestedMaxAge:"http://schema.org/suggestedMaxAge",suggestedMinAge:"http://schema.org/suggestedMinAge",suitableForDiet:"http://schema.org/suitableForDiet",supportingData:"http://schema.org/supportingData",surface:"http://schema.org/surface",target:"http://schema.org/target",targetDescription:"http://schema.org/targetDescription",targetName:"http://schema.org/targetName",targetPlatform:"http://schema.org/targetPlatform",targetProduct:"http://schema.org/targetProduct",targetUrl:"http://schema.org/targetUrl",taxID:"http://schema.org/taxID",telephone:"http://schema.org/telephone",temporal:"http://schema.org/temporal",text:"http://schema.org/text",thumbnail:"http://schema.org/thumbnail",thumbnailUrl:"http://schema.org/thumbnailUrl",tickerSymbol:"http://schema.org/tickerSymbol",ticketNumber:"http://schema.org/ticketNumber",ticketToken:"http://schema.org/ticketToken",ticketedSeat:"http://schema.org/ticketedSeat",timeRequired:"http://schema.org/timeRequired",title:"http://schema.org/title",toLocation:"http://schema.org/toLocation",toRecipient:"http://schema.org/toRecipient",tool:"http://schema.org/tool",totalPaymentDue:"http://schema.org/totalPaymentDue",totalPrice:"http://schema.org/totalPrice",totalTime:"http://schema.org/totalTime",touristType:"http://schema.org/touristType",trackingNumber:"http://schema.org/trackingNumber",trackingUrl:"http://schema.org/trackingUrl",tracks:"http://schema.org/tracks",trailer:"http://schema.org/trailer",trainName:"http://schema.org/trainName",trainNumber:"http://schema.org/trainNumber",transFatContent:"http://schema.org/transFatContent",transcript:"http://schema.org/transcript",translator:"http://schema.org/translator",typeOfBed:"http://schema.org/typeOfBed",typeOfGood:"http://schema.org/typeOfGood",typicalAgeRange:"http://schema.org/typicalAgeRange",underName:"http://schema.org/underName",unitCode:"http://schema.org/unitCode",unitText:"http://schema.org/unitText",unsaturatedFatContent:"http://schema.org/unsaturatedFatContent",uploadDate:"http://schema.org/uploadDate",upvoteCount:"http://schema.org/upvoteCount",url:"http://schema.org/url",urlTemplate:"http://schema.org/urlTemplate",userInteractionCount:"http://schema.org/userInteractionCount",validFor:"http://schema.org/validFor",validFrom:"http://schema.org/validFrom",validIn:"http://schema.org/validIn",validThrough:"http://schema.org/validThrough",validUntil:"http://schema.org/validUntil",value:"http://schema.org/value",valueAddedTaxIncluded:"http://schema.org/valueAddedTaxIncluded",valueMaxLength:"http://schema.org/valueMaxLength",valueMinLength:"http://schema.org/valueMinLength",valueName:"http://schema.org/valueName",valuePattern:"http://schema.org/valuePattern",valueReference:"http://schema.org/valueReference",valueRequired:"http://schema.org/valueRequired",vatID:"http://schema.org/vatID",vehicleConfiguration:"http://schema.org/vehicleConfiguration",vehicleEngine:"http://schema.org/vehicleEngine",vehicleIdentificationNumber:"http://schema.org/vehicleIdentificationNumber",vehicleInteriorColor:"http://schema.org/vehicleInteriorColor",vehicleInteriorType:"http://schema.org/vehicleInteriorType",vehicleModelDate:"http://schema.org/vehicleModelDate",vehicleSeatingCapacity:"http://schema.org/vehicleSeatingCapacity",vehicleTransmission:"http://schema.org/vehicleTransmission",vendor:"http://schema.org/vendor",version:"http://schema.org/version",video:"http://schema.org/video",videoFormat:"http://schema.org/videoFormat",videoFrameSize:"http://schema.org/videoFrameSize",videoQuality:"http://schema.org/videoQuality",volumeNumber:"http://schema.org/volumeNumber",warrantyPromise:"http://schema.org/warrantyPromise",warrantyScope:"http://schema.org/warrantyScope",webCheckinTime:"http://schema.org/webCheckinTime",weight:"http://schema.org/weight",width:"http://schema.org/width",winner:"http://schema.org/winner",wordCount:"http://schema.org/wordCount",workHours:"http://schema.org/workHours",workLocation:"http://schema.org/workLocation",workPerformed:"http://schema.org/workPerformed",workPresented:"http://schema.org/workPresented",worksFor:"http://schema.org/worksFor",worstRating:"http://schema.org/worstRating",xpath:"http://schema.org/xpath",yearlyRevenue:"http://schema.org/yearlyRevenue",yearsInOperation:"http://schema.org/yearsInOperation",actionApplication:"http://schema.org/actionApplication",actionOption:"http://schema.org/actionOption",actor:"http://schema.org/actor",album:"http://schema.org/album",albumRelease:"http://schema.org/albumRelease",alumni:"http://schema.org/alumni",alumniOf:"http://schema.org/alumniOf",artworkSurface:"http://schema.org/artworkSurface",attendee:"http://schema.org/attendee",audience:"http://schema.org/audience",availableOnDevice:"http://schema.org/availableOnDevice",award:"http://schema.org/award",blogPost:"http://schema.org/blogPost",broker:"http://schema.org/broker",codeSampleType:"http://schema.org/codeSampleType",colleague:"http://schema.org/colleague",contactPoint:"http://schema.org/contactPoint",containsPlace:"http://schema.org/containsPlace",containsSeason:"http://schema.org/containsSeason",contentLocation:"http://schema.org/contentLocation",dataset:"http://schema.org/dataset",description:"http://schema.org/description",director:"http://schema.org/director",duration:"http://schema.org/duration",employee:"http://schema.org/employee",encodesCreativeWork:"http://schema.org/encodesCreativeWork",encodingFormat:"http://schema.org/encodingFormat",episode:"http://schema.org/episode",event:"http://schema.org/event",exampleOfWork:"http://schema.org/exampleOfWork",executableLibraryName:"http://schema.org/executableLibraryName",exerciseCourse:"http://schema.org/exerciseCourse",founder:"http://schema.org/founder",game:"http://schema.org/game",gameServer:"http://schema.org/gameServer",hasBroadcastChannel:"http://schema.org/hasBroadcastChannel",hasMenu:"http://schema.org/hasMenu",inLanguage:"http://schema.org/inLanguage",incentiveCompensation:"http://schema.org/incentiveCompensation",interactionStatistic:"http://schema.org/interactionStatistic",isAccessibleForFree:"http://schema.org/isAccessibleForFree",isBasedOn:"http://schema.org/isBasedOn",jobBenefits:"http://schema.org/jobBenefits",mainEntity:"http://schema.org/mainEntity",mainEntityOfPage:"http://schema.org/mainEntityOfPage",makesOffer:"http://schema.org/makesOffer",offeredBy:"http://schema.org/offeredBy",parent:"http://schema.org/parent",partOfSeries:"http://schema.org/partOfSeries",paymentDueDate:"http://schema.org/paymentDueDate",performTime:"http://schema.org/performTime",performer:"http://schema.org/performer",photo:"http://schema.org/photo",provider:"http://schema.org/provider",providesBroadcastService:"http://schema.org/providesBroadcastService",recipeIngredient:"http://schema.org/recipeIngredient",recordedAs:"http://schema.org/recordedAs",recordedAt:"http://schema.org/recordedAt",recordedIn:"http://schema.org/recordedIn",recordingOf:"http://schema.org/recordingOf",releaseOf:"http://schema.org/releaseOf",review:"http://schema.org/review",roleName:"http://schema.org/roleName",runtimePlatform:"http://schema.org/runtimePlatform",season:"http://schema.org/season",serialNumber:"http://schema.org/serialNumber",serviceArea:"http://schema.org/serviceArea",serviceOutput:"http://schema.org/serviceOutput",sibling:"http://schema.org/sibling",significantLink:"http://schema.org/significantLink",softwareRequirements:"http://schema.org/softwareRequirements",sponsor:"http://schema.org/sponsor",subOrganization:"http://schema.org/subOrganization",subjectOf:"http://schema.org/subjectOf",suggestedAnswer:"http://schema.org/suggestedAnswer",superEvent:"http://schema.org/superEvent",targetCollection:"http://schema.org/targetCollection",temporalCoverage:"http://schema.org/temporalCoverage",track:"http://schema.org/track",warranty:"http://schema.org/warranty",workExample:"http://schema.org/workExample",yield__workaround:"http://schema.org/yield",about:"http://schema.org/about",competitor:"http://schema.org/competitor",containedInPlace:"http://schema.org/containedInPlace",encoding:"http://schema.org/encoding",hasMap:"http://schema.org/hasMap",image:"http://schema.org/image",material:"http://schema.org/material",memberOf:"http://schema.org/memberOf",parentOrganization:"http://schema.org/parentOrganization",result:"http://schema.org/result",seller:"http://schema.org/seller",step:"http://schema.org/step",subEvent:"http://schema.org/subEvent",supply:"http://schema.org/supply",workFeatured:"http://schema.org/workFeatured",areaServed:"http://schema.org/areaServed",includedInDataCatalog:"http://schema.org/includedInDataCatalog",member:"http://schema.org/member",recipient:"http://schema.org/recipient",hasPart:"http://schema.org/hasPart",isPartOf:"http://schema.org/isPartOf",position:"http://schema.org/position",instrument:"http://schema.org/instrument",object:"http://schema.org/object",location:"http://schema.org/location",participant:"http://schema.org/participant",identifier:"http://schema.org/identifier",AMRadioChannel:"http://schema.org/AMRadioChannel",APIReference:"http://schema.org/APIReference",AboutPage:"http://schema.org/AboutPage",AcceptAction:"http://schema.org/AcceptAction",Accommodation:"http://schema.org/Accommodation",AccountingService:"http://schema.org/AccountingService",AchieveAction:"http://schema.org/AchieveAction",Action:"http://schema.org/Action",ActionAccessSpecification:"http://schema.org/ActionAccessSpecification",ActionStatusType:"http://schema.org/ActionStatusType",ActivateAction:"http://schema.org/ActivateAction",AddAction:"http://schema.org/AddAction",AdministrativeArea:"http://schema.org/AdministrativeArea",AdultEntertainment:"http://schema.org/AdultEntertainment",AggregateOffer:"http://schema.org/AggregateOffer",AggregateRating:"http://schema.org/AggregateRating",AgreeAction:"http://schema.org/AgreeAction",Airline:"http://schema.org/Airline",Airport:"http://schema.org/Airport",AlignmentObject:"http://schema.org/AlignmentObject",AllocateAction:"http://schema.org/AllocateAction",AmusementPark:"http://schema.org/AmusementPark",AnimalShelter:"http://schema.org/AnimalShelter",Answer:"http://schema.org/Answer",Apartment:"http://schema.org/Apartment",ApartmentComplex:"http://schema.org/ApartmentComplex",AppendAction:"http://schema.org/AppendAction",ApplyAction:"http://schema.org/ApplyAction",Aquarium:"http://schema.org/Aquarium",ArriveAction:"http://schema.org/ArriveAction",ArtGallery:"http://schema.org/ArtGallery",Article:"http://schema.org/Article",AskAction:"http://schema.org/AskAction",AssessAction:"http://schema.org/AssessAction",AssignAction:"http://schema.org/AssignAction",Attorney:"http://schema.org/Attorney",Audience:"http://schema.org/Audience",AudioObject:"http://schema.org/AudioObject",AuthorizeAction:"http://schema.org/AuthorizeAction",AutoBodyShop:"http://schema.org/AutoBodyShop",AutoDealer:"http://schema.org/AutoDealer",AutoPartsStore:"http://schema.org/AutoPartsStore",AutoRental:"http://schema.org/AutoRental",AutoRepair:"http://schema.org/AutoRepair",AutoWash:"http://schema.org/AutoWash",AutomatedTeller:"http://schema.org/AutomatedTeller",AutomotiveBusiness:"http://schema.org/AutomotiveBusiness",Bakery:"http://schema.org/Bakery",BankAccount:"http://schema.org/BankAccount",BankOrCreditUnion:"http://schema.org/BankOrCreditUnion",BarOrPub:"http://schema.org/BarOrPub",Barcode:"http://schema.org/Barcode",Beach:"http://schema.org/Beach",BeautySalon:"http://schema.org/BeautySalon",BedAndBreakfast:"http://schema.org/BedAndBreakfast",BedDetails:"http://schema.org/BedDetails",BedType:"http://schema.org/BedType",BefriendAction:"http://schema.org/BefriendAction",BikeStore:"http://schema.org/BikeStore",Blog:"http://schema.org/Blog",BlogPosting:"http://schema.org/BlogPosting",BoardingPolicyType:"http://schema.org/BoardingPolicyType",BodyOfWater:"http://schema.org/BodyOfWater",Book:"http://schema.org/Book",BookFormatType:"http://schema.org/BookFormatType",BookSeries:"http://schema.org/BookSeries",BookStore:"http://schema.org/BookStore",BookmarkAction:"http://schema.org/BookmarkAction",Boolean__workaround:"http://schema.org/Boolean",BorrowAction:"http://schema.org/BorrowAction",BowlingAlley:"http://schema.org/BowlingAlley",Brand:"http://schema.org/Brand",BreadcrumbList:"http://schema.org/BreadcrumbList",Brewery:"http://schema.org/Brewery",Bridge:"http://schema.org/Bridge",BroadcastChannel:"http://schema.org/BroadcastChannel",BroadcastEvent:"http://schema.org/BroadcastEvent",BroadcastFrequencySpecification:"http://schema.org/BroadcastFrequencySpecification",BroadcastService:"http://schema.org/BroadcastService",BuddhistTemple:"http://schema.org/BuddhistTemple",BusReservation:"http://schema.org/BusReservation",BusStation:"http://schema.org/BusStation",BusStop:"http://schema.org/BusStop",BusTrip:"http://schema.org/BusTrip",BusinessAudience:"http://schema.org/BusinessAudience",BusinessEntityType:"http://schema.org/BusinessEntityType",BusinessEvent:"http://schema.org/BusinessEvent",BusinessFunction:"http://schema.org/BusinessFunction",BuyAction:"http://schema.org/BuyAction",CableOrSatelliteService:"http://schema.org/CableOrSatelliteService",CafeOrCoffeeShop:"http://schema.org/CafeOrCoffeeShop",Campground:"http://schema.org/Campground",CampingPitch:"http://schema.org/CampingPitch",Canal:"http://schema.org/Canal",CancelAction:"http://schema.org/CancelAction",Car:"http://schema.org/Car",Casino:"http://schema.org/Casino",CatholicChurch:"http://schema.org/CatholicChurch",Cemetery:"http://schema.org/Cemetery",CheckAction:"http://schema.org/CheckAction",CheckInAction:"http://schema.org/CheckInAction",CheckOutAction:"http://schema.org/CheckOutAction",CheckoutPage:"http://schema.org/CheckoutPage",ChildCare:"http://schema.org/ChildCare",ChildrensEvent:"http://schema.org/ChildrensEvent",ChooseAction:"http://schema.org/ChooseAction",Church:"http://schema.org/Church",City:"http://schema.org/City",CityHall:"http://schema.org/CityHall",CivicStructure:"http://schema.org/CivicStructure",ClaimReview:"http://schema.org/ClaimReview",Clip:"http://schema.org/Clip",ClothingStore:"http://schema.org/ClothingStore",Code:"http://schema.org/Code",CollectionPage:"http://schema.org/CollectionPage",CollegeOrUniversity:"http://schema.org/CollegeOrUniversity",ComedyClub:"http://schema.org/ComedyClub",ComedyEvent:"http://schema.org/ComedyEvent",Comment:"http://schema.org/Comment",CommentAction:"http://schema.org/CommentAction",CommunicateAction:"http://schema.org/CommunicateAction",CompoundPriceSpecification:"http://schema.org/CompoundPriceSpecification",ComputerLanguage:"http://schema.org/ComputerLanguage",ComputerStore:"http://schema.org/ComputerStore",ConfirmAction:"http://schema.org/ConfirmAction",ConsumeAction:"http://schema.org/ConsumeAction",ContactPage:"http://schema.org/ContactPage",ContactPoint:"http://schema.org/ContactPoint",ContactPointOption:"http://schema.org/ContactPointOption",Continent:"http://schema.org/Continent",ControlAction:"http://schema.org/ControlAction",ConvenienceStore:"http://schema.org/ConvenienceStore",Conversation:"http://schema.org/Conversation",CookAction:"http://schema.org/CookAction",Corporation:"http://schema.org/Corporation",Country:"http://schema.org/Country",Course:"http://schema.org/Course",CourseInstance:"http://schema.org/CourseInstance",Courthouse:"http://schema.org/Courthouse",CreateAction:"http://schema.org/CreateAction",CreativeWork:"http://schema.org/CreativeWork",CreativeWorkSeason:"http://schema.org/CreativeWorkSeason",CreativeWorkSeries:"http://schema.org/CreativeWorkSeries",CreditCard:"http://schema.org/CreditCard",Crematorium:"http://schema.org/Crematorium",CurrencyConversionService:"http://schema.org/CurrencyConversionService",DanceEvent:"http://schema.org/DanceEvent",DanceGroup:"http://schema.org/DanceGroup",DataCatalog:"http://schema.org/DataCatalog",DataDownload:"http://schema.org/DataDownload",DataFeed:"http://schema.org/DataFeed",DataFeedItem:"http://schema.org/DataFeedItem",DataType:"http://schema.org/DataType",Dataset:"http://schema.org/Dataset",Date__workaround:"http://schema.org/Date",DateTime:"http://schema.org/DateTime",DatedMoneySpecification:"http://schema.org/DatedMoneySpecification",DayOfWeek:"http://schema.org/DayOfWeek",DaySpa:"http://schema.org/DaySpa",DeactivateAction:"http://schema.org/DeactivateAction",DefenceEstablishment:"http://schema.org/DefenceEstablishment",DeleteAction:"http://schema.org/DeleteAction",DeliveryChargeSpecification:"http://schema.org/DeliveryChargeSpecification",DeliveryEvent:"http://schema.org/DeliveryEvent",DeliveryMethod:"http://schema.org/DeliveryMethod",Demand:"http://schema.org/Demand",Dentist:"http://schema.org/Dentist",DepartAction:"http://schema.org/DepartAction",DepartmentStore:"http://schema.org/DepartmentStore",DepositAccount:"http://schema.org/DepositAccount",DigitalDocument:"http://schema.org/DigitalDocument",DigitalDocumentPermission:"http://schema.org/DigitalDocumentPermission",DigitalDocumentPermissionType:"http://schema.org/DigitalDocumentPermissionType",DisagreeAction:"http://schema.org/DisagreeAction",DiscoverAction:"http://schema.org/DiscoverAction",DiscussionForumPosting:"http://schema.org/DiscussionForumPosting",DislikeAction:"http://schema.org/DislikeAction",Distance:"http://schema.org/Distance",Distillery:"http://schema.org/Distillery",DonateAction:"http://schema.org/DonateAction",DownloadAction:"http://schema.org/DownloadAction",DrawAction:"http://schema.org/DrawAction",DrinkAction:"http://schema.org/DrinkAction",DriveWheelConfigurationValue:"http://schema.org/DriveWheelConfigurationValue",DryCleaningOrLaundry:"http://schema.org/DryCleaningOrLaundry",Duration:"http://schema.org/Duration",EatAction:"http://schema.org/EatAction",EducationEvent:"http://schema.org/EducationEvent",EducationalAudience:"http://schema.org/EducationalAudience",EducationalOrganization:"http://schema.org/EducationalOrganization",Electrician:"http://schema.org/Electrician",ElectronicsStore:"http://schema.org/ElectronicsStore",ElementarySchool:"http://schema.org/ElementarySchool",EmailMessage:"http://schema.org/EmailMessage",Embassy:"http://schema.org/Embassy",EmergencyService:"http://schema.org/EmergencyService",EmployeeRole:"http://schema.org/EmployeeRole",EmployerAggregateRating:"http://schema.org/EmployerAggregateRating",EmploymentAgency:"http://schema.org/EmploymentAgency",EndorseAction:"http://schema.org/EndorseAction",EndorsementRating:"http://schema.org/EndorsementRating",Energy:"http://schema.org/Energy",EngineSpecification:"http://schema.org/EngineSpecification",EntertainmentBusiness:"http://schema.org/EntertainmentBusiness",EntryPoint:"http://schema.org/EntryPoint",Enumeration:"http://schema.org/Enumeration",Episode:"http://schema.org/Episode",Event:"http://schema.org/Event",EventReservation:"http://schema.org/EventReservation",EventStatusType:"http://schema.org/EventStatusType",EventVenue:"http://schema.org/EventVenue",ExerciseAction:"http://schema.org/ExerciseAction",ExerciseGym:"http://schema.org/ExerciseGym",ExhibitionEvent:"http://schema.org/ExhibitionEvent",FAQPage:"http://schema.org/FAQPage",FMRadioChannel:"http://schema.org/FMRadioChannel",FastFoodRestaurant:"http://schema.org/FastFoodRestaurant",Festival:"http://schema.org/Festival",FilmAction:"http://schema.org/FilmAction",FinancialProduct:"http://schema.org/FinancialProduct",FinancialService:"http://schema.org/FinancialService",FindAction:"http://schema.org/FindAction",FireStation:"http://schema.org/FireStation",Flight:"http://schema.org/Flight",FlightReservation:"http://schema.org/FlightReservation",Float:"http://schema.org/Float",Florist:"http://schema.org/Florist",FollowAction:"http://schema.org/FollowAction",FoodEstablishment:"http://schema.org/FoodEstablishment",FoodEstablishmentReservation:"http://schema.org/FoodEstablishmentReservation",FoodEvent:"http://schema.org/FoodEvent",FoodService:"http://schema.org/FoodService",FurnitureStore:"http://schema.org/FurnitureStore",Game:"http://schema.org/Game",GamePlayMode:"http://schema.org/GamePlayMode",GameServer:"http://schema.org/GameServer",GameServerStatus:"http://schema.org/GameServerStatus",GardenStore:"http://schema.org/GardenStore",GasStation:"http://schema.org/GasStation",GatedResidenceCommunity:"http://schema.org/GatedResidenceCommunity",GenderType:"http://schema.org/GenderType",GeneralContractor:"http://schema.org/GeneralContractor",GeoCircle:"http://schema.org/GeoCircle",GeoCoordinates:"http://schema.org/GeoCoordinates",GeoShape:"http://schema.org/GeoShape",GiveAction:"http://schema.org/GiveAction",GolfCourse:"http://schema.org/GolfCourse",GovernmentBuilding:"http://schema.org/GovernmentBuilding",GovernmentOffice:"http://schema.org/GovernmentOffice",GovernmentOrganization:"http://schema.org/GovernmentOrganization",GovernmentPermit:"http://schema.org/GovernmentPermit",GovernmentService:"http://schema.org/GovernmentService",GroceryStore:"http://schema.org/GroceryStore",HVACBusiness:"http://schema.org/HVACBusiness",HairSalon:"http://schema.org/HairSalon",HardwareStore:"http://schema.org/HardwareStore",HealthAndBeautyBusiness:"http://schema.org/HealthAndBeautyBusiness",HealthClub:"http://schema.org/HealthClub",HighSchool:"http://schema.org/HighSchool",HinduTemple:"http://schema.org/HinduTemple",HobbyShop:"http://schema.org/HobbyShop",HomeAndConstructionBusiness:"http://schema.org/HomeAndConstructionBusiness",HomeGoodsStore:"http://schema.org/HomeGoodsStore",Hospital:"http://schema.org/Hospital",Hostel:"http://schema.org/Hostel",Hotel:"http://schema.org/Hotel",HotelRoom:"http://schema.org/HotelRoom",House:"http://schema.org/House",HousePainter:"http://schema.org/HousePainter",HowTo:"http://schema.org/HowTo",HowToDirection:"http://schema.org/HowToDirection",HowToItem:"http://schema.org/HowToItem",HowToSection:"http://schema.org/HowToSection",HowToStep:"http://schema.org/HowToStep",HowToSupply:"http://schema.org/HowToSupply",HowToTip:"http://schema.org/HowToTip",HowToTool:"http://schema.org/HowToTool",IceCreamShop:"http://schema.org/IceCreamShop",IgnoreAction:"http://schema.org/IgnoreAction",ImageGallery:"http://schema.org/ImageGallery",ImageObject:"http://schema.org/ImageObject",IndividualProduct:"http://schema.org/IndividualProduct",InformAction:"http://schema.org/InformAction",InsertAction:"http://schema.org/InsertAction",InstallAction:"http://schema.org/InstallAction",InsuranceAgency:"http://schema.org/InsuranceAgency",Intangible:"http://schema.org/Intangible",Integer:"http://schema.org/Integer",InteractAction:"http://schema.org/InteractAction",InteractionCounter:"http://schema.org/InteractionCounter",InternetCafe:"http://schema.org/InternetCafe",InvestmentOrDeposit:"http://schema.org/InvestmentOrDeposit",InviteAction:"http://schema.org/InviteAction",Invoice:"http://schema.org/Invoice",ItemAvailability:"http://schema.org/ItemAvailability",ItemList:"http://schema.org/ItemList",ItemListOrderType:"http://schema.org/ItemListOrderType",ItemPage:"http://schema.org/ItemPage",JewelryStore:"http://schema.org/JewelryStore",JobPosting:"http://schema.org/JobPosting",JoinAction:"http://schema.org/JoinAction",LakeBodyOfWater:"http://schema.org/LakeBodyOfWater",Landform:"http://schema.org/Landform",LandmarksOrHistoricalBuildings:"http://schema.org/LandmarksOrHistoricalBuildings",Language:"http://schema.org/Language",LeaveAction:"http://schema.org/LeaveAction",LegalService:"http://schema.org/LegalService",LegislativeBuilding:"http://schema.org/LegislativeBuilding",LendAction:"http://schema.org/LendAction",Library:"http://schema.org/Library",LikeAction:"http://schema.org/LikeAction",LiquorStore:"http://schema.org/LiquorStore",ListItem:"http://schema.org/ListItem",ListenAction:"http://schema.org/ListenAction",LiteraryEvent:"http://schema.org/LiteraryEvent",LiveBlogPosting:"http://schema.org/LiveBlogPosting",LoanOrCredit:"http://schema.org/LoanOrCredit",LocalBusiness:"http://schema.org/LocalBusiness",LocationFeatureSpecification:"http://schema.org/LocationFeatureSpecification",LockerDelivery:"http://schema.org/LockerDelivery",Locksmith:"http://schema.org/Locksmith",LodgingBusiness:"http://schema.org/LodgingBusiness",LodgingReservation:"http://schema.org/LodgingReservation",LoseAction:"http://schema.org/LoseAction",Map__workaround:"http://schema.org/Map",MapCategoryType:"http://schema.org/MapCategoryType",MarryAction:"http://schema.org/MarryAction",Mass:"http://schema.org/Mass",MediaObject:"http://schema.org/MediaObject",MediaSubscription:"http://schema.org/MediaSubscription",MedicalOrganization:"http://schema.org/MedicalOrganization",MeetingRoom:"http://schema.org/MeetingRoom",MensClothingStore:"http://schema.org/MensClothingStore",Menu:"http://schema.org/Menu",MenuItem:"http://schema.org/MenuItem",MenuSection:"http://schema.org/MenuSection",Message:"http://schema.org/Message",MiddleSchool:"http://schema.org/MiddleSchool",MobileApplication:"http://schema.org/MobileApplication",MobilePhoneStore:"http://schema.org/MobilePhoneStore",MonetaryAmount:"http://schema.org/MonetaryAmount",MonetaryAmountDistribution:"http://schema.org/MonetaryAmountDistribution",Mosque:"http://schema.org/Mosque",Motel:"http://schema.org/Motel",MotorcycleDealer:"http://schema.org/MotorcycleDealer",MotorcycleRepair:"http://schema.org/MotorcycleRepair",Mountain:"http://schema.org/Mountain",MoveAction:"http://schema.org/MoveAction",Movie:"http://schema.org/Movie",MovieClip:"http://schema.org/MovieClip",MovieRentalStore:"http://schema.org/MovieRentalStore",MovieSeries:"http://schema.org/MovieSeries",MovieTheater:"http://schema.org/MovieTheater",MovingCompany:"http://schema.org/MovingCompany",Museum:"http://schema.org/Museum",MusicAlbum:"http://schema.org/MusicAlbum",MusicAlbumProductionType:"http://schema.org/MusicAlbumProductionType",MusicAlbumReleaseType:"http://schema.org/MusicAlbumReleaseType",MusicComposition:"http://schema.org/MusicComposition",MusicEvent:"http://schema.org/MusicEvent",MusicGroup:"http://schema.org/MusicGroup",MusicPlaylist:"http://schema.org/MusicPlaylist",MusicRecording:"http://schema.org/MusicRecording",MusicRelease:"http://schema.org/MusicRelease",MusicReleaseFormatType:"http://schema.org/MusicReleaseFormatType",MusicStore:"http://schema.org/MusicStore",MusicVenue:"http://schema.org/MusicVenue",MusicVideoObject:"http://schema.org/MusicVideoObject",NGO:"http://schema.org/NGO",NailSalon:"http://schema.org/NailSalon",NewsArticle:"http://schema.org/NewsArticle",NightClub:"http://schema.org/NightClub",Notary:"http://schema.org/Notary",NoteDigitalDocument:"http://schema.org/NoteDigitalDocument",Number__workaround:"http://schema.org/Number",NutritionInformation:"http://schema.org/NutritionInformation",Occupation:"http://schema.org/Occupation",OceanBodyOfWater:"http://schema.org/OceanBodyOfWater",Offer:"http://schema.org/Offer",OfferCatalog:"http://schema.org/OfferCatalog",OfferItemCondition:"http://schema.org/OfferItemCondition",OfficeEquipmentStore:"http://schema.org/OfficeEquipmentStore",OnDemandEvent:"http://schema.org/OnDemandEvent",OpeningHoursSpecification:"http://schema.org/OpeningHoursSpecification",Order:"http://schema.org/Order",OrderAction:"http://schema.org/OrderAction",OrderItem:"http://schema.org/OrderItem",OrderStatus:"http://schema.org/OrderStatus",Organization:"http://schema.org/Organization",OrganizationRole:"http://schema.org/OrganizationRole",OrganizeAction:"http://schema.org/OrganizeAction",OutletStore:"http://schema.org/OutletStore",OwnershipInfo:"http://schema.org/OwnershipInfo",PaintAction:"http://schema.org/PaintAction",Painting:"http://schema.org/Painting",ParcelDelivery:"http://schema.org/ParcelDelivery",ParcelService:"http://schema.org/ParcelService",ParentAudience:"http://schema.org/ParentAudience",Park:"http://schema.org/Park",ParkingFacility:"http://schema.org/ParkingFacility",PawnShop:"http://schema.org/PawnShop",PayAction:"http://schema.org/PayAction",PaymentCard:"http://schema.org/PaymentCard",PaymentChargeSpecification:"http://schema.org/PaymentChargeSpecification",PaymentMethod:"http://schema.org/PaymentMethod",PaymentService:"http://schema.org/PaymentService",PaymentStatusType:"http://schema.org/PaymentStatusType",PeopleAudience:"http://schema.org/PeopleAudience",PerformAction:"http://schema.org/PerformAction",PerformanceRole:"http://schema.org/PerformanceRole",PerformingArtsTheater:"http://schema.org/PerformingArtsTheater",PerformingGroup:"http://schema.org/PerformingGroup",Periodical:"http://schema.org/Periodical",Permit:"http://schema.org/Permit",Person:"http://schema.org/Person",PetStore:"http://schema.org/PetStore",Pharmacy:"http://schema.org/Pharmacy",Photograph:"http://schema.org/Photograph",PhotographAction:"http://schema.org/PhotographAction",Physician:"http://schema.org/Physician",Place:"http://schema.org/Place",PlaceOfWorship:"http://schema.org/PlaceOfWorship",PlanAction:"http://schema.org/PlanAction",PlayAction:"http://schema.org/PlayAction",Playground:"http://schema.org/Playground",Plumber:"http://schema.org/Plumber",PoliceStation:"http://schema.org/PoliceStation",Pond:"http://schema.org/Pond",PostOffice:"http://schema.org/PostOffice",PostalAddress:"http://schema.org/PostalAddress",PreOrderAction:"http://schema.org/PreOrderAction",PrependAction:"http://schema.org/PrependAction",Preschool:"http://schema.org/Preschool",PresentationDigitalDocument:"http://schema.org/PresentationDigitalDocument",PriceSpecification:"http://schema.org/PriceSpecification",Product:"http://schema.org/Product",ProductModel:"http://schema.org/ProductModel",ProfessionalService:"http://schema.org/ProfessionalService",ProfilePage:"http://schema.org/ProfilePage",ProgramMembership:"http://schema.org/ProgramMembership",PropertyValue:"http://schema.org/PropertyValue",PropertyValueSpecification:"http://schema.org/PropertyValueSpecification",PublicSwimmingPool:"http://schema.org/PublicSwimmingPool",PublicationEvent:"http://schema.org/PublicationEvent",PublicationIssue:"http://schema.org/PublicationIssue",PublicationVolume:"http://schema.org/PublicationVolume",QAPage:"http://schema.org/QAPage",QualitativeValue:"http://schema.org/QualitativeValue",QuantitativeValue:"http://schema.org/QuantitativeValue",QuantitativeValueDistribution:"http://schema.org/QuantitativeValueDistribution",Quantity:"http://schema.org/Quantity",Question:"http://schema.org/Question",QuoteAction:"http://schema.org/QuoteAction",RVPark:"http://schema.org/RVPark",RadioChannel:"http://schema.org/RadioChannel",RadioClip:"http://schema.org/RadioClip",RadioEpisode:"http://schema.org/RadioEpisode",RadioSeason:"http://schema.org/RadioSeason",RadioSeries:"http://schema.org/RadioSeries",RadioStation:"http://schema.org/RadioStation",Rating:"http://schema.org/Rating",ReactAction:"http://schema.org/ReactAction",ReadAction:"http://schema.org/ReadAction",RealEstateAgent:"http://schema.org/RealEstateAgent",ReceiveAction:"http://schema.org/ReceiveAction",Recipe:"http://schema.org/Recipe",RecyclingCenter:"http://schema.org/RecyclingCenter",RegisterAction:"http://schema.org/RegisterAction",RejectAction:"http://schema.org/RejectAction",RentAction:"http://schema.org/RentAction",RentalCarReservation:"http://schema.org/RentalCarReservation",ReplaceAction:"http://schema.org/ReplaceAction",ReplyAction:"http://schema.org/ReplyAction",Report:"http://schema.org/Report",Reservation:"http://schema.org/Reservation",ReservationPackage:"http://schema.org/ReservationPackage",ReservationStatusType:"http://schema.org/ReservationStatusType",ReserveAction:"http://schema.org/ReserveAction",Reservoir:"http://schema.org/Reservoir",Residence:"http://schema.org/Residence",Resort:"http://schema.org/Resort",Restaurant:"http://schema.org/Restaurant",RestrictedDiet:"http://schema.org/RestrictedDiet",ResumeAction:"http://schema.org/ResumeAction",ReturnAction:"http://schema.org/ReturnAction",Review:"http://schema.org/Review",ReviewAction:"http://schema.org/ReviewAction",RiverBodyOfWater:"http://schema.org/RiverBodyOfWater",Role:"http://schema.org/Role",RoofingContractor:"http://schema.org/RoofingContractor",Room:"http://schema.org/Room",RsvpAction:"http://schema.org/RsvpAction",RsvpResponseType:"http://schema.org/RsvpResponseType",SaleEvent:"http://schema.org/SaleEvent",ScheduleAction:"http://schema.org/ScheduleAction",ScholarlyArticle:"http://schema.org/ScholarlyArticle",School:"http://schema.org/School",ScreeningEvent:"http://schema.org/ScreeningEvent",Sculpture:"http://schema.org/Sculpture",SeaBodyOfWater:"http://schema.org/SeaBodyOfWater",SearchAction:"http://schema.org/SearchAction",SearchResultsPage:"http://schema.org/SearchResultsPage",Season:"http://schema.org/Season",Seat:"http://schema.org/Seat",SelfStorage:"http://schema.org/SelfStorage",SellAction:"http://schema.org/SellAction",SendAction:"http://schema.org/SendAction",Series:"http://schema.org/Series",Service:"http://schema.org/Service",ServiceChannel:"http://schema.org/ServiceChannel",ShareAction:"http://schema.org/ShareAction",ShoeStore:"http://schema.org/ShoeStore",ShoppingCenter:"http://schema.org/ShoppingCenter",SingleFamilyResidence:"http://schema.org/SingleFamilyResidence",SiteNavigationElement:"http://schema.org/SiteNavigationElement",SkiResort:"http://schema.org/SkiResort",SocialEvent:"http://schema.org/SocialEvent",SocialMediaPosting:"http://schema.org/SocialMediaPosting",SoftwareApplication:"http://schema.org/SoftwareApplication",SoftwareSourceCode:"http://schema.org/SoftwareSourceCode",SomeProducts:"http://schema.org/SomeProducts",SpeakableSpecification:"http://schema.org/SpeakableSpecification",Specialty:"http://schema.org/Specialty",SportingGoodsStore:"http://schema.org/SportingGoodsStore",SportsActivityLocation:"http://schema.org/SportsActivityLocation",SportsClub:"http://schema.org/SportsClub",SportsEvent:"http://schema.org/SportsEvent",SportsOrganization:"http://schema.org/SportsOrganization",SportsTeam:"http://schema.org/SportsTeam",SpreadsheetDigitalDocument:"http://schema.org/SpreadsheetDigitalDocument",StadiumOrArena:"http://schema.org/StadiumOrArena",State:"http://schema.org/State",SteeringPositionValue:"http://schema.org/SteeringPositionValue",Store:"http://schema.org/Store",StructuredValue:"http://schema.org/StructuredValue",SubscribeAction:"http://schema.org/SubscribeAction",SubwayStation:"http://schema.org/SubwayStation",Suite:"http://schema.org/Suite",SuspendAction:"http://schema.org/SuspendAction",Synagogue:"http://schema.org/Synagogue",TVClip:"http://schema.org/TVClip",TVEpisode:"http://schema.org/TVEpisode",TVSeason:"http://schema.org/TVSeason",TVSeries:"http://schema.org/TVSeries",Table:"http://schema.org/Table",TakeAction:"http://schema.org/TakeAction",TattooParlor:"http://schema.org/TattooParlor",Taxi:"http://schema.org/Taxi",TaxiReservation:"http://schema.org/TaxiReservation",TaxiService:"http://schema.org/TaxiService",TaxiStand:"http://schema.org/TaxiStand",TechArticle:"http://schema.org/TechArticle",TelevisionChannel:"http://schema.org/TelevisionChannel",TelevisionStation:"http://schema.org/TelevisionStation",TennisComplex:"http://schema.org/TennisComplex",Text:"http://schema.org/Text",TextDigitalDocument:"http://schema.org/TextDigitalDocument",TheaterEvent:"http://schema.org/TheaterEvent",TheaterGroup:"http://schema.org/TheaterGroup",Thing:"http://schema.org/Thing",Ticket:"http://schema.org/Ticket",TieAction:"http://schema.org/TieAction",Time:"http://schema.org/Time",TipAction:"http://schema.org/TipAction",TireShop:"http://schema.org/TireShop",TouristAttraction:"http://schema.org/TouristAttraction",TouristInformationCenter:"http://schema.org/TouristInformationCenter",ToyStore:"http://schema.org/ToyStore",TrackAction:"http://schema.org/TrackAction",TradeAction:"http://schema.org/TradeAction",TrainReservation:"http://schema.org/TrainReservation",TrainStation:"http://schema.org/TrainStation",TrainTrip:"http://schema.org/TrainTrip",TransferAction:"http://schema.org/TransferAction",TravelAction:"http://schema.org/TravelAction",TravelAgency:"http://schema.org/TravelAgency",Trip:"http://schema.org/Trip",TypeAndQuantityNode:"http://schema.org/TypeAndQuantityNode",URL:"http://schema.org/URL",UnRegisterAction:"http://schema.org/UnRegisterAction",UnitPriceSpecification:"http://schema.org/UnitPriceSpecification",UpdateAction:"http://schema.org/UpdateAction",UseAction:"http://schema.org/UseAction",UserBlocks:"http://schema.org/UserBlocks",UserCheckins:"http://schema.org/UserCheckins",UserComments:"http://schema.org/UserComments",UserDownloads:"http://schema.org/UserDownloads",UserInteraction:"http://schema.org/UserInteraction",UserLikes:"http://schema.org/UserLikes",UserPageVisits:"http://schema.org/UserPageVisits",UserPlays:"http://schema.org/UserPlays",UserPlusOnes:"http://schema.org/UserPlusOnes",UserTweets:"http://schema.org/UserTweets",Vehicle:"http://schema.org/Vehicle",VideoGallery:"http://schema.org/VideoGallery",VideoGame:"http://schema.org/VideoGame",VideoGameClip:"http://schema.org/VideoGameClip",VideoGameSeries:"http://schema.org/VideoGameSeries",VideoObject:"http://schema.org/VideoObject",ViewAction:"http://schema.org/ViewAction",VisualArtsEvent:"http://schema.org/VisualArtsEvent",VisualArtwork:"http://schema.org/VisualArtwork",Volcano:"http://schema.org/Volcano",VoteAction:"http://schema.org/VoteAction",WPAdBlock:"http://schema.org/WPAdBlock",WPFooter:"http://schema.org/WPFooter",WPHeader:"http://schema.org/WPHeader",WPSideBar:"http://schema.org/WPSideBar",WantAction:"http://schema.org/WantAction",WarrantyPromise:"http://schema.org/WarrantyPromise",WarrantyScope:"http://schema.org/WarrantyScope",WatchAction:"http://schema.org/WatchAction",Waterfall:"http://schema.org/Waterfall",WearAction:"http://schema.org/WearAction",WebApplication:"http://schema.org/WebApplication",WebPage:"http://schema.org/WebPage",WebPageElement:"http://schema.org/WebPageElement",WebSite:"http://schema.org/WebSite",WholesaleStore:"http://schema.org/WholesaleStore",WinAction:"http://schema.org/WinAction",Winery:"http://schema.org/Winery",WorkersUnion:"http://schema.org/WorkersUnion",WriteAction:"http://schema.org/WriteAction",Zoo:"http://schema.org/Zoo"}),Xe=Object.freeze({account:"http://www.w3.org/ns/solid/terms#account",deletes:"http://www.w3.org/ns/solid/terms#deletes",forClass:"http://www.w3.org/ns/solid/terms#forClass",inbox:"http://www.w3.org/ns/solid/terms#inbox",inserts:"http://www.w3.org/ns/solid/terms#inserts",instance:"http://www.w3.org/ns/solid/terms#instance",instanceContainer:"http://www.w3.org/ns/solid/terms#instanceContainer",loginEndpoint:"http://www.w3.org/ns/solid/terms#loginEndpoint",logoutEndpoint:"http://www.w3.org/ns/solid/terms#logoutEndpoint",notification:"http://www.w3.org/ns/solid/terms#notification",privateTypeIndex:"http://www.w3.org/ns/solid/terms#privateTypeIndex",publicTypeIndex:"http://www.w3.org/ns/solid/terms#publicTypeIndex",read:"http://www.w3.org/ns/solid/terms#read",typeIndex:"http://www.w3.org/ns/solid/terms#typeIndex",oidcIssuer:"http://www.w3.org/ns/solid/terms#oidcIssuer",patches:"http://www.w3.org/ns/solid/terms#patches",timeline:"http://www.w3.org/ns/solid/terms#timeline",where:"http://www.w3.org/ns/solid/terms#where",storageQuota:"http://www.w3.org/ns/solid/terms#storageQuota",storageUsage:"http://www.w3.org/ns/solid/terms#storageUsage",Account:"http://www.w3.org/ns/solid/terms#Account",Inbox:"http://www.w3.org/ns/solid/terms#Inbox",ListedDocument:"http://www.w3.org/ns/solid/terms#ListedDocument",Notification:"http://www.w3.org/ns/solid/terms#Notification",Patch:"http://www.w3.org/ns/solid/terms#Patch",Timeline:"http://www.w3.org/ns/solid/terms#Timeline",TypeIndex:"http://www.w3.org/ns/solid/terms#TypeIndex",TypeRegistration:"http://www.w3.org/ns/solid/terms#TypeRegistration",UnlistedDocument:"http://www.w3.org/ns/solid/terms#UnlistedDocument"}),et=Object.freeze({masterWorkspace:"http://www.w3.org/ns/pim/space#masterWorkspace",preferencesFile:"http://www.w3.org/ns/pim/space#preferencesFile",storage:"http://www.w3.org/ns/pim/space#storage",uriPrefix:"http://www.w3.org/ns/pim/space#uriPrefix",workspace:"http://www.w3.org/ns/pim/space#workspace",ControlledStorage:"http://www.w3.org/ns/pim/space#ControlledStorage",PersonalStorage:"http://www.w3.org/ns/pim/space#PersonalStorage",PublicStorage:"http://www.w3.org/ns/pim/space#PublicStorage",Storage:"http://www.w3.org/ns/pim/space#Storage",Workspace:"http://www.w3.org/ns/pim/space#Workspace"}),tt=Object.freeze({Acquaintance:"http://www.w3.org/2006/vcard/ns#Acquaintance",Agent:"http://www.w3.org/2006/vcard/ns#Agent",BBS:"http://www.w3.org/2006/vcard/ns#BBS",Car:"http://www.w3.org/2006/vcard/ns#Car",Cell:"http://www.w3.org/2006/vcard/ns#Cell",Child:"http://www.w3.org/2006/vcard/ns#Child",Colleague:"http://www.w3.org/2006/vcard/ns#Colleague",Contact:"http://www.w3.org/2006/vcard/ns#Contact",Coresident:"http://www.w3.org/2006/vcard/ns#Coresident",Coworker:"http://www.w3.org/2006/vcard/ns#Coworker",Crush:"http://www.w3.org/2006/vcard/ns#Crush",Date__workaround:"http://www.w3.org/2006/vcard/ns#Date",Dom:"http://www.w3.org/2006/vcard/ns#Dom",Emergency:"http://www.w3.org/2006/vcard/ns#Emergency",Fax:"http://www.w3.org/2006/vcard/ns#Fax",Female:"http://www.w3.org/2006/vcard/ns#Female",Friend:"http://www.w3.org/2006/vcard/ns#Friend",Home:"http://www.w3.org/2006/vcard/ns#Home",ISDN:"http://www.w3.org/2006/vcard/ns#ISDN",Internet:"http://www.w3.org/2006/vcard/ns#Internet",Intl__workaround:"http://www.w3.org/2006/vcard/ns#Intl",Kin:"http://www.w3.org/2006/vcard/ns#Kin",Label:"http://www.w3.org/2006/vcard/ns#Label",Male:"http://www.w3.org/2006/vcard/ns#Male",Me:"http://www.w3.org/2006/vcard/ns#Me",Met:"http://www.w3.org/2006/vcard/ns#Met",Modem:"http://www.w3.org/2006/vcard/ns#Modem",Msg:"http://www.w3.org/2006/vcard/ns#Msg",Muse:"http://www.w3.org/2006/vcard/ns#Muse",Neighbor:"http://www.w3.org/2006/vcard/ns#Neighbor",None:"http://www.w3.org/2006/vcard/ns#None",Other:"http://www.w3.org/2006/vcard/ns#Other",PCS:"http://www.w3.org/2006/vcard/ns#PCS",Pager:"http://www.w3.org/2006/vcard/ns#Pager",Parcel:"http://www.w3.org/2006/vcard/ns#Parcel",Parent:"http://www.w3.org/2006/vcard/ns#Parent",Postal:"http://www.w3.org/2006/vcard/ns#Postal",Pref:"http://www.w3.org/2006/vcard/ns#Pref",Sibling:"http://www.w3.org/2006/vcard/ns#Sibling",Spouse:"http://www.w3.org/2006/vcard/ns#Spouse",Sweetheart:"http://www.w3.org/2006/vcard/ns#Sweetheart",Tel:"http://www.w3.org/2006/vcard/ns#Tel",Text:"http://www.w3.org/2006/vcard/ns#Text",TextPhone:"http://www.w3.org/2006/vcard/ns#TextPhone",Unknown:"http://www.w3.org/2006/vcard/ns#Unknown",Video:"http://www.w3.org/2006/vcard/ns#Video",Voice:"http://www.w3.org/2006/vcard/ns#Voice",Work:"http://www.w3.org/2006/vcard/ns#Work",X400:"http://www.w3.org/2006/vcard/ns#X400",Address:"http://www.w3.org/2006/vcard/ns#Address",Email:"http://www.w3.org/2006/vcard/ns#Email",Group:"http://www.w3.org/2006/vcard/ns#Group",Individual:"http://www.w3.org/2006/vcard/ns#Individual",Name:"http://www.w3.org/2006/vcard/ns#Name",VCard:"http://www.w3.org/2006/vcard/ns#VCard",Location:"http://www.w3.org/2006/vcard/ns#Location",Organization:"http://www.w3.org/2006/vcard/ns#Organization",Gender:"http://www.w3.org/2006/vcard/ns#Gender",Kind:"http://www.w3.org/2006/vcard/ns#Kind",Type:"http://www.w3.org/2006/vcard/ns#Type",TelephoneType:"http://www.w3.org/2006/vcard/ns#TelephoneType",RelatedType:"http://www.w3.org/2006/vcard/ns#RelatedType",adr:"http://www.w3.org/2006/vcard/ns#adr",agent:"http://www.w3.org/2006/vcard/ns#agent",email:"http://www.w3.org/2006/vcard/ns#email",geo:"http://www.w3.org/2006/vcard/ns#geo",hasAdditionalName:"http://www.w3.org/2006/vcard/ns#hasAdditionalName",hasCalendarBusy:"http://www.w3.org/2006/vcard/ns#hasCalendarBusy",hasCalendarLink:"http://www.w3.org/2006/vcard/ns#hasCalendarLink",hasCalendarRequest:"http://www.w3.org/2006/vcard/ns#hasCalendarRequest",hasCategory:"http://www.w3.org/2006/vcard/ns#hasCategory",hasCountryName:"http://www.w3.org/2006/vcard/ns#hasCountryName",hasFN:"http://www.w3.org/2006/vcard/ns#hasFN",hasFamilyName:"http://www.w3.org/2006/vcard/ns#hasFamilyName",hasGender:"http://www.w3.org/2006/vcard/ns#hasGender",hasGivenName:"http://www.w3.org/2006/vcard/ns#hasGivenName",hasHonorificPrefix:"http://www.w3.org/2006/vcard/ns#hasHonorificPrefix",hasHonorificSuffix:"http://www.w3.org/2006/vcard/ns#hasHonorificSuffix",hasInstantMessage:"http://www.w3.org/2006/vcard/ns#hasInstantMessage",hasLanguage:"http://www.w3.org/2006/vcard/ns#hasLanguage",hasLocality:"http://www.w3.org/2006/vcard/ns#hasLocality",hasNickname:"http://www.w3.org/2006/vcard/ns#hasNickname",hasNote:"http://www.w3.org/2006/vcard/ns#hasNote",hasOrganizationName:"http://www.w3.org/2006/vcard/ns#hasOrganizationName",hasOrganizationUnit:"http://www.w3.org/2006/vcard/ns#hasOrganizationUnit",hasPostalCode:"http://www.w3.org/2006/vcard/ns#hasPostalCode",hasRegion:"http://www.w3.org/2006/vcard/ns#hasRegion",hasRelated:"http://www.w3.org/2006/vcard/ns#hasRelated",hasRole:"http://www.w3.org/2006/vcard/ns#hasRole",hasSource:"http://www.w3.org/2006/vcard/ns#hasSource",hasStreetAddress:"http://www.w3.org/2006/vcard/ns#hasStreetAddress",hasTitle:"http://www.w3.org/2006/vcard/ns#hasTitle",hasUID:"http://www.w3.org/2006/vcard/ns#hasUID",hasValue:"http://www.w3.org/2006/vcard/ns#hasValue",org:"http://www.w3.org/2006/vcard/ns#org",hasAddress:"http://www.w3.org/2006/vcard/ns#hasAddress",hasEmail:"http://www.w3.org/2006/vcard/ns#hasEmail",hasGeo:"http://www.w3.org/2006/vcard/ns#hasGeo",hasKey:"http://www.w3.org/2006/vcard/ns#hasKey",hasLogo:"http://www.w3.org/2006/vcard/ns#hasLogo",hasName:"http://www.w3.org/2006/vcard/ns#hasName",hasPhoto:"http://www.w3.org/2006/vcard/ns#hasPhoto",hasSound:"http://www.w3.org/2006/vcard/ns#hasSound",hasTelephone:"http://www.w3.org/2006/vcard/ns#hasTelephone",hasURL:"http://www.w3.org/2006/vcard/ns#hasURL",key:"http://www.w3.org/2006/vcard/ns#key",logo:"http://www.w3.org/2006/vcard/ns#logo",n:"http://www.w3.org/2006/vcard/ns#n",photo:"http://www.w3.org/2006/vcard/ns#photo",sound:"http://www.w3.org/2006/vcard/ns#sound",tel:"http://www.w3.org/2006/vcard/ns#tel",url:"http://www.w3.org/2006/vcard/ns#url",hasMember:"http://www.w3.org/2006/vcard/ns#hasMember",anniversary:"http://www.w3.org/2006/vcard/ns#anniversary",bday:"http://www.w3.org/2006/vcard/ns#bday",category:"http://www.w3.org/2006/vcard/ns#category",class__workaround:"http://www.w3.org/2006/vcard/ns#class",label:"http://www.w3.org/2006/vcard/ns#label",language:"http://www.w3.org/2006/vcard/ns#language",latitude:"http://www.w3.org/2006/vcard/ns#latitude",longitude:"http://www.w3.org/2006/vcard/ns#longitude",mailer:"http://www.w3.org/2006/vcard/ns#mailer",note:"http://www.w3.org/2006/vcard/ns#note",prodid:"http://www.w3.org/2006/vcard/ns#prodid",rev:"http://www.w3.org/2006/vcard/ns#rev",role:"http://www.w3.org/2006/vcard/ns#role",title:"http://www.w3.org/2006/vcard/ns#title",tz:"http://www.w3.org/2006/vcard/ns#tz",value:"http://www.w3.org/2006/vcard/ns#value",fn:"http://www.w3.org/2006/vcard/ns#fn",nickname:"http://www.w3.org/2006/vcard/ns#nickname",locality:"http://www.w3.org/2006/vcard/ns#locality",region:"http://www.w3.org/2006/vcard/ns#region"}),rt=(r(825),r(780)),nt=r(885),ot=r(300),it=r.n(ot),at="https://chang.inrupt.net/registerlist/requestlist.ttl",st="http://schema.org/title",ct="http://www.w3.org/ns/dpv#hasPurpose",ht="http://www.w3.org/2000/01/rdf-schema#label",ut="http://www.w3.org/ns/dpv#hasPersonalDataCategory",lt="http://schema.org/DataFeedItem",pt="http://www.w3.org/ns/dpv#hasExpiryTime",dt="http://schema.org/collectionSize",ft="http://www.w3.org/ns/dpv#hasProcessing",gt="http://www.w3.org/ns/dpv#hasAlgorithmicLogic",mt="http://www.w3.org/ns/dpv#hasConsequences",yt="http://www.w3.org/ns/dpv#hasDataController",wt="http://www.w3.org/ns/dpv#PersonalDataHandling",bt="http://www.w3.org/ns/dpv#participation";const vt=document.querySelectorAll(".listen.button"),_t=document.querySelectorAll(".login.button");document.querySelectorAll(".link");var St=window.location.pathname.split("/").pop();async function At(){let e=await t().currentSession();if(e)return e.webId;{const e=await new Promise(((e,t)=>{vt.forEach((function(t){t.addEventListener("click",(function(t){t.preventDefault();const r=t.currentTarget.classList;r.contains("inrupt")?(e("https://inrupt.net"),console.log("Login Inrupt")):r.contains("solidcommunity")&&(e("https://solidcommunity.net"),console.log("Login Solid Community"))}))}))}));t().login(e)}}async function Et(e,t,r,n){try{await Be(e)}catch(e){alert(e.message)}finally{const o=await Be(e);if(n)return o.getTriples();{const e=o.getSubject(t);return r?e.getAllLiterals(r).concat(e.getAllRefs(r)):e.getTriples()}}}function xt(e,t,r){let n=Object.keys(t[0]);if(!r)for(;e.hasChildNodes();)e.removeChild(e.firstChild);e.hasChildNodes()||function(e,t){let r=e.createTHead().insertRow();for(let e of t){let t=document.createElement("th"),n=document.createTextNode(e);t.appendChild(n),r.appendChild(t)}}(e,n),function(e,t){for(let r of t){let t=e.insertRow();for(let e in r){let n=t.insertCell(),o=r[e],i=/"(.*?)"/g,a=o.match(i);if(a){let e=a.map((e=>e.replace(/"/g,""))),t=document.createTextNode(e);n.appendChild(t)}else{let e=document.createElement("a");if(o.includes("#")){const t=document.createTextNode(o.toString().split("#")[1]);e.appendChild(t)}else{let t=o.split("/");const r=document.createTextNode(t[t.length-2]+":"+t[t.length-1]);e.appendChild(r)}e.href=o,n.appendChild(e)}}}}(e,t)}async function Rt(e){const t=(await Be(e)).getSubject(e),r=t.getRef(Xe.publicTypeIndex),n=await Be(r),o=n.findSubjects(Xe.forClass,wt);if(o.length>0)for(let t=0;t "+r+"public/request.ttl",n}(t,n).then((()=>{alert("New file 'public/request.ttl'is created!")}))}async function Ct(e){return await Be(e)}function Tt(e){return{14089001:" - Red blood cell count",184099003:" - Date of birth",224209007:" - Residence and accommodation circumstances",266995e3:" - History of cardiovascular disease",271649006:" - Systolic blood pressure",414798009:" - N-terminal pro-B-type natriuretic peptide",439401001:" - Diagnosis",67079006:" - Glucose",75672003:" - Platelet mean volume determination",398192003:" - Co-morbid conditions",182833002:" - Medication given",401207004:" - Medication side effects present",92818009:" - Chronic myeloid leukemia",22232009:" - Hospital",263495e3:" - Gender",D007182:" - Income",D007341:" - Insurance",118598001:" - Property",224164009:" - Financial circumstances",252150008:" - Lipid elements",38082009:" - Hemoglobin",56564003:" - Protein BCR-ABL",6684200:" - Red cell distribution width",14679004:" - Occupation",397669002:" - Age",409073007:" - Education",703503e3:" - Name"}[e]}function Ot(e,t,r){let n=Object(),o=[],i=[],a=[],s=[];for(let c=0;c{(async function(e){const t=e.findSubjects(),r=[],n=[],o=[],i=[];for(let e=0;e{const r=e[0],n=e[1],o=e[2];t().currentSession().then((e=>{e.webId.split("profile/card#")[0],async function(e,t,r,n,o,i,a){var s=[];for(let n=0;nOpen requests";var i=document.getElementById("ApprovedContainer");i.innerHTML="Approved requests";var a=document.getElementById("DeclinedContainer");a.innerHTML="Declined requests";const s=document.createElement("div");s.className="ui fluid fixed cards",s.id="open_cardsContainer",document.getElementById("OpenContainer").appendChild(s);const c=document.createElement("div");c.className="ui fluid fixed cards",c.id="approved_cardsContainer",document.getElementById("ApprovedContainer").appendChild(c);const h=document.createElement("div");h.className="ui fluid fixed cards",h.id="declined_cardsContainer",document.getElementById("DeclinedContainer").appendChild(h);let u={CommercialResearch:"orange",ResearchAndDevelopment:"blue",Security:"green",RegistrationAuthentication:"yellow",CreatePersonalizedRecommendations:"teal",ServiceProvision:"red",LegalObligation:"purple"},l=!1,p=!1,d=!1;for(var f=0;f3&&2==e){const e=document.createElement("div");e.textContent="... ... "+(R.length-3).toString()+" more personal data categories",document.getElementById("extra_windowContent"+f.toString()).appendChild(e)}}let O=document.createElement("h5");O.className="header",O.textContent="Data Processing Category: ",document.getElementById("extra_windowContent"+f.toString()).appendChild(O);const P=e[f].dataProcessingCategory.split(",");let I=document.createElement("div"),k=document.createTextNode(" - "+P[0].toString().split(": ")[1].split("#")[1].replace(/([A-Z][a-z])/g," $1").trim());I.appendChild(k),document.getElementById("extra_windowContent"+f.toString()).appendChild(I);for(let e=1;e<3;e++){if(e3&&2==e){const e=document.createElement("div");e.textContent="... ... "+(P.length-3).toString()+" more elements",document.getElementById("extra_windowContent"+f.toString()).appendChild(e)}}let j=document.createElement("h5");j.className="header",j.textContent="Requested data: ",document.getElementById("extra_windowContent"+f.toString()).appendChild(j);const D=e[f].dataElement.split(",");if(console.log(D.length),D.length<=30)for(let e=1;e30){for(let e=1;eYou have no open requests":0==p?i.innerHTML="You have no approved requests":0==d&&(a.innerHTML="You have no declined requests"),e}(s),document.getElementById("loader").style.display="none";return[document.querySelectorAll(".answer.button"),s]}(n,o,r).then((e=>{var t,r;t=e[0],r=e[1],t.forEach((function(e){e.addEventListener("click",(function(e){e.preventDefault();const t=e.currentTarget.classList,n=t.value.split(" ").pop().split("_")[1],o=r[n];if(t.contains("approve")){const e=o.url;Ct(e).then((t=>{Pt(t,e,"http://www.w3.org/ns/dpv#consented").then((()=>{alert("You have accepted the request!")||window.location.reload()}))}))}else if(t.contains("deny")){const e=o.url;Ct(e).then((t=>{Pt(t,e,"http://www.w3.org/ns/dpv#declined").then((()=>{alert("You have declined the request!")||window.location.reload()}))}))}else if(t.contains("cancel")){const e=o.url;Ct(e).then((t=>{Pt(t,e,"http://www.w3.org/ns/dpv#open").then((()=>{alert("You have withdrawed the decision!")||window.location.reload()}))}))}}))}))}))}))})).catch((e=>console.log(e)))})):"cmlfetch.html"===St&&Et("https://janjansen.solidcommunity.net/private/healthrecordforpatient.ttl","https://janjansen.solidcommunity.net/profile/card#me","http://xmlns.com/foaf/0.1/name",!0).then((e=>{const t=document.querySelectorAll(".table");let r=[];for(let t=0;t{const r=document.getElementById("homeMessage");if(e){let e=window.location.pathname.toString().split("dist/");"cmlconsent.html"===e[1]&&(window.location.href=e[0]+"dist/cmlparticipate.html"),r&&(r.textContent="Welcome! Jan Janssen"),_t.forEach((function(e){e.addEventListener("click",(function(e){e.preventDefault(),e.currentTarget.classList.contains("login")&&(t().logout().then((()=>alert("See you soon!"))),window.location.href="cmlconsent.html")}))}))}else r&&(r.textContent="Directing to log-in page...")})),vt.forEach((function(e){e.addEventListener("click",(function(e){e.preventDefault();const t=e.currentTarget.classList;if(t.contains("fetchObjects")||t.contains("fetchTriples")){if(t.contains("fetchTriples"))var r=document.getElementById("fetchFromTriples").value;else r=document.getElementById("fetchFromObjects").value;const e=document.getElementById("fetchSubject").value,n=document.getElementById("fetchPredicate").value,o=t.contains("fetchTriples");Et(r,e,n,o).then((r=>{const o=document.querySelectorAll(".table");let i=[];if(t.contains("fetchTriples")){for(let e=0;ealert("New file "+a+" is created!")));const h=c.getRef(Xe.instance);return await Be(h)})(t,e,r).then((e=>{(async function(e,t,r){const n=e+"profile/card#me",o=r.addSubject();o.addRef(Je.type,Ze.dataFeedElement),o.addDateTime(Ze.dateCreated,new Date(Date.now())),o.addRef(Ze.creator,n),o.addRef(yt,n);for(let e=0;e{document.getElementById("addTableMessage").textContent="Above triples are saved in "+r,alert("Your editing is successful!")})).catch((e=>{document.getElementById("addTableMessage").textContent=e.message}))}))}else if(t.contains("checkExtRequest"))At().then((e=>{Rt(e).then((e=>{document.getElementById("firstRequestMessage").textContent="Your have 'public/request.ttl' in your Solid Pod already. Ready to submit a data request!"}))}));else if(t.contains("addRequestedData")){if(!document.getElementById("loader")&&document.getElementById("addTriplePredicate").value.length>2){const e=document.createElement("div");e.className="ui active inline loader",e.id="loader",document.getElementById("input_addedField").appendChild(e)}if("ui active inline loader"==document.getElementById("loader").className){(async function(e){let t=await it()("https://data.bioontology.org/recommender?input="+e+"&apikey=21646475-b5a0-4e92-8aba-d9fcfcfea388"),r=await t.json(),n=[],o="";for(let e=0;e{let t=document.getElementById("input_personaldatacategory").value.split(","),r="";if(t.length>1)for(let e=0;e{let t=[];console.log(e.length),e.map((e=>{(async function(e,t){let r=await it()("https://data.bioontology.org/search?q="+t+"&ontology="+e.Ont+"&subtree_root_id="+e.URI+"&apikey=21646475-b5a0-4e92-8aba-d9fcfcfea388");return await r.json()})(e,document.getElementById("addTriplePredicate").value).then((e=>{e.collection.length>0&&t.push(e.collection)})).catch((e=>{}))}))}))}));const e=document.getElementById("input_addRequestedDataMessage"),t=e.textContent.split("\r\n");e.setAttribute("style","white-space: pre;");const r=document.getElementById("addTriplePredicate").value;!t.includes(r)&&r.length>0&&(t.push(r),e.textContent+=r+"\r\n"),e.textContent.split("\r\n").pop(),document.getElementById("loader").style.display="none",document.getElementById("addTriplePredicate").value=""}}else t.contains("submitRequest")&&At().then((e=>{const t=e,r=document.getElementById("input_classPurpose").value.split(","),n=document.getElementById("input_purpose").value,o=document.getElementById("input_title").value,i=document.getElementById("input_personaldatacategory").value.split(","),a=document.getElementById("input_addRequestedDataMessage").textContent.split("\r\n");a.pop();const s=new Date(document.getElementById("input_period").value),c=document.getElementById("input_numInstance").value,h=document.getElementById("input_dataProcessingCategory").value.split(","),u=(document.getElementById("input_model"),{purposeClass:r,title:o,purpose:n,personalDataCategory:i,data:a,period:s,numInstance:c,dataProcessingCategory:h,model:document.getElementById("input_model").value,consequence:document.getElementById("input_consequence").value,token:document.getElementById("input_token").value});Rt(t).then((e=>{(async function(e,t,r){const n="https://"+e.substring(e.lastIndexOf("https://")+8,e.lastIndexOf("/profile/card#me"))+"/private/registration.ttl",o=(await Be(n)).getTriples();let i="";for(let e=0;e <${Je.type}> .`;if(i+=`<${o}> <${Je.type}> ${wt}.`,i+=`<${o}> ${gt} ${t.model}.`,i+=`<${o}> ${dt} ${t.numInstance}.`,i+=`<${o}> <${Ze.creator}> <${r}>.`,i+=`<${o}> <${yt}> <${r}>.`,i+=`<${o}> ${t.purpose}.`,i+=`<${o}> ${t.title}.`,t.data){let e=t.data.sort();for(let r=0;r <${lt}> <${e[r]}>.`}if(t.purposeClass){let e=t.purposeClass.sort();for(let r=0;r <${ct}> <${e[r]}>.`}if(t.personalDataCategory){let e=t.personalDataCategory.sort();for(let r=0;r <${ut}> <${e[r]}>.`}if(t.dataProcessingCategory){let e=t.dataProcessingCategory.sort();for(let r=0;r <${ft}> <${e[r]}>.`}return i}(a,t,e),h=rt.sign.detached((0,nt.decodeUTF8)(c),i);return s.addString(Ze.validIn,(0,nt.encodeBase64)(h)),await o.save([s]),"Thank you for posting a new data request! You can find the RDF file of the request in the public/request.ttl in your SOLID pod"}alert("Cannot find valid credential. Please register first!")})(t,u,e).then((e=>{alert(e)}))}))}))}))}))})()})();
\ No newline at end of file
+(()=>{var e={825:(e,t,r)=>{const n=r(295);e.exports=n},225:e=>{class t{constructor(e){this.value=e||"b"+ ++t.nextId}equals(e){return!!e&&e.termType===this.termType&&e.value===this.value}}t.prototype.termType="BlankNode",t.nextId=0,e.exports=t},295:(e,t,r)=>{const n=r(225),o=r(805),i=r(542),a=r(694),s=r(358),c=r(790),h=r(895),u={namedNode:function(e){return new s(e)},blankNode:function(e){return new n(e)},literal:function(e,t){return"string"==typeof t?-1===t.indexOf(":")?new a(e,t):new a(e,null,u.namedNode(t)):new a(e,null,t)},variable:function(e){return new h(e)},defaultGraph:function(){return u.defaultGraphInstance},triple:function(e,t,r){return u.quad(e,t,r)},quad:function(e,t,r,n){return new c(e,t,r,n||u.defaultGraphInstance)},fromTerm:function(e){return i.call(u,e)},fromQuad:function(e){return i.call(u,e)},defaultGraphInstance:new o};e.exports=u},805:e=>{class t{equals(e){return!!e&&e.termType===this.termType}}t.prototype.termType="DefaultGraph",t.prototype.value="",e.exports=t},694:(e,t,r)=>{const n=r(358);class o{constructor(e,t,r){this.value=e,this.datatype=o.stringDatatype,this.language="",t?(this.language=t,this.datatype=o.langStringDatatype):r&&(this.datatype=r)}equals(e){return!!e&&e.termType===this.termType&&e.value===this.value&&e.language===this.language&&e.datatype.equals(this.datatype)}}o.prototype.termType="Literal",o.langStringDatatype=new n("http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"),o.stringDatatype=new n("http://www.w3.org/2001/XMLSchema#string"),e.exports=o},358:e=>{class t{constructor(e){this.value=e}equals(e){return!!e&&e.termType===this.termType&&e.value===this.value}}t.prototype.termType="NamedNode",e.exports=t},790:(e,t,r)=>{const n=r(805);class o{constructor(e,t,r,o){this.subject=e,this.predicate=t,this.object=r,this.graph=o||new n}equals(e){return!!e&&("Quad"===e.termType||!e.termType)&&e.subject.equals(this.subject)&&e.predicate.equals(this.predicate)&&e.object.equals(this.object)&&e.graph.equals(this.graph)}}o.prototype.termType="Quad",o.prototype.value="",e.exports=o},895:e=>{class t{constructor(e){this.value=e}equals(e){return!!e&&e.termType===this.termType&&e.value===this.value}}t.prototype.termType="Variable",e.exports=t},542:e=>{e.exports=function(e){if(!e)return null;if("BlankNode"===e.termType)return this.blankNode(e.value);if("DefaultGraph"===e.termType)return this.defaultGraph();if("Literal"===e.termType)return this.literal(e.value,e.language||this.namedNode(e.datatype.value));if("NamedNode"===e.termType)return this.namedNode(e.value);if("Quad"===e.termType){const t=this.fromTerm(e.subject),r=this.fromTerm(e.predicate),n=this.fromTerm(e.object),o=this.fromTerm(e.graph);return this.quad(t,r,n,o)}if("Variable"===e.termType)return this.variable(e.value);throw new Error(`unknown termType ${e.termType}`)}},599:e=>{"use strict";const{AbortController:t,AbortSignal:r}="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0;e.exports=t,e.exports.AbortSignal=r,e.exports.default=t},742:(e,t)=>{"use strict";t.byteLength=function(e){var t=c(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,i=c(e),a=i[0],s=i[1],h=new o(function(e,t,r){return 3*(t+r)/4-r}(0,a,s)),u=0,l=s>0?a-4:a;for(r=0;r>16&255,h[u++]=t>>8&255,h[u++]=255&t;return 2===s&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,h[u++]=255&t),1===s&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,h[u++]=t>>8&255,h[u++]=255&t),h},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],a=16383,s=0,c=n-o;sc?c:s+a));return 1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),i.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=i.length;a0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function h(e,t,n){for(var o,i,a=[],s=t;s>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},764:(e,t,r)=>{"use strict";const n=r(742),o=r(645),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=c,t.SlowBuffer=function(e){return+e!=e&&(e=0),c.alloc(+e)},t.INSPECT_MAX_BYTES=50;const a=2147483647;function s(e){if(e>a)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,c.prototype),t}function c(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return l(e)}return h(e,t,r)}function h(e,t,r){if("string"==typeof e)return function(e,t){if("string"==typeof t&&""!==t||(t="utf8"),!c.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const r=0|g(e,t);let n=s(r);const o=n.write(e,t);return o!==r&&(n=n.slice(0,o)),n}(e,t);if(ArrayBuffer.isView(e))return function(e){if(Y(e,Uint8Array)){const t=new Uint8Array(e);return d(t.buffer,t.byteOffset,t.byteLength)}return p(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(Y(e,ArrayBuffer)||e&&Y(e.buffer,ArrayBuffer))return d(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(Y(e,SharedArrayBuffer)||e&&Y(e.buffer,SharedArrayBuffer)))return d(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const n=e.valueOf&&e.valueOf();if(null!=n&&n!==e)return c.from(n,t,r);const o=function(e){if(c.isBuffer(e)){const t=0|f(e.length),r=s(t);return 0===r.length||e.copy(r,0,0,t),r}return void 0!==e.length?"number"!=typeof e.length||Q(e.length)?s(0):p(e):"Buffer"===e.type&&Array.isArray(e.data)?p(e.data):void 0}(e);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return c.from(e[Symbol.toPrimitive]("string"),t,r);throw new 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 new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function l(e){return u(e),s(e<0?0:0|f(e))}function p(e){const t=e.length<0?0:0|f(e.length),r=s(t);for(let n=0;n=a)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a.toString(16)+" bytes");return 0|e}function g(e,t){if(c.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||Y(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const r=e.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;let o=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return z(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return K(e).length;default:if(o)return n?-1:z(e).length;t=(""+t).toLowerCase(),o=!0}}function m(e,t,r){let n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return P(this,t,r);case"utf8":case"utf-8":return R(this,t,r);case"ascii":return T(this,t,r);case"latin1":case"binary":return O(this,t,r);case"base64":return x(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function y(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function w(e,t,r,n,o){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),Q(r=+r)&&(r=o?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(o)return-1;r=e.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof t&&(t=c.from(t,n)),c.isBuffer(t))return 0===t.length?-1:b(e,t,r,n,o);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):b(e,[t],r,n,o);throw new TypeError("val must be string, number or Buffer")}function b(e,t,r,n,o){let i,a=1,s=e.length,c=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,c/=2,r/=2}function h(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){let n=-1;for(i=r;is&&(r=s-c),i=r;i>=0;i--){let r=!0;for(let n=0;no&&(n=o):n=o;const i=t.length;let a;for(n>i/2&&(n=i/2),a=0;a>8,o=r%256,i.push(o),i.push(n);return i}(t,e.length-r),e,r,n)}function x(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function R(e,t,r){r=Math.min(e.length,r);const n=[];let o=t;for(;o239?4:t>223?3:t>191?2:1;if(o+a<=r){let r,n,s,c;switch(a){case 1:t<128&&(i=t);break;case 2:r=e[o+1],128==(192&r)&&(c=(31&t)<<6|63&r,c>127&&(i=c));break;case 3:r=e[o+1],n=e[o+2],128==(192&r)&&128==(192&n)&&(c=(15&t)<<12|(63&r)<<6|63&n,c>2047&&(c<55296||c>57343)&&(i=c));break;case 4:r=e[o+1],n=e[o+2],s=e[o+3],128==(192&r)&&128==(192&n)&&128==(192&s)&&(c=(15&t)<<18|(63&r)<<12|(63&n)<<6|63&s,c>65535&&c<1114112&&(i=c))}}null===i?(i=65533,a=1):i>65535&&(i-=65536,n.push(i>>>10&1023|55296),i=56320|1023&i),n.push(i),o+=a}return function(e){const t=e.length;if(t<=C)return String.fromCharCode.apply(String,e);let r="",n=0;for(;nn.length?(c.isBuffer(t)||(t=c.from(t)),t.copy(n,o)):Uint8Array.prototype.set.call(n,t,o);else{if(!c.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(n,o)}o+=t.length}return n},c.byteLength=g,c.prototype._isBuffer=!0,c.prototype.swap16=function(){const e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;tr&&(e+=" ... "),""},i&&(c.prototype[i]=c.prototype.inspect),c.prototype.compare=function(e,t,r,n,o){if(Y(e,Uint8Array)&&(e=c.from(e,e.offset,e.byteLength)),!c.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),t<0||r>e.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&t>=r)return 0;if(n>=o)return-1;if(t>=r)return 1;if(this===e)return 0;let i=(o>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0);const s=Math.min(i,a),h=this.slice(n,o),u=e.slice(t,r);for(let e=0;e>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}const o=this.length-t;if((void 0===r||r>o)&&(r=o),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");let i=!1;for(;;)switch(n){case"hex":return v(this,e,t,r);case"utf8":case"utf-8":return _(this,e,t,r);case"ascii":case"latin1":case"binary":return S(this,e,t,r);case"base64":return A(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const C=4096;function T(e,t,r){let n="";r=Math.min(e.length,r);for(let o=t;on)&&(r=n);let o="";for(let n=t;nr)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,r,n,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||te.length)throw new RangeError("Index out of range")}function D(e,t,r,n,o){$(t,n,o,e,r,7);let i=Number(t&BigInt(4294967295));e[r++]=i,i>>=8,e[r++]=i,i>>=8,e[r++]=i,i>>=8,e[r++]=i;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,a>>=8,e[r++]=a,r}function B(e,t,r,n,o){$(t,n,o,e,r,7);let i=Number(t&BigInt(4294967295));e[r+7]=i,i>>=8,e[r+6]=i,i>>=8,e[r+5]=i,i>>=8,e[r+4]=i;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[r+3]=a,a>>=8,e[r+2]=a,a>>=8,e[r+1]=a,a>>=8,e[r]=a,r+8}function N(e,t,r,n,o,i){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function L(e,t,r,n,i){return t=+t,r>>>=0,i||N(e,0,r,4),o.write(e,t,r,n,23,4),r+4}function M(e,t,r,n,i){return t=+t,r>>>=0,i||N(e,0,r,8),o.write(e,t,r,n,52,8),r+8}c.prototype.slice=function(e,t){const r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t>>=0,t>>>=0,r||k(e,t,this.length);let n=this[e],o=1,i=0;for(;++i>>=0,t>>>=0,r||k(e,t,this.length);let n=this[e+--t],o=1;for(;t>0&&(o*=256);)n+=this[e+--t]*o;return n},c.prototype.readUint8=c.prototype.readUInt8=function(e,t){return e>>>=0,t||k(e,1,this.length),this[e]},c.prototype.readUint16LE=c.prototype.readUInt16LE=function(e,t){return e>>>=0,t||k(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUint16BE=c.prototype.readUInt16BE=function(e,t){return e>>>=0,t||k(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUint32LE=c.prototype.readUInt32LE=function(e,t){return e>>>=0,t||k(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUint32BE=c.prototype.readUInt32BE=function(e,t){return e>>>=0,t||k(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readBigUInt64LE=Z((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||W(e,this.length-8);const n=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,o=this[++e]+256*this[++e]+65536*this[++e]+r*2**24;return BigInt(n)+(BigInt(o)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||W(e,this.length-8);const n=t*2**24+65536*this[++e]+256*this[++e]+this[++e],o=this[++e]*2**24+65536*this[++e]+256*this[++e]+r;return(BigInt(n)<>>=0,t>>>=0,r||k(e,t,this.length);let n=this[e],o=1,i=0;for(;++i=o&&(n-=Math.pow(2,8*t)),n},c.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||k(e,t,this.length);let n=t,o=1,i=this[e+--n];for(;n>0&&(o*=256);)i+=this[e+--n]*o;return o*=128,i>=o&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return e>>>=0,t||k(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){e>>>=0,t||k(e,2,this.length);const r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt16BE=function(e,t){e>>>=0,t||k(e,2,this.length);const r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt32LE=function(e,t){return e>>>=0,t||k(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return e>>>=0,t||k(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readBigInt64LE=Z((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||W(e,this.length-8);const n=this[e+4]+256*this[e+5]+65536*this[e+6]+(r<<24);return(BigInt(n)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||W(e,this.length-8);const n=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(n)<>>=0,t||k(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return e>>>=0,t||k(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return e>>>=0,t||k(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return e>>>=0,t||k(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUintLE=c.prototype.writeUIntLE=function(e,t,r,n){e=+e,t>>>=0,r>>>=0,n||j(this,e,t,r,Math.pow(2,8*r)-1,0);let o=1,i=0;for(this[t]=255&e;++i>>=0,r>>>=0,n||j(this,e,t,r,Math.pow(2,8*r)-1,0);let o=r-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+r},c.prototype.writeUint8=c.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,1,255,0),this[t]=255&e,t+1},c.prototype.writeUint16LE=c.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},c.prototype.writeUint16BE=c.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},c.prototype.writeUint32LE=c.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},c.prototype.writeUint32BE=c.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},c.prototype.writeBigUInt64LE=Z((function(e,t=0){return D(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),c.prototype.writeBigUInt64BE=Z((function(e,t=0){return B(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),c.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);j(this,e,t,r,n-1,-n)}let o=0,i=1,a=0;for(this[t]=255&e;++o>0)-a&255;return t+r},c.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){const n=Math.pow(2,8*r-1);j(this,e,t,r,n-1,-n)}let o=r-1,i=1,a=0;for(this[t+o]=255&e;--o>=0&&(i*=256);)e<0&&0===a&&0!==this[t+o+1]&&(a=1),this[t+o]=(e/i>>0)-a&255;return t+r},c.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},c.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},c.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},c.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},c.prototype.writeBigInt64LE=Z((function(e,t=0){return D(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),c.prototype.writeBigInt64BE=Z((function(e,t=0){return B(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),c.prototype.writeFloatLE=function(e,t,r){return L(this,e,t,!0,r)},c.prototype.writeFloatBE=function(e,t,r){return L(this,e,t,!1,r)},c.prototype.writeDoubleLE=function(e,t,r){return M(this,e,t,!0,r)},c.prototype.writeDoubleBE=function(e,t,r){return M(this,e,t,!1,r)},c.prototype.copy=function(e,t,r,n){if(!c.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o=n+4;r-=3)t=`_${e.slice(r-3,r)}${t}`;return`${e.slice(0,r)}${t}`}function $(e,t,r,n,o,i){if(e>r||e3?0===t||t===BigInt(0)?`>= 0${n} and < 2${n} ** ${8*(i+1)}${n}`:`>= -(2${n} ** ${8*(i+1)-1}${n}) and < 2 ** ${8*(i+1)-1}${n}`:`>= ${t}${n} and <= ${r}${n}`,new U.ERR_OUT_OF_RANGE("value",o,e)}!function(e,t,r){H(t,"offset"),void 0!==e[t]&&void 0!==e[t+r]||W(t,e.length-(r+1))}(n,o,i)}function H(e,t){if("number"!=typeof e)throw new U.ERR_INVALID_ARG_TYPE(t,"number",e)}function W(e,t,r){if(Math.floor(e)!==e)throw H(e,r),new U.ERR_OUT_OF_RANGE(r||"offset","an integer",e);if(t<0)throw new U.ERR_BUFFER_OUT_OF_BOUNDS;throw new U.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${t}`,e)}F("ERR_BUFFER_OUT_OF_BOUNDS",(function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),F("ERR_INVALID_ARG_TYPE",(function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`}),TypeError),F("ERR_OUT_OF_RANGE",(function(e,t,r){let n=`The value of "${e}" is out of range.`,o=r;return Number.isInteger(r)&&Math.abs(r)>2**32?o=q(String(r)):"bigint"==typeof r&&(o=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(o=q(o)),o+="n"),n+=` It must be ${t}. Received ${o}`,n}),RangeError);const G=/[^+/0-9A-Za-z-_]/g;function z(e,t){let r;t=t||1/0;const n=e.length;let o=null;const i=[];for(let a=0;a55295&&r<57344){if(!o){if(r>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(t-=3)>-1&&i.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((t-=1)<0)break;i.push(r)}else if(r<2048){if((t-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function K(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(G,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function V(e,t,r,n){let o;for(o=0;o=t.length||o>=e.length);++o)t[o+r]=e[o];return o}function Y(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function Q(e){return e!=e}const J=function(){const e="0123456789abcdef",t=new Array(256);for(let r=0;r<16;++r){const n=16*r;for(let o=0;o<16;++o)t[n+o]=e[r]+e[o]}return t}();function Z(e){return"undefined"==typeof BigInt?X:e}function X(){throw new Error("BigInt not supported")}},187:e=>{"use strict";var t,r="object"==typeof Reflect?Reflect:null,n=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var o=Number.isNaN||function(e){return e!=e};function i(){i.init.call(this)}e.exports=i,e.exports.once=function(e,t){return new Promise((function(r,n){function o(r){e.removeListener(t,i),n(r)}function i(){"function"==typeof e.removeListener&&e.removeListener("error",o),r([].slice.call(arguments))}g(e,t,i,{once:!0}),"error"!==t&&function(e,t,r){"function"==typeof e.on&&g(e,"error",t,{once:!0})}(e,o)}))},i.EventEmitter=i,i.prototype._events=void 0,i.prototype._eventsCount=0,i.prototype._maxListeners=void 0;var a=10;function s(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function c(e){return void 0===e._maxListeners?i.defaultMaxListeners:e._maxListeners}function h(e,t,r,n){var o,i,a,h;if(s(r),void 0===(i=e._events)?(i=e._events=Object.create(null),e._eventsCount=0):(void 0!==i.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),i=e._events),a=i[t]),void 0===a)a=i[t]=r,++e._eventsCount;else if("function"==typeof a?a=i[t]=n?[r,a]:[a,r]:n?a.unshift(r):a.push(r),(o=c(e))>0&&a.length>o&&!a.warned){a.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=e,u.type=t,u.count=a.length,h=u,console&&console.warn&&console.warn(h)}return e}function u(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function l(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},o=u.bind(n);return o.listener=r,n.wrapFn=o,o}function p(e,t,r){var n=e._events;if(void 0===n)return[];var o=n[t];return void 0===o?[]:"function"==typeof o?r?[o.listener||o]:[o]:r?function(e){for(var t=new Array(e.length),r=0;r0&&(a=t[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var c=i[e];if(void 0===c)return!1;if("function"==typeof c)n(c,this,t);else{var h=c.length,u=f(c,h);for(r=0;r=0;i--)if(r[i]===t||r[i].listener===t){a=r[i].listener,o=i;break}if(o<0)return this;0===o?r.shift():function(e,t){for(;t+1=0;n--)this.removeListener(e,t[n]);return this},i.prototype.listeners=function(e){return p(this,e,!0)},i.prototype.rawListeners=function(e){return p(this,e,!1)},i.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},i.prototype.listenerCount=d,i.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},475:e=>{"use strict";var t=/^utf-?8|ascii|utf-?16-?le|ucs-?2|base-?64|latin-?1$/i,r=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,n=/\s|\uFEFF|\xA0/,o=/\r?\n[\x20\x09]+/g,i=/[;,"]/,a=/[;,"]|\s/,s=/^[!#$%&'*+\-\.^_`|~\da-zA-Z]+$/;function c(e){return e.replace(r,"")}function h(e){return n.test(e)}function u(e,t){for(;h(e[t]);)t++;return t}function l(e){return a.test(e)||!s.test(e)}class p{constructor(e){this.refs=[],e&&this.parse(e)}rel(e){for(var t=[],r=e.toLowerCase(),n=0;n{return r=t,n=e,Object.keys(r).length===Object.keys(n).length&&Object.keys(r).every((e=>e in n&&r[e]===n[e]));var r,n}))||this.refs.push(e),this}has(e,t){e=e.toLowerCase();for(var r=0;r",t)))throw new Error("Expected end of URI delimiter at offset "+t);a={uri:e.slice(t+1,d)},t=d,r=2,t++}else if(2===r){if(h(e[t])){t++;continue}if(";"===e[t])r=4,t++;else{if(","!==e[t])throw new Error('Unexpected character "'+e[t]+'" at offset '+t);r=1,t++}}else{if(4!==r)throw new Error('Unknown parser state "'+r+'"');if(";"===e[t]||h(e[t])){t++;continue}if(-1===(d=e.indexOf("=",t)))throw new Error("Expected attribute delimiter at offset "+t);var s=c(e.slice(t,d)).toLowerCase(),l="";if('"'===e[t=u(e,t=d+1)])for(t++;t"),e.push(t);return e.join(", ")}}p.isCompatibleEncoding=function(e){return t.test(e)},p.parse=function(e,t){return(new p).parse(e,t)},p.isSingleOccurenceAttr=function(e){return"rel"===e||"type"===e||"media"===e||"title"===e||"title*"===e},p.isTokenAttr=function(e){return"rel"===e||"type"===e||"anchor"===e},p.escapeQuotes=function(e){return e.replace(/"/g,'\\"')},p.expandRelations=function(e){return e.rel.split(" ").map((function(t){var r=Object.assign({},e);return r.rel=t,r}))},p.parseExtendedValue=function(e){var t=/([^']+)?(?:'([^']*)')?(.+)/.exec(e);return{language:t[2].toLowerCase(),encoding:p.isCompatibleEncoding(t[1])?null:t[1].toLowerCase(),value:p.isCompatibleEncoding(t[1])?decodeURIComponent(t[3]):t[3]}},p.formatExtendedAttribute=function(e,t){var r=(t.encoding||"utf-8").toUpperCase();return e+"="+r+"'"+(t.language||"en")+"'"+(Buffer.isBuffer(t.value)&&p.isCompatibleEncoding(r)?t.value.toString(r):Buffer.isBuffer(t.value)?t.value.toString("hex").replace(/[0-9a-f]{2}/gi,"%$1"):encodeURIComponent(t.value))},p.formatAttribute=function(e,t){return Array.isArray(t)?t.map((t=>p.formatAttribute(e,t))).join("; "):"*"===e[e.length-1]||"string"!=typeof t?p.formatExtendedAttribute(e,t):(p.isTokenAttr(e)?t=l(t)?'"'+p.escapeQuotes(t)+'"':p.escapeQuotes(t):l(t)&&(t='"'+(t=(t=encodeURIComponent(t)).replace(/%20/g," ").replace(/%2C/g,",").replace(/%3B/g,";"))+'"'),e+"="+t)},e.exports=p},645:(e,t)=>{t.read=function(e,t,r,n,o){var i,a,s=8*o-n-1,c=(1<>1,u=-7,l=r?o-1:0,p=r?-1:1,d=e[t+l];for(l+=p,i=d&(1<<-u)-1,d>>=-u,u+=s;u>0;i=256*i+e[t+l],l+=p,u-=8);for(a=i&(1<<-u)-1,i>>=-u,u+=n;u>0;a=256*a+e[t+l],l+=p,u-=8);if(0===i)i=1-h;else{if(i===c)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),i-=h}return(d?-1:1)*a*Math.pow(2,i-n)},t.write=function(e,t,r,n,o,i){var a,s,c,h=8*i-o-1,u=(1<>1,p=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:i-1,f=n?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=u):(a=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-a))<1&&(a--,c*=2),(t+=a+l>=1?p/c:p*Math.pow(2,1-l))*c>=2&&(a++,c/=2),a+l>=u?(s=0,a=u):a+l>=1?(s=(t*c-1)*Math.pow(2,o),a+=l):(s=t*Math.pow(2,l-1)*Math.pow(2,o),a=0));o>=8;e[r+d]=255&s,d+=f,s/=256,o-=8);for(a=a<0;e[r+d]=255&a,d+=f,a/=256,h-=8);e[r+d-f]|=128*g}},300:(e,t,r)=>{"use strict";var n=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==r.g)return r.g;throw new Error("unable to locate global object")}();e.exports=t=n.fetch,n.fetch&&(t.default=n.fetch.bind(n)),t.Headers=n.Headers,t.Request=n.Request,t.Response=n.Response},155:e=>{var t,r,n=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===o||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(r){try{return t.call(null,e,0)}catch(r){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:o}catch(e){t=o}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(e){r=i}}();var s,c=[],h=!1,u=-1;function l(){h&&s&&(h=!1,s.length?c=s.concat(c):u=-1,c.length&&p())}function p(){if(!h){var e=a(l);h=!0;for(var t=c.length;t;){for(s=c,c=[];++u1)for(var r=1;r{let n;e.exports="function"==typeof queueMicrotask?queueMicrotask.bind("undefined"!=typeof window?window:r.g):e=>(n||(n=Promise.resolve())).then(e).catch((e=>setTimeout((()=>{throw e}),0)))},196:(e,t,r)=>{"use strict";const{AbortError:n,codes:o}=r(381),i=r(610),{ERR_INVALID_ARG_TYPE:a}=o;e.exports.addAbortSignal=function(t,r){if(((e,t)=>{if("object"!=typeof e||!("aborted"in e))throw new a("signal","AbortSignal",e)})(t),!(n=r)||"function"!=typeof n.pipe)throw new a("stream","stream.Stream",r);var n;return e.exports.addAbortSignalNoValidate(t,r)},e.exports.addAbortSignalNoValidate=function(e,t){if("object"!=typeof e||!("aborted"in e))return t;const r=()=>{t.destroy(new n(void 0,{cause:e.reason}))};return e.aborted?r():(e.addEventListener("abort",r),i(t,(()=>e.removeEventListener("abort",r)))),t}},327:(e,t,r)=>{"use strict";const{StringPrototypeSlice:n,SymbolIterator:o,TypedArrayPrototypeSet:i,Uint8Array:a}=r(61),{Buffer:s}=r(764),{inspect:c}=r(87);e.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(e){const t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length}unshift(e){const t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}shift(){if(0===this.length)return;const e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}clear(){this.head=this.tail=null,this.length=0}join(e){if(0===this.length)return"";let t=this.head,r=""+t.data;for(;null!==(t=t.next);)r+=e+t.data;return r}concat(e){if(0===this.length)return s.alloc(0);const t=s.allocUnsafe(e>>>0);let r=this.head,n=0;for(;r;)i(t,r.data,n),n+=r.data.length,r=r.next;return t}consume(e,t){const r=this.head.data;if(ei.length)){e===i.length?(t+=i,++o,r.next?this.head=r.next:this.head=this.tail=null):(t+=n(i,0,e),this.head=r,r.data=n(i,e));break}t+=i,e-=i.length,++o}while(null!==(r=r.next));return this.length-=o,t}_getBuffer(e){const t=s.allocUnsafe(e),r=e;let n=this.head,o=0;do{const s=n.data;if(!(e>s.length)){e===s.length?(i(t,s,r-e),++o,n.next?this.head=n.next:this.head=this.tail=null):(i(t,new a(s.buffer,s.byteOffset,e),r-e),this.head=n,n.data=s.slice(e));break}i(t,s,r-e),e-=s.length,++o}while(null!==(n=n.next));return this.length-=o,t}[Symbol.for("nodejs.util.inspect.custom")](e,t){return c(this,{...t,depth:0,customInspect:!1})}}},299:(e,t,r)=>{"use strict";const{pipeline:n}=r(946),o=r(672),{destroyer:i}=r(195),{isNodeStream:a,isReadable:s,isWritable:c}=r(874),{AbortError:h,codes:{ERR_INVALID_ARG_VALUE:u,ERR_MISSING_ARGS:l}}=r(381);e.exports=function(...e){if(0===e.length)throw new l("streams");if(1===e.length)return o.from(e[0]);const t=[...e];if("function"==typeof e[0]&&(e[0]=o.from(e[0])),"function"==typeof e[e.length-1]){const t=e.length-1;e[t]=o.from(e[t])}for(let r=0;r0&&!c(e[r]))throw new u(`streams[${r}]`,t[r],"must be writable")}let r,p,d,f,g;const m=e[0],y=n(e,(function(e){const t=f;f=null,t?t(e):e?g.destroy(e):b||w||g.destroy()})),w=!!c(m),b=!!s(y);return g=new o({writableObjectMode:!(null==m||!m.writableObjectMode),readableObjectMode:!(null==y||!y.writableObjectMode),writable:w,readable:b}),w&&(g._write=function(e,t,n){m.write(e,t)?n():r=n},g._final=function(e){m.end(),p=e},m.on("drain",(function(){if(r){const e=r;r=null,e()}})),y.on("finish",(function(){if(p){const e=p;p=null,e()}}))),b&&(y.on("readable",(function(){if(d){const e=d;d=null,e()}})),y.on("end",(function(){g.push(null)})),g._read=function(){for(;;){const e=y.read();if(null===e)return void(d=g._read);if(!g.push(e))return}}),g._destroy=function(e,t){e||null===f||(e=new h),d=null,r=null,p=null,null===f?t(e):(f=t,i(y,e))},g}},195:(e,t,r)=>{"use strict";const n=r(155),{aggregateTwoErrors:o,codes:{ERR_MULTIPLE_CALLBACK:i},AbortError:a}=r(381),{Symbol:s}=r(61),{kDestroyed:c,isDestroyed:h,isFinished:u,isServerRequest:l}=r(874),p=s("kDestroy"),d=s("kConstruct");function f(e,t,r){e&&(e.stack,t&&!t.errored&&(t.errored=e),r&&!r.errored&&(r.errored=e))}function g(e,t,r){let o=!1;function i(t){if(o)return;o=!0;const i=e._readableState,a=e._writableState;f(t,a,i),a&&(a.closed=!0),i&&(i.closed=!0),"function"==typeof r&&r(t),t?n.nextTick(m,e,t):n.nextTick(y,e)}try{e._destroy(t||null,i)}catch(t){i(t)}}function m(e,t){w(e,t),y(e)}function y(e){const t=e._readableState,r=e._writableState;r&&(r.closeEmitted=!0),t&&(t.closeEmitted=!0),(r&&r.emitClose||t&&t.emitClose)&&e.emit("close")}function w(e,t){const r=e._readableState,n=e._writableState;n&&n.errorEmitted||r&&r.errorEmitted||(n&&(n.errorEmitted=!0),r&&(r.errorEmitted=!0),e.emit("error",t))}function b(e,t,r){const o=e._readableState,i=e._writableState;if(i&&i.destroyed||o&&o.destroyed)return this;o&&o.autoDestroy||i&&i.autoDestroy?e.destroy(t):t&&(t.stack,i&&!i.errored&&(i.errored=t),o&&!o.errored&&(o.errored=t),r?n.nextTick(w,e,t):w(e,t))}function v(e){let t=!1;function r(r){if(t)return void b(e,null!=r?r:new i);t=!0;const o=e._readableState,a=e._writableState,s=a||o;o&&(o.constructed=!0),a&&(a.constructed=!0),s.destroyed?e.emit(p,r):r?b(e,r,!0):n.nextTick(_,e)}try{e._construct(r)}catch(e){r(e)}}function _(e){e.emit(d)}function S(e){return e&&e.setHeader&&"function"==typeof e.abort}function A(e){e.emit("close")}function E(e,t){e.emit("error",t),n.nextTick(A,e)}e.exports={construct:function(e,t){if("function"!=typeof e._construct)return;const r=e._readableState,o=e._writableState;r&&(r.constructed=!1),o&&(o.constructed=!1),e.once(d,t),e.listenerCount(d)>1||n.nextTick(v,e)},destroyer:function(e,t){e&&!h(e)&&(t||u(e)||(t=new a),l(e)?(e.socket=null,e.destroy(t)):S(e)?e.abort():S(e.req)?e.req.abort():"function"==typeof e.destroy?e.destroy(t):"function"==typeof e.close?e.close():t?n.nextTick(E,e,t):n.nextTick(A,e),e.destroyed||(e[c]=!0))},destroy:function(e,t){const r=this._readableState,n=this._writableState,i=n||r;return n&&n.destroyed||r&&r.destroyed?("function"==typeof t&&t(),this):(f(e,n,r),n&&(n.destroyed=!0),r&&(r.destroyed=!0),i.constructed?g(this,e,t):this.once(p,(function(r){g(this,o(r,e),t)})),this)},undestroy:function(){const e=this._readableState,t=this._writableState;e&&(e.constructed=!0,e.closed=!1,e.closeEmitted=!1,e.destroyed=!1,e.errored=null,e.errorEmitted=!1,e.reading=!1,e.ended=!1===e.readable,e.endEmitted=!1===e.readable),t&&(t.constructed=!0,t.destroyed=!1,t.closed=!1,t.closeEmitted=!1,t.errored=null,t.errorEmitted=!1,t.finalCalled=!1,t.prefinished=!1,t.ended=!1===t.writable,t.ending=!1===t.writable,t.finished=!1===t.writable)},errorOrDestroy:b}},672:(e,t,r)=>{"use strict";const{ObjectDefineProperties:n,ObjectGetOwnPropertyDescriptor:o,ObjectKeys:i,ObjectSetPrototypeOf:a}=r(61);e.exports=h;const s=r(911),c=r(304);a(h.prototype,s.prototype),a(h,s);{const e=i(c.prototype);for(let t=0;t{const n=r(155),o=r(764),{isReadable:i,isWritable:a,isIterable:s,isNodeStream:c,isReadableNodeStream:h,isWritableNodeStream:u,isDuplexNodeStream:l}=r(874),p=r(610),{AbortError:d,codes:{ERR_INVALID_ARG_TYPE:f,ERR_INVALID_RETURN_VALUE:g}}=r(381),{destroyer:m}=r(195),y=r(672),w=r(911),{createDeferredPromise:b}=r(87),v=r(307),_=globalThis.Blob||o.Blob,S=void 0!==_?function(e){return e instanceof _}:function(e){return!1},A=globalThis.AbortController||r(599).AbortController,{FunctionPrototypeCall:E}=r(61);class x extends y{constructor(e){super(e),!1===(null==e?void 0:e.readable)&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),!1===(null==e?void 0:e.writable)&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}}function R(e){const t=e.readable&&"function"!=typeof e.readable.read?w.wrap(e.readable):e.readable,r=e.writable;let n,o,s,c,h,u=!!i(t),l=!!a(r);function f(e){const t=c;c=null,t?t(e):e?h.destroy(e):u||l||h.destroy()}return h=new x({readableObjectMode:!(null==t||!t.readableObjectMode),writableObjectMode:!(null==r||!r.writableObjectMode),readable:u,writable:l}),l&&(p(r,(e=>{l=!1,e&&m(t,e),f(e)})),h._write=function(e,t,o){r.write(e,t)?o():n=o},h._final=function(e){r.end(),o=e},r.on("drain",(function(){if(n){const e=n;n=null,e()}})),r.on("finish",(function(){if(o){const e=o;o=null,e()}}))),u&&(p(t,(e=>{u=!1,e&&m(t,e),f(e)})),t.on("readable",(function(){if(s){const e=s;s=null,e()}})),t.on("end",(function(){h.push(null)})),h._read=function(){for(;;){const e=t.read();if(null===e)return void(s=h._read);if(!h.push(e))return}}),h._destroy=function(e,i){e||null===c||(e=new d),s=null,n=null,o=null,null===c?i(e):(c=i,m(r,e),m(t,e))},h}e.exports=function e(t,r){if(l(t))return t;if(h(t))return R({readable:t});if(u(t))return R({writable:t});if(c(t))return R({writable:!1,readable:!1});if("function"==typeof t){const{value:e,write:o,final:i,destroy:a}=function(e){let{promise:t,resolve:r}=b();const o=new A,i=o.signal;return{value:e(async function*(){for(;;){const e=t;t=null;const{chunk:o,done:a,cb:s}=await e;if(n.nextTick(s),a)return;if(i.aborted)throw new d(void 0,{cause:i.reason});({promise:t,resolve:r}=b()),yield o}}(),{signal:i}),write(e,t,n){const o=r;r=null,o({chunk:e,done:!1,cb:n})},final(e){const t=r;r=null,t({done:!0,cb:e})},destroy(e,t){o.abort(),t(e)}}}(t);if(s(e))return v(x,e,{objectMode:!0,write:o,final:i,destroy:a});const c=null==e?void 0:e.then;if("function"==typeof c){let t;const r=E(c,e,(e=>{if(null!=e)throw new g("nully","body",e)}),(e=>{m(t,e)}));return t=new x({objectMode:!0,readable:!1,write:o,final(e){i((async()=>{try{await r,n.nextTick(e,null)}catch(t){n.nextTick(e,t)}}))},destroy:a})}throw new g("Iterable, AsyncIterable or AsyncFunction",r,e)}if(S(t))return e(t.arrayBuffer());if(s(t))return v(x,t,{objectMode:!0,writable:!1});if("object"==typeof(null==t?void 0:t.writable)||"object"==typeof(null==t?void 0:t.readable))return R({readable:null!=t&&t.readable?h(null==t?void 0:t.readable)?null==t?void 0:t.readable:e(t.readable):void 0,writable:null!=t&&t.writable?u(null==t?void 0:t.writable)?null==t?void 0:t.writable:e(t.writable):void 0});const o=null==t?void 0:t.then;if("function"==typeof o){let e;return E(o,t,(t=>{null!=t&&e.push(t),e.push(null)}),(t=>{m(e,t)})),e=new x({objectMode:!0,writable:!1,read(){}})}throw new f(r,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],t)}},610:(e,t,r)=>{const n=r(155),{AbortError:o,codes:i}=r(381),{ERR_INVALID_ARG_TYPE:a,ERR_STREAM_PREMATURE_CLOSE:s}=i,{kEmptyObject:c,once:h}=r(87),{validateAbortSignal:u,validateFunction:l,validateObject:p}=r(547),{Promise:d}=r(61),{isClosed:f,isReadable:g,isReadableNodeStream:m,isReadableFinished:y,isReadableErrored:w,isWritable:b,isWritableNodeStream:v,isWritableFinished:_,isWritableErrored:S,isNodeStream:A,willEmitClose:E}=r(874),x=()=>{};function R(e,t,r){var i,d;2===arguments.length?(r=t,t=c):null==t?t=c:p(t,"options"),l(r,"callback"),u(t.signal,"options.signal"),r=h(r);const R=null!==(i=t.readable)&&void 0!==i?i:m(e),C=null!==(d=t.writable)&&void 0!==d?d:v(e);if(!A(e))throw new a("stream","Stream",e);const T=e._writableState,O=e._readableState,P=()=>{e.writable||j()};let I=E(e)&&m(e)===R&&v(e)===C,k=_(e,!1);const j=()=>{k=!0,e.destroyed&&(I=!1),(!I||e.readable&&!R)&&(R&&!D||r.call(e))};let D=y(e,!1);const B=()=>{D=!0,e.destroyed&&(I=!1),(!I||e.writable&&!C)&&(C&&!k||r.call(e))},N=t=>{r.call(e,t)};let L=f(e);const M=()=>{L=!0;const t=S(e)||w(e);return t&&"boolean"!=typeof t?r.call(e,t):R&&!D&&m(e,!0)&&!y(e,!1)?r.call(e,new s):!C||k||_(e,!1)?void r.call(e):r.call(e,new s)},U=()=>{e.req.on("finish",j)};!function(e){return e.setHeader&&"function"==typeof e.abort}(e)?C&&!T&&(e.on("end",P),e.on("close",P)):(e.on("complete",j),I||e.on("abort",M),e.req?U():e.on("request",U)),I||"boolean"!=typeof e.aborted||e.on("aborted",M),e.on("end",B),e.on("finish",j),!1!==t.error&&e.on("error",N),e.on("close",M),L?n.nextTick(M):null!=T&&T.errorEmitted||null!=O&&O.errorEmitted?I||n.nextTick(M):(R||I&&!g(e)||!k&&!1!==b(e))&&(C||I&&!b(e)||!D&&!1!==g(e))?O&&e.req&&e.aborted&&n.nextTick(M):n.nextTick(M);const F=()=>{r=x,e.removeListener("aborted",M),e.removeListener("complete",j),e.removeListener("abort",M),e.removeListener("request",U),e.req&&e.req.removeListener("finish",j),e.removeListener("end",P),e.removeListener("close",P),e.removeListener("finish",j),e.removeListener("end",B),e.removeListener("error",N),e.removeListener("close",M)};if(t.signal&&!L){const i=()=>{const n=r;F(),n.call(e,new o(void 0,{cause:t.signal.reason}))};if(t.signal.aborted)n.nextTick(i);else{const n=r;r=h(((...r)=>{t.signal.removeEventListener("abort",i),n.apply(e,r)})),t.signal.addEventListener("abort",i)}}return F}e.exports=R,e.exports.finished=function(e,t){return new d(((r,n)=>{R(e,t,(e=>{e?n(e):r()}))}))}},307:(e,t,r)=>{"use strict";const n=r(155),{PromisePrototypeThen:o,SymbolAsyncIterator:i,SymbolIterator:a}=r(61),{Buffer:s}=r(764),{ERR_INVALID_ARG_TYPE:c,ERR_STREAM_NULL_VALUES:h}=r(381).codes;e.exports=function(e,t,r){let u,l;if("string"==typeof t||t instanceof s)return new e({objectMode:!0,...r,read(){this.push(t),this.push(null)}});if(t&&t[i])l=!0,u=t[i]();else{if(!t||!t[a])throw new c("iterable",["Iterable"],t);l=!1,u=t[a]()}const p=new e({objectMode:!0,highWaterMark:1,...r});let d=!1;return p._read=function(){d||(d=!0,async function(){for(;;){try{const{value:e,done:t}=l?await u.next():u.next();if(t)p.push(null);else{const t=e&&"function"==typeof e.then?await e:e;if(null===t)throw d=!1,new h;if(p.push(t))continue;d=!1}}catch(e){p.destroy(e)}break}}())},p._destroy=function(e,t){o(async function(e){const t=null!=e,r="function"==typeof u.throw;if(t&&r){const{value:t,done:r}=await u.throw(e);if(await t,r)return}if("function"==typeof u.return){const{value:e}=await u.return();await e}}(e),(()=>n.nextTick(t,e)),(r=>n.nextTick(t,r||e)))},p}},870:(e,t,r)=>{"use strict";const{ArrayIsArray:n,ObjectSetPrototypeOf:o}=r(61),{EventEmitter:i}=r(187);function a(e){i.call(this,e)}function s(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?n(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}o(a.prototype,i.prototype),o(a,i),a.prototype.pipe=function(e,t){const r=this;function n(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",n),e.on("drain",o),e._isStdio||t&&!1===t.end||(r.on("end",c),r.on("close",h));let a=!1;function c(){a||(a=!0,e.end())}function h(){a||(a=!0,"function"==typeof e.destroy&&e.destroy())}function u(e){l(),0===i.listenerCount(this,"error")&&this.emit("error",e)}function l(){r.removeListener("data",n),e.removeListener("drain",o),r.removeListener("end",c),r.removeListener("close",h),r.removeListener("error",u),e.removeListener("error",u),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return s(r,"error",u),s(e,"error",u),r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e},e.exports={Stream:a,prependListener:s}},382:(e,t,r)=>{"use strict";const n=globalThis.AbortController||r(599).AbortController,{codes:{ERR_INVALID_ARG_TYPE:o,ERR_MISSING_ARGS:i,ERR_OUT_OF_RANGE:a},AbortError:s}=r(381),{validateAbortSignal:c,validateInteger:h,validateObject:u}=r(547),l=r(61).Symbol("kWeak"),{finished:p}=r(610),{ArrayPrototypePush:d,MathFloor:f,Number:g,NumberIsNaN:m,Promise:y,PromiseReject:w,PromisePrototypeThen:b,Symbol:v}=r(61),_=v("kEmpty"),S=v("kEof");function A(e,t){if("function"!=typeof e)throw new o("fn",["Function","AsyncFunction"],e);null!=t&&u(t,"options"),null!=(null==t?void 0:t.signal)&&c(t.signal,"options.signal");let r=1;return null!=(null==t?void 0:t.concurrency)&&(r=f(t.concurrency)),h(r,"concurrency",1),async function*(){var o,i;const a=new n,c=this,h=[],u=a.signal,l={signal:u},p=()=>a.abort();let d,f;null!=t&&null!==(o=t.signal)&&void 0!==o&&o.aborted&&p(),null==t||null===(i=t.signal)||void 0===i||i.addEventListener("abort",p);let g=!1;function m(){g=!0}!async function(){try{for await(let t of c){var n;if(g)return;if(u.aborted)throw new s;try{t=e(t,l)}catch(e){t=w(e)}t!==_&&("function"==typeof(null===(n=t)||void 0===n?void 0:n.catch)&&t.catch(m),h.push(t),d&&(d(),d=null),!g&&h.length&&h.length>=r&&await new y((e=>{f=e})))}h.push(S)}catch(e){const t=w(e);b(t,void 0,m),h.push(t)}finally{var o;g=!0,d&&(d(),d=null),null==t||null===(o=t.signal)||void 0===o||o.removeEventListener("abort",p)}}();try{for(;;){for(;h.length>0;){const e=await h[0];if(e===S)return;if(u.aborted)throw new s;e!==_&&(yield e),h.shift(),f&&(f(),f=null)}await new y((e=>{d=e}))}}finally{a.abort(),g=!0,f&&(f(),f=null)}}.call(this)}async function E(e,t){for await(const r of x.call(this,e,t))return!0;return!1}function x(e,t){if("function"!=typeof e)throw new o("fn",["Function","AsyncFunction"],e);return A.call(this,(async function(t,r){return await e(t,r)?t:_}),t)}class R extends i{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}}function C(e){if(e=g(e),m(e))return 0;if(e<0)throw new a("number",">= 0",e);return e}e.exports.streamReturningOperators={asIndexedPairs:function(e){return null!=e&&u(e,"options"),null!=(null==e?void 0:e.signal)&&c(e.signal,"options.signal"),async function*(){let t=0;for await(const n of this){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new s({cause:e.signal.reason});yield[t++,n]}}.call(this)},drop:function(e,t){return null!=t&&u(t,"options"),null!=(null==t?void 0:t.signal)&&c(t.signal,"options.signal"),e=C(e),async function*(){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new s;for await(const r of this){var n;if(null!=t&&null!==(n=t.signal)&&void 0!==n&&n.aborted)throw new s;e--<=0&&(yield r)}}.call(this)},filter:x,flatMap:function(e,t){const r=A.call(this,e,t);return async function*(){for await(const e of r)yield*e}.call(this)},map:A,take:function(e,t){return null!=t&&u(t,"options"),null!=(null==t?void 0:t.signal)&&c(t.signal,"options.signal"),e=C(e),async function*(){var r;if(null!=t&&null!==(r=t.signal)&&void 0!==r&&r.aborted)throw new s;for await(const r of this){var n;if(null!=t&&null!==(n=t.signal)&&void 0!==n&&n.aborted)throw new s;if(!(e-- >0))return;yield r}}.call(this)}},e.exports.promiseReturningOperators={every:async function(e,t){if("function"!=typeof e)throw new o("fn",["Function","AsyncFunction"],e);return!await E.call(this,(async(...t)=>!await e(...t)),t)},forEach:async function(e,t){if("function"!=typeof e)throw new o("fn",["Function","AsyncFunction"],e);for await(const r of A.call(this,(async function(t,r){return await e(t,r),_}),t));},reduce:async function(e,t,r){var i;if("function"!=typeof e)throw new o("reducer",["Function","AsyncFunction"],e);null!=r&&u(r,"options"),null!=(null==r?void 0:r.signal)&&c(r.signal,"options.signal");let a=arguments.length>1;if(null!=r&&null!==(i=r.signal)&&void 0!==i&&i.aborted){const e=new s(void 0,{cause:r.signal.reason});throw this.once("error",(()=>{})),await p(this.destroy(e)),e}const h=new n,d=h.signal;if(null!=r&&r.signal){const e={once:!0,[l]:this};r.signal.addEventListener("abort",(()=>h.abort()),e)}let f=!1;try{for await(const n of this){var g;if(f=!0,null!=r&&null!==(g=r.signal)&&void 0!==g&&g.aborted)throw new s;a?t=await e(t,n,{signal:d}):(t=n,a=!0)}if(!f&&!a)throw new R}finally{h.abort()}return t},toArray:async function(e){null!=e&&u(e,"options"),null!=(null==e?void 0:e.signal)&&c(e.signal,"options.signal");const t=[];for await(const n of this){var r;if(null!=e&&null!==(r=e.signal)&&void 0!==r&&r.aborted)throw new s(void 0,{cause:e.signal.reason});d(t,n)}return t},some:E,find:async function(e,t){for await(const r of x.call(this,e,t))return r}}},917:(e,t,r)=>{"use strict";const{ObjectSetPrototypeOf:n}=r(61);e.exports=i;const o=r(161);function i(e){if(!(this instanceof i))return new i(e);o.call(this,e)}n(i.prototype,o.prototype),n(i,o),i.prototype._transform=function(e,t,r){r(null,e)}},946:(e,t,r)=>{const n=r(155),{ArrayIsArray:o,Promise:i,SymbolAsyncIterator:a}=r(61),s=r(610),{once:c}=r(87),h=r(195),u=r(672),{aggregateTwoErrors:l,codes:{ERR_INVALID_ARG_TYPE:p,ERR_INVALID_RETURN_VALUE:d,ERR_MISSING_ARGS:f,ERR_STREAM_DESTROYED:g,ERR_STREAM_PREMATURE_CLOSE:m},AbortError:y}=r(381),{validateFunction:w,validateAbortSignal:b}=r(547),{isIterable:v,isReadable:_,isReadableNodeStream:S,isNodeStream:A}=r(874),E=globalThis.AbortController||r(599).AbortController;let x,R;function C(e,t,r){let n=!1;return e.on("close",(()=>{n=!0})),{destroy:t=>{n||(n=!0,h.destroyer(e,t||new g("pipe")))},cleanup:s(e,{readable:t,writable:r},(e=>{n=!e}))}}function T(e){if(v(e))return e;if(S(e))return async function*(e){R||(R=r(911)),yield*R.prototype[a].call(e)}(e);throw new p("val",["Readable","Iterable","AsyncIterable"],e)}async function O(e,t,r,{end:n}){let o,a=null;const c=e=>{if(e&&(o=e),a){const e=a;a=null,e()}},h=()=>new i(((e,t)=>{o?t(o):a=()=>{o?t(o):e()}}));t.on("drain",c);const u=s(t,{readable:!1},c);try{t.writableNeedDrain&&await h();for await(const r of e)t.write(r)||await h();n&&t.end(),await h(),r()}catch(e){r(o!==e?l(o,e):e)}finally{u(),t.off("drain",c)}}function P(e,t,i){if(1===e.length&&o(e[0])&&(e=e[0]),e.length<2)throw new f("streams");const a=new E,s=a.signal,c=null==i?void 0:i.signal,h=[];function l(){j(new y)}let g,m;b(c,"options.signal"),null==c||c.addEventListener("abort",l);const w=[];let R,P=0;function k(e){j(e,0==--P)}function j(e,r){if(!e||g&&"ERR_STREAM_PREMATURE_CLOSE"!==g.code||(g=e),g||r){for(;w.length;)w.shift()(g);null==c||c.removeEventListener("abort",l),a.abort(),r&&(g||h.forEach((e=>e())),n.nextTick(t,g,m))}}for(let N=0;N0,F=M||!1!==(null==i?void 0:i.end),q=N===e.length-1;if(A(L)){if(F){const{destroy:$,cleanup:H}=C(L,M,U);w.push($),_(L)&&q&&h.push(H)}function D(e){e&&"AbortError"!==e.name&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code&&k(e)}L.on("error",D),_(L)&&q&&h.push((()=>{L.removeListener("error",D)}))}if(0===N)if("function"==typeof L){if(R=L({signal:s}),!v(R))throw new d("Iterable, AsyncIterable or Stream","source",R)}else R=v(L)||S(L)?L:u.from(L);else if("function"==typeof L)if(R=T(R),R=L(R,{signal:s}),M){if(!v(R,!0))throw new d("AsyncIterable",`transform[${N-1}]`,R)}else{var B;x||(x=r(917));const W=new x({objectMode:!0}),G=null===(B=R)||void 0===B?void 0:B.then;if("function"==typeof G)P++,G.call(R,(e=>{m=e,null!=e&&W.write(e),F&&W.end(),n.nextTick(k)}),(e=>{W.destroy(e),n.nextTick(k,e)}));else{if(!v(R,!0))throw new d("AsyncIterable or Promise","destination",R);P++,O(R,W,k,{end:F})}R=W;const{destroy:z,cleanup:K}=C(R,!1,!0);w.push(z),q&&h.push(K)}else if(A(L)){if(S(R)){P+=2;const V=I(R,L,k,{end:F});_(L)&&q&&h.push(V)}else{if(!v(R))throw new p("val",["Readable","Iterable","AsyncIterable"],R);P++,O(R,L,k,{end:F})}R=L}else R=u.from(L)}return(null!=s&&s.aborted||null!=c&&c.aborted)&&n.nextTick(l),R}function I(e,t,r,{end:n}){let o=!1;return t.on("close",(()=>{o||r(new m)})),e.pipe(t,{end:n}),n?e.once("end",(()=>{o=!0,t.end()})):r(),s(e,{readable:!0,writable:!1},(t=>{const n=e._readableState;t&&"ERR_STREAM_PREMATURE_CLOSE"===t.code&&n&&n.ended&&!n.errored&&!n.errorEmitted?e.once("end",r).once("error",r):r(t)})),s(t,{readable:!1,writable:!0},r)}e.exports={pipelineImpl:P,pipeline:function(...e){return P(e,c(function(e){return w(e[e.length-1],"streams[stream.length - 1]"),e.pop()}(e)))}}},911:(e,t,r)=>{const n=r(155),{ArrayPrototypeIndexOf:o,NumberIsInteger:i,NumberIsNaN:a,NumberParseInt:s,ObjectDefineProperties:c,ObjectKeys:h,ObjectSetPrototypeOf:u,Promise:l,SafeSet:p,SymbolAsyncIterator:d,Symbol:f}=r(61);e.exports=U,U.ReadableState=M;const{EventEmitter:g}=r(187),{Stream:m,prependListener:y}=r(870),{Buffer:w}=r(764),{addAbortSignal:b}=r(196),v=r(610);let _=r(87).debuglog("stream",(e=>{_=e}));const S=r(327),A=r(195),{getHighWaterMark:E,getDefaultHighWaterMark:x}=r(457),{aggregateTwoErrors:R,codes:{ERR_INVALID_ARG_TYPE:C,ERR_METHOD_NOT_IMPLEMENTED:T,ERR_OUT_OF_RANGE:O,ERR_STREAM_PUSH_AFTER_EOF:P,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:I}}=r(381),{validateObject:k}=r(547),j=f("kPaused"),{StringDecoder:D}=r(553),B=r(307);u(U.prototype,m.prototype),u(U,m);const N=()=>{},{errorOrDestroy:L}=A;function M(e,t,n){"boolean"!=typeof n&&(n=t instanceof r(672)),this.objectMode=!(!e||!e.objectMode),n&&(this.objectMode=this.objectMode||!(!e||!e.readableObjectMode)),this.highWaterMark=e?E(this,e,"readableHighWaterMark",n):x(!1),this.buffer=new S,this.length=0,this.pipes=[],this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.constructed=!0,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this[j]=null,this.errorEmitted=!1,this.emitClose=!e||!1!==e.emitClose,this.autoDestroy=!e||!1!==e.autoDestroy,this.destroyed=!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this.defaultEncoding=e&&e.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.multiAwaitDrain=!1,this.readingMore=!1,this.dataEmitted=!1,this.decoder=null,this.encoding=null,e&&e.encoding&&(this.decoder=new D(e.encoding),this.encoding=e.encoding)}function U(e){if(!(this instanceof U))return new U(e);const t=this instanceof r(672);this._readableState=new M(e,this,t),e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.construct&&(this._construct=e.construct),e.signal&&!t&&b(e.signal,this)),m.call(this,e),A.construct(this,(()=>{this._readableState.needReadable&&G(this,this._readableState)}))}function F(e,t,r,n){_("readableAddChunk",t);const o=e._readableState;let i;if(o.objectMode||("string"==typeof t?(r=r||o.defaultEncoding,o.encoding!==r&&(n&&o.encoding?t=w.from(t,r).toString(o.encoding):(t=w.from(t,r),r=""))):t instanceof w?r="":m._isUint8Array(t)?(t=m._uint8ArrayToBuffer(t),r=""):null!=t&&(i=new C("chunk",["string","Buffer","Uint8Array"],t))),i)L(e,i);else if(null===t)o.reading=!1,function(e,t){if(_("onEofChunk"),!t.ended){if(t.decoder){const e=t.decoder.end();e&&e.length&&(t.buffer.push(e),t.length+=t.objectMode?1:e.length)}t.ended=!0,t.sync?H(e):(t.needReadable=!1,t.emittedReadable=!0,W(e))}}(e,o);else if(o.objectMode||t&&t.length>0)if(n)if(o.endEmitted)L(e,new I);else{if(o.destroyed||o.errored)return!1;q(e,o,t,!0)}else if(o.ended)L(e,new P);else{if(o.destroyed||o.errored)return!1;o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||0!==t.length?q(e,o,t,!1):G(e,o)):q(e,o,t,!1)}else n||(o.reading=!1,G(e,o));return!o.ended&&(o.length0?(t.multiAwaitDrain?t.awaitDrainWriters.clear():t.awaitDrainWriters=null,t.dataEmitted=!0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&H(e)),G(e,t)}U.prototype.destroy=A.destroy,U.prototype._undestroy=A.undestroy,U.prototype._destroy=function(e,t){t(e)},U.prototype[g.captureRejectionSymbol]=function(e){this.destroy(e)},U.prototype.push=function(e,t){return F(this,e,t,!1)},U.prototype.unshift=function(e,t){return F(this,e,t,!0)},U.prototype.isPaused=function(){const e=this._readableState;return!0===e[j]||!1===e.flowing},U.prototype.setEncoding=function(e){const t=new D(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;const r=this._readableState.buffer;let n="";for(const e of r)n+=t.write(e);return r.clear(),""!==n&&r.push(n),this._readableState.length=n.length,this};function $(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:a(e)?t.flowing&&t.length?t.buffer.first().length:t.length:e<=t.length?e:t.ended?t.length:0}function H(e){const t=e._readableState;_("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(_("emitReadable",t.flowing),t.emittedReadable=!0,n.nextTick(W,e))}function W(e){const t=e._readableState;_("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||t.errored||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,Q(e)}function G(e,t){!t.readingMore&&t.constructed&&(t.readingMore=!0,n.nextTick(z,e,t))}function z(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!1===t[j]?t.flowing=!0:e.listenerCount("data")>0?e.resume():t.readableListening||(t.flowing=null)}function V(e){_("readable nexttick read 0"),e.read(0)}function Y(e,t){_("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),Q(e),t.flowing&&!t.reading&&e.read(0)}function Q(e){const t=e._readableState;for(_("flow",t.flowing);t.flowing&&null!==e.read(););}function J(e,t){"function"!=typeof e.read&&(e=U.wrap(e,{objectMode:!0}));const r=async function*(e,t){let r,n=N;function o(t){this===e?(n(),n=N):n=t}e.on("readable",o);const i=v(e,{writable:!1},(e=>{r=e?R(r,e):null,n(),n=N}));try{for(;;){const t=e.destroyed?null:e.read();if(null!==t)yield t;else{if(r)throw r;if(null===r)return;await new l(o)}}}catch(e){throw r=R(r,e),r}finally{!r&&!1===(null==t?void 0:t.destroyOnReturn)||void 0!==r&&!e._readableState.autoDestroy?(e.off("readable",o),i()):A.destroyer(e,null)}}(e,t);return r.stream=e,r}function Z(e,t){if(0===t.length)return null;let r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r}function X(e){const t=e._readableState;_("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,n.nextTick(ee,t,e))}function ee(e,t){if(_("endReadableNT",e.endEmitted,e.length),!e.errored&&!e.closeEmitted&&!e.endEmitted&&0===e.length)if(e.endEmitted=!0,t.emit("end"),t.writable&&!1===t.allowHalfOpen)n.nextTick(te,t);else if(e.autoDestroy){const e=t._writableState;(!e||e.autoDestroy&&(e.finished||!1===e.writable))&&t.destroy()}}function te(e){e.writable&&!e.writableEnded&&!e.destroyed&&e.end()}let re;function ne(){return void 0===re&&(re={}),re}U.prototype.read=function(e){_("read",e),void 0===e?e=NaN:i(e)||(e=s(e,10));const t=this._readableState,r=e;if(e>t.highWaterMark&&(t.highWaterMark=function(e){if(e>1073741824)throw new O("size","<= 1GiB",e);return e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,++e}(e)),0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&((0!==t.highWaterMark?t.length>=t.highWaterMark:t.length>0)||t.ended))return _("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?X(this):H(this),null;if(0===(e=$(e,t))&&t.ended)return 0===t.length&&X(this),null;let n,o=t.needReadable;if(_("need readable",o),(0===t.length||t.length-e0?Z(e,t):null,null===n?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.multiAwaitDrain?t.awaitDrainWriters.clear():t.awaitDrainWriters=null),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&X(this)),null===n||t.errorEmitted||t.closeEmitted||(t.dataEmitted=!0,this.emit("data",n)),n},U.prototype._read=function(e){throw new T("_read()")},U.prototype.pipe=function(e,t){const r=this,o=this._readableState;1===o.pipes.length&&(o.multiAwaitDrain||(o.multiAwaitDrain=!0,o.awaitDrainWriters=new p(o.awaitDrainWriters?[o.awaitDrainWriters]:[]))),o.pipes.push(e),_("pipe count=%d opts=%j",o.pipes.length,t);const i=t&&!1===t.end||e===n.stdout||e===n.stderr?g:a;function a(){_("onend"),e.end()}let s;o.endEmitted?n.nextTick(i):r.once("end",i),e.on("unpipe",(function t(n,i){_("onunpipe"),n===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,_("cleanup"),e.removeListener("close",d),e.removeListener("finish",f),s&&e.removeListener("drain",s),e.removeListener("error",l),e.removeListener("unpipe",t),r.removeListener("end",a),r.removeListener("end",g),r.removeListener("data",u),c=!0,s&&o.awaitDrainWriters&&(!e._writableState||e._writableState.needDrain)&&s())}));let c=!1;function h(){c||(1===o.pipes.length&&o.pipes[0]===e?(_("false write response, pause",0),o.awaitDrainWriters=e,o.multiAwaitDrain=!1):o.pipes.length>1&&o.pipes.includes(e)&&(_("false write response, pause",o.awaitDrainWriters.size),o.awaitDrainWriters.add(e)),r.pause()),s||(s=function(e,t){return function(){const r=e._readableState;r.awaitDrainWriters===t?(_("pipeOnDrain",1),r.awaitDrainWriters=null):r.multiAwaitDrain&&(_("pipeOnDrain",r.awaitDrainWriters.size),r.awaitDrainWriters.delete(t)),r.awaitDrainWriters&&0!==r.awaitDrainWriters.size||!e.listenerCount("data")||e.resume()}}(r,e),e.on("drain",s))}function u(t){_("ondata");const r=e.write(t);_("dest.write",r),!1===r&&h()}function l(t){if(_("onerror",t),g(),e.removeListener("error",l),0===e.listenerCount("error")){const r=e._writableState||e._readableState;r&&!r.errorEmitted?L(e,t):e.emit("error",t)}}function d(){e.removeListener("finish",f),g()}function f(){_("onfinish"),e.removeListener("close",d),g()}function g(){_("unpipe"),r.unpipe(e)}return r.on("data",u),y(e,"error",l),e.once("close",d),e.once("finish",f),e.emit("pipe",r),!0===e.writableNeedDrain?o.flowing&&h():o.flowing||(_("pipe resume"),r.resume()),e},U.prototype.unpipe=function(e){const t=this._readableState;if(0===t.pipes.length)return this;if(!e){const e=t.pipes;t.pipes=[],this.pause();for(let t=0;t0,!1!==o.flowing&&this.resume()):"readable"===e&&(o.endEmitted||o.readableListening||(o.readableListening=o.needReadable=!0,o.flowing=!1,o.emittedReadable=!1,_("on readable",o.length,o.reading),o.length?H(this):o.reading||n.nextTick(V,this))),r},U.prototype.addListener=U.prototype.on,U.prototype.removeListener=function(e,t){const r=m.prototype.removeListener.call(this,e,t);return"readable"===e&&n.nextTick(K,this),r},U.prototype.off=U.prototype.removeListener,U.prototype.removeAllListeners=function(e){const t=m.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||n.nextTick(K,this),t},U.prototype.resume=function(){const e=this._readableState;return e.flowing||(_("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,n.nextTick(Y,e,t))}(this,e)),e[j]=!1,this},U.prototype.pause=function(){return _("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(_("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[j]=!0,this},U.prototype.wrap=function(e){let t=!1;e.on("data",(r=>{!this.push(r)&&e.pause&&(t=!0,e.pause())})),e.on("end",(()=>{this.push(null)})),e.on("error",(e=>{L(this,e)})),e.on("close",(()=>{this.destroy()})),e.on("destroy",(()=>{this.destroy()})),this._read=()=>{t&&e.resume&&(t=!1,e.resume())};const r=h(e);for(let t=1;t{"use strict";const{MathFloor:n,NumberIsInteger:o}=r(61),{ERR_INVALID_ARG_VALUE:i}=r(381).codes;function a(e){return e?16:16384}e.exports={getHighWaterMark:function(e,t,r,s){const c=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,s,r);if(null!=c){if(!o(c)||c<0)throw new i(s?`options.${r}`:"options.highWaterMark",c);return n(c)}return a(e.objectMode)},getDefaultHighWaterMark:a}},161:(e,t,r)=>{"use strict";const{ObjectSetPrototypeOf:n,Symbol:o}=r(61);e.exports=h;const{ERR_METHOD_NOT_IMPLEMENTED:i}=r(381).codes,a=r(672),{getHighWaterMark:s}=r(457);n(h.prototype,a.prototype),n(h,a);const c=o("kCallback");function h(e){if(!(this instanceof h))return new h(e);const t=e?s(this,e,"readableHighWaterMark",!0):null;0===t&&(e={...e,highWaterMark:null,readableHighWaterMark:t,writableHighWaterMark:e.writableHighWaterMark||0}),a.call(this,e),this._readableState.sync=!1,this[c]=null,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",l)}function u(e){"function"!=typeof this._flush||this.destroyed?(this.push(null),e&&e()):this._flush(((t,r)=>{t?e?e(t):this.destroy(t):(null!=r&&this.push(r),this.push(null),e&&e())}))}function l(){this._final!==u&&u.call(this)}h.prototype._final=u,h.prototype._transform=function(e,t,r){throw new i("_transform()")},h.prototype._write=function(e,t,r){const n=this._readableState,o=this._writableState,i=n.length;this._transform(e,t,((e,t)=>{e?r(e):(null!=t&&this.push(t),o.ended||i===n.length||n.length{"use strict";const{Symbol:n,SymbolAsyncIterator:o,SymbolIterator:i}=r(61),a=n("kDestroyed"),s=n("kIsErrored"),c=n("kIsReadable"),h=n("kIsDisturbed");function u(e,t=!1){var r;return!(!e||"function"!=typeof e.pipe||"function"!=typeof e.on||t&&("function"!=typeof e.pause||"function"!=typeof e.resume)||e._writableState&&!1===(null===(r=e._readableState)||void 0===r?void 0:r.readable)||e._writableState&&!e._readableState)}function l(e){var t;return!(!e||"function"!=typeof e.write||"function"!=typeof e.on||e._readableState&&!1===(null===(t=e._writableState)||void 0===t?void 0:t.writable))}function p(e){return e&&(e._readableState||e._writableState||"function"==typeof e.write&&"function"==typeof e.on||"function"==typeof e.pipe&&"function"==typeof e.on)}function d(e){if(!p(e))return null;const t=e._writableState,r=e._readableState,n=t||r;return!!(e.destroyed||e[a]||null!=n&&n.destroyed)}function f(e){if(!l(e))return null;if(!0===e.writableEnded)return!0;const t=e._writableState;return(null==t||!t.errored)&&("boolean"!=typeof(null==t?void 0:t.ended)?null:t.ended)}function g(e,t){if(!u(e))return null;const r=e._readableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.endEmitted)?null:!!(r.endEmitted||!1===t&&!0===r.ended&&0===r.length))}function m(e){return e&&null!=e[c]?e[c]:"boolean"!=typeof(null==e?void 0:e.readable)?null:!d(e)&&u(e)&&e.readable&&!g(e)}function y(e){return"boolean"!=typeof(null==e?void 0:e.writable)?null:!d(e)&&l(e)&&e.writable&&!f(e)}function w(e){return"boolean"==typeof e._closed&&"boolean"==typeof e._defaultKeepAlive&&"boolean"==typeof e._removedConnection&&"boolean"==typeof e._removedContLen}function b(e){return"boolean"==typeof e._sent100&&w(e)}e.exports={kDestroyed:a,isDisturbed:function(e){var t;return!(!e||!(null!==(t=e[h])&&void 0!==t?t:e.readableDidRead||e.readableAborted))},kIsDisturbed:h,isErrored:function(e){var t,r,n,o,i,a,c,h,u,l;return!(!e||!(null!==(t=null!==(r=null!==(n=null!==(o=null!==(i=null!==(a=e[s])&&void 0!==a?a:e.readableErrored)&&void 0!==i?i:e.writableErrored)&&void 0!==o?o:null===(c=e._readableState)||void 0===c?void 0:c.errorEmitted)&&void 0!==n?n:null===(h=e._writableState)||void 0===h?void 0:h.errorEmitted)&&void 0!==r?r:null===(u=e._readableState)||void 0===u?void 0:u.errored)&&void 0!==t?t:null===(l=e._writableState)||void 0===l?void 0:l.errored))},kIsErrored:s,isReadable:m,kIsReadable:c,isClosed:function(e){if(!p(e))return null;if("boolean"==typeof e.closed)return e.closed;const t=e._writableState,r=e._readableState;return"boolean"==typeof(null==t?void 0:t.closed)||"boolean"==typeof(null==r?void 0:r.closed)?(null==t?void 0:t.closed)||(null==r?void 0:r.closed):"boolean"==typeof e._closed&&w(e)?e._closed:null},isDestroyed:d,isDuplexNodeStream:function(e){return!(!e||"function"!=typeof e.pipe||!e._readableState||"function"!=typeof e.on||"function"!=typeof e.write)},isFinished:function(e,t){return p(e)?!(!d(e)&&(!1!==(null==t?void 0:t.readable)&&m(e)||!1!==(null==t?void 0:t.writable)&&y(e))):null},isIterable:function(e,t){return null!=e&&(!0===t?"function"==typeof e[o]:!1===t?"function"==typeof e[i]:"function"==typeof e[o]||"function"==typeof e[i])},isReadableNodeStream:u,isReadableEnded:function(e){if(!u(e))return null;if(!0===e.readableEnded)return!0;const t=e._readableState;return!(!t||t.errored)&&("boolean"!=typeof(null==t?void 0:t.ended)?null:t.ended)},isReadableFinished:g,isReadableErrored:function(e){var t,r;return p(e)?e.readableErrored?e.readableErrored:null!==(t=null===(r=e._readableState)||void 0===r?void 0:r.errored)&&void 0!==t?t:null:null},isNodeStream:p,isWritable:y,isWritableNodeStream:l,isWritableEnded:f,isWritableFinished:function(e,t){if(!l(e))return null;if(!0===e.writableFinished)return!0;const r=e._writableState;return(null==r||!r.errored)&&("boolean"!=typeof(null==r?void 0:r.finished)?null:!!(r.finished||!1===t&&!0===r.ended&&0===r.length))},isWritableErrored:function(e){var t,r;return p(e)?e.writableErrored?e.writableErrored:null!==(t=null===(r=e._writableState)||void 0===r?void 0:r.errored)&&void 0!==t?t:null:null},isServerRequest:function(e){var t;return"boolean"==typeof e._consuming&&"boolean"==typeof e._dumped&&void 0===(null===(t=e.req)||void 0===t?void 0:t.upgradeOrConnect)},isServerResponse:b,willEmitClose:function(e){if(!p(e))return null;const t=e._writableState,r=e._readableState,n=t||r;return!n&&b(e)||!!(n&&n.autoDestroy&&n.emitClose&&!1===n.closed)}}},304:(e,t,r)=>{const n=r(155),{ArrayPrototypeSlice:o,Error:i,FunctionPrototypeSymbolHasInstance:a,ObjectDefineProperty:s,ObjectDefineProperties:c,ObjectSetPrototypeOf:h,StringPrototypeToLowerCase:u,Symbol:l,SymbolHasInstance:p}=r(61);e.exports=D,D.WritableState=k;const{EventEmitter:d}=r(187),f=r(870).Stream,{Buffer:g}=r(764),m=r(195),{addAbortSignal:y}=r(196),{getHighWaterMark:w,getDefaultHighWaterMark:b}=r(457),{ERR_INVALID_ARG_TYPE:v,ERR_METHOD_NOT_IMPLEMENTED:_,ERR_MULTIPLE_CALLBACK:S,ERR_STREAM_CANNOT_PIPE:A,ERR_STREAM_DESTROYED:E,ERR_STREAM_ALREADY_FINISHED:x,ERR_STREAM_NULL_VALUES:R,ERR_STREAM_WRITE_AFTER_END:C,ERR_UNKNOWN_ENCODING:T}=r(381).codes,{errorOrDestroy:O}=m;function P(){}h(D.prototype,f.prototype),h(D,f);const I=l("kOnFinished");function k(e,t,n){"boolean"!=typeof n&&(n=t instanceof r(672)),this.objectMode=!(!e||!e.objectMode),n&&(this.objectMode=this.objectMode||!(!e||!e.writableObjectMode)),this.highWaterMark=e?w(this,e,"writableHighWaterMark",n):b(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;const o=!(!e||!1!==e.decodeStrings);this.decodeStrings=!o,this.defaultEncoding=e&&e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=M.bind(void 0,t),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,j(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!e||!1!==e.emitClose,this.autoDestroy=!e||!1!==e.autoDestroy,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[I]=[]}function j(e){e.buffered=[],e.bufferedIndex=0,e.allBuffers=!0,e.allNoop=!0}function D(e){const t=this instanceof r(672);if(!t&&!a(D,this))return new D(e);this._writableState=new k(e,this,t),e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final),"function"==typeof e.construct&&(this._construct=e.construct),e.signal&&y(e.signal,this)),f.call(this,e),m.construct(this,(()=>{const e=this._writableState;e.writing||$(this,e),W(this,e)}))}function B(e,t,r,o){const i=e._writableState;if("function"==typeof r)o=r,r=i.defaultEncoding;else{if(r){if("buffer"!==r&&!g.isEncoding(r))throw new T(r)}else r=i.defaultEncoding;"function"!=typeof o&&(o=P)}if(null===t)throw new R;if(!i.objectMode)if("string"==typeof t)!1!==i.decodeStrings&&(t=g.from(t,r),r="buffer");else if(t instanceof g)r="buffer";else{if(!f._isUint8Array(t))throw new v("chunk",["string","Buffer","Uint8Array"],t);t=f._uint8ArrayToBuffer(t),r="buffer"}let a;return i.ending?a=new C:i.destroyed&&(a=new E("write")),a?(n.nextTick(o,a),O(e,a,!0),a):(i.pendingcb++,function(e,t,r,n,o){const i=t.objectMode?1:r.length;t.length+=i;const a=t.lengthr.bufferedIndex&&$(e,r),o?null!==r.afterWriteTickInfo&&r.afterWriteTickInfo.cb===i?r.afterWriteTickInfo.count++:(r.afterWriteTickInfo={count:1,cb:i,stream:e,state:r},n.nextTick(U,r.afterWriteTickInfo)):F(e,r,1,i))):O(e,new S)}function U({stream:e,state:t,count:r,cb:n}){return t.afterWriteTickInfo=null,F(e,t,r,n)}function F(e,t,r,n){for(!t.ending&&!e.destroyed&&0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"));r-- >0;)t.pendingcb--,n();t.destroyed&&q(t),W(e,t)}function q(e){if(e.writing)return;for(let r=e.bufferedIndex;r1&&e._writev){t.pendingcb-=a-1;const n=t.allNoop?P:e=>{for(let t=s;t256?(r.splice(0,s),t.bufferedIndex=0):t.bufferedIndex=s}t.bufferProcessing=!1}function H(e){return e.ending&&!e.destroyed&&e.constructed&&0===e.length&&!e.errored&&0===e.buffered.length&&!e.finished&&!e.writing&&!e.errorEmitted&&!e.closeEmitted}function W(e,t,r){H(t)&&(function(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.finalCalled=!0,function(e,t){let r=!1;function o(o){if(r)O(e,null!=o?o:S());else if(r=!0,t.pendingcb--,o){const r=t[I].splice(0);for(let e=0;e{H(t)?G(e,t):t.pendingcb--}),e,t)):H(t)&&(t.pendingcb++,G(e,t))))}function G(e,t){t.pendingcb--,t.finished=!0;const r=t[I].splice(0);for(let e=0;e{"use strict";const{ArrayIsArray:n,ArrayPrototypeIncludes:o,ArrayPrototypeJoin:i,ArrayPrototypeMap:a,NumberIsInteger:s,NumberIsNaN:c,NumberMAX_SAFE_INTEGER:h,NumberMIN_SAFE_INTEGER:u,NumberParseInt:l,ObjectPrototypeHasOwnProperty:p,RegExpPrototypeExec:d,String:f,StringPrototypeToUpperCase:g,StringPrototypeTrim:m}=r(61),{hideStackFrames:y,codes:{ERR_SOCKET_BAD_PORT:w,ERR_INVALID_ARG_TYPE:b,ERR_INVALID_ARG_VALUE:v,ERR_OUT_OF_RANGE:_,ERR_UNKNOWN_SIGNAL:S}}=r(381),{normalizeEncoding:A}=r(87),{isAsyncFunction:E,isArrayBufferView:x}=r(87).types,R={},C=/^[0-7]+$/,T=y(((e,t,r=u,n=h)=>{if("number"!=typeof e)throw new b(t,"number",e);if(!s(e))throw new _(t,"an integer",e);if(en)throw new _(t,`>= ${r} && <= ${n}`,e)})),O=y(((e,t,r=-2147483648,n=2147483647)=>{if("number"!=typeof e)throw new b(t,"number",e);if(!s(e))throw new _(t,"an integer",e);if(en)throw new _(t,`>= ${r} && <= ${n}`,e)})),P=y(((e,t,r=!1)=>{if("number"!=typeof e)throw new b(t,"number",e);if(!s(e))throw new _(t,"an integer",e);const n=r?1:0,o=4294967295;if(eo)throw new _(t,`>= ${n} && <= ${o}`,e)}));function I(e,t){if("string"!=typeof e)throw new b(t,"string",e)}const k=y(((e,t,r)=>{if(!o(r,e)){const n=i(a(r,(e=>"string"==typeof e?`'${e}'`:f(e))),", ");throw new v(t,e,"must be one of: "+n)}}));function j(e,t,r){return null!=e&&p(e,t)?e[t]:r}const D=y(((e,t,r=null)=>{const o=j(r,"allowArray",!1),i=j(r,"allowFunction",!1);if(!j(r,"nullable",!1)&&null===e||!o&&n(e)||"object"!=typeof e&&(!i||"function"!=typeof e))throw new b(t,"Object",e)})),B=y(((e,t,r=0)=>{if(!n(e))throw new b(t,"Array",e);if(e.length{if(!x(e))throw new b(t,["Buffer","TypedArray","DataView"],e)})),L=y(((e,t)=>{if(void 0!==e&&(null===e||"object"!=typeof e||!("aborted"in e)))throw new b(t,"AbortSignal",e)})),M=y(((e,t)=>{if("function"!=typeof e)throw new b(t,"Function",e)})),U=y(((e,t)=>{if("function"!=typeof e||E(e))throw new b(t,"Function",e)})),F=y(((e,t)=>{if(void 0!==e)throw new b(t,"undefined",e)}));e.exports={isInt32:function(e){return e===(0|e)},isUint32:function(e){return e===e>>>0},parseFileMode:function(e,t,r){if(void 0===e&&(e=r),"string"==typeof e){if(null===d(C,e))throw new v(t,e,"must be a 32-bit unsigned integer or an octal string");e=l(e,8)}return P(e,t),e},validateArray:B,validateBoolean:function(e,t){if("boolean"!=typeof e)throw new b(t,"boolean",e)},validateBuffer:N,validateEncoding:function(e,t){const r=A(t),n=e.length;if("hex"===r&&n%2!=0)throw new v("encoding",t,`is invalid for data of length ${n}`)},validateFunction:M,validateInt32:O,validateInteger:T,validateNumber:function(e,t,r,n){if("number"!=typeof e)throw new b(t,"number",e);if(null!=r&&en||(null!=r||null!=n)&&c(e))throw new _(t,`${null!=r?`>= ${r}`:""}${null!=r&&null!=n?" && ":""}${null!=n?`<= ${n}`:""}`,e)},validateObject:D,validateOneOf:k,validatePlainFunction:U,validatePort:function(e,t="Port",r=!0){if("number"!=typeof e&&"string"!=typeof e||"string"==typeof e&&0===m(e).length||+e!=+e>>>0||e>65535||0===e&&!r)throw new w(t,e,r);return 0|e},validateSignalName:function(e,t="signal"){if(I(e,t),void 0===R[e]){if(void 0!==R[g(e)])throw new S(e+" (signals must use all capital letters)");throw new S(e)}},validateString:I,validateUint32:P,validateUndefined:F,validateUnion:function(e,t,r){if(!o(r,e))throw new b(t,`('${i(r,"|")}')`,e)},validateAbortSignal:L}},827:(e,t,r)=>{"use strict";const n=r(99),o=r(854),i=n.Readable.destroy;e.exports=n.Readable,e.exports._uint8ArrayToBuffer=n._uint8ArrayToBuffer,e.exports._isUint8Array=n._isUint8Array,e.exports.isDisturbed=n.isDisturbed,e.exports.isErrored=n.isErrored,e.exports.isReadable=n.isReadable,e.exports.Readable=n.Readable,e.exports.Writable=n.Writable,e.exports.Duplex=n.Duplex,e.exports.Transform=n.Transform,e.exports.PassThrough=n.PassThrough,e.exports.addAbortSignal=n.addAbortSignal,e.exports.finished=n.finished,e.exports.destroy=n.destroy,e.exports.destroy=i,e.exports.pipeline=n.pipeline,e.exports.compose=n.compose,Object.defineProperty(n,"promises",{configurable:!0,enumerable:!0,get:()=>o}),e.exports.Stream=n.Stream,e.exports.default=e.exports},381:(e,t,r)=>{"use strict";const{format:n,inspect:o,AggregateError:i}=r(87),a=globalThis.AggregateError||i,s=Symbol("kIsNodeError"),c=["string","function","number","object","Function","Object","boolean","bigint","symbol"],h=/^([A-Z][a-z0-9]*)+$/,u="__node_internal_",l={};function p(e,t){if(!e)throw new l.ERR_INTERNAL_ASSERTION(t)}function d(e){let t="",r=e.length;const n="-"===e[0]?1:0;for(;r>=n+4;r-=3)t=`_${e.slice(r-3,r)}${t}`;return`${e.slice(0,r)}${t}`}function f(e,t,r){r||(r=Error);class o extends r{constructor(...r){super(function(e,t,r){if("function"==typeof t)return p(t.length<=r.length,`Code: ${e}; The provided arguments length (${r.length}) does not match the required ones (${t.length}).`),t(...r);const o=(t.match(/%[dfijoOs]/g)||[]).length;return p(o===r.length,`Code: ${e}; The provided arguments length (${r.length}) does not match the required ones (${o}).`),0===r.length?t:n(t,...r)}(e,t,r))}toString(){return`${this.name} [${e}]: ${this.message}`}}Object.defineProperties(o.prototype,{name:{value:r.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${e}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),o.prototype.code=e,o.prototype[s]=!0,l[e]=o}function g(e){const t=u+e.name;return Object.defineProperty(e,"name",{value:t}),e}class m extends Error{constructor(e="The operation was aborted",t){if(void 0!==t&&"object"!=typeof t)throw new l.ERR_INVALID_ARG_TYPE("options","Object",t);super(e,t),this.code="ABORT_ERR",this.name="AbortError"}}f("ERR_ASSERTION","%s",Error),f("ERR_INVALID_ARG_TYPE",((e,t,r)=>{p("string"==typeof e,"'name' must be a string"),Array.isArray(t)||(t=[t]);let n="The ";e.endsWith(" argument")?n+=`${e} `:n+=`"${e}" ${e.includes(".")?"property":"argument"} `,n+="must be ";const i=[],a=[],s=[];for(const e of t)p("string"==typeof e,"All expected entries have to be of type string"),c.includes(e)?i.push(e.toLowerCase()):h.test(e)?a.push(e):(p("object"!==e,'The value "object" should be written as "Object"'),s.push(e));if(a.length>0){const e=i.indexOf("object");-1!==e&&(i.splice(i,e,1),a.push("Object"))}if(i.length>0){switch(i.length){case 1:n+=`of type ${i[0]}`;break;case 2:n+=`one of type ${i[0]} or ${i[1]}`;break;default:{const e=i.pop();n+=`one of type ${i.join(", ")}, or ${e}`}}(a.length>0||s.length>0)&&(n+=" or ")}if(a.length>0){switch(a.length){case 1:n+=`an instance of ${a[0]}`;break;case 2:n+=`an instance of ${a[0]} or ${a[1]}`;break;default:{const e=a.pop();n+=`an instance of ${a.join(", ")}, or ${e}`}}s.length>0&&(n+=" or ")}switch(s.length){case 0:break;case 1:s[0].toLowerCase()!==s[0]&&(n+="an "),n+=`${s[0]}`;break;case 2:n+=`one of ${s[0]} or ${s[1]}`;break;default:{const e=s.pop();n+=`one of ${s.join(", ")}, or ${e}`}}if(null==r)n+=`. Received ${r}`;else if("function"==typeof r&&r.name)n+=`. Received function ${r.name}`;else if("object"==typeof r){var u;null!==(u=r.constructor)&&void 0!==u&&u.name?n+=`. Received an instance of ${r.constructor.name}`:n+=`. Received ${o(r,{depth:-1})}`}else{let e=o(r,{colors:!1});e.length>25&&(e=`${e.slice(0,25)}...`),n+=`. Received type ${typeof r} (${e})`}return n}),TypeError),f("ERR_INVALID_ARG_VALUE",((e,t,r="is invalid")=>{let n=o(t);return n.length>128&&(n=n.slice(0,128)+"..."),`The ${e.includes(".")?"property":"argument"} '${e}' ${r}. Received ${n}`}),TypeError),f("ERR_INVALID_RETURN_VALUE",((e,t,r)=>{var n;return`Expected ${e} to be returned from the "${t}" function but got ${null!=r&&null!==(n=r.constructor)&&void 0!==n&&n.name?`instance of ${r.constructor.name}`:"type "+typeof r}.`}),TypeError),f("ERR_MISSING_ARGS",((...e)=>{let t;p(e.length>0,"At least one arg needs to be specified");const r=e.length;switch(e=(Array.isArray(e)?e:[e]).map((e=>`"${e}"`)).join(" or "),r){case 1:t+=`The ${e[0]} argument`;break;case 2:t+=`The ${e[0]} and ${e[1]} arguments`;break;default:{const r=e.pop();t+=`The ${e.join(", ")}, and ${r} arguments`}}return`${t} must be specified`}),TypeError),f("ERR_OUT_OF_RANGE",((e,t,r)=>{let n;return p(t,'Missing "range" argument'),Number.isInteger(r)&&Math.abs(r)>2**32?n=d(String(r)):"bigint"==typeof r?(n=String(r),(r>2n**32n||r<-(2n**32n))&&(n=d(n)),n+="n"):n=o(r),`The value of "${e}" is out of range. It must be ${t}. Received ${n}`}),RangeError),f("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),f("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),f("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),f("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),f("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),f("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),f("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),f("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),f("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),f("ERR_STREAM_WRITE_AFTER_END","write after end",Error),f("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),e.exports={AbortError:m,aggregateTwoErrors:g((function(e,t){if(e&&t&&e!==t){if(Array.isArray(t.errors))return t.errors.push(e),t;const r=new a([t,e],t.message);return r.code=t.code,r}return e||t})),hideStackFrames:g,codes:l}},61:e=>{"use strict";e.exports={ArrayIsArray:e=>Array.isArray(e),ArrayPrototypeIncludes:(e,t)=>e.includes(t),ArrayPrototypeIndexOf:(e,t)=>e.indexOf(t),ArrayPrototypeJoin:(e,t)=>e.join(t),ArrayPrototypeMap:(e,t)=>e.map(t),ArrayPrototypePop:(e,t)=>e.pop(t),ArrayPrototypePush:(e,t)=>e.push(t),ArrayPrototypeSlice:(e,t,r)=>e.slice(t,r),Error,FunctionPrototypeCall:(e,t,...r)=>e.call(t,...r),FunctionPrototypeSymbolHasInstance:(e,t)=>Function.prototype[Symbol.hasInstance].call(e,t),MathFloor:Math.floor,Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties:(e,t)=>Object.defineProperties(e,t),ObjectDefineProperty:(e,t,r)=>Object.defineProperty(e,t,r),ObjectGetOwnPropertyDescriptor:(e,t)=>Object.getOwnPropertyDescriptor(e,t),ObjectKeys:e=>Object.keys(e),ObjectSetPrototypeOf:(e,t)=>Object.setPrototypeOf(e,t),Promise,PromisePrototypeCatch:(e,t)=>e.catch(t),PromisePrototypeThen:(e,t,r)=>e.then(t,r),PromiseReject:e=>Promise.reject(e),ReflectApply:Reflect.apply,RegExpPrototypeTest:(e,t)=>e.test(t),SafeSet:Set,String,StringPrototypeSlice:(e,t,r)=>e.slice(t,r),StringPrototypeToLowerCase:e=>e.toLowerCase(),StringPrototypeToUpperCase:e=>e.toUpperCase(),StringPrototypeTrim:e=>e.trim(),Symbol,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,TypedArrayPrototypeSet:(e,t,r)=>e.set(t,r),Uint8Array}},87:(e,t,r)=>{"use strict";const n=r(764),o=Object.getPrototypeOf((async function(){})).constructor,i=globalThis.Blob||n.Blob,a=void 0!==i?function(e){return e instanceof i}:function(e){return!1};class s extends Error{constructor(e){if(!Array.isArray(e))throw new TypeError("Expected input to be an Array, got "+typeof e);let t="";for(let r=0;r{e=r,t=n})),resolve:e,reject:t}},promisify:e=>new Promise(((t,r)=>{e(((e,...n)=>e?r(e):t(...n)))})),debuglog:()=>function(){},format:(e,...t)=>e.replace(/%([sdifj])/g,(function(...[e,r]){const n=t.shift();return"f"===r?n.toFixed(6):"j"===r?JSON.stringify(n):"s"===r&&"object"==typeof n?`${n.constructor!==Object?n.constructor.name:""} {}`.trim():n.toString()})),inspect(e){switch(typeof e){case"string":if(e.includes("'")){if(!e.includes('"'))return`"${e}"`;if(!e.includes("`")&&!e.includes("${"))return`\`${e}\``}return`'${e}'`;case"number":return isNaN(e)?"NaN":Object.is(e,-0)?String(e):e;case"bigint":return`${String(e)}n`;case"boolean":case"undefined":return String(e);case"object":return"{}"}},types:{isAsyncFunction:e=>e instanceof o,isArrayBufferView:e=>ArrayBuffer.isView(e)},isBlob:a},e.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")},99:(e,t,r)=>{const{Buffer:n}=r(764),{ObjectDefineProperty:o,ObjectKeys:i,ReflectApply:a}=r(61),{promisify:{custom:s}}=r(87),{streamReturningOperators:c,promiseReturningOperators:h}=r(382),{codes:{ERR_ILLEGAL_CONSTRUCTOR:u}}=r(381),l=r(299),{pipeline:p}=r(946),{destroyer:d}=r(195),f=r(610),g=r(854),m=r(874),y=e.exports=r(870).Stream;y.isDisturbed=m.isDisturbed,y.isErrored=m.isErrored,y.isReadable=m.isReadable,y.Readable=r(911);for(const v of i(c)){const _=c[v];function w(...e){if(new.target)throw u();return y.Readable.from(a(_,this,e))}o(w,"name",{__proto__:null,value:_.name}),o(w,"length",{__proto__:null,value:_.length}),o(y.Readable.prototype,v,{__proto__:null,value:w,enumerable:!1,configurable:!0,writable:!0})}for(const S of i(h)){const A=h[S];function w(...e){if(new.target)throw u();return a(A,this,e)}o(w,"name",{__proto__:null,value:A.name}),o(w,"length",{__proto__:null,value:A.length}),o(y.Readable.prototype,S,{__proto__:null,value:w,enumerable:!1,configurable:!0,writable:!0})}y.Writable=r(304),y.Duplex=r(672),y.Transform=r(161),y.PassThrough=r(917),y.pipeline=p;const{addAbortSignal:b}=r(196);y.addAbortSignal=b,y.finished=f,y.destroy=d,y.compose=l,o(y,"promises",{__proto__:null,configurable:!0,enumerable:!0,get:()=>g}),o(p,s,{__proto__:null,enumerable:!0,get:()=>g.pipeline}),o(f,s,{__proto__:null,enumerable:!0,get:()=>g.finished}),y.Stream=y,y._isUint8Array=function(e){return e instanceof Uint8Array},y._uint8ArrayToBuffer=function(e){return n.from(e.buffer,e.byteOffset,e.byteLength)}},854:(e,t,r)=>{"use strict";const{ArrayPrototypePop:n,Promise:o}=r(61),{isIterable:i,isNodeStream:a}=r(874),{pipelineImpl:s}=r(946),{finished:c}=r(610);e.exports={finished:c,pipeline:function(...e){return new o(((t,r)=>{let o,c;const h=e[e.length-1];if(h&&"object"==typeof h&&!a(h)&&!i(h)){const t=n(e);o=t.signal,c=t.end}s(e,((e,n)=>{e?r(e):t(n)}),{signal:o,end:c})}))}}},998:(e,t)=>{var r;e.exports=function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=0)}([function(e,t,r){"use strict";r.r(t);var n=r(1);const o=new n.default;if(t.default=o,Object.getOwnPropertyNames(n.default.prototype).forEach((e=>{const t=o[e];"function"==typeof t&&(o[e]=t.bind(o))})),"undefined"!=typeof window)if("SolidAuthClient"in window)console.warn("Caution: multiple versions of solid-auth-client active.");else{let e=!1;Object.defineProperty(window,"SolidAuthClient",{enumerable:!0,get:()=>(e||(e=!0,console.warn("window.SolidAuthClient has been deprecated."),console.warn("Please use window.solid.auth instead.")),o)})}},function(e,t,r){"use strict";r.r(t),r.d(t,"default",(function(){return m}));var n=r(2),o=r.n(n),i=r(3),a=r.n(i),s=r(4),c=r(65),h=r(8),u=r(9),l=r(6),p=r(11);function d(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function f(e){for(var t=1;t0&&a.length>o&&!a.warned){a.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=a.length,s=c,console&&console.warn&&console.warn(s)}return e}function p(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function d(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},o=p.bind(n);return o.listener=r,n.wrapFn=o,o}function f(e,t,r){var n=e._events;if(void 0===n)return[];var o=n[t];return void 0===o?[]:"function"==typeof o?r?[o.listener||o]:[o]:r?function(e){for(var t=new Array(e.length),r=0;r0&&(a=t[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var c=o[e];if(void 0===c)return!1;if("function"==typeof c)i(c,this,t);else{var h=c.length,u=m(c,h);for(r=0;r=0;i--)if(r[i]===t||r[i].listener===t){a=r[i].listener,o=i;break}if(o<0)return this;0===o?r.shift():function(e,t){for(;t+1=0;n--)this.removeListener(e,t[n]);return this},s.prototype.listeners=function(e){return f(this,e,!0)},s.prototype.rawListeners=function(e){return f(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):g.call(e,t)},s.prototype.listenerCount=g,s.prototype.eventNames=function(){return this._eventsCount>0?n(this._events):[]}},function(e,t,r){"use strict";r.r(t),r.d(t,"authnFetch",(function(){return l}));var n=r(2),o=r.n(n),i=(r(5),r(6)),a=r(7),s=r(8),c=r(11);function h(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function u(e){for(var t=1;t{t[r]=e}));else for(const r in e)t[r]=e[r];return t}(n.headers);n=u(u({},n),{},{headers:e})}const o=await Object(s.getSession)(e);if(!o)return t(r,n);if(await p(e,r))return Object(c.fetchWithCredentials)(o,t,r,n);let i=await t(r,n);return 401===i.status&&(await Object(a.updateHostFromResponse)(e)(i),await p(e,r)&&(i=Object(c.fetchWithCredentials)(o,t,r,n))),i}async function p(e,t){const r=await Object(a.getHost)(e)(Object(i.toUrlString)(t));return null!=r&&r.requiresAuth}},function(e,t){e.exports=window.fetch},function(e,t,r){"use strict";function n(){return"undefined"!=typeof window?window.location:{href:"https://example.org/",pathname:"/",origin:"example.org"}}r.r(t),r.d(t,"currentUrl",(function(){return o})),r.d(t,"currentUrlNoParams",(function(){return i})),r.d(t,"navigateTo",(function(){return a})),r.d(t,"originOf",(function(){return s})),r.d(t,"toUrlString",(function(){return c}));const o=()=>n().href,i=()=>n().origin+n().pathname,a=e=>{n().href=e},s=e=>new URL(e).origin,c=e=>("string"!=typeof e&&(e="url"in e?e.url:e.toString()),new URL(e,o()).toString())},function(e,t,r){"use strict";r.r(t),r.d(t,"getHost",(function(){return u})),r.d(t,"saveHost",(function(){return l})),r.d(t,"updateHostFromResponse",(function(){return p}));var n=r(2),o=r.n(n),i=r(8),a=r(9),s=r(11);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function h(e){for(var t=1;t{const{host:r}=new URL(t),n=await Object(i.getSession)(e);if(n&&r===new URL(n.idp).host)return{url:r,requiresAuth:!0};const{hosts:o}=await Object(a.getData)(e);return o&&o[r]}}function l(e){return async({url:t,requiresAuth:r})=>{await Object(a.updateStorage)(e,(e=>h(h({},e),{},{hosts:h(h({},e.hosts),{},{[t]:{requiresAuth:r}})})))}}function p(e){return async t=>{if(s.requiresAuth(t)){const{host:r}=new URL(t.url);await l(e)({url:r,requiresAuth:!0})}}}},function(e,t,r){"use strict";r.r(t),r.d(t,"getSession",(function(){return c})),r.d(t,"saveSession",(function(){return h})),r.d(t,"clearSession",(function(){return u}));var n=r(2),o=r.n(n),i=r(9);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function s(e){for(var t=1;t(await Object(i.updateStorage)(e,(e=>s(s({},e),{},{session:t})))).session}async function u(e){await Object(i.updateStorage)(e,(e=>s(s({},e),{},{session:null})))}},function(e,t,r){"use strict";r.r(t),r.d(t,"NAMESPACE",(function(){return n})),r.d(t,"defaultStorage",(function(){return o})),r.d(t,"getData",(function(){return i})),r.d(t,"updateStorage",(function(){return a})),r.d(t,"asyncStorage",(function(){return s})),r.d(t,"memStorage",(function(){return c})),r.d(t,"ipcStorage",(function(){return h})),r(10);const n="solid-auth-client",o=()=>s("undefined"!=typeof window&&"localStorage"in window?window.localStorage:c());async function i(e){let t,r;try{t=await e.getItem(n),r=JSON.parse(t||"{}")}catch(e){console.warn("Could not deserialize data:",t),console.error(e),r={}}return r}async function a(e,t){const r=t(await i(e));return await e.setItem(n,JSON.stringify(r)),r}function s(e){return{getItem:t=>Promise.resolve(e.getItem(t)),setItem:(t,r)=>Promise.resolve(e.setItem(t,r)),removeItem:t=>Promise.resolve(e.removeItem(t))}}const c=()=>{const e={};return{getItem:t=>void 0===e[t]?null:e[t],setItem:(t,r)=>{e[t]=r},removeItem:t=>{delete e[t]}}};function h(e){return{getItem:t=>e.request("storage/getItem",t),setItem:(t,r)=>e.request("storage/setItem",t,r),removeItem:t=>e.request("storage/removeItem",t)}}},function(e,t,r){"use strict";r.r(t),r.d(t,"Server",(function(){return a})),r.d(t,"Client",(function(){return s}));var n=r(2),o=r.n(n);const i="solid-auth-client";class a{constructor(e,t,r){o()(this,"_clientWindow",void 0),o()(this,"_clientOrigin",void 0),o()(this,"_handler",void 0),o()(this,"_messageListener",void 0),this._clientWindow=e,this._clientOrigin=t,this._handler=r,this._messageListener=e=>this._handleMessage(e)}async _handleMessage({data:e,origin:t}){if(t!==this._clientOrigin)return void console.warn("solid-auth-client is listening to ".concat(this._clientOrigin," ")+"so ignored a message received from ".concat(t,"."));const r=e&&e[i];if(r&&r.method){const{id:e,method:t,args:n}=r,o=await this._handler(t,...n);this._clientWindow.postMessage({[i]:{id:e,ret:o}},this._clientOrigin)}}start(){window.addEventListener("message",this._messageListener)}stop(){window.removeEventListener("message",this._messageListener)}}class s{constructor(e,t){o()(this,"_serverWindow",void 0),o()(this,"_serverOrigin",void 0),this._serverWindow=e,this._serverOrigin=t}request(e,...t){const r=Math.random();return this._serverWindow.postMessage({[i]:{id:r,method:e,args:t}},this._serverOrigin),new Promise(((e,t)=>{window.addEventListener("message",o);const n=setTimeout((()=>{t(new Error("Could not connect to main window.")),window.removeEventListener("message",o)}),2e3);function o({data:t}){const a=t&&t[i];a&&a.id===r&&a.hasOwnProperty("ret")&&(e(a.ret),clearTimeout(n),window.removeEventListener("message",o))}}))}}},function(e,t,r){"use strict";r.r(t),r.d(t,"login",(function(){return m})),r.d(t,"currentSession",(function(){return y})),r.d(t,"logout",(function(){return w})),r.d(t,"getRegisteredRp",(function(){return b})),r.d(t,"requiresAuth",(function(){return _})),r.d(t,"fetchWithCredentials",(function(){return S}));var n=r(12),o=r.n(n),i=r(2),a=r.n(i),s=r(14),c=r(18),h=r.n(c),u=r(61),l=r.n(u),p=r(6),d=r(9);function f(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function g(e){for(var t=1;tg(g({},e),{},{appHashFragment:window.location.hash})))}(t.storage),async function(e,{callbackUri:t,storage:r}){const n=await Object(d.getData)(r),o=await e.createRequest({redirect_uri:t},n);return await Object(d.updateStorage)(r,(()=>n)),Object(p.navigateTo)(o)}(r,t)}catch(e){return console.warn("Error logging in with WebID-OIDC"),console.error(e),null}}async function y(e=Object(d.defaultStorage)()){try{const t=await v(e);if(!t)return null;const r=Object(p.currentUrl)();if(!/#(.*&)?access_token=/.test(r))return null;window.location.hash="",await async function(e){await Object(d.updateStorage)(e,(e=>{let{appHashFragment:t=""}=e,r=o()(e,["appHashFragment"]);return window.location.hash=t,r}))}(e);const n=await Object(d.getData)(e),i=await t.validateResponse(r,n);return i?g(g({},i),{},{webId:i.idClaims.sub,idp:i.issuer}):null}catch(e){return console.warn("Error finding a WebID-OIDC session"),console.error(e),null}}async function w(e,t){const r=await v(e);if(r)try{await r.logout();try{await t("/.well-known/solid/logout",{credentials:"include"})}catch(e){console.info("Couldn't find /.well-known/solid/logout, this is harmless.")}}catch(e){console.warn("Error logging out of the WebID-OIDC session"),console.error(e)}}async function b(e,t){let r=await v(t.storage);return r&&r.provider.url===e&&r.registration.redirect_uris.includes(t.callbackUri)||(r=await function(e,t){const{storage:r,callbackUri:n}=t,o="id_token token",i={};Object.entries(t).filter((([e,t])=>e.startsWith("clientName#"))).forEach((([e,t])=>i[e.replace("clientName#","client_name#")]=t));const a={logo_uri:t.logoUri,contacts:t.contacts,client_name:t.clientName},s=g(g({issuer:e,grant_types:["implicit"],redirect_uris:[n],response_types:[o],scope:"openid profile"},i),a),c={defaults:{authenticate:{redirect_uri:n,response_type:o,display:"page",scope:["openid"]}},store:r};return h.a.register(e,s,c)}(e,t),await async function(e,t,r){return await Object(d.updateStorage)(e,(e=>g(g({},e),{},{rpConfig:r}))),r}(t.storage,0,r)),r}async function v(e){const t=await Object(d.getData)(e),{rpConfig:r}=t;return r?(r.store=e,h.a.from(r)):null}function _(e){if(401!==e.status)return!1;const t=e.headers.get("www-authenticate");if(!t)return!1;const r=s.parse(t);return"Bearer"===r.scheme&&r.params&&"openid webid"===r.params.scope}async function S(e,t,r,n){const o=(n?n.headers:r.headers)||{},i=await l.a.issueFor(Object(p.toUrlString)(r),e);return o.authorization="Bearer ".concat(i),t(r,g(g({},n),{},{credentials:"include",headers:o}))}},function(e,t,r){var n=r(13);e.exports=function(e,t){if(null==e)return{};var r,o,i=n(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}},function(e,t){e.exports=function(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n=0||(o[r]=e[r]);return o}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"format",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return o.default}});var n=i(r(15)),o=i(r(17));function i(e){return e&&e.__esModule?e:{default:e}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(16);function o(e){return function(e){if(Array.isArray(e)){for(var t=0,r=new Array(e.length);t@,;:\\"/?={}\[\]\u0020\u0009]+$/,o=function(e){return"string"==typeof e&&n.test(e)};t.isToken=o;var i=o;t.isScheme=i,t.quote=function(e){return`"${e.replace(/"/g,'\\"')}"`},t.unquote=function(e){return e.substr(1,e.length-2).replace(/\\"/g,'"')}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(16),o=/((?:[a-zA-Z0-9._~+\/-]+=*(?:\s+|$))|[^\u0000-\u001F\u007F()<>@,;:\\"/?={}\[\]\u0020\u0009]+)(?:=([^\\"=\s,]+|"(?:[^"\\]|\\.)*"))?/g,i=function(e,t){var r='"'===t.charAt(0)?(0,n.unquote)(t):t.trim();return Array.isArray(e)?e.concat(r):"string"==typeof e?[e,r]:r};t.default=function(e){if("string"!=typeof e)throw new TypeError("Header value must be a string.");var t=e.indexOf(" "),r=e.substr(0,t);if(!(0,n.isScheme)(r))throw new TypeError(`Invalid scheme ${r}`);return function(e,t){for(var r=null,n={};;){var a=o.exec(t);if(null===a)break;a[2]?n[a[1]]=i(n[a[1]],a[2]):r=i(r,a[1])}return{scheme:e,params:n,token:r}}(r,e.substr(t))}},function(e,t,r){"use strict";e.exports=r(19)},function(e,t,r){(function(t){const n=r(21),o=r(5),{URL:i}=r(27),a=o.Headers?o.Headers:t.Headers,{JWKSet:s}=r(28),c=r(55),h=r(57),u=r(60),l=r(56);class p{constructor({provider:e={},defaults:t,registration:r={},store:n={}}={}){this.provider=e,this.defaults=t||{popToken:!1,authenticate:{response_type:"id_token token",display:"page",scope:["openid"]}},this.registration=r,this.store=n}static async from(e){const t=new p(e),r=t.validate();if(!r.valid)throw r.error;const n=t.provider.jwks;return n?s.importKeys(n).then((e=>(t.provider.jwks=e,t))):t.jwks().then((()=>t))}static register(e,t,r,o,i){const a=new p({provider:{url:e},defaults:Object.assign({},r.defaults),store:r.store});return Promise.resolve().then((()=>a.discover())).then((()=>a.jwks())).then((()=>(n(a.provider.configuration,"OpenID Configuration is not initialized."),a.provider.configuration.registration_endpoint?a.register(t):a.getRegistration(t,o,i)))).then((()=>a))}validate(){return this.provider&&this.provider.url?{valid:!0}:{valid:!1,error:new Error("Provider url is required.")}}discover(){try{let e=this.provider.url;n(e,'RelyingParty provider must define "url"');let t=new i(e);return t.pathname=".well-known/openid-configuration",o(t.toString()).then(u("Error fetching openid configuration")).then((e=>e.json().then((e=>this.provider.configuration=e))))}catch(e){return Promise.reject(e)}}register(e){try{let t=this.provider.configuration;n(t,"OpenID Configuration is not initialized."),n(t.registration_endpoint,"OpenID Configuration is missing registration_endpoint.");let r=t.registration_endpoint,i="post",s=new a({"Content-Type":"application/json"}),c=this.defaults.register,h=JSON.stringify(Object.assign({},c,e));return o(r,{method:i,headers:s,body:h}).then(u("Error registering client")).then((e=>e.json().then((e=>this.registration=e))))}catch(e){return Promise.reject(e)}}serialize(){return JSON.stringify(this)}getRegistration(e,t,r){return Promise.resolve().then((()=>this.registration=r.getRegistration(t))).catch((e=>{throw e}))}jwks(){try{let e=this.provider.configuration;n(e,"OpenID Configuration is not initialized."),n(e.jwks_uri,"OpenID Configuration is missing jwks_uri.");let t=e.jwks_uri;return o(t).then(u("Error resolving provider keys")).then((e=>e.json().then((e=>s.importKeys(e))).then((e=>this.provider.jwks=e))))}catch(e){return Promise.reject(e)}}createRequest(e,t){return c.create(this,e,t||this.store)}validateResponse(e,t=this.store){let r;r=e.match(/^http(s?):\/\//)?{rp:this,redirect:e,session:t}:{rp:this,body:e,session:t};const n=new h(r);return h.validateResponse(n)}userinfo(e){try{let t=this.provider.configuration;n(t,"OpenID Configuration is not initialized."),n(t.userinfo_endpoint,"OpenID Configuration is missing userinfo_endpoint."),e=e||this.store.access_token,n(e,"Missing access token.");let r=t.userinfo_endpoint,i=new a({"Content-Type":"application/json",Authorization:`Bearer ${e}`});return o(r,{headers:i}).then(u("Error fetching userinfo")).then((e=>e.json()))}catch(e){return Promise.reject(e)}}logoutRequest(e={}){const{id_token_hint:t,post_logout_redirect_uri:r,state:o}=e;let a;if(n(this.provider,"OpenID Configuration is not initialized"),a=this.provider.configuration,n(a,"OpenID Configuration is not initialized"),!a.end_session_endpoint)return console.log(`OpenId Configuration for ${a.issuer} is missing end_session_endpoint`),null;if(r&&!t)throw new Error("id_token_hint is required when using post_logout_redirect_uri");const s={};t&&(s.id_token_hint=t),r&&(s.post_logout_redirect_uri=r),o&&(s.state=o);const c=new i(a.end_session_endpoint);return c.search=l.encode(s),c.href}logout(){let e;try{n(this.provider,"OpenID Configuration is not initialized."),e=this.provider.configuration,n(e,"OpenID Configuration is not initialized.")}catch(e){return Promise.reject(e)}if(!e.end_session_endpoint)return this.clearSession(),Promise.resolve(void 0);let t=e.end_session_endpoint;return o(t,{method:"get",credentials:"include"}).then(u("Error logging out")).then((()=>this.clearSession()))}clearSession(){let e=this.store;e&&delete e[d]}popTokenFor(e,t){return PoPToken.issueFor(e,t)}}const d="oidc.session.privateKey";p.SESSION_PRIVATE_KEY=d,e.exports=p}).call(this,r(20))},function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){"use strict";(function(t){var n=r(22);function o(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,o=0,i=Math.min(r,n);o=0;h--)if(u[h]!==l[h])return!1;for(h=u.length-1;h>=0;h--)if(!b(e[s=u[h]],t[s],r,n))return!1;return!0}(e,t,r,n))}return r?e===t:e==t}function v(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function _(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function S(e,t,r,n){var o;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof r&&(n=r,r=null),o=function(e){var t;try{e()}catch(e){t=e}return t}(t),n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!o&&y(o,r,"Missing expected exception"+n);var i="string"==typeof n,s=!e&&o&&!r;if((!e&&a.isError(o)&&i&&_(o,r)||s)&&y(o,r,"Got unwanted exception"+n),e&&o&&r&&!_(o,r)||!e&&o)throw o}p.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return g(m(e.actual),128)+" "+e.operator+" "+g(m(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||y;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var n=r.stack,o=f(t),i=n.indexOf("\n"+o);if(i>=0){var a=n.indexOf("\n",i+1);n=n.substring(a+1)}this.stack=n}}},a.inherits(p.AssertionError,Error),p.fail=y,p.ok=w,p.equal=function(e,t,r){e!=t&&y(e,t,r,"==",p.equal)},p.notEqual=function(e,t,r){e==t&&y(e,t,r,"!=",p.notEqual)},p.deepEqual=function(e,t,r){b(e,t,!1)||y(e,t,r,"deepEqual",p.deepEqual)},p.deepStrictEqual=function(e,t,r){b(e,t,!0)||y(e,t,r,"deepStrictEqual",p.deepStrictEqual)},p.notDeepEqual=function(e,t,r){b(e,t,!1)&&y(e,t,r,"notDeepEqual",p.notDeepEqual)},p.notDeepStrictEqual=function e(t,r,n){b(t,r,!0)&&y(t,r,n,"notDeepStrictEqual",e)},p.strictEqual=function(e,t,r){e!==t&&y(e,t,r,"===",p.strictEqual)},p.notStrictEqual=function(e,t,r){e===t&&y(e,t,r,"!==",p.notStrictEqual)},p.throws=function(e,t,r){S(!0,e,t,r)},p.doesNotThrow=function(e,t,r){S(!1,e,t,r)},p.ifError=function(e){if(e)throw e},p.strict=n((function e(t,r){t||y(t,!0,r,"==",e)}),p,{equal:p.strictEqual,deepEqual:p.deepStrictEqual,notEqual:p.notStrictEqual,notDeepEqual:p.notDeepStrictEqual}),p.strict.strict=p.strict;var A=Object.keys||function(e){var t=[];for(var r in e)s.call(e,r)&&t.push(r);return t}}).call(this,r(20))},function(e,t,r){"use strict";var n=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var r,a,s=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(e),c=1;c=i)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}})),c=n[r];r=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),f(r)?n.showHidden=r:r&&t._extend(n,r),w(n.showHidden)&&(n.showHidden=!1),w(n.depth)&&(n.depth=2),w(n.colors)&&(n.colors=!1),w(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=c),u(n,e,n.depth)}function c(e,t){var r=s.styles[t];return r?"["+s.colors[r][0]+"m"+e+"["+s.colors[r][1]+"m":e}function h(e,t){return e}function u(e,r,n){if(e.customInspect&&r&&A(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var o=r.inspect(n,e);return y(o)||(o=u(e,o,n)),o}var i=function(e,t){if(w(t))return e.stylize("undefined","undefined");if(y(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return m(t)?e.stylize(""+t,"number"):f(t)?e.stylize(""+t,"boolean"):g(t)?e.stylize("null","null"):void 0}(e,r);if(i)return i;var a=Object.keys(r),s=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),S(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return l(r);if(0===a.length){if(A(r)){var c=r.name?": "+r.name:"";return e.stylize("[Function"+c+"]","special")}if(b(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(_(r))return e.stylize(Date.prototype.toString.call(r),"date");if(S(r))return l(r)}var h,v="",E=!1,x=["{","}"];return d(r)&&(E=!0,x=["[","]"]),A(r)&&(v=" [Function"+(r.name?": "+r.name:"")+"]"),b(r)&&(v=" "+RegExp.prototype.toString.call(r)),_(r)&&(v=" "+Date.prototype.toUTCString.call(r)),S(r)&&(v=" "+l(r)),0!==a.length||E&&0!=r.length?n<0?b(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),h=E?function(e,t,r,n,o){for(var i=[],a=0,s=t.length;a60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}(h,v,x)):x[0]+v+x[1]}function l(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,t,r,n,o,i){var a,s,c;if((c=Object.getOwnPropertyDescriptor(t,o)||{value:t[o]}).get?s=c.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):c.set&&(s=e.stylize("[Setter]","special")),C(n,o)||(a="["+o+"]"),s||(e.seen.indexOf(c.value)<0?(s=g(r)?u(e,c.value,null):u(e,c.value,r-1)).indexOf("\n")>-1&&(s=i?s.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+s.split("\n").map((function(e){return" "+e})).join("\n")):s=e.stylize("[Circular]","special")),w(a)){if(i&&o.match(/^\d+$/))return s;(a=JSON.stringify(""+o)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function d(e){return Array.isArray(e)}function f(e){return"boolean"==typeof e}function g(e){return null===e}function m(e){return"number"==typeof e}function y(e){return"string"==typeof e}function w(e){return void 0===e}function b(e){return v(e)&&"[object RegExp]"===E(e)}function v(e){return"object"==typeof e&&null!==e}function _(e){return v(e)&&"[object Date]"===E(e)}function S(e){return v(e)&&("[object Error]"===E(e)||e instanceof Error)}function A(e){return"function"==typeof e}function E(e){return Object.prototype.toString.call(e)}function x(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(r){if(w(i)&&(i=e.env.NODE_DEBUG||""),r=r.toUpperCase(),!a[r])if(new RegExp("\\b"+r+"\\b","i").test(i)){var n=e.pid;a[r]=function(){var e=t.format.apply(t,arguments);console.error("%s %d: %s",r,n,e)}}else a[r]=function(){};return a[r]},t.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=d,t.isBoolean=f,t.isNull=g,t.isNullOrUndefined=function(e){return null==e},t.isNumber=m,t.isString=y,t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=w,t.isRegExp=b,t.isObject=v,t.isDate=_,t.isError=S,t.isFunction=A,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(25);var R=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function C(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){var e,r;console.log("%s - %s",(r=[x((e=new Date).getHours()),x(e.getMinutes()),x(e.getSeconds())].join(":"),[e.getDate(),R[e.getMonth()],r].join(" ")),t.format.apply(t,arguments))},t.inherits=r(26),t._extend=function(e,t){if(!t||!v(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var T="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function O(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(T&&e[T]){var t;if("function"!=typeof(t=e[T]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,T,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise((function(e,n){t=e,r=n})),o=[],i=0;i1)for(var r=1;r-1),a=!!e.msCrypto&&!i,s=!t.subtle&&!!t.webkitSubtle;if(a||s){var c={KoZIhvcNAQEB:"1.2.840.113549.1.1.1"},h={"1.2.840.113549.1.1.1":"KoZIhvcNAQEB"};if(["generateKey","importKey","unwrapKey"].forEach((function(e){var n=r[e];r[e]=function(o,i,c){var h,u,b,A,E,x=[].slice.call(arguments);switch(e){case"generateKey":h=g(o),u=i,b=c;break;case"importKey":h=g(c),u=x[3],b=x[4],"jwk"===o&&((i=y(i)).alg||(i.alg=m(h)),i.key_ops||(i.key_ops="oct"!==i.kty?"d"in i?b.filter(S):b.filter(_):b.slice()),x[1]=(E=y(i),a&&(E.extractable=E.ext,delete E.ext),d(unescape(encodeURIComponent(JSON.stringify(E)))).buffer));break;case"unwrapKey":h=x[4],u=x[5],b=x[6],x[2]=c._key}if("generateKey"===e&&"HMAC"===h.name&&h.hash)return h.length=h.length||{"SHA-1":512,"SHA-256":512,"SHA-384":1024,"SHA-512":1024}[h.hash.name],r.importKey("raw",t.getRandomValues(new Uint8Array(h.length+7>>3)),h,u,b);if(s&&"generateKey"===e&&"RSASSA-PKCS1-v1_5"===h.name&&(!h.modulusLength||h.modulusLength>=2048))return(o=g(o)).name="RSAES-PKCS1-v1_5",delete o.hash,r.generateKey(o,!0,["encrypt","decrypt"]).then((function(e){return Promise.all([r.exportKey("jwk",e.publicKey),r.exportKey("jwk",e.privateKey)])})).then((function(e){return e[0].alg=e[1].alg=m(h),e[0].key_ops=b.filter(_),e[1].key_ops=b.filter(S),Promise.all([r.importKey("jwk",e[0],h,!0,e[0].key_ops),r.importKey("jwk",e[1],h,u,e[1].key_ops)])})).then((function(e){return{publicKey:e[0],privateKey:e[1]}}));if((s||a&&"SHA-1"===(h.hash||{}).name)&&"importKey"===e&&"jwk"===o&&"HMAC"===h.name&&"oct"===i.kty)return r.importKey("raw",d(p(i.k)),c,x[3],x[4]);if(s&&"importKey"===e&&("spki"===o||"pkcs8"===o))return r.importKey("jwk",function(e){var t=w(e),r=!1;t.length>2&&(r=!0,t.shift());var n={ext:!0};if("1.2.840.113549.1.1.1"!==t[0][0])throw new TypeError("Unsupported key type");var o=["n","e","d","p","q","dp","dq","qi"],i=w(t[1]);r&&i.shift();for(var a=0;a2&&(n=!0,i.unshift(new Uint8Array([0]))),r[0][0]="1.2.840.113549.1.1.1",t=i,r.push(new Uint8Array(b(t)).buffer),n?r.unshift(new Uint8Array([0])):r[1]={tag:3,value:r[1]},new Uint8Array(b(r)).buffer}(y(e))}))),c}})),["encrypt","decrypt","sign","verify"].forEach((function(e){var t=r[e];r[e]=function(n,o,i,s){if(a&&(!i.byteLength||s&&!s.byteLength))throw new Error("Empy input is not allowed");var c,h=[].slice.call(arguments),u=g(n);if(a&&"decrypt"===e&&"AES-GCM"===u.name){var l=n.tagLength>>3;h[2]=(i.buffer||i).slice(0,i.byteLength-l),n.tag=(i.buffer||i).slice(i.byteLength-l)}h[1]=o._key;try{c=t.apply(r,h)}catch(e){return Promise.reject(e)}return a&&(c=new Promise((function(t,r){c.onabort=c.onerror=function(e){r(e)},c.oncomplete=function(r){if(r=r.target.result,"encrypt"===e&&r instanceof AesGcmEncryptResult){var n=r.ciphertext,o=r.tag;(r=new Uint8Array(n.byteLength+o.byteLength)).set(new Uint8Array(n),0),r.set(new Uint8Array(o),n.byteLength),r=r.buffer}t(r)}}))),c}})),a){var u=r.digest;r.digest=function(e,t){if(!t.byteLength)throw new Error("Empy input is not allowed");var n;try{n=u.call(r,e,t)}catch(e){return Promise.reject(e)}return n=new Promise((function(e,t){n.onabort=n.onerror=function(e){t(e)},n.oncomplete=function(t){e(t.target.result)}}))},e.crypto=Object.create(t,{getRandomValues:{value:function(e){return t.getRandomValues(e)}},subtle:{value:r}}),e.CryptoKey=v}s&&(t.subtle=r,e.Crypto=n,e.SubtleCrypto=o,e.CryptoKey=v)}}}function l(e){return btoa(e).replace(/\=+$/,"").replace(/\+/g,"-").replace(/\//g,"_")}function p(e){return e=(e+="===").slice(0,-e.length%4),atob(e.replace(/-/g,"+").replace(/_/g,"/"))}function d(e){for(var t=new Uint8Array(e.length),r=0;re.length)throw new RangeError("Malformed DER");var r,n=e[t.pos++],o=e[t.pos++];if(o>=128){if(o&=127,t.end-t.pos=128){var s=n;for(n=4,t.splice(o,0,s>>24&255,s>>16&255,s>>8&255,255&s);n>1&&!(s>>24);)s<<=8,n--;n<4&&t.splice(o,4-n),n|=128}return t.splice(o-2,2,r,n),t}function v(e,t,r,n){Object.defineProperties(this,{_key:{value:e},type:{value:e.type,enumerable:!0},extractable:{value:void 0===r?e.extractable:r,enumerable:!0},algorithm:{value:void 0===t?e.algorithm:t,enumerable:!0},usages:{value:void 0===n?e.usages:n,enumerable:!0}})}function _(e){return"verify"===e||"encrypt"===e||"wrapKey"===e}function S(e){return"sign"===e||"decrypt"===e||"unwrapKey"===e}}(a)}.apply(t,[]),void 0===r||(e.exports=r),o.default={}},function(e,t,r){const n=r(33),{NotSupportedError:o}=r(48);e.exports=class{static async sign(e,t,r){let i=n.normalize("sign",e);return i instanceof Error?Promise.reject(new o(e)):i.sign(t,r)}static async verify(e,t,r,i){let a=n.normalize("verify",e);return a instanceof Error?Promise.reject(new o(e)):a.verify(t,r,i)}static async importKey(e){return n.normalize("importKey",e.alg).importKey(e)}}},function(e,t,r){const n=r(34),o=r(35),i=r(45),a=new(r(46));a.define("HS256","sign",new o({name:"HMAC",hash:{name:"SHA-256"}})),a.define("HS384","sign",new o({name:"HMAC",hash:{name:"SHA-384"}})),a.define("HS512","sign",new o({name:"HMAC",hash:{name:"SHA-512"}})),a.define("RS256","sign",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}})),a.define("RS384","sign",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-384"}})),a.define("RS512","sign",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-512"}})),a.define("none","sign",new n({})),a.define("HS256","verify",new o({name:"HMAC",hash:{name:"SHA-256"}})),a.define("HS384","verify",new o({name:"HMAC",hash:{name:"SHA-384"}})),a.define("HS512","verify",new o({name:"HMAC",hash:{name:"SHA-512"}})),a.define("RS256","verify",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}})),a.define("RS384","verify",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-384"}})),a.define("RS512","verify",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-512"}})),a.define("none","verify",new n({})),a.define("RS256","importKey",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}})),a.define("RS384","importKey",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-384"}})),a.define("RS512","importKey",new i({name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-512"}})),e.exports=a},function(e,t){e.exports=class{sign(){return Promise.resolve("")}verify(){}}},function(e,t,r){"use strict";(function(t){const n=r(40),o=r(30),i=r(43);e.exports=class{constructor(e){this.params=e}sign(e,r){let a=this.params;return r=(new i).encode(r),o.subtle.sign(a,e,r).then((e=>n(t.from(e))))}verify(e,t,r){let a=this.params;return"string"==typeof t&&(t=Uint8Array.from(n.toBuffer(t))),"string"==typeof r&&(r=(new i).encode(r)),o.subtle.verify(a,e,t,r)}assertSufficientKeyLength(e){if(e.length=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function f(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return q(e).length;default:if(n)return F(e).length;t=(""+t).toLowerCase(),n=!0}}function g(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return P(this,t,r);case"utf8":case"utf-8":return R(this,t,r);case"ascii":return T(this,t,r);case"latin1":case"binary":return O(this,t,r);case"base64":return x(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function m(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function y(e,t,r,n,o){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=o?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(o)return-1;r=e.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof t&&(t=c.from(t,n)),c.isBuffer(t))return 0===t.length?-1:w(e,t,r,n,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):w(e,[t],r,n,o);throw new TypeError("val must be string, number or Buffer")}function w(e,t,r,n,o){var i,a=1,s=e.length,c=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,c/=2,r/=2}function h(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){var u=-1;for(i=r;is&&(r=s-c),i=r;i>=0;i--){for(var l=!0,p=0;po&&(n=o):n=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");n>i/2&&(n=i/2);for(var a=0;a