@dooc-dev/dooc 0.0.8 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +18 -17
- package/dist/engine/compiler/bundle-urls.js +39 -5
- package/dist/engine/compiler/download-progress.d.ts +9 -0
- package/dist/engine/compiler/download-progress.js +12 -0
- package/dist/engine/compiler/public-file.d.ts +1 -1
- package/dist/engine/compiler/public-file.js +9 -1
- package/dist/engine/compiler/textfile-remote.js +19 -1
- package/dist/server/cli.js +87 -9
- package/dist/server/editor-tools.d.ts +36 -1
- package/dist/server/editor-tools.js +6 -1
- package/dist/server/extensions.js +5 -0
- package/dist/server/git-workspace.d.ts +8 -0
- package/dist/server/git-workspace.js +375 -0
- package/dist/server/github-archive.d.ts +1 -0
- package/dist/server/github-archive.js +92 -0
- package/dist/server/languages.js +2 -1
- package/dist/server/operation-log.d.ts +4 -0
- package/dist/server/operation-log.js +45 -0
- package/dist/server/self.js +4 -47
- package/dist/server/serve.js +19 -11
- package/dist/server/static-client.js +2 -1
- package/dist/server/terminal.d.ts +22 -0
- package/dist/server/terminal.js +131 -0
- package/dist/server/workspace-server.js +7 -2
- package/dist/server/workspace-trust.d.ts +2 -0
- package/dist/server/workspace-trust.js +2 -0
- package/dist/workspace/editor-tools.d.ts +3 -3
- package/dist/workspace/editor-tools.js +25 -16
- package/dist/workspace-worker.global.js +8 -8
- package/package.json +3 -1
|
@@ -36,16 +36,16 @@ https://www.w3ctech.com/topic/2226`));let transformer=initializer(...args);retur
|
|
|
36
36
|
`)===-1},reduceToSingleString=(ctx,output,base2,braces,kind,recurseTimes,value2)=>{let entries=output.length;kind===2&&entries>6&&(output=groupArrayElements(ctx,output,value2));let head=base2?base2+" "+braces[0]:braces[0];if(ctx.currentDepth-recurseTimes<3&&entries===output.length){let start=output.length+ctx.indentationLvl+braces[0].length+base2.length+10;if(isBelowBreakLength(output,start,base2)){let joined=join5(output,", ");if(joined.indexOf(`
|
|
37
37
|
`)===-1)return head+" "+joined+" "+braces[1]}}let indentation=`
|
|
38
38
|
`+" ".repeat(ctx.indentationLvl);return head+indentation+" "+join5(output,","+indentation+" ")+indentation+braces[1]};exports.reduceToSingleString=reduceToSingleString}});var require_inspectBrand=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/inspectBrand.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.boxedBase=exports.functionBase=exports.classBase=exports.hexBytes=exports.moreItems=exports.isIndex=exports.nonIndexKeys=exports.ownKeys=exports.prefixOf=exports.constructorName=exports.isInstance=exports.hasBrand=exports.regExpSource=exports.dataViewBuffer=exports.sharedArrayBufferByteLength=exports.arrayBufferByteLength=exports.mapSize=exports.setSize=exports.typedArrayLength=exports.typedArrayTag=exports.getOwn=exports.isEnumerable=exports.hasOwn=exports.objectToString=void 0;var inspectPrimitive_1=require_inspectPrimitive(),INDEX_REG=/^(0|[1-9][0-9]*)$/;exports.objectToString=Object.prototype.toString;exports.hasOwn=Object.prototype.hasOwnProperty;exports.isEnumerable=Object.prototype.propertyIsEnumerable;exports.getOwn=Object.getOwnPropertyDescriptor;var getter=(proto,key)=>(0,exports.getOwn)(proto,key).get,TypedArrayPrototype=Object.getPrototypeOf(Uint8Array.prototype);exports.typedArrayTag=getter(TypedArrayPrototype,Symbol.toStringTag);exports.typedArrayLength=getter(TypedArrayPrototype,"length");exports.setSize=getter(Set.prototype,"size");exports.mapSize=getter(Map.prototype,"size");exports.arrayBufferByteLength=getter(ArrayBuffer.prototype,"byteLength");exports.sharedArrayBufferByteLength=typeof SharedArrayBuffer>"u"?void 0:getter(SharedArrayBuffer.prototype,"byteLength");exports.dataViewBuffer=getter(DataView.prototype,"buffer");exports.regExpSource=getter(RegExp.prototype,"source");var hasBrand=(check2,value2)=>{try{return check2.call(value2),!0}catch{return!1}};exports.hasBrand=hasBrand;var isInstance=(value2,ctor)=>{try{return value2 instanceof ctor}catch{return!1}};exports.isInstance=isInstance;var constructorName=value2=>{let obj=value2,first;for(;obj;){let descriptor=(0,exports.getOwn)(obj,"constructor"),ctor=descriptor&&descriptor.value;if(typeof ctor=="function"&&ctor.name!==""&&(0,exports.isInstance)(value2,ctor))return String(ctor.name);obj=Object.getPrototypeOf(obj),first===void 0&&(first=obj)}return first===null?null:"Object"};exports.constructorName=constructorName;var prefixOf=(constructor,tag2,fallback,size="")=>{if(constructor===null)return tag2!==""&&fallback!==tag2?"["+fallback+size+": null prototype] ["+tag2+"] ":"["+fallback+size+": null prototype] ";let result=constructor+size+" ";if(tag2!==""){let position2=constructor.indexOf(tag2);if(position2===-1)result+="["+tag2+"] ";else{let end=position2+tag2.length;end!==constructor.length&&constructor[end]===constructor[end].toLowerCase()&&(result+="["+tag2+"] ")}}return result};exports.prefixOf=prefixOf;var ownKeys2=value2=>{let keys=Object.keys(value2),symbols=Object.getOwnPropertySymbols(value2);for(let i2=0;i2<symbols.length;i2++)exports.isEnumerable.call(value2,symbols[i2])&&keys.push(symbols[i2]);return keys};exports.ownKeys=ownKeys2;var nonIndexKeys=value2=>{let keys=(0,exports.ownKeys)(value2),out=[];for(let i2=0;i2<keys.length;i2++){let key=keys[i2];(typeof key!="string"||!INDEX_REG.test(key)||+key>4294967294)&&out.push(key)}return out};exports.nonIndexKeys=nonIndexKeys;var isIndex=key=>INDEX_REG.test(key);exports.isIndex=isIndex;var moreItems=remaining=>"... "+remaining+" more item"+(remaining>1?"s":"");exports.moreItems=moreItems;var hexBytes=(bytes,max)=>{let length=bytes.length,shown=length>max?max:length,str="";for(let i2=0;i2<shown;i2++)str+=(i2?" ":"")+(bytes[i2]<16?"0":"")+bytes[i2].toString(16);let remaining=length-shown;return remaining>0?str+" ... "+remaining+" more byte"+(remaining>1?"s":""):str};exports.hexBytes=hexBytes;var classBase=(value2,constructor,tag2)=>{let base2="class "+(exports.hasOwn.call(value2,"name")&&value2.name||"(anonymous)");if(constructor!=="Function"&&constructor!==null&&(base2+=" ["+constructor+"]"),tag2!==""&&constructor!==tag2&&(base2+=" ["+tag2+"]"),constructor===null)base2+=" extends [null prototype]";else{let superName=Object.getPrototypeOf(value2).name;superName&&(base2+=" extends "+superName)}return"["+base2+"]"};exports.classBase=classBase;var CLASS_REG=/^(\s+[^(]*?)\s*{/,COMMENTS_REG=/(\/\/.*?\n)|(\/\*(.|\n)*?\*\/)/g,BOXED={"[object Number]":Number.prototype.valueOf,"[object String]":String.prototype.valueOf,"[object Boolean]":Boolean.prototype.valueOf,"[object BigInt]":BigInt.prototype.valueOf,"[object Symbol]":Symbol.prototype.valueOf},functionBase=(value2,constructor,tag2,formatName)=>{let source2=Function.prototype.toString.call(value2);if(source2.startsWith("class")&&source2.endsWith("}")){let slice=source2.slice(5,-1),bracket=slice.indexOf("{");if(bracket!==-1&&(slice.slice(0,bracket).indexOf("(")===-1||CLASS_REG.test(slice.replace(COMMENTS_REG,""))))return(0,exports.classBase)(value2,constructor,tag2)}let brand=exports.objectToString.call(value2),type=brand.indexOf("GeneratorFunction")===-1?"Function":"GeneratorFunction";brand.indexOf("Async")!==-1&&(type="Async"+type);let base2="["+type;constructor===null&&(base2+=" (null prototype)");let name=value2.name;return base2+=name===""?" (anonymous)":": "+(typeof name=="string"?name:formatName(name)),base2+="]",constructor!==type&&constructor!==null&&(base2+=" "+constructor),tag2!==""&&constructor!==tag2&&(base2+=" ["+tag2+"]"),base2};exports.functionBase=functionBase;var boxedBase=(value2,keys,constructor,tag2,indentation)=>{let brand=exports.objectToString.call(value2),valueOf=BOXED[brand];if(valueOf===void 0)return;let primitive;try{primitive=valueOf.call(value2)}catch{return}let type=brand.slice(8,-1);type==="String"&&keys.splice(0,primitive.length);let base2="["+type;return type!==constructor&&(base2+=constructor===null?" (null prototype)":" ("+constructor+")"),base2+=": "+(0,inspectPrimitive_1.formatPrimitive)(primitive,indentation)+"]",tag2!==""&&tag2!==constructor&&(base2+=" ["+tag2+"]"),base2};exports.boxedBase=boxedBase}});var require_inspect=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/inspect.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.inspect=void 0;var buffer_1=require_buffer3(),inspectPrimitive_1=require_inspectPrimitive(),inspectLayout_1=require_inspectLayout(),inspectBrand_1=require_inspectBrand(),INSPECT_MAX_BYTES=50,KEY_REG=/^[a-zA-Z_][a-zA-Z_0-9]*$/,formatProperty=(ctx,value2,recurseTimes,key,kind,desc)=>{let descriptor=desc||(0,inspectBrand_1.getOwn)(value2,key),str;if(descriptor.value!==void 0?(ctx.indentationLvl+=2,str=formatValue(ctx,descriptor.value,recurseTimes),ctx.indentationLvl-=2):descriptor.get!==void 0?str=descriptor.set!==void 0?"[Getter/Setter]":"[Getter]":str=descriptor.set!==void 0?"[Setter]":"undefined",kind===1)return str;let name;return typeof key=="symbol"?name=(0,inspectPrimitive_1.escapeString)(key.toString(),39):KEY_REG.test(""+key)?name=key==="__proto__"?"['__proto__']":""+key:name=(0,inspectPrimitive_1.quoteString)(""+key),descriptor.enumerable===!1&&(name="["+name+"]"),name+": "+str},formatExtra=(ctx,value2,recurseTimes,key)=>{let item;ctx.indentationLvl+=2;try{item=value2[key]}catch{ctx.indentationLvl+=2,item=value2.buffer[key]}let str=formatValue(ctx,item,recurseTimes);return ctx.indentationLvl-=2,"["+key+"]: "+str},formatSparseArray=(ctx,value2,recurseTimes,maxLength,output,i2)=>{let keys=Object.keys(value2),index4=i2;for(;i2<keys.length&&output.length<maxLength;i2++){let key=keys[i2],tmp=+key;if(tmp>4294967294)break;if(""+index4!==key){if(!(0,inspectBrand_1.isIndex)(key))break;let empty2=tmp-index4;if(output.push("<"+empty2+" empty item"+(empty2>1?"s":"")+">"),index4=tmp,output.length===maxLength)break}output.push(formatProperty(ctx,value2,recurseTimes,key,1)),index4++}let remaining=value2.length-index4;return output.length!==maxLength?remaining>0&&output.push("<"+remaining+" empty item"+(remaining>1?"s":"")+">"):remaining>0&&output.push((0,inspectBrand_1.moreItems)(remaining)),output},formatArray=(ctx,value2,recurseTimes)=>{let length=value2.length,max=length<inspectLayout_1.MAX_ARRAY_LENGTH?length:inspectLayout_1.MAX_ARRAY_LENGTH,output=[];for(let i2=0;i2<max;i2++){let desc=(0,inspectBrand_1.getOwn)(value2,i2);if(desc===void 0)return formatSparseArray(ctx,value2,recurseTimes,max,output,i2);output.push(formatProperty(ctx,value2,recurseTimes,i2,1,desc))}return length>max&&output.push((0,inspectBrand_1.moreItems)(length-max)),output},formatTypedArray=(ctx,value2)=>{let length=inspectBrand_1.typedArrayLength.call(value2),max=length<inspectLayout_1.MAX_ARRAY_LENGTH?length:inspectLayout_1.MAX_ARRAY_LENGTH,output=[],bigint=length>0&&typeof value2[0]!="number";for(let i2=0;i2<max;i2++)output.push(bigint?value2[i2]+"n":(0,inspectPrimitive_1.formatNumber)(value2[i2]));return length>max&&output.push((0,inspectBrand_1.moreItems)(length-max)),output},formatSet=(ctx,value2,recurseTimes)=>{let length=inspectBrand_1.setSize.call(value2),max=length<inspectLayout_1.MAX_ARRAY_LENGTH?length:inspectLayout_1.MAX_ARRAY_LENGTH,output=[],iterator=Set.prototype.values.call(value2);ctx.indentationLvl+=2;for(let entry=iterator.next();!entry.done&&output.length<max;entry=iterator.next())output.push(formatValue(ctx,entry.value,recurseTimes));return length>max&&output.push((0,inspectBrand_1.moreItems)(length-max)),ctx.indentationLvl-=2,output},formatMap=(ctx,value2,recurseTimes)=>{let length=inspectBrand_1.mapSize.call(value2),max=length<inspectLayout_1.MAX_ARRAY_LENGTH?length:inspectLayout_1.MAX_ARRAY_LENGTH,output=[],iterator=Map.prototype.entries.call(value2);ctx.indentationLvl+=2;for(let entry=iterator.next();!entry.done&&output.length<max;entry=iterator.next())output.push(formatValue(ctx,entry.value[0],recurseTimes)+" => "+formatValue(ctx,entry.value[1],recurseTimes));return length>max&&output.push((0,inspectBrand_1.moreItems)(length-max)),ctx.indentationLvl-=2,output},formatArrayBuffer=(ctx,value2)=>{let bytes;try{bytes=new Uint8Array(value2)}catch{return["(detached)"]}return["[Uint8Contents]: <"+(0,inspectBrand_1.hexBytes)(bytes,inspectLayout_1.MAX_ARRAY_LENGTH)+">"]},noEntries=()=>[],formatRaw=(ctx,value2,recurseTimes)=>{let constructor=(0,inspectBrand_1.constructorName)(value2),rawTag="";try{rawTag=value2[Symbol.toStringTag]}catch{}let tag2=typeof rawTag!="string"||rawTag!==""&&inspectBrand_1.isEnumerable.call(value2,Symbol.toStringTag)?"":rawTag,keys,base2="",braces=["{","}"],formatter2=noEntries,kind=0,fallback="Object",extraKeys;if(Symbol.iterator in value2||constructor===null){let typed;if(Array.isArray(value2)){if(fallback="Array",keys=(0,inspectBrand_1.nonIndexKeys)(value2),braces=[(constructor!=="Array"||tag2!==""?(0,inspectBrand_1.prefixOf)(constructor,tag2,"Array","("+value2.length+")"):"")+"[","]"],value2.length===0&&keys.length===0)return braces[0]+"]";kind=2,formatter2=formatArray}else if((0,inspectBrand_1.hasBrand)(inspectBrand_1.setSize,value2)||(0,inspectBrand_1.hasBrand)(inspectBrand_1.mapSize,value2)){let isSet=(0,inspectBrand_1.hasBrand)(inspectBrand_1.setSize,value2),size=isSet?inspectBrand_1.setSize.call(value2):inspectBrand_1.mapSize.call(value2);fallback=isSet?"Set":"Map",keys=(0,inspectBrand_1.ownKeys)(value2);let prefix=(0,inspectBrand_1.prefixOf)(constructor,tag2,fallback,"("+size+")");if(size===0&&keys.length===0)return prefix+"{}";braces=[prefix+"{","}"],formatter2=isSet?formatSet:formatMap}else if((typed=inspectBrand_1.typedArrayTag.call(value2))!==void 0){fallback=typed,keys=(0,inspectBrand_1.nonIndexKeys)(value2);let length=inspectBrand_1.typedArrayLength.call(value2);if(braces=[(0,inspectBrand_1.prefixOf)(constructor,tag2,constructor===null?typed:"","("+length+")")+"[","]"],length===0&&keys.length===0)return braces[0]+"]";kind=2,formatter2=formatTypedArray}}if(keys===void 0)if(keys=(0,inspectBrand_1.ownKeys)(value2),typeof value2=="function"){if(fallback="Function",base2=(0,inspectBrand_1.functionBase)(value2,constructor,tag2,name=>formatValue(ctx,name,0)),keys.length===0)return base2}else if(constructor==="Object"){if(inspectBrand_1.objectToString.call(value2)==="[object Arguments]"&&inspectBrand_1.hasOwn.call(value2,"callee")?braces[0]="[Arguments] {":tag2!==""&&(braces[0]=(0,inspectBrand_1.prefixOf)(constructor,tag2,"Object")+"{"),keys.length===0)return braces[0]+"}"}else if((0,inspectBrand_1.hasBrand)(inspectBrand_1.regExpSource,value2)){fallback="RegExp";let prefix=(0,inspectBrand_1.prefixOf)(constructor,tag2,"RegExp");if(base2=RegExp.prototype.toString.call(constructor===null?new RegExp(value2):value2),prefix!=="RegExp "&&(base2=prefix+base2),keys.length===0||recurseTimes>ctx.depth)return base2}else if((0,inspectBrand_1.hasBrand)(Date.prototype.getTime,value2)){fallback="Date";let prefix=(0,inspectBrand_1.prefixOf)(constructor,tag2,"Date"),time=Date.prototype.getTime.call(value2);if(base2=time!==time?Date.prototype.toString.call(value2):Date.prototype.toISOString.call(value2),prefix!=="Date "&&(base2=prefix+base2),keys.length===0)return base2}else if(inspectBrand_1.objectToString.call(value2)==="[object Error]"||(0,inspectBrand_1.isInstance)(value2,Error)){fallback="Error";let stack=value2.stack;if(base2=typeof stack=="string"&&stack!==""?stack.replace(/\n/g,`
|
|
39
|
-
`+" ".repeat(ctx.indentationLvl)):"["+Error.prototype.toString.call(value2)+"]",keys.length===0)return base2}else if((0,inspectBrand_1.hasBrand)(inspectBrand_1.arrayBufferByteLength,value2)||inspectBrand_1.sharedArrayBufferByteLength!==void 0&&(0,inspectBrand_1.hasBrand)(inspectBrand_1.sharedArrayBufferByteLength,value2))fallback=(0,inspectBrand_1.hasBrand)(inspectBrand_1.arrayBufferByteLength,value2)?"ArrayBuffer":"SharedArrayBuffer",braces[0]=(0,inspectBrand_1.prefixOf)(constructor,tag2,fallback)+"{",formatter2=formatArrayBuffer,extraKeys=["byteLength"];else if((0,inspectBrand_1.hasBrand)(inspectBrand_1.dataViewBuffer,value2))fallback="DataView",braces[0]=(0,inspectBrand_1.prefixOf)(constructor,tag2,"DataView")+"{",extraKeys=["byteLength","byteOffset","buffer"];else{let boxed=(0,inspectBrand_1.boxedBase)(value2,keys,constructor,tag2,ctx.indentationLvl);if(boxed!==void 0){if(base2=boxed,keys.length===0)return base2}else{let style=(0,inspectBrand_1.prefixOf)(constructor,tag2,constructor===null?"Object":"");if(keys.length===0)return style+"{}";braces[0]=style+"{"}}if(recurseTimes>ctx.depth){let name=(0,inspectBrand_1.prefixOf)(constructor,tag2,constructor===null?fallback===tag2?"Object":fallback:"").slice(0,-1);return constructor===null?name:"["+name+"]"}recurseTimes++,ctx.seen.push(value2),ctx.currentDepth=recurseTimes;let output=formatter2(ctx,value2,recurseTimes);if(extraKeys!==void 0)for(let i2=0;i2<extraKeys.length;i2++)output.push(formatExtra(ctx,value2,recurseTimes,extraKeys[i2]));for(let i2=0;i2<keys.length;i2++)output.push(formatProperty(ctx,value2,recurseTimes,keys[i2],kind));let index4=ctx.circular===void 0?void 0:ctx.circular.get(value2);return index4!==void 0&&(base2=base2===""?"<ref *"+index4+">":"<ref *"+index4+"> "+base2),ctx.seen.pop(),(0,inspectLayout_1.reduceToSingleString)(ctx,output,base2,braces,kind,recurseTimes,value2)},formatValue=(ctx,value2,recurseTimes)=>{if(typeof value2!="object"&&typeof value2!="function")return(0,inspectPrimitive_1.formatPrimitive)(value2,ctx.indentationLvl);if(value2===null)return"null";if(buffer_1.Buffer.isBuffer(value2))return"<"+value2.constructor.name+" "+(0,inspectBrand_1.hexBytes)(value2,INSPECT_MAX_BYTES)+">";if(ctx.seen.indexOf(value2)!==-1){let circular=ctx.circular;circular===void 0&&(ctx.circular=circular=new Map);let index4=circular.get(value2);return index4===void 0&&(index4=circular.size+1,circular.set(value2,index4)),"[Circular *"+index4+"]"}return formatRaw(ctx,value2,recurseTimes)},inspect=(value2,depth=2)=>formatValue({depth,indentationLvl:0,currentDepth:0,seen:[],circular:void 0},value2,0);exports.inspect=inspect}});var require_argErrors=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/argErrors.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.invalidUrlScheme=exports.methodNotImplemented=exports.invalidThis=exports.outOfRange=exports.invalidArgValue=exports.invalidArgType=exports.withNativeCode=exports.withCode=void 0;var inspect_1=require_inspect(),inspectPrimitive_1=require_inspectPrimitive(),TWO_POW_32=4294967296,BIG_TWO_POW_32=BigInt(TWO_POW_32),withCode=(error,code4)=>{error.code=code4;let tagged=error.name+" ["+code4+"]";return Object.defineProperty(error,"name",{value:tagged,enumerable:!1,writable:!0,configurable:!0}),error.stack,delete error.name,Object.defineProperty(error,"toString",{value:function(){return tagged+": "+this.message},enumerable:!1,writable:!0,configurable:!0}),error};exports.withCode=withCode;var withNativeCode=(error,code4)=>(error.code=code4,error);exports.withNativeCode=withNativeCode;var kindOf=name=>name.indexOf(".")===-1?"argument":"property",describeType=value2=>{if(value2===null)return"null";if(value2===void 0)return"undefined";switch(typeof value2){case"bigint":return"type bigint ("+value2+"n)";case"number":return"type number ("+(0,inspectPrimitive_1.formatNumber)(value2)+")";case"boolean":return"type boolean ("+value2+")";case"symbol":return"type symbol ("+value2.toString()+")";case"function":return"function "+value2.name;case"string":{let str=value2.length>28?value2.slice(0,25)+"...":value2;return str.indexOf("'")===-1?"type string ('"+str+"')":"type string ("+JSON.stringify(str)+")"}}let ctor=value2.constructor;return ctor&&"name"in ctor?"an instance of "+ctor.name:(0,inspect_1.inspect)(value2,-1)},describeNativeType=value2=>{switch(typeof value2){case"bigint":return"type bigint ("+value2+")";case"symbol":return value2.toString();case"function":return"function";case"object":{if(value2===null)break;let ctor=value2.constructor;return"an instance of "+(ctor&&ctor.name||"Object")}}return describeType(value2)},invalidArgType=(name,expected,actual,native)=>{let head=name.endsWith(" argument")?"The "+name+" ":'The "'+name+'" '+kindOf(name)+" ",received=native?describeNativeType(actual):describeType(actual),error=new TypeError(head+"must be "+expected+". Received "+received);return native?(0,exports.withNativeCode)(error,"ERR_INVALID_ARG_TYPE"):(0,exports.withCode)(error,"ERR_INVALID_ARG_TYPE")};exports.invalidArgType=invalidArgType;var invalidArgValue=(name,value2,reason="is invalid")=>{let inspected=(0,inspect_1.inspect)(value2);return inspected.length>128&&(inspected=inspected.slice(0,128)+"..."),(0,exports.withCode)(new TypeError("The "+kindOf(name)+" '"+name+"' "+reason+". Received "+inspected),"ERR_INVALID_ARG_VALUE")};exports.invalidArgValue=invalidArgValue;var outOfRange=(name,range,value2,native)=>{let message='The value of "'+name+'" is out of range. It must be '+range+". Received ";if(native)return(0,exports.withNativeCode)(new RangeError(message+String(value2)),"ERR_OUT_OF_RANGE");let received;return Number.isInteger(value2)&&Math.abs(value2)>TWO_POW_32?received=(0,inspectPrimitive_1.addNumericalSeparator)(""+value2):typeof value2=="bigint"?(received=""+value2,(value2>BIG_TWO_POW_32||value2<-BIG_TWO_POW_32)&&(received=(0,inspectPrimitive_1.addNumericalSeparator)(received)),received+="n"):received=(0,inspect_1.inspect)(value2),(0,exports.withCode)(new RangeError(message+received),"ERR_OUT_OF_RANGE")};exports.outOfRange=outOfRange;var invalidThis=type=>(0,exports.withCode)(new TypeError('Value of "this" must be of type '+type),"ERR_INVALID_THIS");exports.invalidThis=invalidThis;var methodNotImplemented=method=>(0,exports.withCode)(new Error("The "+method+" method is not implemented"),"ERR_METHOD_NOT_IMPLEMENTED");exports.methodNotImplemented=methodNotImplemented;var invalidUrlScheme=expected=>(0,exports.withCode)(new TypeError("The URL must be of scheme "+expected),"ERR_INVALID_URL_SCHEME");exports.invalidUrlScheme=invalidUrlScheme}});var require_encoding=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/encoding.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.ENCODING_UTF8=void 0;exports.assertEncoding=assertEncoding;exports.strToEncoding=strToEncoding;var buffer_1=require_buffer3(),argErrors_1=require_argErrors();exports.ENCODING_UTF8="utf8";function assertEncoding(encoding){if(encoding&&!buffer_1.Buffer.isEncoding(encoding))throw(0,argErrors_1.invalidArgValue)("encoding",encoding,"is invalid encoding")}function strToEncoding(str,encoding){return!encoding||encoding===exports.ENCODING_UTF8?str:encoding==="buffer"?new buffer_1.Buffer(str):new buffer_1.Buffer(str).toString(encoding)}}});var require_lib4=__commonJS({"node_modules/.pnpm/glob-to-regex.js@1.3.1_tslib@2.9.1/node_modules/glob-to-regex.js/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.toMatcher=exports.toRegex=exports.expandBraces=void 0;var NODOT="(?!\\.)",STAR="[^/]*",GLOBSTAR_NODOT="[^/]*(?:/(?!\\.)[^/]*)*",literal=(pattern,i2,code4)=>{switch(code4){case 36:case 42:case 63:case 91:case 40:case 41:case 43:case 46:case 92:case 93:case 94:case 123:case 124:case 125:return"\\"+pattern[i2];default:return pattern[i2]}},posixClass=name=>{switch(name){case"alnum":return"0-9A-Za-z";case"alpha":return"A-Za-z";case"ascii":return"\\x00-\\x7f";case"blank":return" \\t";case"cntrl":return"\\x00-\\x1f\\x7f";case"digit":return"0-9";case"graph":return"\\x21-\\x7e";case"lower":return"a-z";case"print":return"\\x20-\\x7e";case"punct":return"\\x21-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7e";case"space":return" \\t\\r\\n\\v\\f";case"upper":return"A-Z";case"word":return"0-9A-Za-z_";case"xdigit":return"0-9A-Fa-f"}},classEnd=(pattern,i2)=>{let length=pattern.length,j=i2+1,first=pattern.charCodeAt(j);for((first===33||first===94)&&j++,pattern.charCodeAt(j)===93&&j++;j<length;j++){let code4=pattern.charCodeAt(j);if(code4===93)return j+1;if(code4===91&&pattern.charCodeAt(j+1)===58){let close2=pattern.indexOf(":]",j+2);close2>0&&(j=close2+1)}}return-1},member=(pattern,i2)=>{let code4=pattern.charCodeAt(i2);return(code4===93||code4===92||code4===91||code4===94||code4===45?"\\":"")+pattern[i2]},classSource=(pattern,i2,end)=>{let last=end-1,j=i2+1,out="",members=0,first=pattern.charCodeAt(j),negate=first===33||first===94;for(negate&&j++;j<last;){if(pattern.charCodeAt(j)===91&&pattern.charCodeAt(j+1)===58){let close2=pattern.indexOf(":]",j+2),cls=close2>0?posixClass(pattern.slice(j+2,close2)):void 0;if(cls!==void 0){out+=cls,members+=2,j=close2+2;continue}}if(pattern.charCodeAt(j+1)===45&&j+2<last){pattern.charCodeAt(j+2)>=pattern.charCodeAt(j)&&(out+=member(pattern,j)+"-"+member(pattern,j+2),members+=2),j+=3;continue}out+=member(pattern,j),members++,j++}return!negate&&members===1?literal(pattern,last-1,pattern.charCodeAt(last-1)):members?(negate?"[^":"[")+out+"]":negate?"[^/]":"[]"},groupEnd=(pattern,i2)=>{let length=pattern.length,depth=1;for(;i2<length;i2++){let code4=pattern.charCodeAt(i2);if(code4===91){let end=classEnd(pattern,i2);end>0&&(i2=end-1)}else if(code4===40)depth++;else if(code4===41&&!--depth)return i2+1}return-1},splitAlts=body=>{let length=body.length,alts=[],depth=0,from=0;for(let i2=0;i2<length;i2++){let code4=body.charCodeAt(i2);if(code4===91){let end=classEnd(body,i2);end>0&&(i2=end-1)}else code4===40?depth++:code4===41?depth--:code4===124&&!depth&&(alts.push(body.slice(from,i2)),from=i2+1)}return alts.push(body.slice(from)),alts},isExtglobPrefix=code4=>code4===63||code4===42||code4===43||code4===64||code4===33,altsSource=(alts,extglob,nodot,tail,segStart)=>{let out="";for(let i2=0;i2<alts.length;i2++)out+=(i2?"|":"")+compile(alts[i2],extglob,nodot,tail,segStart);return out},extglobSource=(type,alts,extglob,nodot,tail,segStart)=>{let guard=nodot&&segStart?NODOT:"",body=altsSource(alts,extglob,nodot,tail,segStart);switch(type){case 63:return"(?:"+body+")?";case 64:return"(?:"+body+")";case 33:return alts.length===1&&!alts[0]?guard+"[^/]+":"(?!(?:"+body+")"+tail+"$)"+guard+STAR}let more=guard?altsSource(alts,extglob,nodot,tail,!1):body;if(more===body)return"(?:"+body+")"+(type===42?"*":"+");let once="(?:"+body+")(?:"+more+")*";return type===42?"(?:"+once+")?":once},compile=(pattern,extglob,nodot,tail,segStart)=>{let length=pattern.length,out="",i2=0,start=segStart;for(;i2<length;){let code4=pattern.charCodeAt(i2);if(extglob&&pattern.charCodeAt(i2+1)===40&&isExtglobPrefix(code4)){let end=groupEnd(pattern,i2+2);if(end>0){let after=compile(pattern.slice(end),extglob,nodot,tail,!1),alts=splitAlts(pattern.slice(i2+2,end-1));return out+extglobSource(code4,alts,extglob,nodot,after+tail,start)+after}}let atStart=start,guard=nodot&&atStart?NODOT:"";switch(start=!1,code4){case 42:{let j=i2+1;for(;pattern.charCodeAt(j)===42;)j++;if(j===i2+1){let whole=atStart&&(j===length||pattern.charCodeAt(j)===47);out+=guard+(whole?"[^/]+":STAR),i2=j;break}let slash=pattern.charCodeAt(j)===47;for(;slash;){let k=j+1;if(pattern.charCodeAt(k)!==42||pattern.charCodeAt(k+1)!==42)break;for(k+=2;pattern.charCodeAt(k)===42;)k++;if(k===length)j=k,slash=!1;else if(pattern.charCodeAt(k)===47)j=k;else break}slash?(out+=nodot?"(?:"+guard+GLOBSTAR_NODOT+"/)?":"(?:.*/)?",j++,start=!0):out+=nodot?guard+GLOBSTAR_NODOT:".*",i2=j;break}case 63:out+=guard+"[^/]",i2++;break;case 91:{let end=classEnd(pattern,i2);if(end<0){out+="\\[",i2++;break}let cls=classSource(pattern,i2,end);out+=(cls.charCodeAt(0)===91?guard:"")+cls,i2=end;break}case 47:out+="/",i2++,start=!0;break;default:out+=literal(pattern,i2,code4),i2++}}return out},closingBrace=(pattern,open2)=>{let length=pattern.length,depth=0;for(let i2=open2;i2<length;i2++){let code4=pattern.charCodeAt(i2);if(code4===123)depth++;else if(code4===125&&!--depth)return i2}return-1},commaSplit=body=>{let length=body.length,parts=[],depth=0,from=0;for(let i2=0;i2<length;i2++){let code4=body.charCodeAt(i2);code4===123?depth++:code4===125?depth--:code4===44&&!depth&&(parts.push(body.slice(from,i2)),from=i2+1)}if(parts.length)return parts.push(body.slice(from)),parts},NUMERIC_RANGE=/^(-?\d+)\.\.(-?\d+)(?:\.\.(-?\d+))?$/,ALPHA_RANGE=/^([a-zA-Z])\.\.([a-zA-Z])(?:\.\.(-?\d+))?$/,PADDED=/^-?0\d/,rangeOf=(body,max)=>{let match=NUMERIC_RANGE.exec(body),alpha=!match;if(alpha&&(match=ALPHA_RANGE.exec(body)),!match)return;let from=alpha?match[1].charCodeAt(0):+match[1],to=alpha?match[2].charCodeAt(0):+match[2],step=match[3]===void 0?1:Math.abs(+match[3])||1,width=!alpha&&(PADDED.test(match[1])||PADDED.test(match[2]))?Math.max(match[1].length,match[2].length):0,out=[],dir=from<=to?step:-step;for(let n2=from;(dir>0?n2<=to:n2>=to)&&out.length<max;n2+=dir){if(alpha){out.push(String.fromCharCode(n2));continue}let s2=String(n2),need=width-s2.length;if(need>0){let zeros="";for(let k=0;k<need;k++)zeros+="0";s2=n2<0?"-"+zeros+s2.slice(1):zeros+s2}out.push(s2)}return out},expandInto=(pattern,out,max)=>{for(let open2=pattern.indexOf("{");open2>=0;open2=pattern.indexOf("{",open2+1)){let close2=closingBrace(pattern,open2);if(close2<0)continue;let body=pattern.slice(open2+1,close2),alts=commaSplit(body)||rangeOf(body,max);if(!alts)continue;let prefix=pattern.slice(0,open2),suffixes=(0,exports.expandBraces)(pattern.slice(close2+1),max);for(let i2=0;i2<alts.length;i2++){let heads=(0,exports.expandBraces)(alts[i2],max);for(let j=0;j<heads.length;j++){let head=prefix+heads[j];for(let k=0;k<suffixes.length;k++){if(out.length>=max)return;out.push(head+suffixes[k])}}}return}out.push(pattern)},expandBraces=(pattern,max=1e5)=>{let out=[];return expandInto(pattern,out,max),out};exports.expandBraces=expandBraces;var toRegex=(pattern,options2)=>{let extglob=!!options2?.extglob,nodot=options2?.dot===!1,source2;if(pattern.indexOf("{")<0)source2=compile(pattern,extglob,nodot,"",!0);else{let set2=(0,exports.expandBraces)(pattern),length=set2.length;if(length===1)source2=compile(set2[0],extglob,nodot,"",!0);else{let seen=new Set;source2="(?:";for(let i2=0;i2<length;i2++){let one2=set2[i2];seen.has(one2)||(seen.size&&(source2+="|"),seen.add(one2),source2+=compile(one2,extglob,nodot,"",!0))}source2+=")"}}return new RegExp("^"+source2+"$",options2?.nocase?"i":"")};exports.toRegex=toRegex;var isRegExp=/^\/(.{1,4096})\/([gimsuy]{0,6})$/,toMatcher=(pattern,options2)=>{let regexes=[],patterns=Array.isArray(pattern)?pattern:[pattern];for(let pat of patterns)if(typeof pat=="string"){let match=isRegExp.exec(pat);if(match){let[,expr,flags]=match;regexes.push(new RegExp(expr,flags))}else regexes.push((0,exports.toRegex)(pat,options2))}else regexes.push(pat);return regexes.length?new Function("p","return "+regexes.map(r2=>r2+".test(p)").join("||")):()=>!1};exports.toMatcher=toMatcher}});var require_watchIgnore=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/watchIgnore.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.watchIgnoreToMatcher=exports.watchIgnorePatternToMatcher=void 0;var glob_to_regex_js_1=require_lib4(),watchIgnorePatternToMatcher=pattern=>{if(typeof pattern=="function")return pattern;if(pattern instanceof RegExp)return filename=>pattern.test(filename);if(typeof pattern=="string"){let regex=(0,glob_to_regex_js_1.toRegex)(pattern);return filename=>regex.test(filename)}throw new TypeError(`The "options.ignore" property must be of type string, RegExp, function, or an array thereof. Received ${typeof pattern}`)};exports.watchIgnorePatternToMatcher=watchIgnorePatternToMatcher;var watchIgnoreToMatcher=ignore3=>{if(Array.isArray(ignore3)){let matchers=ignore3.map(exports.watchIgnorePatternToMatcher);return filename=>matchers.some(matcher=>matcher(filename))}return(0,exports.watchIgnorePatternToMatcher)(ignore3)};exports.watchIgnoreToMatcher=watchIgnoreToMatcher}});var require_fsCallbackApiList=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/lists/fsCallbackApiList.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsCallbackApiList=void 0;exports.fsCallbackApiList=["access","appendFile","chmod","chown","close","copyFile","cp","createReadStream","createWriteStream","exists","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","glob","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","openAsBlob","opendir","read","readv","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","statfs","symlink","truncate","unlink","unwatchFile","utimes","lutimes","watch","watchFile","write","writev","writeFile"]}});var require_fsSynchronousApiList=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/lists/fsSynchronousApiList.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsSynchronousApiList=void 0;exports.fsSynchronousApiList=["accessSync","appendFileSync","chmodSync","chownSync","closeSync","copyFileSync","cpSync","existsSync","fchmodSync","fchownSync","fdatasyncSync","fstatSync","fsyncSync","ftruncateSync","futimesSync","globSync","lchmodSync","lchownSync","linkSync","lstatSync","mkdirSync","mkdtempSync","openSync","opendirSync","readdirSync","readFileSync","readlinkSync","readSync","readvSync","realpathSync","renameSync","rmdirSync","rmSync","statfsSync","statSync","symlinkSync","truncateSync","unlinkSync","utimesSync","lutimesSync","writeFileSync","writeSync","writevSync"]}});var require_fsCommonObjectsList=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/lists/fsCommonObjectsList.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsCommonObjectsList=void 0;exports.fsCommonObjectsList=["F_OK","R_OK","W_OK","X_OK","constants","Stats","StatFs","Dir","Dirent","StatWatcher","FSWatcher","ReadStream","WriteStream"]}});var require_lib5=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsCommonObjectsList=exports.fsSynchronousApiList=exports.fsCallbackApiList=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports));tslib_1.__exportStar(require_types2(),exports);tslib_1.__exportStar(require_constants2(),exports);tslib_1.__exportStar(require_AMODE(),exports);tslib_1.__exportStar(require_FLAG(),exports);tslib_1.__exportStar(require_path3(),exports);tslib_1.__exportStar(require_encoding(),exports);tslib_1.__exportStar(require_watchIgnore(),exports);var fsCallbackApiList_1=require_fsCallbackApiList();Object.defineProperty(exports,"fsCallbackApiList",{enumerable:!0,get:function(){return fsCallbackApiList_1.fsCallbackApiList}});var fsSynchronousApiList_1=require_fsSynchronousApiList();Object.defineProperty(exports,"fsSynchronousApiList",{enumerable:!0,get:function(){return fsSynchronousApiList_1.fsSynchronousApiList}});var fsCommonObjectsList_1=require_fsCommonObjectsList();Object.defineProperty(exports,"fsCommonObjectsList",{enumerable:!0,get:function(){return fsCommonObjectsList_1.fsCommonObjectsList}})}});var require_json=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/json.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.flattenJSON=void 0;var buffer_1=require_buffer3(),fs_node_utils_1=require_lib5(),flattenJSON=nestedJSON=>{let flatJSON={};function flatten(pathPrefix,node2){for(let path4 in node2){let contentOrNode=node2[path4],joinedPath=(0,fs_node_utils_1.pathJoin)(pathPrefix,path4);typeof contentOrNode=="string"||contentOrNode instanceof buffer_1.Buffer?flatJSON[joinedPath]=contentOrNode:typeof contentOrNode=="object"&&contentOrNode!==null&&!(contentOrNode instanceof buffer_1.Buffer)&&Object.keys(contentOrNode).length>0?flatten(joinedPath,contentOrNode):flatJSON[joinedPath]=null}}return flatten("",nestedJSON),flatJSON};exports.flattenJSON=flattenJSON}});var require_constants3=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/constants.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0})}});var require_result2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/result.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Ok=Ok;exports.Err=Err;function Ok(value2){return{ok:!0,value:value2}}function Err(err){return{ok:!1,err}}}});var require_fanout=__commonJS({"node_modules/.pnpm/thingies@2.6.1_tslib@2.9.1/node_modules/thingies/lib/fanout.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FanOut=void 0;var FanOut=class{constructor(){this.listeners=new Set}emit(data){this.listeners.forEach(listener=>listener(data))}listen(listener){let listeners=this.listeners;return listeners.add(listener),()=>listeners.delete(listener)}};exports.FanOut=FanOut}});var require_browser=__commonJS({"node_modules/.pnpm/process@0.11.10/node_modules/process/browser.js"(exports,module){init_browser_globals();var process2=module.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout)return setTimeout(fun,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(fun,0);try{return cachedSetTimeout(fun,0)}catch{try{return cachedSetTimeout.call(null,fun,0)}catch{return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout)return clearTimeout(marker);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(marker);try{return cachedClearTimeout(marker)}catch{try{return cachedClearTimeout.call(null,marker)}catch{return cachedClearTimeout.call(this,marker)}}}var queue2=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue2=currentQueue.concat(queue2):queueIndex=-1,queue2.length&&drainQueue())}function drainQueue(){if(!draining){var timeout=runTimeout(cleanUpNextTick);draining=!0;for(var len=queue2.length;len;){for(currentQueue=queue2,queue2=[];++queueIndex<len;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,len=queue2.length}currentQueue=null,draining=!1,runClearTimeout(timeout)}}process2.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1)for(var i2=1;i2<arguments.length;i2++)args[i2-1]=arguments[i2];queue2.push(new Item(fun,args)),queue2.length===1&&!draining&&runTimeout(drainQueue)};function Item(fun,array){this.fun=fun,this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process2.title="browser";process2.browser=!0;process2.env={};process2.argv=[];process2.version="";process2.versions={};function noop(){}process2.on=noop;process2.addListener=noop;process2.once=noop;process2.off=noop;process2.removeListener=noop;process2.removeAllListeners=noop;process2.emit=noop;process2.prependListener=noop;process2.prependOnceListener=noop;process2.listeners=function(name){return[]};process2.binding=function(name){throw new Error("process.binding is not supported")};process2.cwd=function(){return"/"};process2.chdir=function(dir){throw new Error("process.chdir is not supported")};process2.umask=function(){return 0}}});var require_process=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/process.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.createProcess=createProcess;var maybeReturnProcess=()=>{if(typeof process<"u")return process;try{return require_browser()}catch{return}};function createProcess(){let p2=maybeReturnProcess()||{};return p2.cwd||(p2.cwd=()=>"/"),p2.emitWarning||(p2.emitWarning=(message,type)=>{console.warn(`${type}${type?": ":""}${message}`)}),p2.env||(p2.env={}),p2}exports.default=createProcess()}});var require_Node=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/Node.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Node=void 0;var fanout_1=require_fanout(),process_1=require_process(),buffer_1=require_buffer3(),fs_node_utils_1=require_lib5(),{S_IFMT,S_IFDIR,S_IFREG,S_IFLNK,S_IFCHR}=fs_node_utils_1.constants,getuid=()=>process_1.default.getuid?.()??0,getgid=()=>process_1.default.getgid?.()??0,EMPTY_BUFFER=(0,buffer_1.bufferAllocUnsafe)(0),Node3=class{constructor(ino,mode=438,uid=getuid(),gid=getgid()){this.changes=new fanout_1.FanOut,this._uid=getuid(),this._gid=getgid(),this._atime=new Date,this._mtime=new Date,this._ctime=new Date,this._btime=new Date,this.buf=EMPTY_BUFFER,this.capacity=0,this.size=0,this.rdev=0,this._nlink=1,this.mode=mode,this.ino=ino,this._uid=uid,this._gid=gid}set ctime(ctime){this._ctime=ctime}get ctime(){return this._ctime}set btime(btime){this._btime=btime}get btime(){return this._btime}set uid(uid){this._uid=uid,this.ctime=new Date}get uid(){return this._uid}set gid(gid){this._gid=gid,this.ctime=new Date}get gid(){return this._gid}set atime(atime){this._atime=atime}get atime(){return this._atime}set mtime(mtime){this._mtime=mtime,this.ctime=new Date}get mtime(){return this._mtime}get perm(){return this.mode&~S_IFMT}set perm(perm){this.mode=this.mode&S_IFMT|perm&~S_IFMT,this.ctime=new Date}set nlink(nlink){this._nlink=nlink,this.ctime=new Date}get nlink(){return this._nlink}getString(encoding="utf8"){return this.atime=new Date,this.getBuffer().toString(encoding)}setString(str){this._setBuf((0,buffer_1.bufferFrom)(str,"utf8"))}getBuffer(){return this.atime=new Date,this.buf||(this.buf=(0,buffer_1.bufferAllocUnsafe)(0)),(0,buffer_1.bufferFrom)(this.buf.subarray(0,this.size))}setBuffer(buf){let copy=(0,buffer_1.bufferFrom)(buf);this._setBuf(copy)}_setBuf(buf){let size=buf.length;this.buf=buf,this.capacity=size,this.size=size,this.touch()}getSize(){return this.size}setModeProperty(property){this.mode=property}isFile(){return(this.mode&S_IFMT)===S_IFREG}isDirectory(){return(this.mode&S_IFMT)===S_IFDIR}isSymlink(){return(this.mode&S_IFMT)===S_IFLNK}isCharacterDevice(){return(this.mode&S_IFMT)===S_IFCHR}makeSymlink(symlink){this.mode=S_IFLNK|438,this.symlink=symlink}write(buf,off=0,len=buf.length,pos=0){let bufLength=buf.length;if(off+len>bufLength&&(len=bufLength-off),len<=0)return 0;let requiredSize=pos+len;if(requiredSize>this.capacity){let newCapacity=Math.max(this.capacity*2,64);for(;newCapacity<requiredSize;)newCapacity*=2;let newBuf=(0,buffer_1.bufferAllocUnsafe)(newCapacity);this.size>0&&this.buf.copy(newBuf,0,0,this.size),this.buf=newBuf,this.capacity=newCapacity}return pos>this.size&&this.buf.fill(0,this.size,pos),buf.copy(this.buf,pos,off,off+len),requiredSize>this.size&&(this.size=requiredSize),this.touch(),len}read(buf,off=0,len=buf.byteLength,pos=0){if(this.atime=new Date,pos>=this.size)return 0;let actualLen=len;if(actualLen>buf.byteLength&&(actualLen=buf.byteLength),actualLen+pos>this.size&&(actualLen=this.size-pos),actualLen<=0)return 0;let buf2=buf instanceof buffer_1.Buffer?buf:buffer_1.Buffer.from(buf.buffer,buf.byteOffset,buf.byteLength);return this.buf.copy(buf2,off,pos,pos+actualLen),actualLen}truncate(len=0){if(len<=0){this.buf=EMPTY_BUFFER,this.capacity=0,this.size=0,this.touch();return}if(len<=this.size)this.size=len;else{if(len>this.capacity){let newCapacity=Math.max(this.capacity*2,64);for(;newCapacity<len;)newCapacity*=2;let buf=(0,buffer_1.bufferAllocUnsafe)(newCapacity);this.size>0&&this.buf.copy(buf,0,0,this.size),buf.fill(0,this.size,len),this.buf=buf,this.capacity=newCapacity}else this.buf.fill(0,this.size,len);this.size=len}this.touch()}chmod(perm){this.mode=this.mode&S_IFMT|perm&~S_IFMT,this.touch()}chown(uid,gid){this.uid=uid,this.gid=gid,this.touch()}touch(){this.mtime=new Date,this.changes.emit(["modify"])}canRead(uid=getuid(),gid=getgid()){return!!(this.perm&4||gid===this.gid&&this.perm&32||uid===this.uid&&this.perm&256)}canWrite(uid=getuid(),gid=getgid()){return!!(this.perm&2||gid===this.gid&&this.perm&16||uid===this.uid&&this.perm&128)}canExecute(uid=getuid(),gid=getgid()){return!!(this.perm&1||gid===this.gid&&this.perm&8||uid===this.uid&&this.perm&64)}del(){this.changes.emit(["delete"])}toJSON(){return{ino:this.ino,uid:this.uid,gid:this.gid,atime:this.atime.getTime(),mtime:this.mtime.getTime(),ctime:this.ctime.getTime(),btime:this.btime.getTime(),perm:this.perm,mode:this.mode,nlink:this.nlink,symlink:this.symlink,data:this.getString()}}};exports.Node=Node3}});var require_Link=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/Link.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Link=void 0;var fs_node_utils_1=require_lib5(),fanout_1=require_fanout(),{S_IFREG}=fs_node_utils_1.constants,Link=class _Link{get steps(){return this._steps}set steps(val){this._steps=val;for(let[child,link2]of this.children.entries())child==="."||child===".."||link2?.syncSteps()}constructor(vol,parent,name){this.changes=new fanout_1.FanOut,this.children=new Map,this._steps=[],this.ino=0,this.length=0,this.vol=vol,this.parent=parent,this.name=name,this.syncSteps()}setNode(node2){this.node=node2,this.ino=node2.ino}getNode(){return this.node}createChild(name,node2=this.vol.createNode(S_IFREG|438)){let link2=new _Link(this.vol,this,name);return link2.setNode(node2),node2.isDirectory()&&(link2.children.set(".",link2),link2.getNode().nlink++),this.setChild(name,link2),link2}setChild(name,link2=new _Link(this.vol,this,name)){return this.children.set(name,link2),link2.parent=this,this.length++,link2.getNode().isDirectory()&&(link2.children.set("..",this),this.getNode().nlink++),this.getNode().mtime=new Date,this.changes.emit(["child:add",link2,this]),link2}deleteChild(link2){link2.getNode().isDirectory()&&(link2.children.delete(".."),this.getNode().nlink--),this.children.delete(link2.getName()),this.length--,this.getNode().mtime=new Date,this.changes.emit(["child:del",link2,this])}getChild(name){return this.getNode().atime=new Date,this.children.get(name)}getPath(){return this.steps.join("/")}getParentPath(){let parent=this.steps.slice(0,-1).join("/");return parent||"/"}getName(){return this.steps[this.steps.length-1]}toJSON(){return{steps:this.steps,ino:this.ino,children:Array.from(this.children.keys())}}syncSteps(){this.steps=this.parent?this.parent.steps.concat([this.name]):[this.name]}};exports.Link=Link}});var require_File=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/File.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.File=void 0;var fs_node_utils_1=require_lib5(),{O_APPEND}=fs_node_utils_1.constants,File=class{constructor(link2,node2,flags,fd){this.link=link2,this.node=node2,this.flags=flags,this.fd=fd,this.position=0}getString(encoding="utf8"){return this.node.getString()}setString(str){this.node.setString(str)}getBuffer(){return this.node.getBuffer()}setBuffer(buf){this.node.setBuffer(buf)}getSize(){return this.node.getSize()}truncate(len){this.node.truncate(len)}seekTo(position2){this.position=position2}write(buf,offset=0,length=buf.length,position2){let append=!!(this.flags&O_APPEND),explicit=!append&&typeof position2=="number",pos=append?this.node.getSize():explicit?position2:this.position,bytes=this.node.write(buf,offset,length,pos);return explicit||(this.position=pos+bytes),bytes}read(buf,offset=0,length=buf.byteLength,position2){let explicit=typeof position2=="number",pos=explicit?position2:this.position,bytes=this.node.read(buf,offset,length,pos);return explicit||(this.position=pos+bytes),bytes}chmod(perm){this.node.chmod(perm)}chown(uid,gid){this.node.chown(uid,gid)}};exports.File=File}});var require_validators=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/validators.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.validateAbortSignal=exports.validateBuffer=exports.validateStringArray=exports.validateArray=exports.validateOneOf=exports.validateObject=exports.validateFunction=exports.validateBoolean=exports.validateString=exports.validateUint32=exports.validateInt32=exports.validateInteger=exports.INT32_MAX=void 0;var argErrors_1=require_argErrors();exports.INT32_MAX=2147483647;var INT32_MIN=-2147483648,UINT32_MAX=4294967295,MAX_SAFE=9007199254740991,validateRange=(value2,name,min,max)=>{if(typeof value2!="number")throw(0,argErrors_1.invalidArgType)(name,"of type number",value2);if(!Number.isInteger(value2))throw(0,argErrors_1.outOfRange)(name,"an integer",value2);if(value2<min||value2>max)throw(0,argErrors_1.outOfRange)(name,">= "+min+" && <= "+max,value2)},validateInteger=(value2,name,min=-MAX_SAFE,max=MAX_SAFE)=>validateRange(value2,name,min,max);exports.validateInteger=validateInteger;var validateInt32=(value2,name,min=INT32_MIN,max=exports.INT32_MAX)=>validateRange(value2,name,min,max);exports.validateInt32=validateInt32;var validateUint32=(value2,name,positive)=>validateRange(value2,name,positive?1:0,UINT32_MAX);exports.validateUint32=validateUint32;var validateString=(value2,name)=>{if(typeof value2!="string")throw(0,argErrors_1.invalidArgType)(name,"of type string",value2)};exports.validateString=validateString;var validateBoolean=(value2,name)=>{if(typeof value2!="boolean")throw(0,argErrors_1.invalidArgType)(name,"of type boolean",value2)};exports.validateBoolean=validateBoolean;var validateFunction=(value2,name)=>{if(typeof value2!="function")throw(0,argErrors_1.invalidArgType)(name,"of type function",value2)};exports.validateFunction=validateFunction;var validateObject=(value2,name,options2=0)=>{if(value2===null&&!(options2&1)||Array.isArray(value2)&&!(options2&2)||value2!==null&&typeof value2!="object"&&(typeof value2!="function"||!(options2&4)))throw(0,argErrors_1.invalidArgType)(name,"of type object",value2)};exports.validateObject=validateObject;var validateOneOf=(value2,name,oneOf)=>{if(oneOf.includes(value2))return;let allowed="";for(let i2=0;i2<oneOf.length;i2++){let one2=oneOf[i2];allowed+=(i2?", ":"")+(typeof one2=="string"?"'"+one2+"'":String(one2))}throw(0,argErrors_1.invalidArgValue)(name,value2,"must be one of: "+allowed)};exports.validateOneOf=validateOneOf;var validateArray=(value2,name,minLength=0)=>{if(!Array.isArray(value2))throw(0,argErrors_1.invalidArgType)(name,"an instance of Array",value2);if(value2.length<minLength)throw(0,argErrors_1.invalidArgValue)(name,value2,"must have a length of at least "+minLength)};exports.validateArray=validateArray;var validateStringArray=(value2,name)=>{(0,exports.validateArray)(value2,name);let array=value2;for(let i2=0;i2<array.length;i2++)if(typeof array[i2]!="string")throw(0,argErrors_1.invalidArgType)(name+"["+i2+"]","of type string",array[i2])};exports.validateStringArray=validateStringArray;var validateBuffer=(buffer,name="buffer")=>{if(!ArrayBuffer.isView(buffer))throw(0,argErrors_1.invalidArgType)(name,"an instance of Buffer, TypedArray, or DataView",buffer)};exports.validateBuffer=validateBuffer;var validateAbortSignal=(signal,name)=>{if(signal!==void 0&&(signal===null||typeof signal!="object"||!("aborted"in signal)))throw(0,argErrors_1.invalidArgType)(name,"an instance of AbortSignal",signal)};exports.validateAbortSignal=validateAbortSignal}});var require_util=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/util.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.filenameToSteps=exports.resolve=exports.unixify=exports.isWin=void 0;exports.isFd=isFd;exports.validateFd=validateFd;exports.dataToBuffer=dataToBuffer;exports.nullCheck=nullCheck;exports.pathToFilename=pathToFilename;var path_1=require_path2(),buffer_1=require_buffer3(),process_1=require_process(),fs_node_utils_1=require_lib5(),argErrors_1=require_argErrors(),validators_1=require_validators();exports.isWin=process_1.default.platform==="win32";var resolveCrossPlatform=path_1.resolve,isSeparator=(str,i2)=>{let char=str[i2];return i2>0&&(char==="/"||exports.isWin&&char==="\\")},removeTrailingSeparator=str=>{let i2=str.length-1;if(i2<2)return str;for(;isSeparator(str,i2);)i2--;return str.substr(0,i2+1)},normalizePath2=(str,stripTrailing)=>{if(typeof str!="string")throw new TypeError("expected a string");return str=str.replace(/[\\\/]+/g,"/"),stripTrailing!==!1&&(str=removeTrailingSeparator(str)),str},unixify=(filepath,stripTrailing=!0)=>exports.isWin?(filepath=normalizePath2(filepath,stripTrailing),filepath.replace(/^([a-zA-Z]+:|\.\/)/,"")):filepath;exports.unixify=unixify;var resolve2=(filename,base2=process_1.default.cwd())=>resolveCrossPlatform(base2,filename);exports.resolve=resolve2;if(exports.isWin){let _resolve=resolve2;exports.resolve=resolve2=(filename,base2)=>(0,exports.unixify)(_resolve(filename,base2))}var filenameToSteps=(filename,base2)=>{let fullPathSansSlash=resolve2(filename,base2).substring(1);return fullPathSansSlash?fullPathSansSlash.split(fs_node_utils_1.pathSep):[]};exports.filenameToSteps=filenameToSteps;function isFd(path4){return path4>>>0===path4}function validateFd(fd){if(typeof fd!="number")throw(0,argErrors_1.invalidArgType)("fd","of type number",fd,!0);if((fd<0||fd>validators_1.INT32_MAX)&&fd!==1/0&&fd!==-1/0)throw(0,argErrors_1.outOfRange)("fd",">= 0 && <= "+validators_1.INT32_MAX,fd,!0);if(!Number.isInteger(fd))throw(0,argErrors_1.outOfRange)("fd","an integer",fd,!0)}function dataToBuffer(data,encoding=fs_node_utils_1.ENCODING_UTF8){return buffer_1.Buffer.isBuffer(data)?data:data instanceof Uint8Array?(0,buffer_1.bufferFrom)(data):encoding==="buffer"?(0,buffer_1.bufferFrom)(String(data),"utf8"):(0,buffer_1.bufferFrom)(String(data),encoding)}var NO_NULL_BYTES="must be a string, Uint8Array, or URL without null bytes",checkNullByte=(path4,name,received)=>{if(path4.indexOf("\0")!==-1)throw(0,argErrors_1.invalidArgValue)(name,received,NO_NULL_BYTES)};function nullCheck(path4,name="path"){if(path4 instanceof Uint8Array){for(let i2=0;i2<path4.length;i2++)if(!path4[i2])throw(0,argErrors_1.invalidArgValue)(name,path4,NO_NULL_BYTES);return!0}let str=""+path4;return checkNullByte(str,name,str),!0}var isURL=value2=>!!value2&&!!value2.href&&!!value2.protocol&&value2.auth===void 0&&value2.path===void 0,getPathFromURL=url=>{if(url.protocol!=="file:")throw(0,argErrors_1.invalidUrlScheme)("file");if(url.hostname!=="")throw(0,argErrors_1.withCode)(new TypeError('File URL host must be "localhost" or empty on '+process_1.default.platform),"ERR_INVALID_FILE_URL_HOST");let pathname=url.pathname;for(let n2=0;n2<pathname.length;n2++)if(pathname[n2]==="%"){let third=pathname.codePointAt(n2+2)|32;if(pathname[n2+1]==="2"&&third===102)throw(0,argErrors_1.withCode)(new TypeError("File URL path must not include encoded / characters"),"ERR_INVALID_FILE_URL_PATH")}let filepath=decodeURIComponent(pathname);return exports.isWin?filepath.replace(/^\/([a-zA-Z]:)/,"$1"):filepath};function pathToFilename(path4,name="path"){let received=path4;if(path4 instanceof Uint8Array&&(path4=(0,buffer_1.bufferFrom)(path4)),typeof path4!="string"&&!buffer_1.Buffer.isBuffer(path4)){if(!isURL(path4))throw(0,argErrors_1.invalidArgType)(name,"of type string or an instance of Buffer or URL",path4);path4=getPathFromURL(path4)}let pathString=String(path4);return checkNullByte(pathString,name,received instanceof Uint8Array?received:pathString),pathString}}});var require_SystemError=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/SystemError.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.SystemError=void 0;var SystemError=class extends Error{constructor(code4,prefix,info){let path4=info.path,dest=info.dest,message=prefix+": "+info.syscall+" returned "+info.code+" ("+info.message+")";path4!==void 0&&(message+=" "+path4),dest!==void 0&&(message+=" => "+dest),super(message),this.code=code4,this.info=info,this.errno=info.errno,this.syscall=info.syscall,path4!==void 0&&(this.path=path4),dest!==void 0&&(this.dest=dest)}toString(){return this.name+" ["+this.code+"]: "+this.message}};exports.SystemError=SystemError;SystemError.prototype.name="SystemError"}});var require_errors=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/errors.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.createEisdirError=exports.createWatchError=exports.createStatError=exports.createError=void 0;var SystemError_1=require_SystemError(),UV={EPERM:[-1,"operation not permitted"],ENOENT:[-2,"no such file or directory"],EIO:[-5,"i/o error"],EBADF:[-9,"bad file descriptor"],EAGAIN:[-11,"resource temporarily unavailable"],EACCES:[-13,"permission denied"],EBUSY:[-16,"resource busy or locked"],EEXIST:[-17,"file already exists"],EXDEV:[-18,"cross-device link not permitted"],ENOTDIR:[-20,"not a directory"],EISDIR:[-21,"illegal operation on a directory"],EINVAL:[-22,"invalid argument"],ENFILE:[-23,"file table overflow"],EMFILE:[-24,"too many open files"],ETXTBSY:[-26,"text file is busy"],EFBIG:[-27,"file too large"],ENOSPC:[-28,"no space left on device"],ESPIPE:[-29,"invalid seek"],EROFS:[-30,"read-only file system"],EMLINK:[-31,"too many links"],ERANGE:[-34,"result too large"],ENAMETOOLONG:[-36,"name too long"],ENOSYS:[-38,"function not implemented"],ENOTEMPTY:[-39,"directory not empty"],ELOOP:[-40,"too many symbolic links encountered"],EPROTO:[-71,"protocol error"],EOVERFLOW:[-75,"value too large for defined data type"],ENOTSUP:[-95,"operation not supported on socket"]},formatMessage=(code4,uv,syscall,path4,dest)=>{let message=code4+": "+(uv?uv[1]:"unknown error")+", "+syscall;return path4&&(message+=" '"+path4+"'"),dest&&(message+=" -> '"+dest+"'"),message},createError=(code4,syscall="",path4="",dest="",Constructor=Error)=>{let uv=UV[code4],error=new Constructor(formatMessage(code4,uv,syscall,path4,dest));return uv&&(error.errno=uv[0]),error.code=code4,error.syscall=syscall,path4&&(error.path=path4),dest&&(error.dest=dest),error};exports.createError=createError;var createStatError=(code4,syscall="",path4="",dest="")=>{let uv=UV[code4];return{errno:uv?uv[0]:void 0,code:code4,syscall,path:path4,dest,message:formatMessage(code4,uv,syscall,path4,dest),toError:()=>(0,exports.createError)(code4,syscall,path4,dest)}};exports.createStatError=createStatError;var createWatchError=(code4,filename)=>{let uv=UV[code4],error=new Error(formatMessage(code4,uv,"watch",filename,""));return uv&&(error.errno=uv[0]),error.syscall="watch",error.code=code4,error.path=filename,error.filename=filename,error};exports.createWatchError=createWatchError;var createEisdirError=(syscall,path4)=>new SystemError_1.SystemError("ERR_FS_EISDIR","Path is a directory",{code:"EISDIR",message:"is a directory",path:path4,syscall,errno:-UV.EISDIR[0]});exports.createEisdirError=createEisdirError}});var require_FsEvent=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/watch/FsEvent.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FsEvent=void 0;var FsEvent=class{constructor(type,steps,node2,link2,oldSteps=void 0){this.type=type,this.steps=steps,this.node=node2,this.link=link2,this.oldSteps=oldSteps}};exports.FsEvent=FsEvent}});var require_Superblock=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/Superblock.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Superblock=void 0;var path_1=require_path2(),Node_1=require_Node(),Link_1=require_Link(),File_1=require_File(),buffer_1=require_buffer3(),process_1=require_process(),fs_node_utils_1=require_lib5(),fs_node_utils_2=require_lib5(),util_1=require_util(),errors_1=require_errors(),argErrors_1=require_argErrors(),json_1=require_json(),result_1=require_result2(),fanout_1=require_fanout(),FsEvent_1=require_FsEvent(),{O_RDONLY,O_WRONLY,O_RDWR,O_CREAT,O_EXCL,O_TRUNC,O_DIRECTORY,O_NOFOLLOW}=fs_node_utils_1.constants,MAX_SYMLINK_HOPS=40,endsWithSep=(path4,win32)=>{let i2=path4.length-1;if(i2<1)return!1;let code4=path4.charCodeAt(i2);return code4===46&&(code4=path4.charCodeAt(--i2)),code4===47||win32&&code4===92},Superblock=class _Superblock{static fromJSON(json,cwd2,opts){let vol=new _Superblock(opts);return vol.fromJSON(json,cwd2),vol}static fromNestedJSON(json,cwd2,opts){let vol=new _Superblock(opts);return vol.fromNestedJSON(json,cwd2),vol}constructor(opts={}){this.ino=0,this.inodes={},this.releasedInos=[],this.fds={},this.releasedFds=[],this.maxFiles=1e4,this.openFiles=0,this.changes=new fanout_1.FanOut,this.open=(filename,flagsNum,modeNum,resolveSymlinks=!0)=>{let file=this.openFile(filename,flagsNum,modeNum,resolveSymlinks);if(!file)throw(0,errors_1.createError)("ENOENT","open",filename);return file.fd},this.writeFile=(id,buf,flagsNum,modeNum)=>{let isUserFd=typeof id=="number",fd;isUserFd?fd=id:fd=this.open((0,util_1.pathToFilename)(id),flagsNum,modeNum);let offset=0,length=buf.length;try{for(;length>0;){let written=this.write(fd,buf,offset,length,null);offset+=written,length-=written}}finally{isUserFd||this.close(fd)}},this.read=(fd,buffer,offset,length,position2)=>{if(offset<0)throw(0,argErrors_1.outOfRange)("offset",">= 0 && <= 9007199254740991",offset);if(length===0)return 0;if(length<0)throw(0,argErrors_1.outOfRange)("length",">= 0",length);if(offset+length>buffer.byteLength)throw(0,argErrors_1.outOfRange)("length","<= "+(buffer.byteLength-offset),length);let file=this.getFileByFdOrThrow(fd,"read");if(file.node.isSymlink())throw(0,errors_1.createError)("EPERM","read",file.link.getPath());return file.read(buffer,Number(offset),Number(length),position2===-1||typeof position2!="number"?void 0:position2)},this.readv=(fd,buffers,position2)=>{let file=this.getFileByFdOrThrow(fd,"read"),p2=position2??void 0;p2===-1&&(p2=void 0);let bytesRead=0;for(let buffer of buffers){let bytes=file.read(buffer,0,buffer.byteLength,p2);if(p2!==void 0&&(p2+=bytes),bytesRead+=bytes,bytes<buffer.byteLength)break}return bytesRead},this.link=(filename1,filename2)=>{let link1;try{link1=this.getLinkOrThrow(filename1,"link")}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"link",filename1,filename2)),err}let dirname22=(0,path_1.dirname)(filename2),dir2;try{dir2=this.getLinkOrThrow(dirname22,"link")}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"link",filename1,filename2)),err}let name=(0,path_1.basename)(filename2);if(dir2.getChild(name))throw(0,errors_1.createError)("EEXIST","link",filename1,filename2);let node2=link1.getNode();node2.nlink++;let newLink=dir2.createChild(name,node2);this.emit(new FsEvent_1.FsEvent(0,newLink.steps,node2,newLink))},this.unlink=filename=>{let link2=this.getLinkOrThrow(filename,"unlink");if(link2.getNode().isDirectory())throw(0,errors_1.createError)("EPERM","unlink",filename);this._emitDeleteRecursive(link2),this.deleteLink(link2);let node2=link2.getNode();node2.nlink--,node2.nlink<=0&&this.deleteNode(node2)},this.symlink=(targetFilename,pathFilename)=>{if(!targetFilename)throw(0,errors_1.createError)("ENOENT","symlink",targetFilename,pathFilename);let pathSteps=this.filenameToSteps(pathFilename),dirLink;try{dirLink=this.getLinkParentAsDirOrThrow(pathSteps)}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"symlink",targetFilename,pathFilename)),err}let name=pathSteps[pathSteps.length-1];if(dirLink.getChild(name))throw(0,errors_1.createError)("EEXIST","symlink",targetFilename,pathFilename);let node2=dirLink.getNode();if(!node2.canExecute()||!node2.canWrite())throw(0,errors_1.createError)("EACCES","symlink",targetFilename,pathFilename);let symlink=dirLink.createChild(name);return symlink.getNode().makeSymlink(targetFilename),this.emit(new FsEvent_1.FsEvent(0,symlink.steps,symlink.getNode(),symlink)),symlink},this.rename=(oldPathFilename,newPathFilename)=>{let link2;try{link2=this.getResolvedLinkOrThrow(oldPathFilename)}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"rename",oldPathFilename,newPathFilename)),err}let newPathDirLink;try{newPathDirLink=this.getLinkParentAsDirOrThrow(newPathFilename)}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"rename",oldPathFilename,newPathFilename)),err}let oldLinkParent=link2.parent;if(!oldLinkParent)throw(0,errors_1.createError)("EINVAL","rename",oldPathFilename,newPathFilename);let oldParentNode=oldLinkParent.getNode(),newPathDirNode=newPathDirLink.getNode();if(!oldParentNode.canExecute()||!oldParentNode.canWrite()||!newPathDirNode.canExecute()||!newPathDirNode.canWrite())throw(0,errors_1.createError)("EACCES","rename",oldPathFilename,newPathFilename);oldLinkParent.deleteChild(link2);let name=(0,path_1.basename)(newPathFilename),oldSteps=link2.steps;link2.name=name,link2.steps=[...newPathDirLink.steps,name],newPathDirLink.setChild(link2.getName(),link2),this.emit(new FsEvent_1.FsEvent(4,link2.steps,link2.getNode(),link2,oldSteps))},this.mkdir=(filename,modeNum)=>{let steps=this.filenameToSteps(filename);if(!steps.length)throw(0,errors_1.createError)("EEXIST","mkdir",filename);let dir=this.getLinkParentAsDirOrThrow(filename,"mkdir"),name=steps[steps.length-1];if(dir.getChild(name))throw(0,errors_1.createError)("EEXIST","mkdir",filename);let node2=dir.getNode();if(!node2.canWrite()||!node2.canExecute())throw(0,errors_1.createError)("EACCES","mkdir",filename);let child=dir.createChild(name,this.createNode(fs_node_utils_1.constants.S_IFDIR|modeNum));this.emit(new FsEvent_1.FsEvent(0,child.steps,child.getNode(),child))},this.mkdirp=(filename,modeNum)=>{let created=!1,steps=this.filenameToSteps(filename),curr=null,i2=steps.length;for(i2=steps.length;i2>=0&&(curr=this.getResolvedLink(steps.slice(0,i2)),!curr);i2--);for(curr||(curr=this.root,i2=0),curr=this.getResolvedLinkOrThrow(fs_node_utils_2.pathSep+steps.slice(0,i2).join(fs_node_utils_2.pathSep),"mkdir"),i2;i2<steps.length;i2++){let node2=curr.getNode();if(node2.isDirectory()){if(!node2.canExecute()||!node2.canWrite())throw(0,errors_1.createError)("EACCES","mkdir",filename)}else throw(0,errors_1.createError)("ENOTDIR","mkdir",filename);created=!0,curr=curr.createChild(steps[i2],this.createNode(fs_node_utils_1.constants.S_IFDIR|modeNum)),this.emit(new FsEvent_1.FsEvent(0,curr.steps,curr.getNode(),curr))}return created?filename:void 0},this.rmdir=(filename,recursive=!1)=>{let link2=this.getLinkAsDirOrThrow(filename,"rmdir");if(link2.length&&!recursive)throw(0,errors_1.createError)("ENOTEMPTY","rmdir",filename);this._emitDeleteRecursive(link2),this.deleteLink(link2)},this.rm=(filename,force=!1,recursive=!1)=>{let link2;try{link2=this.getResolvedLinkOrThrow(filename,"lstat")}catch(err){if(err.code==="ENOENT"&&force)return;throw err}if(link2.getNode().isDirectory()&&!recursive)throw(0,errors_1.createEisdirError)("rm",filename);if(!link2.parent?.getNode().canWrite())throw(0,errors_1.createError)("EACCES","rm",filename);this._emitDeleteRecursive(link2),this.deleteLink(link2)},this.close=fd=>{(0,util_1.validateFd)(fd);let file=this.getFileByFdOrThrow(fd,"close");this.closeFile(file)},this.ftruncate=(fd,len)=>{let file=this.getFileByFdOrThrow(fd,"ftruncate");file.truncate(len),this.emit(new FsEvent_1.FsEvent(2,file.link.steps,file.node,file.link))},this.fchmod=(fd,modeNum)=>{let file=this.getFileByFdOrThrow(fd,"fchmod");file.chmod(modeNum),this.emit(new FsEvent_1.FsEvent(3,file.link.steps,file.node,file.link))},this.chmod=(filename,modeNum)=>{let link2=this.getResolvedLinkOrThrow(filename,"chmod");link2.getNode().chmod(modeNum),this.emit(new FsEvent_1.FsEvent(3,link2.steps,link2.getNode(),link2))},this.lchmod=(filename,modeNum)=>{let link2=this.getLinkOrThrow(filename,"lchmod");link2.getNode().chmod(modeNum),this.emit(new FsEvent_1.FsEvent(3,link2.steps,link2.getNode(),link2))},this.fchown=(fd,uid,gid)=>{let file=this.getFileByFdOrThrow(fd,"fchown");file.chown(uid,gid),this.emit(new FsEvent_1.FsEvent(3,file.link.steps,file.node,file.link))},this.chown=(filename,uid,gid)=>{let link2=this.getResolvedLinkOrThrow(filename,"chown");link2.getNode().chown(uid,gid),this.emit(new FsEvent_1.FsEvent(3,link2.steps,link2.getNode(),link2))},this.lchown=(filename,uid,gid)=>{let link2=this.getLinkOrThrow(filename,"lchown");link2.getNode().chown(uid,gid),this.emit(new FsEvent_1.FsEvent(3,link2.steps,link2.getNode(),link2))},this.futimes=(fd,atime,mtime)=>{let file=this.getFileByFdOrThrow(fd,"futime"),node2=file.node;node2.atime=new Date(atime*1e3),node2.mtime=new Date(mtime*1e3),this.emit(new FsEvent_1.FsEvent(3,file.link.steps,file.node,file.link))},this.utimes=(filename,atime,mtime,followSymlinks=!0)=>{let link2=followSymlinks?this.getResolvedLinkOrThrow(filename,"utime"):this.getLinkOrThrow(filename,"lutime"),node2=link2.getNode();node2.atime=new Date(atime*1e3),node2.mtime=new Date(mtime*1e3),this.emit(new FsEvent_1.FsEvent(3,link2.steps,node2,link2))},this.process=opts.process??process_1.default;let root4=this.createLink();root4.setNode(this.createNode(fs_node_utils_1.constants.S_IFDIR|511)),root4.setChild(".",root4),root4.getNode().nlink++,root4.setChild("..",root4),root4.getNode().nlink++,this.root=root4}filenameToSteps(filename){return(0,util_1.filenameToSteps)(filename,this.process.cwd())}emit(change){this.changes.emit(change)}createLink(parent,name,isDirectory=!1,mode){if(!parent)return new Link_1.Link(this,void 0,"");if(!name)throw new Error("createLink: name cannot be empty");let finalPerm=mode??(isDirectory?511:438),modeType=mode&&mode&fs_node_utils_1.constants.S_IFMT?mode&fs_node_utils_1.constants.S_IFMT:isDirectory?fs_node_utils_1.constants.S_IFDIR:fs_node_utils_1.constants.S_IFREG,finalMode=finalPerm&~fs_node_utils_1.constants.S_IFMT|modeType;return parent.createChild(name,this.createNode(finalMode))}deleteLink(link2){let parent=link2.parent;return parent?(parent.deleteChild(link2),!0):!1}_emitDeleteRecursive(link2){if(link2.getNode().isDirectory())for(let[name,child]of link2.children.entries())child&&name!=="."&&name!==".."&&this._emitDeleteRecursive(child);this.emit(new FsEvent_1.FsEvent(1,link2.steps,link2.getNode(),link2))}newInoNumber(){let releasedFd=this.releasedInos.pop();return releasedFd||(this.ino=(this.ino+1)%4294967295,this.ino)}newFdNumber(){let releasedFd=this.releasedFds.pop();return typeof releasedFd=="number"?releasedFd:_Superblock.fd--}createNode(mode){let uid=this.process.getuid?.()??0,gid=this.process.getgid?.()??0,node2=new Node_1.Node(this.newInoNumber(),mode,uid,gid);return this.inodes[node2.ino]=node2,node2}deleteNode(node2){node2.del(),delete this.inodes[node2.ino],this.releasedInos.push(node2.ino)}walk(stepsOrFilenameOrLink,resolveSymlinks=!1,checkExistence=!1,checkAccess=!1,funcName,budget){let steps,filename;stepsOrFilenameOrLink instanceof Link_1.Link?(steps=stepsOrFilenameOrLink.steps,filename=fs_node_utils_2.pathSep+steps.join(fs_node_utils_2.pathSep)):typeof stepsOrFilenameOrLink=="string"?(steps=this.filenameToSteps(stepsOrFilenameOrLink),filename=stepsOrFilenameOrLink):(steps=stepsOrFilenameOrLink,filename=fs_node_utils_2.pathSep+steps.join(fs_node_utils_2.pathSep));let curr=this.root,i2=0,hops=budget?budget.hops:0,uid=this.process.getuid?.()??0,gid=this.process.getgid?.()??0;for(;i2<steps.length;){let node2=curr.getNode();if(node2.isDirectory()){if(checkAccess&&!node2.canExecute(uid,gid))return(0,result_1.Err)((0,errors_1.createStatError)("EACCES",funcName,filename))}else if(i2<steps.length-1)return(0,result_1.Err)((0,errors_1.createStatError)("ENOTDIR",funcName,filename));if(curr=curr.getChild(steps[i2])??null,!curr)return checkExistence?(0,result_1.Err)((0,errors_1.createStatError)("ENOENT",funcName,filename)):(0,result_1.Ok)(null);if(node2=curr?.getNode(),node2.isSymlink()&&(resolveSymlinks||i2<steps.length-1)){if(++hops>MAX_SYMLINK_HOPS)return(0,result_1.Err)((0,errors_1.createStatError)("ELOOP",funcName,filename));budget&&(budget.hops=hops);let resolvedPath=(0,path_1.isAbsolute)(node2.symlink)?node2.symlink:(0,fs_node_utils_2.pathJoin)((0,path_1.dirname)(curr.getPath()),node2.symlink);steps=this.filenameToSteps(resolvedPath).concat(steps.slice(i2+1)),curr=this.root,i2=0;continue}if(checkExistence&&!node2.isDirectory()&&i2<steps.length-1){let errorCode=this.process.platform==="win32"?"ENOENT":"ENOTDIR";return(0,result_1.Err)((0,errors_1.createStatError)(errorCode,funcName,filename))}i2++}return(0,result_1.Ok)(curr)}getLink(steps){let result=this.walk(steps,!1,!1,!1);if(result.ok)return result.value;throw result.err.toError()}getLinkOrThrow(filename,funcName){let result=this.walk(filename,!1,!0,!0,funcName);if(result.ok)return result.value;throw result.err.toError()}getResolvedLink(filenameOrSteps){let result=this.walk(filenameOrSteps,!0,!1,!1);if(result.ok)return result.value;throw result.err.toError()}getResolvedLinkOrThrow(filename,funcName){let result=this.walk(filename,!0,!0,!0,funcName);if(result.ok)return result.value;throw result.err.toError()}getResolvedLinkResult(filename,funcName){let result=this.walk(filename,!0,!0,!0,funcName);return result.ok?(0,result_1.Ok)(result.value):result}resolveSymlinks(link2){return this.getResolvedLink(link2.steps.slice(1))}getLinkAsDirOrThrow(filename,funcName){let link2=this.getLinkOrThrow(filename,funcName);if(!link2.getNode().isDirectory())throw(0,errors_1.createError)("ENOTDIR",funcName,filename);return link2}getLinkParent(steps){return this.getLink(steps.slice(0,-1))}getLinkParentAsDirOrThrow(filenameOrSteps,funcName){let steps=(filenameOrSteps instanceof Array?filenameOrSteps:this.filenameToSteps(filenameOrSteps)).slice(0,-1),filename=fs_node_utils_2.pathSep+steps.join(fs_node_utils_2.pathSep),link2=this.getLinkOrThrow(filename,funcName);if(!link2.getNode().isDirectory())throw(0,errors_1.createError)("ENOTDIR",funcName,filename);return link2}getFileByFd(fd){return this.fds[String(fd)]}getFileByFdOrThrow(fd,funcName){(0,util_1.validateFd)(fd);let file=this.getFileByFd(fd);if(!file)throw(0,errors_1.createError)("EBADF",funcName);return file}_toJSON(link2=this.root,json={},path4,asBuffer){let isEmpty2=!0,children=link2.children;link2.getNode().isFile()&&(children=new Map([[link2.getName(),link2.parent.getChild(link2.getName())]]),link2=link2.parent);for(let name of children.keys()){if(name==="."||name==="..")continue;isEmpty2=!1;let child=link2.getChild(name);if(!child)throw new Error("_toJSON: unexpected undefined");let node2=child.getNode();if(node2.isFile()){let filename=child.getPath();path4&&(filename=(0,fs_node_utils_2.pathRelative)(path4,filename)),json[filename]=asBuffer?node2.getBuffer():node2.getString()}else node2.isDirectory()&&this._toJSON(child,json,path4,asBuffer)}let dirPath=link2.getPath();return path4&&(dirPath=(0,fs_node_utils_2.pathRelative)(path4,dirPath)),dirPath&&isEmpty2&&(json[dirPath]=null),json}toJSON(paths,json={},isRelative=!1,asBuffer=!1){let links=[];if(paths){Array.isArray(paths)||(paths=[paths]);for(let path4 of paths){let filename=(0,util_1.pathToFilename)(path4),link2=this.getResolvedLink(filename);link2&&links.push(link2)}}else links.push(this.root);if(!links.length)return json;for(let link2 of links)this._toJSON(link2,json,isRelative?link2.getPath():"",asBuffer);return json}fromJSON(json,cwd2=this.process.cwd()){for(let filename in json){let data=json[filename];if(filename=(0,util_1.resolve)(filename,cwd2),typeof data=="string"||data instanceof buffer_1.Buffer){let dir=(0,path_1.dirname)(filename);this.mkdirp(dir,511);let buffer=(0,util_1.dataToBuffer)(data);this.writeFile(filename,buffer,fs_node_utils_2.FLAGS.w,438)}else this.mkdirp(filename,511)}}fromNestedJSON(json,cwd2){this.fromJSON((0,json_1.flattenJSON)(json),cwd2)}reset(){this.ino=0,this.inodes={},this.releasedInos=[],this.fds={},this.releasedFds=[],this.openFiles=0,this.root=this.createLink(),this.root.setNode(this.createNode(fs_node_utils_1.constants.S_IFDIR|511))}mountSync(mountpoint,json){this.fromJSON(json,mountpoint)}openLink(link2,flagsNum,resolveSymlinks=!0,filename=link2.getPath()){if(this.openFiles>=this.maxFiles)throw(0,errors_1.createError)("EMFILE","open",filename);let realLink=link2;resolveSymlinks&&(realLink=this.getResolvedLinkOrThrow(link2.getPath(),"open"));let node2=realLink.getNode();if(node2.isDirectory()){if((flagsNum&(O_RDONLY|O_RDWR|O_WRONLY))!==O_RDONLY)throw(0,errors_1.createError)("EISDIR","open",filename)}else if(flagsNum&O_DIRECTORY)throw(0,errors_1.createError)("ENOTDIR","open",filename);if(node2.isSymlink()&&flagsNum&O_NOFOLLOW)throw(0,errors_1.createError)("ELOOP","open",filename);if((flagsNum&(O_RDONLY|O_RDWR|O_WRONLY))!==O_WRONLY&&!node2.canRead()||flagsNum&(O_WRONLY|O_RDWR)&&!node2.canWrite())throw(0,errors_1.createError)("EACCES","open",filename);let file=new File_1.File(link2,node2,flagsNum,this.newFdNumber());if(this.fds[file.fd]=file,this.openFiles++,flagsNum&O_TRUNC){let hadContent=file.node.getSize()>0;file.truncate(),hadContent&&this.emit(new FsEvent_1.FsEvent(2,file.link.steps,file.node,file.link))}return file}throwCreatDir(path4,filename,budget){let dir=this.walk((0,path_1.dirname)(path4),!0,!0,!0,"open",budget);if(!dir.ok)throw(0,errors_1.createError)(dir.err.code,"open",filename);let node2=dir.value.getNode();throw node2.isDirectory()?node2.canExecute()?(0,errors_1.createError)("EISDIR","open",filename):(0,errors_1.createError)("EACCES","open",filename):(0,errors_1.createError)("ENOTDIR","open",filename)}openFile(filename,flagsNum,modeNum,resolveSymlinks=!0){if(this.openFiles>=this.maxFiles)throw(0,errors_1.createError)("EMFILE","open",filename);if((flagsNum&(O_CREAT|O_DIRECTORY))===(O_CREAT|O_DIRECTORY))throw(0,errors_1.createError)("EINVAL","open",filename);let win32=this.process.platform==="win32",budget={hops:0},trailingSlash=endsWithSep(filename,win32);trailingSlash&&flagsNum&O_CREAT&&this.throwCreatDir(filename,filename,budget);let excl=(flagsNum&(O_CREAT|O_EXCL))===(O_CREAT|O_EXCL),follow=trailingSlash||resolveSymlinks&&!(flagsNum&O_NOFOLLOW)&&!excl,path4=filename,link2=null;for(;;){let hops=budget.hops,result=this.walk(path4,!1,!0,!0,"open",budget);if(!result.ok){let code4=result.err.code;if(code4!=="ENOENT"||!(flagsNum&O_CREAT))throw(0,errors_1.createError)(code4,"open",filename);budget.hops=hops,link2=null;break}link2=result.value;let node2=link2.getNode();if(!follow||!node2.isSymlink())break;if(++budget.hops>MAX_SYMLINK_HOPS)throw(0,errors_1.createError)("ELOOP","open",filename);path4=(0,path_1.isAbsolute)(node2.symlink)?node2.symlink:(0,fs_node_utils_2.pathJoin)((0,path_1.dirname)(link2.getPath()),node2.symlink),endsWithSep(path4,win32)&&(flagsNum&O_CREAT&&this.throwCreatDir(path4,filename,budget),trailingSlash=!0)}if(link2){let node2=link2.getNode();if(excl)throw(0,errors_1.createError)("EEXIST","open",filename);if(trailingSlash&&!node2.isDirectory())throw(0,errors_1.createError)("ENOTDIR","open",filename);if(flagsNum&O_CREAT&&node2.isDirectory())throw(0,errors_1.createError)("EISDIR","open",filename);return this.openLink(link2,flagsNum,!1,filename)}let dir=this.walk((0,path_1.dirname)(path4),!0,!0,!0,"open",budget);if(!dir.ok)throw(0,errors_1.createError)(dir.err.code,"open",filename);let dirLink=dir.value,dirNode=dirLink.getNode();if(!dirNode.isDirectory())throw(0,errors_1.createError)("ENOTDIR","open",filename);if(!dirNode.canExecute()||!dirNode.canWrite())throw(0,errors_1.createError)("EACCES","open",filename);modeNum??(modeNum=438);let steps=(0,util_1.filenameToSteps)(path4);return link2=this.createLink(dirLink,steps[steps.length-1],!1,modeNum),this.emit(new FsEvent_1.FsEvent(0,link2.steps,link2.getNode(),link2)),this.openLink(link2,flagsNum,!1,filename)}closeFile(file){this.fds[file.fd]&&(this.openFiles--,delete this.fds[file.fd],this.releasedFds.push(file.fd))}write(fd,buf,offset,length,position2){let file=this.getFileByFdOrThrow(fd,"write");if(file.node.isSymlink())throw(0,errors_1.createError)("EBADF","write",file.link.getPath());let bytes=file.write(buf,offset,length,position2===-1||typeof position2!="number"?void 0:position2);return bytes>0&&this.emit(new FsEvent_1.FsEvent(2,file.link.steps,file.node,file.link)),bytes}};exports.Superblock=Superblock;Superblock.fd=2147483647}});var require_CoreWatcher=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/watch/CoreWatcher.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.CoreWatcher=exports.CoreWatchEvent=void 0;var fanout_1=require_fanout(),CoreWatchEvent=class{constructor(type,steps,node2,link2,oldSteps=void 0){this.type=type,this.steps=steps,this.node=node2,this.link=link2,this.oldSteps=oldSteps}};exports.CoreWatchEvent=CoreWatchEvent;var CoreWatcher=class{constructor(core,path4,opts={}){this.changes=new fanout_1.FanOut,this.link=opts.follow??!0?core.getResolvedLinkOrThrow(path4,"watch"):core.getLinkOrThrow(path4,"watch"),this.node=this.link.getNode(),this.recursive=!!opts.recursive,this.unsub=core.changes.listen(event=>this.onEvent(event))}get closed(){return!this.unsub}onEvent(event){let rootLength=this.link.steps.length;if(event.link===this.link||event.node===this.node&&(event.type===2||event.type===3)){this.changes.emit(new CoreWatchEvent(event.type,[],event.node,this.link)),event.type===1&&this.close();return}if(event.type===4){let from=event.oldSteps&&this.inScope(event.oldSteps)?event.oldSteps.slice(rootLength):void 0,to=this.inScope(event.steps)?event.steps.slice(rootLength):void 0;from&&to?this.changes.emit(new CoreWatchEvent(4,to,event.node,event.link,from)):from?this.changes.emit(new CoreWatchEvent(1,from,event.node,event.link)):to&&this.changes.emit(new CoreWatchEvent(0,to,event.node,event.link));return}this.inScope(event.steps)&&this.changes.emit(new CoreWatchEvent(event.type,event.steps.slice(rootLength),event.node,event.link))}inScope(steps){let root4=this.link.steps;if(steps.length<=root4.length||!this.recursive&&steps.length!==root4.length+1)return!1;for(let i2=0;i2<root4.length;i2++)if(steps[i2]!==root4[i2])return!1;return!0}close(){this.unsub?.(),this.unsub=void 0}};exports.CoreWatcher=CoreWatcher}});var require_lib6=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.SystemError=exports.createWatchError=exports.createEisdirError=exports.createStatError=exports.createError=exports.resolve=exports.pathToFilename=exports.nullCheck=exports.validateFd=exports.isWin=exports.isFd=exports.filenameToSteps=exports.dataToBuffer=exports.Superblock=exports.File=exports.Link=exports.Node=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports));tslib_1.__exportStar(require_types(),exports);tslib_1.__exportStar(require_json(),exports);tslib_1.__exportStar(require_constants3(),exports);tslib_1.__exportStar(require_result2(),exports);var Node_1=require_Node();Object.defineProperty(exports,"Node",{enumerable:!0,get:function(){return Node_1.Node}});var Link_1=require_Link();Object.defineProperty(exports,"Link",{enumerable:!0,get:function(){return Link_1.Link}});var File_1=require_File();Object.defineProperty(exports,"File",{enumerable:!0,get:function(){return File_1.File}});var Superblock_1=require_Superblock();Object.defineProperty(exports,"Superblock",{enumerable:!0,get:function(){return Superblock_1.Superblock}});tslib_1.__exportStar(require_FsEvent(),exports);tslib_1.__exportStar(require_CoreWatcher(),exports);var util_1=require_util();Object.defineProperty(exports,"dataToBuffer",{enumerable:!0,get:function(){return util_1.dataToBuffer}});Object.defineProperty(exports,"filenameToSteps",{enumerable:!0,get:function(){return util_1.filenameToSteps}});Object.defineProperty(exports,"isFd",{enumerable:!0,get:function(){return util_1.isFd}});Object.defineProperty(exports,"isWin",{enumerable:!0,get:function(){return util_1.isWin}});Object.defineProperty(exports,"validateFd",{enumerable:!0,get:function(){return util_1.validateFd}});Object.defineProperty(exports,"nullCheck",{enumerable:!0,get:function(){return util_1.nullCheck}});Object.defineProperty(exports,"pathToFilename",{enumerable:!0,get:function(){return util_1.pathToFilename}});Object.defineProperty(exports,"resolve",{enumerable:!0,get:function(){return util_1.resolve}});var errors_1=require_errors();Object.defineProperty(exports,"createError",{enumerable:!0,get:function(){return errors_1.createError}});Object.defineProperty(exports,"createStatError",{enumerable:!0,get:function(){return errors_1.createStatError}});Object.defineProperty(exports,"createEisdirError",{enumerable:!0,get:function(){return errors_1.createEisdirError}});Object.defineProperty(exports,"createWatchError",{enumerable:!0,get:function(){return errors_1.createWatchError}});var SystemError_1=require_SystemError();Object.defineProperty(exports,"SystemError",{enumerable:!0,get:function(){return SystemError_1.SystemError}})}});var require_Stats=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/Stats.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Stats=void 0;var fs_node_utils_1=require_lib5(),{S_IFMT,S_IFDIR,S_IFREG,S_IFBLK,S_IFCHR,S_IFLNK,S_IFIFO,S_IFSOCK}=fs_node_utils_1.constants,Stats=class _Stats{static build(node2,bigint=!1){let stats=new _Stats,{uid,gid,atime,mtime,ctime,btime}=node2,getStatNumber=bigint?number=>BigInt(number):number=>number;return stats.uid=getStatNumber(uid),stats.gid=getStatNumber(gid),stats.rdev=getStatNumber(node2.rdev),stats.blksize=getStatNumber(4096),stats.ino=getStatNumber(node2.ino),stats.size=getStatNumber(node2.getSize()),stats.blocks=getStatNumber(1),stats.atime=new Date(atime.getTime()),stats.mtime=new Date(mtime.getTime()),stats.ctime=new Date(ctime.getTime()),stats.birthtime=new Date(btime.getTime()),stats.atimeMs=getStatNumber(atime.getTime()),stats.mtimeMs=getStatNumber(mtime.getTime()),stats.ctimeMs=getStatNumber(ctime.getTime()),stats.birthtimeMs=getStatNumber(btime.getTime()),bigint&&(stats.atimeNs=BigInt(atime.getTime())*BigInt(1e6),stats.mtimeNs=BigInt(mtime.getTime())*BigInt(1e6),stats.ctimeNs=BigInt(ctime.getTime())*BigInt(1e6),stats.birthtimeNs=BigInt(btime.getTime())*BigInt(1e6)),stats.dev=getStatNumber(0),stats.mode=getStatNumber(node2.mode),stats.nlink=getStatNumber(node2.nlink),stats}_checkModeProperty(property){return(Number(this.mode)&S_IFMT)===property}isDirectory(){return this._checkModeProperty(S_IFDIR)}isFile(){return this._checkModeProperty(S_IFREG)}isBlockDevice(){return this._checkModeProperty(S_IFBLK)}isCharacterDevice(){return this._checkModeProperty(S_IFCHR)}isSymbolicLink(){return this._checkModeProperty(S_IFLNK)}isFIFO(){return this._checkModeProperty(S_IFIFO)}isSocket(){return this._checkModeProperty(S_IFSOCK)}};exports.Stats=Stats;exports.default=Stats}});var require_Dirent=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/Dirent.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Dirent=void 0;var fs_node_utils_1=require_lib5(),{S_IFMT,S_IFDIR,S_IFREG,S_IFBLK,S_IFCHR,S_IFLNK,S_IFIFO,S_IFSOCK}=fs_node_utils_1.constants,Dirent=class _Dirent{constructor(){this.name="",this.parentPath="",this.mode=0,this.path=""}static build(link2,encoding,parentPath=link2.getParentPath()){let dirent=new _Dirent,{mode}=link2.getNode();return dirent.name=(0,fs_node_utils_1.strToEncoding)(link2.getName(),encoding),dirent.mode=mode,dirent.parentPath=parentPath,dirent.path=parentPath,dirent}_checkModeProperty(property){return(this.mode&S_IFMT)===property}isDirectory(){return this._checkModeProperty(S_IFDIR)}isFile(){return this._checkModeProperty(S_IFREG)}isBlockDevice(){return this._checkModeProperty(S_IFBLK)}isCharacterDevice(){return this._checkModeProperty(S_IFCHR)}isSymbolicLink(){return this._checkModeProperty(S_IFLNK)}isFIFO(){return this._checkModeProperty(S_IFIFO)}isSocket(){return this._checkModeProperty(S_IFSOCK)}};exports.Dirent=Dirent;exports.default=Dirent}});var require_StatFs=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/StatFs.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.StatFs=void 0;var StatFs=class _StatFs{static build(superblock,bigint=!1){let statfs=new _StatFs,getStatNumber=bigint?number=>BigInt(number):number=>number;statfs.type=getStatNumber(2240043254),statfs.bsize=getStatNumber(4096);let totalInodes=Object.keys(superblock.inodes).length,totalBlocks=1e6,usedBlocks=Math.min(totalInodes*2,totalBlocks),freeBlocks=totalBlocks-usedBlocks;statfs.blocks=getStatNumber(totalBlocks),statfs.bfree=getStatNumber(freeBlocks),statfs.bavail=getStatNumber(freeBlocks);let maxFiles=1e6;return statfs.files=getStatNumber(maxFiles),statfs.ffree=getStatNumber(maxFiles-totalInodes),statfs}};exports.StatFs=StatFs;exports.default=StatFs}});var browser_url_exports={};__export(browser_url_exports,{URL:()=>URL2,URLSearchParams:()=>URLSearchParams,fileURLToPath:()=>fileURLToPath,pathToFileURL:()=>pathToFileURL});var import_path_browserify,URL2,URLSearchParams,fileURLToPath,pathToFileURL,init_browser_url=__esm({"packages/workspace/src/browser-url.ts"(){"use strict";init_browser_globals();import_path_browserify=__toESM(require_path_browserify(),1),URL2=globalThis.URL,URLSearchParams=globalThis.URLSearchParams,fileURLToPath=value2=>{let url=new URL2(value2);if(url.protocol!=="file:"||url.hostname)throw new Error("Expected a local file URL");return decodeURIComponent(url.pathname)},pathToFileURL=value2=>new URL2(`file://${import_path_browserify.default.resolve(value2).split("/").map(encodeURIComponent).join("/")}`)}});var require_url2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-builtins@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-builtins/lib/url.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.URL=void 0;var node_url_1=(init_browser_url(),__toCommonJS(browser_url_exports));Object.defineProperty(exports,"URL",{enumerable:!0,get:function(){return node_url_1.URL}})}});var require_readWriteArgs=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/readWriteArgs.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.getWriteSyncArgs=exports.getWriteArgs=exports.getVectorCallbackArgs=exports.getVectorArgs=exports.getHandleWriteArgs=exports.getHandleReadArgs=exports.getReadArgs=exports.getReadSyncArgs=void 0;var buffer_1=require_buffer3(),fs_core_1=require_lib6(),argErrors_1=require_argErrors(),validators_1=require_validators(),READ_BUFFER_SIZE=16384,validateOptions=(value2,name)=>(0,validators_1.validateObject)(value2,name,1),validatePosition=(position2,name,length)=>{if(typeof position2=="number")(0,validators_1.validateInteger)(position2,name,-1);else if(typeof position2=="bigint"){let max=2n**63n-1n-BigInt(length);if(!(position2>=-1n&&position2<=max))throw(0,argErrors_1.outOfRange)(name,">= -1 && <= "+max,position2)}else throw(0,argErrors_1.invalidArgType)(name,"of type bigint or integer",position2)},validateBufferArray=(buffers,name="buffers")=>{if(!Array.isArray(buffers))throw(0,argErrors_1.invalidArgType)(name,"an ArrayBufferView[]",buffers);let length=buffers.length;for(let i2=0;i2<length;i2++)if(!ArrayBuffer.isView(buffers[i2]))throw(0,argErrors_1.invalidArgType)(name,"an ArrayBufferView[]",buffers)},validateOffsetLengthRead=(offset,length,bufferLength)=>{if(offset<0)throw(0,argErrors_1.outOfRange)("offset",">= 0",offset);if(length<0)throw(0,argErrors_1.outOfRange)("length",">= 0",length);if(offset+length>bufferLength)throw(0,argErrors_1.outOfRange)("length","<= "+(bufferLength-offset),length)},validateOffsetLengthWrite=(offset,length,byteLength)=>{if(offset>byteLength)throw(0,argErrors_1.outOfRange)("offset","<= "+byteLength,offset);if(length>byteLength-offset)throw(0,argErrors_1.outOfRange)("length","<= "+(byteLength-offset),length);if(length<0)throw(0,argErrors_1.outOfRange)("length",">= 0",length);(0,validators_1.validateInt32)(length,"length",0)},validateStringAfterArrayBufferView=(buffer,name)=>{if(typeof buffer!="string")throw(0,argErrors_1.invalidArgType)(name,"of type string or an instance of Buffer, TypedArray, or DataView",buffer)},toEncoding=encoding=>typeof encoding=="string"&&buffer_1.Buffer.isEncoding(encoding)?encoding:"utf8",validateEncoding=(data,encoding)=>{if(toEncoding(encoding)==="hex"&&data.length%2!==0)throw(0,argErrors_1.invalidArgValue)("encoding",encoding,"is invalid for data of length "+data.length)},viewToBuffer=view=>buffer_1.Buffer.isBuffer(view)?view:buffer_1.Buffer.from(view.buffer,view.byteOffset,view.byteLength),seekPosition=position2=>typeof position2=="number"&&position2>=0&&Number.isSafeInteger(position2)?position2:null,readPosition=position2=>typeof position2=="bigint"?position2<0n?null:Number(position2):position2<0?null:position2,getReadSyncArgs=(argc,buffer,a2,b2,c2)=>{(0,validators_1.validateBuffer)(buffer);let view=buffer,offset=a2,length=b2,position2=c2;if(argc<=3||typeof a2=="object"){a2!==void 0&&validateOptions(a2,"options");let options2=a2??{};offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:view.byteLength-offset,position2=options2.position!==void 0?options2.position:null}if(offset===void 0?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),length=length|0,position2==null?position2=-1:validatePosition(position2,"position",length),length!==0){if(view.byteLength===0)throw(0,argErrors_1.invalidArgValue)("buffer",view,"is empty and cannot be written");validateOffsetLengthRead(offset,length,view.byteLength)}return{buffer:view,offset,length,position:readPosition(position2)}};exports.getReadSyncArgs=getReadSyncArgs;var getReadArgs=(argc,buffer,a2,b2,c2,d2)=>{let buf=buffer,params=null,offset=a2,length=b2,position2=c2,callback=d2;if(argc<=4){if(argc===4)validateOptions(a2,"options"),callback=b2,params=a2;else if(argc===3){if(!ArrayBuffer.isView(buf)){params=buf;let source3=buf??{};buf=source3.buffer!==void 0?source3.buffer:buffer_1.Buffer.alloc(READ_BUFFER_SIZE)}callback=a2}else callback=buf,buf=buffer_1.Buffer.alloc(READ_BUFFER_SIZE);params!==void 0&&validateOptions(params,"options");let source2=params??{};offset=source2.offset!==void 0?source2.offset:0,length=source2.length!==void 0?source2.length:buf?.byteLength-offset,position2=source2.position!==void 0?source2.position:null}if((0,validators_1.validateBuffer)(buf),(0,validators_1.validateFunction)(callback,"cb"),offset==null?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),length=length|0,position2==null?position2=-1:validatePosition(position2,"position",length),length!==0){if(buf.byteLength===0)throw(0,argErrors_1.invalidArgValue)("buffer",buf,"is empty and cannot be written");validateOffsetLengthRead(offset,length,buf.byteLength)}return{buffer:buf,offset,length,position:readPosition(position2),callback}};exports.getReadArgs=getReadArgs;var getHandleReadArgs=(bufferOrParams,a2,b2,c2)=>{let buf=bufferOrParams,offset=a2,length=b2,position2=c2;if(!ArrayBuffer.isView(buf)){bufferOrParams!==void 0&&validateOptions(bufferOrParams,"options");let source2=bufferOrParams??{};buf=source2.buffer!==void 0?source2.buffer:buffer_1.Buffer.alloc(READ_BUFFER_SIZE),offset=source2.offset!==void 0?source2.offset:0,length=source2.length!==void 0?source2.length:buf.byteLength-offset,position2=source2.position!==void 0?source2.position:null,(0,validators_1.validateBuffer)(buf)}if(offset!==null&&typeof offset=="object"){let options2=offset;offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:buf.byteLength-offset,position2=options2.position!==void 0?options2.position:null}if(offset==null?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),length==null&&(length=buf.byteLength-offset),position2==null?position2=-1:validatePosition(position2,"position",length),length!==0){if(buf.byteLength===0)throw(0,argErrors_1.invalidArgValue)("buffer",buf,"is empty and cannot be written");validateOffsetLengthRead(offset,length,buf.byteLength)}return{buffer:buf,offset,length,position:readPosition(position2)}};exports.getHandleReadArgs=getHandleReadArgs;var getHandleWriteArgs=(data,a2,b2,c2)=>{if(data?.byteLength===0)return null;let offset=a2,length=b2,position2=c2;if(ArrayBuffer.isView(data)){let view=data;if(typeof offset=="object"){let options2=offset??{};offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:view.byteLength-offset,position2=options2.position!==void 0?options2.position:null}return offset==null?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),typeof length!="number"&&(length=view.byteLength-offset),validateOffsetLengthWrite(offset,length,view.byteLength),{buffer:viewToBuffer(view),offset,length,position:seekPosition(position2)}}validateStringAfterArrayBufferView(data,"buffer");let str=data;validateEncoding(str,length);let buf=(0,buffer_1.bufferFrom)(str,toEncoding(length));return{buffer:buf,offset:0,length:buf.length,position:seekPosition(offset)}};exports.getHandleWriteArgs=getHandleWriteArgs;var getVectorArgs=(buffers,position2)=>(validateBufferArray(buffers),seekPosition(position2));exports.getVectorArgs=getVectorArgs;var getVectorCallbackArgs=(buffers,a2,b2)=>{validateBufferArray(buffers);let callback=b2||a2;return(0,validators_1.validateFunction)(callback,"cb"),[seekPosition(a2),callback]};exports.getVectorCallbackArgs=getVectorCallbackArgs;var getWriteArgs=(fd,a2,b2,c2,d2,e2)=>{(0,validators_1.validateInt32)(fd,"fd",0);let offset=b2,length=c2,position2=d2,callback=e2;if(ArrayBuffer.isView(a2)){let view=a2;if(callback||(callback=position2||length||offset),(0,validators_1.validateFunction)(callback,"cb"),typeof offset=="object"){let options2=offset??{};offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:view.byteLength-offset,position2=options2.position!==void 0?options2.position:null}return offset==null||typeof offset=="function"?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),typeof length!="number"&&(length=view.byteLength-offset),validateOffsetLengthWrite(offset,length,view.byteLength),[fd,!1,viewToBuffer(view),offset,length,seekPosition(position2),callback]}validateStringAfterArrayBufferView(a2,"buffer"),typeof position2!="function"&&(typeof offset=="function"?(position2=offset,offset=null):position2=length,length="utf8");let str=a2;validateEncoding(str,length),callback=position2,(0,validators_1.validateFunction)(callback,"cb");let buf=(0,buffer_1.bufferFrom)(str,toEncoding(length));return[fd,!0,buf,0,buf.length,seekPosition(offset),callback]};exports.getWriteArgs=getWriteArgs;var getWriteSyncArgs=(fd,a2,b2,c2,d2)=>{let offset=b2,length=c2,position2=d2;if(ArrayBuffer.isView(a2)){let view=a2;if(typeof offset=="object"){let options2=offset??{};offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:view.byteLength-offset,position2=options2.position!==void 0?options2.position:null}return offset==null?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),typeof length!="number"&&(length=view.byteLength-offset),validateOffsetLengthWrite(offset,length,view.byteLength),(0,fs_core_1.validateFd)(fd),[fd,viewToBuffer(view),offset,length,seekPosition(position2)]}validateStringAfterArrayBufferView(a2,"buffer");let str=a2;validateEncoding(str,length),(0,fs_core_1.validateFd)(fd);let buf=(0,buffer_1.bufferFrom)(str,toEncoding(length));return[fd,buf,0,buf.length,seekPosition(offset)]};exports.getWriteSyncArgs=getWriteSyncArgs}});var require_util2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/util.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.getWriteSyncArgs=exports.getWriteArgs=exports.bufToUint8=exports.createWatchError=exports.createStatError=exports.createError=exports.pathToFilename=exports.nullCheck=void 0;exports.promisify=promisify;exports.validateCallback=validateCallback;exports.modeToNumber=modeToNumber;exports.genRndStr6=genRndStr6;exports.flagsToNumber=flagsToNumber;exports.streamToBuffer=streamToBuffer;exports.bufferToEncoding=bufferToEncoding;exports.isReadableStream=isReadableStream;var fs_node_utils_1=require_lib5(),argErrors_1=require_argErrors(),validators_1=require_validators(),buffer_1=require_buffer3(),fs_core_1=require_lib6();Object.defineProperty(exports,"nullCheck",{enumerable:!0,get:function(){return fs_core_1.nullCheck}});Object.defineProperty(exports,"pathToFilename",{enumerable:!0,get:function(){return fs_core_1.pathToFilename}});Object.defineProperty(exports,"createError",{enumerable:!0,get:function(){return fs_core_1.createError}});Object.defineProperty(exports,"createStatError",{enumerable:!0,get:function(){return fs_core_1.createStatError}});Object.defineProperty(exports,"createWatchError",{enumerable:!0,get:function(){return fs_core_1.createWatchError}});function promisify(fs2,fn2,getResult=input=>input){return(...args)=>new Promise((resolve2,reject)=>{fs2[fn2].bind(fs2)(...args,(error,result)=>error?reject(error):resolve2(getResult(result)))})}function validateCallback(callback,name="cb"){return(0,validators_1.validateFunction)(callback,name),callback}var OCTAL_REG=/^[0-7]+$/,MODE_DESC="must be a 32-bit unsigned integer or an octal string";function modeToNumber(mode,def,name="mode"){let value2=mode??def;if(typeof value2=="string"){if(!OCTAL_REG.test(value2))throw(0,argErrors_1.invalidArgValue)(name,value2,MODE_DESC);value2=parseInt(value2,8)}return(0,validators_1.validateUint32)(value2,name),value2+0}function genRndStr6(){return Math.random().toString(36).slice(2,8).padEnd(6,"0")}function flagsToNumber(flags){if(typeof flags=="number")return(0,validators_1.validateInt32)(flags,"flags"),flags;if(typeof flags=="string"){let flagsNum=fs_node_utils_1.FLAGS[flags];if(typeof flagsNum<"u")return flagsNum}throw(0,argErrors_1.invalidArgValue)("flags",flags)}function streamToBuffer(stream){let chunks=[];return new Promise((resolve2,reject)=>{stream.on("data",chunk=>chunks.push(chunk)),stream.on("end",()=>resolve2(buffer_1.Buffer.concat(chunks))),stream.on("error",reject)})}var bufToUint8=buf=>new Uint8Array(buf.buffer,buf.byteOffset,buf.byteLength);exports.bufToUint8=bufToUint8;var readWriteArgs_1=require_readWriteArgs();Object.defineProperty(exports,"getWriteArgs",{enumerable:!0,get:function(){return readWriteArgs_1.getWriteArgs}});Object.defineProperty(exports,"getWriteSyncArgs",{enumerable:!0,get:function(){return readWriteArgs_1.getWriteSyncArgs}});function bufferToEncoding(buffer,encoding){return!encoding||encoding==="buffer"?buffer:buffer.toString(encoding)}function isReadableStream(stream){return stream!==null&&typeof stream=="object"&&typeof stream.pipe=="function"&&typeof stream.on=="function"&&stream.readable===!0}}});var require_glob=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/glob.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.globSync=exports.globWalk=void 0;exports.glob=glob;var path_1=require_path2(),url_1=require_url2(),argErrors_1=require_argErrors(),validators_1=require_validators(),glob_to_regex_js_1=require_lib4(),util_1=require_util2(),Dirent_1=require_Dirent(),{basename:basename4,dirname:dirname4,isAbsolute:isAbsolute3,join:join5,relative:relative2,resolve:resolve2}=path_1.posix,internalAssertionError=()=>(0,argErrors_1.withCode)(new Error(`This is caused by either a bug in Node.js or incorrect usage of Node.js internals.
|
|
39
|
+
`+" ".repeat(ctx.indentationLvl)):"["+Error.prototype.toString.call(value2)+"]",keys.length===0)return base2}else if((0,inspectBrand_1.hasBrand)(inspectBrand_1.arrayBufferByteLength,value2)||inspectBrand_1.sharedArrayBufferByteLength!==void 0&&(0,inspectBrand_1.hasBrand)(inspectBrand_1.sharedArrayBufferByteLength,value2))fallback=(0,inspectBrand_1.hasBrand)(inspectBrand_1.arrayBufferByteLength,value2)?"ArrayBuffer":"SharedArrayBuffer",braces[0]=(0,inspectBrand_1.prefixOf)(constructor,tag2,fallback)+"{",formatter2=formatArrayBuffer,extraKeys=["byteLength"];else if((0,inspectBrand_1.hasBrand)(inspectBrand_1.dataViewBuffer,value2))fallback="DataView",braces[0]=(0,inspectBrand_1.prefixOf)(constructor,tag2,"DataView")+"{",extraKeys=["byteLength","byteOffset","buffer"];else{let boxed=(0,inspectBrand_1.boxedBase)(value2,keys,constructor,tag2,ctx.indentationLvl);if(boxed!==void 0){if(base2=boxed,keys.length===0)return base2}else{let style=(0,inspectBrand_1.prefixOf)(constructor,tag2,constructor===null?"Object":"");if(keys.length===0)return style+"{}";braces[0]=style+"{"}}if(recurseTimes>ctx.depth){let name=(0,inspectBrand_1.prefixOf)(constructor,tag2,constructor===null?fallback===tag2?"Object":fallback:"").slice(0,-1);return constructor===null?name:"["+name+"]"}recurseTimes++,ctx.seen.push(value2),ctx.currentDepth=recurseTimes;let output=formatter2(ctx,value2,recurseTimes);if(extraKeys!==void 0)for(let i2=0;i2<extraKeys.length;i2++)output.push(formatExtra(ctx,value2,recurseTimes,extraKeys[i2]));for(let i2=0;i2<keys.length;i2++)output.push(formatProperty(ctx,value2,recurseTimes,keys[i2],kind));let index4=ctx.circular===void 0?void 0:ctx.circular.get(value2);return index4!==void 0&&(base2=base2===""?"<ref *"+index4+">":"<ref *"+index4+"> "+base2),ctx.seen.pop(),(0,inspectLayout_1.reduceToSingleString)(ctx,output,base2,braces,kind,recurseTimes,value2)},formatValue=(ctx,value2,recurseTimes)=>{if(typeof value2!="object"&&typeof value2!="function")return(0,inspectPrimitive_1.formatPrimitive)(value2,ctx.indentationLvl);if(value2===null)return"null";if(buffer_1.Buffer.isBuffer(value2))return"<"+value2.constructor.name+" "+(0,inspectBrand_1.hexBytes)(value2,INSPECT_MAX_BYTES)+">";if(ctx.seen.indexOf(value2)!==-1){let circular=ctx.circular;circular===void 0&&(ctx.circular=circular=new Map);let index4=circular.get(value2);return index4===void 0&&(index4=circular.size+1,circular.set(value2,index4)),"[Circular *"+index4+"]"}return formatRaw(ctx,value2,recurseTimes)},inspect=(value2,depth=2)=>formatValue({depth,indentationLvl:0,currentDepth:0,seen:[],circular:void 0},value2,0);exports.inspect=inspect}});var require_argErrors=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/argErrors.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.invalidUrlScheme=exports.methodNotImplemented=exports.invalidThis=exports.outOfRange=exports.invalidArgValue=exports.invalidArgType=exports.withNativeCode=exports.withCode=void 0;var inspect_1=require_inspect(),inspectPrimitive_1=require_inspectPrimitive(),TWO_POW_32=4294967296,BIG_TWO_POW_32=BigInt(TWO_POW_32),withCode=(error,code4)=>{error.code=code4;let tagged=error.name+" ["+code4+"]";return Object.defineProperty(error,"name",{value:tagged,enumerable:!1,writable:!0,configurable:!0}),error.stack,delete error.name,Object.defineProperty(error,"toString",{value:function(){return tagged+": "+this.message},enumerable:!1,writable:!0,configurable:!0}),error};exports.withCode=withCode;var withNativeCode=(error,code4)=>(error.code=code4,error);exports.withNativeCode=withNativeCode;var kindOf=name=>name.indexOf(".")===-1?"argument":"property",describeType=value2=>{if(value2===null)return"null";if(value2===void 0)return"undefined";switch(typeof value2){case"bigint":return"type bigint ("+value2+"n)";case"number":return"type number ("+(0,inspectPrimitive_1.formatNumber)(value2)+")";case"boolean":return"type boolean ("+value2+")";case"symbol":return"type symbol ("+value2.toString()+")";case"function":return"function "+value2.name;case"string":{let str=value2.length>28?value2.slice(0,25)+"...":value2;return str.indexOf("'")===-1?"type string ('"+str+"')":"type string ("+JSON.stringify(str)+")"}}let ctor=value2.constructor;return ctor&&"name"in ctor?"an instance of "+ctor.name:(0,inspect_1.inspect)(value2,-1)},describeNativeType=value2=>{switch(typeof value2){case"bigint":return"type bigint ("+value2+")";case"symbol":return value2.toString();case"function":return"function";case"object":{if(value2===null)break;let ctor=value2.constructor;return"an instance of "+(ctor&&ctor.name||"Object")}}return describeType(value2)},invalidArgType=(name,expected,actual,native)=>{let head=name.endsWith(" argument")?"The "+name+" ":'The "'+name+'" '+kindOf(name)+" ",received=native?describeNativeType(actual):describeType(actual),error=new TypeError(head+"must be "+expected+". Received "+received);return native?(0,exports.withNativeCode)(error,"ERR_INVALID_ARG_TYPE"):(0,exports.withCode)(error,"ERR_INVALID_ARG_TYPE")};exports.invalidArgType=invalidArgType;var invalidArgValue=(name,value2,reason="is invalid")=>{let inspected=(0,inspect_1.inspect)(value2);return inspected.length>128&&(inspected=inspected.slice(0,128)+"..."),(0,exports.withCode)(new TypeError("The "+kindOf(name)+" '"+name+"' "+reason+". Received "+inspected),"ERR_INVALID_ARG_VALUE")};exports.invalidArgValue=invalidArgValue;var outOfRange=(name,range,value2,native)=>{let message='The value of "'+name+'" is out of range. It must be '+range+". Received ";if(native)return(0,exports.withNativeCode)(new RangeError(message+String(value2)),"ERR_OUT_OF_RANGE");let received;return Number.isInteger(value2)&&Math.abs(value2)>TWO_POW_32?received=(0,inspectPrimitive_1.addNumericalSeparator)(""+value2):typeof value2=="bigint"?(received=""+value2,(value2>BIG_TWO_POW_32||value2<-BIG_TWO_POW_32)&&(received=(0,inspectPrimitive_1.addNumericalSeparator)(received)),received+="n"):received=(0,inspect_1.inspect)(value2),(0,exports.withCode)(new RangeError(message+received),"ERR_OUT_OF_RANGE")};exports.outOfRange=outOfRange;var invalidThis=type=>(0,exports.withCode)(new TypeError('Value of "this" must be of type '+type),"ERR_INVALID_THIS");exports.invalidThis=invalidThis;var methodNotImplemented=method=>(0,exports.withCode)(new Error("The "+method+" method is not implemented"),"ERR_METHOD_NOT_IMPLEMENTED");exports.methodNotImplemented=methodNotImplemented;var invalidUrlScheme=expected=>(0,exports.withCode)(new TypeError("The URL must be of scheme "+expected),"ERR_INVALID_URL_SCHEME");exports.invalidUrlScheme=invalidUrlScheme}});var require_encoding=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/encoding.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.ENCODING_UTF8=void 0;exports.assertEncoding=assertEncoding;exports.strToEncoding=strToEncoding;var buffer_1=require_buffer3(),argErrors_1=require_argErrors();exports.ENCODING_UTF8="utf8";function assertEncoding(encoding){if(encoding&&!buffer_1.Buffer.isEncoding(encoding))throw(0,argErrors_1.invalidArgValue)("encoding",encoding,"is invalid encoding")}function strToEncoding(str,encoding){return!encoding||encoding===exports.ENCODING_UTF8?str:encoding==="buffer"?new buffer_1.Buffer(str):new buffer_1.Buffer(str).toString(encoding)}}});var require_lib4=__commonJS({"node_modules/.pnpm/glob-to-regex.js@1.3.1_tslib@2.9.1/node_modules/glob-to-regex.js/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.toMatcher=exports.toRegex=exports.expandBraces=void 0;var NODOT="(?!\\.)",STAR="[^/]*",GLOBSTAR_NODOT="[^/]*(?:/(?!\\.)[^/]*)*",literal=(pattern,i2,code4)=>{switch(code4){case 36:case 42:case 63:case 91:case 40:case 41:case 43:case 46:case 92:case 93:case 94:case 123:case 124:case 125:return"\\"+pattern[i2];default:return pattern[i2]}},posixClass=name=>{switch(name){case"alnum":return"0-9A-Za-z";case"alpha":return"A-Za-z";case"ascii":return"\\x00-\\x7f";case"blank":return" \\t";case"cntrl":return"\\x00-\\x1f\\x7f";case"digit":return"0-9";case"graph":return"\\x21-\\x7e";case"lower":return"a-z";case"print":return"\\x20-\\x7e";case"punct":return"\\x21-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7e";case"space":return" \\t\\r\\n\\v\\f";case"upper":return"A-Z";case"word":return"0-9A-Za-z_";case"xdigit":return"0-9A-Fa-f"}},classEnd=(pattern,i2)=>{let length=pattern.length,j=i2+1,first=pattern.charCodeAt(j);for((first===33||first===94)&&j++,pattern.charCodeAt(j)===93&&j++;j<length;j++){let code4=pattern.charCodeAt(j);if(code4===93)return j+1;if(code4===91&&pattern.charCodeAt(j+1)===58){let close2=pattern.indexOf(":]",j+2);close2>0&&(j=close2+1)}}return-1},member=(pattern,i2)=>{let code4=pattern.charCodeAt(i2);return(code4===93||code4===92||code4===91||code4===94||code4===45?"\\":"")+pattern[i2]},classSource=(pattern,i2,end)=>{let last=end-1,j=i2+1,out="",members=0,first=pattern.charCodeAt(j),negate=first===33||first===94;for(negate&&j++;j<last;){if(pattern.charCodeAt(j)===91&&pattern.charCodeAt(j+1)===58){let close2=pattern.indexOf(":]",j+2),cls=close2>0?posixClass(pattern.slice(j+2,close2)):void 0;if(cls!==void 0){out+=cls,members+=2,j=close2+2;continue}}if(pattern.charCodeAt(j+1)===45&&j+2<last){pattern.charCodeAt(j+2)>=pattern.charCodeAt(j)&&(out+=member(pattern,j)+"-"+member(pattern,j+2),members+=2),j+=3;continue}out+=member(pattern,j),members++,j++}return!negate&&members===1?literal(pattern,last-1,pattern.charCodeAt(last-1)):members?(negate?"[^":"[")+out+"]":negate?"[^/]":"[]"},groupEnd=(pattern,i2)=>{let length=pattern.length,depth=1;for(;i2<length;i2++){let code4=pattern.charCodeAt(i2);if(code4===91){let end=classEnd(pattern,i2);end>0&&(i2=end-1)}else if(code4===40)depth++;else if(code4===41&&!--depth)return i2+1}return-1},splitAlts=body=>{let length=body.length,alts=[],depth=0,from=0;for(let i2=0;i2<length;i2++){let code4=body.charCodeAt(i2);if(code4===91){let end=classEnd(body,i2);end>0&&(i2=end-1)}else code4===40?depth++:code4===41?depth--:code4===124&&!depth&&(alts.push(body.slice(from,i2)),from=i2+1)}return alts.push(body.slice(from)),alts},isExtglobPrefix=code4=>code4===63||code4===42||code4===43||code4===64||code4===33,altsSource=(alts,extglob,nodot,tail,segStart)=>{let out="";for(let i2=0;i2<alts.length;i2++)out+=(i2?"|":"")+compile(alts[i2],extglob,nodot,tail,segStart);return out},extglobSource=(type,alts,extglob,nodot,tail,segStart)=>{let guard=nodot&&segStart?NODOT:"",body=altsSource(alts,extglob,nodot,tail,segStart);switch(type){case 63:return"(?:"+body+")?";case 64:return"(?:"+body+")";case 33:return alts.length===1&&!alts[0]?guard+"[^/]+":"(?!(?:"+body+")"+tail+"$)"+guard+STAR}let more=guard?altsSource(alts,extglob,nodot,tail,!1):body;if(more===body)return"(?:"+body+")"+(type===42?"*":"+");let once="(?:"+body+")(?:"+more+")*";return type===42?"(?:"+once+")?":once},compile=(pattern,extglob,nodot,tail,segStart)=>{let length=pattern.length,out="",i2=0,start=segStart;for(;i2<length;){let code4=pattern.charCodeAt(i2);if(extglob&&pattern.charCodeAt(i2+1)===40&&isExtglobPrefix(code4)){let end=groupEnd(pattern,i2+2);if(end>0){let after=compile(pattern.slice(end),extglob,nodot,tail,!1),alts=splitAlts(pattern.slice(i2+2,end-1));return out+extglobSource(code4,alts,extglob,nodot,after+tail,start)+after}}let atStart=start,guard=nodot&&atStart?NODOT:"";switch(start=!1,code4){case 42:{let j=i2+1;for(;pattern.charCodeAt(j)===42;)j++;if(j===i2+1){let whole=atStart&&(j===length||pattern.charCodeAt(j)===47);out+=guard+(whole?"[^/]+":STAR),i2=j;break}let slash=pattern.charCodeAt(j)===47;for(;slash;){let k=j+1;if(pattern.charCodeAt(k)!==42||pattern.charCodeAt(k+1)!==42)break;for(k+=2;pattern.charCodeAt(k)===42;)k++;if(k===length)j=k,slash=!1;else if(pattern.charCodeAt(k)===47)j=k;else break}slash?(out+=nodot?"(?:"+guard+GLOBSTAR_NODOT+"/)?":"(?:.*/)?",j++,start=!0):out+=nodot?guard+GLOBSTAR_NODOT:".*",i2=j;break}case 63:out+=guard+"[^/]",i2++;break;case 91:{let end=classEnd(pattern,i2);if(end<0){out+="\\[",i2++;break}let cls=classSource(pattern,i2,end);out+=(cls.charCodeAt(0)===91?guard:"")+cls,i2=end;break}case 47:out+="/",i2++,start=!0;break;default:out+=literal(pattern,i2,code4),i2++}}return out},closingBrace=(pattern,open2)=>{let length=pattern.length,depth=0;for(let i2=open2;i2<length;i2++){let code4=pattern.charCodeAt(i2);if(code4===123)depth++;else if(code4===125&&!--depth)return i2}return-1},commaSplit=body=>{let length=body.length,parts=[],depth=0,from=0;for(let i2=0;i2<length;i2++){let code4=body.charCodeAt(i2);code4===123?depth++:code4===125?depth--:code4===44&&!depth&&(parts.push(body.slice(from,i2)),from=i2+1)}if(parts.length)return parts.push(body.slice(from)),parts},NUMERIC_RANGE=/^(-?\d+)\.\.(-?\d+)(?:\.\.(-?\d+))?$/,ALPHA_RANGE=/^([a-zA-Z])\.\.([a-zA-Z])(?:\.\.(-?\d+))?$/,PADDED=/^-?0\d/,rangeOf=(body,max)=>{let match=NUMERIC_RANGE.exec(body),alpha=!match;if(alpha&&(match=ALPHA_RANGE.exec(body)),!match)return;let from=alpha?match[1].charCodeAt(0):+match[1],to=alpha?match[2].charCodeAt(0):+match[2],step=match[3]===void 0?1:Math.abs(+match[3])||1,width=!alpha&&(PADDED.test(match[1])||PADDED.test(match[2]))?Math.max(match[1].length,match[2].length):0,out=[],dir=from<=to?step:-step;for(let n2=from;(dir>0?n2<=to:n2>=to)&&out.length<max;n2+=dir){if(alpha){out.push(String.fromCharCode(n2));continue}let s2=String(n2),need=width-s2.length;if(need>0){let zeros="";for(let k=0;k<need;k++)zeros+="0";s2=n2<0?"-"+zeros+s2.slice(1):zeros+s2}out.push(s2)}return out},expandInto=(pattern,out,max)=>{for(let open2=pattern.indexOf("{");open2>=0;open2=pattern.indexOf("{",open2+1)){let close2=closingBrace(pattern,open2);if(close2<0)continue;let body=pattern.slice(open2+1,close2),alts=commaSplit(body)||rangeOf(body,max);if(!alts)continue;let prefix=pattern.slice(0,open2),suffixes=(0,exports.expandBraces)(pattern.slice(close2+1),max);for(let i2=0;i2<alts.length;i2++){let heads=(0,exports.expandBraces)(alts[i2],max);for(let j=0;j<heads.length;j++){let head=prefix+heads[j];for(let k=0;k<suffixes.length;k++){if(out.length>=max)return;out.push(head+suffixes[k])}}}return}out.push(pattern)},expandBraces=(pattern,max=1e5)=>{let out=[];return expandInto(pattern,out,max),out};exports.expandBraces=expandBraces;var toRegex=(pattern,options2)=>{let extglob=!!options2?.extglob,nodot=options2?.dot===!1,source2;if(pattern.indexOf("{")<0)source2=compile(pattern,extglob,nodot,"",!0);else{let set2=(0,exports.expandBraces)(pattern),length=set2.length;if(length===1)source2=compile(set2[0],extglob,nodot,"",!0);else{let seen=new Set;source2="(?:";for(let i2=0;i2<length;i2++){let one2=set2[i2];seen.has(one2)||(seen.size&&(source2+="|"),seen.add(one2),source2+=compile(one2,extglob,nodot,"",!0))}source2+=")"}}return new RegExp("^"+source2+"$",options2?.nocase?"i":"")};exports.toRegex=toRegex;var isRegExp=/^\/(.{1,4096})\/([gimsuy]{0,6})$/,toMatcher=(pattern,options2)=>{let regexes=[],patterns=Array.isArray(pattern)?pattern:[pattern];for(let pat of patterns)if(typeof pat=="string"){let match=isRegExp.exec(pat);if(match){let[,expr,flags]=match;regexes.push(new RegExp(expr,flags))}else regexes.push((0,exports.toRegex)(pat,options2))}else regexes.push(pat);return regexes.length?new Function("p","return "+regexes.map(r2=>r2+".test(p)").join("||")):()=>!1};exports.toMatcher=toMatcher}});var require_watchIgnore=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/watchIgnore.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.watchIgnoreToMatcher=exports.watchIgnorePatternToMatcher=void 0;var glob_to_regex_js_1=require_lib4(),watchIgnorePatternToMatcher=pattern=>{if(typeof pattern=="function")return pattern;if(pattern instanceof RegExp)return filename=>pattern.test(filename);if(typeof pattern=="string"){let regex=(0,glob_to_regex_js_1.toRegex)(pattern);return filename=>regex.test(filename)}throw new TypeError(`The "options.ignore" property must be of type string, RegExp, function, or an array thereof. Received ${typeof pattern}`)};exports.watchIgnorePatternToMatcher=watchIgnorePatternToMatcher;var watchIgnoreToMatcher=ignore3=>{if(Array.isArray(ignore3)){let matchers=ignore3.map(exports.watchIgnorePatternToMatcher);return filename=>matchers.some(matcher=>matcher(filename))}return(0,exports.watchIgnorePatternToMatcher)(ignore3)};exports.watchIgnoreToMatcher=watchIgnoreToMatcher}});var require_fsCallbackApiList=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/lists/fsCallbackApiList.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsCallbackApiList=void 0;exports.fsCallbackApiList=["access","appendFile","chmod","chown","close","copyFile","cp","createReadStream","createWriteStream","exists","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","glob","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","openAsBlob","opendir","read","readv","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","statfs","symlink","truncate","unlink","unwatchFile","utimes","lutimes","watch","watchFile","write","writev","writeFile"]}});var require_fsSynchronousApiList=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/lists/fsSynchronousApiList.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsSynchronousApiList=void 0;exports.fsSynchronousApiList=["accessSync","appendFileSync","chmodSync","chownSync","closeSync","copyFileSync","cpSync","existsSync","fchmodSync","fchownSync","fdatasyncSync","fstatSync","fsyncSync","ftruncateSync","futimesSync","globSync","lchmodSync","lchownSync","linkSync","lstatSync","mkdirSync","mkdtempSync","openSync","opendirSync","readdirSync","readFileSync","readlinkSync","readSync","readvSync","realpathSync","renameSync","rmdirSync","rmSync","statfsSync","statSync","symlinkSync","truncateSync","unlinkSync","utimesSync","lutimesSync","writeFileSync","writeSync","writevSync"]}});var require_fsCommonObjectsList=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/lists/fsCommonObjectsList.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsCommonObjectsList=void 0;exports.fsCommonObjectsList=["F_OK","R_OK","W_OK","X_OK","constants","Stats","StatFs","Dir","Dirent","StatWatcher","FSWatcher","ReadStream","WriteStream"]}});var require_lib5=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsCommonObjectsList=exports.fsSynchronousApiList=exports.fsCallbackApiList=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports));tslib_1.__exportStar(require_types2(),exports);tslib_1.__exportStar(require_constants2(),exports);tslib_1.__exportStar(require_AMODE(),exports);tslib_1.__exportStar(require_FLAG(),exports);tslib_1.__exportStar(require_path3(),exports);tslib_1.__exportStar(require_encoding(),exports);tslib_1.__exportStar(require_watchIgnore(),exports);var fsCallbackApiList_1=require_fsCallbackApiList();Object.defineProperty(exports,"fsCallbackApiList",{enumerable:!0,get:function(){return fsCallbackApiList_1.fsCallbackApiList}});var fsSynchronousApiList_1=require_fsSynchronousApiList();Object.defineProperty(exports,"fsSynchronousApiList",{enumerable:!0,get:function(){return fsSynchronousApiList_1.fsSynchronousApiList}});var fsCommonObjectsList_1=require_fsCommonObjectsList();Object.defineProperty(exports,"fsCommonObjectsList",{enumerable:!0,get:function(){return fsCommonObjectsList_1.fsCommonObjectsList}})}});var require_json=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/json.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.flattenJSON=void 0;var buffer_1=require_buffer3(),fs_node_utils_1=require_lib5(),flattenJSON=nestedJSON=>{let flatJSON={};function flatten(pathPrefix,node2){for(let path4 in node2){let contentOrNode=node2[path4],joinedPath=(0,fs_node_utils_1.pathJoin)(pathPrefix,path4);typeof contentOrNode=="string"||contentOrNode instanceof buffer_1.Buffer?flatJSON[joinedPath]=contentOrNode:typeof contentOrNode=="object"&&contentOrNode!==null&&!(contentOrNode instanceof buffer_1.Buffer)&&Object.keys(contentOrNode).length>0?flatten(joinedPath,contentOrNode):flatJSON[joinedPath]=null}}return flatten("",nestedJSON),flatJSON};exports.flattenJSON=flattenJSON}});var require_constants3=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/constants.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0})}});var require_result2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/result.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Ok=Ok;exports.Err=Err;function Ok(value2){return{ok:!0,value:value2}}function Err(err){return{ok:!1,err}}}});var require_fanout=__commonJS({"node_modules/.pnpm/thingies@2.6.1_tslib@2.9.1/node_modules/thingies/lib/fanout.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FanOut=void 0;var FanOut=class{constructor(){this.listeners=new Set}emit(data){this.listeners.forEach(listener2=>listener2(data))}listen(listener2){let listeners=this.listeners;return listeners.add(listener2),()=>listeners.delete(listener2)}};exports.FanOut=FanOut}});var require_browser=__commonJS({"node_modules/.pnpm/process@0.11.10/node_modules/process/browser.js"(exports,module){init_browser_globals();var process2=module.exports={},cachedSetTimeout,cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?cachedSetTimeout=setTimeout:cachedSetTimeout=defaultSetTimout}catch{cachedSetTimeout=defaultSetTimout}try{typeof clearTimeout=="function"?cachedClearTimeout=clearTimeout:cachedClearTimeout=defaultClearTimeout}catch{cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout)return setTimeout(fun,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(fun,0);try{return cachedSetTimeout(fun,0)}catch{try{return cachedSetTimeout.call(null,fun,0)}catch{return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout)return clearTimeout(marker);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(marker);try{return cachedClearTimeout(marker)}catch{try{return cachedClearTimeout.call(null,marker)}catch{return cachedClearTimeout.call(this,marker)}}}var queue2=[],draining=!1,currentQueue,queueIndex=-1;function cleanUpNextTick(){!draining||!currentQueue||(draining=!1,currentQueue.length?queue2=currentQueue.concat(queue2):queueIndex=-1,queue2.length&&drainQueue())}function drainQueue(){if(!draining){var timeout=runTimeout(cleanUpNextTick);draining=!0;for(var len=queue2.length;len;){for(currentQueue=queue2,queue2=[];++queueIndex<len;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,len=queue2.length}currentQueue=null,draining=!1,runClearTimeout(timeout)}}process2.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1)for(var i2=1;i2<arguments.length;i2++)args[i2-1]=arguments[i2];queue2.push(new Item(fun,args)),queue2.length===1&&!draining&&runTimeout(drainQueue)};function Item(fun,array){this.fun=fun,this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process2.title="browser";process2.browser=!0;process2.env={};process2.argv=[];process2.version="";process2.versions={};function noop(){}process2.on=noop;process2.addListener=noop;process2.once=noop;process2.off=noop;process2.removeListener=noop;process2.removeAllListeners=noop;process2.emit=noop;process2.prependListener=noop;process2.prependOnceListener=noop;process2.listeners=function(name){return[]};process2.binding=function(name){throw new Error("process.binding is not supported")};process2.cwd=function(){return"/"};process2.chdir=function(dir){throw new Error("process.chdir is not supported")};process2.umask=function(){return 0}}});var require_process=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/process.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.createProcess=createProcess;var maybeReturnProcess=()=>{if(typeof process<"u")return process;try{return require_browser()}catch{return}};function createProcess(){let p2=maybeReturnProcess()||{};return p2.cwd||(p2.cwd=()=>"/"),p2.emitWarning||(p2.emitWarning=(message,type)=>{console.warn(`${type}${type?": ":""}${message}`)}),p2.env||(p2.env={}),p2}exports.default=createProcess()}});var require_Node=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/Node.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Node=void 0;var fanout_1=require_fanout(),process_1=require_process(),buffer_1=require_buffer3(),fs_node_utils_1=require_lib5(),{S_IFMT,S_IFDIR,S_IFREG,S_IFLNK,S_IFCHR}=fs_node_utils_1.constants,getuid=()=>process_1.default.getuid?.()??0,getgid=()=>process_1.default.getgid?.()??0,EMPTY_BUFFER=(0,buffer_1.bufferAllocUnsafe)(0),Node3=class{constructor(ino,mode=438,uid=getuid(),gid=getgid()){this.changes=new fanout_1.FanOut,this._uid=getuid(),this._gid=getgid(),this._atime=new Date,this._mtime=new Date,this._ctime=new Date,this._btime=new Date,this.buf=EMPTY_BUFFER,this.capacity=0,this.size=0,this.rdev=0,this._nlink=1,this.mode=mode,this.ino=ino,this._uid=uid,this._gid=gid}set ctime(ctime){this._ctime=ctime}get ctime(){return this._ctime}set btime(btime){this._btime=btime}get btime(){return this._btime}set uid(uid){this._uid=uid,this.ctime=new Date}get uid(){return this._uid}set gid(gid){this._gid=gid,this.ctime=new Date}get gid(){return this._gid}set atime(atime){this._atime=atime}get atime(){return this._atime}set mtime(mtime){this._mtime=mtime,this.ctime=new Date}get mtime(){return this._mtime}get perm(){return this.mode&~S_IFMT}set perm(perm){this.mode=this.mode&S_IFMT|perm&~S_IFMT,this.ctime=new Date}set nlink(nlink){this._nlink=nlink,this.ctime=new Date}get nlink(){return this._nlink}getString(encoding="utf8"){return this.atime=new Date,this.getBuffer().toString(encoding)}setString(str){this._setBuf((0,buffer_1.bufferFrom)(str,"utf8"))}getBuffer(){return this.atime=new Date,this.buf||(this.buf=(0,buffer_1.bufferAllocUnsafe)(0)),(0,buffer_1.bufferFrom)(this.buf.subarray(0,this.size))}setBuffer(buf){let copy=(0,buffer_1.bufferFrom)(buf);this._setBuf(copy)}_setBuf(buf){let size=buf.length;this.buf=buf,this.capacity=size,this.size=size,this.touch()}getSize(){return this.size}setModeProperty(property){this.mode=property}isFile(){return(this.mode&S_IFMT)===S_IFREG}isDirectory(){return(this.mode&S_IFMT)===S_IFDIR}isSymlink(){return(this.mode&S_IFMT)===S_IFLNK}isCharacterDevice(){return(this.mode&S_IFMT)===S_IFCHR}makeSymlink(symlink){this.mode=S_IFLNK|438,this.symlink=symlink}write(buf,off=0,len=buf.length,pos=0){let bufLength=buf.length;if(off+len>bufLength&&(len=bufLength-off),len<=0)return 0;let requiredSize=pos+len;if(requiredSize>this.capacity){let newCapacity=Math.max(this.capacity*2,64);for(;newCapacity<requiredSize;)newCapacity*=2;let newBuf=(0,buffer_1.bufferAllocUnsafe)(newCapacity);this.size>0&&this.buf.copy(newBuf,0,0,this.size),this.buf=newBuf,this.capacity=newCapacity}return pos>this.size&&this.buf.fill(0,this.size,pos),buf.copy(this.buf,pos,off,off+len),requiredSize>this.size&&(this.size=requiredSize),this.touch(),len}read(buf,off=0,len=buf.byteLength,pos=0){if(this.atime=new Date,pos>=this.size)return 0;let actualLen=len;if(actualLen>buf.byteLength&&(actualLen=buf.byteLength),actualLen+pos>this.size&&(actualLen=this.size-pos),actualLen<=0)return 0;let buf2=buf instanceof buffer_1.Buffer?buf:buffer_1.Buffer.from(buf.buffer,buf.byteOffset,buf.byteLength);return this.buf.copy(buf2,off,pos,pos+actualLen),actualLen}truncate(len=0){if(len<=0){this.buf=EMPTY_BUFFER,this.capacity=0,this.size=0,this.touch();return}if(len<=this.size)this.size=len;else{if(len>this.capacity){let newCapacity=Math.max(this.capacity*2,64);for(;newCapacity<len;)newCapacity*=2;let buf=(0,buffer_1.bufferAllocUnsafe)(newCapacity);this.size>0&&this.buf.copy(buf,0,0,this.size),buf.fill(0,this.size,len),this.buf=buf,this.capacity=newCapacity}else this.buf.fill(0,this.size,len);this.size=len}this.touch()}chmod(perm){this.mode=this.mode&S_IFMT|perm&~S_IFMT,this.touch()}chown(uid,gid){this.uid=uid,this.gid=gid,this.touch()}touch(){this.mtime=new Date,this.changes.emit(["modify"])}canRead(uid=getuid(),gid=getgid()){return!!(this.perm&4||gid===this.gid&&this.perm&32||uid===this.uid&&this.perm&256)}canWrite(uid=getuid(),gid=getgid()){return!!(this.perm&2||gid===this.gid&&this.perm&16||uid===this.uid&&this.perm&128)}canExecute(uid=getuid(),gid=getgid()){return!!(this.perm&1||gid===this.gid&&this.perm&8||uid===this.uid&&this.perm&64)}del(){this.changes.emit(["delete"])}toJSON(){return{ino:this.ino,uid:this.uid,gid:this.gid,atime:this.atime.getTime(),mtime:this.mtime.getTime(),ctime:this.ctime.getTime(),btime:this.btime.getTime(),perm:this.perm,mode:this.mode,nlink:this.nlink,symlink:this.symlink,data:this.getString()}}};exports.Node=Node3}});var require_Link=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/Link.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Link=void 0;var fs_node_utils_1=require_lib5(),fanout_1=require_fanout(),{S_IFREG}=fs_node_utils_1.constants,Link=class _Link{get steps(){return this._steps}set steps(val){this._steps=val;for(let[child,link2]of this.children.entries())child==="."||child===".."||link2?.syncSteps()}constructor(vol,parent,name){this.changes=new fanout_1.FanOut,this.children=new Map,this._steps=[],this.ino=0,this.length=0,this.vol=vol,this.parent=parent,this.name=name,this.syncSteps()}setNode(node2){this.node=node2,this.ino=node2.ino}getNode(){return this.node}createChild(name,node2=this.vol.createNode(S_IFREG|438)){let link2=new _Link(this.vol,this,name);return link2.setNode(node2),node2.isDirectory()&&(link2.children.set(".",link2),link2.getNode().nlink++),this.setChild(name,link2),link2}setChild(name,link2=new _Link(this.vol,this,name)){return this.children.set(name,link2),link2.parent=this,this.length++,link2.getNode().isDirectory()&&(link2.children.set("..",this),this.getNode().nlink++),this.getNode().mtime=new Date,this.changes.emit(["child:add",link2,this]),link2}deleteChild(link2){link2.getNode().isDirectory()&&(link2.children.delete(".."),this.getNode().nlink--),this.children.delete(link2.getName()),this.length--,this.getNode().mtime=new Date,this.changes.emit(["child:del",link2,this])}getChild(name){return this.getNode().atime=new Date,this.children.get(name)}getPath(){return this.steps.join("/")}getParentPath(){let parent=this.steps.slice(0,-1).join("/");return parent||"/"}getName(){return this.steps[this.steps.length-1]}toJSON(){return{steps:this.steps,ino:this.ino,children:Array.from(this.children.keys())}}syncSteps(){this.steps=this.parent?this.parent.steps.concat([this.name]):[this.name]}};exports.Link=Link}});var require_File=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/File.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.File=void 0;var fs_node_utils_1=require_lib5(),{O_APPEND}=fs_node_utils_1.constants,File=class{constructor(link2,node2,flags,fd){this.link=link2,this.node=node2,this.flags=flags,this.fd=fd,this.position=0}getString(encoding="utf8"){return this.node.getString()}setString(str){this.node.setString(str)}getBuffer(){return this.node.getBuffer()}setBuffer(buf){this.node.setBuffer(buf)}getSize(){return this.node.getSize()}truncate(len){this.node.truncate(len)}seekTo(position2){this.position=position2}write(buf,offset=0,length=buf.length,position2){let append=!!(this.flags&O_APPEND),explicit=!append&&typeof position2=="number",pos=append?this.node.getSize():explicit?position2:this.position,bytes=this.node.write(buf,offset,length,pos);return explicit||(this.position=pos+bytes),bytes}read(buf,offset=0,length=buf.byteLength,position2){let explicit=typeof position2=="number",pos=explicit?position2:this.position,bytes=this.node.read(buf,offset,length,pos);return explicit||(this.position=pos+bytes),bytes}chmod(perm){this.node.chmod(perm)}chown(uid,gid){this.node.chown(uid,gid)}};exports.File=File}});var require_validators=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/validators.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.validateAbortSignal=exports.validateBuffer=exports.validateStringArray=exports.validateArray=exports.validateOneOf=exports.validateObject=exports.validateFunction=exports.validateBoolean=exports.validateString=exports.validateUint32=exports.validateInt32=exports.validateInteger=exports.INT32_MAX=void 0;var argErrors_1=require_argErrors();exports.INT32_MAX=2147483647;var INT32_MIN=-2147483648,UINT32_MAX=4294967295,MAX_SAFE=9007199254740991,validateRange=(value2,name,min,max)=>{if(typeof value2!="number")throw(0,argErrors_1.invalidArgType)(name,"of type number",value2);if(!Number.isInteger(value2))throw(0,argErrors_1.outOfRange)(name,"an integer",value2);if(value2<min||value2>max)throw(0,argErrors_1.outOfRange)(name,">= "+min+" && <= "+max,value2)},validateInteger=(value2,name,min=-MAX_SAFE,max=MAX_SAFE)=>validateRange(value2,name,min,max);exports.validateInteger=validateInteger;var validateInt32=(value2,name,min=INT32_MIN,max=exports.INT32_MAX)=>validateRange(value2,name,min,max);exports.validateInt32=validateInt32;var validateUint32=(value2,name,positive)=>validateRange(value2,name,positive?1:0,UINT32_MAX);exports.validateUint32=validateUint32;var validateString=(value2,name)=>{if(typeof value2!="string")throw(0,argErrors_1.invalidArgType)(name,"of type string",value2)};exports.validateString=validateString;var validateBoolean=(value2,name)=>{if(typeof value2!="boolean")throw(0,argErrors_1.invalidArgType)(name,"of type boolean",value2)};exports.validateBoolean=validateBoolean;var validateFunction=(value2,name)=>{if(typeof value2!="function")throw(0,argErrors_1.invalidArgType)(name,"of type function",value2)};exports.validateFunction=validateFunction;var validateObject=(value2,name,options2=0)=>{if(value2===null&&!(options2&1)||Array.isArray(value2)&&!(options2&2)||value2!==null&&typeof value2!="object"&&(typeof value2!="function"||!(options2&4)))throw(0,argErrors_1.invalidArgType)(name,"of type object",value2)};exports.validateObject=validateObject;var validateOneOf=(value2,name,oneOf)=>{if(oneOf.includes(value2))return;let allowed="";for(let i2=0;i2<oneOf.length;i2++){let one2=oneOf[i2];allowed+=(i2?", ":"")+(typeof one2=="string"?"'"+one2+"'":String(one2))}throw(0,argErrors_1.invalidArgValue)(name,value2,"must be one of: "+allowed)};exports.validateOneOf=validateOneOf;var validateArray=(value2,name,minLength=0)=>{if(!Array.isArray(value2))throw(0,argErrors_1.invalidArgType)(name,"an instance of Array",value2);if(value2.length<minLength)throw(0,argErrors_1.invalidArgValue)(name,value2,"must have a length of at least "+minLength)};exports.validateArray=validateArray;var validateStringArray=(value2,name)=>{(0,exports.validateArray)(value2,name);let array=value2;for(let i2=0;i2<array.length;i2++)if(typeof array[i2]!="string")throw(0,argErrors_1.invalidArgType)(name+"["+i2+"]","of type string",array[i2])};exports.validateStringArray=validateStringArray;var validateBuffer=(buffer,name="buffer")=>{if(!ArrayBuffer.isView(buffer))throw(0,argErrors_1.invalidArgType)(name,"an instance of Buffer, TypedArray, or DataView",buffer)};exports.validateBuffer=validateBuffer;var validateAbortSignal=(signal,name)=>{if(signal!==void 0&&(signal===null||typeof signal!="object"||!("aborted"in signal)))throw(0,argErrors_1.invalidArgType)(name,"an instance of AbortSignal",signal)};exports.validateAbortSignal=validateAbortSignal}});var require_util=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/util.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.filenameToSteps=exports.resolve=exports.unixify=exports.isWin=void 0;exports.isFd=isFd;exports.validateFd=validateFd;exports.dataToBuffer=dataToBuffer;exports.nullCheck=nullCheck;exports.pathToFilename=pathToFilename;var path_1=require_path2(),buffer_1=require_buffer3(),process_1=require_process(),fs_node_utils_1=require_lib5(),argErrors_1=require_argErrors(),validators_1=require_validators();exports.isWin=process_1.default.platform==="win32";var resolveCrossPlatform=path_1.resolve,isSeparator=(str,i2)=>{let char=str[i2];return i2>0&&(char==="/"||exports.isWin&&char==="\\")},removeTrailingSeparator=str=>{let i2=str.length-1;if(i2<2)return str;for(;isSeparator(str,i2);)i2--;return str.substr(0,i2+1)},normalizePath2=(str,stripTrailing)=>{if(typeof str!="string")throw new TypeError("expected a string");return str=str.replace(/[\\\/]+/g,"/"),stripTrailing!==!1&&(str=removeTrailingSeparator(str)),str},unixify=(filepath,stripTrailing=!0)=>exports.isWin?(filepath=normalizePath2(filepath,stripTrailing),filepath.replace(/^([a-zA-Z]+:|\.\/)/,"")):filepath;exports.unixify=unixify;var resolve2=(filename,base2=process_1.default.cwd())=>resolveCrossPlatform(base2,filename);exports.resolve=resolve2;if(exports.isWin){let _resolve=resolve2;exports.resolve=resolve2=(filename,base2)=>(0,exports.unixify)(_resolve(filename,base2))}var filenameToSteps=(filename,base2)=>{let fullPathSansSlash=resolve2(filename,base2).substring(1);return fullPathSansSlash?fullPathSansSlash.split(fs_node_utils_1.pathSep):[]};exports.filenameToSteps=filenameToSteps;function isFd(path4){return path4>>>0===path4}function validateFd(fd){if(typeof fd!="number")throw(0,argErrors_1.invalidArgType)("fd","of type number",fd,!0);if((fd<0||fd>validators_1.INT32_MAX)&&fd!==1/0&&fd!==-1/0)throw(0,argErrors_1.outOfRange)("fd",">= 0 && <= "+validators_1.INT32_MAX,fd,!0);if(!Number.isInteger(fd))throw(0,argErrors_1.outOfRange)("fd","an integer",fd,!0)}function dataToBuffer(data,encoding=fs_node_utils_1.ENCODING_UTF8){return buffer_1.Buffer.isBuffer(data)?data:data instanceof Uint8Array?(0,buffer_1.bufferFrom)(data):encoding==="buffer"?(0,buffer_1.bufferFrom)(String(data),"utf8"):(0,buffer_1.bufferFrom)(String(data),encoding)}var NO_NULL_BYTES="must be a string, Uint8Array, or URL without null bytes",checkNullByte=(path4,name,received)=>{if(path4.indexOf("\0")!==-1)throw(0,argErrors_1.invalidArgValue)(name,received,NO_NULL_BYTES)};function nullCheck(path4,name="path"){if(path4 instanceof Uint8Array){for(let i2=0;i2<path4.length;i2++)if(!path4[i2])throw(0,argErrors_1.invalidArgValue)(name,path4,NO_NULL_BYTES);return!0}let str=""+path4;return checkNullByte(str,name,str),!0}var isURL=value2=>!!value2&&!!value2.href&&!!value2.protocol&&value2.auth===void 0&&value2.path===void 0,getPathFromURL=url=>{if(url.protocol!=="file:")throw(0,argErrors_1.invalidUrlScheme)("file");if(url.hostname!=="")throw(0,argErrors_1.withCode)(new TypeError('File URL host must be "localhost" or empty on '+process_1.default.platform),"ERR_INVALID_FILE_URL_HOST");let pathname=url.pathname;for(let n2=0;n2<pathname.length;n2++)if(pathname[n2]==="%"){let third=pathname.codePointAt(n2+2)|32;if(pathname[n2+1]==="2"&&third===102)throw(0,argErrors_1.withCode)(new TypeError("File URL path must not include encoded / characters"),"ERR_INVALID_FILE_URL_PATH")}let filepath=decodeURIComponent(pathname);return exports.isWin?filepath.replace(/^\/([a-zA-Z]:)/,"$1"):filepath};function pathToFilename(path4,name="path"){let received=path4;if(path4 instanceof Uint8Array&&(path4=(0,buffer_1.bufferFrom)(path4)),typeof path4!="string"&&!buffer_1.Buffer.isBuffer(path4)){if(!isURL(path4))throw(0,argErrors_1.invalidArgType)(name,"of type string or an instance of Buffer or URL",path4);path4=getPathFromURL(path4)}let pathString=String(path4);return checkNullByte(pathString,name,received instanceof Uint8Array?received:pathString),pathString}}});var require_SystemError=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/SystemError.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.SystemError=void 0;var SystemError=class extends Error{constructor(code4,prefix,info){let path4=info.path,dest=info.dest,message=prefix+": "+info.syscall+" returned "+info.code+" ("+info.message+")";path4!==void 0&&(message+=" "+path4),dest!==void 0&&(message+=" => "+dest),super(message),this.code=code4,this.info=info,this.errno=info.errno,this.syscall=info.syscall,path4!==void 0&&(this.path=path4),dest!==void 0&&(this.dest=dest)}toString(){return this.name+" ["+this.code+"]: "+this.message}};exports.SystemError=SystemError;SystemError.prototype.name="SystemError"}});var require_errors=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/errors.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.createEisdirError=exports.createWatchError=exports.createStatError=exports.createError=void 0;var SystemError_1=require_SystemError(),UV={EPERM:[-1,"operation not permitted"],ENOENT:[-2,"no such file or directory"],EIO:[-5,"i/o error"],EBADF:[-9,"bad file descriptor"],EAGAIN:[-11,"resource temporarily unavailable"],EACCES:[-13,"permission denied"],EBUSY:[-16,"resource busy or locked"],EEXIST:[-17,"file already exists"],EXDEV:[-18,"cross-device link not permitted"],ENOTDIR:[-20,"not a directory"],EISDIR:[-21,"illegal operation on a directory"],EINVAL:[-22,"invalid argument"],ENFILE:[-23,"file table overflow"],EMFILE:[-24,"too many open files"],ETXTBSY:[-26,"text file is busy"],EFBIG:[-27,"file too large"],ENOSPC:[-28,"no space left on device"],ESPIPE:[-29,"invalid seek"],EROFS:[-30,"read-only file system"],EMLINK:[-31,"too many links"],ERANGE:[-34,"result too large"],ENAMETOOLONG:[-36,"name too long"],ENOSYS:[-38,"function not implemented"],ENOTEMPTY:[-39,"directory not empty"],ELOOP:[-40,"too many symbolic links encountered"],EPROTO:[-71,"protocol error"],EOVERFLOW:[-75,"value too large for defined data type"],ENOTSUP:[-95,"operation not supported on socket"]},formatMessage=(code4,uv,syscall,path4,dest)=>{let message=code4+": "+(uv?uv[1]:"unknown error")+", "+syscall;return path4&&(message+=" '"+path4+"'"),dest&&(message+=" -> '"+dest+"'"),message},createError=(code4,syscall="",path4="",dest="",Constructor=Error)=>{let uv=UV[code4],error=new Constructor(formatMessage(code4,uv,syscall,path4,dest));return uv&&(error.errno=uv[0]),error.code=code4,error.syscall=syscall,path4&&(error.path=path4),dest&&(error.dest=dest),error};exports.createError=createError;var createStatError=(code4,syscall="",path4="",dest="")=>{let uv=UV[code4];return{errno:uv?uv[0]:void 0,code:code4,syscall,path:path4,dest,message:formatMessage(code4,uv,syscall,path4,dest),toError:()=>(0,exports.createError)(code4,syscall,path4,dest)}};exports.createStatError=createStatError;var createWatchError=(code4,filename)=>{let uv=UV[code4],error=new Error(formatMessage(code4,uv,"watch",filename,""));return uv&&(error.errno=uv[0]),error.syscall="watch",error.code=code4,error.path=filename,error.filename=filename,error};exports.createWatchError=createWatchError;var createEisdirError=(syscall,path4)=>new SystemError_1.SystemError("ERR_FS_EISDIR","Path is a directory",{code:"EISDIR",message:"is a directory",path:path4,syscall,errno:-UV.EISDIR[0]});exports.createEisdirError=createEisdirError}});var require_FsEvent=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/watch/FsEvent.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FsEvent=void 0;var FsEvent=class{constructor(type,steps,node2,link2,oldSteps=void 0){this.type=type,this.steps=steps,this.node=node2,this.link=link2,this.oldSteps=oldSteps}};exports.FsEvent=FsEvent}});var require_Superblock=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/Superblock.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Superblock=void 0;var path_1=require_path2(),Node_1=require_Node(),Link_1=require_Link(),File_1=require_File(),buffer_1=require_buffer3(),process_1=require_process(),fs_node_utils_1=require_lib5(),fs_node_utils_2=require_lib5(),util_1=require_util(),errors_1=require_errors(),argErrors_1=require_argErrors(),json_1=require_json(),result_1=require_result2(),fanout_1=require_fanout(),FsEvent_1=require_FsEvent(),{O_RDONLY,O_WRONLY,O_RDWR,O_CREAT,O_EXCL,O_TRUNC,O_DIRECTORY,O_NOFOLLOW}=fs_node_utils_1.constants,MAX_SYMLINK_HOPS=40,endsWithSep=(path4,win32)=>{let i2=path4.length-1;if(i2<1)return!1;let code4=path4.charCodeAt(i2);return code4===46&&(code4=path4.charCodeAt(--i2)),code4===47||win32&&code4===92},Superblock=class _Superblock{static fromJSON(json,cwd2,opts){let vol=new _Superblock(opts);return vol.fromJSON(json,cwd2),vol}static fromNestedJSON(json,cwd2,opts){let vol=new _Superblock(opts);return vol.fromNestedJSON(json,cwd2),vol}constructor(opts={}){this.ino=0,this.inodes={},this.releasedInos=[],this.fds={},this.releasedFds=[],this.maxFiles=1e4,this.openFiles=0,this.changes=new fanout_1.FanOut,this.open=(filename,flagsNum,modeNum,resolveSymlinks=!0)=>{let file=this.openFile(filename,flagsNum,modeNum,resolveSymlinks);if(!file)throw(0,errors_1.createError)("ENOENT","open",filename);return file.fd},this.writeFile=(id,buf,flagsNum,modeNum)=>{let isUserFd=typeof id=="number",fd;isUserFd?fd=id:fd=this.open((0,util_1.pathToFilename)(id),flagsNum,modeNum);let offset=0,length=buf.length;try{for(;length>0;){let written=this.write(fd,buf,offset,length,null);offset+=written,length-=written}}finally{isUserFd||this.close(fd)}},this.read=(fd,buffer,offset,length,position2)=>{if(offset<0)throw(0,argErrors_1.outOfRange)("offset",">= 0 && <= 9007199254740991",offset);if(length===0)return 0;if(length<0)throw(0,argErrors_1.outOfRange)("length",">= 0",length);if(offset+length>buffer.byteLength)throw(0,argErrors_1.outOfRange)("length","<= "+(buffer.byteLength-offset),length);let file=this.getFileByFdOrThrow(fd,"read");if(file.node.isSymlink())throw(0,errors_1.createError)("EPERM","read",file.link.getPath());return file.read(buffer,Number(offset),Number(length),position2===-1||typeof position2!="number"?void 0:position2)},this.readv=(fd,buffers,position2)=>{let file=this.getFileByFdOrThrow(fd,"read"),p2=position2??void 0;p2===-1&&(p2=void 0);let bytesRead=0;for(let buffer of buffers){let bytes=file.read(buffer,0,buffer.byteLength,p2);if(p2!==void 0&&(p2+=bytes),bytesRead+=bytes,bytes<buffer.byteLength)break}return bytesRead},this.link=(filename1,filename2)=>{let link1;try{link1=this.getLinkOrThrow(filename1,"link")}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"link",filename1,filename2)),err}let dirname22=(0,path_1.dirname)(filename2),dir2;try{dir2=this.getLinkOrThrow(dirname22,"link")}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"link",filename1,filename2)),err}let name=(0,path_1.basename)(filename2);if(dir2.getChild(name))throw(0,errors_1.createError)("EEXIST","link",filename1,filename2);let node2=link1.getNode();node2.nlink++;let newLink=dir2.createChild(name,node2);this.emit(new FsEvent_1.FsEvent(0,newLink.steps,node2,newLink))},this.unlink=filename=>{let link2=this.getLinkOrThrow(filename,"unlink");if(link2.getNode().isDirectory())throw(0,errors_1.createError)("EPERM","unlink",filename);this._emitDeleteRecursive(link2),this.deleteLink(link2);let node2=link2.getNode();node2.nlink--,node2.nlink<=0&&this.deleteNode(node2)},this.symlink=(targetFilename,pathFilename)=>{if(!targetFilename)throw(0,errors_1.createError)("ENOENT","symlink",targetFilename,pathFilename);let pathSteps=this.filenameToSteps(pathFilename),dirLink;try{dirLink=this.getLinkParentAsDirOrThrow(pathSteps)}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"symlink",targetFilename,pathFilename)),err}let name=pathSteps[pathSteps.length-1];if(dirLink.getChild(name))throw(0,errors_1.createError)("EEXIST","symlink",targetFilename,pathFilename);let node2=dirLink.getNode();if(!node2.canExecute()||!node2.canWrite())throw(0,errors_1.createError)("EACCES","symlink",targetFilename,pathFilename);let symlink=dirLink.createChild(name);return symlink.getNode().makeSymlink(targetFilename),this.emit(new FsEvent_1.FsEvent(0,symlink.steps,symlink.getNode(),symlink)),symlink},this.rename=(oldPathFilename,newPathFilename)=>{let link2;try{link2=this.getResolvedLinkOrThrow(oldPathFilename)}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"rename",oldPathFilename,newPathFilename)),err}let newPathDirLink;try{newPathDirLink=this.getLinkParentAsDirOrThrow(newPathFilename)}catch(err){throw err.code&&(err=(0,errors_1.createError)(err.code,"rename",oldPathFilename,newPathFilename)),err}let oldLinkParent=link2.parent;if(!oldLinkParent)throw(0,errors_1.createError)("EINVAL","rename",oldPathFilename,newPathFilename);let oldParentNode=oldLinkParent.getNode(),newPathDirNode=newPathDirLink.getNode();if(!oldParentNode.canExecute()||!oldParentNode.canWrite()||!newPathDirNode.canExecute()||!newPathDirNode.canWrite())throw(0,errors_1.createError)("EACCES","rename",oldPathFilename,newPathFilename);oldLinkParent.deleteChild(link2);let name=(0,path_1.basename)(newPathFilename),oldSteps=link2.steps;link2.name=name,link2.steps=[...newPathDirLink.steps,name],newPathDirLink.setChild(link2.getName(),link2),this.emit(new FsEvent_1.FsEvent(4,link2.steps,link2.getNode(),link2,oldSteps))},this.mkdir=(filename,modeNum)=>{let steps=this.filenameToSteps(filename);if(!steps.length)throw(0,errors_1.createError)("EEXIST","mkdir",filename);let dir=this.getLinkParentAsDirOrThrow(filename,"mkdir"),name=steps[steps.length-1];if(dir.getChild(name))throw(0,errors_1.createError)("EEXIST","mkdir",filename);let node2=dir.getNode();if(!node2.canWrite()||!node2.canExecute())throw(0,errors_1.createError)("EACCES","mkdir",filename);let child=dir.createChild(name,this.createNode(fs_node_utils_1.constants.S_IFDIR|modeNum));this.emit(new FsEvent_1.FsEvent(0,child.steps,child.getNode(),child))},this.mkdirp=(filename,modeNum)=>{let created=!1,steps=this.filenameToSteps(filename),curr=null,i2=steps.length;for(i2=steps.length;i2>=0&&(curr=this.getResolvedLink(steps.slice(0,i2)),!curr);i2--);for(curr||(curr=this.root,i2=0),curr=this.getResolvedLinkOrThrow(fs_node_utils_2.pathSep+steps.slice(0,i2).join(fs_node_utils_2.pathSep),"mkdir"),i2;i2<steps.length;i2++){let node2=curr.getNode();if(node2.isDirectory()){if(!node2.canExecute()||!node2.canWrite())throw(0,errors_1.createError)("EACCES","mkdir",filename)}else throw(0,errors_1.createError)("ENOTDIR","mkdir",filename);created=!0,curr=curr.createChild(steps[i2],this.createNode(fs_node_utils_1.constants.S_IFDIR|modeNum)),this.emit(new FsEvent_1.FsEvent(0,curr.steps,curr.getNode(),curr))}return created?filename:void 0},this.rmdir=(filename,recursive=!1)=>{let link2=this.getLinkAsDirOrThrow(filename,"rmdir");if(link2.length&&!recursive)throw(0,errors_1.createError)("ENOTEMPTY","rmdir",filename);this._emitDeleteRecursive(link2),this.deleteLink(link2)},this.rm=(filename,force=!1,recursive=!1)=>{let link2;try{link2=this.getResolvedLinkOrThrow(filename,"lstat")}catch(err){if(err.code==="ENOENT"&&force)return;throw err}if(link2.getNode().isDirectory()&&!recursive)throw(0,errors_1.createEisdirError)("rm",filename);if(!link2.parent?.getNode().canWrite())throw(0,errors_1.createError)("EACCES","rm",filename);this._emitDeleteRecursive(link2),this.deleteLink(link2)},this.close=fd=>{(0,util_1.validateFd)(fd);let file=this.getFileByFdOrThrow(fd,"close");this.closeFile(file)},this.ftruncate=(fd,len)=>{let file=this.getFileByFdOrThrow(fd,"ftruncate");file.truncate(len),this.emit(new FsEvent_1.FsEvent(2,file.link.steps,file.node,file.link))},this.fchmod=(fd,modeNum)=>{let file=this.getFileByFdOrThrow(fd,"fchmod");file.chmod(modeNum),this.emit(new FsEvent_1.FsEvent(3,file.link.steps,file.node,file.link))},this.chmod=(filename,modeNum)=>{let link2=this.getResolvedLinkOrThrow(filename,"chmod");link2.getNode().chmod(modeNum),this.emit(new FsEvent_1.FsEvent(3,link2.steps,link2.getNode(),link2))},this.lchmod=(filename,modeNum)=>{let link2=this.getLinkOrThrow(filename,"lchmod");link2.getNode().chmod(modeNum),this.emit(new FsEvent_1.FsEvent(3,link2.steps,link2.getNode(),link2))},this.fchown=(fd,uid,gid)=>{let file=this.getFileByFdOrThrow(fd,"fchown");file.chown(uid,gid),this.emit(new FsEvent_1.FsEvent(3,file.link.steps,file.node,file.link))},this.chown=(filename,uid,gid)=>{let link2=this.getResolvedLinkOrThrow(filename,"chown");link2.getNode().chown(uid,gid),this.emit(new FsEvent_1.FsEvent(3,link2.steps,link2.getNode(),link2))},this.lchown=(filename,uid,gid)=>{let link2=this.getLinkOrThrow(filename,"lchown");link2.getNode().chown(uid,gid),this.emit(new FsEvent_1.FsEvent(3,link2.steps,link2.getNode(),link2))},this.futimes=(fd,atime,mtime)=>{let file=this.getFileByFdOrThrow(fd,"futime"),node2=file.node;node2.atime=new Date(atime*1e3),node2.mtime=new Date(mtime*1e3),this.emit(new FsEvent_1.FsEvent(3,file.link.steps,file.node,file.link))},this.utimes=(filename,atime,mtime,followSymlinks=!0)=>{let link2=followSymlinks?this.getResolvedLinkOrThrow(filename,"utime"):this.getLinkOrThrow(filename,"lutime"),node2=link2.getNode();node2.atime=new Date(atime*1e3),node2.mtime=new Date(mtime*1e3),this.emit(new FsEvent_1.FsEvent(3,link2.steps,node2,link2))},this.process=opts.process??process_1.default;let root4=this.createLink();root4.setNode(this.createNode(fs_node_utils_1.constants.S_IFDIR|511)),root4.setChild(".",root4),root4.getNode().nlink++,root4.setChild("..",root4),root4.getNode().nlink++,this.root=root4}filenameToSteps(filename){return(0,util_1.filenameToSteps)(filename,this.process.cwd())}emit(change){this.changes.emit(change)}createLink(parent,name,isDirectory=!1,mode){if(!parent)return new Link_1.Link(this,void 0,"");if(!name)throw new Error("createLink: name cannot be empty");let finalPerm=mode??(isDirectory?511:438),modeType=mode&&mode&fs_node_utils_1.constants.S_IFMT?mode&fs_node_utils_1.constants.S_IFMT:isDirectory?fs_node_utils_1.constants.S_IFDIR:fs_node_utils_1.constants.S_IFREG,finalMode=finalPerm&~fs_node_utils_1.constants.S_IFMT|modeType;return parent.createChild(name,this.createNode(finalMode))}deleteLink(link2){let parent=link2.parent;return parent?(parent.deleteChild(link2),!0):!1}_emitDeleteRecursive(link2){if(link2.getNode().isDirectory())for(let[name,child]of link2.children.entries())child&&name!=="."&&name!==".."&&this._emitDeleteRecursive(child);this.emit(new FsEvent_1.FsEvent(1,link2.steps,link2.getNode(),link2))}newInoNumber(){let releasedFd=this.releasedInos.pop();return releasedFd||(this.ino=(this.ino+1)%4294967295,this.ino)}newFdNumber(){let releasedFd=this.releasedFds.pop();return typeof releasedFd=="number"?releasedFd:_Superblock.fd--}createNode(mode){let uid=this.process.getuid?.()??0,gid=this.process.getgid?.()??0,node2=new Node_1.Node(this.newInoNumber(),mode,uid,gid);return this.inodes[node2.ino]=node2,node2}deleteNode(node2){node2.del(),delete this.inodes[node2.ino],this.releasedInos.push(node2.ino)}walk(stepsOrFilenameOrLink,resolveSymlinks=!1,checkExistence=!1,checkAccess=!1,funcName,budget){let steps,filename;stepsOrFilenameOrLink instanceof Link_1.Link?(steps=stepsOrFilenameOrLink.steps,filename=fs_node_utils_2.pathSep+steps.join(fs_node_utils_2.pathSep)):typeof stepsOrFilenameOrLink=="string"?(steps=this.filenameToSteps(stepsOrFilenameOrLink),filename=stepsOrFilenameOrLink):(steps=stepsOrFilenameOrLink,filename=fs_node_utils_2.pathSep+steps.join(fs_node_utils_2.pathSep));let curr=this.root,i2=0,hops=budget?budget.hops:0,uid=this.process.getuid?.()??0,gid=this.process.getgid?.()??0;for(;i2<steps.length;){let node2=curr.getNode();if(node2.isDirectory()){if(checkAccess&&!node2.canExecute(uid,gid))return(0,result_1.Err)((0,errors_1.createStatError)("EACCES",funcName,filename))}else if(i2<steps.length-1)return(0,result_1.Err)((0,errors_1.createStatError)("ENOTDIR",funcName,filename));if(curr=curr.getChild(steps[i2])??null,!curr)return checkExistence?(0,result_1.Err)((0,errors_1.createStatError)("ENOENT",funcName,filename)):(0,result_1.Ok)(null);if(node2=curr?.getNode(),node2.isSymlink()&&(resolveSymlinks||i2<steps.length-1)){if(++hops>MAX_SYMLINK_HOPS)return(0,result_1.Err)((0,errors_1.createStatError)("ELOOP",funcName,filename));budget&&(budget.hops=hops);let resolvedPath=(0,path_1.isAbsolute)(node2.symlink)?node2.symlink:(0,fs_node_utils_2.pathJoin)((0,path_1.dirname)(curr.getPath()),node2.symlink);steps=this.filenameToSteps(resolvedPath).concat(steps.slice(i2+1)),curr=this.root,i2=0;continue}if(checkExistence&&!node2.isDirectory()&&i2<steps.length-1){let errorCode=this.process.platform==="win32"?"ENOENT":"ENOTDIR";return(0,result_1.Err)((0,errors_1.createStatError)(errorCode,funcName,filename))}i2++}return(0,result_1.Ok)(curr)}getLink(steps){let result=this.walk(steps,!1,!1,!1);if(result.ok)return result.value;throw result.err.toError()}getLinkOrThrow(filename,funcName){let result=this.walk(filename,!1,!0,!0,funcName);if(result.ok)return result.value;throw result.err.toError()}getResolvedLink(filenameOrSteps){let result=this.walk(filenameOrSteps,!0,!1,!1);if(result.ok)return result.value;throw result.err.toError()}getResolvedLinkOrThrow(filename,funcName){let result=this.walk(filename,!0,!0,!0,funcName);if(result.ok)return result.value;throw result.err.toError()}getResolvedLinkResult(filename,funcName){let result=this.walk(filename,!0,!0,!0,funcName);return result.ok?(0,result_1.Ok)(result.value):result}resolveSymlinks(link2){return this.getResolvedLink(link2.steps.slice(1))}getLinkAsDirOrThrow(filename,funcName){let link2=this.getLinkOrThrow(filename,funcName);if(!link2.getNode().isDirectory())throw(0,errors_1.createError)("ENOTDIR",funcName,filename);return link2}getLinkParent(steps){return this.getLink(steps.slice(0,-1))}getLinkParentAsDirOrThrow(filenameOrSteps,funcName){let steps=(filenameOrSteps instanceof Array?filenameOrSteps:this.filenameToSteps(filenameOrSteps)).slice(0,-1),filename=fs_node_utils_2.pathSep+steps.join(fs_node_utils_2.pathSep),link2=this.getLinkOrThrow(filename,funcName);if(!link2.getNode().isDirectory())throw(0,errors_1.createError)("ENOTDIR",funcName,filename);return link2}getFileByFd(fd){return this.fds[String(fd)]}getFileByFdOrThrow(fd,funcName){(0,util_1.validateFd)(fd);let file=this.getFileByFd(fd);if(!file)throw(0,errors_1.createError)("EBADF",funcName);return file}_toJSON(link2=this.root,json={},path4,asBuffer){let isEmpty2=!0,children=link2.children;link2.getNode().isFile()&&(children=new Map([[link2.getName(),link2.parent.getChild(link2.getName())]]),link2=link2.parent);for(let name of children.keys()){if(name==="."||name==="..")continue;isEmpty2=!1;let child=link2.getChild(name);if(!child)throw new Error("_toJSON: unexpected undefined");let node2=child.getNode();if(node2.isFile()){let filename=child.getPath();path4&&(filename=(0,fs_node_utils_2.pathRelative)(path4,filename)),json[filename]=asBuffer?node2.getBuffer():node2.getString()}else node2.isDirectory()&&this._toJSON(child,json,path4,asBuffer)}let dirPath=link2.getPath();return path4&&(dirPath=(0,fs_node_utils_2.pathRelative)(path4,dirPath)),dirPath&&isEmpty2&&(json[dirPath]=null),json}toJSON(paths,json={},isRelative=!1,asBuffer=!1){let links=[];if(paths){Array.isArray(paths)||(paths=[paths]);for(let path4 of paths){let filename=(0,util_1.pathToFilename)(path4),link2=this.getResolvedLink(filename);link2&&links.push(link2)}}else links.push(this.root);if(!links.length)return json;for(let link2 of links)this._toJSON(link2,json,isRelative?link2.getPath():"",asBuffer);return json}fromJSON(json,cwd2=this.process.cwd()){for(let filename in json){let data=json[filename];if(filename=(0,util_1.resolve)(filename,cwd2),typeof data=="string"||data instanceof buffer_1.Buffer){let dir=(0,path_1.dirname)(filename);this.mkdirp(dir,511);let buffer=(0,util_1.dataToBuffer)(data);this.writeFile(filename,buffer,fs_node_utils_2.FLAGS.w,438)}else this.mkdirp(filename,511)}}fromNestedJSON(json,cwd2){this.fromJSON((0,json_1.flattenJSON)(json),cwd2)}reset(){this.ino=0,this.inodes={},this.releasedInos=[],this.fds={},this.releasedFds=[],this.openFiles=0,this.root=this.createLink(),this.root.setNode(this.createNode(fs_node_utils_1.constants.S_IFDIR|511))}mountSync(mountpoint,json){this.fromJSON(json,mountpoint)}openLink(link2,flagsNum,resolveSymlinks=!0,filename=link2.getPath()){if(this.openFiles>=this.maxFiles)throw(0,errors_1.createError)("EMFILE","open",filename);let realLink=link2;resolveSymlinks&&(realLink=this.getResolvedLinkOrThrow(link2.getPath(),"open"));let node2=realLink.getNode();if(node2.isDirectory()){if((flagsNum&(O_RDONLY|O_RDWR|O_WRONLY))!==O_RDONLY)throw(0,errors_1.createError)("EISDIR","open",filename)}else if(flagsNum&O_DIRECTORY)throw(0,errors_1.createError)("ENOTDIR","open",filename);if(node2.isSymlink()&&flagsNum&O_NOFOLLOW)throw(0,errors_1.createError)("ELOOP","open",filename);if((flagsNum&(O_RDONLY|O_RDWR|O_WRONLY))!==O_WRONLY&&!node2.canRead()||flagsNum&(O_WRONLY|O_RDWR)&&!node2.canWrite())throw(0,errors_1.createError)("EACCES","open",filename);let file=new File_1.File(link2,node2,flagsNum,this.newFdNumber());if(this.fds[file.fd]=file,this.openFiles++,flagsNum&O_TRUNC){let hadContent=file.node.getSize()>0;file.truncate(),hadContent&&this.emit(new FsEvent_1.FsEvent(2,file.link.steps,file.node,file.link))}return file}throwCreatDir(path4,filename,budget){let dir=this.walk((0,path_1.dirname)(path4),!0,!0,!0,"open",budget);if(!dir.ok)throw(0,errors_1.createError)(dir.err.code,"open",filename);let node2=dir.value.getNode();throw node2.isDirectory()?node2.canExecute()?(0,errors_1.createError)("EISDIR","open",filename):(0,errors_1.createError)("EACCES","open",filename):(0,errors_1.createError)("ENOTDIR","open",filename)}openFile(filename,flagsNum,modeNum,resolveSymlinks=!0){if(this.openFiles>=this.maxFiles)throw(0,errors_1.createError)("EMFILE","open",filename);if((flagsNum&(O_CREAT|O_DIRECTORY))===(O_CREAT|O_DIRECTORY))throw(0,errors_1.createError)("EINVAL","open",filename);let win32=this.process.platform==="win32",budget={hops:0},trailingSlash=endsWithSep(filename,win32);trailingSlash&&flagsNum&O_CREAT&&this.throwCreatDir(filename,filename,budget);let excl=(flagsNum&(O_CREAT|O_EXCL))===(O_CREAT|O_EXCL),follow=trailingSlash||resolveSymlinks&&!(flagsNum&O_NOFOLLOW)&&!excl,path4=filename,link2=null;for(;;){let hops=budget.hops,result=this.walk(path4,!1,!0,!0,"open",budget);if(!result.ok){let code4=result.err.code;if(code4!=="ENOENT"||!(flagsNum&O_CREAT))throw(0,errors_1.createError)(code4,"open",filename);budget.hops=hops,link2=null;break}link2=result.value;let node2=link2.getNode();if(!follow||!node2.isSymlink())break;if(++budget.hops>MAX_SYMLINK_HOPS)throw(0,errors_1.createError)("ELOOP","open",filename);path4=(0,path_1.isAbsolute)(node2.symlink)?node2.symlink:(0,fs_node_utils_2.pathJoin)((0,path_1.dirname)(link2.getPath()),node2.symlink),endsWithSep(path4,win32)&&(flagsNum&O_CREAT&&this.throwCreatDir(path4,filename,budget),trailingSlash=!0)}if(link2){let node2=link2.getNode();if(excl)throw(0,errors_1.createError)("EEXIST","open",filename);if(trailingSlash&&!node2.isDirectory())throw(0,errors_1.createError)("ENOTDIR","open",filename);if(flagsNum&O_CREAT&&node2.isDirectory())throw(0,errors_1.createError)("EISDIR","open",filename);return this.openLink(link2,flagsNum,!1,filename)}let dir=this.walk((0,path_1.dirname)(path4),!0,!0,!0,"open",budget);if(!dir.ok)throw(0,errors_1.createError)(dir.err.code,"open",filename);let dirLink=dir.value,dirNode=dirLink.getNode();if(!dirNode.isDirectory())throw(0,errors_1.createError)("ENOTDIR","open",filename);if(!dirNode.canExecute()||!dirNode.canWrite())throw(0,errors_1.createError)("EACCES","open",filename);modeNum??(modeNum=438);let steps=(0,util_1.filenameToSteps)(path4);return link2=this.createLink(dirLink,steps[steps.length-1],!1,modeNum),this.emit(new FsEvent_1.FsEvent(0,link2.steps,link2.getNode(),link2)),this.openLink(link2,flagsNum,!1,filename)}closeFile(file){this.fds[file.fd]&&(this.openFiles--,delete this.fds[file.fd],this.releasedFds.push(file.fd))}write(fd,buf,offset,length,position2){let file=this.getFileByFdOrThrow(fd,"write");if(file.node.isSymlink())throw(0,errors_1.createError)("EBADF","write",file.link.getPath());let bytes=file.write(buf,offset,length,position2===-1||typeof position2!="number"?void 0:position2);return bytes>0&&this.emit(new FsEvent_1.FsEvent(2,file.link.steps,file.node,file.link)),bytes}};exports.Superblock=Superblock;Superblock.fd=2147483647}});var require_CoreWatcher=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/watch/CoreWatcher.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.CoreWatcher=exports.CoreWatchEvent=void 0;var fanout_1=require_fanout(),CoreWatchEvent=class{constructor(type,steps,node2,link2,oldSteps=void 0){this.type=type,this.steps=steps,this.node=node2,this.link=link2,this.oldSteps=oldSteps}};exports.CoreWatchEvent=CoreWatchEvent;var CoreWatcher=class{constructor(core,path4,opts={}){this.changes=new fanout_1.FanOut,this.link=opts.follow??!0?core.getResolvedLinkOrThrow(path4,"watch"):core.getLinkOrThrow(path4,"watch"),this.node=this.link.getNode(),this.recursive=!!opts.recursive,this.unsub=core.changes.listen(event=>this.onEvent(event))}get closed(){return!this.unsub}onEvent(event){let rootLength=this.link.steps.length;if(event.link===this.link||event.node===this.node&&(event.type===2||event.type===3)){this.changes.emit(new CoreWatchEvent(event.type,[],event.node,this.link)),event.type===1&&this.close();return}if(event.type===4){let from=event.oldSteps&&this.inScope(event.oldSteps)?event.oldSteps.slice(rootLength):void 0,to=this.inScope(event.steps)?event.steps.slice(rootLength):void 0;from&&to?this.changes.emit(new CoreWatchEvent(4,to,event.node,event.link,from)):from?this.changes.emit(new CoreWatchEvent(1,from,event.node,event.link)):to&&this.changes.emit(new CoreWatchEvent(0,to,event.node,event.link));return}this.inScope(event.steps)&&this.changes.emit(new CoreWatchEvent(event.type,event.steps.slice(rootLength),event.node,event.link))}inScope(steps){let root4=this.link.steps;if(steps.length<=root4.length||!this.recursive&&steps.length!==root4.length+1)return!1;for(let i2=0;i2<root4.length;i2++)if(steps[i2]!==root4[i2])return!1;return!0}close(){this.unsub?.(),this.unsub=void 0}};exports.CoreWatcher=CoreWatcher}});var require_lib6=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-core@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-core/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.SystemError=exports.createWatchError=exports.createEisdirError=exports.createStatError=exports.createError=exports.resolve=exports.pathToFilename=exports.nullCheck=exports.validateFd=exports.isWin=exports.isFd=exports.filenameToSteps=exports.dataToBuffer=exports.Superblock=exports.File=exports.Link=exports.Node=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports));tslib_1.__exportStar(require_types(),exports);tslib_1.__exportStar(require_json(),exports);tslib_1.__exportStar(require_constants3(),exports);tslib_1.__exportStar(require_result2(),exports);var Node_1=require_Node();Object.defineProperty(exports,"Node",{enumerable:!0,get:function(){return Node_1.Node}});var Link_1=require_Link();Object.defineProperty(exports,"Link",{enumerable:!0,get:function(){return Link_1.Link}});var File_1=require_File();Object.defineProperty(exports,"File",{enumerable:!0,get:function(){return File_1.File}});var Superblock_1=require_Superblock();Object.defineProperty(exports,"Superblock",{enumerable:!0,get:function(){return Superblock_1.Superblock}});tslib_1.__exportStar(require_FsEvent(),exports);tslib_1.__exportStar(require_CoreWatcher(),exports);var util_1=require_util();Object.defineProperty(exports,"dataToBuffer",{enumerable:!0,get:function(){return util_1.dataToBuffer}});Object.defineProperty(exports,"filenameToSteps",{enumerable:!0,get:function(){return util_1.filenameToSteps}});Object.defineProperty(exports,"isFd",{enumerable:!0,get:function(){return util_1.isFd}});Object.defineProperty(exports,"isWin",{enumerable:!0,get:function(){return util_1.isWin}});Object.defineProperty(exports,"validateFd",{enumerable:!0,get:function(){return util_1.validateFd}});Object.defineProperty(exports,"nullCheck",{enumerable:!0,get:function(){return util_1.nullCheck}});Object.defineProperty(exports,"pathToFilename",{enumerable:!0,get:function(){return util_1.pathToFilename}});Object.defineProperty(exports,"resolve",{enumerable:!0,get:function(){return util_1.resolve}});var errors_1=require_errors();Object.defineProperty(exports,"createError",{enumerable:!0,get:function(){return errors_1.createError}});Object.defineProperty(exports,"createStatError",{enumerable:!0,get:function(){return errors_1.createStatError}});Object.defineProperty(exports,"createEisdirError",{enumerable:!0,get:function(){return errors_1.createEisdirError}});Object.defineProperty(exports,"createWatchError",{enumerable:!0,get:function(){return errors_1.createWatchError}});var SystemError_1=require_SystemError();Object.defineProperty(exports,"SystemError",{enumerable:!0,get:function(){return SystemError_1.SystemError}})}});var require_Stats=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/Stats.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Stats=void 0;var fs_node_utils_1=require_lib5(),{S_IFMT,S_IFDIR,S_IFREG,S_IFBLK,S_IFCHR,S_IFLNK,S_IFIFO,S_IFSOCK}=fs_node_utils_1.constants,Stats=class _Stats{static build(node2,bigint=!1){let stats=new _Stats,{uid,gid,atime,mtime,ctime,btime}=node2,getStatNumber=bigint?number=>BigInt(number):number=>number;return stats.uid=getStatNumber(uid),stats.gid=getStatNumber(gid),stats.rdev=getStatNumber(node2.rdev),stats.blksize=getStatNumber(4096),stats.ino=getStatNumber(node2.ino),stats.size=getStatNumber(node2.getSize()),stats.blocks=getStatNumber(1),stats.atime=new Date(atime.getTime()),stats.mtime=new Date(mtime.getTime()),stats.ctime=new Date(ctime.getTime()),stats.birthtime=new Date(btime.getTime()),stats.atimeMs=getStatNumber(atime.getTime()),stats.mtimeMs=getStatNumber(mtime.getTime()),stats.ctimeMs=getStatNumber(ctime.getTime()),stats.birthtimeMs=getStatNumber(btime.getTime()),bigint&&(stats.atimeNs=BigInt(atime.getTime())*BigInt(1e6),stats.mtimeNs=BigInt(mtime.getTime())*BigInt(1e6),stats.ctimeNs=BigInt(ctime.getTime())*BigInt(1e6),stats.birthtimeNs=BigInt(btime.getTime())*BigInt(1e6)),stats.dev=getStatNumber(0),stats.mode=getStatNumber(node2.mode),stats.nlink=getStatNumber(node2.nlink),stats}_checkModeProperty(property){return(Number(this.mode)&S_IFMT)===property}isDirectory(){return this._checkModeProperty(S_IFDIR)}isFile(){return this._checkModeProperty(S_IFREG)}isBlockDevice(){return this._checkModeProperty(S_IFBLK)}isCharacterDevice(){return this._checkModeProperty(S_IFCHR)}isSymbolicLink(){return this._checkModeProperty(S_IFLNK)}isFIFO(){return this._checkModeProperty(S_IFIFO)}isSocket(){return this._checkModeProperty(S_IFSOCK)}};exports.Stats=Stats;exports.default=Stats}});var require_Dirent=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/Dirent.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Dirent=void 0;var fs_node_utils_1=require_lib5(),{S_IFMT,S_IFDIR,S_IFREG,S_IFBLK,S_IFCHR,S_IFLNK,S_IFIFO,S_IFSOCK}=fs_node_utils_1.constants,Dirent=class _Dirent{constructor(){this.name="",this.parentPath="",this.mode=0,this.path=""}static build(link2,encoding,parentPath=link2.getParentPath()){let dirent=new _Dirent,{mode}=link2.getNode();return dirent.name=(0,fs_node_utils_1.strToEncoding)(link2.getName(),encoding),dirent.mode=mode,dirent.parentPath=parentPath,dirent.path=parentPath,dirent}_checkModeProperty(property){return(this.mode&S_IFMT)===property}isDirectory(){return this._checkModeProperty(S_IFDIR)}isFile(){return this._checkModeProperty(S_IFREG)}isBlockDevice(){return this._checkModeProperty(S_IFBLK)}isCharacterDevice(){return this._checkModeProperty(S_IFCHR)}isSymbolicLink(){return this._checkModeProperty(S_IFLNK)}isFIFO(){return this._checkModeProperty(S_IFIFO)}isSocket(){return this._checkModeProperty(S_IFSOCK)}};exports.Dirent=Dirent;exports.default=Dirent}});var require_StatFs=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/StatFs.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.StatFs=void 0;var StatFs=class _StatFs{static build(superblock,bigint=!1){let statfs=new _StatFs,getStatNumber=bigint?number=>BigInt(number):number=>number;statfs.type=getStatNumber(2240043254),statfs.bsize=getStatNumber(4096);let totalInodes=Object.keys(superblock.inodes).length,totalBlocks=1e6,usedBlocks=Math.min(totalInodes*2,totalBlocks),freeBlocks=totalBlocks-usedBlocks;statfs.blocks=getStatNumber(totalBlocks),statfs.bfree=getStatNumber(freeBlocks),statfs.bavail=getStatNumber(freeBlocks);let maxFiles=1e6;return statfs.files=getStatNumber(maxFiles),statfs.ffree=getStatNumber(maxFiles-totalInodes),statfs}};exports.StatFs=StatFs;exports.default=StatFs}});var browser_url_exports={};__export(browser_url_exports,{URL:()=>URL2,URLSearchParams:()=>URLSearchParams,fileURLToPath:()=>fileURLToPath,pathToFileURL:()=>pathToFileURL});var import_path_browserify,URL2,URLSearchParams,fileURLToPath,pathToFileURL,init_browser_url=__esm({"packages/workspace/src/browser-url.ts"(){"use strict";init_browser_globals();import_path_browserify=__toESM(require_path_browserify(),1),URL2=globalThis.URL,URLSearchParams=globalThis.URLSearchParams,fileURLToPath=value2=>{let url=new URL2(value2);if(url.protocol!=="file:"||url.hostname)throw new Error("Expected a local file URL");return decodeURIComponent(url.pathname)},pathToFileURL=value2=>new URL2(`file://${import_path_browserify.default.resolve(value2).split("/").map(encodeURIComponent).join("/")}`)}});var require_url2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-builtins@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-builtins/lib/url.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.URL=void 0;var node_url_1=(init_browser_url(),__toCommonJS(browser_url_exports));Object.defineProperty(exports,"URL",{enumerable:!0,get:function(){return node_url_1.URL}})}});var require_readWriteArgs=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/readWriteArgs.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.getWriteSyncArgs=exports.getWriteArgs=exports.getVectorCallbackArgs=exports.getVectorArgs=exports.getHandleWriteArgs=exports.getHandleReadArgs=exports.getReadArgs=exports.getReadSyncArgs=void 0;var buffer_1=require_buffer3(),fs_core_1=require_lib6(),argErrors_1=require_argErrors(),validators_1=require_validators(),READ_BUFFER_SIZE=16384,validateOptions=(value2,name)=>(0,validators_1.validateObject)(value2,name,1),validatePosition=(position2,name,length)=>{if(typeof position2=="number")(0,validators_1.validateInteger)(position2,name,-1);else if(typeof position2=="bigint"){let max=2n**63n-1n-BigInt(length);if(!(position2>=-1n&&position2<=max))throw(0,argErrors_1.outOfRange)(name,">= -1 && <= "+max,position2)}else throw(0,argErrors_1.invalidArgType)(name,"of type bigint or integer",position2)},validateBufferArray=(buffers,name="buffers")=>{if(!Array.isArray(buffers))throw(0,argErrors_1.invalidArgType)(name,"an ArrayBufferView[]",buffers);let length=buffers.length;for(let i2=0;i2<length;i2++)if(!ArrayBuffer.isView(buffers[i2]))throw(0,argErrors_1.invalidArgType)(name,"an ArrayBufferView[]",buffers)},validateOffsetLengthRead=(offset,length,bufferLength)=>{if(offset<0)throw(0,argErrors_1.outOfRange)("offset",">= 0",offset);if(length<0)throw(0,argErrors_1.outOfRange)("length",">= 0",length);if(offset+length>bufferLength)throw(0,argErrors_1.outOfRange)("length","<= "+(bufferLength-offset),length)},validateOffsetLengthWrite=(offset,length,byteLength)=>{if(offset>byteLength)throw(0,argErrors_1.outOfRange)("offset","<= "+byteLength,offset);if(length>byteLength-offset)throw(0,argErrors_1.outOfRange)("length","<= "+(byteLength-offset),length);if(length<0)throw(0,argErrors_1.outOfRange)("length",">= 0",length);(0,validators_1.validateInt32)(length,"length",0)},validateStringAfterArrayBufferView=(buffer,name)=>{if(typeof buffer!="string")throw(0,argErrors_1.invalidArgType)(name,"of type string or an instance of Buffer, TypedArray, or DataView",buffer)},toEncoding=encoding=>typeof encoding=="string"&&buffer_1.Buffer.isEncoding(encoding)?encoding:"utf8",validateEncoding=(data,encoding)=>{if(toEncoding(encoding)==="hex"&&data.length%2!==0)throw(0,argErrors_1.invalidArgValue)("encoding",encoding,"is invalid for data of length "+data.length)},viewToBuffer=view=>buffer_1.Buffer.isBuffer(view)?view:buffer_1.Buffer.from(view.buffer,view.byteOffset,view.byteLength),seekPosition=position2=>typeof position2=="number"&&position2>=0&&Number.isSafeInteger(position2)?position2:null,readPosition=position2=>typeof position2=="bigint"?position2<0n?null:Number(position2):position2<0?null:position2,getReadSyncArgs=(argc,buffer,a2,b2,c2)=>{(0,validators_1.validateBuffer)(buffer);let view=buffer,offset=a2,length=b2,position2=c2;if(argc<=3||typeof a2=="object"){a2!==void 0&&validateOptions(a2,"options");let options2=a2??{};offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:view.byteLength-offset,position2=options2.position!==void 0?options2.position:null}if(offset===void 0?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),length=length|0,position2==null?position2=-1:validatePosition(position2,"position",length),length!==0){if(view.byteLength===0)throw(0,argErrors_1.invalidArgValue)("buffer",view,"is empty and cannot be written");validateOffsetLengthRead(offset,length,view.byteLength)}return{buffer:view,offset,length,position:readPosition(position2)}};exports.getReadSyncArgs=getReadSyncArgs;var getReadArgs=(argc,buffer,a2,b2,c2,d2)=>{let buf=buffer,params=null,offset=a2,length=b2,position2=c2,callback=d2;if(argc<=4){if(argc===4)validateOptions(a2,"options"),callback=b2,params=a2;else if(argc===3){if(!ArrayBuffer.isView(buf)){params=buf;let source3=buf??{};buf=source3.buffer!==void 0?source3.buffer:buffer_1.Buffer.alloc(READ_BUFFER_SIZE)}callback=a2}else callback=buf,buf=buffer_1.Buffer.alloc(READ_BUFFER_SIZE);params!==void 0&&validateOptions(params,"options");let source2=params??{};offset=source2.offset!==void 0?source2.offset:0,length=source2.length!==void 0?source2.length:buf?.byteLength-offset,position2=source2.position!==void 0?source2.position:null}if((0,validators_1.validateBuffer)(buf),(0,validators_1.validateFunction)(callback,"cb"),offset==null?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),length=length|0,position2==null?position2=-1:validatePosition(position2,"position",length),length!==0){if(buf.byteLength===0)throw(0,argErrors_1.invalidArgValue)("buffer",buf,"is empty and cannot be written");validateOffsetLengthRead(offset,length,buf.byteLength)}return{buffer:buf,offset,length,position:readPosition(position2),callback}};exports.getReadArgs=getReadArgs;var getHandleReadArgs=(bufferOrParams,a2,b2,c2)=>{let buf=bufferOrParams,offset=a2,length=b2,position2=c2;if(!ArrayBuffer.isView(buf)){bufferOrParams!==void 0&&validateOptions(bufferOrParams,"options");let source2=bufferOrParams??{};buf=source2.buffer!==void 0?source2.buffer:buffer_1.Buffer.alloc(READ_BUFFER_SIZE),offset=source2.offset!==void 0?source2.offset:0,length=source2.length!==void 0?source2.length:buf.byteLength-offset,position2=source2.position!==void 0?source2.position:null,(0,validators_1.validateBuffer)(buf)}if(offset!==null&&typeof offset=="object"){let options2=offset;offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:buf.byteLength-offset,position2=options2.position!==void 0?options2.position:null}if(offset==null?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),length==null&&(length=buf.byteLength-offset),position2==null?position2=-1:validatePosition(position2,"position",length),length!==0){if(buf.byteLength===0)throw(0,argErrors_1.invalidArgValue)("buffer",buf,"is empty and cannot be written");validateOffsetLengthRead(offset,length,buf.byteLength)}return{buffer:buf,offset,length,position:readPosition(position2)}};exports.getHandleReadArgs=getHandleReadArgs;var getHandleWriteArgs=(data,a2,b2,c2)=>{if(data?.byteLength===0)return null;let offset=a2,length=b2,position2=c2;if(ArrayBuffer.isView(data)){let view=data;if(typeof offset=="object"){let options2=offset??{};offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:view.byteLength-offset,position2=options2.position!==void 0?options2.position:null}return offset==null?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),typeof length!="number"&&(length=view.byteLength-offset),validateOffsetLengthWrite(offset,length,view.byteLength),{buffer:viewToBuffer(view),offset,length,position:seekPosition(position2)}}validateStringAfterArrayBufferView(data,"buffer");let str=data;validateEncoding(str,length);let buf=(0,buffer_1.bufferFrom)(str,toEncoding(length));return{buffer:buf,offset:0,length:buf.length,position:seekPosition(offset)}};exports.getHandleWriteArgs=getHandleWriteArgs;var getVectorArgs=(buffers,position2)=>(validateBufferArray(buffers),seekPosition(position2));exports.getVectorArgs=getVectorArgs;var getVectorCallbackArgs=(buffers,a2,b2)=>{validateBufferArray(buffers);let callback=b2||a2;return(0,validators_1.validateFunction)(callback,"cb"),[seekPosition(a2),callback]};exports.getVectorCallbackArgs=getVectorCallbackArgs;var getWriteArgs=(fd,a2,b2,c2,d2,e2)=>{(0,validators_1.validateInt32)(fd,"fd",0);let offset=b2,length=c2,position2=d2,callback=e2;if(ArrayBuffer.isView(a2)){let view=a2;if(callback||(callback=position2||length||offset),(0,validators_1.validateFunction)(callback,"cb"),typeof offset=="object"){let options2=offset??{};offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:view.byteLength-offset,position2=options2.position!==void 0?options2.position:null}return offset==null||typeof offset=="function"?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),typeof length!="number"&&(length=view.byteLength-offset),validateOffsetLengthWrite(offset,length,view.byteLength),[fd,!1,viewToBuffer(view),offset,length,seekPosition(position2),callback]}validateStringAfterArrayBufferView(a2,"buffer"),typeof position2!="function"&&(typeof offset=="function"?(position2=offset,offset=null):position2=length,length="utf8");let str=a2;validateEncoding(str,length),callback=position2,(0,validators_1.validateFunction)(callback,"cb");let buf=(0,buffer_1.bufferFrom)(str,toEncoding(length));return[fd,!0,buf,0,buf.length,seekPosition(offset),callback]};exports.getWriteArgs=getWriteArgs;var getWriteSyncArgs=(fd,a2,b2,c2,d2)=>{let offset=b2,length=c2,position2=d2;if(ArrayBuffer.isView(a2)){let view=a2;if(typeof offset=="object"){let options2=offset??{};offset=options2.offset!==void 0?options2.offset:0,length=options2.length!==void 0?options2.length:view.byteLength-offset,position2=options2.position!==void 0?options2.position:null}return offset==null?offset=0:(0,validators_1.validateInteger)(offset,"offset",0),typeof length!="number"&&(length=view.byteLength-offset),validateOffsetLengthWrite(offset,length,view.byteLength),(0,fs_core_1.validateFd)(fd),[fd,viewToBuffer(view),offset,length,seekPosition(position2)]}validateStringAfterArrayBufferView(a2,"buffer");let str=a2;validateEncoding(str,length),(0,fs_core_1.validateFd)(fd);let buf=(0,buffer_1.bufferFrom)(str,toEncoding(length));return[fd,buf,0,buf.length,seekPosition(offset)]};exports.getWriteSyncArgs=getWriteSyncArgs}});var require_util2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/util.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.getWriteSyncArgs=exports.getWriteArgs=exports.bufToUint8=exports.createWatchError=exports.createStatError=exports.createError=exports.pathToFilename=exports.nullCheck=void 0;exports.promisify=promisify;exports.validateCallback=validateCallback;exports.modeToNumber=modeToNumber;exports.genRndStr6=genRndStr6;exports.flagsToNumber=flagsToNumber;exports.streamToBuffer=streamToBuffer;exports.bufferToEncoding=bufferToEncoding;exports.isReadableStream=isReadableStream;var fs_node_utils_1=require_lib5(),argErrors_1=require_argErrors(),validators_1=require_validators(),buffer_1=require_buffer3(),fs_core_1=require_lib6();Object.defineProperty(exports,"nullCheck",{enumerable:!0,get:function(){return fs_core_1.nullCheck}});Object.defineProperty(exports,"pathToFilename",{enumerable:!0,get:function(){return fs_core_1.pathToFilename}});Object.defineProperty(exports,"createError",{enumerable:!0,get:function(){return fs_core_1.createError}});Object.defineProperty(exports,"createStatError",{enumerable:!0,get:function(){return fs_core_1.createStatError}});Object.defineProperty(exports,"createWatchError",{enumerable:!0,get:function(){return fs_core_1.createWatchError}});function promisify(fs2,fn2,getResult=input=>input){return(...args)=>new Promise((resolve2,reject)=>{fs2[fn2].bind(fs2)(...args,(error,result)=>error?reject(error):resolve2(getResult(result)))})}function validateCallback(callback,name="cb"){return(0,validators_1.validateFunction)(callback,name),callback}var OCTAL_REG=/^[0-7]+$/,MODE_DESC="must be a 32-bit unsigned integer or an octal string";function modeToNumber(mode,def,name="mode"){let value2=mode??def;if(typeof value2=="string"){if(!OCTAL_REG.test(value2))throw(0,argErrors_1.invalidArgValue)(name,value2,MODE_DESC);value2=parseInt(value2,8)}return(0,validators_1.validateUint32)(value2,name),value2+0}function genRndStr6(){return Math.random().toString(36).slice(2,8).padEnd(6,"0")}function flagsToNumber(flags){if(typeof flags=="number")return(0,validators_1.validateInt32)(flags,"flags"),flags;if(typeof flags=="string"){let flagsNum=fs_node_utils_1.FLAGS[flags];if(typeof flagsNum<"u")return flagsNum}throw(0,argErrors_1.invalidArgValue)("flags",flags)}function streamToBuffer(stream){let chunks=[];return new Promise((resolve2,reject)=>{stream.on("data",chunk=>chunks.push(chunk)),stream.on("end",()=>resolve2(buffer_1.Buffer.concat(chunks))),stream.on("error",reject)})}var bufToUint8=buf=>new Uint8Array(buf.buffer,buf.byteOffset,buf.byteLength);exports.bufToUint8=bufToUint8;var readWriteArgs_1=require_readWriteArgs();Object.defineProperty(exports,"getWriteArgs",{enumerable:!0,get:function(){return readWriteArgs_1.getWriteArgs}});Object.defineProperty(exports,"getWriteSyncArgs",{enumerable:!0,get:function(){return readWriteArgs_1.getWriteSyncArgs}});function bufferToEncoding(buffer,encoding){return!encoding||encoding==="buffer"?buffer:buffer.toString(encoding)}function isReadableStream(stream){return stream!==null&&typeof stream=="object"&&typeof stream.pipe=="function"&&typeof stream.on=="function"&&stream.readable===!0}}});var require_glob=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/glob.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.globSync=exports.globWalk=void 0;exports.glob=glob;var path_1=require_path2(),url_1=require_url2(),argErrors_1=require_argErrors(),validators_1=require_validators(),glob_to_regex_js_1=require_lib4(),util_1=require_util2(),Dirent_1=require_Dirent(),{basename:basename4,dirname:dirname4,isAbsolute:isAbsolute3,join:join5,relative:relative2,resolve:resolve2}=path_1.posix,internalAssertionError=()=>(0,argErrors_1.withCode)(new Error(`This is caused by either a bug in Node.js or incorrect usage of Node.js internals.
|
|
40
40
|
Please open an issue with this stack trace at https://github.com/nodejs/node/issues
|
|
41
41
|
`),"ERR_INTERNAL_ASSERTION"),validateStringArrayOrFunction=(value2,name)=>{if(Array.isArray(value2)){for(let i2=0;i2<value2.length;i2++)if(typeof value2[i2]!="string")throw(0,argErrors_1.invalidArgType)(name+"["+i2+"]","of type string",value2[i2]);return}if(typeof value2!="function")throw(0,argErrors_1.invalidArgType)(name,"of type function or string[]",value2)},toPathIfFileURL=value2=>{if(!(value2 instanceof url_1.URL))return value2;if(value2.protocol!=="file:")throw(0,argErrors_1.invalidUrlScheme)("file");return(0,util_1.pathToFilename)(value2)},GLOBSTAR=Symbol("globstar **"),MAGIC=/[*?[]|[!+@]\(/,OPTS={extglob:!0,dot:!1},parsePart=part=>part==="**"?GLOBSTAR:MAGIC.test(part)?(0,glob_to_regex_js_1.toRegex)(part,OPTS):part,firstPhasePreProcess=globParts=>{let didSomething=!1;do{didSomething=!1;for(let n2=0;n2<globParts.length;n2++){let parts=globParts[n2],gs=-1;for(;(gs=parts.indexOf("**",gs+1))!==-1;){let gss=gs;for(;parts[gss+1]==="**";)gss++;gss>gs&&parts.splice(gs+1,gss-gs);let next=parts[gs+1],p2=parts[gs+2],p22=parts[gs+3];if(next!==".."||!p2||p2==="."||p2===".."||!p22||p22==="."||p22==="..")continue;didSomething=!0,parts.splice(gs,1);let other=parts.slice(0);other[gs]="**",globParts.push(other),gs--}for(let i2=1;i2<parts.length-1;i2++){let p2=parts[i2];i2===1&&p2===""&&parts[0]===""||(p2==="."||p2==="")&&(didSomething=!0,parts.splice(i2,1),i2--)}parts[0]==="."&&parts.length===2&&(parts[1]==="."||parts[1]==="")&&(didSomething=!0,parts.pop());let dd=0;for(;(dd=parts.indexOf("..",dd+1))!==-1;){let p2=parts[dd-1];if(p2&&p2!=="."&&p2!==".."&&p2!=="**"){didSomething=!0;let needDot=dd===1&&parts[dd+1]==="**";parts.splice(dd-1,2,...needDot?["."]:[]),parts.length||parts.push(""),dd-=2}}}}while(didSomething);return globParts},partsMatch=(a2,b2)=>{let ai=0,bi=0,result=[],which="";for(;ai<a2.length&&bi<b2.length;)if(a2[ai]===b2[bi])result.push(which==="b"?b2[bi]:a2[ai]),ai++,bi++;else if(a2[ai]==="**"&&b2[bi]===a2[ai+1])result.push(a2[ai]),ai++;else if(b2[bi]==="**"&&a2[ai]===b2[bi+1])result.push(b2[bi]),bi++;else if(a2[ai]==="*"&&b2[bi]&&!b2[bi].startsWith(".")&&b2[bi]!=="**"){if(which==="b")return!1;which="a",result.push(a2[ai]),ai++,bi++}else if(b2[bi]==="*"&&a2[ai]&&!a2[ai].startsWith(".")&&a2[ai]!=="**"){if(which==="a")return!1;which="b",result.push(b2[bi]),ai++,bi++}else return!1;return a2.length===b2.length&&result},secondPhasePreProcess=globParts=>{for(let i2=0;i2<globParts.length-1;i2++)for(let j=i2+1;j<globParts.length;j++){let matched=partsMatch(globParts[i2],globParts[j]);if(matched){globParts[i2]=[],globParts[j]=matched;break}}return globParts.filter(parts=>parts.length)},compile=pattern=>{let source2=pattern.replace(/\\/g,"/");if(!source2)return[[],[]];let globSet=[...new Set((0,glob_to_regex_js_1.expandBraces)(source2))],globParts=secondPhasePreProcess(firstPhasePreProcess(globSet.map(one2=>one2.split(/\/+/))));return[globParts.map(parts=>parts.map(parsePart)),globParts]},createExcludeMatcher=(patterns,root4)=>{let regexes=[];for(let i2=0;i2<patterns.length;i2++)regexes.push((0,glob_to_regex_js_1.toRegex)(resolve2(root4,patterns[i2].replace(/\\/g,"/")),OPTS));return value2=>{for(let i2=0;i2<regexes.length;i2++)if(regexes[i2].test(value2))return!0;return!1}},Pattern=class _Pattern{constructor(parts,globStrings,indexes,symlinks,realpaths=new Set){this.parts=parts,this.globStrings=globStrings,this.indexes=indexes,this.symlinks=symlinks,this.realpaths=realpaths,this.last=parts.length-1}isLast(isDirectory){return this.indexes.has(this.last)||this.at(-1)===""&&isDirectory&&this.indexes.has(this.last-1)&&this.at(-2)===GLOBSTAR}isFirst(){return this.indexes.has(0)}get hasSeenSymlinks(){for(let index4 of this.indexes)if(!this.symlinks.has(index4))return!0;return!1}at(index4){let parts=this.parts;return parts[index4<0?parts.length+index4:index4]}child(indexes,symlinks=new Set,realpaths=this.realpaths){return new _Pattern(this.parts,this.globStrings,indexes,symlinks,realpaths)}test(index4,path4){let part=this.parts[index4];return part===GLOBSTAR?!0:typeof part=="string"?part===path4:part!==void 0&&part.test(path4)}cacheKey(index4){let globStrings=this.globStrings,length=globStrings.length,key="";for(let i2=index4;i2<length;i2++)key+=globStrings[i2],i2!==length-1&&(key+="/");return key}},rethrowUnlessFsError=error=>{if(!error?.code)throw error},direntOf=(name,parentPath,mode)=>{let dirent=new Dirent_1.default;return dirent.name=name,dirent.parentPath=parentPath,dirent.path=parentPath,dirent.mode=mode,dirent},Cache=class{constructor(fs2){this.fs=fs2,this.stats=new Map,this.followStats=new Map,this.realpaths=new Map,this.readdirs=new Map,this.seenKeys=new Map}statSync(path4){let cached2=this.stats.get(path4);if(cached2!==void 0)return cached2;let value2=null;try{value2=direntOf(basename4(path4),dirname4(path4),this.fs.lstatSync(path4).mode)}catch(error){rethrowUnlessFsError(error)}return this.stats.set(path4,value2),value2}followStatSync(path4){let cached2=this.followStats.get(path4);if(cached2!==void 0)return cached2;let value2=null;try{value2=direntOf(basename4(path4),dirname4(path4),this.fs.statSync(path4).mode)}catch(error){rethrowUnlessFsError(error)}return this.followStats.set(path4,value2),value2}realpathSync(path4){let cached2=this.realpaths.get(path4);if(cached2!==void 0)return cached2;let value2=null;try{value2=String(this.fs.realpathSync(path4))}catch(error){rethrowUnlessFsError(error)}return this.realpaths.set(path4,value2),value2}readdirSync(path4){let cached2=this.readdirs.get(path4);if(cached2!==void 0)return cached2;let value2=[];try{value2=this.fs.readdirSync(path4,{withFileTypes:!0})}catch(error){rethrowUnlessFsError(error)}return this.readdirs.set(path4,value2),value2}addToStatCache(path4,value2){this.stats.set(path4,value2)}add(path4,pattern){let keys=this.seenKeys.get(path4);keys||(keys=new Set,this.seenKeys.set(path4,keys));let originalSize=keys.size;for(let index4 of pattern.indexes)keys.add(pattern.cacheKey(index4));return keys.size!==originalSize+pattern.indexes.size}seen(path4,pattern,index4){return!!this.seenKeys.get(path4)?.has(pattern.cacheKey(index4))}},depthOf=(root4,fullpath)=>{let rel=relative2(root4,fullpath);if(!rel)return 0;let parts=rel.split("/"),depth=0;for(let i2=0;i2<parts.length;i2++)depth+=parts[i2]===".."?-1:1;return depth},EMPTY_OPTIONS={},Glob=class{constructor(fs2,pattern,options2=EMPTY_OPTIONS){this.fs=fs2,this.followSymlinks=!1,this.isExcluded=()=>!1,this.results=new Set,this.queue=[],this.subpatterns=new Map,(0,validators_1.validateObject)(options2,"options");let{exclude,cwd:cwd2,followSymlinks,withFileTypes,maxdepth}=options2;if(this.cache=new Cache(fs2),this.root=toPathIfFileURL(cwd2)??".",followSymlinks!=null&&((0,validators_1.validateBoolean)(followSymlinks,"options.followSymlinks"),this.followSymlinks=followSymlinks),this.withFileTypes=!!withFileTypes,this.maxdepth=maxdepth??1/0,exclude!=null)if(validateStringArrayOrFunction(exclude,"options.exclude"),Array.isArray(exclude)){if(typeof this.root!="string")throw internalAssertionError();this.isExcluded=createExcludeMatcher(exclude,this.root)}else this.exclude=exclude;let patterns;typeof pattern=="object"?((0,validators_1.validateStringArray)(pattern,"patterns"),patterns=pattern):((0,validators_1.validateString)(pattern,"patterns"),patterns=[pattern]);let compiled=[];for(let i2=0;i2<patterns.length;i2++){let[set2,globParts]=compile(patterns[i2]);for(let j=0;j<set2.length;j++)compiled.push(new Pattern(set2[j],globParts[j],new Set([0]),new Set))}this.patterns=compiled}*walk(){let queue2=this.queue;for(queue2.push({path:".",patterns:this.patterns});queue2.length>0;){let item=queue2.pop();for(let i2=0;i2<item.patterns.length;i2++)yield*this.walkPattern(item.path,item.patterns[i2]);this.subpatterns.forEach((patterns,path4)=>queue2.push({path:path4,patterns})),this.subpatterns.clear()}}result(path4){if(!this.withFileTypes)return path4;let full=isAbsolute3(path4)?path4:join5(this.root,path4),stat2=this.cache.statSync(full);return direntOf(basename4(full),dirname4(full),stat2?stat2.mode:0)}isDirectory(path4,stat2,pattern){return stat2?.isDirectory()?!0:stat2?.isSymbolicLink()?this.followSymlinks?!!this.cache.followStatSync(path4)?.isDirectory():pattern.hasSeenSymlinks:!1}nextRealpaths(path4,isDirectory,pattern){if(!this.followSymlinks||!isDirectory)return pattern.realpaths;let real=this.cache.realpathSync(path4);if(real===null)return pattern.realpaths;let realpaths=new Set(pattern.realpaths);return realpaths.add(real),realpaths}isCyclic(path4,isDirectory,pattern){if(!this.followSymlinks||!isDirectory)return!1;let real=this.cache.realpathSync(path4);return real!==null&&pattern.realpaths.has(real)}addSubpattern(path4,pattern){if(this.isExcluded(path4))return;let fullpath=resolve2(this.root,path4);if(this.isExcluded(fullpath+"/")&&this.cache.statSync(fullpath)?.isDirectory())return;let exclude=this.exclude;if(exclude){if(this.withFileTypes){let stat2=this.cache.statSync(path4);if(stat2!==null&&exclude(stat2))return}else if(exclude(path4))return}let existing=this.subpatterns.get(path4);existing?existing.push(pattern):this.subpatterns.set(path4,[pattern])}accept(path4){return this.results.has(path4)||this.isExcluded(resolve2(this.root,path4))?!1:(this.results.add(path4),!0)}*walkPattern(path4,pattern){if(this.cache.add(path4,pattern))return;let cache3=this.cache,fullpath=resolve2(this.root,path4),stat2=cache3.statSync(fullpath),last=pattern.last,isDirectory=this.isDirectory(fullpath,stat2,pattern),isLast=pattern.isLast(isDirectory),isFirst=pattern.isFirst();if(this.isExcluded(fullpath))return;if(isFirst&&pattern.at(0)===""){this.addSubpattern("/",pattern.child(new Set([1])));return}if(isFirst&&pattern.at(0)===".."){this.addSubpattern("../",pattern.child(new Set([1])));return}if(isFirst&&pattern.at(0)==="."){this.addSubpattern(".",pattern.child(new Set([1])));return}if(isLast&&typeof pattern.at(-1)=="string"){let p2=pattern.at(-1),leaf=cache3.statSync(join5(fullpath,p2)),match=join5(path4,p2);if(leaf&&(p2||isDirectory)&&this.accept(match)&&(yield this.result(match)),pattern.indexes.size===1&&pattern.indexes.has(last))return}else isLast&&pattern.at(-1)===GLOBSTAR&&(path4!=="."||pattern.at(0)==="."||!last&&stat2)&&this.accept(path4)&&(yield this.result(path4));if(!isDirectory||this.isCyclic(fullpath,isDirectory,pattern)||this.maxdepth!==1/0&&depthOf(this.root,fullpath)>this.maxdepth)return;let nextRealpaths=this.nextRealpaths(fullpath,isDirectory,pattern),children,firstPattern=pattern.indexes.size===1&&pattern.at(pattern.indexes.values().next().value);if(typeof firstPattern=="string"){let child=cache3.statSync(join5(fullpath,firstPattern));if(!child)return;child.name=firstPattern,children=[child]}else children=cache3.readdirSync(fullpath);for(let i2=0;i2<children.length;i2++){let entry=children[i2],name=entry.name,entryPath=join5(path4,name),entryFullpath=join5(fullpath,name);cache3.addToStatCache(entryFullpath,entry);let entryIsDirectory=entry.isDirectory()||this.followSymlinks&&entry.isSymbolicLink()&&!!cache3.followStatSync(entryFullpath)?.isDirectory(),subPatterns=new Set,nSymlinks=new Set;for(let index4 of pattern.indexes){if(cache3.seen(entryPath,pattern,index4)||cache3.seen(entryPath,pattern,index4+1))return;let current=pattern.at(index4),nextIndex=index4+1,next=pattern.at(nextIndex),fromSymlink=!this.followSymlinks&&pattern.symlinks.has(index4);if(current===GLOBSTAR){let isDot=name.charCodeAt(0)===46,nextMatches=pattern.test(nextIndex,name),nextNonGlobIndex=nextIndex;for(;pattern.at(nextNonGlobIndex)===GLOBSTAR;)nextNonGlobIndex++;let matchesDot=isDot&&pattern.test(nextNonGlobIndex,name);if(isDot&&!matchesDot||this.exclude&&this.exclude(this.withFileTypes?entry:name))continue;if(!fromSymlink&&entryIsDirectory?subPatterns.add(index4):!fromSymlink&&index4===last&&this.accept(entryPath)&&(yield this.result(entryPath)),nextMatches&&nextIndex===last&&!isLast?this.accept(entryPath)&&(yield this.result(entryPath)):nextMatches&&entryIsDirectory&&subPatterns.add(index4+2),(nextMatches||pattern.at(0)===".")&&(entryIsDirectory||entry.isSymbolicLink())&&!fromSymlink&&subPatterns.add(nextIndex),!this.followSymlinks&&entry.isSymbolicLink()&&nSymlinks.add(index4),next===".."&&entryIsDirectory){let parent=join5(path4,"..");nextIndex<last?(!this.subpatterns.has(path4)&&!cache3.seen(path4,pattern,nextIndex+1)&&this.subpatterns.set(path4,[pattern.child(new Set([nextIndex+1]))]),!this.subpatterns.has(parent)&&!cache3.seen(parent,pattern,nextIndex+1)&&this.subpatterns.set(parent,[pattern.child(new Set([nextIndex+1]))])):(cache3.seen(path4,pattern,nextIndex)||(cache3.add(path4,pattern.child(new Set([nextIndex]))),this.accept(path4)&&(yield this.result(path4))),(!cache3.seen(path4,pattern,nextIndex)||!cache3.seen(parent,pattern,nextIndex))&&(cache3.add(parent,pattern.child(new Set([nextIndex]))),this.accept(parent)&&(yield this.result(parent))))}}typeof current=="string"&&(pattern.test(index4,name)&&index4!==last?subPatterns.add(nextIndex):current==="."&&pattern.test(nextIndex,name)&&(nextIndex===last?this.accept(entryPath)&&(yield this.result(entryPath)):subPatterns.add(nextIndex+1))),typeof current=="object"&&pattern.test(index4,name)&&(index4===last?this.accept(entryPath)&&(yield this.result(entryPath)):entryIsDirectory&&subPatterns.add(nextIndex))}subPatterns.size>0&&this.addSubpattern(entryPath,pattern.child(subPatterns,nSymlinks,nextRealpaths))}}},globWalk=(fs2,pattern,options2)=>new Glob(fs2,pattern,options2).walk();exports.globWalk=globWalk;var globSync=(fs2,pattern,options2)=>{let results=[];for(let match of(0,exports.globWalk)(fs2,pattern,options2))results.push(match);return results};exports.globSync=globSync;async function*glob(fs2,pattern,options2){yield*(0,exports.globWalk)(fs2,pattern,options2)}}});var require_setTimeoutUnref=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-utils@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-utils/lib/setTimeoutUnref.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});function setTimeoutUnref(callback,time,args){let ref=setTimeout.apply(typeof globalThis<"u"?globalThis:global,arguments);return ref&&typeof ref=="object"&&typeof ref.unref=="function"&&ref.unref(),ref}exports.default=setTimeoutUnref}});var require_primordials=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/primordials.js"(exports,module){"use strict";init_browser_globals();var AggregateError2=class extends Error{constructor(errors){if(!Array.isArray(errors))throw new TypeError(`Expected input to be an Array, got ${typeof errors}`);let message="";for(let i2=0;i2<errors.length;i2++)message+=` ${errors[i2].stack}
|
|
42
|
-
`;super(message),this.name="AggregateError",this.errors=errors}};module.exports={AggregateError:AggregateError2,ArrayIsArray(self2){return Array.isArray(self2)},ArrayPrototypeIncludes(self2,el){return self2.includes(el)},ArrayPrototypeIndexOf(self2,el){return self2.indexOf(el)},ArrayPrototypeJoin(self2,sep2){return self2.join(sep2)},ArrayPrototypeMap(self2,fn2){return self2.map(fn2)},ArrayPrototypePop(self2,el){return self2.pop(el)},ArrayPrototypePush(self2,el){return self2.push(el)},ArrayPrototypeSlice(self2,start,end){return self2.slice(start,end)},Error,FunctionPrototypeCall(fn2,thisArgs,...args){return fn2.call(thisArgs,...args)},FunctionPrototypeSymbolHasInstance(self2,instance){return Function.prototype[Symbol.hasInstance].call(self2,instance)},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(self2,props){return Object.defineProperties(self2,props)},ObjectDefineProperty(self2,name,prop){return Object.defineProperty(self2,name,prop)},ObjectGetOwnPropertyDescriptor(self2,name){return Object.getOwnPropertyDescriptor(self2,name)},ObjectKeys(obj){return Object.keys(obj)},ObjectSetPrototypeOf(target,proto){return Object.setPrototypeOf(target,proto)},Promise,PromisePrototypeCatch(self2,fn2){return self2.catch(fn2)},PromisePrototypeThen(self2,thenFn,catchFn){return self2.then(thenFn,catchFn)},PromiseReject(err){return Promise.reject(err)},PromiseResolve(val){return Promise.resolve(val)},ReflectApply:Reflect.apply,RegExpPrototypeTest(self2,value2){return self2.test(value2)},SafeSet:Set,String,StringPrototypeSlice(self2,start,end){return self2.slice(start,end)},StringPrototypeToLowerCase(self2){return self2.toLowerCase()},StringPrototypeToUpperCase(self2){return self2.toUpperCase()},StringPrototypeTrim(self2){return self2.trim()},Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet(self2,buf,len){return self2.set(buf,len)},Boolean,Uint8Array}}});var require_inspect2=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/util/inspect.js"(exports,module){"use strict";init_browser_globals();module.exports={format(format5,...args){return format5.replace(/%([sdifj])/g,function(...[_unused,type]){let replacement=args.shift();return type==="f"?replacement.toFixed(6):type==="j"?JSON.stringify(replacement):type==="s"&&typeof replacement=="object"?`${replacement.constructor!==Object?replacement.constructor.name:""} {}`.trim():replacement.toString()})},inspect(value2){switch(typeof value2){case"string":if(value2.includes("'"))if(value2.includes('"')){if(!value2.includes("`")&&!value2.includes("${"))return`\`${value2}\``}else return`"${value2}"`;return`'${value2}'`;case"number":return isNaN(value2)?"NaN":Object.is(value2,-0)?String(value2):value2;case"bigint":return`${String(value2)}n`;case"boolean":case"undefined":return String(value2);case"object":return"{}"}}}}});var require_errors2=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/errors.js"(exports,module){"use strict";init_browser_globals();var{format:format5,inspect}=require_inspect2(),{AggregateError:CustomAggregateError}=require_primordials(),AggregateError2=globalThis.AggregateError||CustomAggregateError,kIsNodeError=Symbol("kIsNodeError"),kTypes=["string","function","number","object","Function","Object","boolean","bigint","symbol"],classRegExp=/^([A-Z][a-z0-9]*)+$/,nodeInternalPrefix="__node_internal_",codes2={};function assert(value2,message){if(!value2)throw new codes2.ERR_INTERNAL_ASSERTION(message)}function addNumericalSeparator(val){let res="",i2=val.length,start=val[0]==="-"?1:0;for(;i2>=start+4;i2-=3)res=`_${val.slice(i2-3,i2)}${res}`;return`${val.slice(0,i2)}${res}`}function getMessage(key,msg,args){if(typeof msg=="function")return assert(msg.length<=args.length,`Code: ${key}; The provided arguments length (${args.length}) does not match the required ones (${msg.length}).`),msg(...args);let expectedLength=(msg.match(/%[dfijoOs]/g)||[]).length;return assert(expectedLength===args.length,`Code: ${key}; The provided arguments length (${args.length}) does not match the required ones (${expectedLength}).`),args.length===0?msg:format5(msg,...args)}function E(code4,message,Base){Base||(Base=Error);class NodeError extends Base{constructor(...args){super(getMessage(code4,message,args))}toString(){return`${this.name} [${code4}]: ${this.message}`}}Object.defineProperties(NodeError.prototype,{name:{value:Base.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${code4}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),NodeError.prototype.code=code4,NodeError.prototype[kIsNodeError]=!0,codes2[code4]=NodeError}function hideStackFrames(fn2){let hidden=nodeInternalPrefix+fn2.name;return Object.defineProperty(fn2,"name",{value:hidden}),fn2}function aggregateTwoErrors(innerError,outerError){if(innerError&&outerError&&innerError!==outerError){if(Array.isArray(outerError.errors))return outerError.errors.push(innerError),outerError;let err=new AggregateError2([outerError,innerError],outerError.message);return err.code=outerError.code,err}return innerError||outerError}var AbortError=class extends Error{constructor(message="The operation was aborted",options2=void 0){if(options2!==void 0&&typeof options2!="object")throw new codes2.ERR_INVALID_ARG_TYPE("options","Object",options2);super(message,options2),this.code="ABORT_ERR",this.name="AbortError"}};E("ERR_ASSERTION","%s",Error);E("ERR_INVALID_ARG_TYPE",(name,expected,actual)=>{assert(typeof name=="string","'name' must be a string"),Array.isArray(expected)||(expected=[expected]);let msg="The ";name.endsWith(" argument")?msg+=`${name} `:msg+=`"${name}" ${name.includes(".")?"property":"argument"} `,msg+="must be ";let types2=[],instances=[],other=[];for(let value2 of expected)assert(typeof value2=="string","All expected entries have to be of type string"),kTypes.includes(value2)?types2.push(value2.toLowerCase()):classRegExp.test(value2)?instances.push(value2):(assert(value2!=="object",'The value "object" should be written as "Object"'),other.push(value2));if(instances.length>0){let pos=types2.indexOf("object");pos!==-1&&(types2.splice(types2,pos,1),instances.push("Object"))}if(types2.length>0){switch(types2.length){case 1:msg+=`of type ${types2[0]}`;break;case 2:msg+=`one of type ${types2[0]} or ${types2[1]}`;break;default:{let last=types2.pop();msg+=`one of type ${types2.join(", ")}, or ${last}`}}(instances.length>0||other.length>0)&&(msg+=" or ")}if(instances.length>0){switch(instances.length){case 1:msg+=`an instance of ${instances[0]}`;break;case 2:msg+=`an instance of ${instances[0]} or ${instances[1]}`;break;default:{let last=instances.pop();msg+=`an instance of ${instances.join(", ")}, or ${last}`}}other.length>0&&(msg+=" or ")}switch(other.length){case 0:break;case 1:other[0].toLowerCase()!==other[0]&&(msg+="an "),msg+=`${other[0]}`;break;case 2:msg+=`one of ${other[0]} or ${other[1]}`;break;default:{let last=other.pop();msg+=`one of ${other.join(", ")}, or ${last}`}}if(actual==null)msg+=`. Received ${actual}`;else if(typeof actual=="function"&&actual.name)msg+=`. Received function ${actual.name}`;else if(typeof actual=="object"){var _actual$constructor;if((_actual$constructor=actual.constructor)!==null&&_actual$constructor!==void 0&&_actual$constructor.name)msg+=`. Received an instance of ${actual.constructor.name}`;else{let inspected=inspect(actual,{depth:-1});msg+=`. Received ${inspected}`}}else{let inspected=inspect(actual,{colors:!1});inspected.length>25&&(inspected=`${inspected.slice(0,25)}...`),msg+=`. Received type ${typeof actual} (${inspected})`}return msg},TypeError);E("ERR_INVALID_ARG_VALUE",(name,value2,reason="is invalid")=>{let inspected=inspect(value2);return inspected.length>128&&(inspected=inspected.slice(0,128)+"..."),`The ${name.includes(".")?"property":"argument"} '${name}' ${reason}. Received ${inspected}`},TypeError);E("ERR_INVALID_RETURN_VALUE",(input,name,value2)=>{var _value$constructor;let type=value2!=null&&(_value$constructor=value2.constructor)!==null&&_value$constructor!==void 0&&_value$constructor.name?`instance of ${value2.constructor.name}`:`type ${typeof value2}`;return`Expected ${input} to be returned from the "${name}" function but got ${type}.`},TypeError);E("ERR_MISSING_ARGS",(...args)=>{assert(args.length>0,"At least one arg needs to be specified");let msg,len=args.length;switch(args=(Array.isArray(args)?args:[args]).map(a2=>`"${a2}"`).join(" or "),len){case 1:msg+=`The ${args[0]} argument`;break;case 2:msg+=`The ${args[0]} and ${args[1]} arguments`;break;default:{let last=args.pop();msg+=`The ${args.join(", ")}, and ${last} arguments`}break}return`${msg} must be specified`},TypeError);E("ERR_OUT_OF_RANGE",(str,range,input)=>{assert(range,'Missing "range" argument');let received;if(Number.isInteger(input)&&Math.abs(input)>2**32)received=addNumericalSeparator(String(input));else if(typeof input=="bigint"){received=String(input);let limit=BigInt(2)**BigInt(32);(input>limit||input<-limit)&&(received=addNumericalSeparator(received)),received+="n"}else received=inspect(input);return`The value of "${str}" is out of range. It must be ${range}. Received ${received}`},RangeError);E("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error);E("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error);E("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error);E("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error);E("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error);E("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);E("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error);E("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error);E("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error);E("ERR_STREAM_WRITE_AFTER_END","write after end",Error);E("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError);module.exports={AbortError,aggregateTwoErrors:hideStackFrames(aggregateTwoErrors),hideStackFrames,codes:codes2}}});var require_browser2=__commonJS({"node_modules/.pnpm/abort-controller@3.0.0/node_modules/abort-controller/browser.js"(exports,module){"use strict";init_browser_globals();var{AbortController:AbortController2,AbortSignal:AbortSignal2}=typeof self<"u"?self:typeof window<"u"?window:void 0;module.exports=AbortController2;module.exports.AbortSignal=AbortSignal2;module.exports.default=AbortController2}});var require_events=__commonJS({"node_modules/.pnpm/events@3.3.0/node_modules/events/events.js"(exports,module){"use strict";init_browser_globals();var R=typeof Reflect=="object"?Reflect:null,ReflectApply=R&&typeof R.apply=="function"?R.apply:function(target,receiver,args){return Function.prototype.apply.call(target,receiver,args)},ReflectOwnKeys;R&&typeof R.ownKeys=="function"?ReflectOwnKeys=R.ownKeys:Object.getOwnPropertySymbols?ReflectOwnKeys=function(target){return Object.getOwnPropertyNames(target).concat(Object.getOwnPropertySymbols(target))}:ReflectOwnKeys=function(target){return Object.getOwnPropertyNames(target)};function ProcessEmitWarning(warning){console&&console.warn&&console.warn(warning)}var NumberIsNaN=Number.isNaN||function(value2){return value2!==value2};function EventEmitter(){EventEmitter.init.call(this)}module.exports=EventEmitter;module.exports.once=once;EventEmitter.EventEmitter=EventEmitter;EventEmitter.prototype._events=void 0;EventEmitter.prototype._eventsCount=0;EventEmitter.prototype._maxListeners=void 0;var defaultMaxListeners=10;function checkListener(listener){if(typeof listener!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof listener)}Object.defineProperty(EventEmitter,"defaultMaxListeners",{enumerable:!0,get:function(){return defaultMaxListeners},set:function(arg){if(typeof arg!="number"||arg<0||NumberIsNaN(arg))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+arg+".");defaultMaxListeners=arg}});EventEmitter.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0};EventEmitter.prototype.setMaxListeners=function(n2){if(typeof n2!="number"||n2<0||NumberIsNaN(n2))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+n2+".");return this._maxListeners=n2,this};function _getMaxListeners(that){return that._maxListeners===void 0?EventEmitter.defaultMaxListeners:that._maxListeners}EventEmitter.prototype.getMaxListeners=function(){return _getMaxListeners(this)};EventEmitter.prototype.emit=function(type){for(var args=[],i2=1;i2<arguments.length;i2++)args.push(arguments[i2]);var doError=type==="error",events=this._events;if(events!==void 0)doError=doError&&events.error===void 0;else if(!doError)return!1;if(doError){var er2;if(args.length>0&&(er2=args[0]),er2 instanceof Error)throw er2;var err=new Error("Unhandled error."+(er2?" ("+er2.message+")":""));throw err.context=er2,err}var handler2=events[type];if(handler2===void 0)return!1;if(typeof handler2=="function")ReflectApply(handler2,this,args);else for(var len=handler2.length,listeners=arrayClone(handler2,len),i2=0;i2<len;++i2)ReflectApply(listeners[i2],this,args);return!0};function _addListener(target,type,listener,prepend){var m2,events,existing;if(checkListener(listener),events=target._events,events===void 0?(events=target._events=Object.create(null),target._eventsCount=0):(events.newListener!==void 0&&(target.emit("newListener",type,listener.listener?listener.listener:listener),events=target._events),existing=events[type]),existing===void 0)existing=events[type]=listener,++target._eventsCount;else if(typeof existing=="function"?existing=events[type]=prepend?[listener,existing]:[existing,listener]:prepend?existing.unshift(listener):existing.push(listener),m2=_getMaxListeners(target),m2>0&&existing.length>m2&&!existing.warned){existing.warned=!0;var w2=new Error("Possible EventEmitter memory leak detected. "+existing.length+" "+String(type)+" listeners added. Use emitter.setMaxListeners() to increase limit");w2.name="MaxListenersExceededWarning",w2.emitter=target,w2.type=type,w2.count=existing.length,ProcessEmitWarning(w2)}return target}EventEmitter.prototype.addListener=function(type,listener){return _addListener(this,type,listener,!1)};EventEmitter.prototype.on=EventEmitter.prototype.addListener;EventEmitter.prototype.prependListener=function(type,listener){return _addListener(this,type,listener,!0)};function onceWrapper(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function _onceWrap(target,type,listener){var state={fired:!1,wrapFn:void 0,target,type,listener},wrapped=onceWrapper.bind(state);return wrapped.listener=listener,state.wrapFn=wrapped,wrapped}EventEmitter.prototype.once=function(type,listener){return checkListener(listener),this.on(type,_onceWrap(this,type,listener)),this};EventEmitter.prototype.prependOnceListener=function(type,listener){return checkListener(listener),this.prependListener(type,_onceWrap(this,type,listener)),this};EventEmitter.prototype.removeListener=function(type,listener){var list5,events,position2,i2,originalListener;if(checkListener(listener),events=this._events,events===void 0)return this;if(list5=events[type],list5===void 0)return this;if(list5===listener||list5.listener===listener)--this._eventsCount===0?this._events=Object.create(null):(delete events[type],events.removeListener&&this.emit("removeListener",type,list5.listener||listener));else if(typeof list5!="function"){for(position2=-1,i2=list5.length-1;i2>=0;i2--)if(list5[i2]===listener||list5[i2].listener===listener){originalListener=list5[i2].listener,position2=i2;break}if(position2<0)return this;position2===0?list5.shift():spliceOne(list5,position2),list5.length===1&&(events[type]=list5[0]),events.removeListener!==void 0&&this.emit("removeListener",type,originalListener||listener)}return this};EventEmitter.prototype.off=EventEmitter.prototype.removeListener;EventEmitter.prototype.removeAllListeners=function(type){var listeners,events,i2;if(events=this._events,events===void 0)return this;if(events.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):events[type]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete events[type]),this;if(arguments.length===0){var keys=Object.keys(events),key;for(i2=0;i2<keys.length;++i2)key=keys[i2],key!=="removeListener"&&this.removeAllListeners(key);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(listeners=events[type],typeof listeners=="function")this.removeListener(type,listeners);else if(listeners!==void 0)for(i2=listeners.length-1;i2>=0;i2--)this.removeListener(type,listeners[i2]);return this};function _listeners(target,type,unwrap){var events=target._events;if(events===void 0)return[];var evlistener=events[type];return evlistener===void 0?[]:typeof evlistener=="function"?unwrap?[evlistener.listener||evlistener]:[evlistener]:unwrap?unwrapListeners(evlistener):arrayClone(evlistener,evlistener.length)}EventEmitter.prototype.listeners=function(type){return _listeners(this,type,!0)};EventEmitter.prototype.rawListeners=function(type){return _listeners(this,type,!1)};EventEmitter.listenerCount=function(emitter,type){return typeof emitter.listenerCount=="function"?emitter.listenerCount(type):listenerCount.call(emitter,type)};EventEmitter.prototype.listenerCount=listenerCount;function listenerCount(type){var events=this._events;if(events!==void 0){var evlistener=events[type];if(typeof evlistener=="function")return 1;if(evlistener!==void 0)return evlistener.length}return 0}EventEmitter.prototype.eventNames=function(){return this._eventsCount>0?ReflectOwnKeys(this._events):[]};function arrayClone(arr,n2){for(var copy=new Array(n2),i2=0;i2<n2;++i2)copy[i2]=arr[i2];return copy}function spliceOne(list5,index4){for(;index4+1<list5.length;index4++)list5[index4]=list5[index4+1];list5.pop()}function unwrapListeners(arr){for(var ret=new Array(arr.length),i2=0;i2<ret.length;++i2)ret[i2]=arr[i2].listener||arr[i2];return ret}function once(emitter,name){return new Promise(function(resolve2,reject){function errorListener(err){emitter.removeListener(name,resolver2),reject(err)}function resolver2(){typeof emitter.removeListener=="function"&&emitter.removeListener("error",errorListener),resolve2([].slice.call(arguments))}eventTargetAgnosticAddListener(emitter,name,resolver2,{once:!0}),name!=="error"&&addErrorHandlerIfEventEmitter(emitter,errorListener,{once:!0})})}function addErrorHandlerIfEventEmitter(emitter,handler2,flags){typeof emitter.on=="function"&&eventTargetAgnosticAddListener(emitter,"error",handler2,flags)}function eventTargetAgnosticAddListener(emitter,name,listener,flags){if(typeof emitter.on=="function")flags.once?emitter.once(name,listener):emitter.on(name,listener);else if(typeof emitter.addEventListener=="function")emitter.addEventListener(name,function wrapListener(arg){flags.once&&emitter.removeEventListener(name,wrapListener),listener(arg)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof emitter)}}});var require_util3=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/util.js"(exports,module){"use strict";init_browser_globals();var bufferModule=require_buffer(),{format:format5,inspect}=require_inspect2(),{codes:{ERR_INVALID_ARG_TYPE}}=require_errors2(),{kResistStopPropagation,AggregateError:AggregateError2,SymbolDispose}=require_primordials(),AbortSignal2=globalThis.AbortSignal||require_browser2().AbortSignal,AbortController2=globalThis.AbortController||require_browser2().AbortController,AsyncFunction=Object.getPrototypeOf(async function(){}).constructor,Blob2=globalThis.Blob||bufferModule.Blob,isBlob=typeof Blob2<"u"?function(b2){return b2 instanceof Blob2}:function(b2){return!1},validateAbortSignal=(signal,name)=>{if(signal!==void 0&&(signal===null||typeof signal!="object"||!("aborted"in signal)))throw new ERR_INVALID_ARG_TYPE(name,"AbortSignal",signal)},validateFunction=(value2,name)=>{if(typeof value2!="function")throw new ERR_INVALID_ARG_TYPE(name,"Function",value2)};module.exports={AggregateError:AggregateError2,kEmptyObject:Object.freeze({}),once(callback){let called=!1;return function(...args){called||(called=!0,callback.apply(this,args))}},createDeferredPromise:function(){let resolve2,reject;return{promise:new Promise((res,rej)=>{resolve2=res,reject=rej}),resolve:resolve2,reject}},promisify(fn2){return new Promise((resolve2,reject)=>{fn2((err,...args)=>err?reject(err):resolve2(...args))})},debuglog(){return function(){}},format:format5,inspect,types:{isAsyncFunction(fn2){return fn2 instanceof AsyncFunction},isArrayBufferView(arr){return ArrayBuffer.isView(arr)}},isBlob,deprecate(fn2,message){return fn2},addAbortListener:require_events().addAbortListener||function(signal,listener){if(signal===void 0)throw new ERR_INVALID_ARG_TYPE("signal","AbortSignal",signal);validateAbortSignal(signal,"signal"),validateFunction(listener,"listener");let removeEventListener;return signal.aborted?queueMicrotask(()=>listener()):(signal.addEventListener("abort",listener,{__proto__:null,once:!0,[kResistStopPropagation]:!0}),removeEventListener=()=>{signal.removeEventListener("abort",listener)}),{__proto__:null,[SymbolDispose](){var _removeEventListener;(_removeEventListener=removeEventListener)===null||_removeEventListener===void 0||_removeEventListener()}}},AbortSignalAny:AbortSignal2.any||function(signals){if(signals.length===1)return signals[0];let ac=new AbortController2,abort=()=>ac.abort();return signals.forEach(signal=>{validateAbortSignal(signal,"signals"),signal.addEventListener("abort",abort,{once:!0})}),ac.signal.addEventListener("abort",()=>{signals.forEach(signal=>signal.removeEventListener("abort",abort))},{once:!0}),ac.signal}};module.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}});var require_validators2=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/validators.js"(exports,module){"use strict";init_browser_globals();var{ArrayIsArray,ArrayPrototypeIncludes,ArrayPrototypeJoin,ArrayPrototypeMap,NumberIsInteger,NumberIsNaN,NumberMAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER,NumberParseInt,ObjectPrototypeHasOwnProperty,RegExpPrototypeExec,String:String2,StringPrototypeToUpperCase,StringPrototypeTrim}=require_primordials(),{hideStackFrames,codes:{ERR_SOCKET_BAD_PORT,ERR_INVALID_ARG_TYPE,ERR_INVALID_ARG_VALUE,ERR_OUT_OF_RANGE,ERR_UNKNOWN_SIGNAL}}=require_errors2(),{normalizeEncoding}=require_util3(),{isAsyncFunction,isArrayBufferView}=require_util3().types,signals={};function isInt32(value2){return value2===(value2|0)}function isUint32(value2){return value2===value2>>>0}var octalReg=/^[0-7]+$/,modeDesc="must be a 32-bit unsigned integer or an octal string";function parseFileMode(value2,name,def){if(typeof value2>"u"&&(value2=def),typeof value2=="string"){if(RegExpPrototypeExec(octalReg,value2)===null)throw new ERR_INVALID_ARG_VALUE(name,value2,modeDesc);value2=NumberParseInt(value2,8)}return validateUint32(value2,name),value2}var validateInteger=hideStackFrames((value2,name,min=NumberMIN_SAFE_INTEGER,max=NumberMAX_SAFE_INTEGER)=>{if(typeof value2!="number")throw new ERR_INVALID_ARG_TYPE(name,"number",value2);if(!NumberIsInteger(value2))throw new ERR_OUT_OF_RANGE(name,"an integer",value2);if(value2<min||value2>max)throw new ERR_OUT_OF_RANGE(name,`>= ${min} && <= ${max}`,value2)}),validateInt32=hideStackFrames((value2,name,min=-2147483648,max=2147483647)=>{if(typeof value2!="number")throw new ERR_INVALID_ARG_TYPE(name,"number",value2);if(!NumberIsInteger(value2))throw new ERR_OUT_OF_RANGE(name,"an integer",value2);if(value2<min||value2>max)throw new ERR_OUT_OF_RANGE(name,`>= ${min} && <= ${max}`,value2)}),validateUint32=hideStackFrames((value2,name,positive=!1)=>{if(typeof value2!="number")throw new ERR_INVALID_ARG_TYPE(name,"number",value2);if(!NumberIsInteger(value2))throw new ERR_OUT_OF_RANGE(name,"an integer",value2);let min=positive?1:0,max=4294967295;if(value2<min||value2>max)throw new ERR_OUT_OF_RANGE(name,`>= ${min} && <= ${max}`,value2)});function validateString(value2,name){if(typeof value2!="string")throw new ERR_INVALID_ARG_TYPE(name,"string",value2)}function validateNumber(value2,name,min=void 0,max){if(typeof value2!="number")throw new ERR_INVALID_ARG_TYPE(name,"number",value2);if(min!=null&&value2<min||max!=null&&value2>max||(min!=null||max!=null)&&NumberIsNaN(value2))throw new ERR_OUT_OF_RANGE(name,`${min!=null?`>= ${min}`:""}${min!=null&&max!=null?" && ":""}${max!=null?`<= ${max}`:""}`,value2)}var validateOneOf=hideStackFrames((value2,name,oneOf)=>{if(!ArrayPrototypeIncludes(oneOf,value2)){let reason="must be one of: "+ArrayPrototypeJoin(ArrayPrototypeMap(oneOf,v2=>typeof v2=="string"?`'${v2}'`:String2(v2)),", ");throw new ERR_INVALID_ARG_VALUE(name,value2,reason)}});function validateBoolean(value2,name){if(typeof value2!="boolean")throw new ERR_INVALID_ARG_TYPE(name,"boolean",value2)}function getOwnPropertyValueOrDefault(options2,key,defaultValue){return options2==null||!ObjectPrototypeHasOwnProperty(options2,key)?defaultValue:options2[key]}var validateObject=hideStackFrames((value2,name,options2=null)=>{let allowArray=getOwnPropertyValueOrDefault(options2,"allowArray",!1),allowFunction=getOwnPropertyValueOrDefault(options2,"allowFunction",!1);if(!getOwnPropertyValueOrDefault(options2,"nullable",!1)&&value2===null||!allowArray&&ArrayIsArray(value2)||typeof value2!="object"&&(!allowFunction||typeof value2!="function"))throw new ERR_INVALID_ARG_TYPE(name,"Object",value2)}),validateDictionary=hideStackFrames((value2,name)=>{if(value2!=null&&typeof value2!="object"&&typeof value2!="function")throw new ERR_INVALID_ARG_TYPE(name,"a dictionary",value2)}),validateArray=hideStackFrames((value2,name,minLength=0)=>{if(!ArrayIsArray(value2))throw new ERR_INVALID_ARG_TYPE(name,"Array",value2);if(value2.length<minLength){let reason=`must be longer than ${minLength}`;throw new ERR_INVALID_ARG_VALUE(name,value2,reason)}});function validateStringArray(value2,name){validateArray(value2,name);for(let i2=0;i2<value2.length;i2++)validateString(value2[i2],`${name}[${i2}]`)}function validateBooleanArray(value2,name){validateArray(value2,name);for(let i2=0;i2<value2.length;i2++)validateBoolean(value2[i2],`${name}[${i2}]`)}function validateAbortSignalArray(value2,name){validateArray(value2,name);for(let i2=0;i2<value2.length;i2++){let signal=value2[i2],indexedName=`${name}[${i2}]`;if(signal==null)throw new ERR_INVALID_ARG_TYPE(indexedName,"AbortSignal",signal);validateAbortSignal(signal,indexedName)}}function validateSignalName(signal,name="signal"){if(validateString(signal,name),signals[signal]===void 0)throw signals[StringPrototypeToUpperCase(signal)]!==void 0?new ERR_UNKNOWN_SIGNAL(signal+" (signals must use all capital letters)"):new ERR_UNKNOWN_SIGNAL(signal)}var validateBuffer=hideStackFrames((buffer,name="buffer")=>{if(!isArrayBufferView(buffer))throw new ERR_INVALID_ARG_TYPE(name,["Buffer","TypedArray","DataView"],buffer)});function validateEncoding(data,encoding){let normalizedEncoding=normalizeEncoding(encoding),length=data.length;if(normalizedEncoding==="hex"&&length%2!==0)throw new ERR_INVALID_ARG_VALUE("encoding",encoding,`is invalid for data of length ${length}`)}function validatePort(port,name="Port",allowZero=!0){if(typeof port!="number"&&typeof port!="string"||typeof port=="string"&&StringPrototypeTrim(port).length===0||+port!==+port>>>0||port>65535||port===0&&!allowZero)throw new ERR_SOCKET_BAD_PORT(name,port,allowZero);return port|0}var validateAbortSignal=hideStackFrames((signal,name)=>{if(signal!==void 0&&(signal===null||typeof signal!="object"||!("aborted"in signal)))throw new ERR_INVALID_ARG_TYPE(name,"AbortSignal",signal)}),validateFunction=hideStackFrames((value2,name)=>{if(typeof value2!="function")throw new ERR_INVALID_ARG_TYPE(name,"Function",value2)}),validatePlainFunction=hideStackFrames((value2,name)=>{if(typeof value2!="function"||isAsyncFunction(value2))throw new ERR_INVALID_ARG_TYPE(name,"Function",value2)}),validateUndefined=hideStackFrames((value2,name)=>{if(value2!==void 0)throw new ERR_INVALID_ARG_TYPE(name,"undefined",value2)});function validateUnion(value2,name,union){if(!ArrayPrototypeIncludes(union,value2))throw new ERR_INVALID_ARG_TYPE(name,`('${ArrayPrototypeJoin(union,"|")}')`,value2)}var linkValueRegExp=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function validateLinkHeaderFormat(value2,name){if(typeof value2>"u"||!RegExpPrototypeExec(linkValueRegExp,value2))throw new ERR_INVALID_ARG_VALUE(name,value2,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}function validateLinkHeaderValue(hints){if(typeof hints=="string")return validateLinkHeaderFormat(hints,"hints"),hints;if(ArrayIsArray(hints)){let hintsLength=hints.length,result="";if(hintsLength===0)return result;for(let i2=0;i2<hintsLength;i2++){let link2=hints[i2];validateLinkHeaderFormat(link2,"hints"),result+=link2,i2!==hintsLength-1&&(result+=", ")}return result}throw new ERR_INVALID_ARG_VALUE("hints",hints,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}module.exports={isInt32,isUint32,parseFileMode,validateArray,validateStringArray,validateBooleanArray,validateAbortSignalArray,validateBoolean,validateBuffer,validateDictionary,validateEncoding,validateFunction,validateInt32,validateInteger,validateNumber,validateObject,validateOneOf,validatePlainFunction,validatePort,validateSignalName,validateString,validateUint32,validateUndefined,validateUnion,validateAbortSignal,validateLinkHeaderValue}}});var require_process2=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/shims/process.js"(exports,module){"use strict";init_browser_globals();var process2=((base2,esmKey,keys,isValid)=>{if(esmKey in base2&&base2[esmKey]===!0){let candidate;for(let key of keys)if(key in base2&&(candidate=base2[key],isValid(candidate)))return candidate}return base2})(require_browser(),"__esModule",["default","process"],candidate=>"nextTick"in candidate);module.exports=process2}});var require_utils=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/utils.js"(exports,module){"use strict";init_browser_globals();var{SymbolAsyncIterator,SymbolIterator,SymbolFor}=require_primordials(),kIsDestroyed=SymbolFor("nodejs.stream.destroyed"),kIsErrored=SymbolFor("nodejs.stream.errored"),kIsReadable=SymbolFor("nodejs.stream.readable"),kIsWritable=SymbolFor("nodejs.stream.writable"),kIsDisturbed=SymbolFor("nodejs.stream.disturbed"),kIsClosedPromise=SymbolFor("nodejs.webstream.isClosedPromise"),kControllerErrorFunction=SymbolFor("nodejs.webstream.controllerErrorFunction");function isReadableNodeStream(obj,strict=!1){var _obj$_readableState;return!!(obj&&typeof obj.pipe=="function"&&typeof obj.on=="function"&&(!strict||typeof obj.pause=="function"&&typeof obj.resume=="function")&&(!obj._writableState||((_obj$_readableState=obj._readableState)===null||_obj$_readableState===void 0?void 0:_obj$_readableState.readable)!==!1)&&(!obj._writableState||obj._readableState))}function isWritableNodeStream(obj){var _obj$_writableState;return!!(obj&&typeof obj.write=="function"&&typeof obj.on=="function"&&(!obj._readableState||((_obj$_writableState=obj._writableState)===null||_obj$_writableState===void 0?void 0:_obj$_writableState.writable)!==!1))}function isDuplexNodeStream(obj){return!!(obj&&typeof obj.pipe=="function"&&obj._readableState&&typeof obj.on=="function"&&typeof obj.write=="function")}function isNodeStream(obj){return obj&&(obj._readableState||obj._writableState||typeof obj.write=="function"&&typeof obj.on=="function"||typeof obj.pipe=="function"&&typeof obj.on=="function")}function isReadableStream(obj){return!!(obj&&!isNodeStream(obj)&&typeof obj.pipeThrough=="function"&&typeof obj.getReader=="function"&&typeof obj.cancel=="function")}function isWritableStream(obj){return!!(obj&&!isNodeStream(obj)&&typeof obj.getWriter=="function"&&typeof obj.abort=="function")}function isTransformStream(obj){return!!(obj&&!isNodeStream(obj)&&typeof obj.readable=="object"&&typeof obj.writable=="object")}function isWebStream(obj){return isReadableStream(obj)||isWritableStream(obj)||isTransformStream(obj)}function isIterable(obj,isAsync){return obj==null?!1:isAsync===!0?typeof obj[SymbolAsyncIterator]=="function":isAsync===!1?typeof obj[SymbolIterator]=="function":typeof obj[SymbolAsyncIterator]=="function"||typeof obj[SymbolIterator]=="function"}function isDestroyed(stream){if(!isNodeStream(stream))return null;let wState=stream._writableState,rState=stream._readableState,state=wState||rState;return!!(stream.destroyed||stream[kIsDestroyed]||state!=null&&state.destroyed)}function isWritableEnded(stream){if(!isWritableNodeStream(stream))return null;if(stream.writableEnded===!0)return!0;let wState=stream._writableState;return wState!=null&&wState.errored?!1:typeof wState?.ended!="boolean"?null:wState.ended}function isWritableFinished(stream,strict){if(!isWritableNodeStream(stream))return null;if(stream.writableFinished===!0)return!0;let wState=stream._writableState;return wState!=null&&wState.errored?!1:typeof wState?.finished!="boolean"?null:!!(wState.finished||strict===!1&&wState.ended===!0&&wState.length===0)}function isReadableEnded(stream){if(!isReadableNodeStream(stream))return null;if(stream.readableEnded===!0)return!0;let rState=stream._readableState;return!rState||rState.errored?!1:typeof rState?.ended!="boolean"?null:rState.ended}function isReadableFinished(stream,strict){if(!isReadableNodeStream(stream))return null;let rState=stream._readableState;return rState!=null&&rState.errored?!1:typeof rState?.endEmitted!="boolean"?null:!!(rState.endEmitted||strict===!1&&rState.ended===!0&&rState.length===0)}function isReadable(stream){return stream&&stream[kIsReadable]!=null?stream[kIsReadable]:typeof stream?.readable!="boolean"?null:isDestroyed(stream)?!1:isReadableNodeStream(stream)&&stream.readable&&!isReadableFinished(stream)}function isWritable(stream){return stream&&stream[kIsWritable]!=null?stream[kIsWritable]:typeof stream?.writable!="boolean"?null:isDestroyed(stream)?!1:isWritableNodeStream(stream)&&stream.writable&&!isWritableEnded(stream)}function isFinished(stream,opts){return isNodeStream(stream)?isDestroyed(stream)?!0:!(opts?.readable!==!1&&isReadable(stream)||opts?.writable!==!1&&isWritable(stream)):null}function isWritableErrored(stream){var _stream$_writableStat,_stream$_writableStat2;return isNodeStream(stream)?stream.writableErrored?stream.writableErrored:(_stream$_writableStat=(_stream$_writableStat2=stream._writableState)===null||_stream$_writableStat2===void 0?void 0:_stream$_writableStat2.errored)!==null&&_stream$_writableStat!==void 0?_stream$_writableStat:null:null}function isReadableErrored(stream){var _stream$_readableStat,_stream$_readableStat2;return isNodeStream(stream)?stream.readableErrored?stream.readableErrored:(_stream$_readableStat=(_stream$_readableStat2=stream._readableState)===null||_stream$_readableStat2===void 0?void 0:_stream$_readableStat2.errored)!==null&&_stream$_readableStat!==void 0?_stream$_readableStat:null:null}function isClosed(stream){if(!isNodeStream(stream))return null;if(typeof stream.closed=="boolean")return stream.closed;let wState=stream._writableState,rState=stream._readableState;return typeof wState?.closed=="boolean"||typeof rState?.closed=="boolean"?wState?.closed||rState?.closed:typeof stream._closed=="boolean"&&isOutgoingMessage(stream)?stream._closed:null}function isOutgoingMessage(stream){return typeof stream._closed=="boolean"&&typeof stream._defaultKeepAlive=="boolean"&&typeof stream._removedConnection=="boolean"&&typeof stream._removedContLen=="boolean"}function isServerResponse(stream){return typeof stream._sent100=="boolean"&&isOutgoingMessage(stream)}function isServerRequest(stream){var _stream$req;return typeof stream._consuming=="boolean"&&typeof stream._dumped=="boolean"&&((_stream$req=stream.req)===null||_stream$req===void 0?void 0:_stream$req.upgradeOrConnect)===void 0}function willEmitClose(stream){if(!isNodeStream(stream))return null;let wState=stream._writableState,rState=stream._readableState,state=wState||rState;return!state&&isServerResponse(stream)||!!(state&&state.autoDestroy&&state.emitClose&&state.closed===!1)}function isDisturbed(stream){var _stream$kIsDisturbed;return!!(stream&&((_stream$kIsDisturbed=stream[kIsDisturbed])!==null&&_stream$kIsDisturbed!==void 0?_stream$kIsDisturbed:stream.readableDidRead||stream.readableAborted))}function isErrored(stream){var _ref,_ref2,_ref3,_ref4,_ref5,_stream$kIsErrored,_stream$_readableStat3,_stream$_writableStat3,_stream$_readableStat4,_stream$_writableStat4;return!!(stream&&((_ref=(_ref2=(_ref3=(_ref4=(_ref5=(_stream$kIsErrored=stream[kIsErrored])!==null&&_stream$kIsErrored!==void 0?_stream$kIsErrored:stream.readableErrored)!==null&&_ref5!==void 0?_ref5:stream.writableErrored)!==null&&_ref4!==void 0?_ref4:(_stream$_readableStat3=stream._readableState)===null||_stream$_readableStat3===void 0?void 0:_stream$_readableStat3.errorEmitted)!==null&&_ref3!==void 0?_ref3:(_stream$_writableStat3=stream._writableState)===null||_stream$_writableStat3===void 0?void 0:_stream$_writableStat3.errorEmitted)!==null&&_ref2!==void 0?_ref2:(_stream$_readableStat4=stream._readableState)===null||_stream$_readableStat4===void 0?void 0:_stream$_readableStat4.errored)!==null&&_ref!==void 0?_ref:!((_stream$_writableStat4=stream._writableState)===null||_stream$_writableStat4===void 0)&&_stream$_writableStat4.errored))}module.exports={isDestroyed,kIsDestroyed,isDisturbed,kIsDisturbed,isErrored,kIsErrored,isReadable,kIsReadable,kIsClosedPromise,kControllerErrorFunction,kIsWritable,isClosed,isDuplexNodeStream,isFinished,isIterable,isReadableNodeStream,isReadableStream,isReadableEnded,isReadableFinished,isReadableErrored,isNodeStream,isWebStream,isWritable,isWritableNodeStream,isWritableStream,isWritableEnded,isWritableFinished,isWritableErrored,isServerRequest,isServerResponse,willEmitClose,isTransformStream}}});var require_end_of_stream=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/end-of-stream.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{AbortError,codes:codes2}=require_errors2(),{ERR_INVALID_ARG_TYPE,ERR_STREAM_PREMATURE_CLOSE}=codes2,{kEmptyObject,once}=require_util3(),{validateAbortSignal,validateFunction,validateObject,validateBoolean}=require_validators2(),{Promise:Promise2,PromisePrototypeThen,SymbolDispose}=require_primordials(),{isClosed,isReadable,isReadableNodeStream,isReadableStream,isReadableFinished,isReadableErrored,isWritable,isWritableNodeStream,isWritableStream,isWritableFinished,isWritableErrored,isNodeStream,willEmitClose:_willEmitClose,kIsClosedPromise}=require_utils(),addAbortListener;function isRequest(stream){return stream.setHeader&&typeof stream.abort=="function"}var nop=()=>{};function eos(stream,options2,callback){var _options$readable,_options$writable;if(arguments.length===2?(callback=options2,options2=kEmptyObject):options2==null?options2=kEmptyObject:validateObject(options2,"options"),validateFunction(callback,"callback"),validateAbortSignal(options2.signal,"options.signal"),callback=once(callback),isReadableStream(stream)||isWritableStream(stream))return eosWeb(stream,options2,callback);if(!isNodeStream(stream))throw new ERR_INVALID_ARG_TYPE("stream",["ReadableStream","WritableStream","Stream"],stream);let readable=(_options$readable=options2.readable)!==null&&_options$readable!==void 0?_options$readable:isReadableNodeStream(stream),writable=(_options$writable=options2.writable)!==null&&_options$writable!==void 0?_options$writable:isWritableNodeStream(stream),wState=stream._writableState,rState=stream._readableState,onlegacyfinish=()=>{stream.writable||onfinish()},willEmitClose=_willEmitClose(stream)&&isReadableNodeStream(stream)===readable&&isWritableNodeStream(stream)===writable,writableFinished=isWritableFinished(stream,!1),onfinish=()=>{writableFinished=!0,stream.destroyed&&(willEmitClose=!1),!(willEmitClose&&(!stream.readable||readable))&&(!readable||readableFinished)&&callback.call(stream)},readableFinished=isReadableFinished(stream,!1),onend=()=>{readableFinished=!0,stream.destroyed&&(willEmitClose=!1),!(willEmitClose&&(!stream.writable||writable))&&(!writable||writableFinished)&&callback.call(stream)},onerror=err=>{callback.call(stream,err)},closed=isClosed(stream),onclose=()=>{closed=!0;let errored=isWritableErrored(stream)||isReadableErrored(stream);if(errored&&typeof errored!="boolean")return callback.call(stream,errored);if(readable&&!readableFinished&&isReadableNodeStream(stream,!0)&&!isReadableFinished(stream,!1))return callback.call(stream,new ERR_STREAM_PREMATURE_CLOSE);if(writable&&!writableFinished&&!isWritableFinished(stream,!1))return callback.call(stream,new ERR_STREAM_PREMATURE_CLOSE);callback.call(stream)},onclosed=()=>{closed=!0;let errored=isWritableErrored(stream)||isReadableErrored(stream);if(errored&&typeof errored!="boolean")return callback.call(stream,errored);callback.call(stream)},onrequest=()=>{stream.req.on("finish",onfinish)};isRequest(stream)?(stream.on("complete",onfinish),willEmitClose||stream.on("abort",onclose),stream.req?onrequest():stream.on("request",onrequest)):writable&&!wState&&(stream.on("end",onlegacyfinish),stream.on("close",onlegacyfinish)),!willEmitClose&&typeof stream.aborted=="boolean"&&stream.on("aborted",onclose),stream.on("end",onend),stream.on("finish",onfinish),options2.error!==!1&&stream.on("error",onerror),stream.on("close",onclose),closed?process2.nextTick(onclose):wState!=null&&wState.errorEmitted||rState!=null&&rState.errorEmitted?willEmitClose||process2.nextTick(onclosed):(!readable&&(!willEmitClose||isReadable(stream))&&(writableFinished||isWritable(stream)===!1)||!writable&&(!willEmitClose||isWritable(stream))&&(readableFinished||isReadable(stream)===!1)||rState&&stream.req&&stream.aborted)&&process2.nextTick(onclosed);let cleanup=()=>{callback=nop,stream.removeListener("aborted",onclose),stream.removeListener("complete",onfinish),stream.removeListener("abort",onclose),stream.removeListener("request",onrequest),stream.req&&stream.req.removeListener("finish",onfinish),stream.removeListener("end",onlegacyfinish),stream.removeListener("close",onlegacyfinish),stream.removeListener("finish",onfinish),stream.removeListener("end",onend),stream.removeListener("error",onerror),stream.removeListener("close",onclose)};if(options2.signal&&!closed){let abort=()=>{let endCallback=callback;cleanup(),endCallback.call(stream,new AbortError(void 0,{cause:options2.signal.reason}))};if(options2.signal.aborted)process2.nextTick(abort);else{addAbortListener=addAbortListener||require_util3().addAbortListener;let disposable=addAbortListener(options2.signal,abort),originalCallback=callback;callback=once((...args)=>{disposable[SymbolDispose](),originalCallback.apply(stream,args)})}}return cleanup}function eosWeb(stream,options2,callback){let isAborted=!1,abort=nop;if(options2.signal)if(abort=()=>{isAborted=!0,callback.call(stream,new AbortError(void 0,{cause:options2.signal.reason}))},options2.signal.aborted)process2.nextTick(abort);else{addAbortListener=addAbortListener||require_util3().addAbortListener;let disposable=addAbortListener(options2.signal,abort),originalCallback=callback;callback=once((...args)=>{disposable[SymbolDispose](),originalCallback.apply(stream,args)})}let resolverFn=(...args)=>{isAborted||process2.nextTick(()=>callback.apply(stream,args))};return PromisePrototypeThen(stream[kIsClosedPromise].promise,resolverFn,resolverFn),nop}function finished(stream,opts){var _opts;let autoCleanup=!1;return opts===null&&(opts=kEmptyObject),(_opts=opts)!==null&&_opts!==void 0&&_opts.cleanup&&(validateBoolean(opts.cleanup,"cleanup"),autoCleanup=opts.cleanup),new Promise2((resolve2,reject)=>{let cleanup=eos(stream,opts,err=>{autoCleanup&&cleanup(),err?reject(err):resolve2()})})}module.exports=eos;module.exports.finished=finished}});var require_destroy=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/destroy.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{aggregateTwoErrors,codes:{ERR_MULTIPLE_CALLBACK},AbortError}=require_errors2(),{Symbol:Symbol2}=require_primordials(),{kIsDestroyed,isDestroyed,isFinished,isServerRequest}=require_utils(),kDestroy=Symbol2("kDestroy"),kConstruct=Symbol2("kConstruct");function checkError(err,w2,r2){err&&(err.stack,w2&&!w2.errored&&(w2.errored=err),r2&&!r2.errored&&(r2.errored=err))}function destroy(err,cb){let r2=this._readableState,w2=this._writableState,s2=w2||r2;return w2!=null&&w2.destroyed||r2!=null&&r2.destroyed?(typeof cb=="function"&&cb(),this):(checkError(err,w2,r2),w2&&(w2.destroyed=!0),r2&&(r2.destroyed=!0),s2.constructed?_destroy(this,err,cb):this.once(kDestroy,function(er2){_destroy(this,aggregateTwoErrors(er2,err),cb)}),this)}function _destroy(self2,err,cb){let called=!1;function onDestroy(err2){if(called)return;called=!0;let r2=self2._readableState,w2=self2._writableState;checkError(err2,w2,r2),w2&&(w2.closed=!0),r2&&(r2.closed=!0),typeof cb=="function"&&cb(err2),err2?process2.nextTick(emitErrorCloseNT,self2,err2):process2.nextTick(emitCloseNT,self2)}try{self2._destroy(err||null,onDestroy)}catch(err2){onDestroy(err2)}}function emitErrorCloseNT(self2,err){emitErrorNT(self2,err),emitCloseNT(self2)}function emitCloseNT(self2){let r2=self2._readableState,w2=self2._writableState;w2&&(w2.closeEmitted=!0),r2&&(r2.closeEmitted=!0),(w2!=null&&w2.emitClose||r2!=null&&r2.emitClose)&&self2.emit("close")}function emitErrorNT(self2,err){let r2=self2._readableState,w2=self2._writableState;w2!=null&&w2.errorEmitted||r2!=null&&r2.errorEmitted||(w2&&(w2.errorEmitted=!0),r2&&(r2.errorEmitted=!0),self2.emit("error",err))}function undestroy(){let r2=this._readableState,w2=this._writableState;r2&&(r2.constructed=!0,r2.closed=!1,r2.closeEmitted=!1,r2.destroyed=!1,r2.errored=null,r2.errorEmitted=!1,r2.reading=!1,r2.ended=r2.readable===!1,r2.endEmitted=r2.readable===!1),w2&&(w2.constructed=!0,w2.destroyed=!1,w2.closed=!1,w2.closeEmitted=!1,w2.errored=null,w2.errorEmitted=!1,w2.finalCalled=!1,w2.prefinished=!1,w2.ended=w2.writable===!1,w2.ending=w2.writable===!1,w2.finished=w2.writable===!1)}function errorOrDestroy(stream,err,sync){let r2=stream._readableState,w2=stream._writableState;if(w2!=null&&w2.destroyed||r2!=null&&r2.destroyed)return this;r2!=null&&r2.autoDestroy||w2!=null&&w2.autoDestroy?stream.destroy(err):err&&(err.stack,w2&&!w2.errored&&(w2.errored=err),r2&&!r2.errored&&(r2.errored=err),sync?process2.nextTick(emitErrorNT,stream,err):emitErrorNT(stream,err))}function construct(stream,cb){if(typeof stream._construct!="function")return;let r2=stream._readableState,w2=stream._writableState;r2&&(r2.constructed=!1),w2&&(w2.constructed=!1),stream.once(kConstruct,cb),!(stream.listenerCount(kConstruct)>1)&&process2.nextTick(constructNT,stream)}function constructNT(stream){let called=!1;function onConstruct(err){if(called){errorOrDestroy(stream,err??new ERR_MULTIPLE_CALLBACK);return}called=!0;let r2=stream._readableState,w2=stream._writableState,s2=w2||r2;r2&&(r2.constructed=!0),w2&&(w2.constructed=!0),s2.destroyed?stream.emit(kDestroy,err):err?errorOrDestroy(stream,err,!0):process2.nextTick(emitConstructNT,stream)}try{stream._construct(err=>{process2.nextTick(onConstruct,err)})}catch(err){process2.nextTick(onConstruct,err)}}function emitConstructNT(stream){stream.emit(kConstruct)}function isRequest(stream){return stream?.setHeader&&typeof stream.abort=="function"}function emitCloseLegacy(stream){stream.emit("close")}function emitErrorCloseLegacy(stream,err){stream.emit("error",err),process2.nextTick(emitCloseLegacy,stream)}function destroyer(stream,err){!stream||isDestroyed(stream)||(!err&&!isFinished(stream)&&(err=new AbortError),isServerRequest(stream)?(stream.socket=null,stream.destroy(err)):isRequest(stream)?stream.abort():isRequest(stream.req)?stream.req.abort():typeof stream.destroy=="function"?stream.destroy(err):typeof stream.close=="function"?stream.close():err?process2.nextTick(emitErrorCloseLegacy,stream,err):process2.nextTick(emitCloseLegacy,stream),stream.destroyed||(stream[kIsDestroyed]=!0))}module.exports={construct,destroyer,destroy,undestroy,errorOrDestroy}}});var require_legacy=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/legacy.js"(exports,module){"use strict";init_browser_globals();var{ArrayIsArray,ObjectSetPrototypeOf}=require_primordials(),{EventEmitter:EE}=require_events();function Stream(opts){EE.call(this,opts)}ObjectSetPrototypeOf(Stream.prototype,EE.prototype);ObjectSetPrototypeOf(Stream,EE);Stream.prototype.pipe=function(dest,options2){let source2=this;function ondata(chunk){dest.writable&&dest.write(chunk)===!1&&source2.pause&&source2.pause()}source2.on("data",ondata);function ondrain(){source2.readable&&source2.resume&&source2.resume()}dest.on("drain",ondrain),!dest._isStdio&&(!options2||options2.end!==!1)&&(source2.on("end",onend),source2.on("close",onclose));let didOnEnd=!1;function onend(){didOnEnd||(didOnEnd=!0,dest.end())}function onclose(){didOnEnd||(didOnEnd=!0,typeof dest.destroy=="function"&&dest.destroy())}function onerror(er2){var _this$listenerCount;cleanup(),((_this$listenerCount=this.listenerCount)===null||_this$listenerCount===void 0?void 0:_this$listenerCount.call(this,"error"))===0&&this.emit("error",er2)}prependListener(source2,"error",onerror),prependListener(dest,"error",onerror);function cleanup(){source2.removeListener("data",ondata),dest.removeListener("drain",ondrain),source2.removeListener("end",onend),source2.removeListener("close",onclose),source2.removeListener("error",onerror),dest.removeListener("error",onerror),source2.removeListener("end",cleanup),source2.removeListener("close",cleanup),dest.removeListener("close",cleanup)}return source2.on("end",cleanup),source2.on("close",cleanup),dest.on("close",cleanup),dest.emit("pipe",source2),dest};function prependListener(emitter,event,fn2){if(typeof emitter.prependListener=="function")return emitter.prependListener(event,fn2);!emitter._events||!emitter._events[event]?emitter.on(event,fn2):ArrayIsArray(emitter._events[event])?emitter._events[event].unshift(fn2):emitter._events[event]=[fn2,emitter._events[event]]}module.exports={Stream,prependListener}}});var require_add_abort_signal=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/add-abort-signal.js"(exports,module){"use strict";init_browser_globals();var{SymbolDispose}=require_primordials(),{AbortError,codes:codes2}=require_errors2(),{isNodeStream,isWebStream,kControllerErrorFunction}=require_utils(),eos=require_end_of_stream(),{ERR_INVALID_ARG_TYPE}=codes2,addAbortListener,validateAbortSignal=(signal,name)=>{if(typeof signal!="object"||!("aborted"in signal))throw new ERR_INVALID_ARG_TYPE(name,"AbortSignal",signal)};module.exports.addAbortSignal=function(signal,stream){if(validateAbortSignal(signal,"signal"),!isNodeStream(stream)&&!isWebStream(stream))throw new ERR_INVALID_ARG_TYPE("stream",["ReadableStream","WritableStream","Stream"],stream);return module.exports.addAbortSignalNoValidate(signal,stream)};module.exports.addAbortSignalNoValidate=function(signal,stream){if(typeof signal!="object"||!("aborted"in signal))return stream;let onAbort=isNodeStream(stream)?()=>{stream.destroy(new AbortError(void 0,{cause:signal.reason}))}:()=>{stream[kControllerErrorFunction](new AbortError(void 0,{cause:signal.reason}))};if(signal.aborted)onAbort();else{addAbortListener=addAbortListener||require_util3().addAbortListener;let disposable=addAbortListener(signal,onAbort);eos(stream,disposable[SymbolDispose])}return stream}}});var require_buffer_list=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/buffer_list.js"(exports,module){"use strict";init_browser_globals();var{StringPrototypeSlice,SymbolIterator,TypedArrayPrototypeSet,Uint8Array:Uint8Array2}=require_primordials(),{Buffer:Buffer6}=require_buffer(),{inspect}=require_util3();module.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(v2){let entry={data:v2,next:null};this.length>0?this.tail.next=entry:this.head=entry,this.tail=entry,++this.length}unshift(v2){let entry={data:v2,next:this.head};this.length===0&&(this.tail=entry),this.head=entry,++this.length}shift(){if(this.length===0)return;let ret=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,ret}clear(){this.head=this.tail=null,this.length=0}join(s2){if(this.length===0)return"";let p2=this.head,ret=""+p2.data;for(;(p2=p2.next)!==null;)ret+=s2+p2.data;return ret}concat(n2){if(this.length===0)return Buffer6.alloc(0);let ret=Buffer6.allocUnsafe(n2>>>0),p2=this.head,i2=0;for(;p2;)TypedArrayPrototypeSet(ret,p2.data,i2),i2+=p2.data.length,p2=p2.next;return ret}consume(n2,hasStrings){let data=this.head.data;if(n2<data.length){let slice=data.slice(0,n2);return this.head.data=data.slice(n2),slice}return n2===data.length?this.shift():hasStrings?this._getString(n2):this._getBuffer(n2)}first(){return this.head.data}*[SymbolIterator](){for(let p2=this.head;p2;p2=p2.next)yield p2.data}_getString(n2){let ret="",p2=this.head,c2=0;do{let str=p2.data;if(n2>str.length)ret+=str,n2-=str.length;else{n2===str.length?(ret+=str,++c2,p2.next?this.head=p2.next:this.head=this.tail=null):(ret+=StringPrototypeSlice(str,0,n2),this.head=p2,p2.data=StringPrototypeSlice(str,n2));break}++c2}while((p2=p2.next)!==null);return this.length-=c2,ret}_getBuffer(n2){let ret=Buffer6.allocUnsafe(n2),retLen=n2,p2=this.head,c2=0;do{let buf=p2.data;if(n2>buf.length)TypedArrayPrototypeSet(ret,buf,retLen-n2),n2-=buf.length;else{n2===buf.length?(TypedArrayPrototypeSet(ret,buf,retLen-n2),++c2,p2.next?this.head=p2.next:this.head=this.tail=null):(TypedArrayPrototypeSet(ret,new Uint8Array2(buf.buffer,buf.byteOffset,n2),retLen-n2),this.head=p2,p2.data=buf.slice(n2));break}++c2}while((p2=p2.next)!==null);return this.length-=c2,ret}[Symbol.for("nodejs.util.inspect.custom")](_2,options2){return inspect(this,{...options2,depth:0,customInspect:!1})}}}});var require_state=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/state.js"(exports,module){"use strict";init_browser_globals();var{MathFloor,NumberIsInteger}=require_primordials(),{validateInteger}=require_validators2(),{ERR_INVALID_ARG_VALUE}=require_errors2().codes,defaultHighWaterMarkBytes=16*1024,defaultHighWaterMarkObjectMode=16;function highWaterMarkFrom(options2,isDuplex,duplexKey){return options2.highWaterMark!=null?options2.highWaterMark:isDuplex?options2[duplexKey]:null}function getDefaultHighWaterMark(objectMode){return objectMode?defaultHighWaterMarkObjectMode:defaultHighWaterMarkBytes}function setDefaultHighWaterMark(objectMode,value2){validateInteger(value2,"value",0),objectMode?defaultHighWaterMarkObjectMode=value2:defaultHighWaterMarkBytes=value2}function getHighWaterMark(state,options2,duplexKey,isDuplex){let hwm=highWaterMarkFrom(options2,isDuplex,duplexKey);if(hwm!=null){if(!NumberIsInteger(hwm)||hwm<0){let name=isDuplex?`options.${duplexKey}`:"options.highWaterMark";throw new ERR_INVALID_ARG_VALUE(name,hwm)}return MathFloor(hwm)}return getDefaultHighWaterMark(state.objectMode)}module.exports={getHighWaterMark,getDefaultHighWaterMark,setDefaultHighWaterMark}}});var require_string_decoder=__commonJS({"node_modules/.pnpm/string_decoder@1.3.0/node_modules/string_decoder/lib/string_decoder.js"(exports){"use strict";init_browser_globals();var Buffer6=require_safe_buffer().Buffer,isEncoding=Buffer6.isEncoding||function(encoding){switch(encoding=""+encoding,encoding&&encoding.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 _normalizeEncoding(enc){if(!enc)return"utf8";for(var retried;;)switch(enc){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 enc;default:if(retried)return;enc=(""+enc).toLowerCase(),retried=!0}}function normalizeEncoding(enc){var nenc=_normalizeEncoding(enc);if(typeof nenc!="string"&&(Buffer6.isEncoding===isEncoding||!isEncoding(enc)))throw new Error("Unknown encoding: "+enc);return nenc||enc}exports.StringDecoder=StringDecoder;function StringDecoder(encoding){this.encoding=normalizeEncoding(encoding);var nb;switch(this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,nb=4;break;case"utf8":this.fillLast=utf8FillLast,nb=4;break;case"base64":this.text=base64Text,this.end=base64End,nb=3;break;default:this.write=simpleWrite,this.end=simpleEnd;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Buffer6.allocUnsafe(nb)}StringDecoder.prototype.write=function(buf){if(buf.length===0)return"";var r2,i2;if(this.lastNeed){if(r2=this.fillLast(buf),r2===void 0)return"";i2=this.lastNeed,this.lastNeed=0}else i2=0;return i2<buf.length?r2?r2+this.text(buf,i2):this.text(buf,i2):r2||""};StringDecoder.prototype.end=utf8End;StringDecoder.prototype.text=utf8Text;StringDecoder.prototype.fillLast=function(buf){if(this.lastNeed<=buf.length)return buf.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);buf.copy(this.lastChar,this.lastTotal-this.lastNeed,0,buf.length),this.lastNeed-=buf.length};function utf8CheckByte(byte){return byte<=127?0:byte>>5===6?2:byte>>4===14?3:byte>>3===30?4:byte>>6===2?-1:-2}function utf8CheckIncomplete(self2,buf,i2){var j=buf.length-1;if(j<i2)return 0;var nb=utf8CheckByte(buf[j]);return nb>=0?(nb>0&&(self2.lastNeed=nb-1),nb):--j<i2||nb===-2?0:(nb=utf8CheckByte(buf[j]),nb>=0?(nb>0&&(self2.lastNeed=nb-2),nb):--j<i2||nb===-2?0:(nb=utf8CheckByte(buf[j]),nb>=0?(nb>0&&(nb===2?nb=0:self2.lastNeed=nb-3),nb):0))}function utf8CheckExtraBytes(self2,buf,p2){if((buf[0]&192)!==128)return self2.lastNeed=0,"\uFFFD";if(self2.lastNeed>1&&buf.length>1){if((buf[1]&192)!==128)return self2.lastNeed=1,"\uFFFD";if(self2.lastNeed>2&&buf.length>2&&(buf[2]&192)!==128)return self2.lastNeed=2,"\uFFFD"}}function utf8FillLast(buf){var p2=this.lastTotal-this.lastNeed,r2=utf8CheckExtraBytes(this,buf,p2);if(r2!==void 0)return r2;if(this.lastNeed<=buf.length)return buf.copy(this.lastChar,p2,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);buf.copy(this.lastChar,p2,0,buf.length),this.lastNeed-=buf.length}function utf8Text(buf,i2){var total=utf8CheckIncomplete(this,buf,i2);if(!this.lastNeed)return buf.toString("utf8",i2);this.lastTotal=total;var end=buf.length-(total-this.lastNeed);return buf.copy(this.lastChar,0,end),buf.toString("utf8",i2,end)}function utf8End(buf){var r2=buf&&buf.length?this.write(buf):"";return this.lastNeed?r2+"\uFFFD":r2}function utf16Text(buf,i2){if((buf.length-i2)%2===0){var r2=buf.toString("utf16le",i2);if(r2){var c2=r2.charCodeAt(r2.length-1);if(c2>=55296&&c2<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=buf[buf.length-2],this.lastChar[1]=buf[buf.length-1],r2.slice(0,-1)}return r2}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=buf[buf.length-1],buf.toString("utf16le",i2,buf.length-1)}function utf16End(buf){var r2=buf&&buf.length?this.write(buf):"";if(this.lastNeed){var end=this.lastTotal-this.lastNeed;return r2+this.lastChar.toString("utf16le",0,end)}return r2}function base64Text(buf,i2){var n2=(buf.length-i2)%3;return n2===0?buf.toString("base64",i2):(this.lastNeed=3-n2,this.lastTotal=3,n2===1?this.lastChar[0]=buf[buf.length-1]:(this.lastChar[0]=buf[buf.length-2],this.lastChar[1]=buf[buf.length-1]),buf.toString("base64",i2,buf.length-n2))}function base64End(buf){var r2=buf&&buf.length?this.write(buf):"";return this.lastNeed?r2+this.lastChar.toString("base64",0,3-this.lastNeed):r2}function simpleWrite(buf){return buf.toString(this.encoding)}function simpleEnd(buf){return buf&&buf.length?this.write(buf):""}}});var require_from=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/from.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{PromisePrototypeThen,SymbolAsyncIterator,SymbolIterator}=require_primordials(),{Buffer:Buffer6}=require_buffer(),{ERR_INVALID_ARG_TYPE,ERR_STREAM_NULL_VALUES}=require_errors2().codes;function from(Readable,iterable,opts){let iterator;if(typeof iterable=="string"||iterable instanceof Buffer6)return new Readable({objectMode:!0,...opts,read(){this.push(iterable),this.push(null)}});let isAsync;if(iterable&&iterable[SymbolAsyncIterator])isAsync=!0,iterator=iterable[SymbolAsyncIterator]();else if(iterable&&iterable[SymbolIterator])isAsync=!1,iterator=iterable[SymbolIterator]();else throw new ERR_INVALID_ARG_TYPE("iterable",["Iterable"],iterable);let readable=new Readable({objectMode:!0,highWaterMark:1,...opts}),reading=!1;readable._read=function(){reading||(reading=!0,next())},readable._destroy=function(error,cb){PromisePrototypeThen(close2(error),()=>process2.nextTick(cb,error),e2=>process2.nextTick(cb,e2||error))};async function close2(error){let hadError=error!=null,hasThrow=typeof iterator.throw=="function";if(hadError&&hasThrow){let{value:value2,done}=await iterator.throw(error);if(await value2,done)return}if(typeof iterator.return=="function"){let{value:value2}=await iterator.return();await value2}}async function next(){for(;;){try{let{value:value2,done}=isAsync?await iterator.next():iterator.next();if(done)readable.push(null);else{let res=value2&&typeof value2.then=="function"?await value2:value2;if(res===null)throw reading=!1,new ERR_STREAM_NULL_VALUES;if(readable.push(res))continue;reading=!1}}catch(err){readable.destroy(err)}break}}return readable}module.exports=from}});var require_readable=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/readable.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{ArrayPrototypeIndexOf,NumberIsInteger,NumberIsNaN,NumberParseInt,ObjectDefineProperties,ObjectKeys,ObjectSetPrototypeOf,Promise:Promise2,SafeSet,SymbolAsyncDispose,SymbolAsyncIterator,Symbol:Symbol2}=require_primordials();module.exports=Readable;Readable.ReadableState=ReadableState;var{EventEmitter:EE}=require_events(),{Stream,prependListener}=require_legacy(),{Buffer:Buffer6}=require_buffer(),{addAbortSignal}=require_add_abort_signal(),eos=require_end_of_stream(),debug=require_util3().debuglog("stream",fn2=>{debug=fn2}),BufferList=require_buffer_list(),destroyImpl=require_destroy(),{getHighWaterMark,getDefaultHighWaterMark}=require_state(),{aggregateTwoErrors,codes:{ERR_INVALID_ARG_TYPE,ERR_METHOD_NOT_IMPLEMENTED,ERR_OUT_OF_RANGE,ERR_STREAM_PUSH_AFTER_EOF,ERR_STREAM_UNSHIFT_AFTER_END_EVENT},AbortError}=require_errors2(),{validateObject}=require_validators2(),kPaused=Symbol2("kPaused"),{StringDecoder}=require_string_decoder(),from=require_from();ObjectSetPrototypeOf(Readable.prototype,Stream.prototype);ObjectSetPrototypeOf(Readable,Stream);var nop=()=>{},{errorOrDestroy}=destroyImpl,kObjectMode=1,kEnded=2,kEndEmitted=4,kReading=8,kConstructed=16,kSync=32,kNeedReadable=64,kEmittedReadable=128,kReadableListening=256,kResumeScheduled=512,kErrorEmitted=1024,kEmitClose=2048,kAutoDestroy=4096,kDestroyed=8192,kClosed=16384,kCloseEmitted=32768,kMultiAwaitDrain=65536,kReadingMore=1<<17,kDataEmitted=1<<18;function makeBitMapDescriptor(bit){return{enumerable:!1,get(){return(this.state&bit)!==0},set(value2){value2?this.state|=bit:this.state&=~bit}}}ObjectDefineProperties(ReadableState.prototype,{objectMode:makeBitMapDescriptor(kObjectMode),ended:makeBitMapDescriptor(kEnded),endEmitted:makeBitMapDescriptor(kEndEmitted),reading:makeBitMapDescriptor(kReading),constructed:makeBitMapDescriptor(kConstructed),sync:makeBitMapDescriptor(kSync),needReadable:makeBitMapDescriptor(kNeedReadable),emittedReadable:makeBitMapDescriptor(kEmittedReadable),readableListening:makeBitMapDescriptor(kReadableListening),resumeScheduled:makeBitMapDescriptor(kResumeScheduled),errorEmitted:makeBitMapDescriptor(kErrorEmitted),emitClose:makeBitMapDescriptor(kEmitClose),autoDestroy:makeBitMapDescriptor(kAutoDestroy),destroyed:makeBitMapDescriptor(kDestroyed),closed:makeBitMapDescriptor(kClosed),closeEmitted:makeBitMapDescriptor(kCloseEmitted),multiAwaitDrain:makeBitMapDescriptor(kMultiAwaitDrain),readingMore:makeBitMapDescriptor(kReadingMore),dataEmitted:makeBitMapDescriptor(kDataEmitted)});function ReadableState(options2,stream,isDuplex){typeof isDuplex!="boolean"&&(isDuplex=stream instanceof require_duplex()),this.state=kEmitClose|kAutoDestroy|kConstructed|kSync,options2&&options2.objectMode&&(this.state|=kObjectMode),isDuplex&&options2&&options2.readableObjectMode&&(this.state|=kObjectMode),this.highWaterMark=options2?getHighWaterMark(this,options2,"readableHighWaterMark",isDuplex):getDefaultHighWaterMark(!1),this.buffer=new BufferList,this.length=0,this.pipes=[],this.flowing=null,this[kPaused]=null,options2&&options2.emitClose===!1&&(this.state&=~kEmitClose),options2&&options2.autoDestroy===!1&&(this.state&=~kAutoDestroy),this.errored=null,this.defaultEncoding=options2&&options2.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,options2&&options2.encoding&&(this.decoder=new StringDecoder(options2.encoding),this.encoding=options2.encoding)}function Readable(options2){if(!(this instanceof Readable))return new Readable(options2);let isDuplex=this instanceof require_duplex();this._readableState=new ReadableState(options2,this,isDuplex),options2&&(typeof options2.read=="function"&&(this._read=options2.read),typeof options2.destroy=="function"&&(this._destroy=options2.destroy),typeof options2.construct=="function"&&(this._construct=options2.construct),options2.signal&&!isDuplex&&addAbortSignal(options2.signal,this)),Stream.call(this,options2),destroyImpl.construct(this,()=>{this._readableState.needReadable&&maybeReadMore(this,this._readableState)})}Readable.prototype.destroy=destroyImpl.destroy;Readable.prototype._undestroy=destroyImpl.undestroy;Readable.prototype._destroy=function(err,cb){cb(err)};Readable.prototype[EE.captureRejectionSymbol]=function(err){this.destroy(err)};Readable.prototype[SymbolAsyncDispose]=function(){let error;return this.destroyed||(error=this.readableEnded?null:new AbortError,this.destroy(error)),new Promise2((resolve2,reject)=>eos(this,err=>err&&err!==error?reject(err):resolve2(null)))};Readable.prototype.push=function(chunk,encoding){return readableAddChunk(this,chunk,encoding,!1)};Readable.prototype.unshift=function(chunk,encoding){return readableAddChunk(this,chunk,encoding,!0)};function readableAddChunk(stream,chunk,encoding,addToFront){debug("readableAddChunk",chunk);let state=stream._readableState,err;if((state.state&kObjectMode)===0&&(typeof chunk=="string"?(encoding=encoding||state.defaultEncoding,state.encoding!==encoding&&(addToFront&&state.encoding?chunk=Buffer6.from(chunk,encoding).toString(state.encoding):(chunk=Buffer6.from(chunk,encoding),encoding=""))):chunk instanceof Buffer6?encoding="":Stream._isUint8Array(chunk)?(chunk=Stream._uint8ArrayToBuffer(chunk),encoding=""):chunk!=null&&(err=new ERR_INVALID_ARG_TYPE("chunk",["string","Buffer","Uint8Array"],chunk))),err)errorOrDestroy(stream,err);else if(chunk===null)state.state&=~kReading,onEofChunk(stream,state);else if((state.state&kObjectMode)!==0||chunk&&chunk.length>0)if(addToFront)if((state.state&kEndEmitted)!==0)errorOrDestroy(stream,new ERR_STREAM_UNSHIFT_AFTER_END_EVENT);else{if(state.destroyed||state.errored)return!1;addChunk(stream,state,chunk,!0)}else if(state.ended)errorOrDestroy(stream,new ERR_STREAM_PUSH_AFTER_EOF);else{if(state.destroyed||state.errored)return!1;state.state&=~kReading,state.decoder&&!encoding?(chunk=state.decoder.write(chunk),state.objectMode||chunk.length!==0?addChunk(stream,state,chunk,!1):maybeReadMore(stream,state)):addChunk(stream,state,chunk,!1)}else addToFront||(state.state&=~kReading,maybeReadMore(stream,state));return!state.ended&&(state.length<state.highWaterMark||state.length===0)}function addChunk(stream,state,chunk,addToFront){state.flowing&&state.length===0&&!state.sync&&stream.listenerCount("data")>0?((state.state&kMultiAwaitDrain)!==0?state.awaitDrainWriters.clear():state.awaitDrainWriters=null,state.dataEmitted=!0,stream.emit("data",chunk)):(state.length+=state.objectMode?1:chunk.length,addToFront?state.buffer.unshift(chunk):state.buffer.push(chunk),(state.state&kNeedReadable)!==0&&emitReadable(stream)),maybeReadMore(stream,state)}Readable.prototype.isPaused=function(){let state=this._readableState;return state[kPaused]===!0||state.flowing===!1};Readable.prototype.setEncoding=function(enc){let decoder=new StringDecoder(enc);this._readableState.decoder=decoder,this._readableState.encoding=this._readableState.decoder.encoding;let buffer=this._readableState.buffer,content3="";for(let data of buffer)content3+=decoder.write(data);return buffer.clear(),content3!==""&&buffer.push(content3),this._readableState.length=content3.length,this};var MAX_HWM=1073741824;function computeNewHighWaterMark(n2){if(n2>MAX_HWM)throw new ERR_OUT_OF_RANGE("size","<= 1GiB",n2);return n2--,n2|=n2>>>1,n2|=n2>>>2,n2|=n2>>>4,n2|=n2>>>8,n2|=n2>>>16,n2++,n2}function howMuchToRead(n2,state){return n2<=0||state.length===0&&state.ended?0:(state.state&kObjectMode)!==0?1:NumberIsNaN(n2)?state.flowing&&state.length?state.buffer.first().length:state.length:n2<=state.length?n2:state.ended?state.length:0}Readable.prototype.read=function(n2){debug("read",n2),n2===void 0?n2=NaN:NumberIsInteger(n2)||(n2=NumberParseInt(n2,10));let state=this._readableState,nOrig=n2;if(n2>state.highWaterMark&&(state.highWaterMark=computeNewHighWaterMark(n2)),n2!==0&&(state.state&=~kEmittedReadable),n2===0&&state.needReadable&&((state.highWaterMark!==0?state.length>=state.highWaterMark:state.length>0)||state.ended))return debug("read: emitReadable",state.length,state.ended),state.length===0&&state.ended?endReadable(this):emitReadable(this),null;if(n2=howMuchToRead(n2,state),n2===0&&state.ended)return state.length===0&&endReadable(this),null;let doRead=(state.state&kNeedReadable)!==0;if(debug("need readable",doRead),(state.length===0||state.length-n2<state.highWaterMark)&&(doRead=!0,debug("length less than watermark",doRead)),state.ended||state.reading||state.destroyed||state.errored||!state.constructed)doRead=!1,debug("reading, ended or constructing",doRead);else if(doRead){debug("do read"),state.state|=kReading|kSync,state.length===0&&(state.state|=kNeedReadable);try{this._read(state.highWaterMark)}catch(err){errorOrDestroy(this,err)}state.state&=~kSync,state.reading||(n2=howMuchToRead(nOrig,state))}let ret;return n2>0?ret=fromList(n2,state):ret=null,ret===null?(state.needReadable=state.length<=state.highWaterMark,n2=0):(state.length-=n2,state.multiAwaitDrain?state.awaitDrainWriters.clear():state.awaitDrainWriters=null),state.length===0&&(state.ended||(state.needReadable=!0),nOrig!==n2&&state.ended&&endReadable(this)),ret!==null&&!state.errorEmitted&&!state.closeEmitted&&(state.dataEmitted=!0,this.emit("data",ret)),ret};function onEofChunk(stream,state){if(debug("onEofChunk"),!state.ended){if(state.decoder){let chunk=state.decoder.end();chunk&&chunk.length&&(state.buffer.push(chunk),state.length+=state.objectMode?1:chunk.length)}state.ended=!0,state.sync?emitReadable(stream):(state.needReadable=!1,state.emittedReadable=!0,emitReadable_(stream))}}function emitReadable(stream){let state=stream._readableState;debug("emitReadable",state.needReadable,state.emittedReadable),state.needReadable=!1,state.emittedReadable||(debug("emitReadable",state.flowing),state.emittedReadable=!0,process2.nextTick(emitReadable_,stream))}function emitReadable_(stream){let state=stream._readableState;debug("emitReadable_",state.destroyed,state.length,state.ended),!state.destroyed&&!state.errored&&(state.length||state.ended)&&(stream.emit("readable"),state.emittedReadable=!1),state.needReadable=!state.flowing&&!state.ended&&state.length<=state.highWaterMark,flow3(stream)}function maybeReadMore(stream,state){!state.readingMore&&state.constructed&&(state.readingMore=!0,process2.nextTick(maybeReadMore_,stream,state))}function maybeReadMore_(stream,state){for(;!state.reading&&!state.ended&&(state.length<state.highWaterMark||state.flowing&&state.length===0);){let len=state.length;if(debug("maybeReadMore read 0"),stream.read(0),len===state.length)break}state.readingMore=!1}Readable.prototype._read=function(n2){throw new ERR_METHOD_NOT_IMPLEMENTED("_read()")};Readable.prototype.pipe=function(dest,pipeOpts){let src=this,state=this._readableState;state.pipes.length===1&&(state.multiAwaitDrain||(state.multiAwaitDrain=!0,state.awaitDrainWriters=new SafeSet(state.awaitDrainWriters?[state.awaitDrainWriters]:[]))),state.pipes.push(dest),debug("pipe count=%d opts=%j",state.pipes.length,pipeOpts);let endFn=(!pipeOpts||pipeOpts.end!==!1)&&dest!==process2.stdout&&dest!==process2.stderr?onend:unpipe;state.endEmitted?process2.nextTick(endFn):src.once("end",endFn),dest.on("unpipe",onunpipe);function onunpipe(readable,unpipeInfo){debug("onunpipe"),readable===src&&unpipeInfo&&unpipeInfo.hasUnpiped===!1&&(unpipeInfo.hasUnpiped=!0,cleanup())}function onend(){debug("onend"),dest.end()}let ondrain,cleanedUp=!1;function cleanup(){debug("cleanup"),dest.removeListener("close",onclose),dest.removeListener("finish",onfinish),ondrain&&dest.removeListener("drain",ondrain),dest.removeListener("error",onerror),dest.removeListener("unpipe",onunpipe),src.removeListener("end",onend),src.removeListener("end",unpipe),src.removeListener("data",ondata),cleanedUp=!0,ondrain&&state.awaitDrainWriters&&(!dest._writableState||dest._writableState.needDrain)&&ondrain()}function pause(){cleanedUp||(state.pipes.length===1&&state.pipes[0]===dest?(debug("false write response, pause",0),state.awaitDrainWriters=dest,state.multiAwaitDrain=!1):state.pipes.length>1&&state.pipes.includes(dest)&&(debug("false write response, pause",state.awaitDrainWriters.size),state.awaitDrainWriters.add(dest)),src.pause()),ondrain||(ondrain=pipeOnDrain(src,dest),dest.on("drain",ondrain))}src.on("data",ondata);function ondata(chunk){debug("ondata");let ret=dest.write(chunk);debug("dest.write",ret),ret===!1&&pause()}function onerror(er2){if(debug("onerror",er2),unpipe(),dest.removeListener("error",onerror),dest.listenerCount("error")===0){let s2=dest._writableState||dest._readableState;s2&&!s2.errorEmitted?errorOrDestroy(dest,er2):dest.emit("error",er2)}}prependListener(dest,"error",onerror);function onclose(){dest.removeListener("finish",onfinish),unpipe()}dest.once("close",onclose);function onfinish(){debug("onfinish"),dest.removeListener("close",onclose),unpipe()}dest.once("finish",onfinish);function unpipe(){debug("unpipe"),src.unpipe(dest)}return dest.emit("pipe",src),dest.writableNeedDrain===!0?pause():state.flowing||(debug("pipe resume"),src.resume()),dest};function pipeOnDrain(src,dest){return function(){let state=src._readableState;state.awaitDrainWriters===dest?(debug("pipeOnDrain",1),state.awaitDrainWriters=null):state.multiAwaitDrain&&(debug("pipeOnDrain",state.awaitDrainWriters.size),state.awaitDrainWriters.delete(dest)),(!state.awaitDrainWriters||state.awaitDrainWriters.size===0)&&src.listenerCount("data")&&src.resume()}}Readable.prototype.unpipe=function(dest){let state=this._readableState,unpipeInfo={hasUnpiped:!1};if(state.pipes.length===0)return this;if(!dest){let dests=state.pipes;state.pipes=[],this.pause();for(let i2=0;i2<dests.length;i2++)dests[i2].emit("unpipe",this,{hasUnpiped:!1});return this}let index4=ArrayPrototypeIndexOf(state.pipes,dest);return index4===-1?this:(state.pipes.splice(index4,1),state.pipes.length===0&&this.pause(),dest.emit("unpipe",this,unpipeInfo),this)};Readable.prototype.on=function(ev,fn2){let res=Stream.prototype.on.call(this,ev,fn2),state=this._readableState;return ev==="data"?(state.readableListening=this.listenerCount("readable")>0,state.flowing!==!1&&this.resume()):ev==="readable"&&!state.endEmitted&&!state.readableListening&&(state.readableListening=state.needReadable=!0,state.flowing=!1,state.emittedReadable=!1,debug("on readable",state.length,state.reading),state.length?emitReadable(this):state.reading||process2.nextTick(nReadingNextTick,this)),res};Readable.prototype.addListener=Readable.prototype.on;Readable.prototype.removeListener=function(ev,fn2){let res=Stream.prototype.removeListener.call(this,ev,fn2);return ev==="readable"&&process2.nextTick(updateReadableListening,this),res};Readable.prototype.off=Readable.prototype.removeListener;Readable.prototype.removeAllListeners=function(ev){let res=Stream.prototype.removeAllListeners.apply(this,arguments);return(ev==="readable"||ev===void 0)&&process2.nextTick(updateReadableListening,this),res};function updateReadableListening(self2){let state=self2._readableState;state.readableListening=self2.listenerCount("readable")>0,state.resumeScheduled&&state[kPaused]===!1?state.flowing=!0:self2.listenerCount("data")>0?self2.resume():state.readableListening||(state.flowing=null)}function nReadingNextTick(self2){debug("readable nexttick read 0"),self2.read(0)}Readable.prototype.resume=function(){let state=this._readableState;return state.flowing||(debug("resume"),state.flowing=!state.readableListening,resume(this,state)),state[kPaused]=!1,this};function resume(stream,state){state.resumeScheduled||(state.resumeScheduled=!0,process2.nextTick(resume_,stream,state))}function resume_(stream,state){debug("resume",state.reading),state.reading||stream.read(0),state.resumeScheduled=!1,stream.emit("resume"),flow3(stream),state.flowing&&!state.reading&&stream.read(0)}Readable.prototype.pause=function(){return debug("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(debug("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[kPaused]=!0,this};function flow3(stream){let state=stream._readableState;for(debug("flow",state.flowing);state.flowing&&stream.read()!==null;);}Readable.prototype.wrap=function(stream){let paused=!1;stream.on("data",chunk=>{!this.push(chunk)&&stream.pause&&(paused=!0,stream.pause())}),stream.on("end",()=>{this.push(null)}),stream.on("error",err=>{errorOrDestroy(this,err)}),stream.on("close",()=>{this.destroy()}),stream.on("destroy",()=>{this.destroy()}),this._read=()=>{paused&&stream.resume&&(paused=!1,stream.resume())};let streamKeys=ObjectKeys(stream);for(let j=1;j<streamKeys.length;j++){let i2=streamKeys[j];this[i2]===void 0&&typeof stream[i2]=="function"&&(this[i2]=stream[i2].bind(stream))}return this};Readable.prototype[SymbolAsyncIterator]=function(){return streamToAsyncIterator(this)};Readable.prototype.iterator=function(options2){return options2!==void 0&&validateObject(options2,"options"),streamToAsyncIterator(this,options2)};function streamToAsyncIterator(stream,options2){typeof stream.read!="function"&&(stream=Readable.wrap(stream,{objectMode:!0}));let iter=createAsyncIterator(stream,options2);return iter.stream=stream,iter}async function*createAsyncIterator(stream,options2){let callback=nop;function next(resolve2){this===stream?(callback(),callback=nop):callback=resolve2}stream.on("readable",next);let error,cleanup=eos(stream,{writable:!1},err=>{error=err?aggregateTwoErrors(error,err):null,callback(),callback=nop});try{for(;;){let chunk=stream.destroyed?null:stream.read();if(chunk!==null)yield chunk;else{if(error)throw error;if(error===null)return;await new Promise2(next)}}}catch(err){throw error=aggregateTwoErrors(error,err),error}finally{(error||options2?.destroyOnReturn!==!1)&&(error===void 0||stream._readableState.autoDestroy)?destroyImpl.destroyer(stream,null):(stream.off("readable",next),cleanup())}}ObjectDefineProperties(Readable.prototype,{readable:{__proto__:null,get(){let r2=this._readableState;return!!r2&&r2.readable!==!1&&!r2.destroyed&&!r2.errorEmitted&&!r2.endEmitted},set(val){this._readableState&&(this._readableState.readable=!!val)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(state){this._readableState&&(this._readableState.flowing=state)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(value2){this._readableState&&(this._readableState.destroyed=value2)}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}});ObjectDefineProperties(ReadableState.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[kPaused]!==!1},set(value2){this[kPaused]=!!value2}}});Readable._fromList=fromList;function fromList(n2,state){if(state.length===0)return null;let ret;return state.objectMode?ret=state.buffer.shift():!n2||n2>=state.length?(state.decoder?ret=state.buffer.join(""):state.buffer.length===1?ret=state.buffer.first():ret=state.buffer.concat(state.length),state.buffer.clear()):ret=state.buffer.consume(n2,state.decoder),ret}function endReadable(stream){let state=stream._readableState;debug("endReadable",state.endEmitted),state.endEmitted||(state.ended=!0,process2.nextTick(endReadableNT,state,stream))}function endReadableNT(state,stream){if(debug("endReadableNT",state.endEmitted,state.length),!state.errored&&!state.closeEmitted&&!state.endEmitted&&state.length===0){if(state.endEmitted=!0,stream.emit("end"),stream.writable&&stream.allowHalfOpen===!1)process2.nextTick(endWritableNT,stream);else if(state.autoDestroy){let wState=stream._writableState;(!wState||wState.autoDestroy&&(wState.finished||wState.writable===!1))&&stream.destroy()}}}function endWritableNT(stream){stream.writable&&!stream.writableEnded&&!stream.destroyed&&stream.end()}Readable.from=function(iterable,opts){return from(Readable,iterable,opts)};var webStreamsAdapters;function lazyWebStreams(){return webStreamsAdapters===void 0&&(webStreamsAdapters={}),webStreamsAdapters}Readable.fromWeb=function(readableStream,options2){return lazyWebStreams().newStreamReadableFromReadableStream(readableStream,options2)};Readable.toWeb=function(streamReadable,options2){return lazyWebStreams().newReadableStreamFromStreamReadable(streamReadable,options2)};Readable.wrap=function(src,options2){var _ref,_src$readableObjectMo;return new Readable({objectMode:(_ref=(_src$readableObjectMo=src.readableObjectMode)!==null&&_src$readableObjectMo!==void 0?_src$readableObjectMo:src.objectMode)!==null&&_ref!==void 0?_ref:!0,...options2,destroy(err,callback){destroyImpl.destroyer(src,err),callback(err)}}).wrap(src)}}});var require_writable=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/writable.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{ArrayPrototypeSlice,Error:Error2,FunctionPrototypeSymbolHasInstance,ObjectDefineProperty,ObjectDefineProperties,ObjectSetPrototypeOf,StringPrototypeToLowerCase,Symbol:Symbol2,SymbolHasInstance}=require_primordials();module.exports=Writable;Writable.WritableState=WritableState;var{EventEmitter:EE}=require_events(),Stream=require_legacy().Stream,{Buffer:Buffer6}=require_buffer(),destroyImpl=require_destroy(),{addAbortSignal}=require_add_abort_signal(),{getHighWaterMark,getDefaultHighWaterMark}=require_state(),{ERR_INVALID_ARG_TYPE,ERR_METHOD_NOT_IMPLEMENTED,ERR_MULTIPLE_CALLBACK,ERR_STREAM_CANNOT_PIPE,ERR_STREAM_DESTROYED,ERR_STREAM_ALREADY_FINISHED,ERR_STREAM_NULL_VALUES,ERR_STREAM_WRITE_AFTER_END,ERR_UNKNOWN_ENCODING}=require_errors2().codes,{errorOrDestroy}=destroyImpl;ObjectSetPrototypeOf(Writable.prototype,Stream.prototype);ObjectSetPrototypeOf(Writable,Stream);function nop(){}var kOnFinished=Symbol2("kOnFinished");function WritableState(options2,stream,isDuplex){typeof isDuplex!="boolean"&&(isDuplex=stream instanceof require_duplex()),this.objectMode=!!(options2&&options2.objectMode),isDuplex&&(this.objectMode=this.objectMode||!!(options2&&options2.writableObjectMode)),this.highWaterMark=options2?getHighWaterMark(this,options2,"writableHighWaterMark",isDuplex):getDefaultHighWaterMark(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let noDecode=!!(options2&&options2.decodeStrings===!1);this.decodeStrings=!noDecode,this.defaultEncoding=options2&&options2.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=onwrite.bind(void 0,stream),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,resetBuffer(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!options2||options2.emitClose!==!1,this.autoDestroy=!options2||options2.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[kOnFinished]=[]}function resetBuffer(state){state.buffered=[],state.bufferedIndex=0,state.allBuffers=!0,state.allNoop=!0}WritableState.prototype.getBuffer=function(){return ArrayPrototypeSlice(this.buffered,this.bufferedIndex)};ObjectDefineProperty(WritableState.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function Writable(options2){let isDuplex=this instanceof require_duplex();if(!isDuplex&&!FunctionPrototypeSymbolHasInstance(Writable,this))return new Writable(options2);this._writableState=new WritableState(options2,this,isDuplex),options2&&(typeof options2.write=="function"&&(this._write=options2.write),typeof options2.writev=="function"&&(this._writev=options2.writev),typeof options2.destroy=="function"&&(this._destroy=options2.destroy),typeof options2.final=="function"&&(this._final=options2.final),typeof options2.construct=="function"&&(this._construct=options2.construct),options2.signal&&addAbortSignal(options2.signal,this)),Stream.call(this,options2),destroyImpl.construct(this,()=>{let state=this._writableState;state.writing||clearBuffer(this,state),finishMaybe(this,state)})}ObjectDefineProperty(Writable,SymbolHasInstance,{__proto__:null,value:function(object){return FunctionPrototypeSymbolHasInstance(this,object)?!0:this!==Writable?!1:object&&object._writableState instanceof WritableState}});Writable.prototype.pipe=function(){errorOrDestroy(this,new ERR_STREAM_CANNOT_PIPE)};function _write(stream,chunk,encoding,cb){let state=stream._writableState;if(typeof encoding=="function")cb=encoding,encoding=state.defaultEncoding;else{if(!encoding)encoding=state.defaultEncoding;else if(encoding!=="buffer"&&!Buffer6.isEncoding(encoding))throw new ERR_UNKNOWN_ENCODING(encoding);typeof cb!="function"&&(cb=nop)}if(chunk===null)throw new ERR_STREAM_NULL_VALUES;if(!state.objectMode)if(typeof chunk=="string")state.decodeStrings!==!1&&(chunk=Buffer6.from(chunk,encoding),encoding="buffer");else if(chunk instanceof Buffer6)encoding="buffer";else if(Stream._isUint8Array(chunk))chunk=Stream._uint8ArrayToBuffer(chunk),encoding="buffer";else throw new ERR_INVALID_ARG_TYPE("chunk",["string","Buffer","Uint8Array"],chunk);let err;return state.ending?err=new ERR_STREAM_WRITE_AFTER_END:state.destroyed&&(err=new ERR_STREAM_DESTROYED("write")),err?(process2.nextTick(cb,err),errorOrDestroy(stream,err,!0),err):(state.pendingcb++,writeOrBuffer(stream,state,chunk,encoding,cb))}Writable.prototype.write=function(chunk,encoding,cb){return _write(this,chunk,encoding,cb)===!0};Writable.prototype.cork=function(){this._writableState.corked++};Writable.prototype.uncork=function(){let state=this._writableState;state.corked&&(state.corked--,state.writing||clearBuffer(this,state))};Writable.prototype.setDefaultEncoding=function(encoding){if(typeof encoding=="string"&&(encoding=StringPrototypeToLowerCase(encoding)),!Buffer6.isEncoding(encoding))throw new ERR_UNKNOWN_ENCODING(encoding);return this._writableState.defaultEncoding=encoding,this};function writeOrBuffer(stream,state,chunk,encoding,callback){let len=state.objectMode?1:chunk.length;state.length+=len;let ret=state.length<state.highWaterMark;return ret||(state.needDrain=!0),state.writing||state.corked||state.errored||!state.constructed?(state.buffered.push({chunk,encoding,callback}),state.allBuffers&&encoding!=="buffer"&&(state.allBuffers=!1),state.allNoop&&callback!==nop&&(state.allNoop=!1)):(state.writelen=len,state.writecb=callback,state.writing=!0,state.sync=!0,stream._write(chunk,encoding,state.onwrite),state.sync=!1),ret&&!state.errored&&!state.destroyed}function doWrite(stream,state,writev,len,chunk,encoding,cb){state.writelen=len,state.writecb=cb,state.writing=!0,state.sync=!0,state.destroyed?state.onwrite(new ERR_STREAM_DESTROYED("write")):writev?stream._writev(chunk,state.onwrite):stream._write(chunk,encoding,state.onwrite),state.sync=!1}function onwriteError(stream,state,er2,cb){--state.pendingcb,cb(er2),errorBuffer(state),errorOrDestroy(stream,er2)}function onwrite(stream,er2){let state=stream._writableState,sync=state.sync,cb=state.writecb;if(typeof cb!="function"){errorOrDestroy(stream,new ERR_MULTIPLE_CALLBACK);return}state.writing=!1,state.writecb=null,state.length-=state.writelen,state.writelen=0,er2?(er2.stack,state.errored||(state.errored=er2),stream._readableState&&!stream._readableState.errored&&(stream._readableState.errored=er2),sync?process2.nextTick(onwriteError,stream,state,er2,cb):onwriteError(stream,state,er2,cb)):(state.buffered.length>state.bufferedIndex&&clearBuffer(stream,state),sync?state.afterWriteTickInfo!==null&&state.afterWriteTickInfo.cb===cb?state.afterWriteTickInfo.count++:(state.afterWriteTickInfo={count:1,cb,stream,state},process2.nextTick(afterWriteTick,state.afterWriteTickInfo)):afterWrite(stream,state,1,cb))}function afterWriteTick({stream,state,count,cb}){return state.afterWriteTickInfo=null,afterWrite(stream,state,count,cb)}function afterWrite(stream,state,count,cb){for(!state.ending&&!stream.destroyed&&state.length===0&&state.needDrain&&(state.needDrain=!1,stream.emit("drain"));count-- >0;)state.pendingcb--,cb();state.destroyed&&errorBuffer(state),finishMaybe(stream,state)}function errorBuffer(state){if(state.writing)return;for(let n2=state.bufferedIndex;n2<state.buffered.length;++n2){var _state$errored;let{chunk,callback}=state.buffered[n2],len=state.objectMode?1:chunk.length;state.length-=len,callback((_state$errored=state.errored)!==null&&_state$errored!==void 0?_state$errored:new ERR_STREAM_DESTROYED("write"))}let onfinishCallbacks=state[kOnFinished].splice(0);for(let i2=0;i2<onfinishCallbacks.length;i2++){var _state$errored2;onfinishCallbacks[i2]((_state$errored2=state.errored)!==null&&_state$errored2!==void 0?_state$errored2:new ERR_STREAM_DESTROYED("end"))}resetBuffer(state)}function clearBuffer(stream,state){if(state.corked||state.bufferProcessing||state.destroyed||!state.constructed)return;let{buffered,bufferedIndex,objectMode}=state,bufferedLength=buffered.length-bufferedIndex;if(!bufferedLength)return;let i2=bufferedIndex;if(state.bufferProcessing=!0,bufferedLength>1&&stream._writev){state.pendingcb-=bufferedLength-1;let callback=state.allNoop?nop:err=>{for(let n2=i2;n2<buffered.length;++n2)buffered[n2].callback(err)},chunks=state.allNoop&&i2===0?buffered:ArrayPrototypeSlice(buffered,i2);chunks.allBuffers=state.allBuffers,doWrite(stream,state,!0,state.length,chunks,"",callback),resetBuffer(state)}else{do{let{chunk,encoding,callback}=buffered[i2];buffered[i2++]=null;let len=objectMode?1:chunk.length;doWrite(stream,state,!1,len,chunk,encoding,callback)}while(i2<buffered.length&&!state.writing);i2===buffered.length?resetBuffer(state):i2>256?(buffered.splice(0,i2),state.bufferedIndex=0):state.bufferedIndex=i2}state.bufferProcessing=!1}Writable.prototype._write=function(chunk,encoding,cb){if(this._writev)this._writev([{chunk,encoding}],cb);else throw new ERR_METHOD_NOT_IMPLEMENTED("_write()")};Writable.prototype._writev=null;Writable.prototype.end=function(chunk,encoding,cb){let state=this._writableState;typeof chunk=="function"?(cb=chunk,chunk=null,encoding=null):typeof encoding=="function"&&(cb=encoding,encoding=null);let err;if(chunk!=null){let ret=_write(this,chunk,encoding);ret instanceof Error2&&(err=ret)}return state.corked&&(state.corked=1,this.uncork()),err||(!state.errored&&!state.ending?(state.ending=!0,finishMaybe(this,state,!0),state.ended=!0):state.finished?err=new ERR_STREAM_ALREADY_FINISHED("end"):state.destroyed&&(err=new ERR_STREAM_DESTROYED("end"))),typeof cb=="function"&&(err||state.finished?process2.nextTick(cb,err):state[kOnFinished].push(cb)),this};function needFinish(state){return state.ending&&!state.destroyed&&state.constructed&&state.length===0&&!state.errored&&state.buffered.length===0&&!state.finished&&!state.writing&&!state.errorEmitted&&!state.closeEmitted}function callFinal(stream,state){let called=!1;function onFinish(err){if(called){errorOrDestroy(stream,err??ERR_MULTIPLE_CALLBACK());return}if(called=!0,state.pendingcb--,err){let onfinishCallbacks=state[kOnFinished].splice(0);for(let i2=0;i2<onfinishCallbacks.length;i2++)onfinishCallbacks[i2](err);errorOrDestroy(stream,err,state.sync)}else needFinish(state)&&(state.prefinished=!0,stream.emit("prefinish"),state.pendingcb++,process2.nextTick(finish,stream,state))}state.sync=!0,state.pendingcb++;try{stream._final(onFinish)}catch(err){onFinish(err)}state.sync=!1}function prefinish(stream,state){!state.prefinished&&!state.finalCalled&&(typeof stream._final=="function"&&!state.destroyed?(state.finalCalled=!0,callFinal(stream,state)):(state.prefinished=!0,stream.emit("prefinish")))}function finishMaybe(stream,state,sync){needFinish(state)&&(prefinish(stream,state),state.pendingcb===0&&(sync?(state.pendingcb++,process2.nextTick((stream2,state2)=>{needFinish(state2)?finish(stream2,state2):state2.pendingcb--},stream,state)):needFinish(state)&&(state.pendingcb++,finish(stream,state))))}function finish(stream,state){state.pendingcb--,state.finished=!0;let onfinishCallbacks=state[kOnFinished].splice(0);for(let i2=0;i2<onfinishCallbacks.length;i2++)onfinishCallbacks[i2]();if(stream.emit("finish"),state.autoDestroy){let rState=stream._readableState;(!rState||rState.autoDestroy&&(rState.endEmitted||rState.readable===!1))&&stream.destroy()}}ObjectDefineProperties(Writable.prototype,{closed:{__proto__:null,get(){return this._writableState?this._writableState.closed:!1}},destroyed:{__proto__:null,get(){return this._writableState?this._writableState.destroyed:!1},set(value2){this._writableState&&(this._writableState.destroyed=value2)}},writable:{__proto__:null,get(){let w2=this._writableState;return!!w2&&w2.writable!==!1&&!w2.destroyed&&!w2.errored&&!w2.ending&&!w2.ended},set(val){this._writableState&&(this._writableState.writable=!!val)}},writableFinished:{__proto__:null,get(){return this._writableState?this._writableState.finished:!1}},writableObjectMode:{__proto__:null,get(){return this._writableState?this._writableState.objectMode:!1}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return this._writableState?this._writableState.ending:!1}},writableNeedDrain:{__proto__:null,get(){let wState=this._writableState;return wState?!wState.destroyed&&!wState.ending&&wState.needDrain:!1}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._writableState.writable!==!1&&(this._writableState.destroyed||this._writableState.errored)&&!this._writableState.finished)}}});var destroy=destroyImpl.destroy;Writable.prototype.destroy=function(err,cb){let state=this._writableState;return!state.destroyed&&(state.bufferedIndex<state.buffered.length||state[kOnFinished].length)&&process2.nextTick(errorBuffer,state),destroy.call(this,err,cb),this};Writable.prototype._undestroy=destroyImpl.undestroy;Writable.prototype._destroy=function(err,cb){cb(err)};Writable.prototype[EE.captureRejectionSymbol]=function(err){this.destroy(err)};var webStreamsAdapters;function lazyWebStreams(){return webStreamsAdapters===void 0&&(webStreamsAdapters={}),webStreamsAdapters}Writable.fromWeb=function(writableStream,options2){return lazyWebStreams().newStreamWritableFromWritableStream(writableStream,options2)};Writable.toWeb=function(streamWritable){return lazyWebStreams().newWritableStreamFromStreamWritable(streamWritable)}}});var require_duplexify=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/duplexify.js"(exports,module){init_browser_globals();var process2=require_process2(),bufferModule=require_buffer(),{isReadable,isWritable,isIterable,isNodeStream,isReadableNodeStream,isWritableNodeStream,isDuplexNodeStream,isReadableStream,isWritableStream}=require_utils(),eos=require_end_of_stream(),{AbortError,codes:{ERR_INVALID_ARG_TYPE,ERR_INVALID_RETURN_VALUE}}=require_errors2(),{destroyer}=require_destroy(),Duplex=require_duplex(),Readable=require_readable(),Writable=require_writable(),{createDeferredPromise}=require_util3(),from=require_from(),Blob2=globalThis.Blob||bufferModule.Blob,isBlob=typeof Blob2<"u"?function(b2){return b2 instanceof Blob2}:function(b2){return!1},AbortController2=globalThis.AbortController||require_browser2().AbortController,{FunctionPrototypeCall}=require_primordials(),Duplexify=class extends Duplex{constructor(options2){super(options2),options2?.readable===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),options2?.writable===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}};module.exports=function duplexify(body,name){if(isDuplexNodeStream(body))return body;if(isReadableNodeStream(body))return _duplexify({readable:body});if(isWritableNodeStream(body))return _duplexify({writable:body});if(isNodeStream(body))return _duplexify({writable:!1,readable:!1});if(isReadableStream(body))return _duplexify({readable:Readable.fromWeb(body)});if(isWritableStream(body))return _duplexify({writable:Writable.fromWeb(body)});if(typeof body=="function"){let{value:value2,write,final,destroy}=fromAsyncGen(body);if(isIterable(value2))return from(Duplexify,value2,{objectMode:!0,write,final,destroy});let then2=value2?.then;if(typeof then2=="function"){let d2,promise=FunctionPrototypeCall(then2,value2,val=>{if(val!=null)throw new ERR_INVALID_RETURN_VALUE("nully","body",val)},err=>{destroyer(d2,err)});return d2=new Duplexify({objectMode:!0,readable:!1,write,final(cb){final(async()=>{try{await promise,process2.nextTick(cb,null)}catch(err){process2.nextTick(cb,err)}})},destroy})}throw new ERR_INVALID_RETURN_VALUE("Iterable, AsyncIterable or AsyncFunction",name,value2)}if(isBlob(body))return duplexify(body.arrayBuffer());if(isIterable(body))return from(Duplexify,body,{objectMode:!0,writable:!1});if(isReadableStream(body?.readable)&&isWritableStream(body?.writable))return Duplexify.fromWeb(body);if(typeof body?.writable=="object"||typeof body?.readable=="object"){let readable=body!=null&&body.readable?isReadableNodeStream(body?.readable)?body?.readable:duplexify(body.readable):void 0,writable=body!=null&&body.writable?isWritableNodeStream(body?.writable)?body?.writable:duplexify(body.writable):void 0;return _duplexify({readable,writable})}let then=body?.then;if(typeof then=="function"){let d2;return FunctionPrototypeCall(then,body,val=>{val!=null&&d2.push(val),d2.push(null)},err=>{destroyer(d2,err)}),d2=new Duplexify({objectMode:!0,writable:!1,read(){}})}throw new ERR_INVALID_ARG_TYPE(name,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],body)};function fromAsyncGen(fn2){let{promise,resolve:resolve2}=createDeferredPromise(),ac=new AbortController2,signal=ac.signal;return{value:fn2((async function*(){for(;;){let _promise=promise;promise=null;let{chunk,done,cb}=await _promise;if(process2.nextTick(cb),done)return;if(signal.aborted)throw new AbortError(void 0,{cause:signal.reason});({promise,resolve:resolve2}=createDeferredPromise()),yield chunk}})(),{signal}),write(chunk,encoding,cb){let _resolve=resolve2;resolve2=null,_resolve({chunk,done:!1,cb})},final(cb){let _resolve=resolve2;resolve2=null,_resolve({done:!0,cb})},destroy(err,cb){ac.abort(),cb(err)}}}function _duplexify(pair2){let r2=pair2.readable&&typeof pair2.readable.read!="function"?Readable.wrap(pair2.readable):pair2.readable,w2=pair2.writable,readable=!!isReadable(r2),writable=!!isWritable(w2),ondrain,onfinish,onreadable,onclose,d2;function onfinished(err){let cb=onclose;onclose=null,cb?cb(err):err&&d2.destroy(err)}return d2=new Duplexify({readableObjectMode:!!(r2!=null&&r2.readableObjectMode),writableObjectMode:!!(w2!=null&&w2.writableObjectMode),readable,writable}),writable&&(eos(w2,err=>{writable=!1,err&&destroyer(r2,err),onfinished(err)}),d2._write=function(chunk,encoding,callback){w2.write(chunk,encoding)?callback():ondrain=callback},d2._final=function(callback){w2.end(),onfinish=callback},w2.on("drain",function(){if(ondrain){let cb=ondrain;ondrain=null,cb()}}),w2.on("finish",function(){if(onfinish){let cb=onfinish;onfinish=null,cb()}})),readable&&(eos(r2,err=>{readable=!1,err&&destroyer(r2,err),onfinished(err)}),r2.on("readable",function(){if(onreadable){let cb=onreadable;onreadable=null,cb()}}),r2.on("end",function(){d2.push(null)}),d2._read=function(){for(;;){let buf=r2.read();if(buf===null){onreadable=d2._read;return}if(!d2.push(buf))return}}),d2._destroy=function(err,callback){!err&&onclose!==null&&(err=new AbortError),onreadable=null,ondrain=null,onfinish=null,onclose===null?callback(err):(onclose=callback,destroyer(w2,err),destroyer(r2,err))},d2}}});var require_duplex=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/duplex.js"(exports,module){"use strict";init_browser_globals();var{ObjectDefineProperties,ObjectGetOwnPropertyDescriptor,ObjectKeys,ObjectSetPrototypeOf}=require_primordials();module.exports=Duplex;var Readable=require_readable(),Writable=require_writable();ObjectSetPrototypeOf(Duplex.prototype,Readable.prototype);ObjectSetPrototypeOf(Duplex,Readable);{let keys=ObjectKeys(Writable.prototype);for(let i2=0;i2<keys.length;i2++){let method=keys[i2];Duplex.prototype[method]||(Duplex.prototype[method]=Writable.prototype[method])}}function Duplex(options2){if(!(this instanceof Duplex))return new Duplex(options2);Readable.call(this,options2),Writable.call(this,options2),options2?(this.allowHalfOpen=options2.allowHalfOpen!==!1,options2.readable===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),options2.writable===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)):this.allowHalfOpen=!0}ObjectDefineProperties(Duplex.prototype,{writable:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writable")},writableHighWaterMark:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableBuffer")},writableLength:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableLength")},writableFinished:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableFinished")},writableCorked:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableCorked")},writableEnded:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set(value2){this._readableState&&this._writableState&&(this._readableState.destroyed=value2,this._writableState.destroyed=value2)}}});var webStreamsAdapters;function lazyWebStreams(){return webStreamsAdapters===void 0&&(webStreamsAdapters={}),webStreamsAdapters}Duplex.fromWeb=function(pair2,options2){return lazyWebStreams().newStreamDuplexFromReadableWritablePair(pair2,options2)};Duplex.toWeb=function(duplex){return lazyWebStreams().newReadableWritablePairFromDuplex(duplex)};var duplexify;Duplex.from=function(body){return duplexify||(duplexify=require_duplexify()),duplexify(body,"body")}}});var require_transform=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/transform.js"(exports,module){"use strict";init_browser_globals();var{ObjectSetPrototypeOf,Symbol:Symbol2}=require_primordials();module.exports=Transform;var{ERR_METHOD_NOT_IMPLEMENTED}=require_errors2().codes,Duplex=require_duplex(),{getHighWaterMark}=require_state();ObjectSetPrototypeOf(Transform.prototype,Duplex.prototype);ObjectSetPrototypeOf(Transform,Duplex);var kCallback=Symbol2("kCallback");function Transform(options2){if(!(this instanceof Transform))return new Transform(options2);let readableHighWaterMark=options2?getHighWaterMark(this,options2,"readableHighWaterMark",!0):null;readableHighWaterMark===0&&(options2={...options2,highWaterMark:null,readableHighWaterMark,writableHighWaterMark:options2.writableHighWaterMark||0}),Duplex.call(this,options2),this._readableState.sync=!1,this[kCallback]=null,options2&&(typeof options2.transform=="function"&&(this._transform=options2.transform),typeof options2.flush=="function"&&(this._flush=options2.flush)),this.on("prefinish",prefinish)}function final(cb){typeof this._flush=="function"&&!this.destroyed?this._flush((er2,data)=>{if(er2){cb?cb(er2):this.destroy(er2);return}data!=null&&this.push(data),this.push(null),cb&&cb()}):(this.push(null),cb&&cb())}function prefinish(){this._final!==final&&final.call(this)}Transform.prototype._final=final;Transform.prototype._transform=function(chunk,encoding,callback){throw new ERR_METHOD_NOT_IMPLEMENTED("_transform()")};Transform.prototype._write=function(chunk,encoding,callback){let rState=this._readableState,wState=this._writableState,length=rState.length;this._transform(chunk,encoding,(err,val)=>{if(err){callback(err);return}val!=null&&this.push(val),wState.ended||length===rState.length||rState.length<rState.highWaterMark?callback():this[kCallback]=callback})};Transform.prototype._read=function(){if(this[kCallback]){let callback=this[kCallback];this[kCallback]=null,callback()}}}});var require_passthrough=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/passthrough.js"(exports,module){"use strict";init_browser_globals();var{ObjectSetPrototypeOf}=require_primordials();module.exports=PassThrough;var Transform=require_transform();ObjectSetPrototypeOf(PassThrough.prototype,Transform.prototype);ObjectSetPrototypeOf(PassThrough,Transform);function PassThrough(options2){if(!(this instanceof PassThrough))return new PassThrough(options2);Transform.call(this,options2)}PassThrough.prototype._transform=function(chunk,encoding,cb){cb(null,chunk)}}});var require_pipeline=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/pipeline.js"(exports,module){init_browser_globals();var process2=require_process2(),{ArrayIsArray,Promise:Promise2,SymbolAsyncIterator,SymbolDispose}=require_primordials(),eos=require_end_of_stream(),{once}=require_util3(),destroyImpl=require_destroy(),Duplex=require_duplex(),{aggregateTwoErrors,codes:{ERR_INVALID_ARG_TYPE,ERR_INVALID_RETURN_VALUE,ERR_MISSING_ARGS,ERR_STREAM_DESTROYED,ERR_STREAM_PREMATURE_CLOSE},AbortError}=require_errors2(),{validateFunction,validateAbortSignal}=require_validators2(),{isIterable,isReadable,isReadableNodeStream,isNodeStream,isTransformStream,isWebStream,isReadableStream,isReadableFinished}=require_utils(),AbortController2=globalThis.AbortController||require_browser2().AbortController,PassThrough,Readable,addAbortListener;function destroyer(stream,reading,writing){let finished=!1;stream.on("close",()=>{finished=!0});let cleanup=eos(stream,{readable:reading,writable:writing},err=>{finished=!err});return{destroy:err=>{finished||(finished=!0,destroyImpl.destroyer(stream,err||new ERR_STREAM_DESTROYED("pipe")))},cleanup}}function popCallback(streams){return validateFunction(streams[streams.length-1],"streams[stream.length - 1]"),streams.pop()}function makeAsyncIterable(val){if(isIterable(val))return val;if(isReadableNodeStream(val))return fromReadable(val);throw new ERR_INVALID_ARG_TYPE("val",["Readable","Iterable","AsyncIterable"],val)}async function*fromReadable(val){Readable||(Readable=require_readable()),yield*Readable.prototype[SymbolAsyncIterator].call(val)}async function pumpToNode(iterable,writable,finish,{end}){let error,onresolve=null,resume=err=>{if(err&&(error=err),onresolve){let callback=onresolve;onresolve=null,callback()}},wait=()=>new Promise2((resolve2,reject)=>{error?reject(error):onresolve=()=>{error?reject(error):resolve2()}});writable.on("drain",resume);let cleanup=eos(writable,{readable:!1},resume);try{writable.writableNeedDrain&&await wait();for await(let chunk of iterable)writable.write(chunk)||await wait();end&&(writable.end(),await wait()),finish()}catch(err){finish(error!==err?aggregateTwoErrors(error,err):err)}finally{cleanup(),writable.off("drain",resume)}}async function pumpToWeb(readable,writable,finish,{end}){isTransformStream(writable)&&(writable=writable.writable);let writer=writable.getWriter();try{for await(let chunk of readable)await writer.ready,writer.write(chunk).catch(()=>{});await writer.ready,end&&await writer.close(),finish()}catch(err){try{await writer.abort(err),finish(err)}catch(err2){finish(err2)}}}function pipeline(...streams){return pipelineImpl(streams,once(popCallback(streams)))}function pipelineImpl(streams,callback,opts){if(streams.length===1&&ArrayIsArray(streams[0])&&(streams=streams[0]),streams.length<2)throw new ERR_MISSING_ARGS("streams");let ac=new AbortController2,signal=ac.signal,outerSignal=opts?.signal,lastStreamCleanup=[];validateAbortSignal(outerSignal,"options.signal");function abort(){finishImpl(new AbortError)}addAbortListener=addAbortListener||require_util3().addAbortListener;let disposable;outerSignal&&(disposable=addAbortListener(outerSignal,abort));let error,value2,destroys=[],finishCount=0;function finish(err){finishImpl(err,--finishCount===0)}function finishImpl(err,final){var _disposable;if(err&&(!error||error.code==="ERR_STREAM_PREMATURE_CLOSE")&&(error=err),!(!error&&!final)){for(;destroys.length;)destroys.shift()(error);(_disposable=disposable)===null||_disposable===void 0||_disposable[SymbolDispose](),ac.abort(),final&&(error||lastStreamCleanup.forEach(fn2=>fn2()),process2.nextTick(callback,error,value2))}}let ret;for(let i2=0;i2<streams.length;i2++){let stream=streams[i2],reading=i2<streams.length-1,writing=i2>0,end=reading||opts?.end!==!1,isLastStream=i2===streams.length-1;if(isNodeStream(stream)){let onError2=function(err){err&&err.name!=="AbortError"&&err.code!=="ERR_STREAM_PREMATURE_CLOSE"&&finish(err)};var onError=onError2;if(end){let{destroy,cleanup}=destroyer(stream,reading,writing);destroys.push(destroy),isReadable(stream)&&isLastStream&&lastStreamCleanup.push(cleanup)}stream.on("error",onError2),isReadable(stream)&&isLastStream&&lastStreamCleanup.push(()=>{stream.removeListener("error",onError2)})}if(i2===0)if(typeof stream=="function"){if(ret=stream({signal}),!isIterable(ret))throw new ERR_INVALID_RETURN_VALUE("Iterable, AsyncIterable or Stream","source",ret)}else isIterable(stream)||isReadableNodeStream(stream)||isTransformStream(stream)?ret=stream:ret=Duplex.from(stream);else if(typeof stream=="function"){if(isTransformStream(ret)){var _ret;ret=makeAsyncIterable((_ret=ret)===null||_ret===void 0?void 0:_ret.readable)}else ret=makeAsyncIterable(ret);if(ret=stream(ret,{signal}),reading){if(!isIterable(ret,!0))throw new ERR_INVALID_RETURN_VALUE("AsyncIterable",`transform[${i2-1}]`,ret)}else{var _ret2;PassThrough||(PassThrough=require_passthrough());let pt2=new PassThrough({objectMode:!0}),then=(_ret2=ret)===null||_ret2===void 0?void 0:_ret2.then;if(typeof then=="function")finishCount++,then.call(ret,val=>{value2=val,val!=null&&pt2.write(val),end&&pt2.end(),process2.nextTick(finish)},err=>{pt2.destroy(err),process2.nextTick(finish,err)});else if(isIterable(ret,!0))finishCount++,pumpToNode(ret,pt2,finish,{end});else if(isReadableStream(ret)||isTransformStream(ret)){let toRead=ret.readable||ret;finishCount++,pumpToNode(toRead,pt2,finish,{end})}else throw new ERR_INVALID_RETURN_VALUE("AsyncIterable or Promise","destination",ret);ret=pt2;let{destroy,cleanup}=destroyer(ret,!1,!0);destroys.push(destroy),isLastStream&&lastStreamCleanup.push(cleanup)}}else if(isNodeStream(stream)){if(isReadableNodeStream(ret)){finishCount+=2;let cleanup=pipe(ret,stream,finish,{end});isReadable(stream)&&isLastStream&&lastStreamCleanup.push(cleanup)}else if(isTransformStream(ret)||isReadableStream(ret)){let toRead=ret.readable||ret;finishCount++,pumpToNode(toRead,stream,finish,{end})}else if(isIterable(ret))finishCount++,pumpToNode(ret,stream,finish,{end});else throw new ERR_INVALID_ARG_TYPE("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],ret);ret=stream}else if(isWebStream(stream)){if(isReadableNodeStream(ret))finishCount++,pumpToWeb(makeAsyncIterable(ret),stream,finish,{end});else if(isReadableStream(ret)||isIterable(ret))finishCount++,pumpToWeb(ret,stream,finish,{end});else if(isTransformStream(ret))finishCount++,pumpToWeb(ret.readable,stream,finish,{end});else throw new ERR_INVALID_ARG_TYPE("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],ret);ret=stream}else ret=Duplex.from(stream)}return(signal!=null&&signal.aborted||outerSignal!=null&&outerSignal.aborted)&&process2.nextTick(abort),ret}function pipe(src,dst,finish,{end}){let ended=!1;if(dst.on("close",()=>{ended||finish(new ERR_STREAM_PREMATURE_CLOSE)}),src.pipe(dst,{end:!1}),end){let endFn2=function(){ended=!0,dst.end()};var endFn=endFn2;isReadableFinished(src)?process2.nextTick(endFn2):src.once("end",endFn2)}else finish();return eos(src,{readable:!0,writable:!1},err=>{let rState=src._readableState;err&&err.code==="ERR_STREAM_PREMATURE_CLOSE"&&rState&&rState.ended&&!rState.errored&&!rState.errorEmitted?src.once("end",finish).once("error",finish):finish(err)}),eos(dst,{readable:!1,writable:!0},finish)}module.exports={pipelineImpl,pipeline}}});var require_compose=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/compose.js"(exports,module){"use strict";init_browser_globals();var{pipeline}=require_pipeline(),Duplex=require_duplex(),{destroyer}=require_destroy(),{isNodeStream,isReadable,isWritable,isWebStream,isTransformStream,isWritableStream,isReadableStream}=require_utils(),{AbortError,codes:{ERR_INVALID_ARG_VALUE,ERR_MISSING_ARGS}}=require_errors2(),eos=require_end_of_stream();module.exports=function(...streams){if(streams.length===0)throw new ERR_MISSING_ARGS("streams");if(streams.length===1)return Duplex.from(streams[0]);let orgStreams=[...streams];if(typeof streams[0]=="function"&&(streams[0]=Duplex.from(streams[0])),typeof streams[streams.length-1]=="function"){let idx=streams.length-1;streams[idx]=Duplex.from(streams[idx])}for(let n2=0;n2<streams.length;++n2)if(!(!isNodeStream(streams[n2])&&!isWebStream(streams[n2]))){if(n2<streams.length-1&&!(isReadable(streams[n2])||isReadableStream(streams[n2])||isTransformStream(streams[n2])))throw new ERR_INVALID_ARG_VALUE(`streams[${n2}]`,orgStreams[n2],"must be readable");if(n2>0&&!(isWritable(streams[n2])||isWritableStream(streams[n2])||isTransformStream(streams[n2])))throw new ERR_INVALID_ARG_VALUE(`streams[${n2}]`,orgStreams[n2],"must be writable")}let ondrain,onfinish,onreadable,onclose,d2;function onfinished(err){let cb=onclose;onclose=null,cb?cb(err):err?d2.destroy(err):!readable&&!writable&&d2.destroy()}let head=streams[0],tail=pipeline(streams,onfinished),writable=!!(isWritable(head)||isWritableStream(head)||isTransformStream(head)),readable=!!(isReadable(tail)||isReadableStream(tail)||isTransformStream(tail));if(d2=new Duplex({writableObjectMode:!!(head!=null&&head.writableObjectMode),readableObjectMode:!!(tail!=null&&tail.readableObjectMode),writable,readable}),writable){if(isNodeStream(head))d2._write=function(chunk,encoding,callback){head.write(chunk,encoding)?callback():ondrain=callback},d2._final=function(callback){head.end(),onfinish=callback},head.on("drain",function(){if(ondrain){let cb=ondrain;ondrain=null,cb()}});else if(isWebStream(head)){let writer=(isTransformStream(head)?head.writable:head).getWriter();d2._write=async function(chunk,encoding,callback){try{await writer.ready,writer.write(chunk).catch(()=>{}),callback()}catch(err){callback(err)}},d2._final=async function(callback){try{await writer.ready,writer.close().catch(()=>{}),onfinish=callback}catch(err){callback(err)}}}let toRead=isTransformStream(tail)?tail.readable:tail;eos(toRead,()=>{if(onfinish){let cb=onfinish;onfinish=null,cb()}})}if(readable){if(isNodeStream(tail))tail.on("readable",function(){if(onreadable){let cb=onreadable;onreadable=null,cb()}}),tail.on("end",function(){d2.push(null)}),d2._read=function(){for(;;){let buf=tail.read();if(buf===null){onreadable=d2._read;return}if(!d2.push(buf))return}};else if(isWebStream(tail)){let reader=(isTransformStream(tail)?tail.readable:tail).getReader();d2._read=async function(){for(;;)try{let{value:value2,done}=await reader.read();if(!d2.push(value2))return;if(done){d2.push(null);return}}catch{return}}}}return d2._destroy=function(err,callback){!err&&onclose!==null&&(err=new AbortError),onreadable=null,ondrain=null,onfinish=null,onclose===null?callback(err):(onclose=callback,isNodeStream(tail)&&destroyer(tail,err))},d2}}});var require_operators=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/operators.js"(exports,module){"use strict";init_browser_globals();var AbortController2=globalThis.AbortController||require_browser2().AbortController,{codes:{ERR_INVALID_ARG_VALUE,ERR_INVALID_ARG_TYPE,ERR_MISSING_ARGS,ERR_OUT_OF_RANGE},AbortError}=require_errors2(),{validateAbortSignal,validateInteger,validateObject}=require_validators2(),kWeakHandler=require_primordials().Symbol("kWeak"),kResistStopPropagation=require_primordials().Symbol("kResistStopPropagation"),{finished}=require_end_of_stream(),staticCompose=require_compose(),{addAbortSignalNoValidate}=require_add_abort_signal(),{isWritable,isNodeStream}=require_utils(),{deprecate}=require_util3(),{ArrayPrototypePush,Boolean:Boolean2,MathFloor,Number:Number2,NumberIsNaN,Promise:Promise2,PromiseReject,PromiseResolve,PromisePrototypeThen,Symbol:Symbol2}=require_primordials(),kEmpty=Symbol2("kEmpty"),kEof=Symbol2("kEof");function compose(stream,options2){if(options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal"),isNodeStream(stream)&&!isWritable(stream))throw new ERR_INVALID_ARG_VALUE("stream",stream,"must be writable");let composedStream=staticCompose(this,stream);return options2!=null&&options2.signal&&addAbortSignalNoValidate(options2.signal,composedStream),composedStream}function map5(fn2,options2){if(typeof fn2!="function")throw new ERR_INVALID_ARG_TYPE("fn",["Function","AsyncFunction"],fn2);options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal");let concurrency=1;options2?.concurrency!=null&&(concurrency=MathFloor(options2.concurrency));let highWaterMark=concurrency-1;return options2?.highWaterMark!=null&&(highWaterMark=MathFloor(options2.highWaterMark)),validateInteger(concurrency,"options.concurrency",1),validateInteger(highWaterMark,"options.highWaterMark",0),highWaterMark+=concurrency,async function*(){let signal=require_util3().AbortSignalAny([options2?.signal].filter(Boolean2)),stream=this,queue2=[],signalOpt={signal},next,resume,done=!1,cnt=0;function onCatch(){done=!0,afterItemProcessed()}function afterItemProcessed(){cnt-=1,maybeResume()}function maybeResume(){resume&&!done&&cnt<concurrency&&queue2.length<highWaterMark&&(resume(),resume=null)}async function pump(){try{for await(let val of stream){if(done)return;if(signal.aborted)throw new AbortError;try{if(val=fn2(val,signalOpt),val===kEmpty)continue;val=PromiseResolve(val)}catch(err){val=PromiseReject(err)}cnt+=1,PromisePrototypeThen(val,afterItemProcessed,onCatch),queue2.push(val),next&&(next(),next=null),!done&&(queue2.length>=highWaterMark||cnt>=concurrency)&&await new Promise2(resolve2=>{resume=resolve2})}queue2.push(kEof)}catch(err){let val=PromiseReject(err);PromisePrototypeThen(val,afterItemProcessed,onCatch),queue2.push(val)}finally{done=!0,next&&(next(),next=null)}}pump();try{for(;;){for(;queue2.length>0;){let val=await queue2[0];if(val===kEof)return;if(signal.aborted)throw new AbortError;val!==kEmpty&&(yield val),queue2.shift(),maybeResume()}await new Promise2(resolve2=>{next=resolve2})}}finally{done=!0,resume&&(resume(),resume=null)}}.call(this)}function asIndexedPairs(options2=void 0){return options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal"),async function*(){let index4=0;for await(let val of this){var _options$signal;if(options2!=null&&(_options$signal=options2.signal)!==null&&_options$signal!==void 0&&_options$signal.aborted)throw new AbortError({cause:options2.signal.reason});yield[index4++,val]}}.call(this)}async function some(fn2,options2=void 0){for await(let unused of filter.call(this,fn2,options2))return!0;return!1}async function every(fn2,options2=void 0){if(typeof fn2!="function")throw new ERR_INVALID_ARG_TYPE("fn",["Function","AsyncFunction"],fn2);return!await some.call(this,async(...args)=>!await fn2(...args),options2)}async function find(fn2,options2){for await(let result of filter.call(this,fn2,options2))return result}async function forEach(fn2,options2){if(typeof fn2!="function")throw new ERR_INVALID_ARG_TYPE("fn",["Function","AsyncFunction"],fn2);async function forEachFn(value2,options3){return await fn2(value2,options3),kEmpty}for await(let unused of map5.call(this,forEachFn,options2));}function filter(fn2,options2){if(typeof fn2!="function")throw new ERR_INVALID_ARG_TYPE("fn",["Function","AsyncFunction"],fn2);async function filterFn(value2,options3){return await fn2(value2,options3)?value2:kEmpty}return map5.call(this,filterFn,options2)}var ReduceAwareErrMissingArgs=class extends ERR_MISSING_ARGS{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}};async function reduce(reducer,initialValue,options2){var _options$signal2;if(typeof reducer!="function")throw new ERR_INVALID_ARG_TYPE("reducer",["Function","AsyncFunction"],reducer);options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal");let hasInitialValue=arguments.length>1;if(options2!=null&&(_options$signal2=options2.signal)!==null&&_options$signal2!==void 0&&_options$signal2.aborted){let err=new AbortError(void 0,{cause:options2.signal.reason});throw this.once("error",()=>{}),await finished(this.destroy(err)),err}let ac=new AbortController2,signal=ac.signal;if(options2!=null&&options2.signal){let opts={once:!0,[kWeakHandler]:this,[kResistStopPropagation]:!0};options2.signal.addEventListener("abort",()=>ac.abort(),opts)}let gotAnyItemFromStream=!1;try{for await(let value2 of this){var _options$signal3;if(gotAnyItemFromStream=!0,options2!=null&&(_options$signal3=options2.signal)!==null&&_options$signal3!==void 0&&_options$signal3.aborted)throw new AbortError;hasInitialValue?initialValue=await reducer(initialValue,value2,{signal}):(initialValue=value2,hasInitialValue=!0)}if(!gotAnyItemFromStream&&!hasInitialValue)throw new ReduceAwareErrMissingArgs}finally{ac.abort()}return initialValue}async function toArray(options2){options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal");let result=[];for await(let val of this){var _options$signal4;if(options2!=null&&(_options$signal4=options2.signal)!==null&&_options$signal4!==void 0&&_options$signal4.aborted)throw new AbortError(void 0,{cause:options2.signal.reason});ArrayPrototypePush(result,val)}return result}function flatMap(fn2,options2){let values=map5.call(this,fn2,options2);return async function*(){for await(let val of values)yield*val}.call(this)}function toIntegerOrInfinity(number){if(number=Number2(number),NumberIsNaN(number))return 0;if(number<0)throw new ERR_OUT_OF_RANGE("number",">= 0",number);return number}function drop(number,options2=void 0){return options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal"),number=toIntegerOrInfinity(number),async function*(){var _options$signal5;if(options2!=null&&(_options$signal5=options2.signal)!==null&&_options$signal5!==void 0&&_options$signal5.aborted)throw new AbortError;for await(let val of this){var _options$signal6;if(options2!=null&&(_options$signal6=options2.signal)!==null&&_options$signal6!==void 0&&_options$signal6.aborted)throw new AbortError;number--<=0&&(yield val)}}.call(this)}function take(number,options2=void 0){return options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal"),number=toIntegerOrInfinity(number),async function*(){var _options$signal7;if(options2!=null&&(_options$signal7=options2.signal)!==null&&_options$signal7!==void 0&&_options$signal7.aborted)throw new AbortError;for await(let val of this){var _options$signal8;if(options2!=null&&(_options$signal8=options2.signal)!==null&&_options$signal8!==void 0&&_options$signal8.aborted)throw new AbortError;if(number-- >0&&(yield val),number<=0)return}}.call(this)}module.exports.streamReturningOperators={asIndexedPairs:deprecate(asIndexedPairs,"readable.asIndexedPairs will be removed in a future version."),drop,filter,flatMap,map:map5,take,compose};module.exports.promiseReturningOperators={every,forEach,reduce,toArray,some,find}}});var require_promises=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/stream/promises.js"(exports,module){"use strict";init_browser_globals();var{ArrayPrototypePop,Promise:Promise2}=require_primordials(),{isIterable,isNodeStream,isWebStream}=require_utils(),{pipelineImpl:pl}=require_pipeline(),{finished}=require_end_of_stream();require_stream();function pipeline(...streams){return new Promise2((resolve2,reject)=>{let signal,end,lastArg=streams[streams.length-1];if(lastArg&&typeof lastArg=="object"&&!isNodeStream(lastArg)&&!isIterable(lastArg)&&!isWebStream(lastArg)){let options2=ArrayPrototypePop(streams);signal=options2.signal,end=options2.end}pl(streams,(err,value2)=>{err?reject(err):resolve2(value2)},{signal,end})})}module.exports={finished,pipeline}}});var require_stream=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/stream.js"(exports,module){"use strict";init_browser_globals();var{Buffer:Buffer6}=require_buffer(),{ObjectDefineProperty,ObjectKeys,ReflectApply}=require_primordials(),{promisify:{custom:customPromisify}}=require_util3(),{streamReturningOperators,promiseReturningOperators}=require_operators(),{codes:{ERR_ILLEGAL_CONSTRUCTOR}}=require_errors2(),compose=require_compose(),{setDefaultHighWaterMark,getDefaultHighWaterMark}=require_state(),{pipeline}=require_pipeline(),{destroyer}=require_destroy(),eos=require_end_of_stream(),promises=require_promises(),utils=require_utils(),Stream=module.exports=require_legacy().Stream;Stream.isDestroyed=utils.isDestroyed;Stream.isDisturbed=utils.isDisturbed;Stream.isErrored=utils.isErrored;Stream.isReadable=utils.isReadable;Stream.isWritable=utils.isWritable;Stream.Readable=require_readable();for(let key of ObjectKeys(streamReturningOperators)){let fn2=function(...args){if(new.target)throw ERR_ILLEGAL_CONSTRUCTOR();return Stream.Readable.from(ReflectApply(op,this,args))},op=streamReturningOperators[key];ObjectDefineProperty(fn2,"name",{__proto__:null,value:op.name}),ObjectDefineProperty(fn2,"length",{__proto__:null,value:op.length}),ObjectDefineProperty(Stream.Readable.prototype,key,{__proto__:null,value:fn2,enumerable:!1,configurable:!0,writable:!0})}for(let key of ObjectKeys(promiseReturningOperators)){let fn2=function(...args){if(new.target)throw ERR_ILLEGAL_CONSTRUCTOR();return ReflectApply(op,this,args)},op=promiseReturningOperators[key];ObjectDefineProperty(fn2,"name",{__proto__:null,value:op.name}),ObjectDefineProperty(fn2,"length",{__proto__:null,value:op.length}),ObjectDefineProperty(Stream.Readable.prototype,key,{__proto__:null,value:fn2,enumerable:!1,configurable:!0,writable:!0})}Stream.Writable=require_writable();Stream.Duplex=require_duplex();Stream.Transform=require_transform();Stream.PassThrough=require_passthrough();Stream.pipeline=pipeline;var{addAbortSignal}=require_add_abort_signal();Stream.addAbortSignal=addAbortSignal;Stream.finished=eos;Stream.destroy=destroyer;Stream.compose=compose;Stream.setDefaultHighWaterMark=setDefaultHighWaterMark;Stream.getDefaultHighWaterMark=getDefaultHighWaterMark;ObjectDefineProperty(Stream,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return promises}});ObjectDefineProperty(pipeline,customPromisify,{__proto__:null,enumerable:!0,get(){return promises.pipeline}});ObjectDefineProperty(eos,customPromisify,{__proto__:null,enumerable:!0,get(){return promises.finished}});Stream.Stream=Stream;Stream._isUint8Array=function(value2){return value2 instanceof Uint8Array};Stream._uint8ArrayToBuffer=function(chunk){return Buffer6.from(chunk.buffer,chunk.byteOffset,chunk.byteLength)}}});var require_browser3=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/browser.js"(exports,module){"use strict";init_browser_globals();var CustomStream=require_stream(),promises=require_promises(),originalDestroy=CustomStream.Readable.destroy;module.exports=CustomStream.Readable;module.exports._uint8ArrayToBuffer=CustomStream._uint8ArrayToBuffer;module.exports._isUint8Array=CustomStream._isUint8Array;module.exports.isDisturbed=CustomStream.isDisturbed;module.exports.isErrored=CustomStream.isErrored;module.exports.isReadable=CustomStream.isReadable;module.exports.Readable=CustomStream.Readable;module.exports.Writable=CustomStream.Writable;module.exports.Duplex=CustomStream.Duplex;module.exports.Transform=CustomStream.Transform;module.exports.PassThrough=CustomStream.PassThrough;module.exports.addAbortSignal=CustomStream.addAbortSignal;module.exports.finished=CustomStream.finished;module.exports.destroy=CustomStream.destroy;module.exports.destroy=originalDestroy;module.exports.pipeline=CustomStream.pipeline;module.exports.compose=CustomStream.compose;Object.defineProperty(CustomStream,"promises",{configurable:!0,enumerable:!0,get(){return promises}});module.exports.Stream=CustomStream.Stream;module.exports.default=module.exports}});var require_stream2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-builtins@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-builtins/lib/stream.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Writable=exports.Readable=void 0;var node_stream_1=require_browser3();Object.defineProperty(exports,"Readable",{enumerable:!0,get:function(){return node_stream_1.Readable}});Object.defineProperty(exports,"Writable",{enumerable:!0,get:function(){return node_stream_1.Writable}})}});var require_events2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-builtins@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-builtins/lib/events.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.EventEmitter=void 0;var node_events_1=require_events();Object.defineProperty(exports,"EventEmitter",{enumerable:!0,get:function(){return node_events_1.EventEmitter}})}});var require_FileHandle=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/FileHandle.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FileHandle=void 0;var util_1=require_util2(),readWriteArgs_1=require_readWriteArgs(),events_1=require_events2(),assertOpen=(fd,syscall)=>{if(fd!==-1)return;let error=new Error("file closed");throw error.code="EBADF",error.syscall=syscall,error},FileHandle=class extends events_1.EventEmitter{constructor(fs2,fd){super(),this.refs=1,this.closePromise=null,this.readableWebStreamLocked=!1,this.fs=fs2,this.fd=fd}getAsyncId(){return this.fd}appendFile(data,options2){return(0,util_1.promisify)(this.fs,"appendFile")(this.fd,data,options2)}chmod(mode){return(0,util_1.promisify)(this.fs,"fchmod")(this.fd,mode)}chown(uid,gid){return(0,util_1.promisify)(this.fs,"fchown")(this.fd,uid,gid)}close(){if(this.fd===-1)return Promise.resolve();if(this.closePromise)return this.closePromise;if(this.refs--,this.refs===0){let currentFd=this.fd;this.fd=-1,this.closePromise=(0,util_1.promisify)(this.fs,"close")(currentFd).finally(()=>{this.closePromise=null})}else this.closePromise=new Promise((resolve2,reject)=>{this.closeResolve=resolve2,this.closeReject=reject}).finally(()=>{this.closePromise=null,this.closeReject=void 0,this.closeResolve=void 0});return this.emit("close"),this.closePromise}datasync(){return(0,util_1.promisify)(this.fs,"fdatasync")(this.fd)}createReadStream(options2){return this.fs.createReadStream("",{...options2,fd:this})}createWriteStream(options2){return this.fs.createWriteStream("",{...options2,fd:this})}readableWebStream(options2={}){let{type="bytes",autoClose=!1}=options2;if(this.fd===-1)throw new Error("The FileHandle is closed");if(this.closePromise)throw new Error("The FileHandle is closing");if(this.readableWebStreamLocked)throw new Error("An error will be thrown if this method is called more than once or is called after the FileHandle is closed or closing.");this.readableWebStreamLocked=!0,this.ref();let unlockAndCleanup=()=>{this.readableWebStreamLocked=!1,this.unref(),autoClose&&this.close().catch(()=>{})};return new ReadableStream({type:type==="bytes"?"bytes":void 0,autoAllocateChunkSize:16384,pull:async controller=>{try{let view=controller.byobRequest?.view;if(!view){let buffer=new Uint8Array(16384),result2=await this.read(buffer,0,buffer.length,null);if(result2.bytesRead===0){controller.close(),unlockAndCleanup();return}controller.enqueue(buffer.slice(0,result2.bytesRead));return}let result=await this.read(view,0,view.byteLength,null);if(result.bytesRead===0){controller.close(),controller.byobRequest.respond(0),unlockAndCleanup();return}controller.byobRequest.respond(result.bytesRead)}catch(error){controller.error(error),unlockAndCleanup()}},cancel:async()=>{unlockAndCleanup()}})}async read(bufferOrParams,offsetOrOptions,length,position2){assertOpen(this.fd,"read");let args=(0,readWriteArgs_1.getHandleReadArgs)(bufferOrParams,offsetOrOptions,length,position2),buffer=args.buffer;return args.length===0?{__proto__:null,bytesRead:args.length,buffer}:{__proto__:null,bytesRead:await(0,util_1.promisify)(this.fs,"read")(this.fd,buffer,args.offset,args.length,args.position),buffer}}async readv(buffers,position2){return assertOpen(this.fd,"readv"),{__proto__:null,bytesRead:await(0,util_1.promisify)(this.fs,"readv")(this.fd,buffers,position2??null),buffers}}readFile(options2){return(0,util_1.promisify)(this.fs,"readFile")(this.fd,options2)}stat(options2){return(0,util_1.promisify)(this.fs,"fstat")(this.fd,options2)}sync(){return(0,util_1.promisify)(this.fs,"fsync")(this.fd)}truncate(len){return(0,util_1.promisify)(this.fs,"ftruncate")(this.fd,len)}utimes(atime,mtime){return(0,util_1.promisify)(this.fs,"futimes")(this.fd,atime,mtime)}async write(data,offsetOrOptions,lengthOrEncoding,position2){assertOpen(this.fd,"write");let args=(0,readWriteArgs_1.getHandleWriteArgs)(data,offsetOrOptions,lengthOrEncoding,position2);return args?{__proto__:null,bytesWritten:await(0,util_1.promisify)(this.fs,"write")(this.fd,args.buffer,args.offset,args.length,args.position),buffer:data}:{__proto__:null,bytesWritten:0,buffer:data}}async writev(buffers,position2){return assertOpen(this.fd,"writev"),{__proto__:null,bytesWritten:await(0,util_1.promisify)(this.fs,"writev")(this.fd,buffers,position2??null),buffers}}writeFile(data,options2){return(0,util_1.promisify)(this.fs,"writeFile")(this.fd,data,options2)}async[Symbol.asyncDispose](){await this.close()}ref(){this.refs++}unref(){this.refs--,this.refs===0&&(this.fd=-1,this.closeResolve&&(0,util_1.promisify)(this.fs,"close")(this.fd).then(this.closeResolve,this.closeReject))}};exports.FileHandle=FileHandle}});var require_util4=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-builtins@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-builtins/lib/util.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.inherits=inherits;exports.promisify=promisify;exports.inspect=inspect;exports.format=format5;function inherits(ctor,superCtor){if(ctor==null)throw new TypeError("The constructor to inherit from is not defined");if(superCtor==null)throw new TypeError("The super constructor to inherit from is not defined");ctor.super_=superCtor,ctor.prototype=Object.create(superCtor.prototype,{constructor:{value:ctor,enumerable:!1,writable:!0,configurable:!0}})}function promisify(fn2){if(typeof fn2!="function")throw new TypeError('The "original" argument must be of type function');return function(...args){return new Promise((resolve2,reject)=>{fn2.call(this,...args,(err,result)=>{err?reject(err):resolve2(result)})})}}function inspect(value2){return value2===null?"null":value2===void 0?"undefined":typeof value2=="string"?`'${value2}'`:typeof value2=="number"||typeof value2=="boolean"?String(value2):Array.isArray(value2)?`[ ${value2.map(item=>inspect(item)).join(", ")} ]`:typeof value2=="object"?`{ ${Object.entries(value2).map(([key,val])=>`${key}: ${inspect(val)}`).join(", ")} }`:String(value2)}function format5(template,...args){if(args.length===0)return template;let result=template,argIndex=0;for(result=result.replace(/%[sdj%]/g,match=>{if(argIndex>=args.length)return match;let arg=args[argIndex++];switch(match){case"%s":return String(arg);case"%d":return Number(arg).toString();case"%j":try{return JSON.stringify(arg)}catch{return"[Circular]"}case"%%":return"%";default:return match}});argIndex<args.length;)result+=" "+String(args[argIndex++]);return result}}});var require_cp=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/cp.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.cpAsync=exports.cpSync=exports.copyFileCore=exports.getCpOptions=exports.getValidCopyFileMode=void 0;var path_1=require_path2(),fs_node_utils_1=require_lib5(),fs_core_1=require_lib6(),argErrors_1=require_argErrors(),validators_1=require_validators(),pathResolve=path_1.posix.resolve,{O_RDONLY,O_WRONLY,O_CREAT,O_EXCL,COPYFILE_EXCL,COPYFILE_FICLONE_FORCE}=fs_node_utils_1.constants,PREFIX={ERR_FS_CP_DIR_TO_NON_DIR:"Cannot overwrite non-directory with directory",ERR_FS_CP_EEXIST:"Target already exists",ERR_FS_CP_EINVAL:"Invalid src or dest",ERR_FS_CP_FIFO_PIPE:"Cannot copy a FIFO pipe",ERR_FS_CP_NON_DIR_TO_DIR:"Cannot overwrite directory with non-directory",ERR_FS_CP_SOCKET:"Cannot copy a socket file",ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY:"Cannot overwrite symlink in subdirectory of self",ERR_FS_CP_UNKNOWN:"Cannot copy an unknown file type",ERR_FS_EISDIR:"Path is a directory"},cpSystemError=(code4,message,path4,errno,uv)=>new fs_core_1.SystemError(code4,PREFIX[code4],{code:uv,message,path:path4,syscall:"cp",errno}),cpCodeError=(code4,message)=>(0,argErrors_1.withNativeCode)(new Error(message),code4),invalidFilterReturn=value2=>(0,argErrors_1.withCode)(new TypeError('Expected boolean to be returned from the "filter" function but got an instance of Promise.'),"ERR_INVALID_RETURN_VALUE"),asCopyfileError=(error,src,dest)=>error&&typeof error.code=="string"&&typeof error.syscall=="string"?(0,fs_core_1.createError)(error.code,"copyfile",src,dest):error,getValidCpMode=mode=>mode==null?0:((0,validators_1.validateInteger)(mode,"mode",0,7),mode),getValidCopyFileMode=mode=>{if(mode==null)return 0;if(typeof mode!="number")throw(0,argErrors_1.withNativeCode)(new TypeError("mode must be int32 or null/undefined"),"ERR_INVALID_ARG_TYPE");if(!Number.isFinite(mode))throw(0,argErrors_1.withNativeCode)(new RangeError("mode is out of range"),"ERR_OUT_OF_RANGE");let truncated=Math.trunc(mode);if(truncated<0||truncated>7)throw(0,argErrors_1.withNativeCode)(new RangeError("mode is out of range: >= 0 && <= 7"),"ERR_OUT_OF_RANGE");return truncated};exports.getValidCopyFileMode=getValidCopyFileMode;var CP_DEFAULTS={dereference:!1,errorOnExist:!1,filter:void 0,force:!0,mode:0,preserveTimestamps:!1,recursive:!1,verbatimSymlinks:!1},getCpOptions=options2=>{if(options2===void 0)return{...CP_DEFAULTS};(0,validators_1.validateObject)(options2,"options");let resolved={...CP_DEFAULTS,...options2};if((0,validators_1.validateBoolean)(resolved.dereference,"options.dereference"),(0,validators_1.validateBoolean)(resolved.errorOnExist,"options.errorOnExist"),(0,validators_1.validateBoolean)(resolved.force,"options.force"),(0,validators_1.validateBoolean)(resolved.preserveTimestamps,"options.preserveTimestamps"),(0,validators_1.validateBoolean)(resolved.recursive,"options.recursive"),(0,validators_1.validateBoolean)(resolved.verbatimSymlinks,"options.verbatimSymlinks"),resolved.mode=getValidCpMode(options2.mode),resolved.dereference===!0&&resolved.verbatimSymlinks===!0)throw(0,argErrors_1.withCode)(new TypeError('Option "dereference" cannot be used in combination with option "verbatimSymlinks"'),"ERR_INCOMPATIBLE_OPTION_PAIR");return resolved.filter!==void 0&&(0,validators_1.validateFunction)(resolved.filter,"options.filter"),resolved};exports.getCpOptions=getCpOptions;var isPromise=value2=>!!value2&&(typeof value2=="object"||typeof value2=="function")&&typeof value2.then=="function",copyFileCore=(core,src,dest,flags)=>{let srcFd=-1,destFd=-1,copied=!1;try{srcFd=core.open(src,O_RDONLY,0);let srcNode=core.getFileByFdOrThrow(srcFd,"copyfile").node,srcMode=srcNode.mode,excl=!!(flags©FILE_EXCL);destFd=core.open(dest,excl?O_WRONLY|O_CREAT|O_EXCL:O_WRONLY|O_CREAT,438);let destNode=core.getFileByFdOrThrow(destFd,"copyfile").node;if(!excl){if(destNode===srcNode){copied=!0;return}core.ftruncate(destFd,0)}if(core.fchmod(destFd,srcMode),flags©FILE_FICLONE_FORCE)throw(0,fs_core_1.createError)("ENOSYS","copyfile",src,dest);if(srcNode.isDirectory())throw(0,fs_core_1.createError)("EISDIR","copyfile",src,dest);let size=srcNode.getSize();size>0&&core.write(destFd,srcNode.getBuffer(),0,size,0),copied=!0}catch(error){throw asCopyfileError(error,src,dest)}finally{if(srcFd>=0&&core.close(srcFd),destFd>=0&&(core.close(destFd),!copied))try{core.unlink(dest)}catch{}}};exports.copyFileCore=copyFileCore;var toParts=path4=>{let raw=pathResolve(path4).split("/"),parts=[];for(let i2=0;i2<raw.length;i2++)raw[i2]&&parts.push(raw[i2]);return parts},isSrcSubdir=(src,dest)=>{let srcArr=toParts(src),destArr=toParts(dest),length=srcArr.length;if(length>destArr.length)return!1;for(let i2=0;i2<length;i2++)if(destArr[i2]!==srcArr[i2])return!1;return!0},areIdentical=(srcStat,destStat)=>srcStat.ino===destStat.ino&&srcStat.dev===destStat.dev,statOf=(vol,path4,dereference)=>dereference?vol.statSync(path4):vol.lstatSync(path4),statOrNull=(vol,path4,dereference)=>dereference?vol.statSync(path4,{throwIfNoEntry:!1}):vol.lstatSync(path4,{throwIfNoEntry:!1}),readEntries=(vol,dir)=>{try{return vol.readdirSync(dir)}catch(error){let code4=error.code;throw code4?(0,fs_core_1.createError)(code4,"opendir",dir):error}},isDirectory=(vol,path4)=>{let stats=vol.statSync(path4,{throwIfNoEntry:!1});return!!stats&&stats.isDirectory()},setDestMode=(vol,dest,srcMode)=>{vol.chmodSync(dest,Number(srcMode))},setDestTimestamps=(vol,src,dest)=>{let updated=vol.statSync(src);vol.utimesSync(dest,updated.atime,updated.mtime)},resolveLinkTarget=(vol,src,verbatimSymlinks)=>{let target=String(vol.readlinkSync(src));return!verbatimSymlinks&&target[0]!=="/"?pathResolve((0,fs_node_utils_1.pathDirname)(src),target):target},identicalPaths=(vol,a2,b2)=>{try{let statA=vol.statSync(a2,{throwIfNoEntry:!1});if(!statA)return!1;let statB=vol.statSync(b2,{throwIfNoEntry:!1});return!!statB&&areIdentical(statA,statB)}catch{return!1}},srcAliasesAncestor=(vol,srcStat,srcParent,destParent)=>{for(let ancestor=destParent;ancestor!==srcParent&&ancestor!=="/";ancestor=(0,fs_node_utils_1.pathDirname)(ancestor)){let stat2;try{stat2=vol.statSync(ancestor,{throwIfNoEntry:!1})}catch{return!1}if(stat2){if(!stat2.isDirectory())return!1;if(areIdentical(srcStat,stat2))return!0}}return!1},checkPathsSync=(vol,src,dest,dereference,recursive)=>{let srcStat;try{srcStat=statOf(vol,src,!dereference)}catch(error){let code4=error.code;throw code4?(0,fs_core_1.createError)(code4,dereference?"stat":"lstat",src):error}let destStat;try{destStat=statOf(vol,dest,dereference)}catch{}let srcIsDir=srcStat.isDirectory()||dereference&&srcStat.isSymbolicLink(),srcPath=pathResolve(src),destPath=pathResolve(dest);if(destStat){if(identicalPaths(vol,srcPath,destPath))throw cpCodeError("ERR_FS_CP_EINVAL","src and dest cannot be the same "+destPath);let destIsDir=destStat.isDirectory();if(srcIsDir&&!destIsDir)throw cpCodeError("ERR_FS_CP_DIR_TO_NON_DIR","Cannot overwrite non-directory "+destPath+" with directory "+srcPath);if(!srcIsDir&&destIsDir)throw cpCodeError("ERR_FS_CP_NON_DIR_TO_DIR","Cannot overwrite directory "+destPath+" with non-directory "+srcPath)}let srcPrefix=srcPath==="/"?srcPath:srcPath+"/";if(srcIsDir&&destPath.startsWith(srcPrefix))throw cpCodeError("ERR_FS_CP_EINVAL","Cannot copy "+srcPrefix+" to a subdirectory of self "+destPath);let destParent=(0,fs_node_utils_1.pathDirname)(destPath),srcParent=(0,fs_node_utils_1.pathDirname)(srcPath);if(srcParent!==destParent&&destParent!=="/"&&identicalPaths(vol,srcPath,destParent))throw cpCodeError("ERR_FS_CP_EINVAL","Cannot copy "+srcPrefix+" to a subdirectory of self "+destPath);if(recursive&&srcIsDir){let copyStat=statOrNull(vol,src,dereference),followed=dereference?copyStat:srcStat;if(copyStat&&followed&©Stat.isDirectory()&&srcAliasesAncestor(vol,followed,srcParent,destParent))throw cpCodeError("ERR_FS_CP_EINVAL","Cannot copy "+srcPrefix+" to a subdirectory of self "+destPath)}if(srcIsDir&&!recursive)throw cpCodeError("ERR_FS_EISDIR","Recursive option not enabled, cannot copy a directory: "+srcPrefix);if(srcStat.isSocket())throw cpCodeError("ERR_FS_CP_SOCKET","Cannot copy a socket file: "+destPath);if(srcStat.isFIFO())throw cpCodeError("ERR_FS_CP_FIFO_PIPE","Cannot copy a FIFO pipe: "+destPath);try{(!destStat||!vol.existsSync(destParent))&&vol.mkdirSync(destParent,{recursive:!0})}catch{}},filterSync=(filter,src,dest)=>{let shouldCopy=filter(src,dest);if(isPromise(shouldCopy))throw invalidFilterReturn(shouldCopy);return!!shouldCopy},cpSync=(vol,src,dest,options2)=>{let filter=options2.filter;filter&&!filterSync(filter,src,dest)||(checkPathsSync(vol,src,dest,options2.dereference,options2.recursive),getStatsSync(vol,src,dest,options2))};exports.cpSync=cpSync;var getStatsSync=(vol,src,dest,options2)=>{let dereference=options2.dereference,srcStat=statOf(vol,src,dereference),destStat=statOrNull(vol,dest,dereference);if(srcStat.isDirectory()&&options2.recursive)return onDirSync(srcStat,destStat,vol,src,dest,options2);if(srcStat.isFile()||srcStat.isCharacterDevice()||srcStat.isBlockDevice())return onFileSync(srcStat,destStat,vol,src,dest,options2);if(srcStat.isSymbolicLink())return onLinkSync(destStat,vol,src,dest,options2.verbatimSymlinks)},onFileSync=(srcStat,destStat,vol,src,dest,options2)=>{if(destStat)if(options2.force)vol.unlinkSync(dest);else{if(options2.errorOnExist)throw cpSystemError("ERR_FS_CP_EEXIST",dest+" already exists",dest,17,"EEXIST");return}(0,exports.copyFileCore)(vol._core,src,dest,options2.mode);let srcMode=Number(srcStat.mode);setDestMode(vol,dest,srcMode),options2.preserveTimestamps&&setDestTimestamps(vol,src,dest)},onDirSync=(srcStat,destStat,vol,src,dest,options2)=>{destStat?copyDirSync(vol,src,dest,options2,!1,void 0):copyDirSync(vol,src,dest,options2,!0,Number(srcStat.mode))},copyDirSync=(vol,src,dest,options2,mkDir,srcMode)=>{mkDir&&vol.mkdirSync(dest);try{let entries=readEntries(vol,src),filter=options2.filter;for(let i2=0;i2<entries.length;i2++){let name=entries[i2],srcItem=(0,fs_node_utils_1.pathJoin)(src,name),destItem=(0,fs_node_utils_1.pathJoin)(dest,name);filter&&!filterSync(filter,srcItem,destItem)||getStatsSync(vol,srcItem,destItem,options2)}}finally{srcMode!==void 0&&setDestMode(vol,dest,srcMode)}},onLinkSync=(destStat,vol,src,dest,verbatimSymlinks)=>{let resolvedSrc=resolveLinkTarget(vol,src,verbatimSymlinks);if(!destStat){vol.symlinkSync(resolvedSrc,dest);return}let resolvedDest;try{resolvedDest=String(vol.readlinkSync(dest))}catch(error){if(error.code==="EINVAL"){vol.symlinkSync(resolvedSrc,dest);return}throw error}if(resolvedDest[0]!=="/"&&(resolvedDest=pathResolve((0,fs_node_utils_1.pathDirname)(dest),resolvedDest)),isDirectory(vol,src)&&isSrcSubdir(resolvedSrc,resolvedDest))throw cpCodeError("ERR_FS_CP_EINVAL","Cannot copy "+resolvedSrc+" to a subdirectory of self "+resolvedDest);if(isDirectory(vol,dest)&&isSrcSubdir(resolvedDest,resolvedSrc))throw cpCodeError("ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY","cannot overwrite "+resolvedDest+" with "+resolvedSrc);vol.unlinkSync(dest),vol.symlinkSync(resolvedSrc,dest)},cpAsync=async(vol,src,dest,options2)=>{let stats=await checkPaths(vol,src,dest,options2);if(!stats)return;checkParentPaths(vol,src,stats.srcStat,dest,options2.recursive);let destParent=(0,fs_node_utils_1.pathDirname)(dest);vol.existsSync(destParent)||vol.mkdirSync(destParent,{recursive:!0}),await getStatsForCopy(vol,stats.destStat,src,dest,options2)};exports.cpAsync=cpAsync;var checkPaths=async(vol,src,dest,options2)=>{let filter=options2.filter;if(filter&&!await filter(src,dest))return;let dereference=options2.dereference,srcStat=statOf(vol,src,dereference),destStat=statOrNull(vol,dest,dereference);if(destStat){if(areIdentical(srcStat,destStat))throw cpSystemError("ERR_FS_CP_EINVAL","src and dest cannot be the same",dest,22,"EINVAL");if(srcStat.isDirectory()&&!destStat.isDirectory())throw cpSystemError("ERR_FS_CP_DIR_TO_NON_DIR","cannot overwrite non-directory "+dest+" with directory "+src,dest,21,"EISDIR");if(!srcStat.isDirectory()&&destStat.isDirectory())throw cpSystemError("ERR_FS_CP_NON_DIR_TO_DIR","cannot overwrite directory "+dest+" with non-directory "+src,dest,20,"ENOTDIR")}if(srcStat.isDirectory()&&isSrcSubdir(src,dest))throw cpSystemError("ERR_FS_CP_EINVAL","cannot copy "+src+" to a subdirectory of self "+dest,dest,22,"EINVAL");return{srcStat,destStat}},checkParentPaths=(vol,src,srcStat,dest,recursive)=>{let srcParent=pathResolve((0,fs_node_utils_1.pathDirname)(src)),skipMissing=recursive&&srcStat.isDirectory(),at2=dest;for(let parent=pathResolve((0,fs_node_utils_1.pathDirname)(dest));parent!==srcParent&&parent!=="/";at2=parent,parent=(0,fs_node_utils_1.pathDirname)(parent)){let parentStat=vol.statSync(parent,{throwIfNoEntry:!1});if(!parentStat){if(skipMissing)continue;return}if(areIdentical(srcStat,parentStat))throw cpSystemError("ERR_FS_CP_EINVAL","cannot copy "+src+" to a subdirectory of self "+at2,at2,22,"EINVAL")}},getStatsForCopy=async(vol,destStat,src,dest,options2)=>{let srcStat=statOf(vol,src,options2.dereference);if(srcStat.isDirectory()&&options2.recursive)return onDir(vol,srcStat,destStat,src,dest,options2);if(srcStat.isDirectory())throw cpSystemError("ERR_FS_EISDIR",src+" is a directory (not copied)",src,21,"EISDIR");if(srcStat.isFile()||srcStat.isCharacterDevice()||srcStat.isBlockDevice())return onFile(vol,srcStat,destStat,src,dest,options2);if(srcStat.isSymbolicLink())return onLink(vol,destStat,src,dest,options2);throw srcStat.isSocket()?cpSystemError("ERR_FS_CP_SOCKET","cannot copy a socket file: "+dest,dest,22,"EINVAL"):srcStat.isFIFO()?cpSystemError("ERR_FS_CP_FIFO_PIPE","cannot copy a FIFO pipe: "+dest,dest,22,"EINVAL"):cpSystemError("ERR_FS_CP_UNKNOWN","cannot copy an unknown file type: "+dest,dest,22,"EINVAL")},onFile=async(vol,srcStat,destStat,src,dest,options2)=>{if(destStat)if(options2.force)vol.unlinkSync(dest);else{if(options2.errorOnExist)throw cpSystemError("ERR_FS_CP_EEXIST",dest+" already exists",dest,17,"EEXIST");return}(0,exports.copyFileCore)(vol._core,src,dest,options2.mode);let srcMode=Number(srcStat.mode);setDestMode(vol,dest,srcMode),options2.preserveTimestamps&&setDestTimestamps(vol,src,dest)},onDir=async(vol,srcStat,destStat,src,dest,options2)=>{if(!destStat){vol.mkdirSync(dest),await copyDir(vol,src,dest,options2),setDestMode(vol,dest,Number(srcStat.mode));return}if(options2.errorOnExist&&!options2.force)throw cpSystemError("ERR_FS_CP_EEXIST",dest+" already exists",dest,17,"EEXIST");await copyDir(vol,src,dest,options2)},copyDir=async(vol,src,dest,options2)=>{let entries=readEntries(vol,src);for(let i2=0;i2<entries.length;i2++){let name=entries[i2],srcItem=(0,fs_node_utils_1.pathJoin)(src,name),destItem=(0,fs_node_utils_1.pathJoin)(dest,name),checked=await checkPaths(vol,srcItem,destItem,options2);checked&&await getStatsForCopy(vol,checked.destStat,srcItem,destItem,options2)}},onLink=async(vol,destStat,src,dest,options2)=>{let resolvedSrc=resolveLinkTarget(vol,src,options2.verbatimSymlinks);if(!destStat){vol.symlinkSync(resolvedSrc,dest);return}let resolvedDest;try{resolvedDest=String(vol.readlinkSync(dest))}catch(error){if(error.code==="EINVAL"){vol.symlinkSync(resolvedSrc,dest);return}throw error}if(resolvedDest[0]!=="/"&&(resolvedDest=pathResolve((0,fs_node_utils_1.pathDirname)(dest),resolvedDest)),isDirectory(vol,src)&&isSrcSubdir(resolvedSrc,resolvedDest))throw cpSystemError("ERR_FS_CP_EINVAL","cannot copy "+resolvedSrc+" to a subdirectory of self "+resolvedDest,dest,22,"EINVAL");if(statOf(vol,src,!0).isDirectory()&&isSrcSubdir(resolvedDest,resolvedSrc))throw cpSystemError("ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY","cannot overwrite "+resolvedDest+" with "+resolvedSrc,dest,22,"EINVAL");vol.unlinkSync(dest),vol.symlinkSync(resolvedSrc,dest)}}});var require_FsPromises=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/FsPromises.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FsPromises=void 0;var util_1=require_util2(),cp_1=require_cp(),glob_1=require_glob(),fs_node_utils_1=require_lib5(),newAbortError=signal=>{let error=new Error("The operation was aborted");return error.name="AbortError",error.code="ABORT_ERR",error.cause=signal.reason,error},FSWatchAsyncIterator=class{constructor(fs2,path4,options2={}){this.fs=fs2,this.path=path4,this.options=options2,this.eventQueue=[],this.resolveQueue=[],this.finished=!1,this.maxQueue=options2.maxQueue||2048;let overflow=options2.overflow||"ignore";if(overflow!=="ignore"&&overflow!=="error"&&overflow!=="throw")throw new TypeError(`The argument 'options.overflow' must be one of: 'ignore', 'error'. Received '${overflow}'`);this.overflow=overflow==="throw"?"error":overflow;let signal=options2.signal;if(signal){if(signal.aborted){this.finish(newAbortError(signal));return}this.onAbort=()=>this.finish(newAbortError(signal)),signal.addEventListener("abort",this.onAbort)}this.startWatching()}startWatching(){let{signal,...watchOptions}=this.options;try{this.watcher=this.fs.watch(this.path,watchOptions,(eventType,filename)=>{this.enqueueEvent({eventType,filename})})}catch(error){throw this.finish(),error}}enqueueEvent(event){if(!this.finished){if(this.eventQueue.length>=this.maxQueue){if(this.overflow==="error"){let error=new Error(`Watch queue overflow: more than ${this.maxQueue} events queued`);error.code="ERR_FS_WATCH_QUEUE_OVERFLOW",this.finish(error)}else typeof process<"u"&&typeof process.emitWarning=="function"&&process.emitWarning("fs.watch maxQueue exceeded");return}if(this.eventQueue.push(event),this.resolveQueue.length>0){let{resolve:resolve2}=this.resolveQueue.shift(),nextEvent=this.eventQueue.shift();resolve2({value:nextEvent,done:!1})}}}finish(error){if(this.finished)return;this.finished=!0,this.error=error,error&&(this.eventQueue.length=0),this.onAbort&&(this.options.signal.removeEventListener("abort",this.onAbort),this.onAbort=void 0),this.watcher&&(this.watcher.close(),this.watcher=null);let delivered=error&&this.resolveQueue.length>0;for(;this.resolveQueue.length>0;){let{resolve:resolve2,reject}=this.resolveQueue.shift();error?reject(error):resolve2({value:void 0,done:!0})}delivered&&(this.error=void 0)}async next(){if(this.error){let error=this.error;throw this.error=void 0,error}return this.finished?{value:void 0,done:!0}:this.eventQueue.length>0?{value:this.eventQueue.shift(),done:!1}:new Promise((resolve2,reject)=>{this.resolveQueue.push({resolve:resolve2,reject})})}async return(){return this.finish(),{value:void 0,done:!0}}async throw(error){throw this.finish(error),error}[Symbol.asyncIterator](){return this}},FsPromises=class{constructor(fs2,FileHandle){this.fs=fs2,this.FileHandle=FileHandle,this.constants=fs_node_utils_1.constants,this.cp=(src,dest,options2)=>new Promise((resolve2,reject)=>{this.fs.cp(src,dest,(0,cp_1.getCpOptions)(options2),error=>error?reject(error):resolve2())}),this.copyFile=(src,dest,mode)=>new Promise((resolve2,reject)=>{this.fs.copyFile(src,dest,mode,error=>error?reject(error):resolve2())}),this.opendir=(0,util_1.promisify)(this.fs,"opendir"),this.statfs=(0,util_1.promisify)(this.fs,"statfs"),this.lutimes=(0,util_1.promisify)(this.fs,"lutimes"),this.glob=(pattern,options2)=>(0,glob_1.glob)(this.fs,pattern,options2),this.access=(0,util_1.promisify)(this.fs,"access"),this.chmod=(0,util_1.promisify)(this.fs,"chmod"),this.chown=(0,util_1.promisify)(this.fs,"chown"),this.lchmod=(0,util_1.promisify)(this.fs,"lchmod"),this.lchown=(0,util_1.promisify)(this.fs,"lchown"),this.link=(0,util_1.promisify)(this.fs,"link"),this.lstat=(0,util_1.promisify)(this.fs,"lstat"),this.mkdir=(0,util_1.promisify)(this.fs,"mkdir"),this.mkdtemp=(0,util_1.promisify)(this.fs,"mkdtemp"),this.readdir=(0,util_1.promisify)(this.fs,"readdir"),this.readlink=(0,util_1.promisify)(this.fs,"readlink"),this.realpath=(0,util_1.promisify)(this.fs,"realpath"),this.rename=(0,util_1.promisify)(this.fs,"rename"),this.rmdir=(0,util_1.promisify)(this.fs,"rmdir"),this.rm=(0,util_1.promisify)(this.fs,"rm"),this.stat=(0,util_1.promisify)(this.fs,"stat"),this.symlink=(0,util_1.promisify)(this.fs,"symlink"),this.truncate=(0,util_1.promisify)(this.fs,"truncate"),this.unlink=(0,util_1.promisify)(this.fs,"unlink"),this.utimes=(0,util_1.promisify)(this.fs,"utimes"),this.readFile=(id,options2)=>(0,util_1.promisify)(this.fs,"readFile")(id instanceof this.FileHandle?id.fd:id,options2),this.appendFile=(path4,data,options2)=>(0,util_1.promisify)(this.fs,"appendFile")(path4 instanceof this.FileHandle?path4.fd:path4,data,options2),this.open=(path4,flags="r",mode)=>(0,util_1.promisify)(this.fs,"open",fd=>new this.FileHandle(this.fs,fd))(path4,flags,mode),this.writeFile=(id,data,options2)=>((0,util_1.isReadableStream)(data)?(0,util_1.streamToBuffer)(data):Promise.resolve(data)).then(data2=>(0,util_1.promisify)(this.fs,"writeFile")(id instanceof this.FileHandle?id.fd:id,data2,options2)),this.watch=(filename,options2)=>{let watchOptions=typeof options2=="string"?{encoding:options2}:options2||{};return new FSWatchAsyncIterator(this.fs,filename,watchOptions)}}};exports.FsPromises=FsPromises}});var require_printTree=__commonJS({"node_modules/.pnpm/tree-dump@1.1.0_tslib@2.9.1/node_modules/tree-dump/lib/printTree.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.printTree=void 0;var printTree=(tab="",children)=>{let str="",last=children.length-1;for(;last>=0&&!children[last];last--);for(let i2=0;i2<=last;i2++){let fn2=children[i2];if(!fn2)continue;let isLast=i2===last,child=fn2(tab+(isLast?" ":"\u2502")+" "),branch2=child?isLast?"\u2514\u2500":"\u251C\u2500":"\u2502";str+=`
|
|
42
|
+
`;super(message),this.name="AggregateError",this.errors=errors}};module.exports={AggregateError:AggregateError2,ArrayIsArray(self2){return Array.isArray(self2)},ArrayPrototypeIncludes(self2,el){return self2.includes(el)},ArrayPrototypeIndexOf(self2,el){return self2.indexOf(el)},ArrayPrototypeJoin(self2,sep2){return self2.join(sep2)},ArrayPrototypeMap(self2,fn2){return self2.map(fn2)},ArrayPrototypePop(self2,el){return self2.pop(el)},ArrayPrototypePush(self2,el){return self2.push(el)},ArrayPrototypeSlice(self2,start,end){return self2.slice(start,end)},Error,FunctionPrototypeCall(fn2,thisArgs,...args){return fn2.call(thisArgs,...args)},FunctionPrototypeSymbolHasInstance(self2,instance){return Function.prototype[Symbol.hasInstance].call(self2,instance)},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(self2,props){return Object.defineProperties(self2,props)},ObjectDefineProperty(self2,name,prop){return Object.defineProperty(self2,name,prop)},ObjectGetOwnPropertyDescriptor(self2,name){return Object.getOwnPropertyDescriptor(self2,name)},ObjectKeys(obj){return Object.keys(obj)},ObjectSetPrototypeOf(target,proto){return Object.setPrototypeOf(target,proto)},Promise,PromisePrototypeCatch(self2,fn2){return self2.catch(fn2)},PromisePrototypeThen(self2,thenFn,catchFn){return self2.then(thenFn,catchFn)},PromiseReject(err){return Promise.reject(err)},PromiseResolve(val){return Promise.resolve(val)},ReflectApply:Reflect.apply,RegExpPrototypeTest(self2,value2){return self2.test(value2)},SafeSet:Set,String,StringPrototypeSlice(self2,start,end){return self2.slice(start,end)},StringPrototypeToLowerCase(self2){return self2.toLowerCase()},StringPrototypeToUpperCase(self2){return self2.toUpperCase()},StringPrototypeTrim(self2){return self2.trim()},Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet(self2,buf,len){return self2.set(buf,len)},Boolean,Uint8Array}}});var require_inspect2=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/util/inspect.js"(exports,module){"use strict";init_browser_globals();module.exports={format(format5,...args){return format5.replace(/%([sdifj])/g,function(...[_unused,type]){let replacement=args.shift();return type==="f"?replacement.toFixed(6):type==="j"?JSON.stringify(replacement):type==="s"&&typeof replacement=="object"?`${replacement.constructor!==Object?replacement.constructor.name:""} {}`.trim():replacement.toString()})},inspect(value2){switch(typeof value2){case"string":if(value2.includes("'"))if(value2.includes('"')){if(!value2.includes("`")&&!value2.includes("${"))return`\`${value2}\``}else return`"${value2}"`;return`'${value2}'`;case"number":return isNaN(value2)?"NaN":Object.is(value2,-0)?String(value2):value2;case"bigint":return`${String(value2)}n`;case"boolean":case"undefined":return String(value2);case"object":return"{}"}}}}});var require_errors2=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/errors.js"(exports,module){"use strict";init_browser_globals();var{format:format5,inspect}=require_inspect2(),{AggregateError:CustomAggregateError}=require_primordials(),AggregateError2=globalThis.AggregateError||CustomAggregateError,kIsNodeError=Symbol("kIsNodeError"),kTypes=["string","function","number","object","Function","Object","boolean","bigint","symbol"],classRegExp=/^([A-Z][a-z0-9]*)+$/,nodeInternalPrefix="__node_internal_",codes2={};function assert(value2,message){if(!value2)throw new codes2.ERR_INTERNAL_ASSERTION(message)}function addNumericalSeparator(val){let res="",i2=val.length,start=val[0]==="-"?1:0;for(;i2>=start+4;i2-=3)res=`_${val.slice(i2-3,i2)}${res}`;return`${val.slice(0,i2)}${res}`}function getMessage(key,msg,args){if(typeof msg=="function")return assert(msg.length<=args.length,`Code: ${key}; The provided arguments length (${args.length}) does not match the required ones (${msg.length}).`),msg(...args);let expectedLength=(msg.match(/%[dfijoOs]/g)||[]).length;return assert(expectedLength===args.length,`Code: ${key}; The provided arguments length (${args.length}) does not match the required ones (${expectedLength}).`),args.length===0?msg:format5(msg,...args)}function E(code4,message,Base){Base||(Base=Error);class NodeError extends Base{constructor(...args){super(getMessage(code4,message,args))}toString(){return`${this.name} [${code4}]: ${this.message}`}}Object.defineProperties(NodeError.prototype,{name:{value:Base.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${code4}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),NodeError.prototype.code=code4,NodeError.prototype[kIsNodeError]=!0,codes2[code4]=NodeError}function hideStackFrames(fn2){let hidden=nodeInternalPrefix+fn2.name;return Object.defineProperty(fn2,"name",{value:hidden}),fn2}function aggregateTwoErrors(innerError,outerError){if(innerError&&outerError&&innerError!==outerError){if(Array.isArray(outerError.errors))return outerError.errors.push(innerError),outerError;let err=new AggregateError2([outerError,innerError],outerError.message);return err.code=outerError.code,err}return innerError||outerError}var AbortError=class extends Error{constructor(message="The operation was aborted",options2=void 0){if(options2!==void 0&&typeof options2!="object")throw new codes2.ERR_INVALID_ARG_TYPE("options","Object",options2);super(message,options2),this.code="ABORT_ERR",this.name="AbortError"}};E("ERR_ASSERTION","%s",Error);E("ERR_INVALID_ARG_TYPE",(name,expected,actual)=>{assert(typeof name=="string","'name' must be a string"),Array.isArray(expected)||(expected=[expected]);let msg="The ";name.endsWith(" argument")?msg+=`${name} `:msg+=`"${name}" ${name.includes(".")?"property":"argument"} `,msg+="must be ";let types2=[],instances=[],other=[];for(let value2 of expected)assert(typeof value2=="string","All expected entries have to be of type string"),kTypes.includes(value2)?types2.push(value2.toLowerCase()):classRegExp.test(value2)?instances.push(value2):(assert(value2!=="object",'The value "object" should be written as "Object"'),other.push(value2));if(instances.length>0){let pos=types2.indexOf("object");pos!==-1&&(types2.splice(types2,pos,1),instances.push("Object"))}if(types2.length>0){switch(types2.length){case 1:msg+=`of type ${types2[0]}`;break;case 2:msg+=`one of type ${types2[0]} or ${types2[1]}`;break;default:{let last=types2.pop();msg+=`one of type ${types2.join(", ")}, or ${last}`}}(instances.length>0||other.length>0)&&(msg+=" or ")}if(instances.length>0){switch(instances.length){case 1:msg+=`an instance of ${instances[0]}`;break;case 2:msg+=`an instance of ${instances[0]} or ${instances[1]}`;break;default:{let last=instances.pop();msg+=`an instance of ${instances.join(", ")}, or ${last}`}}other.length>0&&(msg+=" or ")}switch(other.length){case 0:break;case 1:other[0].toLowerCase()!==other[0]&&(msg+="an "),msg+=`${other[0]}`;break;case 2:msg+=`one of ${other[0]} or ${other[1]}`;break;default:{let last=other.pop();msg+=`one of ${other.join(", ")}, or ${last}`}}if(actual==null)msg+=`. Received ${actual}`;else if(typeof actual=="function"&&actual.name)msg+=`. Received function ${actual.name}`;else if(typeof actual=="object"){var _actual$constructor;if((_actual$constructor=actual.constructor)!==null&&_actual$constructor!==void 0&&_actual$constructor.name)msg+=`. Received an instance of ${actual.constructor.name}`;else{let inspected=inspect(actual,{depth:-1});msg+=`. Received ${inspected}`}}else{let inspected=inspect(actual,{colors:!1});inspected.length>25&&(inspected=`${inspected.slice(0,25)}...`),msg+=`. Received type ${typeof actual} (${inspected})`}return msg},TypeError);E("ERR_INVALID_ARG_VALUE",(name,value2,reason="is invalid")=>{let inspected=inspect(value2);return inspected.length>128&&(inspected=inspected.slice(0,128)+"..."),`The ${name.includes(".")?"property":"argument"} '${name}' ${reason}. Received ${inspected}`},TypeError);E("ERR_INVALID_RETURN_VALUE",(input,name,value2)=>{var _value$constructor;let type=value2!=null&&(_value$constructor=value2.constructor)!==null&&_value$constructor!==void 0&&_value$constructor.name?`instance of ${value2.constructor.name}`:`type ${typeof value2}`;return`Expected ${input} to be returned from the "${name}" function but got ${type}.`},TypeError);E("ERR_MISSING_ARGS",(...args)=>{assert(args.length>0,"At least one arg needs to be specified");let msg,len=args.length;switch(args=(Array.isArray(args)?args:[args]).map(a2=>`"${a2}"`).join(" or "),len){case 1:msg+=`The ${args[0]} argument`;break;case 2:msg+=`The ${args[0]} and ${args[1]} arguments`;break;default:{let last=args.pop();msg+=`The ${args.join(", ")}, and ${last} arguments`}break}return`${msg} must be specified`},TypeError);E("ERR_OUT_OF_RANGE",(str,range,input)=>{assert(range,'Missing "range" argument');let received;if(Number.isInteger(input)&&Math.abs(input)>2**32)received=addNumericalSeparator(String(input));else if(typeof input=="bigint"){received=String(input);let limit=BigInt(2)**BigInt(32);(input>limit||input<-limit)&&(received=addNumericalSeparator(received)),received+="n"}else received=inspect(input);return`The value of "${str}" is out of range. It must be ${range}. Received ${received}`},RangeError);E("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error);E("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error);E("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error);E("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error);E("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error);E("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);E("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error);E("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error);E("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error);E("ERR_STREAM_WRITE_AFTER_END","write after end",Error);E("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError);module.exports={AbortError,aggregateTwoErrors:hideStackFrames(aggregateTwoErrors),hideStackFrames,codes:codes2}}});var require_browser2=__commonJS({"node_modules/.pnpm/abort-controller@3.0.0/node_modules/abort-controller/browser.js"(exports,module){"use strict";init_browser_globals();var{AbortController:AbortController2,AbortSignal:AbortSignal2}=typeof self<"u"?self:typeof window<"u"?window:void 0;module.exports=AbortController2;module.exports.AbortSignal=AbortSignal2;module.exports.default=AbortController2}});var require_events=__commonJS({"node_modules/.pnpm/events@3.3.0/node_modules/events/events.js"(exports,module){"use strict";init_browser_globals();var R=typeof Reflect=="object"?Reflect:null,ReflectApply=R&&typeof R.apply=="function"?R.apply:function(target,receiver,args){return Function.prototype.apply.call(target,receiver,args)},ReflectOwnKeys;R&&typeof R.ownKeys=="function"?ReflectOwnKeys=R.ownKeys:Object.getOwnPropertySymbols?ReflectOwnKeys=function(target){return Object.getOwnPropertyNames(target).concat(Object.getOwnPropertySymbols(target))}:ReflectOwnKeys=function(target){return Object.getOwnPropertyNames(target)};function ProcessEmitWarning(warning){console&&console.warn&&console.warn(warning)}var NumberIsNaN=Number.isNaN||function(value2){return value2!==value2};function EventEmitter(){EventEmitter.init.call(this)}module.exports=EventEmitter;module.exports.once=once;EventEmitter.EventEmitter=EventEmitter;EventEmitter.prototype._events=void 0;EventEmitter.prototype._eventsCount=0;EventEmitter.prototype._maxListeners=void 0;var defaultMaxListeners=10;function checkListener(listener2){if(typeof listener2!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof listener2)}Object.defineProperty(EventEmitter,"defaultMaxListeners",{enumerable:!0,get:function(){return defaultMaxListeners},set:function(arg){if(typeof arg!="number"||arg<0||NumberIsNaN(arg))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+arg+".");defaultMaxListeners=arg}});EventEmitter.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0};EventEmitter.prototype.setMaxListeners=function(n2){if(typeof n2!="number"||n2<0||NumberIsNaN(n2))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+n2+".");return this._maxListeners=n2,this};function _getMaxListeners(that){return that._maxListeners===void 0?EventEmitter.defaultMaxListeners:that._maxListeners}EventEmitter.prototype.getMaxListeners=function(){return _getMaxListeners(this)};EventEmitter.prototype.emit=function(type){for(var args=[],i2=1;i2<arguments.length;i2++)args.push(arguments[i2]);var doError=type==="error",events=this._events;if(events!==void 0)doError=doError&&events.error===void 0;else if(!doError)return!1;if(doError){var er2;if(args.length>0&&(er2=args[0]),er2 instanceof Error)throw er2;var err=new Error("Unhandled error."+(er2?" ("+er2.message+")":""));throw err.context=er2,err}var handler2=events[type];if(handler2===void 0)return!1;if(typeof handler2=="function")ReflectApply(handler2,this,args);else for(var len=handler2.length,listeners=arrayClone(handler2,len),i2=0;i2<len;++i2)ReflectApply(listeners[i2],this,args);return!0};function _addListener(target,type,listener2,prepend){var m2,events,existing;if(checkListener(listener2),events=target._events,events===void 0?(events=target._events=Object.create(null),target._eventsCount=0):(events.newListener!==void 0&&(target.emit("newListener",type,listener2.listener?listener2.listener:listener2),events=target._events),existing=events[type]),existing===void 0)existing=events[type]=listener2,++target._eventsCount;else if(typeof existing=="function"?existing=events[type]=prepend?[listener2,existing]:[existing,listener2]:prepend?existing.unshift(listener2):existing.push(listener2),m2=_getMaxListeners(target),m2>0&&existing.length>m2&&!existing.warned){existing.warned=!0;var w2=new Error("Possible EventEmitter memory leak detected. "+existing.length+" "+String(type)+" listeners added. Use emitter.setMaxListeners() to increase limit");w2.name="MaxListenersExceededWarning",w2.emitter=target,w2.type=type,w2.count=existing.length,ProcessEmitWarning(w2)}return target}EventEmitter.prototype.addListener=function(type,listener2){return _addListener(this,type,listener2,!1)};EventEmitter.prototype.on=EventEmitter.prototype.addListener;EventEmitter.prototype.prependListener=function(type,listener2){return _addListener(this,type,listener2,!0)};function onceWrapper(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function _onceWrap(target,type,listener2){var state={fired:!1,wrapFn:void 0,target,type,listener:listener2},wrapped=onceWrapper.bind(state);return wrapped.listener=listener2,state.wrapFn=wrapped,wrapped}EventEmitter.prototype.once=function(type,listener2){return checkListener(listener2),this.on(type,_onceWrap(this,type,listener2)),this};EventEmitter.prototype.prependOnceListener=function(type,listener2){return checkListener(listener2),this.prependListener(type,_onceWrap(this,type,listener2)),this};EventEmitter.prototype.removeListener=function(type,listener2){var list5,events,position2,i2,originalListener;if(checkListener(listener2),events=this._events,events===void 0)return this;if(list5=events[type],list5===void 0)return this;if(list5===listener2||list5.listener===listener2)--this._eventsCount===0?this._events=Object.create(null):(delete events[type],events.removeListener&&this.emit("removeListener",type,list5.listener||listener2));else if(typeof list5!="function"){for(position2=-1,i2=list5.length-1;i2>=0;i2--)if(list5[i2]===listener2||list5[i2].listener===listener2){originalListener=list5[i2].listener,position2=i2;break}if(position2<0)return this;position2===0?list5.shift():spliceOne(list5,position2),list5.length===1&&(events[type]=list5[0]),events.removeListener!==void 0&&this.emit("removeListener",type,originalListener||listener2)}return this};EventEmitter.prototype.off=EventEmitter.prototype.removeListener;EventEmitter.prototype.removeAllListeners=function(type){var listeners,events,i2;if(events=this._events,events===void 0)return this;if(events.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):events[type]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete events[type]),this;if(arguments.length===0){var keys=Object.keys(events),key;for(i2=0;i2<keys.length;++i2)key=keys[i2],key!=="removeListener"&&this.removeAllListeners(key);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(listeners=events[type],typeof listeners=="function")this.removeListener(type,listeners);else if(listeners!==void 0)for(i2=listeners.length-1;i2>=0;i2--)this.removeListener(type,listeners[i2]);return this};function _listeners(target,type,unwrap){var events=target._events;if(events===void 0)return[];var evlistener=events[type];return evlistener===void 0?[]:typeof evlistener=="function"?unwrap?[evlistener.listener||evlistener]:[evlistener]:unwrap?unwrapListeners(evlistener):arrayClone(evlistener,evlistener.length)}EventEmitter.prototype.listeners=function(type){return _listeners(this,type,!0)};EventEmitter.prototype.rawListeners=function(type){return _listeners(this,type,!1)};EventEmitter.listenerCount=function(emitter,type){return typeof emitter.listenerCount=="function"?emitter.listenerCount(type):listenerCount.call(emitter,type)};EventEmitter.prototype.listenerCount=listenerCount;function listenerCount(type){var events=this._events;if(events!==void 0){var evlistener=events[type];if(typeof evlistener=="function")return 1;if(evlistener!==void 0)return evlistener.length}return 0}EventEmitter.prototype.eventNames=function(){return this._eventsCount>0?ReflectOwnKeys(this._events):[]};function arrayClone(arr,n2){for(var copy=new Array(n2),i2=0;i2<n2;++i2)copy[i2]=arr[i2];return copy}function spliceOne(list5,index4){for(;index4+1<list5.length;index4++)list5[index4]=list5[index4+1];list5.pop()}function unwrapListeners(arr){for(var ret=new Array(arr.length),i2=0;i2<ret.length;++i2)ret[i2]=arr[i2].listener||arr[i2];return ret}function once(emitter,name){return new Promise(function(resolve2,reject){function errorListener(err){emitter.removeListener(name,resolver2),reject(err)}function resolver2(){typeof emitter.removeListener=="function"&&emitter.removeListener("error",errorListener),resolve2([].slice.call(arguments))}eventTargetAgnosticAddListener(emitter,name,resolver2,{once:!0}),name!=="error"&&addErrorHandlerIfEventEmitter(emitter,errorListener,{once:!0})})}function addErrorHandlerIfEventEmitter(emitter,handler2,flags){typeof emitter.on=="function"&&eventTargetAgnosticAddListener(emitter,"error",handler2,flags)}function eventTargetAgnosticAddListener(emitter,name,listener2,flags){if(typeof emitter.on=="function")flags.once?emitter.once(name,listener2):emitter.on(name,listener2);else if(typeof emitter.addEventListener=="function")emitter.addEventListener(name,function wrapListener(arg){flags.once&&emitter.removeEventListener(name,wrapListener),listener2(arg)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof emitter)}}});var require_util3=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/util.js"(exports,module){"use strict";init_browser_globals();var bufferModule=require_buffer(),{format:format5,inspect}=require_inspect2(),{codes:{ERR_INVALID_ARG_TYPE}}=require_errors2(),{kResistStopPropagation,AggregateError:AggregateError2,SymbolDispose}=require_primordials(),AbortSignal2=globalThis.AbortSignal||require_browser2().AbortSignal,AbortController2=globalThis.AbortController||require_browser2().AbortController,AsyncFunction=Object.getPrototypeOf(async function(){}).constructor,Blob2=globalThis.Blob||bufferModule.Blob,isBlob=typeof Blob2<"u"?function(b2){return b2 instanceof Blob2}:function(b2){return!1},validateAbortSignal=(signal,name)=>{if(signal!==void 0&&(signal===null||typeof signal!="object"||!("aborted"in signal)))throw new ERR_INVALID_ARG_TYPE(name,"AbortSignal",signal)},validateFunction=(value2,name)=>{if(typeof value2!="function")throw new ERR_INVALID_ARG_TYPE(name,"Function",value2)};module.exports={AggregateError:AggregateError2,kEmptyObject:Object.freeze({}),once(callback){let called=!1;return function(...args){called||(called=!0,callback.apply(this,args))}},createDeferredPromise:function(){let resolve2,reject;return{promise:new Promise((res,rej)=>{resolve2=res,reject=rej}),resolve:resolve2,reject}},promisify(fn2){return new Promise((resolve2,reject)=>{fn2((err,...args)=>err?reject(err):resolve2(...args))})},debuglog(){return function(){}},format:format5,inspect,types:{isAsyncFunction(fn2){return fn2 instanceof AsyncFunction},isArrayBufferView(arr){return ArrayBuffer.isView(arr)}},isBlob,deprecate(fn2,message){return fn2},addAbortListener:require_events().addAbortListener||function(signal,listener2){if(signal===void 0)throw new ERR_INVALID_ARG_TYPE("signal","AbortSignal",signal);validateAbortSignal(signal,"signal"),validateFunction(listener2,"listener");let removeEventListener;return signal.aborted?queueMicrotask(()=>listener2()):(signal.addEventListener("abort",listener2,{__proto__:null,once:!0,[kResistStopPropagation]:!0}),removeEventListener=()=>{signal.removeEventListener("abort",listener2)}),{__proto__:null,[SymbolDispose](){var _removeEventListener;(_removeEventListener=removeEventListener)===null||_removeEventListener===void 0||_removeEventListener()}}},AbortSignalAny:AbortSignal2.any||function(signals){if(signals.length===1)return signals[0];let ac=new AbortController2,abort=()=>ac.abort();return signals.forEach(signal=>{validateAbortSignal(signal,"signals"),signal.addEventListener("abort",abort,{once:!0})}),ac.signal.addEventListener("abort",()=>{signals.forEach(signal=>signal.removeEventListener("abort",abort))},{once:!0}),ac.signal}};module.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}});var require_validators2=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/validators.js"(exports,module){"use strict";init_browser_globals();var{ArrayIsArray,ArrayPrototypeIncludes,ArrayPrototypeJoin,ArrayPrototypeMap,NumberIsInteger,NumberIsNaN,NumberMAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER,NumberParseInt,ObjectPrototypeHasOwnProperty,RegExpPrototypeExec,String:String2,StringPrototypeToUpperCase,StringPrototypeTrim}=require_primordials(),{hideStackFrames,codes:{ERR_SOCKET_BAD_PORT,ERR_INVALID_ARG_TYPE,ERR_INVALID_ARG_VALUE,ERR_OUT_OF_RANGE,ERR_UNKNOWN_SIGNAL}}=require_errors2(),{normalizeEncoding}=require_util3(),{isAsyncFunction,isArrayBufferView}=require_util3().types,signals={};function isInt32(value2){return value2===(value2|0)}function isUint32(value2){return value2===value2>>>0}var octalReg=/^[0-7]+$/,modeDesc="must be a 32-bit unsigned integer or an octal string";function parseFileMode(value2,name,def){if(typeof value2>"u"&&(value2=def),typeof value2=="string"){if(RegExpPrototypeExec(octalReg,value2)===null)throw new ERR_INVALID_ARG_VALUE(name,value2,modeDesc);value2=NumberParseInt(value2,8)}return validateUint32(value2,name),value2}var validateInteger=hideStackFrames((value2,name,min=NumberMIN_SAFE_INTEGER,max=NumberMAX_SAFE_INTEGER)=>{if(typeof value2!="number")throw new ERR_INVALID_ARG_TYPE(name,"number",value2);if(!NumberIsInteger(value2))throw new ERR_OUT_OF_RANGE(name,"an integer",value2);if(value2<min||value2>max)throw new ERR_OUT_OF_RANGE(name,`>= ${min} && <= ${max}`,value2)}),validateInt32=hideStackFrames((value2,name,min=-2147483648,max=2147483647)=>{if(typeof value2!="number")throw new ERR_INVALID_ARG_TYPE(name,"number",value2);if(!NumberIsInteger(value2))throw new ERR_OUT_OF_RANGE(name,"an integer",value2);if(value2<min||value2>max)throw new ERR_OUT_OF_RANGE(name,`>= ${min} && <= ${max}`,value2)}),validateUint32=hideStackFrames((value2,name,positive=!1)=>{if(typeof value2!="number")throw new ERR_INVALID_ARG_TYPE(name,"number",value2);if(!NumberIsInteger(value2))throw new ERR_OUT_OF_RANGE(name,"an integer",value2);let min=positive?1:0,max=4294967295;if(value2<min||value2>max)throw new ERR_OUT_OF_RANGE(name,`>= ${min} && <= ${max}`,value2)});function validateString(value2,name){if(typeof value2!="string")throw new ERR_INVALID_ARG_TYPE(name,"string",value2)}function validateNumber(value2,name,min=void 0,max){if(typeof value2!="number")throw new ERR_INVALID_ARG_TYPE(name,"number",value2);if(min!=null&&value2<min||max!=null&&value2>max||(min!=null||max!=null)&&NumberIsNaN(value2))throw new ERR_OUT_OF_RANGE(name,`${min!=null?`>= ${min}`:""}${min!=null&&max!=null?" && ":""}${max!=null?`<= ${max}`:""}`,value2)}var validateOneOf=hideStackFrames((value2,name,oneOf)=>{if(!ArrayPrototypeIncludes(oneOf,value2)){let reason="must be one of: "+ArrayPrototypeJoin(ArrayPrototypeMap(oneOf,v2=>typeof v2=="string"?`'${v2}'`:String2(v2)),", ");throw new ERR_INVALID_ARG_VALUE(name,value2,reason)}});function validateBoolean(value2,name){if(typeof value2!="boolean")throw new ERR_INVALID_ARG_TYPE(name,"boolean",value2)}function getOwnPropertyValueOrDefault(options2,key,defaultValue){return options2==null||!ObjectPrototypeHasOwnProperty(options2,key)?defaultValue:options2[key]}var validateObject=hideStackFrames((value2,name,options2=null)=>{let allowArray=getOwnPropertyValueOrDefault(options2,"allowArray",!1),allowFunction=getOwnPropertyValueOrDefault(options2,"allowFunction",!1);if(!getOwnPropertyValueOrDefault(options2,"nullable",!1)&&value2===null||!allowArray&&ArrayIsArray(value2)||typeof value2!="object"&&(!allowFunction||typeof value2!="function"))throw new ERR_INVALID_ARG_TYPE(name,"Object",value2)}),validateDictionary=hideStackFrames((value2,name)=>{if(value2!=null&&typeof value2!="object"&&typeof value2!="function")throw new ERR_INVALID_ARG_TYPE(name,"a dictionary",value2)}),validateArray=hideStackFrames((value2,name,minLength=0)=>{if(!ArrayIsArray(value2))throw new ERR_INVALID_ARG_TYPE(name,"Array",value2);if(value2.length<minLength){let reason=`must be longer than ${minLength}`;throw new ERR_INVALID_ARG_VALUE(name,value2,reason)}});function validateStringArray(value2,name){validateArray(value2,name);for(let i2=0;i2<value2.length;i2++)validateString(value2[i2],`${name}[${i2}]`)}function validateBooleanArray(value2,name){validateArray(value2,name);for(let i2=0;i2<value2.length;i2++)validateBoolean(value2[i2],`${name}[${i2}]`)}function validateAbortSignalArray(value2,name){validateArray(value2,name);for(let i2=0;i2<value2.length;i2++){let signal=value2[i2],indexedName=`${name}[${i2}]`;if(signal==null)throw new ERR_INVALID_ARG_TYPE(indexedName,"AbortSignal",signal);validateAbortSignal(signal,indexedName)}}function validateSignalName(signal,name="signal"){if(validateString(signal,name),signals[signal]===void 0)throw signals[StringPrototypeToUpperCase(signal)]!==void 0?new ERR_UNKNOWN_SIGNAL(signal+" (signals must use all capital letters)"):new ERR_UNKNOWN_SIGNAL(signal)}var validateBuffer=hideStackFrames((buffer,name="buffer")=>{if(!isArrayBufferView(buffer))throw new ERR_INVALID_ARG_TYPE(name,["Buffer","TypedArray","DataView"],buffer)});function validateEncoding(data,encoding){let normalizedEncoding=normalizeEncoding(encoding),length=data.length;if(normalizedEncoding==="hex"&&length%2!==0)throw new ERR_INVALID_ARG_VALUE("encoding",encoding,`is invalid for data of length ${length}`)}function validatePort(port,name="Port",allowZero=!0){if(typeof port!="number"&&typeof port!="string"||typeof port=="string"&&StringPrototypeTrim(port).length===0||+port!==+port>>>0||port>65535||port===0&&!allowZero)throw new ERR_SOCKET_BAD_PORT(name,port,allowZero);return port|0}var validateAbortSignal=hideStackFrames((signal,name)=>{if(signal!==void 0&&(signal===null||typeof signal!="object"||!("aborted"in signal)))throw new ERR_INVALID_ARG_TYPE(name,"AbortSignal",signal)}),validateFunction=hideStackFrames((value2,name)=>{if(typeof value2!="function")throw new ERR_INVALID_ARG_TYPE(name,"Function",value2)}),validatePlainFunction=hideStackFrames((value2,name)=>{if(typeof value2!="function"||isAsyncFunction(value2))throw new ERR_INVALID_ARG_TYPE(name,"Function",value2)}),validateUndefined=hideStackFrames((value2,name)=>{if(value2!==void 0)throw new ERR_INVALID_ARG_TYPE(name,"undefined",value2)});function validateUnion(value2,name,union){if(!ArrayPrototypeIncludes(union,value2))throw new ERR_INVALID_ARG_TYPE(name,`('${ArrayPrototypeJoin(union,"|")}')`,value2)}var linkValueRegExp=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function validateLinkHeaderFormat(value2,name){if(typeof value2>"u"||!RegExpPrototypeExec(linkValueRegExp,value2))throw new ERR_INVALID_ARG_VALUE(name,value2,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}function validateLinkHeaderValue(hints){if(typeof hints=="string")return validateLinkHeaderFormat(hints,"hints"),hints;if(ArrayIsArray(hints)){let hintsLength=hints.length,result="";if(hintsLength===0)return result;for(let i2=0;i2<hintsLength;i2++){let link2=hints[i2];validateLinkHeaderFormat(link2,"hints"),result+=link2,i2!==hintsLength-1&&(result+=", ")}return result}throw new ERR_INVALID_ARG_VALUE("hints",hints,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}module.exports={isInt32,isUint32,parseFileMode,validateArray,validateStringArray,validateBooleanArray,validateAbortSignalArray,validateBoolean,validateBuffer,validateDictionary,validateEncoding,validateFunction,validateInt32,validateInteger,validateNumber,validateObject,validateOneOf,validatePlainFunction,validatePort,validateSignalName,validateString,validateUint32,validateUndefined,validateUnion,validateAbortSignal,validateLinkHeaderValue}}});var require_process2=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/shims/process.js"(exports,module){"use strict";init_browser_globals();var process2=((base2,esmKey,keys,isValid)=>{if(esmKey in base2&&base2[esmKey]===!0){let candidate;for(let key of keys)if(key in base2&&(candidate=base2[key],isValid(candidate)))return candidate}return base2})(require_browser(),"__esModule",["default","process"],candidate=>"nextTick"in candidate);module.exports=process2}});var require_utils=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/utils.js"(exports,module){"use strict";init_browser_globals();var{SymbolAsyncIterator,SymbolIterator,SymbolFor}=require_primordials(),kIsDestroyed=SymbolFor("nodejs.stream.destroyed"),kIsErrored=SymbolFor("nodejs.stream.errored"),kIsReadable=SymbolFor("nodejs.stream.readable"),kIsWritable=SymbolFor("nodejs.stream.writable"),kIsDisturbed=SymbolFor("nodejs.stream.disturbed"),kIsClosedPromise=SymbolFor("nodejs.webstream.isClosedPromise"),kControllerErrorFunction=SymbolFor("nodejs.webstream.controllerErrorFunction");function isReadableNodeStream(obj,strict=!1){var _obj$_readableState;return!!(obj&&typeof obj.pipe=="function"&&typeof obj.on=="function"&&(!strict||typeof obj.pause=="function"&&typeof obj.resume=="function")&&(!obj._writableState||((_obj$_readableState=obj._readableState)===null||_obj$_readableState===void 0?void 0:_obj$_readableState.readable)!==!1)&&(!obj._writableState||obj._readableState))}function isWritableNodeStream(obj){var _obj$_writableState;return!!(obj&&typeof obj.write=="function"&&typeof obj.on=="function"&&(!obj._readableState||((_obj$_writableState=obj._writableState)===null||_obj$_writableState===void 0?void 0:_obj$_writableState.writable)!==!1))}function isDuplexNodeStream(obj){return!!(obj&&typeof obj.pipe=="function"&&obj._readableState&&typeof obj.on=="function"&&typeof obj.write=="function")}function isNodeStream(obj){return obj&&(obj._readableState||obj._writableState||typeof obj.write=="function"&&typeof obj.on=="function"||typeof obj.pipe=="function"&&typeof obj.on=="function")}function isReadableStream(obj){return!!(obj&&!isNodeStream(obj)&&typeof obj.pipeThrough=="function"&&typeof obj.getReader=="function"&&typeof obj.cancel=="function")}function isWritableStream(obj){return!!(obj&&!isNodeStream(obj)&&typeof obj.getWriter=="function"&&typeof obj.abort=="function")}function isTransformStream(obj){return!!(obj&&!isNodeStream(obj)&&typeof obj.readable=="object"&&typeof obj.writable=="object")}function isWebStream(obj){return isReadableStream(obj)||isWritableStream(obj)||isTransformStream(obj)}function isIterable(obj,isAsync){return obj==null?!1:isAsync===!0?typeof obj[SymbolAsyncIterator]=="function":isAsync===!1?typeof obj[SymbolIterator]=="function":typeof obj[SymbolAsyncIterator]=="function"||typeof obj[SymbolIterator]=="function"}function isDestroyed(stream){if(!isNodeStream(stream))return null;let wState=stream._writableState,rState=stream._readableState,state=wState||rState;return!!(stream.destroyed||stream[kIsDestroyed]||state!=null&&state.destroyed)}function isWritableEnded(stream){if(!isWritableNodeStream(stream))return null;if(stream.writableEnded===!0)return!0;let wState=stream._writableState;return wState!=null&&wState.errored?!1:typeof wState?.ended!="boolean"?null:wState.ended}function isWritableFinished(stream,strict){if(!isWritableNodeStream(stream))return null;if(stream.writableFinished===!0)return!0;let wState=stream._writableState;return wState!=null&&wState.errored?!1:typeof wState?.finished!="boolean"?null:!!(wState.finished||strict===!1&&wState.ended===!0&&wState.length===0)}function isReadableEnded(stream){if(!isReadableNodeStream(stream))return null;if(stream.readableEnded===!0)return!0;let rState=stream._readableState;return!rState||rState.errored?!1:typeof rState?.ended!="boolean"?null:rState.ended}function isReadableFinished(stream,strict){if(!isReadableNodeStream(stream))return null;let rState=stream._readableState;return rState!=null&&rState.errored?!1:typeof rState?.endEmitted!="boolean"?null:!!(rState.endEmitted||strict===!1&&rState.ended===!0&&rState.length===0)}function isReadable(stream){return stream&&stream[kIsReadable]!=null?stream[kIsReadable]:typeof stream?.readable!="boolean"?null:isDestroyed(stream)?!1:isReadableNodeStream(stream)&&stream.readable&&!isReadableFinished(stream)}function isWritable(stream){return stream&&stream[kIsWritable]!=null?stream[kIsWritable]:typeof stream?.writable!="boolean"?null:isDestroyed(stream)?!1:isWritableNodeStream(stream)&&stream.writable&&!isWritableEnded(stream)}function isFinished(stream,opts){return isNodeStream(stream)?isDestroyed(stream)?!0:!(opts?.readable!==!1&&isReadable(stream)||opts?.writable!==!1&&isWritable(stream)):null}function isWritableErrored(stream){var _stream$_writableStat,_stream$_writableStat2;return isNodeStream(stream)?stream.writableErrored?stream.writableErrored:(_stream$_writableStat=(_stream$_writableStat2=stream._writableState)===null||_stream$_writableStat2===void 0?void 0:_stream$_writableStat2.errored)!==null&&_stream$_writableStat!==void 0?_stream$_writableStat:null:null}function isReadableErrored(stream){var _stream$_readableStat,_stream$_readableStat2;return isNodeStream(stream)?stream.readableErrored?stream.readableErrored:(_stream$_readableStat=(_stream$_readableStat2=stream._readableState)===null||_stream$_readableStat2===void 0?void 0:_stream$_readableStat2.errored)!==null&&_stream$_readableStat!==void 0?_stream$_readableStat:null:null}function isClosed(stream){if(!isNodeStream(stream))return null;if(typeof stream.closed=="boolean")return stream.closed;let wState=stream._writableState,rState=stream._readableState;return typeof wState?.closed=="boolean"||typeof rState?.closed=="boolean"?wState?.closed||rState?.closed:typeof stream._closed=="boolean"&&isOutgoingMessage(stream)?stream._closed:null}function isOutgoingMessage(stream){return typeof stream._closed=="boolean"&&typeof stream._defaultKeepAlive=="boolean"&&typeof stream._removedConnection=="boolean"&&typeof stream._removedContLen=="boolean"}function isServerResponse(stream){return typeof stream._sent100=="boolean"&&isOutgoingMessage(stream)}function isServerRequest(stream){var _stream$req;return typeof stream._consuming=="boolean"&&typeof stream._dumped=="boolean"&&((_stream$req=stream.req)===null||_stream$req===void 0?void 0:_stream$req.upgradeOrConnect)===void 0}function willEmitClose(stream){if(!isNodeStream(stream))return null;let wState=stream._writableState,rState=stream._readableState,state=wState||rState;return!state&&isServerResponse(stream)||!!(state&&state.autoDestroy&&state.emitClose&&state.closed===!1)}function isDisturbed(stream){var _stream$kIsDisturbed;return!!(stream&&((_stream$kIsDisturbed=stream[kIsDisturbed])!==null&&_stream$kIsDisturbed!==void 0?_stream$kIsDisturbed:stream.readableDidRead||stream.readableAborted))}function isErrored(stream){var _ref,_ref2,_ref3,_ref4,_ref5,_stream$kIsErrored,_stream$_readableStat3,_stream$_writableStat3,_stream$_readableStat4,_stream$_writableStat4;return!!(stream&&((_ref=(_ref2=(_ref3=(_ref4=(_ref5=(_stream$kIsErrored=stream[kIsErrored])!==null&&_stream$kIsErrored!==void 0?_stream$kIsErrored:stream.readableErrored)!==null&&_ref5!==void 0?_ref5:stream.writableErrored)!==null&&_ref4!==void 0?_ref4:(_stream$_readableStat3=stream._readableState)===null||_stream$_readableStat3===void 0?void 0:_stream$_readableStat3.errorEmitted)!==null&&_ref3!==void 0?_ref3:(_stream$_writableStat3=stream._writableState)===null||_stream$_writableStat3===void 0?void 0:_stream$_writableStat3.errorEmitted)!==null&&_ref2!==void 0?_ref2:(_stream$_readableStat4=stream._readableState)===null||_stream$_readableStat4===void 0?void 0:_stream$_readableStat4.errored)!==null&&_ref!==void 0?_ref:!((_stream$_writableStat4=stream._writableState)===null||_stream$_writableStat4===void 0)&&_stream$_writableStat4.errored))}module.exports={isDestroyed,kIsDestroyed,isDisturbed,kIsDisturbed,isErrored,kIsErrored,isReadable,kIsReadable,kIsClosedPromise,kControllerErrorFunction,kIsWritable,isClosed,isDuplexNodeStream,isFinished,isIterable,isReadableNodeStream,isReadableStream,isReadableEnded,isReadableFinished,isReadableErrored,isNodeStream,isWebStream,isWritable,isWritableNodeStream,isWritableStream,isWritableEnded,isWritableFinished,isWritableErrored,isServerRequest,isServerResponse,willEmitClose,isTransformStream}}});var require_end_of_stream=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/end-of-stream.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{AbortError,codes:codes2}=require_errors2(),{ERR_INVALID_ARG_TYPE,ERR_STREAM_PREMATURE_CLOSE}=codes2,{kEmptyObject,once}=require_util3(),{validateAbortSignal,validateFunction,validateObject,validateBoolean}=require_validators2(),{Promise:Promise2,PromisePrototypeThen,SymbolDispose}=require_primordials(),{isClosed,isReadable,isReadableNodeStream,isReadableStream,isReadableFinished,isReadableErrored,isWritable,isWritableNodeStream,isWritableStream,isWritableFinished,isWritableErrored,isNodeStream,willEmitClose:_willEmitClose,kIsClosedPromise}=require_utils(),addAbortListener;function isRequest(stream){return stream.setHeader&&typeof stream.abort=="function"}var nop=()=>{};function eos(stream,options2,callback){var _options$readable,_options$writable;if(arguments.length===2?(callback=options2,options2=kEmptyObject):options2==null?options2=kEmptyObject:validateObject(options2,"options"),validateFunction(callback,"callback"),validateAbortSignal(options2.signal,"options.signal"),callback=once(callback),isReadableStream(stream)||isWritableStream(stream))return eosWeb(stream,options2,callback);if(!isNodeStream(stream))throw new ERR_INVALID_ARG_TYPE("stream",["ReadableStream","WritableStream","Stream"],stream);let readable=(_options$readable=options2.readable)!==null&&_options$readable!==void 0?_options$readable:isReadableNodeStream(stream),writable=(_options$writable=options2.writable)!==null&&_options$writable!==void 0?_options$writable:isWritableNodeStream(stream),wState=stream._writableState,rState=stream._readableState,onlegacyfinish=()=>{stream.writable||onfinish()},willEmitClose=_willEmitClose(stream)&&isReadableNodeStream(stream)===readable&&isWritableNodeStream(stream)===writable,writableFinished=isWritableFinished(stream,!1),onfinish=()=>{writableFinished=!0,stream.destroyed&&(willEmitClose=!1),!(willEmitClose&&(!stream.readable||readable))&&(!readable||readableFinished)&&callback.call(stream)},readableFinished=isReadableFinished(stream,!1),onend=()=>{readableFinished=!0,stream.destroyed&&(willEmitClose=!1),!(willEmitClose&&(!stream.writable||writable))&&(!writable||writableFinished)&&callback.call(stream)},onerror=err=>{callback.call(stream,err)},closed=isClosed(stream),onclose=()=>{closed=!0;let errored=isWritableErrored(stream)||isReadableErrored(stream);if(errored&&typeof errored!="boolean")return callback.call(stream,errored);if(readable&&!readableFinished&&isReadableNodeStream(stream,!0)&&!isReadableFinished(stream,!1))return callback.call(stream,new ERR_STREAM_PREMATURE_CLOSE);if(writable&&!writableFinished&&!isWritableFinished(stream,!1))return callback.call(stream,new ERR_STREAM_PREMATURE_CLOSE);callback.call(stream)},onclosed=()=>{closed=!0;let errored=isWritableErrored(stream)||isReadableErrored(stream);if(errored&&typeof errored!="boolean")return callback.call(stream,errored);callback.call(stream)},onrequest=()=>{stream.req.on("finish",onfinish)};isRequest(stream)?(stream.on("complete",onfinish),willEmitClose||stream.on("abort",onclose),stream.req?onrequest():stream.on("request",onrequest)):writable&&!wState&&(stream.on("end",onlegacyfinish),stream.on("close",onlegacyfinish)),!willEmitClose&&typeof stream.aborted=="boolean"&&stream.on("aborted",onclose),stream.on("end",onend),stream.on("finish",onfinish),options2.error!==!1&&stream.on("error",onerror),stream.on("close",onclose),closed?process2.nextTick(onclose):wState!=null&&wState.errorEmitted||rState!=null&&rState.errorEmitted?willEmitClose||process2.nextTick(onclosed):(!readable&&(!willEmitClose||isReadable(stream))&&(writableFinished||isWritable(stream)===!1)||!writable&&(!willEmitClose||isWritable(stream))&&(readableFinished||isReadable(stream)===!1)||rState&&stream.req&&stream.aborted)&&process2.nextTick(onclosed);let cleanup=()=>{callback=nop,stream.removeListener("aborted",onclose),stream.removeListener("complete",onfinish),stream.removeListener("abort",onclose),stream.removeListener("request",onrequest),stream.req&&stream.req.removeListener("finish",onfinish),stream.removeListener("end",onlegacyfinish),stream.removeListener("close",onlegacyfinish),stream.removeListener("finish",onfinish),stream.removeListener("end",onend),stream.removeListener("error",onerror),stream.removeListener("close",onclose)};if(options2.signal&&!closed){let abort=()=>{let endCallback=callback;cleanup(),endCallback.call(stream,new AbortError(void 0,{cause:options2.signal.reason}))};if(options2.signal.aborted)process2.nextTick(abort);else{addAbortListener=addAbortListener||require_util3().addAbortListener;let disposable=addAbortListener(options2.signal,abort),originalCallback=callback;callback=once((...args)=>{disposable[SymbolDispose](),originalCallback.apply(stream,args)})}}return cleanup}function eosWeb(stream,options2,callback){let isAborted=!1,abort=nop;if(options2.signal)if(abort=()=>{isAborted=!0,callback.call(stream,new AbortError(void 0,{cause:options2.signal.reason}))},options2.signal.aborted)process2.nextTick(abort);else{addAbortListener=addAbortListener||require_util3().addAbortListener;let disposable=addAbortListener(options2.signal,abort),originalCallback=callback;callback=once((...args)=>{disposable[SymbolDispose](),originalCallback.apply(stream,args)})}let resolverFn=(...args)=>{isAborted||process2.nextTick(()=>callback.apply(stream,args))};return PromisePrototypeThen(stream[kIsClosedPromise].promise,resolverFn,resolverFn),nop}function finished(stream,opts){var _opts;let autoCleanup=!1;return opts===null&&(opts=kEmptyObject),(_opts=opts)!==null&&_opts!==void 0&&_opts.cleanup&&(validateBoolean(opts.cleanup,"cleanup"),autoCleanup=opts.cleanup),new Promise2((resolve2,reject)=>{let cleanup=eos(stream,opts,err=>{autoCleanup&&cleanup(),err?reject(err):resolve2()})})}module.exports=eos;module.exports.finished=finished}});var require_destroy=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/destroy.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{aggregateTwoErrors,codes:{ERR_MULTIPLE_CALLBACK},AbortError}=require_errors2(),{Symbol:Symbol2}=require_primordials(),{kIsDestroyed,isDestroyed,isFinished,isServerRequest}=require_utils(),kDestroy=Symbol2("kDestroy"),kConstruct=Symbol2("kConstruct");function checkError(err,w2,r2){err&&(err.stack,w2&&!w2.errored&&(w2.errored=err),r2&&!r2.errored&&(r2.errored=err))}function destroy(err,cb){let r2=this._readableState,w2=this._writableState,s2=w2||r2;return w2!=null&&w2.destroyed||r2!=null&&r2.destroyed?(typeof cb=="function"&&cb(),this):(checkError(err,w2,r2),w2&&(w2.destroyed=!0),r2&&(r2.destroyed=!0),s2.constructed?_destroy(this,err,cb):this.once(kDestroy,function(er2){_destroy(this,aggregateTwoErrors(er2,err),cb)}),this)}function _destroy(self2,err,cb){let called=!1;function onDestroy(err2){if(called)return;called=!0;let r2=self2._readableState,w2=self2._writableState;checkError(err2,w2,r2),w2&&(w2.closed=!0),r2&&(r2.closed=!0),typeof cb=="function"&&cb(err2),err2?process2.nextTick(emitErrorCloseNT,self2,err2):process2.nextTick(emitCloseNT,self2)}try{self2._destroy(err||null,onDestroy)}catch(err2){onDestroy(err2)}}function emitErrorCloseNT(self2,err){emitErrorNT(self2,err),emitCloseNT(self2)}function emitCloseNT(self2){let r2=self2._readableState,w2=self2._writableState;w2&&(w2.closeEmitted=!0),r2&&(r2.closeEmitted=!0),(w2!=null&&w2.emitClose||r2!=null&&r2.emitClose)&&self2.emit("close")}function emitErrorNT(self2,err){let r2=self2._readableState,w2=self2._writableState;w2!=null&&w2.errorEmitted||r2!=null&&r2.errorEmitted||(w2&&(w2.errorEmitted=!0),r2&&(r2.errorEmitted=!0),self2.emit("error",err))}function undestroy(){let r2=this._readableState,w2=this._writableState;r2&&(r2.constructed=!0,r2.closed=!1,r2.closeEmitted=!1,r2.destroyed=!1,r2.errored=null,r2.errorEmitted=!1,r2.reading=!1,r2.ended=r2.readable===!1,r2.endEmitted=r2.readable===!1),w2&&(w2.constructed=!0,w2.destroyed=!1,w2.closed=!1,w2.closeEmitted=!1,w2.errored=null,w2.errorEmitted=!1,w2.finalCalled=!1,w2.prefinished=!1,w2.ended=w2.writable===!1,w2.ending=w2.writable===!1,w2.finished=w2.writable===!1)}function errorOrDestroy(stream,err,sync){let r2=stream._readableState,w2=stream._writableState;if(w2!=null&&w2.destroyed||r2!=null&&r2.destroyed)return this;r2!=null&&r2.autoDestroy||w2!=null&&w2.autoDestroy?stream.destroy(err):err&&(err.stack,w2&&!w2.errored&&(w2.errored=err),r2&&!r2.errored&&(r2.errored=err),sync?process2.nextTick(emitErrorNT,stream,err):emitErrorNT(stream,err))}function construct(stream,cb){if(typeof stream._construct!="function")return;let r2=stream._readableState,w2=stream._writableState;r2&&(r2.constructed=!1),w2&&(w2.constructed=!1),stream.once(kConstruct,cb),!(stream.listenerCount(kConstruct)>1)&&process2.nextTick(constructNT,stream)}function constructNT(stream){let called=!1;function onConstruct(err){if(called){errorOrDestroy(stream,err??new ERR_MULTIPLE_CALLBACK);return}called=!0;let r2=stream._readableState,w2=stream._writableState,s2=w2||r2;r2&&(r2.constructed=!0),w2&&(w2.constructed=!0),s2.destroyed?stream.emit(kDestroy,err):err?errorOrDestroy(stream,err,!0):process2.nextTick(emitConstructNT,stream)}try{stream._construct(err=>{process2.nextTick(onConstruct,err)})}catch(err){process2.nextTick(onConstruct,err)}}function emitConstructNT(stream){stream.emit(kConstruct)}function isRequest(stream){return stream?.setHeader&&typeof stream.abort=="function"}function emitCloseLegacy(stream){stream.emit("close")}function emitErrorCloseLegacy(stream,err){stream.emit("error",err),process2.nextTick(emitCloseLegacy,stream)}function destroyer(stream,err){!stream||isDestroyed(stream)||(!err&&!isFinished(stream)&&(err=new AbortError),isServerRequest(stream)?(stream.socket=null,stream.destroy(err)):isRequest(stream)?stream.abort():isRequest(stream.req)?stream.req.abort():typeof stream.destroy=="function"?stream.destroy(err):typeof stream.close=="function"?stream.close():err?process2.nextTick(emitErrorCloseLegacy,stream,err):process2.nextTick(emitCloseLegacy,stream),stream.destroyed||(stream[kIsDestroyed]=!0))}module.exports={construct,destroyer,destroy,undestroy,errorOrDestroy}}});var require_legacy=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/legacy.js"(exports,module){"use strict";init_browser_globals();var{ArrayIsArray,ObjectSetPrototypeOf}=require_primordials(),{EventEmitter:EE}=require_events();function Stream(opts){EE.call(this,opts)}ObjectSetPrototypeOf(Stream.prototype,EE.prototype);ObjectSetPrototypeOf(Stream,EE);Stream.prototype.pipe=function(dest,options2){let source2=this;function ondata(chunk){dest.writable&&dest.write(chunk)===!1&&source2.pause&&source2.pause()}source2.on("data",ondata);function ondrain(){source2.readable&&source2.resume&&source2.resume()}dest.on("drain",ondrain),!dest._isStdio&&(!options2||options2.end!==!1)&&(source2.on("end",onend),source2.on("close",onclose));let didOnEnd=!1;function onend(){didOnEnd||(didOnEnd=!0,dest.end())}function onclose(){didOnEnd||(didOnEnd=!0,typeof dest.destroy=="function"&&dest.destroy())}function onerror(er2){var _this$listenerCount;cleanup(),((_this$listenerCount=this.listenerCount)===null||_this$listenerCount===void 0?void 0:_this$listenerCount.call(this,"error"))===0&&this.emit("error",er2)}prependListener(source2,"error",onerror),prependListener(dest,"error",onerror);function cleanup(){source2.removeListener("data",ondata),dest.removeListener("drain",ondrain),source2.removeListener("end",onend),source2.removeListener("close",onclose),source2.removeListener("error",onerror),dest.removeListener("error",onerror),source2.removeListener("end",cleanup),source2.removeListener("close",cleanup),dest.removeListener("close",cleanup)}return source2.on("end",cleanup),source2.on("close",cleanup),dest.on("close",cleanup),dest.emit("pipe",source2),dest};function prependListener(emitter,event,fn2){if(typeof emitter.prependListener=="function")return emitter.prependListener(event,fn2);!emitter._events||!emitter._events[event]?emitter.on(event,fn2):ArrayIsArray(emitter._events[event])?emitter._events[event].unshift(fn2):emitter._events[event]=[fn2,emitter._events[event]]}module.exports={Stream,prependListener}}});var require_add_abort_signal=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/add-abort-signal.js"(exports,module){"use strict";init_browser_globals();var{SymbolDispose}=require_primordials(),{AbortError,codes:codes2}=require_errors2(),{isNodeStream,isWebStream,kControllerErrorFunction}=require_utils(),eos=require_end_of_stream(),{ERR_INVALID_ARG_TYPE}=codes2,addAbortListener,validateAbortSignal=(signal,name)=>{if(typeof signal!="object"||!("aborted"in signal))throw new ERR_INVALID_ARG_TYPE(name,"AbortSignal",signal)};module.exports.addAbortSignal=function(signal,stream){if(validateAbortSignal(signal,"signal"),!isNodeStream(stream)&&!isWebStream(stream))throw new ERR_INVALID_ARG_TYPE("stream",["ReadableStream","WritableStream","Stream"],stream);return module.exports.addAbortSignalNoValidate(signal,stream)};module.exports.addAbortSignalNoValidate=function(signal,stream){if(typeof signal!="object"||!("aborted"in signal))return stream;let onAbort=isNodeStream(stream)?()=>{stream.destroy(new AbortError(void 0,{cause:signal.reason}))}:()=>{stream[kControllerErrorFunction](new AbortError(void 0,{cause:signal.reason}))};if(signal.aborted)onAbort();else{addAbortListener=addAbortListener||require_util3().addAbortListener;let disposable=addAbortListener(signal,onAbort);eos(stream,disposable[SymbolDispose])}return stream}}});var require_buffer_list=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/buffer_list.js"(exports,module){"use strict";init_browser_globals();var{StringPrototypeSlice,SymbolIterator,TypedArrayPrototypeSet,Uint8Array:Uint8Array2}=require_primordials(),{Buffer:Buffer6}=require_buffer(),{inspect}=require_util3();module.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(v2){let entry={data:v2,next:null};this.length>0?this.tail.next=entry:this.head=entry,this.tail=entry,++this.length}unshift(v2){let entry={data:v2,next:this.head};this.length===0&&(this.tail=entry),this.head=entry,++this.length}shift(){if(this.length===0)return;let ret=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,ret}clear(){this.head=this.tail=null,this.length=0}join(s2){if(this.length===0)return"";let p2=this.head,ret=""+p2.data;for(;(p2=p2.next)!==null;)ret+=s2+p2.data;return ret}concat(n2){if(this.length===0)return Buffer6.alloc(0);let ret=Buffer6.allocUnsafe(n2>>>0),p2=this.head,i2=0;for(;p2;)TypedArrayPrototypeSet(ret,p2.data,i2),i2+=p2.data.length,p2=p2.next;return ret}consume(n2,hasStrings){let data=this.head.data;if(n2<data.length){let slice=data.slice(0,n2);return this.head.data=data.slice(n2),slice}return n2===data.length?this.shift():hasStrings?this._getString(n2):this._getBuffer(n2)}first(){return this.head.data}*[SymbolIterator](){for(let p2=this.head;p2;p2=p2.next)yield p2.data}_getString(n2){let ret="",p2=this.head,c2=0;do{let str=p2.data;if(n2>str.length)ret+=str,n2-=str.length;else{n2===str.length?(ret+=str,++c2,p2.next?this.head=p2.next:this.head=this.tail=null):(ret+=StringPrototypeSlice(str,0,n2),this.head=p2,p2.data=StringPrototypeSlice(str,n2));break}++c2}while((p2=p2.next)!==null);return this.length-=c2,ret}_getBuffer(n2){let ret=Buffer6.allocUnsafe(n2),retLen=n2,p2=this.head,c2=0;do{let buf=p2.data;if(n2>buf.length)TypedArrayPrototypeSet(ret,buf,retLen-n2),n2-=buf.length;else{n2===buf.length?(TypedArrayPrototypeSet(ret,buf,retLen-n2),++c2,p2.next?this.head=p2.next:this.head=this.tail=null):(TypedArrayPrototypeSet(ret,new Uint8Array2(buf.buffer,buf.byteOffset,n2),retLen-n2),this.head=p2,p2.data=buf.slice(n2));break}++c2}while((p2=p2.next)!==null);return this.length-=c2,ret}[Symbol.for("nodejs.util.inspect.custom")](_2,options2){return inspect(this,{...options2,depth:0,customInspect:!1})}}}});var require_state=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/state.js"(exports,module){"use strict";init_browser_globals();var{MathFloor,NumberIsInteger}=require_primordials(),{validateInteger}=require_validators2(),{ERR_INVALID_ARG_VALUE}=require_errors2().codes,defaultHighWaterMarkBytes=16*1024,defaultHighWaterMarkObjectMode=16;function highWaterMarkFrom(options2,isDuplex,duplexKey){return options2.highWaterMark!=null?options2.highWaterMark:isDuplex?options2[duplexKey]:null}function getDefaultHighWaterMark(objectMode){return objectMode?defaultHighWaterMarkObjectMode:defaultHighWaterMarkBytes}function setDefaultHighWaterMark(objectMode,value2){validateInteger(value2,"value",0),objectMode?defaultHighWaterMarkObjectMode=value2:defaultHighWaterMarkBytes=value2}function getHighWaterMark(state,options2,duplexKey,isDuplex){let hwm=highWaterMarkFrom(options2,isDuplex,duplexKey);if(hwm!=null){if(!NumberIsInteger(hwm)||hwm<0){let name=isDuplex?`options.${duplexKey}`:"options.highWaterMark";throw new ERR_INVALID_ARG_VALUE(name,hwm)}return MathFloor(hwm)}return getDefaultHighWaterMark(state.objectMode)}module.exports={getHighWaterMark,getDefaultHighWaterMark,setDefaultHighWaterMark}}});var require_string_decoder=__commonJS({"node_modules/.pnpm/string_decoder@1.3.0/node_modules/string_decoder/lib/string_decoder.js"(exports){"use strict";init_browser_globals();var Buffer6=require_safe_buffer().Buffer,isEncoding=Buffer6.isEncoding||function(encoding){switch(encoding=""+encoding,encoding&&encoding.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 _normalizeEncoding(enc){if(!enc)return"utf8";for(var retried;;)switch(enc){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 enc;default:if(retried)return;enc=(""+enc).toLowerCase(),retried=!0}}function normalizeEncoding(enc){var nenc=_normalizeEncoding(enc);if(typeof nenc!="string"&&(Buffer6.isEncoding===isEncoding||!isEncoding(enc)))throw new Error("Unknown encoding: "+enc);return nenc||enc}exports.StringDecoder=StringDecoder;function StringDecoder(encoding){this.encoding=normalizeEncoding(encoding);var nb;switch(this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,nb=4;break;case"utf8":this.fillLast=utf8FillLast,nb=4;break;case"base64":this.text=base64Text,this.end=base64End,nb=3;break;default:this.write=simpleWrite,this.end=simpleEnd;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Buffer6.allocUnsafe(nb)}StringDecoder.prototype.write=function(buf){if(buf.length===0)return"";var r2,i2;if(this.lastNeed){if(r2=this.fillLast(buf),r2===void 0)return"";i2=this.lastNeed,this.lastNeed=0}else i2=0;return i2<buf.length?r2?r2+this.text(buf,i2):this.text(buf,i2):r2||""};StringDecoder.prototype.end=utf8End;StringDecoder.prototype.text=utf8Text;StringDecoder.prototype.fillLast=function(buf){if(this.lastNeed<=buf.length)return buf.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);buf.copy(this.lastChar,this.lastTotal-this.lastNeed,0,buf.length),this.lastNeed-=buf.length};function utf8CheckByte(byte){return byte<=127?0:byte>>5===6?2:byte>>4===14?3:byte>>3===30?4:byte>>6===2?-1:-2}function utf8CheckIncomplete(self2,buf,i2){var j=buf.length-1;if(j<i2)return 0;var nb=utf8CheckByte(buf[j]);return nb>=0?(nb>0&&(self2.lastNeed=nb-1),nb):--j<i2||nb===-2?0:(nb=utf8CheckByte(buf[j]),nb>=0?(nb>0&&(self2.lastNeed=nb-2),nb):--j<i2||nb===-2?0:(nb=utf8CheckByte(buf[j]),nb>=0?(nb>0&&(nb===2?nb=0:self2.lastNeed=nb-3),nb):0))}function utf8CheckExtraBytes(self2,buf,p2){if((buf[0]&192)!==128)return self2.lastNeed=0,"\uFFFD";if(self2.lastNeed>1&&buf.length>1){if((buf[1]&192)!==128)return self2.lastNeed=1,"\uFFFD";if(self2.lastNeed>2&&buf.length>2&&(buf[2]&192)!==128)return self2.lastNeed=2,"\uFFFD"}}function utf8FillLast(buf){var p2=this.lastTotal-this.lastNeed,r2=utf8CheckExtraBytes(this,buf,p2);if(r2!==void 0)return r2;if(this.lastNeed<=buf.length)return buf.copy(this.lastChar,p2,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);buf.copy(this.lastChar,p2,0,buf.length),this.lastNeed-=buf.length}function utf8Text(buf,i2){var total=utf8CheckIncomplete(this,buf,i2);if(!this.lastNeed)return buf.toString("utf8",i2);this.lastTotal=total;var end=buf.length-(total-this.lastNeed);return buf.copy(this.lastChar,0,end),buf.toString("utf8",i2,end)}function utf8End(buf){var r2=buf&&buf.length?this.write(buf):"";return this.lastNeed?r2+"\uFFFD":r2}function utf16Text(buf,i2){if((buf.length-i2)%2===0){var r2=buf.toString("utf16le",i2);if(r2){var c2=r2.charCodeAt(r2.length-1);if(c2>=55296&&c2<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=buf[buf.length-2],this.lastChar[1]=buf[buf.length-1],r2.slice(0,-1)}return r2}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=buf[buf.length-1],buf.toString("utf16le",i2,buf.length-1)}function utf16End(buf){var r2=buf&&buf.length?this.write(buf):"";if(this.lastNeed){var end=this.lastTotal-this.lastNeed;return r2+this.lastChar.toString("utf16le",0,end)}return r2}function base64Text(buf,i2){var n2=(buf.length-i2)%3;return n2===0?buf.toString("base64",i2):(this.lastNeed=3-n2,this.lastTotal=3,n2===1?this.lastChar[0]=buf[buf.length-1]:(this.lastChar[0]=buf[buf.length-2],this.lastChar[1]=buf[buf.length-1]),buf.toString("base64",i2,buf.length-n2))}function base64End(buf){var r2=buf&&buf.length?this.write(buf):"";return this.lastNeed?r2+this.lastChar.toString("base64",0,3-this.lastNeed):r2}function simpleWrite(buf){return buf.toString(this.encoding)}function simpleEnd(buf){return buf&&buf.length?this.write(buf):""}}});var require_from=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/from.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{PromisePrototypeThen,SymbolAsyncIterator,SymbolIterator}=require_primordials(),{Buffer:Buffer6}=require_buffer(),{ERR_INVALID_ARG_TYPE,ERR_STREAM_NULL_VALUES}=require_errors2().codes;function from(Readable,iterable,opts){let iterator;if(typeof iterable=="string"||iterable instanceof Buffer6)return new Readable({objectMode:!0,...opts,read(){this.push(iterable),this.push(null)}});let isAsync;if(iterable&&iterable[SymbolAsyncIterator])isAsync=!0,iterator=iterable[SymbolAsyncIterator]();else if(iterable&&iterable[SymbolIterator])isAsync=!1,iterator=iterable[SymbolIterator]();else throw new ERR_INVALID_ARG_TYPE("iterable",["Iterable"],iterable);let readable=new Readable({objectMode:!0,highWaterMark:1,...opts}),reading=!1;readable._read=function(){reading||(reading=!0,next())},readable._destroy=function(error,cb){PromisePrototypeThen(close2(error),()=>process2.nextTick(cb,error),e2=>process2.nextTick(cb,e2||error))};async function close2(error){let hadError=error!=null,hasThrow=typeof iterator.throw=="function";if(hadError&&hasThrow){let{value:value2,done}=await iterator.throw(error);if(await value2,done)return}if(typeof iterator.return=="function"){let{value:value2}=await iterator.return();await value2}}async function next(){for(;;){try{let{value:value2,done}=isAsync?await iterator.next():iterator.next();if(done)readable.push(null);else{let res=value2&&typeof value2.then=="function"?await value2:value2;if(res===null)throw reading=!1,new ERR_STREAM_NULL_VALUES;if(readable.push(res))continue;reading=!1}}catch(err){readable.destroy(err)}break}}return readable}module.exports=from}});var require_readable=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/readable.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{ArrayPrototypeIndexOf,NumberIsInteger,NumberIsNaN,NumberParseInt,ObjectDefineProperties,ObjectKeys,ObjectSetPrototypeOf,Promise:Promise2,SafeSet,SymbolAsyncDispose,SymbolAsyncIterator,Symbol:Symbol2}=require_primordials();module.exports=Readable;Readable.ReadableState=ReadableState;var{EventEmitter:EE}=require_events(),{Stream,prependListener}=require_legacy(),{Buffer:Buffer6}=require_buffer(),{addAbortSignal}=require_add_abort_signal(),eos=require_end_of_stream(),debug=require_util3().debuglog("stream",fn2=>{debug=fn2}),BufferList=require_buffer_list(),destroyImpl=require_destroy(),{getHighWaterMark,getDefaultHighWaterMark}=require_state(),{aggregateTwoErrors,codes:{ERR_INVALID_ARG_TYPE,ERR_METHOD_NOT_IMPLEMENTED,ERR_OUT_OF_RANGE,ERR_STREAM_PUSH_AFTER_EOF,ERR_STREAM_UNSHIFT_AFTER_END_EVENT},AbortError}=require_errors2(),{validateObject}=require_validators2(),kPaused=Symbol2("kPaused"),{StringDecoder}=require_string_decoder(),from=require_from();ObjectSetPrototypeOf(Readable.prototype,Stream.prototype);ObjectSetPrototypeOf(Readable,Stream);var nop=()=>{},{errorOrDestroy}=destroyImpl,kObjectMode=1,kEnded=2,kEndEmitted=4,kReading=8,kConstructed=16,kSync=32,kNeedReadable=64,kEmittedReadable=128,kReadableListening=256,kResumeScheduled=512,kErrorEmitted=1024,kEmitClose=2048,kAutoDestroy=4096,kDestroyed=8192,kClosed=16384,kCloseEmitted=32768,kMultiAwaitDrain=65536,kReadingMore=1<<17,kDataEmitted=1<<18;function makeBitMapDescriptor(bit){return{enumerable:!1,get(){return(this.state&bit)!==0},set(value2){value2?this.state|=bit:this.state&=~bit}}}ObjectDefineProperties(ReadableState.prototype,{objectMode:makeBitMapDescriptor(kObjectMode),ended:makeBitMapDescriptor(kEnded),endEmitted:makeBitMapDescriptor(kEndEmitted),reading:makeBitMapDescriptor(kReading),constructed:makeBitMapDescriptor(kConstructed),sync:makeBitMapDescriptor(kSync),needReadable:makeBitMapDescriptor(kNeedReadable),emittedReadable:makeBitMapDescriptor(kEmittedReadable),readableListening:makeBitMapDescriptor(kReadableListening),resumeScheduled:makeBitMapDescriptor(kResumeScheduled),errorEmitted:makeBitMapDescriptor(kErrorEmitted),emitClose:makeBitMapDescriptor(kEmitClose),autoDestroy:makeBitMapDescriptor(kAutoDestroy),destroyed:makeBitMapDescriptor(kDestroyed),closed:makeBitMapDescriptor(kClosed),closeEmitted:makeBitMapDescriptor(kCloseEmitted),multiAwaitDrain:makeBitMapDescriptor(kMultiAwaitDrain),readingMore:makeBitMapDescriptor(kReadingMore),dataEmitted:makeBitMapDescriptor(kDataEmitted)});function ReadableState(options2,stream,isDuplex){typeof isDuplex!="boolean"&&(isDuplex=stream instanceof require_duplex()),this.state=kEmitClose|kAutoDestroy|kConstructed|kSync,options2&&options2.objectMode&&(this.state|=kObjectMode),isDuplex&&options2&&options2.readableObjectMode&&(this.state|=kObjectMode),this.highWaterMark=options2?getHighWaterMark(this,options2,"readableHighWaterMark",isDuplex):getDefaultHighWaterMark(!1),this.buffer=new BufferList,this.length=0,this.pipes=[],this.flowing=null,this[kPaused]=null,options2&&options2.emitClose===!1&&(this.state&=~kEmitClose),options2&&options2.autoDestroy===!1&&(this.state&=~kAutoDestroy),this.errored=null,this.defaultEncoding=options2&&options2.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,options2&&options2.encoding&&(this.decoder=new StringDecoder(options2.encoding),this.encoding=options2.encoding)}function Readable(options2){if(!(this instanceof Readable))return new Readable(options2);let isDuplex=this instanceof require_duplex();this._readableState=new ReadableState(options2,this,isDuplex),options2&&(typeof options2.read=="function"&&(this._read=options2.read),typeof options2.destroy=="function"&&(this._destroy=options2.destroy),typeof options2.construct=="function"&&(this._construct=options2.construct),options2.signal&&!isDuplex&&addAbortSignal(options2.signal,this)),Stream.call(this,options2),destroyImpl.construct(this,()=>{this._readableState.needReadable&&maybeReadMore(this,this._readableState)})}Readable.prototype.destroy=destroyImpl.destroy;Readable.prototype._undestroy=destroyImpl.undestroy;Readable.prototype._destroy=function(err,cb){cb(err)};Readable.prototype[EE.captureRejectionSymbol]=function(err){this.destroy(err)};Readable.prototype[SymbolAsyncDispose]=function(){let error;return this.destroyed||(error=this.readableEnded?null:new AbortError,this.destroy(error)),new Promise2((resolve2,reject)=>eos(this,err=>err&&err!==error?reject(err):resolve2(null)))};Readable.prototype.push=function(chunk,encoding){return readableAddChunk(this,chunk,encoding,!1)};Readable.prototype.unshift=function(chunk,encoding){return readableAddChunk(this,chunk,encoding,!0)};function readableAddChunk(stream,chunk,encoding,addToFront){debug("readableAddChunk",chunk);let state=stream._readableState,err;if((state.state&kObjectMode)===0&&(typeof chunk=="string"?(encoding=encoding||state.defaultEncoding,state.encoding!==encoding&&(addToFront&&state.encoding?chunk=Buffer6.from(chunk,encoding).toString(state.encoding):(chunk=Buffer6.from(chunk,encoding),encoding=""))):chunk instanceof Buffer6?encoding="":Stream._isUint8Array(chunk)?(chunk=Stream._uint8ArrayToBuffer(chunk),encoding=""):chunk!=null&&(err=new ERR_INVALID_ARG_TYPE("chunk",["string","Buffer","Uint8Array"],chunk))),err)errorOrDestroy(stream,err);else if(chunk===null)state.state&=~kReading,onEofChunk(stream,state);else if((state.state&kObjectMode)!==0||chunk&&chunk.length>0)if(addToFront)if((state.state&kEndEmitted)!==0)errorOrDestroy(stream,new ERR_STREAM_UNSHIFT_AFTER_END_EVENT);else{if(state.destroyed||state.errored)return!1;addChunk(stream,state,chunk,!0)}else if(state.ended)errorOrDestroy(stream,new ERR_STREAM_PUSH_AFTER_EOF);else{if(state.destroyed||state.errored)return!1;state.state&=~kReading,state.decoder&&!encoding?(chunk=state.decoder.write(chunk),state.objectMode||chunk.length!==0?addChunk(stream,state,chunk,!1):maybeReadMore(stream,state)):addChunk(stream,state,chunk,!1)}else addToFront||(state.state&=~kReading,maybeReadMore(stream,state));return!state.ended&&(state.length<state.highWaterMark||state.length===0)}function addChunk(stream,state,chunk,addToFront){state.flowing&&state.length===0&&!state.sync&&stream.listenerCount("data")>0?((state.state&kMultiAwaitDrain)!==0?state.awaitDrainWriters.clear():state.awaitDrainWriters=null,state.dataEmitted=!0,stream.emit("data",chunk)):(state.length+=state.objectMode?1:chunk.length,addToFront?state.buffer.unshift(chunk):state.buffer.push(chunk),(state.state&kNeedReadable)!==0&&emitReadable(stream)),maybeReadMore(stream,state)}Readable.prototype.isPaused=function(){let state=this._readableState;return state[kPaused]===!0||state.flowing===!1};Readable.prototype.setEncoding=function(enc){let decoder=new StringDecoder(enc);this._readableState.decoder=decoder,this._readableState.encoding=this._readableState.decoder.encoding;let buffer=this._readableState.buffer,content3="";for(let data of buffer)content3+=decoder.write(data);return buffer.clear(),content3!==""&&buffer.push(content3),this._readableState.length=content3.length,this};var MAX_HWM=1073741824;function computeNewHighWaterMark(n2){if(n2>MAX_HWM)throw new ERR_OUT_OF_RANGE("size","<= 1GiB",n2);return n2--,n2|=n2>>>1,n2|=n2>>>2,n2|=n2>>>4,n2|=n2>>>8,n2|=n2>>>16,n2++,n2}function howMuchToRead(n2,state){return n2<=0||state.length===0&&state.ended?0:(state.state&kObjectMode)!==0?1:NumberIsNaN(n2)?state.flowing&&state.length?state.buffer.first().length:state.length:n2<=state.length?n2:state.ended?state.length:0}Readable.prototype.read=function(n2){debug("read",n2),n2===void 0?n2=NaN:NumberIsInteger(n2)||(n2=NumberParseInt(n2,10));let state=this._readableState,nOrig=n2;if(n2>state.highWaterMark&&(state.highWaterMark=computeNewHighWaterMark(n2)),n2!==0&&(state.state&=~kEmittedReadable),n2===0&&state.needReadable&&((state.highWaterMark!==0?state.length>=state.highWaterMark:state.length>0)||state.ended))return debug("read: emitReadable",state.length,state.ended),state.length===0&&state.ended?endReadable(this):emitReadable(this),null;if(n2=howMuchToRead(n2,state),n2===0&&state.ended)return state.length===0&&endReadable(this),null;let doRead=(state.state&kNeedReadable)!==0;if(debug("need readable",doRead),(state.length===0||state.length-n2<state.highWaterMark)&&(doRead=!0,debug("length less than watermark",doRead)),state.ended||state.reading||state.destroyed||state.errored||!state.constructed)doRead=!1,debug("reading, ended or constructing",doRead);else if(doRead){debug("do read"),state.state|=kReading|kSync,state.length===0&&(state.state|=kNeedReadable);try{this._read(state.highWaterMark)}catch(err){errorOrDestroy(this,err)}state.state&=~kSync,state.reading||(n2=howMuchToRead(nOrig,state))}let ret;return n2>0?ret=fromList(n2,state):ret=null,ret===null?(state.needReadable=state.length<=state.highWaterMark,n2=0):(state.length-=n2,state.multiAwaitDrain?state.awaitDrainWriters.clear():state.awaitDrainWriters=null),state.length===0&&(state.ended||(state.needReadable=!0),nOrig!==n2&&state.ended&&endReadable(this)),ret!==null&&!state.errorEmitted&&!state.closeEmitted&&(state.dataEmitted=!0,this.emit("data",ret)),ret};function onEofChunk(stream,state){if(debug("onEofChunk"),!state.ended){if(state.decoder){let chunk=state.decoder.end();chunk&&chunk.length&&(state.buffer.push(chunk),state.length+=state.objectMode?1:chunk.length)}state.ended=!0,state.sync?emitReadable(stream):(state.needReadable=!1,state.emittedReadable=!0,emitReadable_(stream))}}function emitReadable(stream){let state=stream._readableState;debug("emitReadable",state.needReadable,state.emittedReadable),state.needReadable=!1,state.emittedReadable||(debug("emitReadable",state.flowing),state.emittedReadable=!0,process2.nextTick(emitReadable_,stream))}function emitReadable_(stream){let state=stream._readableState;debug("emitReadable_",state.destroyed,state.length,state.ended),!state.destroyed&&!state.errored&&(state.length||state.ended)&&(stream.emit("readable"),state.emittedReadable=!1),state.needReadable=!state.flowing&&!state.ended&&state.length<=state.highWaterMark,flow3(stream)}function maybeReadMore(stream,state){!state.readingMore&&state.constructed&&(state.readingMore=!0,process2.nextTick(maybeReadMore_,stream,state))}function maybeReadMore_(stream,state){for(;!state.reading&&!state.ended&&(state.length<state.highWaterMark||state.flowing&&state.length===0);){let len=state.length;if(debug("maybeReadMore read 0"),stream.read(0),len===state.length)break}state.readingMore=!1}Readable.prototype._read=function(n2){throw new ERR_METHOD_NOT_IMPLEMENTED("_read()")};Readable.prototype.pipe=function(dest,pipeOpts){let src=this,state=this._readableState;state.pipes.length===1&&(state.multiAwaitDrain||(state.multiAwaitDrain=!0,state.awaitDrainWriters=new SafeSet(state.awaitDrainWriters?[state.awaitDrainWriters]:[]))),state.pipes.push(dest),debug("pipe count=%d opts=%j",state.pipes.length,pipeOpts);let endFn=(!pipeOpts||pipeOpts.end!==!1)&&dest!==process2.stdout&&dest!==process2.stderr?onend:unpipe;state.endEmitted?process2.nextTick(endFn):src.once("end",endFn),dest.on("unpipe",onunpipe);function onunpipe(readable,unpipeInfo){debug("onunpipe"),readable===src&&unpipeInfo&&unpipeInfo.hasUnpiped===!1&&(unpipeInfo.hasUnpiped=!0,cleanup())}function onend(){debug("onend"),dest.end()}let ondrain,cleanedUp=!1;function cleanup(){debug("cleanup"),dest.removeListener("close",onclose),dest.removeListener("finish",onfinish),ondrain&&dest.removeListener("drain",ondrain),dest.removeListener("error",onerror),dest.removeListener("unpipe",onunpipe),src.removeListener("end",onend),src.removeListener("end",unpipe),src.removeListener("data",ondata),cleanedUp=!0,ondrain&&state.awaitDrainWriters&&(!dest._writableState||dest._writableState.needDrain)&&ondrain()}function pause(){cleanedUp||(state.pipes.length===1&&state.pipes[0]===dest?(debug("false write response, pause",0),state.awaitDrainWriters=dest,state.multiAwaitDrain=!1):state.pipes.length>1&&state.pipes.includes(dest)&&(debug("false write response, pause",state.awaitDrainWriters.size),state.awaitDrainWriters.add(dest)),src.pause()),ondrain||(ondrain=pipeOnDrain(src,dest),dest.on("drain",ondrain))}src.on("data",ondata);function ondata(chunk){debug("ondata");let ret=dest.write(chunk);debug("dest.write",ret),ret===!1&&pause()}function onerror(er2){if(debug("onerror",er2),unpipe(),dest.removeListener("error",onerror),dest.listenerCount("error")===0){let s2=dest._writableState||dest._readableState;s2&&!s2.errorEmitted?errorOrDestroy(dest,er2):dest.emit("error",er2)}}prependListener(dest,"error",onerror);function onclose(){dest.removeListener("finish",onfinish),unpipe()}dest.once("close",onclose);function onfinish(){debug("onfinish"),dest.removeListener("close",onclose),unpipe()}dest.once("finish",onfinish);function unpipe(){debug("unpipe"),src.unpipe(dest)}return dest.emit("pipe",src),dest.writableNeedDrain===!0?pause():state.flowing||(debug("pipe resume"),src.resume()),dest};function pipeOnDrain(src,dest){return function(){let state=src._readableState;state.awaitDrainWriters===dest?(debug("pipeOnDrain",1),state.awaitDrainWriters=null):state.multiAwaitDrain&&(debug("pipeOnDrain",state.awaitDrainWriters.size),state.awaitDrainWriters.delete(dest)),(!state.awaitDrainWriters||state.awaitDrainWriters.size===0)&&src.listenerCount("data")&&src.resume()}}Readable.prototype.unpipe=function(dest){let state=this._readableState,unpipeInfo={hasUnpiped:!1};if(state.pipes.length===0)return this;if(!dest){let dests=state.pipes;state.pipes=[],this.pause();for(let i2=0;i2<dests.length;i2++)dests[i2].emit("unpipe",this,{hasUnpiped:!1});return this}let index4=ArrayPrototypeIndexOf(state.pipes,dest);return index4===-1?this:(state.pipes.splice(index4,1),state.pipes.length===0&&this.pause(),dest.emit("unpipe",this,unpipeInfo),this)};Readable.prototype.on=function(ev,fn2){let res=Stream.prototype.on.call(this,ev,fn2),state=this._readableState;return ev==="data"?(state.readableListening=this.listenerCount("readable")>0,state.flowing!==!1&&this.resume()):ev==="readable"&&!state.endEmitted&&!state.readableListening&&(state.readableListening=state.needReadable=!0,state.flowing=!1,state.emittedReadable=!1,debug("on readable",state.length,state.reading),state.length?emitReadable(this):state.reading||process2.nextTick(nReadingNextTick,this)),res};Readable.prototype.addListener=Readable.prototype.on;Readable.prototype.removeListener=function(ev,fn2){let res=Stream.prototype.removeListener.call(this,ev,fn2);return ev==="readable"&&process2.nextTick(updateReadableListening,this),res};Readable.prototype.off=Readable.prototype.removeListener;Readable.prototype.removeAllListeners=function(ev){let res=Stream.prototype.removeAllListeners.apply(this,arguments);return(ev==="readable"||ev===void 0)&&process2.nextTick(updateReadableListening,this),res};function updateReadableListening(self2){let state=self2._readableState;state.readableListening=self2.listenerCount("readable")>0,state.resumeScheduled&&state[kPaused]===!1?state.flowing=!0:self2.listenerCount("data")>0?self2.resume():state.readableListening||(state.flowing=null)}function nReadingNextTick(self2){debug("readable nexttick read 0"),self2.read(0)}Readable.prototype.resume=function(){let state=this._readableState;return state.flowing||(debug("resume"),state.flowing=!state.readableListening,resume(this,state)),state[kPaused]=!1,this};function resume(stream,state){state.resumeScheduled||(state.resumeScheduled=!0,process2.nextTick(resume_,stream,state))}function resume_(stream,state){debug("resume",state.reading),state.reading||stream.read(0),state.resumeScheduled=!1,stream.emit("resume"),flow3(stream),state.flowing&&!state.reading&&stream.read(0)}Readable.prototype.pause=function(){return debug("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(debug("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[kPaused]=!0,this};function flow3(stream){let state=stream._readableState;for(debug("flow",state.flowing);state.flowing&&stream.read()!==null;);}Readable.prototype.wrap=function(stream){let paused=!1;stream.on("data",chunk=>{!this.push(chunk)&&stream.pause&&(paused=!0,stream.pause())}),stream.on("end",()=>{this.push(null)}),stream.on("error",err=>{errorOrDestroy(this,err)}),stream.on("close",()=>{this.destroy()}),stream.on("destroy",()=>{this.destroy()}),this._read=()=>{paused&&stream.resume&&(paused=!1,stream.resume())};let streamKeys=ObjectKeys(stream);for(let j=1;j<streamKeys.length;j++){let i2=streamKeys[j];this[i2]===void 0&&typeof stream[i2]=="function"&&(this[i2]=stream[i2].bind(stream))}return this};Readable.prototype[SymbolAsyncIterator]=function(){return streamToAsyncIterator(this)};Readable.prototype.iterator=function(options2){return options2!==void 0&&validateObject(options2,"options"),streamToAsyncIterator(this,options2)};function streamToAsyncIterator(stream,options2){typeof stream.read!="function"&&(stream=Readable.wrap(stream,{objectMode:!0}));let iter=createAsyncIterator(stream,options2);return iter.stream=stream,iter}async function*createAsyncIterator(stream,options2){let callback=nop;function next(resolve2){this===stream?(callback(),callback=nop):callback=resolve2}stream.on("readable",next);let error,cleanup=eos(stream,{writable:!1},err=>{error=err?aggregateTwoErrors(error,err):null,callback(),callback=nop});try{for(;;){let chunk=stream.destroyed?null:stream.read();if(chunk!==null)yield chunk;else{if(error)throw error;if(error===null)return;await new Promise2(next)}}}catch(err){throw error=aggregateTwoErrors(error,err),error}finally{(error||options2?.destroyOnReturn!==!1)&&(error===void 0||stream._readableState.autoDestroy)?destroyImpl.destroyer(stream,null):(stream.off("readable",next),cleanup())}}ObjectDefineProperties(Readable.prototype,{readable:{__proto__:null,get(){let r2=this._readableState;return!!r2&&r2.readable!==!1&&!r2.destroyed&&!r2.errorEmitted&&!r2.endEmitted},set(val){this._readableState&&(this._readableState.readable=!!val)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(state){this._readableState&&(this._readableState.flowing=state)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(value2){this._readableState&&(this._readableState.destroyed=value2)}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}});ObjectDefineProperties(ReadableState.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[kPaused]!==!1},set(value2){this[kPaused]=!!value2}}});Readable._fromList=fromList;function fromList(n2,state){if(state.length===0)return null;let ret;return state.objectMode?ret=state.buffer.shift():!n2||n2>=state.length?(state.decoder?ret=state.buffer.join(""):state.buffer.length===1?ret=state.buffer.first():ret=state.buffer.concat(state.length),state.buffer.clear()):ret=state.buffer.consume(n2,state.decoder),ret}function endReadable(stream){let state=stream._readableState;debug("endReadable",state.endEmitted),state.endEmitted||(state.ended=!0,process2.nextTick(endReadableNT,state,stream))}function endReadableNT(state,stream){if(debug("endReadableNT",state.endEmitted,state.length),!state.errored&&!state.closeEmitted&&!state.endEmitted&&state.length===0){if(state.endEmitted=!0,stream.emit("end"),stream.writable&&stream.allowHalfOpen===!1)process2.nextTick(endWritableNT,stream);else if(state.autoDestroy){let wState=stream._writableState;(!wState||wState.autoDestroy&&(wState.finished||wState.writable===!1))&&stream.destroy()}}}function endWritableNT(stream){stream.writable&&!stream.writableEnded&&!stream.destroyed&&stream.end()}Readable.from=function(iterable,opts){return from(Readable,iterable,opts)};var webStreamsAdapters;function lazyWebStreams(){return webStreamsAdapters===void 0&&(webStreamsAdapters={}),webStreamsAdapters}Readable.fromWeb=function(readableStream,options2){return lazyWebStreams().newStreamReadableFromReadableStream(readableStream,options2)};Readable.toWeb=function(streamReadable,options2){return lazyWebStreams().newReadableStreamFromStreamReadable(streamReadable,options2)};Readable.wrap=function(src,options2){var _ref,_src$readableObjectMo;return new Readable({objectMode:(_ref=(_src$readableObjectMo=src.readableObjectMode)!==null&&_src$readableObjectMo!==void 0?_src$readableObjectMo:src.objectMode)!==null&&_ref!==void 0?_ref:!0,...options2,destroy(err,callback){destroyImpl.destroyer(src,err),callback(err)}}).wrap(src)}}});var require_writable=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/writable.js"(exports,module){"use strict";init_browser_globals();var process2=require_process2(),{ArrayPrototypeSlice,Error:Error2,FunctionPrototypeSymbolHasInstance,ObjectDefineProperty,ObjectDefineProperties,ObjectSetPrototypeOf,StringPrototypeToLowerCase,Symbol:Symbol2,SymbolHasInstance}=require_primordials();module.exports=Writable;Writable.WritableState=WritableState;var{EventEmitter:EE}=require_events(),Stream=require_legacy().Stream,{Buffer:Buffer6}=require_buffer(),destroyImpl=require_destroy(),{addAbortSignal}=require_add_abort_signal(),{getHighWaterMark,getDefaultHighWaterMark}=require_state(),{ERR_INVALID_ARG_TYPE,ERR_METHOD_NOT_IMPLEMENTED,ERR_MULTIPLE_CALLBACK,ERR_STREAM_CANNOT_PIPE,ERR_STREAM_DESTROYED,ERR_STREAM_ALREADY_FINISHED,ERR_STREAM_NULL_VALUES,ERR_STREAM_WRITE_AFTER_END,ERR_UNKNOWN_ENCODING}=require_errors2().codes,{errorOrDestroy}=destroyImpl;ObjectSetPrototypeOf(Writable.prototype,Stream.prototype);ObjectSetPrototypeOf(Writable,Stream);function nop(){}var kOnFinished=Symbol2("kOnFinished");function WritableState(options2,stream,isDuplex){typeof isDuplex!="boolean"&&(isDuplex=stream instanceof require_duplex()),this.objectMode=!!(options2&&options2.objectMode),isDuplex&&(this.objectMode=this.objectMode||!!(options2&&options2.writableObjectMode)),this.highWaterMark=options2?getHighWaterMark(this,options2,"writableHighWaterMark",isDuplex):getDefaultHighWaterMark(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let noDecode=!!(options2&&options2.decodeStrings===!1);this.decodeStrings=!noDecode,this.defaultEncoding=options2&&options2.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=onwrite.bind(void 0,stream),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,resetBuffer(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!options2||options2.emitClose!==!1,this.autoDestroy=!options2||options2.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[kOnFinished]=[]}function resetBuffer(state){state.buffered=[],state.bufferedIndex=0,state.allBuffers=!0,state.allNoop=!0}WritableState.prototype.getBuffer=function(){return ArrayPrototypeSlice(this.buffered,this.bufferedIndex)};ObjectDefineProperty(WritableState.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function Writable(options2){let isDuplex=this instanceof require_duplex();if(!isDuplex&&!FunctionPrototypeSymbolHasInstance(Writable,this))return new Writable(options2);this._writableState=new WritableState(options2,this,isDuplex),options2&&(typeof options2.write=="function"&&(this._write=options2.write),typeof options2.writev=="function"&&(this._writev=options2.writev),typeof options2.destroy=="function"&&(this._destroy=options2.destroy),typeof options2.final=="function"&&(this._final=options2.final),typeof options2.construct=="function"&&(this._construct=options2.construct),options2.signal&&addAbortSignal(options2.signal,this)),Stream.call(this,options2),destroyImpl.construct(this,()=>{let state=this._writableState;state.writing||clearBuffer(this,state),finishMaybe(this,state)})}ObjectDefineProperty(Writable,SymbolHasInstance,{__proto__:null,value:function(object){return FunctionPrototypeSymbolHasInstance(this,object)?!0:this!==Writable?!1:object&&object._writableState instanceof WritableState}});Writable.prototype.pipe=function(){errorOrDestroy(this,new ERR_STREAM_CANNOT_PIPE)};function _write(stream,chunk,encoding,cb){let state=stream._writableState;if(typeof encoding=="function")cb=encoding,encoding=state.defaultEncoding;else{if(!encoding)encoding=state.defaultEncoding;else if(encoding!=="buffer"&&!Buffer6.isEncoding(encoding))throw new ERR_UNKNOWN_ENCODING(encoding);typeof cb!="function"&&(cb=nop)}if(chunk===null)throw new ERR_STREAM_NULL_VALUES;if(!state.objectMode)if(typeof chunk=="string")state.decodeStrings!==!1&&(chunk=Buffer6.from(chunk,encoding),encoding="buffer");else if(chunk instanceof Buffer6)encoding="buffer";else if(Stream._isUint8Array(chunk))chunk=Stream._uint8ArrayToBuffer(chunk),encoding="buffer";else throw new ERR_INVALID_ARG_TYPE("chunk",["string","Buffer","Uint8Array"],chunk);let err;return state.ending?err=new ERR_STREAM_WRITE_AFTER_END:state.destroyed&&(err=new ERR_STREAM_DESTROYED("write")),err?(process2.nextTick(cb,err),errorOrDestroy(stream,err,!0),err):(state.pendingcb++,writeOrBuffer(stream,state,chunk,encoding,cb))}Writable.prototype.write=function(chunk,encoding,cb){return _write(this,chunk,encoding,cb)===!0};Writable.prototype.cork=function(){this._writableState.corked++};Writable.prototype.uncork=function(){let state=this._writableState;state.corked&&(state.corked--,state.writing||clearBuffer(this,state))};Writable.prototype.setDefaultEncoding=function(encoding){if(typeof encoding=="string"&&(encoding=StringPrototypeToLowerCase(encoding)),!Buffer6.isEncoding(encoding))throw new ERR_UNKNOWN_ENCODING(encoding);return this._writableState.defaultEncoding=encoding,this};function writeOrBuffer(stream,state,chunk,encoding,callback){let len=state.objectMode?1:chunk.length;state.length+=len;let ret=state.length<state.highWaterMark;return ret||(state.needDrain=!0),state.writing||state.corked||state.errored||!state.constructed?(state.buffered.push({chunk,encoding,callback}),state.allBuffers&&encoding!=="buffer"&&(state.allBuffers=!1),state.allNoop&&callback!==nop&&(state.allNoop=!1)):(state.writelen=len,state.writecb=callback,state.writing=!0,state.sync=!0,stream._write(chunk,encoding,state.onwrite),state.sync=!1),ret&&!state.errored&&!state.destroyed}function doWrite(stream,state,writev,len,chunk,encoding,cb){state.writelen=len,state.writecb=cb,state.writing=!0,state.sync=!0,state.destroyed?state.onwrite(new ERR_STREAM_DESTROYED("write")):writev?stream._writev(chunk,state.onwrite):stream._write(chunk,encoding,state.onwrite),state.sync=!1}function onwriteError(stream,state,er2,cb){--state.pendingcb,cb(er2),errorBuffer(state),errorOrDestroy(stream,er2)}function onwrite(stream,er2){let state=stream._writableState,sync=state.sync,cb=state.writecb;if(typeof cb!="function"){errorOrDestroy(stream,new ERR_MULTIPLE_CALLBACK);return}state.writing=!1,state.writecb=null,state.length-=state.writelen,state.writelen=0,er2?(er2.stack,state.errored||(state.errored=er2),stream._readableState&&!stream._readableState.errored&&(stream._readableState.errored=er2),sync?process2.nextTick(onwriteError,stream,state,er2,cb):onwriteError(stream,state,er2,cb)):(state.buffered.length>state.bufferedIndex&&clearBuffer(stream,state),sync?state.afterWriteTickInfo!==null&&state.afterWriteTickInfo.cb===cb?state.afterWriteTickInfo.count++:(state.afterWriteTickInfo={count:1,cb,stream,state},process2.nextTick(afterWriteTick,state.afterWriteTickInfo)):afterWrite(stream,state,1,cb))}function afterWriteTick({stream,state,count,cb}){return state.afterWriteTickInfo=null,afterWrite(stream,state,count,cb)}function afterWrite(stream,state,count,cb){for(!state.ending&&!stream.destroyed&&state.length===0&&state.needDrain&&(state.needDrain=!1,stream.emit("drain"));count-- >0;)state.pendingcb--,cb();state.destroyed&&errorBuffer(state),finishMaybe(stream,state)}function errorBuffer(state){if(state.writing)return;for(let n2=state.bufferedIndex;n2<state.buffered.length;++n2){var _state$errored;let{chunk,callback}=state.buffered[n2],len=state.objectMode?1:chunk.length;state.length-=len,callback((_state$errored=state.errored)!==null&&_state$errored!==void 0?_state$errored:new ERR_STREAM_DESTROYED("write"))}let onfinishCallbacks=state[kOnFinished].splice(0);for(let i2=0;i2<onfinishCallbacks.length;i2++){var _state$errored2;onfinishCallbacks[i2]((_state$errored2=state.errored)!==null&&_state$errored2!==void 0?_state$errored2:new ERR_STREAM_DESTROYED("end"))}resetBuffer(state)}function clearBuffer(stream,state){if(state.corked||state.bufferProcessing||state.destroyed||!state.constructed)return;let{buffered,bufferedIndex,objectMode}=state,bufferedLength=buffered.length-bufferedIndex;if(!bufferedLength)return;let i2=bufferedIndex;if(state.bufferProcessing=!0,bufferedLength>1&&stream._writev){state.pendingcb-=bufferedLength-1;let callback=state.allNoop?nop:err=>{for(let n2=i2;n2<buffered.length;++n2)buffered[n2].callback(err)},chunks=state.allNoop&&i2===0?buffered:ArrayPrototypeSlice(buffered,i2);chunks.allBuffers=state.allBuffers,doWrite(stream,state,!0,state.length,chunks,"",callback),resetBuffer(state)}else{do{let{chunk,encoding,callback}=buffered[i2];buffered[i2++]=null;let len=objectMode?1:chunk.length;doWrite(stream,state,!1,len,chunk,encoding,callback)}while(i2<buffered.length&&!state.writing);i2===buffered.length?resetBuffer(state):i2>256?(buffered.splice(0,i2),state.bufferedIndex=0):state.bufferedIndex=i2}state.bufferProcessing=!1}Writable.prototype._write=function(chunk,encoding,cb){if(this._writev)this._writev([{chunk,encoding}],cb);else throw new ERR_METHOD_NOT_IMPLEMENTED("_write()")};Writable.prototype._writev=null;Writable.prototype.end=function(chunk,encoding,cb){let state=this._writableState;typeof chunk=="function"?(cb=chunk,chunk=null,encoding=null):typeof encoding=="function"&&(cb=encoding,encoding=null);let err;if(chunk!=null){let ret=_write(this,chunk,encoding);ret instanceof Error2&&(err=ret)}return state.corked&&(state.corked=1,this.uncork()),err||(!state.errored&&!state.ending?(state.ending=!0,finishMaybe(this,state,!0),state.ended=!0):state.finished?err=new ERR_STREAM_ALREADY_FINISHED("end"):state.destroyed&&(err=new ERR_STREAM_DESTROYED("end"))),typeof cb=="function"&&(err||state.finished?process2.nextTick(cb,err):state[kOnFinished].push(cb)),this};function needFinish(state){return state.ending&&!state.destroyed&&state.constructed&&state.length===0&&!state.errored&&state.buffered.length===0&&!state.finished&&!state.writing&&!state.errorEmitted&&!state.closeEmitted}function callFinal(stream,state){let called=!1;function onFinish(err){if(called){errorOrDestroy(stream,err??ERR_MULTIPLE_CALLBACK());return}if(called=!0,state.pendingcb--,err){let onfinishCallbacks=state[kOnFinished].splice(0);for(let i2=0;i2<onfinishCallbacks.length;i2++)onfinishCallbacks[i2](err);errorOrDestroy(stream,err,state.sync)}else needFinish(state)&&(state.prefinished=!0,stream.emit("prefinish"),state.pendingcb++,process2.nextTick(finish,stream,state))}state.sync=!0,state.pendingcb++;try{stream._final(onFinish)}catch(err){onFinish(err)}state.sync=!1}function prefinish(stream,state){!state.prefinished&&!state.finalCalled&&(typeof stream._final=="function"&&!state.destroyed?(state.finalCalled=!0,callFinal(stream,state)):(state.prefinished=!0,stream.emit("prefinish")))}function finishMaybe(stream,state,sync){needFinish(state)&&(prefinish(stream,state),state.pendingcb===0&&(sync?(state.pendingcb++,process2.nextTick((stream2,state2)=>{needFinish(state2)?finish(stream2,state2):state2.pendingcb--},stream,state)):needFinish(state)&&(state.pendingcb++,finish(stream,state))))}function finish(stream,state){state.pendingcb--,state.finished=!0;let onfinishCallbacks=state[kOnFinished].splice(0);for(let i2=0;i2<onfinishCallbacks.length;i2++)onfinishCallbacks[i2]();if(stream.emit("finish"),state.autoDestroy){let rState=stream._readableState;(!rState||rState.autoDestroy&&(rState.endEmitted||rState.readable===!1))&&stream.destroy()}}ObjectDefineProperties(Writable.prototype,{closed:{__proto__:null,get(){return this._writableState?this._writableState.closed:!1}},destroyed:{__proto__:null,get(){return this._writableState?this._writableState.destroyed:!1},set(value2){this._writableState&&(this._writableState.destroyed=value2)}},writable:{__proto__:null,get(){let w2=this._writableState;return!!w2&&w2.writable!==!1&&!w2.destroyed&&!w2.errored&&!w2.ending&&!w2.ended},set(val){this._writableState&&(this._writableState.writable=!!val)}},writableFinished:{__proto__:null,get(){return this._writableState?this._writableState.finished:!1}},writableObjectMode:{__proto__:null,get(){return this._writableState?this._writableState.objectMode:!1}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return this._writableState?this._writableState.ending:!1}},writableNeedDrain:{__proto__:null,get(){let wState=this._writableState;return wState?!wState.destroyed&&!wState.ending&&wState.needDrain:!1}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._writableState.writable!==!1&&(this._writableState.destroyed||this._writableState.errored)&&!this._writableState.finished)}}});var destroy=destroyImpl.destroy;Writable.prototype.destroy=function(err,cb){let state=this._writableState;return!state.destroyed&&(state.bufferedIndex<state.buffered.length||state[kOnFinished].length)&&process2.nextTick(errorBuffer,state),destroy.call(this,err,cb),this};Writable.prototype._undestroy=destroyImpl.undestroy;Writable.prototype._destroy=function(err,cb){cb(err)};Writable.prototype[EE.captureRejectionSymbol]=function(err){this.destroy(err)};var webStreamsAdapters;function lazyWebStreams(){return webStreamsAdapters===void 0&&(webStreamsAdapters={}),webStreamsAdapters}Writable.fromWeb=function(writableStream,options2){return lazyWebStreams().newStreamWritableFromWritableStream(writableStream,options2)};Writable.toWeb=function(streamWritable){return lazyWebStreams().newWritableStreamFromStreamWritable(streamWritable)}}});var require_duplexify=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/duplexify.js"(exports,module){init_browser_globals();var process2=require_process2(),bufferModule=require_buffer(),{isReadable,isWritable,isIterable,isNodeStream,isReadableNodeStream,isWritableNodeStream,isDuplexNodeStream,isReadableStream,isWritableStream}=require_utils(),eos=require_end_of_stream(),{AbortError,codes:{ERR_INVALID_ARG_TYPE,ERR_INVALID_RETURN_VALUE}}=require_errors2(),{destroyer}=require_destroy(),Duplex=require_duplex(),Readable=require_readable(),Writable=require_writable(),{createDeferredPromise}=require_util3(),from=require_from(),Blob2=globalThis.Blob||bufferModule.Blob,isBlob=typeof Blob2<"u"?function(b2){return b2 instanceof Blob2}:function(b2){return!1},AbortController2=globalThis.AbortController||require_browser2().AbortController,{FunctionPrototypeCall}=require_primordials(),Duplexify=class extends Duplex{constructor(options2){super(options2),options2?.readable===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),options2?.writable===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}};module.exports=function duplexify(body,name){if(isDuplexNodeStream(body))return body;if(isReadableNodeStream(body))return _duplexify({readable:body});if(isWritableNodeStream(body))return _duplexify({writable:body});if(isNodeStream(body))return _duplexify({writable:!1,readable:!1});if(isReadableStream(body))return _duplexify({readable:Readable.fromWeb(body)});if(isWritableStream(body))return _duplexify({writable:Writable.fromWeb(body)});if(typeof body=="function"){let{value:value2,write,final,destroy}=fromAsyncGen(body);if(isIterable(value2))return from(Duplexify,value2,{objectMode:!0,write,final,destroy});let then2=value2?.then;if(typeof then2=="function"){let d2,promise=FunctionPrototypeCall(then2,value2,val=>{if(val!=null)throw new ERR_INVALID_RETURN_VALUE("nully","body",val)},err=>{destroyer(d2,err)});return d2=new Duplexify({objectMode:!0,readable:!1,write,final(cb){final(async()=>{try{await promise,process2.nextTick(cb,null)}catch(err){process2.nextTick(cb,err)}})},destroy})}throw new ERR_INVALID_RETURN_VALUE("Iterable, AsyncIterable or AsyncFunction",name,value2)}if(isBlob(body))return duplexify(body.arrayBuffer());if(isIterable(body))return from(Duplexify,body,{objectMode:!0,writable:!1});if(isReadableStream(body?.readable)&&isWritableStream(body?.writable))return Duplexify.fromWeb(body);if(typeof body?.writable=="object"||typeof body?.readable=="object"){let readable=body!=null&&body.readable?isReadableNodeStream(body?.readable)?body?.readable:duplexify(body.readable):void 0,writable=body!=null&&body.writable?isWritableNodeStream(body?.writable)?body?.writable:duplexify(body.writable):void 0;return _duplexify({readable,writable})}let then=body?.then;if(typeof then=="function"){let d2;return FunctionPrototypeCall(then,body,val=>{val!=null&&d2.push(val),d2.push(null)},err=>{destroyer(d2,err)}),d2=new Duplexify({objectMode:!0,writable:!1,read(){}})}throw new ERR_INVALID_ARG_TYPE(name,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],body)};function fromAsyncGen(fn2){let{promise,resolve:resolve2}=createDeferredPromise(),ac=new AbortController2,signal=ac.signal;return{value:fn2((async function*(){for(;;){let _promise=promise;promise=null;let{chunk,done,cb}=await _promise;if(process2.nextTick(cb),done)return;if(signal.aborted)throw new AbortError(void 0,{cause:signal.reason});({promise,resolve:resolve2}=createDeferredPromise()),yield chunk}})(),{signal}),write(chunk,encoding,cb){let _resolve=resolve2;resolve2=null,_resolve({chunk,done:!1,cb})},final(cb){let _resolve=resolve2;resolve2=null,_resolve({done:!0,cb})},destroy(err,cb){ac.abort(),cb(err)}}}function _duplexify(pair2){let r2=pair2.readable&&typeof pair2.readable.read!="function"?Readable.wrap(pair2.readable):pair2.readable,w2=pair2.writable,readable=!!isReadable(r2),writable=!!isWritable(w2),ondrain,onfinish,onreadable,onclose,d2;function onfinished(err){let cb=onclose;onclose=null,cb?cb(err):err&&d2.destroy(err)}return d2=new Duplexify({readableObjectMode:!!(r2!=null&&r2.readableObjectMode),writableObjectMode:!!(w2!=null&&w2.writableObjectMode),readable,writable}),writable&&(eos(w2,err=>{writable=!1,err&&destroyer(r2,err),onfinished(err)}),d2._write=function(chunk,encoding,callback){w2.write(chunk,encoding)?callback():ondrain=callback},d2._final=function(callback){w2.end(),onfinish=callback},w2.on("drain",function(){if(ondrain){let cb=ondrain;ondrain=null,cb()}}),w2.on("finish",function(){if(onfinish){let cb=onfinish;onfinish=null,cb()}})),readable&&(eos(r2,err=>{readable=!1,err&&destroyer(r2,err),onfinished(err)}),r2.on("readable",function(){if(onreadable){let cb=onreadable;onreadable=null,cb()}}),r2.on("end",function(){d2.push(null)}),d2._read=function(){for(;;){let buf=r2.read();if(buf===null){onreadable=d2._read;return}if(!d2.push(buf))return}}),d2._destroy=function(err,callback){!err&&onclose!==null&&(err=new AbortError),onreadable=null,ondrain=null,onfinish=null,onclose===null?callback(err):(onclose=callback,destroyer(w2,err),destroyer(r2,err))},d2}}});var require_duplex=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/duplex.js"(exports,module){"use strict";init_browser_globals();var{ObjectDefineProperties,ObjectGetOwnPropertyDescriptor,ObjectKeys,ObjectSetPrototypeOf}=require_primordials();module.exports=Duplex;var Readable=require_readable(),Writable=require_writable();ObjectSetPrototypeOf(Duplex.prototype,Readable.prototype);ObjectSetPrototypeOf(Duplex,Readable);{let keys=ObjectKeys(Writable.prototype);for(let i2=0;i2<keys.length;i2++){let method=keys[i2];Duplex.prototype[method]||(Duplex.prototype[method]=Writable.prototype[method])}}function Duplex(options2){if(!(this instanceof Duplex))return new Duplex(options2);Readable.call(this,options2),Writable.call(this,options2),options2?(this.allowHalfOpen=options2.allowHalfOpen!==!1,options2.readable===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),options2.writable===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)):this.allowHalfOpen=!0}ObjectDefineProperties(Duplex.prototype,{writable:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writable")},writableHighWaterMark:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableBuffer")},writableLength:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableLength")},writableFinished:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableFinished")},writableCorked:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableCorked")},writableEnded:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...ObjectGetOwnPropertyDescriptor(Writable.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set(value2){this._readableState&&this._writableState&&(this._readableState.destroyed=value2,this._writableState.destroyed=value2)}}});var webStreamsAdapters;function lazyWebStreams(){return webStreamsAdapters===void 0&&(webStreamsAdapters={}),webStreamsAdapters}Duplex.fromWeb=function(pair2,options2){return lazyWebStreams().newStreamDuplexFromReadableWritablePair(pair2,options2)};Duplex.toWeb=function(duplex){return lazyWebStreams().newReadableWritablePairFromDuplex(duplex)};var duplexify;Duplex.from=function(body){return duplexify||(duplexify=require_duplexify()),duplexify(body,"body")}}});var require_transform=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/transform.js"(exports,module){"use strict";init_browser_globals();var{ObjectSetPrototypeOf,Symbol:Symbol2}=require_primordials();module.exports=Transform;var{ERR_METHOD_NOT_IMPLEMENTED}=require_errors2().codes,Duplex=require_duplex(),{getHighWaterMark}=require_state();ObjectSetPrototypeOf(Transform.prototype,Duplex.prototype);ObjectSetPrototypeOf(Transform,Duplex);var kCallback=Symbol2("kCallback");function Transform(options2){if(!(this instanceof Transform))return new Transform(options2);let readableHighWaterMark=options2?getHighWaterMark(this,options2,"readableHighWaterMark",!0):null;readableHighWaterMark===0&&(options2={...options2,highWaterMark:null,readableHighWaterMark,writableHighWaterMark:options2.writableHighWaterMark||0}),Duplex.call(this,options2),this._readableState.sync=!1,this[kCallback]=null,options2&&(typeof options2.transform=="function"&&(this._transform=options2.transform),typeof options2.flush=="function"&&(this._flush=options2.flush)),this.on("prefinish",prefinish)}function final(cb){typeof this._flush=="function"&&!this.destroyed?this._flush((er2,data)=>{if(er2){cb?cb(er2):this.destroy(er2);return}data!=null&&this.push(data),this.push(null),cb&&cb()}):(this.push(null),cb&&cb())}function prefinish(){this._final!==final&&final.call(this)}Transform.prototype._final=final;Transform.prototype._transform=function(chunk,encoding,callback){throw new ERR_METHOD_NOT_IMPLEMENTED("_transform()")};Transform.prototype._write=function(chunk,encoding,callback){let rState=this._readableState,wState=this._writableState,length=rState.length;this._transform(chunk,encoding,(err,val)=>{if(err){callback(err);return}val!=null&&this.push(val),wState.ended||length===rState.length||rState.length<rState.highWaterMark?callback():this[kCallback]=callback})};Transform.prototype._read=function(){if(this[kCallback]){let callback=this[kCallback];this[kCallback]=null,callback()}}}});var require_passthrough=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/passthrough.js"(exports,module){"use strict";init_browser_globals();var{ObjectSetPrototypeOf}=require_primordials();module.exports=PassThrough;var Transform=require_transform();ObjectSetPrototypeOf(PassThrough.prototype,Transform.prototype);ObjectSetPrototypeOf(PassThrough,Transform);function PassThrough(options2){if(!(this instanceof PassThrough))return new PassThrough(options2);Transform.call(this,options2)}PassThrough.prototype._transform=function(chunk,encoding,cb){cb(null,chunk)}}});var require_pipeline=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/pipeline.js"(exports,module){init_browser_globals();var process2=require_process2(),{ArrayIsArray,Promise:Promise2,SymbolAsyncIterator,SymbolDispose}=require_primordials(),eos=require_end_of_stream(),{once}=require_util3(),destroyImpl=require_destroy(),Duplex=require_duplex(),{aggregateTwoErrors,codes:{ERR_INVALID_ARG_TYPE,ERR_INVALID_RETURN_VALUE,ERR_MISSING_ARGS,ERR_STREAM_DESTROYED,ERR_STREAM_PREMATURE_CLOSE},AbortError}=require_errors2(),{validateFunction,validateAbortSignal}=require_validators2(),{isIterable,isReadable,isReadableNodeStream,isNodeStream,isTransformStream,isWebStream,isReadableStream,isReadableFinished}=require_utils(),AbortController2=globalThis.AbortController||require_browser2().AbortController,PassThrough,Readable,addAbortListener;function destroyer(stream,reading,writing){let finished=!1;stream.on("close",()=>{finished=!0});let cleanup=eos(stream,{readable:reading,writable:writing},err=>{finished=!err});return{destroy:err=>{finished||(finished=!0,destroyImpl.destroyer(stream,err||new ERR_STREAM_DESTROYED("pipe")))},cleanup}}function popCallback(streams){return validateFunction(streams[streams.length-1],"streams[stream.length - 1]"),streams.pop()}function makeAsyncIterable(val){if(isIterable(val))return val;if(isReadableNodeStream(val))return fromReadable(val);throw new ERR_INVALID_ARG_TYPE("val",["Readable","Iterable","AsyncIterable"],val)}async function*fromReadable(val){Readable||(Readable=require_readable()),yield*Readable.prototype[SymbolAsyncIterator].call(val)}async function pumpToNode(iterable,writable,finish,{end}){let error,onresolve=null,resume=err=>{if(err&&(error=err),onresolve){let callback=onresolve;onresolve=null,callback()}},wait=()=>new Promise2((resolve2,reject)=>{error?reject(error):onresolve=()=>{error?reject(error):resolve2()}});writable.on("drain",resume);let cleanup=eos(writable,{readable:!1},resume);try{writable.writableNeedDrain&&await wait();for await(let chunk of iterable)writable.write(chunk)||await wait();end&&(writable.end(),await wait()),finish()}catch(err){finish(error!==err?aggregateTwoErrors(error,err):err)}finally{cleanup(),writable.off("drain",resume)}}async function pumpToWeb(readable,writable,finish,{end}){isTransformStream(writable)&&(writable=writable.writable);let writer=writable.getWriter();try{for await(let chunk of readable)await writer.ready,writer.write(chunk).catch(()=>{});await writer.ready,end&&await writer.close(),finish()}catch(err){try{await writer.abort(err),finish(err)}catch(err2){finish(err2)}}}function pipeline(...streams){return pipelineImpl(streams,once(popCallback(streams)))}function pipelineImpl(streams,callback,opts){if(streams.length===1&&ArrayIsArray(streams[0])&&(streams=streams[0]),streams.length<2)throw new ERR_MISSING_ARGS("streams");let ac=new AbortController2,signal=ac.signal,outerSignal=opts?.signal,lastStreamCleanup=[];validateAbortSignal(outerSignal,"options.signal");function abort(){finishImpl(new AbortError)}addAbortListener=addAbortListener||require_util3().addAbortListener;let disposable;outerSignal&&(disposable=addAbortListener(outerSignal,abort));let error,value2,destroys=[],finishCount=0;function finish(err){finishImpl(err,--finishCount===0)}function finishImpl(err,final){var _disposable;if(err&&(!error||error.code==="ERR_STREAM_PREMATURE_CLOSE")&&(error=err),!(!error&&!final)){for(;destroys.length;)destroys.shift()(error);(_disposable=disposable)===null||_disposable===void 0||_disposable[SymbolDispose](),ac.abort(),final&&(error||lastStreamCleanup.forEach(fn2=>fn2()),process2.nextTick(callback,error,value2))}}let ret;for(let i2=0;i2<streams.length;i2++){let stream=streams[i2],reading=i2<streams.length-1,writing=i2>0,end=reading||opts?.end!==!1,isLastStream=i2===streams.length-1;if(isNodeStream(stream)){let onError2=function(err){err&&err.name!=="AbortError"&&err.code!=="ERR_STREAM_PREMATURE_CLOSE"&&finish(err)};var onError=onError2;if(end){let{destroy,cleanup}=destroyer(stream,reading,writing);destroys.push(destroy),isReadable(stream)&&isLastStream&&lastStreamCleanup.push(cleanup)}stream.on("error",onError2),isReadable(stream)&&isLastStream&&lastStreamCleanup.push(()=>{stream.removeListener("error",onError2)})}if(i2===0)if(typeof stream=="function"){if(ret=stream({signal}),!isIterable(ret))throw new ERR_INVALID_RETURN_VALUE("Iterable, AsyncIterable or Stream","source",ret)}else isIterable(stream)||isReadableNodeStream(stream)||isTransformStream(stream)?ret=stream:ret=Duplex.from(stream);else if(typeof stream=="function"){if(isTransformStream(ret)){var _ret;ret=makeAsyncIterable((_ret=ret)===null||_ret===void 0?void 0:_ret.readable)}else ret=makeAsyncIterable(ret);if(ret=stream(ret,{signal}),reading){if(!isIterable(ret,!0))throw new ERR_INVALID_RETURN_VALUE("AsyncIterable",`transform[${i2-1}]`,ret)}else{var _ret2;PassThrough||(PassThrough=require_passthrough());let pt2=new PassThrough({objectMode:!0}),then=(_ret2=ret)===null||_ret2===void 0?void 0:_ret2.then;if(typeof then=="function")finishCount++,then.call(ret,val=>{value2=val,val!=null&&pt2.write(val),end&&pt2.end(),process2.nextTick(finish)},err=>{pt2.destroy(err),process2.nextTick(finish,err)});else if(isIterable(ret,!0))finishCount++,pumpToNode(ret,pt2,finish,{end});else if(isReadableStream(ret)||isTransformStream(ret)){let toRead=ret.readable||ret;finishCount++,pumpToNode(toRead,pt2,finish,{end})}else throw new ERR_INVALID_RETURN_VALUE("AsyncIterable or Promise","destination",ret);ret=pt2;let{destroy,cleanup}=destroyer(ret,!1,!0);destroys.push(destroy),isLastStream&&lastStreamCleanup.push(cleanup)}}else if(isNodeStream(stream)){if(isReadableNodeStream(ret)){finishCount+=2;let cleanup=pipe(ret,stream,finish,{end});isReadable(stream)&&isLastStream&&lastStreamCleanup.push(cleanup)}else if(isTransformStream(ret)||isReadableStream(ret)){let toRead=ret.readable||ret;finishCount++,pumpToNode(toRead,stream,finish,{end})}else if(isIterable(ret))finishCount++,pumpToNode(ret,stream,finish,{end});else throw new ERR_INVALID_ARG_TYPE("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],ret);ret=stream}else if(isWebStream(stream)){if(isReadableNodeStream(ret))finishCount++,pumpToWeb(makeAsyncIterable(ret),stream,finish,{end});else if(isReadableStream(ret)||isIterable(ret))finishCount++,pumpToWeb(ret,stream,finish,{end});else if(isTransformStream(ret))finishCount++,pumpToWeb(ret.readable,stream,finish,{end});else throw new ERR_INVALID_ARG_TYPE("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],ret);ret=stream}else ret=Duplex.from(stream)}return(signal!=null&&signal.aborted||outerSignal!=null&&outerSignal.aborted)&&process2.nextTick(abort),ret}function pipe(src,dst,finish,{end}){let ended=!1;if(dst.on("close",()=>{ended||finish(new ERR_STREAM_PREMATURE_CLOSE)}),src.pipe(dst,{end:!1}),end){let endFn2=function(){ended=!0,dst.end()};var endFn=endFn2;isReadableFinished(src)?process2.nextTick(endFn2):src.once("end",endFn2)}else finish();return eos(src,{readable:!0,writable:!1},err=>{let rState=src._readableState;err&&err.code==="ERR_STREAM_PREMATURE_CLOSE"&&rState&&rState.ended&&!rState.errored&&!rState.errorEmitted?src.once("end",finish).once("error",finish):finish(err)}),eos(dst,{readable:!1,writable:!0},finish)}module.exports={pipelineImpl,pipeline}}});var require_compose=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/compose.js"(exports,module){"use strict";init_browser_globals();var{pipeline}=require_pipeline(),Duplex=require_duplex(),{destroyer}=require_destroy(),{isNodeStream,isReadable,isWritable,isWebStream,isTransformStream,isWritableStream,isReadableStream}=require_utils(),{AbortError,codes:{ERR_INVALID_ARG_VALUE,ERR_MISSING_ARGS}}=require_errors2(),eos=require_end_of_stream();module.exports=function(...streams){if(streams.length===0)throw new ERR_MISSING_ARGS("streams");if(streams.length===1)return Duplex.from(streams[0]);let orgStreams=[...streams];if(typeof streams[0]=="function"&&(streams[0]=Duplex.from(streams[0])),typeof streams[streams.length-1]=="function"){let idx=streams.length-1;streams[idx]=Duplex.from(streams[idx])}for(let n2=0;n2<streams.length;++n2)if(!(!isNodeStream(streams[n2])&&!isWebStream(streams[n2]))){if(n2<streams.length-1&&!(isReadable(streams[n2])||isReadableStream(streams[n2])||isTransformStream(streams[n2])))throw new ERR_INVALID_ARG_VALUE(`streams[${n2}]`,orgStreams[n2],"must be readable");if(n2>0&&!(isWritable(streams[n2])||isWritableStream(streams[n2])||isTransformStream(streams[n2])))throw new ERR_INVALID_ARG_VALUE(`streams[${n2}]`,orgStreams[n2],"must be writable")}let ondrain,onfinish,onreadable,onclose,d2;function onfinished(err){let cb=onclose;onclose=null,cb?cb(err):err?d2.destroy(err):!readable&&!writable&&d2.destroy()}let head=streams[0],tail=pipeline(streams,onfinished),writable=!!(isWritable(head)||isWritableStream(head)||isTransformStream(head)),readable=!!(isReadable(tail)||isReadableStream(tail)||isTransformStream(tail));if(d2=new Duplex({writableObjectMode:!!(head!=null&&head.writableObjectMode),readableObjectMode:!!(tail!=null&&tail.readableObjectMode),writable,readable}),writable){if(isNodeStream(head))d2._write=function(chunk,encoding,callback){head.write(chunk,encoding)?callback():ondrain=callback},d2._final=function(callback){head.end(),onfinish=callback},head.on("drain",function(){if(ondrain){let cb=ondrain;ondrain=null,cb()}});else if(isWebStream(head)){let writer=(isTransformStream(head)?head.writable:head).getWriter();d2._write=async function(chunk,encoding,callback){try{await writer.ready,writer.write(chunk).catch(()=>{}),callback()}catch(err){callback(err)}},d2._final=async function(callback){try{await writer.ready,writer.close().catch(()=>{}),onfinish=callback}catch(err){callback(err)}}}let toRead=isTransformStream(tail)?tail.readable:tail;eos(toRead,()=>{if(onfinish){let cb=onfinish;onfinish=null,cb()}})}if(readable){if(isNodeStream(tail))tail.on("readable",function(){if(onreadable){let cb=onreadable;onreadable=null,cb()}}),tail.on("end",function(){d2.push(null)}),d2._read=function(){for(;;){let buf=tail.read();if(buf===null){onreadable=d2._read;return}if(!d2.push(buf))return}};else if(isWebStream(tail)){let reader=(isTransformStream(tail)?tail.readable:tail).getReader();d2._read=async function(){for(;;)try{let{value:value2,done}=await reader.read();if(!d2.push(value2))return;if(done){d2.push(null);return}}catch{return}}}}return d2._destroy=function(err,callback){!err&&onclose!==null&&(err=new AbortError),onreadable=null,ondrain=null,onfinish=null,onclose===null?callback(err):(onclose=callback,isNodeStream(tail)&&destroyer(tail,err))},d2}}});var require_operators=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/internal/streams/operators.js"(exports,module){"use strict";init_browser_globals();var AbortController2=globalThis.AbortController||require_browser2().AbortController,{codes:{ERR_INVALID_ARG_VALUE,ERR_INVALID_ARG_TYPE,ERR_MISSING_ARGS,ERR_OUT_OF_RANGE},AbortError}=require_errors2(),{validateAbortSignal,validateInteger,validateObject}=require_validators2(),kWeakHandler=require_primordials().Symbol("kWeak"),kResistStopPropagation=require_primordials().Symbol("kResistStopPropagation"),{finished}=require_end_of_stream(),staticCompose=require_compose(),{addAbortSignalNoValidate}=require_add_abort_signal(),{isWritable,isNodeStream}=require_utils(),{deprecate}=require_util3(),{ArrayPrototypePush,Boolean:Boolean2,MathFloor,Number:Number2,NumberIsNaN,Promise:Promise2,PromiseReject,PromiseResolve,PromisePrototypeThen,Symbol:Symbol2}=require_primordials(),kEmpty=Symbol2("kEmpty"),kEof=Symbol2("kEof");function compose(stream,options2){if(options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal"),isNodeStream(stream)&&!isWritable(stream))throw new ERR_INVALID_ARG_VALUE("stream",stream,"must be writable");let composedStream=staticCompose(this,stream);return options2!=null&&options2.signal&&addAbortSignalNoValidate(options2.signal,composedStream),composedStream}function map5(fn2,options2){if(typeof fn2!="function")throw new ERR_INVALID_ARG_TYPE("fn",["Function","AsyncFunction"],fn2);options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal");let concurrency=1;options2?.concurrency!=null&&(concurrency=MathFloor(options2.concurrency));let highWaterMark=concurrency-1;return options2?.highWaterMark!=null&&(highWaterMark=MathFloor(options2.highWaterMark)),validateInteger(concurrency,"options.concurrency",1),validateInteger(highWaterMark,"options.highWaterMark",0),highWaterMark+=concurrency,async function*(){let signal=require_util3().AbortSignalAny([options2?.signal].filter(Boolean2)),stream=this,queue2=[],signalOpt={signal},next,resume,done=!1,cnt=0;function onCatch(){done=!0,afterItemProcessed()}function afterItemProcessed(){cnt-=1,maybeResume()}function maybeResume(){resume&&!done&&cnt<concurrency&&queue2.length<highWaterMark&&(resume(),resume=null)}async function pump(){try{for await(let val of stream){if(done)return;if(signal.aborted)throw new AbortError;try{if(val=fn2(val,signalOpt),val===kEmpty)continue;val=PromiseResolve(val)}catch(err){val=PromiseReject(err)}cnt+=1,PromisePrototypeThen(val,afterItemProcessed,onCatch),queue2.push(val),next&&(next(),next=null),!done&&(queue2.length>=highWaterMark||cnt>=concurrency)&&await new Promise2(resolve2=>{resume=resolve2})}queue2.push(kEof)}catch(err){let val=PromiseReject(err);PromisePrototypeThen(val,afterItemProcessed,onCatch),queue2.push(val)}finally{done=!0,next&&(next(),next=null)}}pump();try{for(;;){for(;queue2.length>0;){let val=await queue2[0];if(val===kEof)return;if(signal.aborted)throw new AbortError;val!==kEmpty&&(yield val),queue2.shift(),maybeResume()}await new Promise2(resolve2=>{next=resolve2})}}finally{done=!0,resume&&(resume(),resume=null)}}.call(this)}function asIndexedPairs(options2=void 0){return options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal"),async function*(){let index4=0;for await(let val of this){var _options$signal;if(options2!=null&&(_options$signal=options2.signal)!==null&&_options$signal!==void 0&&_options$signal.aborted)throw new AbortError({cause:options2.signal.reason});yield[index4++,val]}}.call(this)}async function some(fn2,options2=void 0){for await(let unused of filter.call(this,fn2,options2))return!0;return!1}async function every(fn2,options2=void 0){if(typeof fn2!="function")throw new ERR_INVALID_ARG_TYPE("fn",["Function","AsyncFunction"],fn2);return!await some.call(this,async(...args)=>!await fn2(...args),options2)}async function find(fn2,options2){for await(let result of filter.call(this,fn2,options2))return result}async function forEach(fn2,options2){if(typeof fn2!="function")throw new ERR_INVALID_ARG_TYPE("fn",["Function","AsyncFunction"],fn2);async function forEachFn(value2,options3){return await fn2(value2,options3),kEmpty}for await(let unused of map5.call(this,forEachFn,options2));}function filter(fn2,options2){if(typeof fn2!="function")throw new ERR_INVALID_ARG_TYPE("fn",["Function","AsyncFunction"],fn2);async function filterFn(value2,options3){return await fn2(value2,options3)?value2:kEmpty}return map5.call(this,filterFn,options2)}var ReduceAwareErrMissingArgs=class extends ERR_MISSING_ARGS{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}};async function reduce(reducer,initialValue,options2){var _options$signal2;if(typeof reducer!="function")throw new ERR_INVALID_ARG_TYPE("reducer",["Function","AsyncFunction"],reducer);options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal");let hasInitialValue=arguments.length>1;if(options2!=null&&(_options$signal2=options2.signal)!==null&&_options$signal2!==void 0&&_options$signal2.aborted){let err=new AbortError(void 0,{cause:options2.signal.reason});throw this.once("error",()=>{}),await finished(this.destroy(err)),err}let ac=new AbortController2,signal=ac.signal;if(options2!=null&&options2.signal){let opts={once:!0,[kWeakHandler]:this,[kResistStopPropagation]:!0};options2.signal.addEventListener("abort",()=>ac.abort(),opts)}let gotAnyItemFromStream=!1;try{for await(let value2 of this){var _options$signal3;if(gotAnyItemFromStream=!0,options2!=null&&(_options$signal3=options2.signal)!==null&&_options$signal3!==void 0&&_options$signal3.aborted)throw new AbortError;hasInitialValue?initialValue=await reducer(initialValue,value2,{signal}):(initialValue=value2,hasInitialValue=!0)}if(!gotAnyItemFromStream&&!hasInitialValue)throw new ReduceAwareErrMissingArgs}finally{ac.abort()}return initialValue}async function toArray(options2){options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal");let result=[];for await(let val of this){var _options$signal4;if(options2!=null&&(_options$signal4=options2.signal)!==null&&_options$signal4!==void 0&&_options$signal4.aborted)throw new AbortError(void 0,{cause:options2.signal.reason});ArrayPrototypePush(result,val)}return result}function flatMap(fn2,options2){let values=map5.call(this,fn2,options2);return async function*(){for await(let val of values)yield*val}.call(this)}function toIntegerOrInfinity(number){if(number=Number2(number),NumberIsNaN(number))return 0;if(number<0)throw new ERR_OUT_OF_RANGE("number",">= 0",number);return number}function drop(number,options2=void 0){return options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal"),number=toIntegerOrInfinity(number),async function*(){var _options$signal5;if(options2!=null&&(_options$signal5=options2.signal)!==null&&_options$signal5!==void 0&&_options$signal5.aborted)throw new AbortError;for await(let val of this){var _options$signal6;if(options2!=null&&(_options$signal6=options2.signal)!==null&&_options$signal6!==void 0&&_options$signal6.aborted)throw new AbortError;number--<=0&&(yield val)}}.call(this)}function take(number,options2=void 0){return options2!=null&&validateObject(options2,"options"),options2?.signal!=null&&validateAbortSignal(options2.signal,"options.signal"),number=toIntegerOrInfinity(number),async function*(){var _options$signal7;if(options2!=null&&(_options$signal7=options2.signal)!==null&&_options$signal7!==void 0&&_options$signal7.aborted)throw new AbortError;for await(let val of this){var _options$signal8;if(options2!=null&&(_options$signal8=options2.signal)!==null&&_options$signal8!==void 0&&_options$signal8.aborted)throw new AbortError;if(number-- >0&&(yield val),number<=0)return}}.call(this)}module.exports.streamReturningOperators={asIndexedPairs:deprecate(asIndexedPairs,"readable.asIndexedPairs will be removed in a future version."),drop,filter,flatMap,map:map5,take,compose};module.exports.promiseReturningOperators={every,forEach,reduce,toArray,some,find}}});var require_promises=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/stream/promises.js"(exports,module){"use strict";init_browser_globals();var{ArrayPrototypePop,Promise:Promise2}=require_primordials(),{isIterable,isNodeStream,isWebStream}=require_utils(),{pipelineImpl:pl}=require_pipeline(),{finished}=require_end_of_stream();require_stream();function pipeline(...streams){return new Promise2((resolve2,reject)=>{let signal,end,lastArg=streams[streams.length-1];if(lastArg&&typeof lastArg=="object"&&!isNodeStream(lastArg)&&!isIterable(lastArg)&&!isWebStream(lastArg)){let options2=ArrayPrototypePop(streams);signal=options2.signal,end=options2.end}pl(streams,(err,value2)=>{err?reject(err):resolve2(value2)},{signal,end})})}module.exports={finished,pipeline}}});var require_stream=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/stream.js"(exports,module){"use strict";init_browser_globals();var{Buffer:Buffer6}=require_buffer(),{ObjectDefineProperty,ObjectKeys,ReflectApply}=require_primordials(),{promisify:{custom:customPromisify}}=require_util3(),{streamReturningOperators,promiseReturningOperators}=require_operators(),{codes:{ERR_ILLEGAL_CONSTRUCTOR}}=require_errors2(),compose=require_compose(),{setDefaultHighWaterMark,getDefaultHighWaterMark}=require_state(),{pipeline}=require_pipeline(),{destroyer}=require_destroy(),eos=require_end_of_stream(),promises=require_promises(),utils=require_utils(),Stream=module.exports=require_legacy().Stream;Stream.isDestroyed=utils.isDestroyed;Stream.isDisturbed=utils.isDisturbed;Stream.isErrored=utils.isErrored;Stream.isReadable=utils.isReadable;Stream.isWritable=utils.isWritable;Stream.Readable=require_readable();for(let key of ObjectKeys(streamReturningOperators)){let fn2=function(...args){if(new.target)throw ERR_ILLEGAL_CONSTRUCTOR();return Stream.Readable.from(ReflectApply(op,this,args))},op=streamReturningOperators[key];ObjectDefineProperty(fn2,"name",{__proto__:null,value:op.name}),ObjectDefineProperty(fn2,"length",{__proto__:null,value:op.length}),ObjectDefineProperty(Stream.Readable.prototype,key,{__proto__:null,value:fn2,enumerable:!1,configurable:!0,writable:!0})}for(let key of ObjectKeys(promiseReturningOperators)){let fn2=function(...args){if(new.target)throw ERR_ILLEGAL_CONSTRUCTOR();return ReflectApply(op,this,args)},op=promiseReturningOperators[key];ObjectDefineProperty(fn2,"name",{__proto__:null,value:op.name}),ObjectDefineProperty(fn2,"length",{__proto__:null,value:op.length}),ObjectDefineProperty(Stream.Readable.prototype,key,{__proto__:null,value:fn2,enumerable:!1,configurable:!0,writable:!0})}Stream.Writable=require_writable();Stream.Duplex=require_duplex();Stream.Transform=require_transform();Stream.PassThrough=require_passthrough();Stream.pipeline=pipeline;var{addAbortSignal}=require_add_abort_signal();Stream.addAbortSignal=addAbortSignal;Stream.finished=eos;Stream.destroy=destroyer;Stream.compose=compose;Stream.setDefaultHighWaterMark=setDefaultHighWaterMark;Stream.getDefaultHighWaterMark=getDefaultHighWaterMark;ObjectDefineProperty(Stream,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return promises}});ObjectDefineProperty(pipeline,customPromisify,{__proto__:null,enumerable:!0,get(){return promises.pipeline}});ObjectDefineProperty(eos,customPromisify,{__proto__:null,enumerable:!0,get(){return promises.finished}});Stream.Stream=Stream;Stream._isUint8Array=function(value2){return value2 instanceof Uint8Array};Stream._uint8ArrayToBuffer=function(chunk){return Buffer6.from(chunk.buffer,chunk.byteOffset,chunk.byteLength)}}});var require_browser3=__commonJS({"node_modules/.pnpm/readable-stream@4.8.0/node_modules/readable-stream/lib/ours/browser.js"(exports,module){"use strict";init_browser_globals();var CustomStream=require_stream(),promises=require_promises(),originalDestroy=CustomStream.Readable.destroy;module.exports=CustomStream.Readable;module.exports._uint8ArrayToBuffer=CustomStream._uint8ArrayToBuffer;module.exports._isUint8Array=CustomStream._isUint8Array;module.exports.isDisturbed=CustomStream.isDisturbed;module.exports.isErrored=CustomStream.isErrored;module.exports.isReadable=CustomStream.isReadable;module.exports.Readable=CustomStream.Readable;module.exports.Writable=CustomStream.Writable;module.exports.Duplex=CustomStream.Duplex;module.exports.Transform=CustomStream.Transform;module.exports.PassThrough=CustomStream.PassThrough;module.exports.addAbortSignal=CustomStream.addAbortSignal;module.exports.finished=CustomStream.finished;module.exports.destroy=CustomStream.destroy;module.exports.destroy=originalDestroy;module.exports.pipeline=CustomStream.pipeline;module.exports.compose=CustomStream.compose;Object.defineProperty(CustomStream,"promises",{configurable:!0,enumerable:!0,get(){return promises}});module.exports.Stream=CustomStream.Stream;module.exports.default=module.exports}});var require_stream2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-builtins@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-builtins/lib/stream.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Writable=exports.Readable=void 0;var node_stream_1=require_browser3();Object.defineProperty(exports,"Readable",{enumerable:!0,get:function(){return node_stream_1.Readable}});Object.defineProperty(exports,"Writable",{enumerable:!0,get:function(){return node_stream_1.Writable}})}});var require_events2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-builtins@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-builtins/lib/events.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.EventEmitter=void 0;var node_events_1=require_events();Object.defineProperty(exports,"EventEmitter",{enumerable:!0,get:function(){return node_events_1.EventEmitter}})}});var require_FileHandle=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/FileHandle.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FileHandle=void 0;var util_1=require_util2(),readWriteArgs_1=require_readWriteArgs(),events_1=require_events2(),assertOpen=(fd,syscall)=>{if(fd!==-1)return;let error=new Error("file closed");throw error.code="EBADF",error.syscall=syscall,error},FileHandle=class extends events_1.EventEmitter{constructor(fs2,fd){super(),this.refs=1,this.closePromise=null,this.readableWebStreamLocked=!1,this.fs=fs2,this.fd=fd}getAsyncId(){return this.fd}appendFile(data,options2){return(0,util_1.promisify)(this.fs,"appendFile")(this.fd,data,options2)}chmod(mode){return(0,util_1.promisify)(this.fs,"fchmod")(this.fd,mode)}chown(uid,gid){return(0,util_1.promisify)(this.fs,"fchown")(this.fd,uid,gid)}close(){if(this.fd===-1)return Promise.resolve();if(this.closePromise)return this.closePromise;if(this.refs--,this.refs===0){let currentFd=this.fd;this.fd=-1,this.closePromise=(0,util_1.promisify)(this.fs,"close")(currentFd).finally(()=>{this.closePromise=null})}else this.closePromise=new Promise((resolve2,reject)=>{this.closeResolve=resolve2,this.closeReject=reject}).finally(()=>{this.closePromise=null,this.closeReject=void 0,this.closeResolve=void 0});return this.emit("close"),this.closePromise}datasync(){return(0,util_1.promisify)(this.fs,"fdatasync")(this.fd)}createReadStream(options2){return this.fs.createReadStream("",{...options2,fd:this})}createWriteStream(options2){return this.fs.createWriteStream("",{...options2,fd:this})}readableWebStream(options2={}){let{type="bytes",autoClose=!1}=options2;if(this.fd===-1)throw new Error("The FileHandle is closed");if(this.closePromise)throw new Error("The FileHandle is closing");if(this.readableWebStreamLocked)throw new Error("An error will be thrown if this method is called more than once or is called after the FileHandle is closed or closing.");this.readableWebStreamLocked=!0,this.ref();let unlockAndCleanup=()=>{this.readableWebStreamLocked=!1,this.unref(),autoClose&&this.close().catch(()=>{})};return new ReadableStream({type:type==="bytes"?"bytes":void 0,autoAllocateChunkSize:16384,pull:async controller=>{try{let view=controller.byobRequest?.view;if(!view){let buffer=new Uint8Array(16384),result2=await this.read(buffer,0,buffer.length,null);if(result2.bytesRead===0){controller.close(),unlockAndCleanup();return}controller.enqueue(buffer.slice(0,result2.bytesRead));return}let result=await this.read(view,0,view.byteLength,null);if(result.bytesRead===0){controller.close(),controller.byobRequest.respond(0),unlockAndCleanup();return}controller.byobRequest.respond(result.bytesRead)}catch(error){controller.error(error),unlockAndCleanup()}},cancel:async()=>{unlockAndCleanup()}})}async read(bufferOrParams,offsetOrOptions,length,position2){assertOpen(this.fd,"read");let args=(0,readWriteArgs_1.getHandleReadArgs)(bufferOrParams,offsetOrOptions,length,position2),buffer=args.buffer;return args.length===0?{__proto__:null,bytesRead:args.length,buffer}:{__proto__:null,bytesRead:await(0,util_1.promisify)(this.fs,"read")(this.fd,buffer,args.offset,args.length,args.position),buffer}}async readv(buffers,position2){return assertOpen(this.fd,"readv"),{__proto__:null,bytesRead:await(0,util_1.promisify)(this.fs,"readv")(this.fd,buffers,position2??null),buffers}}readFile(options2){return(0,util_1.promisify)(this.fs,"readFile")(this.fd,options2)}stat(options2){return(0,util_1.promisify)(this.fs,"fstat")(this.fd,options2)}sync(){return(0,util_1.promisify)(this.fs,"fsync")(this.fd)}truncate(len){return(0,util_1.promisify)(this.fs,"ftruncate")(this.fd,len)}utimes(atime,mtime){return(0,util_1.promisify)(this.fs,"futimes")(this.fd,atime,mtime)}async write(data,offsetOrOptions,lengthOrEncoding,position2){assertOpen(this.fd,"write");let args=(0,readWriteArgs_1.getHandleWriteArgs)(data,offsetOrOptions,lengthOrEncoding,position2);return args?{__proto__:null,bytesWritten:await(0,util_1.promisify)(this.fs,"write")(this.fd,args.buffer,args.offset,args.length,args.position),buffer:data}:{__proto__:null,bytesWritten:0,buffer:data}}async writev(buffers,position2){return assertOpen(this.fd,"writev"),{__proto__:null,bytesWritten:await(0,util_1.promisify)(this.fs,"writev")(this.fd,buffers,position2??null),buffers}}writeFile(data,options2){return(0,util_1.promisify)(this.fs,"writeFile")(this.fd,data,options2)}async[Symbol.asyncDispose](){await this.close()}ref(){this.refs++}unref(){this.refs--,this.refs===0&&(this.fd=-1,this.closeResolve&&(0,util_1.promisify)(this.fs,"close")(this.fd).then(this.closeResolve,this.closeReject))}};exports.FileHandle=FileHandle}});var require_util4=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node-builtins@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node-builtins/lib/util.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.inherits=inherits;exports.promisify=promisify;exports.inspect=inspect;exports.format=format5;function inherits(ctor,superCtor){if(ctor==null)throw new TypeError("The constructor to inherit from is not defined");if(superCtor==null)throw new TypeError("The super constructor to inherit from is not defined");ctor.super_=superCtor,ctor.prototype=Object.create(superCtor.prototype,{constructor:{value:ctor,enumerable:!1,writable:!0,configurable:!0}})}function promisify(fn2){if(typeof fn2!="function")throw new TypeError('The "original" argument must be of type function');return function(...args){return new Promise((resolve2,reject)=>{fn2.call(this,...args,(err,result)=>{err?reject(err):resolve2(result)})})}}function inspect(value2){return value2===null?"null":value2===void 0?"undefined":typeof value2=="string"?`'${value2}'`:typeof value2=="number"||typeof value2=="boolean"?String(value2):Array.isArray(value2)?`[ ${value2.map(item=>inspect(item)).join(", ")} ]`:typeof value2=="object"?`{ ${Object.entries(value2).map(([key,val])=>`${key}: ${inspect(val)}`).join(", ")} }`:String(value2)}function format5(template,...args){if(args.length===0)return template;let result=template,argIndex=0;for(result=result.replace(/%[sdj%]/g,match=>{if(argIndex>=args.length)return match;let arg=args[argIndex++];switch(match){case"%s":return String(arg);case"%d":return Number(arg).toString();case"%j":try{return JSON.stringify(arg)}catch{return"[Circular]"}case"%%":return"%";default:return match}});argIndex<args.length;)result+=" "+String(args[argIndex++]);return result}}});var require_cp=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/cp.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.cpAsync=exports.cpSync=exports.copyFileCore=exports.getCpOptions=exports.getValidCopyFileMode=void 0;var path_1=require_path2(),fs_node_utils_1=require_lib5(),fs_core_1=require_lib6(),argErrors_1=require_argErrors(),validators_1=require_validators(),pathResolve=path_1.posix.resolve,{O_RDONLY,O_WRONLY,O_CREAT,O_EXCL,COPYFILE_EXCL,COPYFILE_FICLONE_FORCE}=fs_node_utils_1.constants,PREFIX={ERR_FS_CP_DIR_TO_NON_DIR:"Cannot overwrite non-directory with directory",ERR_FS_CP_EEXIST:"Target already exists",ERR_FS_CP_EINVAL:"Invalid src or dest",ERR_FS_CP_FIFO_PIPE:"Cannot copy a FIFO pipe",ERR_FS_CP_NON_DIR_TO_DIR:"Cannot overwrite directory with non-directory",ERR_FS_CP_SOCKET:"Cannot copy a socket file",ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY:"Cannot overwrite symlink in subdirectory of self",ERR_FS_CP_UNKNOWN:"Cannot copy an unknown file type",ERR_FS_EISDIR:"Path is a directory"},cpSystemError=(code4,message,path4,errno,uv)=>new fs_core_1.SystemError(code4,PREFIX[code4],{code:uv,message,path:path4,syscall:"cp",errno}),cpCodeError=(code4,message)=>(0,argErrors_1.withNativeCode)(new Error(message),code4),invalidFilterReturn=value2=>(0,argErrors_1.withCode)(new TypeError('Expected boolean to be returned from the "filter" function but got an instance of Promise.'),"ERR_INVALID_RETURN_VALUE"),asCopyfileError=(error,src,dest)=>error&&typeof error.code=="string"&&typeof error.syscall=="string"?(0,fs_core_1.createError)(error.code,"copyfile",src,dest):error,getValidCpMode=mode=>mode==null?0:((0,validators_1.validateInteger)(mode,"mode",0,7),mode),getValidCopyFileMode=mode=>{if(mode==null)return 0;if(typeof mode!="number")throw(0,argErrors_1.withNativeCode)(new TypeError("mode must be int32 or null/undefined"),"ERR_INVALID_ARG_TYPE");if(!Number.isFinite(mode))throw(0,argErrors_1.withNativeCode)(new RangeError("mode is out of range"),"ERR_OUT_OF_RANGE");let truncated=Math.trunc(mode);if(truncated<0||truncated>7)throw(0,argErrors_1.withNativeCode)(new RangeError("mode is out of range: >= 0 && <= 7"),"ERR_OUT_OF_RANGE");return truncated};exports.getValidCopyFileMode=getValidCopyFileMode;var CP_DEFAULTS={dereference:!1,errorOnExist:!1,filter:void 0,force:!0,mode:0,preserveTimestamps:!1,recursive:!1,verbatimSymlinks:!1},getCpOptions=options2=>{if(options2===void 0)return{...CP_DEFAULTS};(0,validators_1.validateObject)(options2,"options");let resolved={...CP_DEFAULTS,...options2};if((0,validators_1.validateBoolean)(resolved.dereference,"options.dereference"),(0,validators_1.validateBoolean)(resolved.errorOnExist,"options.errorOnExist"),(0,validators_1.validateBoolean)(resolved.force,"options.force"),(0,validators_1.validateBoolean)(resolved.preserveTimestamps,"options.preserveTimestamps"),(0,validators_1.validateBoolean)(resolved.recursive,"options.recursive"),(0,validators_1.validateBoolean)(resolved.verbatimSymlinks,"options.verbatimSymlinks"),resolved.mode=getValidCpMode(options2.mode),resolved.dereference===!0&&resolved.verbatimSymlinks===!0)throw(0,argErrors_1.withCode)(new TypeError('Option "dereference" cannot be used in combination with option "verbatimSymlinks"'),"ERR_INCOMPATIBLE_OPTION_PAIR");return resolved.filter!==void 0&&(0,validators_1.validateFunction)(resolved.filter,"options.filter"),resolved};exports.getCpOptions=getCpOptions;var isPromise=value2=>!!value2&&(typeof value2=="object"||typeof value2=="function")&&typeof value2.then=="function",copyFileCore=(core,src,dest,flags)=>{let srcFd=-1,destFd=-1,copied=!1;try{srcFd=core.open(src,O_RDONLY,0);let srcNode=core.getFileByFdOrThrow(srcFd,"copyfile").node,srcMode=srcNode.mode,excl=!!(flags©FILE_EXCL);destFd=core.open(dest,excl?O_WRONLY|O_CREAT|O_EXCL:O_WRONLY|O_CREAT,438);let destNode=core.getFileByFdOrThrow(destFd,"copyfile").node;if(!excl){if(destNode===srcNode){copied=!0;return}core.ftruncate(destFd,0)}if(core.fchmod(destFd,srcMode),flags©FILE_FICLONE_FORCE)throw(0,fs_core_1.createError)("ENOSYS","copyfile",src,dest);if(srcNode.isDirectory())throw(0,fs_core_1.createError)("EISDIR","copyfile",src,dest);let size=srcNode.getSize();size>0&&core.write(destFd,srcNode.getBuffer(),0,size,0),copied=!0}catch(error){throw asCopyfileError(error,src,dest)}finally{if(srcFd>=0&&core.close(srcFd),destFd>=0&&(core.close(destFd),!copied))try{core.unlink(dest)}catch{}}};exports.copyFileCore=copyFileCore;var toParts=path4=>{let raw=pathResolve(path4).split("/"),parts=[];for(let i2=0;i2<raw.length;i2++)raw[i2]&&parts.push(raw[i2]);return parts},isSrcSubdir=(src,dest)=>{let srcArr=toParts(src),destArr=toParts(dest),length=srcArr.length;if(length>destArr.length)return!1;for(let i2=0;i2<length;i2++)if(destArr[i2]!==srcArr[i2])return!1;return!0},areIdentical=(srcStat,destStat)=>srcStat.ino===destStat.ino&&srcStat.dev===destStat.dev,statOf=(vol,path4,dereference)=>dereference?vol.statSync(path4):vol.lstatSync(path4),statOrNull=(vol,path4,dereference)=>dereference?vol.statSync(path4,{throwIfNoEntry:!1}):vol.lstatSync(path4,{throwIfNoEntry:!1}),readEntries=(vol,dir)=>{try{return vol.readdirSync(dir)}catch(error){let code4=error.code;throw code4?(0,fs_core_1.createError)(code4,"opendir",dir):error}},isDirectory=(vol,path4)=>{let stats=vol.statSync(path4,{throwIfNoEntry:!1});return!!stats&&stats.isDirectory()},setDestMode=(vol,dest,srcMode)=>{vol.chmodSync(dest,Number(srcMode))},setDestTimestamps=(vol,src,dest)=>{let updated=vol.statSync(src);vol.utimesSync(dest,updated.atime,updated.mtime)},resolveLinkTarget=(vol,src,verbatimSymlinks)=>{let target=String(vol.readlinkSync(src));return!verbatimSymlinks&&target[0]!=="/"?pathResolve((0,fs_node_utils_1.pathDirname)(src),target):target},identicalPaths=(vol,a2,b2)=>{try{let statA=vol.statSync(a2,{throwIfNoEntry:!1});if(!statA)return!1;let statB=vol.statSync(b2,{throwIfNoEntry:!1});return!!statB&&areIdentical(statA,statB)}catch{return!1}},srcAliasesAncestor=(vol,srcStat,srcParent,destParent)=>{for(let ancestor=destParent;ancestor!==srcParent&&ancestor!=="/";ancestor=(0,fs_node_utils_1.pathDirname)(ancestor)){let stat2;try{stat2=vol.statSync(ancestor,{throwIfNoEntry:!1})}catch{return!1}if(stat2){if(!stat2.isDirectory())return!1;if(areIdentical(srcStat,stat2))return!0}}return!1},checkPathsSync=(vol,src,dest,dereference,recursive)=>{let srcStat;try{srcStat=statOf(vol,src,!dereference)}catch(error){let code4=error.code;throw code4?(0,fs_core_1.createError)(code4,dereference?"stat":"lstat",src):error}let destStat;try{destStat=statOf(vol,dest,dereference)}catch{}let srcIsDir=srcStat.isDirectory()||dereference&&srcStat.isSymbolicLink(),srcPath=pathResolve(src),destPath=pathResolve(dest);if(destStat){if(identicalPaths(vol,srcPath,destPath))throw cpCodeError("ERR_FS_CP_EINVAL","src and dest cannot be the same "+destPath);let destIsDir=destStat.isDirectory();if(srcIsDir&&!destIsDir)throw cpCodeError("ERR_FS_CP_DIR_TO_NON_DIR","Cannot overwrite non-directory "+destPath+" with directory "+srcPath);if(!srcIsDir&&destIsDir)throw cpCodeError("ERR_FS_CP_NON_DIR_TO_DIR","Cannot overwrite directory "+destPath+" with non-directory "+srcPath)}let srcPrefix=srcPath==="/"?srcPath:srcPath+"/";if(srcIsDir&&destPath.startsWith(srcPrefix))throw cpCodeError("ERR_FS_CP_EINVAL","Cannot copy "+srcPrefix+" to a subdirectory of self "+destPath);let destParent=(0,fs_node_utils_1.pathDirname)(destPath),srcParent=(0,fs_node_utils_1.pathDirname)(srcPath);if(srcParent!==destParent&&destParent!=="/"&&identicalPaths(vol,srcPath,destParent))throw cpCodeError("ERR_FS_CP_EINVAL","Cannot copy "+srcPrefix+" to a subdirectory of self "+destPath);if(recursive&&srcIsDir){let copyStat=statOrNull(vol,src,dereference),followed=dereference?copyStat:srcStat;if(copyStat&&followed&©Stat.isDirectory()&&srcAliasesAncestor(vol,followed,srcParent,destParent))throw cpCodeError("ERR_FS_CP_EINVAL","Cannot copy "+srcPrefix+" to a subdirectory of self "+destPath)}if(srcIsDir&&!recursive)throw cpCodeError("ERR_FS_EISDIR","Recursive option not enabled, cannot copy a directory: "+srcPrefix);if(srcStat.isSocket())throw cpCodeError("ERR_FS_CP_SOCKET","Cannot copy a socket file: "+destPath);if(srcStat.isFIFO())throw cpCodeError("ERR_FS_CP_FIFO_PIPE","Cannot copy a FIFO pipe: "+destPath);try{(!destStat||!vol.existsSync(destParent))&&vol.mkdirSync(destParent,{recursive:!0})}catch{}},filterSync=(filter,src,dest)=>{let shouldCopy=filter(src,dest);if(isPromise(shouldCopy))throw invalidFilterReturn(shouldCopy);return!!shouldCopy},cpSync=(vol,src,dest,options2)=>{let filter=options2.filter;filter&&!filterSync(filter,src,dest)||(checkPathsSync(vol,src,dest,options2.dereference,options2.recursive),getStatsSync(vol,src,dest,options2))};exports.cpSync=cpSync;var getStatsSync=(vol,src,dest,options2)=>{let dereference=options2.dereference,srcStat=statOf(vol,src,dereference),destStat=statOrNull(vol,dest,dereference);if(srcStat.isDirectory()&&options2.recursive)return onDirSync(srcStat,destStat,vol,src,dest,options2);if(srcStat.isFile()||srcStat.isCharacterDevice()||srcStat.isBlockDevice())return onFileSync(srcStat,destStat,vol,src,dest,options2);if(srcStat.isSymbolicLink())return onLinkSync(destStat,vol,src,dest,options2.verbatimSymlinks)},onFileSync=(srcStat,destStat,vol,src,dest,options2)=>{if(destStat)if(options2.force)vol.unlinkSync(dest);else{if(options2.errorOnExist)throw cpSystemError("ERR_FS_CP_EEXIST",dest+" already exists",dest,17,"EEXIST");return}(0,exports.copyFileCore)(vol._core,src,dest,options2.mode);let srcMode=Number(srcStat.mode);setDestMode(vol,dest,srcMode),options2.preserveTimestamps&&setDestTimestamps(vol,src,dest)},onDirSync=(srcStat,destStat,vol,src,dest,options2)=>{destStat?copyDirSync(vol,src,dest,options2,!1,void 0):copyDirSync(vol,src,dest,options2,!0,Number(srcStat.mode))},copyDirSync=(vol,src,dest,options2,mkDir,srcMode)=>{mkDir&&vol.mkdirSync(dest);try{let entries=readEntries(vol,src),filter=options2.filter;for(let i2=0;i2<entries.length;i2++){let name=entries[i2],srcItem=(0,fs_node_utils_1.pathJoin)(src,name),destItem=(0,fs_node_utils_1.pathJoin)(dest,name);filter&&!filterSync(filter,srcItem,destItem)||getStatsSync(vol,srcItem,destItem,options2)}}finally{srcMode!==void 0&&setDestMode(vol,dest,srcMode)}},onLinkSync=(destStat,vol,src,dest,verbatimSymlinks)=>{let resolvedSrc=resolveLinkTarget(vol,src,verbatimSymlinks);if(!destStat){vol.symlinkSync(resolvedSrc,dest);return}let resolvedDest;try{resolvedDest=String(vol.readlinkSync(dest))}catch(error){if(error.code==="EINVAL"){vol.symlinkSync(resolvedSrc,dest);return}throw error}if(resolvedDest[0]!=="/"&&(resolvedDest=pathResolve((0,fs_node_utils_1.pathDirname)(dest),resolvedDest)),isDirectory(vol,src)&&isSrcSubdir(resolvedSrc,resolvedDest))throw cpCodeError("ERR_FS_CP_EINVAL","Cannot copy "+resolvedSrc+" to a subdirectory of self "+resolvedDest);if(isDirectory(vol,dest)&&isSrcSubdir(resolvedDest,resolvedSrc))throw cpCodeError("ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY","cannot overwrite "+resolvedDest+" with "+resolvedSrc);vol.unlinkSync(dest),vol.symlinkSync(resolvedSrc,dest)},cpAsync=async(vol,src,dest,options2)=>{let stats=await checkPaths(vol,src,dest,options2);if(!stats)return;checkParentPaths(vol,src,stats.srcStat,dest,options2.recursive);let destParent=(0,fs_node_utils_1.pathDirname)(dest);vol.existsSync(destParent)||vol.mkdirSync(destParent,{recursive:!0}),await getStatsForCopy(vol,stats.destStat,src,dest,options2)};exports.cpAsync=cpAsync;var checkPaths=async(vol,src,dest,options2)=>{let filter=options2.filter;if(filter&&!await filter(src,dest))return;let dereference=options2.dereference,srcStat=statOf(vol,src,dereference),destStat=statOrNull(vol,dest,dereference);if(destStat){if(areIdentical(srcStat,destStat))throw cpSystemError("ERR_FS_CP_EINVAL","src and dest cannot be the same",dest,22,"EINVAL");if(srcStat.isDirectory()&&!destStat.isDirectory())throw cpSystemError("ERR_FS_CP_DIR_TO_NON_DIR","cannot overwrite non-directory "+dest+" with directory "+src,dest,21,"EISDIR");if(!srcStat.isDirectory()&&destStat.isDirectory())throw cpSystemError("ERR_FS_CP_NON_DIR_TO_DIR","cannot overwrite directory "+dest+" with non-directory "+src,dest,20,"ENOTDIR")}if(srcStat.isDirectory()&&isSrcSubdir(src,dest))throw cpSystemError("ERR_FS_CP_EINVAL","cannot copy "+src+" to a subdirectory of self "+dest,dest,22,"EINVAL");return{srcStat,destStat}},checkParentPaths=(vol,src,srcStat,dest,recursive)=>{let srcParent=pathResolve((0,fs_node_utils_1.pathDirname)(src)),skipMissing=recursive&&srcStat.isDirectory(),at2=dest;for(let parent=pathResolve((0,fs_node_utils_1.pathDirname)(dest));parent!==srcParent&&parent!=="/";at2=parent,parent=(0,fs_node_utils_1.pathDirname)(parent)){let parentStat=vol.statSync(parent,{throwIfNoEntry:!1});if(!parentStat){if(skipMissing)continue;return}if(areIdentical(srcStat,parentStat))throw cpSystemError("ERR_FS_CP_EINVAL","cannot copy "+src+" to a subdirectory of self "+at2,at2,22,"EINVAL")}},getStatsForCopy=async(vol,destStat,src,dest,options2)=>{let srcStat=statOf(vol,src,options2.dereference);if(srcStat.isDirectory()&&options2.recursive)return onDir(vol,srcStat,destStat,src,dest,options2);if(srcStat.isDirectory())throw cpSystemError("ERR_FS_EISDIR",src+" is a directory (not copied)",src,21,"EISDIR");if(srcStat.isFile()||srcStat.isCharacterDevice()||srcStat.isBlockDevice())return onFile(vol,srcStat,destStat,src,dest,options2);if(srcStat.isSymbolicLink())return onLink(vol,destStat,src,dest,options2);throw srcStat.isSocket()?cpSystemError("ERR_FS_CP_SOCKET","cannot copy a socket file: "+dest,dest,22,"EINVAL"):srcStat.isFIFO()?cpSystemError("ERR_FS_CP_FIFO_PIPE","cannot copy a FIFO pipe: "+dest,dest,22,"EINVAL"):cpSystemError("ERR_FS_CP_UNKNOWN","cannot copy an unknown file type: "+dest,dest,22,"EINVAL")},onFile=async(vol,srcStat,destStat,src,dest,options2)=>{if(destStat)if(options2.force)vol.unlinkSync(dest);else{if(options2.errorOnExist)throw cpSystemError("ERR_FS_CP_EEXIST",dest+" already exists",dest,17,"EEXIST");return}(0,exports.copyFileCore)(vol._core,src,dest,options2.mode);let srcMode=Number(srcStat.mode);setDestMode(vol,dest,srcMode),options2.preserveTimestamps&&setDestTimestamps(vol,src,dest)},onDir=async(vol,srcStat,destStat,src,dest,options2)=>{if(!destStat){vol.mkdirSync(dest),await copyDir(vol,src,dest,options2),setDestMode(vol,dest,Number(srcStat.mode));return}if(options2.errorOnExist&&!options2.force)throw cpSystemError("ERR_FS_CP_EEXIST",dest+" already exists",dest,17,"EEXIST");await copyDir(vol,src,dest,options2)},copyDir=async(vol,src,dest,options2)=>{let entries=readEntries(vol,src);for(let i2=0;i2<entries.length;i2++){let name=entries[i2],srcItem=(0,fs_node_utils_1.pathJoin)(src,name),destItem=(0,fs_node_utils_1.pathJoin)(dest,name),checked=await checkPaths(vol,srcItem,destItem,options2);checked&&await getStatsForCopy(vol,checked.destStat,srcItem,destItem,options2)}},onLink=async(vol,destStat,src,dest,options2)=>{let resolvedSrc=resolveLinkTarget(vol,src,options2.verbatimSymlinks);if(!destStat){vol.symlinkSync(resolvedSrc,dest);return}let resolvedDest;try{resolvedDest=String(vol.readlinkSync(dest))}catch(error){if(error.code==="EINVAL"){vol.symlinkSync(resolvedSrc,dest);return}throw error}if(resolvedDest[0]!=="/"&&(resolvedDest=pathResolve((0,fs_node_utils_1.pathDirname)(dest),resolvedDest)),isDirectory(vol,src)&&isSrcSubdir(resolvedSrc,resolvedDest))throw cpSystemError("ERR_FS_CP_EINVAL","cannot copy "+resolvedSrc+" to a subdirectory of self "+resolvedDest,dest,22,"EINVAL");if(statOf(vol,src,!0).isDirectory()&&isSrcSubdir(resolvedDest,resolvedSrc))throw cpSystemError("ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY","cannot overwrite "+resolvedDest+" with "+resolvedSrc,dest,22,"EINVAL");vol.unlinkSync(dest),vol.symlinkSync(resolvedSrc,dest)}}});var require_FsPromises=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/FsPromises.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FsPromises=void 0;var util_1=require_util2(),cp_1=require_cp(),glob_1=require_glob(),fs_node_utils_1=require_lib5(),newAbortError=signal=>{let error=new Error("The operation was aborted");return error.name="AbortError",error.code="ABORT_ERR",error.cause=signal.reason,error},FSWatchAsyncIterator=class{constructor(fs2,path4,options2={}){this.fs=fs2,this.path=path4,this.options=options2,this.eventQueue=[],this.resolveQueue=[],this.finished=!1,this.maxQueue=options2.maxQueue||2048;let overflow=options2.overflow||"ignore";if(overflow!=="ignore"&&overflow!=="error"&&overflow!=="throw")throw new TypeError(`The argument 'options.overflow' must be one of: 'ignore', 'error'. Received '${overflow}'`);this.overflow=overflow==="throw"?"error":overflow;let signal=options2.signal;if(signal){if(signal.aborted){this.finish(newAbortError(signal));return}this.onAbort=()=>this.finish(newAbortError(signal)),signal.addEventListener("abort",this.onAbort)}this.startWatching()}startWatching(){let{signal,...watchOptions}=this.options;try{this.watcher=this.fs.watch(this.path,watchOptions,(eventType,filename)=>{this.enqueueEvent({eventType,filename})})}catch(error){throw this.finish(),error}}enqueueEvent(event){if(!this.finished){if(this.eventQueue.length>=this.maxQueue){if(this.overflow==="error"){let error=new Error(`Watch queue overflow: more than ${this.maxQueue} events queued`);error.code="ERR_FS_WATCH_QUEUE_OVERFLOW",this.finish(error)}else typeof process<"u"&&typeof process.emitWarning=="function"&&process.emitWarning("fs.watch maxQueue exceeded");return}if(this.eventQueue.push(event),this.resolveQueue.length>0){let{resolve:resolve2}=this.resolveQueue.shift(),nextEvent=this.eventQueue.shift();resolve2({value:nextEvent,done:!1})}}}finish(error){if(this.finished)return;this.finished=!0,this.error=error,error&&(this.eventQueue.length=0),this.onAbort&&(this.options.signal.removeEventListener("abort",this.onAbort),this.onAbort=void 0),this.watcher&&(this.watcher.close(),this.watcher=null);let delivered=error&&this.resolveQueue.length>0;for(;this.resolveQueue.length>0;){let{resolve:resolve2,reject}=this.resolveQueue.shift();error?reject(error):resolve2({value:void 0,done:!0})}delivered&&(this.error=void 0)}async next(){if(this.error){let error=this.error;throw this.error=void 0,error}return this.finished?{value:void 0,done:!0}:this.eventQueue.length>0?{value:this.eventQueue.shift(),done:!1}:new Promise((resolve2,reject)=>{this.resolveQueue.push({resolve:resolve2,reject})})}async return(){return this.finish(),{value:void 0,done:!0}}async throw(error){throw this.finish(error),error}[Symbol.asyncIterator](){return this}},FsPromises=class{constructor(fs2,FileHandle){this.fs=fs2,this.FileHandle=FileHandle,this.constants=fs_node_utils_1.constants,this.cp=(src,dest,options2)=>new Promise((resolve2,reject)=>{this.fs.cp(src,dest,(0,cp_1.getCpOptions)(options2),error=>error?reject(error):resolve2())}),this.copyFile=(src,dest,mode)=>new Promise((resolve2,reject)=>{this.fs.copyFile(src,dest,mode,error=>error?reject(error):resolve2())}),this.opendir=(0,util_1.promisify)(this.fs,"opendir"),this.statfs=(0,util_1.promisify)(this.fs,"statfs"),this.lutimes=(0,util_1.promisify)(this.fs,"lutimes"),this.glob=(pattern,options2)=>(0,glob_1.glob)(this.fs,pattern,options2),this.access=(0,util_1.promisify)(this.fs,"access"),this.chmod=(0,util_1.promisify)(this.fs,"chmod"),this.chown=(0,util_1.promisify)(this.fs,"chown"),this.lchmod=(0,util_1.promisify)(this.fs,"lchmod"),this.lchown=(0,util_1.promisify)(this.fs,"lchown"),this.link=(0,util_1.promisify)(this.fs,"link"),this.lstat=(0,util_1.promisify)(this.fs,"lstat"),this.mkdir=(0,util_1.promisify)(this.fs,"mkdir"),this.mkdtemp=(0,util_1.promisify)(this.fs,"mkdtemp"),this.readdir=(0,util_1.promisify)(this.fs,"readdir"),this.readlink=(0,util_1.promisify)(this.fs,"readlink"),this.realpath=(0,util_1.promisify)(this.fs,"realpath"),this.rename=(0,util_1.promisify)(this.fs,"rename"),this.rmdir=(0,util_1.promisify)(this.fs,"rmdir"),this.rm=(0,util_1.promisify)(this.fs,"rm"),this.stat=(0,util_1.promisify)(this.fs,"stat"),this.symlink=(0,util_1.promisify)(this.fs,"symlink"),this.truncate=(0,util_1.promisify)(this.fs,"truncate"),this.unlink=(0,util_1.promisify)(this.fs,"unlink"),this.utimes=(0,util_1.promisify)(this.fs,"utimes"),this.readFile=(id,options2)=>(0,util_1.promisify)(this.fs,"readFile")(id instanceof this.FileHandle?id.fd:id,options2),this.appendFile=(path4,data,options2)=>(0,util_1.promisify)(this.fs,"appendFile")(path4 instanceof this.FileHandle?path4.fd:path4,data,options2),this.open=(path4,flags="r",mode)=>(0,util_1.promisify)(this.fs,"open",fd=>new this.FileHandle(this.fs,fd))(path4,flags,mode),this.writeFile=(id,data,options2)=>((0,util_1.isReadableStream)(data)?(0,util_1.streamToBuffer)(data):Promise.resolve(data)).then(data2=>(0,util_1.promisify)(this.fs,"writeFile")(id instanceof this.FileHandle?id.fd:id,data2,options2)),this.watch=(filename,options2)=>{let watchOptions=typeof options2=="string"?{encoding:options2}:options2||{};return new FSWatchAsyncIterator(this.fs,filename,watchOptions)}}};exports.FsPromises=FsPromises}});var require_printTree=__commonJS({"node_modules/.pnpm/tree-dump@1.1.0_tslib@2.9.1/node_modules/tree-dump/lib/printTree.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.printTree=void 0;var printTree=(tab="",children)=>{let str="",last=children.length-1;for(;last>=0&&!children[last];last--);for(let i2=0;i2<=last;i2++){let fn2=children[i2];if(!fn2)continue;let isLast=i2===last,child=fn2(tab+(isLast?" ":"\u2502")+" "),branch2=child?isLast?"\u2514\u2500":"\u251C\u2500":"\u2502";str+=`
|
|
43
43
|
`+tab+branch2+(child?" "+child:"")}return str};exports.printTree=printTree}});var require_printBinary=__commonJS({"node_modules/.pnpm/tree-dump@1.1.0_tslib@2.9.1/node_modules/tree-dump/lib/printBinary.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.printBinary=void 0;var printBinary=(tab="",children)=>{let left=children[0],right=children[1],str="";return left&&(str+=`
|
|
44
44
|
`+tab+"\u2190 "+left(tab+" ")),right&&(str+=`
|
|
45
45
|
`+tab+"\u2192 "+right(tab+" ")),str};exports.printBinary=printBinary}});var require_printJson=__commonJS({"node_modules/.pnpm/tree-dump@1.1.0_tslib@2.9.1/node_modules/tree-dump/lib/printJson.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.printJson=void 0;var printJson=(tab="",json,space=2)=>(JSON.stringify(json,null,space)||"nil").split(`
|
|
46
46
|
`).join(`
|
|
47
47
|
`+tab);exports.printJson=printJson}});var require_lib7=__commonJS({"node_modules/.pnpm/tree-dump@1.1.0_tslib@2.9.1/node_modules/tree-dump/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports));tslib_1.__exportStar(require_printTree(),exports);tslib_1.__exportStar(require_printBinary(),exports);tslib_1.__exportStar(require_printJson(),exports)}});var require_lib8=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-print@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-print/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.toTreeSync=void 0;var tree_dump_1=require_lib7(),fs_node_utils_1=require_lib5(),toTreeSync=(fs2,opts={})=>{let separator=opts.separator||"/",dir=opts.dir||separator;dir[dir.length-1]!==separator&&(dir+=separator);let tab=opts.tab||"",depth=opts.depth??10,sort2=opts.sort??!0,subtree=" (...)";if(depth>0){let list5=fs2.readdirSync(dir,{withFileTypes:!0});sort2&&list5.sort((a2,b2)=>a2.isDirectory()&&b2.isDirectory()?a2.name.toString().localeCompare(b2.name.toString()):a2.isDirectory()?-1:b2.isDirectory()?1:a2.name.toString().localeCompare(b2.name.toString())),subtree=(0,tree_dump_1.printTree)(tab,list5.map(entry=>tab2=>entry.isDirectory()?(0,exports.toTreeSync)(fs2,{dir:dir+entry.name,depth:depth-1,tab:tab2}):entry.isSymbolicLink()?""+entry.name+" \u2192 "+fs2.readlinkSync(dir+entry.name):""+entry.name))}return(0,fs_node_utils_1.basename)(dir,separator)+separator+subtree};exports.toTreeSync=toTreeSync}});var require_constants4=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/constants.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0})}});var require_Slice=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/Slice.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Slice=void 0;var Slice=class{constructor(uint8,view,start,end){this.uint8=uint8,this.view=view,this.start=start,this.end=end}subarray(){return this.uint8.subarray(this.start,this.end)}};exports.Slice=Slice}});var require_Writer=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/Writer.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Writer=void 0;var Slice_1=require_Slice(),EMPTY_UINT8=new Uint8Array([]),EMPTY_VIEW=new DataView(EMPTY_UINT8.buffer),hasBuffer=typeof import_buffer.Buffer=="function",utf8Write=hasBuffer?import_buffer.Buffer.prototype.utf8Write:null,from=hasBuffer?import_buffer.Buffer.from:null,textEncoder=typeof TextEncoder<"u"?new TextEncoder:null,Writer=class{constructor(allocSize=64*1024){this.allocSize=allocSize,this.view=EMPTY_VIEW,this.x0=0,this.x=0,this.uint8=new Uint8Array(allocSize),this.size=allocSize,this.view=new DataView(this.uint8.buffer)}grow(size){let x0=this.x0,x2=this.x,oldUint8=this.uint8,newUint8=new Uint8Array(size),view=new DataView(newUint8.buffer),activeSlice=oldUint8.subarray(x0,x2);newUint8.set(activeSlice,0),this.x=x2-x0,this.x0=0,this.uint8=newUint8,this.size=size,this.view=view}ensureCapacity(capacity){let byteLength=this.size,remaining=byteLength-this.x;if(remaining<capacity){let total=byteLength-this.x0,required=capacity-remaining,totalRequired=total+required;this.grow(totalRequired<=this.allocSize?this.allocSize:totalRequired*2)}}move(capacity){this.ensureCapacity(capacity),this.x+=capacity}reset(){this.x0=this.x}newBuffer(size){let uint8=this.uint8=new Uint8Array(size);this.size=size,this.view=new DataView(uint8.buffer),this.x=this.x0=0}flush(){let result=this.uint8.subarray(this.x0,this.x);return this.x0=this.x,result}flushSlice(){let slice=new Slice_1.Slice(this.uint8,this.view,this.x0,this.x);return this.x0=this.x,slice}u8(char){this.ensureCapacity(1),this.uint8[this.x++]=char}u16(word){this.ensureCapacity(2),this.view.setUint16(this.x,word),this.x+=2}u32(dword){this.ensureCapacity(4),this.view.setUint32(this.x,dword),this.x+=4}i32(dword){this.ensureCapacity(4),this.view.setInt32(this.x,dword),this.x+=4}u64(qword){this.ensureCapacity(8),this.view.setBigUint64(this.x,BigInt(qword)),this.x+=8}f64(float3){this.ensureCapacity(8),this.view.setFloat64(this.x,float3),this.x+=8}u8u16(u8,u16){this.ensureCapacity(3);let x2=this.x;this.uint8[x2++]=u8,this.uint8[x2++]=u16>>>8,this.uint8[x2++]=u16&255,this.x=x2}u8u32(u8,u32){this.ensureCapacity(5);let x2=this.x;this.uint8[x2++]=u8,this.view.setUint32(x2,u32),this.x=x2+4}u8u64(u8,u64){this.ensureCapacity(9);let x2=this.x;this.uint8[x2++]=u8,this.view.setBigUint64(x2,BigInt(u64)),this.x=x2+8}u8f32(u8,f32){this.ensureCapacity(5);let x2=this.x;this.uint8[x2++]=u8,this.view.setFloat32(x2,f32),this.x=x2+4}u8f64(u8,f64){this.ensureCapacity(9);let x2=this.x;this.uint8[x2++]=u8,this.view.setFloat64(x2,f64),this.x=x2+8}buf(buf,length){this.ensureCapacity(length);let x2=this.x;this.uint8.set(buf,x2),this.x=x2+length}utf8(str){let theoreticalMaxLength=str.length*4;if(theoreticalMaxLength<168)return this.utf8Native(str);this.ensureCapacity(theoreticalMaxLength);let maxLength=this.size-this.x;if(utf8Write){let writeLength=utf8Write.call(this.uint8,str,this.x,maxLength);return this.x+=writeLength,writeLength}else if(from){let uint8=this.uint8,offset=uint8.byteOffset+this.x,writeLength=from(uint8.buffer).subarray(offset,offset+maxLength).write(str,0,maxLength,"utf8");return this.x+=writeLength,writeLength}else if(theoreticalMaxLength>1024&&textEncoder){let writeLength=textEncoder.encodeInto(str,this.uint8.subarray(this.x,this.x+maxLength)).written;return this.x+=writeLength,writeLength}return this.utf8Native(str)}utf8Native(str){let length=str.length,uint8=this.uint8,offset=this.x,pos=0;for(;pos<length;){let value2=str.charCodeAt(pos++);if((value2&4294967168)===0){uint8[offset++]=value2;continue}else if((value2&4294965248)===0)uint8[offset++]=value2>>6&31|192;else{if(value2>=55296&&value2<=56319&&pos<length){let extra=str.charCodeAt(pos);(extra&64512)===56320&&(pos++,value2=((value2&1023)<<10)+(extra&1023)+65536)}(value2&4294901760)===0?(uint8[offset++]=value2>>12&15|224,uint8[offset++]=value2>>6&63|128):(uint8[offset++]=value2>>18&7|240,uint8[offset++]=value2>>12&63|128,uint8[offset++]=value2>>6&63|128)}uint8[offset++]=value2&63|128}let writeLength=offset-this.x;return this.x=offset,writeLength}ascii(str){let length=str.length;this.ensureCapacity(length);let uint8=this.uint8,x2=this.x,pos=0;for(;pos<length;)uint8[x2++]=str.charCodeAt(pos++);this.x=x2}};exports.Writer=Writer}});var require_shared=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/shared.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.validateEntryName=exports.writer=void 0;var Writer_1=require_Writer();exports.writer=new Writer_1.Writer(1024*32);var validateEntryName=name=>{if(!name||name==="."||name===".."||name.indexOf("/")!==-1||name.indexOf("\\")!==-1)throw new Error(`Invalid snapshot entry name: ${JSON.stringify(name)}`)};exports.validateEntryName=validateEntryName}});var require_sync=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/sync.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fromSnapshotSync=exports.toSnapshotSync=void 0;var shared_1=require_shared(),toSnapshotSync=({fs:fs2,path:path4="/",separator="/"})=>{let stats=fs2.lstatSync(path4);if(stats.isDirectory()){let list5=fs2.readdirSync(path4),entries={},dir=path4.endsWith(separator)?path4:path4+separator;for(let child of list5){let childSnapshot=(0,exports.toSnapshotSync)({fs:fs2,path:`${dir}${child}`,separator});childSnapshot&&(entries[""+child]=childSnapshot)}return[0,{},entries]}else if(stats.isFile()){let buf=fs2.readFileSync(path4),uint8=new Uint8Array(buf.buffer,buf.byteOffset,buf.byteLength);return[1,{},uint8]}else if(stats.isSymbolicLink())return[2,{target:fs2.readlinkSync(path4).toString()}];return null};exports.toSnapshotSync=toSnapshotSync;var fromSnapshotSync=(snapshot,{fs:fs2,path:path4="/",separator="/"})=>{if(snapshot)switch(snapshot[0]){case 0:{path4.endsWith(separator)||(path4=path4+separator);let[,,entries]=snapshot;fs2.mkdirSync(path4,{recursive:!0});for(let[name,child]of Object.entries(entries))(0,shared_1.validateEntryName)(name),(0,exports.fromSnapshotSync)(child,{fs:fs2,path:`${path4}${name}`,separator});break}case 1:{let[,,data]=snapshot;fs2.writeFileSync(path4,data);break}case 2:{let[,{target}]=snapshot;fs2.symlinkSync(target,path4);break}}};exports.fromSnapshotSync=fromSnapshotSync}});var require_isFloat32=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/isFloat32.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.isFloat32=void 0;var view=new DataView(new ArrayBuffer(4)),isFloat32=n2=>(view.setFloat32(0,n2),n2===view.getFloat32(0));exports.isFloat32=isFloat32}});var require_JsonPackExtension=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/JsonPackExtension.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.JsonPackExtension=void 0;var JsonPackExtension=class{constructor(tag2,val){this.tag=tag2,this.val=val}};exports.JsonPackExtension=JsonPackExtension}});var require_CborEncoderFast=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/cbor/CborEncoderFast.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.CborEncoderFast=void 0;var Writer_1=require_Writer(),isSafeInteger=Number.isSafeInteger,CborEncoderFast=class{constructor(writer=new Writer_1.Writer){this.writer=writer}encode(value2){return this.writeAny(value2),this.writer.flush()}writeAny(value2){switch(typeof value2){case"number":return this.writeNumber(value2);case"string":return this.writeStr(value2);case"boolean":return this.writer.u8(244+ +value2);case"object":return value2?value2.constructor===Array?this.writeArr(value2):this.writeObj(value2):this.writer.u8(246)}}writeCbor(){this.writer.u8u16(217,55799)}writeEnd(){this.writer.u8(255)}writeNull(){this.writer.u8(246)}writeBoolean(bool2){bool2?this.writer.u8(245):this.writer.u8(244)}writeNumber(num3){isSafeInteger(num3)?this.writeInteger(num3):typeof num3=="bigint"?this.writeBigInt(num3):this.writeFloat(num3)}writeBigInt(int3){int3>=0?this.writeBigUint(int3):this.writeBigSint(int3)}writeBigUint(uint){if(uint<=Number.MAX_SAFE_INTEGER)return this.writeUInteger(Number(uint));this.writer.u8u64(27,uint)}writeBigSint(int3){if(int3>=Number.MIN_SAFE_INTEGER)return this.encodeNint(Number(int3));let uint=-BigInt(1)-int3;this.writer.u8u64(59,uint)}writeInteger(int3){int3>=0?this.writeUInteger(int3):this.encodeNint(int3)}writeUInteger(uint){let writer=this.writer;writer.ensureCapacity(9);let uint8=writer.uint8,x2=writer.x;uint<=23?uint8[x2++]=0+uint:uint<=255?(uint8[x2++]=24,uint8[x2++]=uint):uint<=65535?(uint8[x2++]=25,writer.view.setUint16(x2,uint),x2+=2):uint<=4294967295?(uint8[x2++]=26,writer.view.setUint32(x2,uint),x2+=4):(uint8[x2++]=27,writer.view.setBigUint64(x2,BigInt(uint)),x2+=8),writer.x=x2}encodeNumber(num3){this.writeNumber(num3)}encodeInteger(int3){this.writeInteger(int3)}encodeUint(uint){this.writeUInteger(uint)}encodeNint(int3){let uint=-1-int3,writer=this.writer;writer.ensureCapacity(9);let uint8=writer.uint8,x2=writer.x;uint<24?uint8[x2++]=32+uint:uint<=255?(uint8[x2++]=56,uint8[x2++]=uint):uint<=65535?(uint8[x2++]=57,writer.view.setUint16(x2,uint),x2+=2):uint<=4294967295?(uint8[x2++]=58,writer.view.setUint32(x2,uint),x2+=4):(uint8[x2++]=59,writer.view.setBigUint64(x2,BigInt(uint)),x2+=8),writer.x=x2}writeFloat(float3){this.writer.u8f64(251,float3)}writeBin(buf){let length=buf.length;this.writeBinHdr(length),this.writer.buf(buf,length)}writeBinHdr(length){let writer=this.writer;length<=23?writer.u8(64+length):length<=255?writer.u16(22528+length):length<=65535?writer.u8u16(89,length):length<=4294967295?writer.u8u32(90,length):writer.u8u64(91,length)}writeStr(str){let writer=this.writer,maxSize=str.length*4;writer.ensureCapacity(5+maxSize);let uint8=writer.uint8,lengthOffset=writer.x;maxSize<=23?writer.x++:maxSize<=255?(uint8[writer.x++]=120,lengthOffset=writer.x,writer.x++):maxSize<=65535?(uint8[writer.x++]=121,lengthOffset=writer.x,writer.x+=2):(uint8[writer.x++]=122,lengthOffset=writer.x,writer.x+=4);let bytesWritten=writer.utf8(str);maxSize<=23?uint8[lengthOffset]=96+bytesWritten:maxSize<=255?uint8[lengthOffset]=bytesWritten:maxSize<=65535?writer.view.setUint16(lengthOffset,bytesWritten):writer.view.setUint32(lengthOffset,bytesWritten)}writeStrHdr(length){let writer=this.writer;length<=23?writer.u8(96+length):length<=255?writer.u16(30720+length):length<=65535?writer.u8u16(121,length):writer.u8u32(122,length)}writeAsciiStr(str){this.writeStrHdr(str.length),this.writer.ascii(str)}writeArr(arr){let length=arr.length;this.writeArrHdr(length);for(let i2=0;i2<length;i2++)this.writeAny(arr[i2])}writeArrHdr(length){let writer=this.writer;length<=23?writer.u8(128+length):length<=255?writer.u16(38912+length):length<=65535?writer.u8u16(153,length):length<=4294967295?writer.u8u32(154,length):writer.u8u64(155,length)}writeObj(obj){let keys=Object.keys(obj),length=keys.length;this.writeObjHdr(length);for(let i2=0;i2<length;i2++){let key=keys[i2];this.writeStr(key),this.writeAny(obj[key])}}writeObjHdr(length){let writer=this.writer;length<=23?writer.u8(160+length):length<=255?writer.u16(47104+length):length<=65535?writer.u8u16(185,length):length<=4294967295?writer.u8u32(186,length):writer.u8u64(187,length)}writeMapHdr(length){this.writeObjHdr(length)}writeStartMap(){this.writer.u8(191)}writeTag(tag2,value2){this.writeTagHdr(tag2),this.writeAny(value2)}writeTagHdr(tag2){let writer=this.writer;tag2<=23?writer.u8(192+tag2):tag2<=255?writer.u16(55296+tag2):tag2<=65535?writer.u8u16(217,tag2):tag2<=4294967295?writer.u8u32(218,tag2):writer.u8u64(219,tag2)}writeTkn(value2){let writer=this.writer;value2<=23?writer.u8(224+value2):value2<=255&&writer.u16(63488+value2)}writeStartStr(){this.writer.u8(127)}writeStrChunk(str){throw new Error("Not implemented")}writeEndStr(){throw new Error("Not implemented")}writeStartBin(){this.writer.u8(95)}writeBinChunk(buf){throw new Error("Not implemented")}writeEndBin(){throw new Error("Not implemented")}writeStartArr(){this.writer.u8(159)}writeArrChunk(item){throw new Error("Not implemented")}writeEndArr(){this.writer.u8(255)}writeStartObj(){this.writer.u8(191)}writeObjChunk(key,value2){throw new Error("Not implemented")}writeEndObj(){this.writer.u8(255)}};exports.CborEncoderFast=CborEncoderFast}});var require_JsonPackValue=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/JsonPackValue.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.JsonPackValue=void 0;var JsonPackValue=class{constructor(val){this.val=val}};exports.JsonPackValue=JsonPackValue}});var require_CborEncoder=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/cbor/CborEncoder.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.CborEncoder=void 0;var isFloat32_1=require_isFloat32(),JsonPackExtension_1=require_JsonPackExtension(),CborEncoderFast_1=require_CborEncoderFast(),JsonPackValue_1=require_JsonPackValue(),CborEncoder=class extends CborEncoderFast_1.CborEncoderFast{writeUnknown(value2){this.writeNull()}writeAny(value2){switch(typeof value2){case"number":return this.writeNumber(value2);case"string":return this.writeStr(value2);case"boolean":return this.writer.u8(244+ +value2);case"object":{if(!value2)return this.writer.u8(246);switch(value2.constructor){case Object:return this.writeObj(value2);case Array:return this.writeArr(value2);case Uint8Array:return this.writeBin(value2);case Map:return this.writeMap(value2);case JsonPackExtension_1.JsonPackExtension:return this.writeTag(value2.tag,value2.val);case JsonPackValue_1.JsonPackValue:{let buf=value2.val;return this.writer.buf(buf,buf.length)}default:return value2 instanceof Uint8Array?this.writeBin(value2):Array.isArray(value2)?this.writeArr(value2):value2 instanceof Map?this.writeMap(value2):this.writeUnknown(value2)}}case"undefined":return this.writeUndef();case"bigint":return this.writeBigInt(value2);default:return this.writeUnknown(value2)}}writeFloat(float3){(0,isFloat32_1.isFloat32)(float3)?this.writer.u8f32(250,float3):this.writer.u8f64(251,float3)}writeMap(map5){this.writeMapHdr(map5.size),map5.forEach((value2,key)=>{this.writeAny(key),this.writeAny(value2)})}writeUndef(){this.writer.u8(247)}};exports.CborEncoder=CborEncoder}});var require_f16=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/f16.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.decodeF16=void 0;var pow=Math.pow,decodeF16=binary2=>{let exponent=(binary2&31744)>>10,fraction=binary2&1023;return(binary2>>15?-1:1)*(exponent?exponent===31?fraction?NaN:1/0:pow(2,exponent-15)*(1+fraction/1024):6103515625e-14*(fraction/1024))};exports.decodeF16=decodeF16}});var require_decodeAscii=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/utf8/decodeAscii.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.decodeAsciiMax15=exports.decodeAscii=void 0;var fromCharCode=String.fromCharCode,decodeAscii=(src,position2,length)=>{let bytes=[];for(let i2=0;i2<length;i2++){let byte=src[position2++];if(byte&128)return;bytes.push(byte)}return fromCharCode.apply(String,bytes)};exports.decodeAscii=decodeAscii;var decodeAsciiMax15=(src,position2,length)=>{if(length<4)if(length<2){if(length===0)return"";{let a2=src[position2++];if((a2&128)>1){position2-=1;return}return fromCharCode(a2)}}else{let a2=src[position2++],b2=src[position2++];if((a2&128)>0||(b2&128)>0){position2-=2;return}if(length<3)return fromCharCode(a2,b2);let c2=src[position2++];if((c2&128)>0){position2-=3;return}return fromCharCode(a2,b2,c2)}else{let a2=src[position2++],b2=src[position2++],c2=src[position2++],d2=src[position2++];if((a2&128)>0||(b2&128)>0||(c2&128)>0||(d2&128)>0){position2-=4;return}if(length<6){if(length===4)return fromCharCode(a2,b2,c2,d2);{let e2=src[position2++];if((e2&128)>0){position2-=5;return}return fromCharCode(a2,b2,c2,d2,e2)}}else if(length<8){let e2=src[position2++],f2=src[position2++];if((e2&128)>0||(f2&128)>0){position2-=6;return}if(length<7)return fromCharCode(a2,b2,c2,d2,e2,f2);let g2=src[position2++];if((g2&128)>0){position2-=7;return}return fromCharCode(a2,b2,c2,d2,e2,f2,g2)}else{let e2=src[position2++],f2=src[position2++],g2=src[position2++],h2=src[position2++];if((e2&128)>0||(f2&128)>0||(g2&128)>0||(h2&128)>0){position2-=8;return}if(length<10){if(length===8)return fromCharCode(a2,b2,c2,d2,e2,f2,g2,h2);{let i2=src[position2++];if((i2&128)>0){position2-=9;return}return fromCharCode(a2,b2,c2,d2,e2,f2,g2,h2,i2)}}else if(length<12){let i2=src[position2++],j=src[position2++];if((i2&128)>0||(j&128)>0){position2-=10;return}if(length<11)return fromCharCode(a2,b2,c2,d2,e2,f2,g2,h2,i2,j);let k=src[position2++];if((k&128)>0){position2-=11;return}return fromCharCode(a2,b2,c2,d2,e2,f2,g2,h2,i2,j,k)}else{let i2=src[position2++],j=src[position2++],k=src[position2++],l2=src[position2++];if((i2&128)>0||(j&128)>0||(k&128)>0||(l2&128)>0){position2-=12;return}if(length<14){if(length===12)return fromCharCode(a2,b2,c2,d2,e2,f2,g2,h2,i2,j,k,l2);{let m2=src[position2++];if((m2&128)>0){position2-=13;return}return fromCharCode(a2,b2,c2,d2,e2,f2,g2,h2,i2,j,k,l2,m2)}}else{let m2=src[position2++],n2=src[position2++];if((m2&128)>0||(n2&128)>0){position2-=14;return}if(length<15)return fromCharCode(a2,b2,c2,d2,e2,f2,g2,h2,i2,j,k,l2,m2,n2);let o2=src[position2++];if((o2&128)>0){position2-=15;return}return fromCharCode(a2,b2,c2,d2,e2,f2,g2,h2,i2,j,k,l2,m2,n2,o2)}}}}};exports.decodeAsciiMax15=decodeAsciiMax15}});var require_v18=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/utf8/decodeUtf8/v18.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});var fromCharCode=String.fromCharCode;exports.default=(buf,start,length)=>{let offset=start,end=offset+length,points=[];for(;offset<end;){let code4=buf[offset++];if((code4&128)!==0){let octet2=buf[offset++]&63;if((code4&224)===192)code4=(code4&31)<<6|octet2;else{let octet3=buf[offset++]&63;if((code4&240)===224)code4=(code4&31)<<12|octet2<<6|octet3;else if((code4&248)===240){let octet4=buf[offset++]&63,unit=(code4&7)<<18|octet2<<12|octet3<<6|octet4;if(unit>65535){unit-=65536;let unit0=unit>>>10&1023|55296;code4=56320|unit&1023,points.push(unit0)}else code4=unit}}}points.push(code4)}return fromCharCode.apply(String,points)}}});var require_v16=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/utf8/decodeUtf8/v16.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports)),decodeAscii_1=require_decodeAscii(),v18_1=tslib_1.__importDefault(require_v18()),hasBuffer=typeof import_buffer.Buffer<"u",utf8Slice=hasBuffer?import_buffer.Buffer.prototype.utf8Slice:null,from=hasBuffer?import_buffer.Buffer.from:null,shortDecoder=(buf,start,length)=>(0,decodeAscii_1.decodeAsciiMax15)(buf,start,length)??(0,v18_1.default)(buf,start,length),midDecoder=(buf,start,length)=>(0,decodeAscii_1.decodeAscii)(buf,start,length)??(0,v18_1.default)(buf,start,length),longDecoder=utf8Slice?(buf,start,length)=>utf8Slice.call(buf,start,start+length):from?(buf,start,length)=>from(buf).subarray(start,start+length).toString("utf8"):v18_1.default,decoder=(buf,start,length)=>length<16?shortDecoder(buf,start,length):length<32?midDecoder(buf,start,length):longDecoder(buf,start,length);exports.default=decoder}});var require_decodeUtf8=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/utf8/decodeUtf8/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.decodeUtf8=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports)),v16_1=tslib_1.__importDefault(require_v16());exports.decodeUtf8=v16_1.default}});var require_Reader=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/Reader.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Reader=void 0;var decodeUtf8_1=require_decodeUtf8(),Reader=class _Reader{constructor(uint8=new Uint8Array([]),view=new DataView(uint8.buffer,uint8.byteOffset,uint8.length),x2=0,end=uint8.length){this.uint8=uint8,this.view=view,this.x=x2,this.end=end}reset(uint8){this.x=0,this.uint8=uint8,this.view=new DataView(uint8.buffer,uint8.byteOffset,uint8.length)}size(){return this.end-this.x}peek(){return this.view.getUint8(this.x)}peak(){return this.peek()}skip(length){this.x+=length}buf(size=this.size()){let x2=this.x,end=x2+size,bin=this.uint8.subarray(x2,end);return this.x=end,bin}subarray(start=0,end){let x2=this.x,actualStart=x2+start,actualEnd=typeof end=="number"?x2+end:this.end;return this.uint8.subarray(actualStart,actualEnd)}slice(start=0,end){let x2=this.x,actualStart=x2+start,actualEnd=typeof end=="number"?x2+end:this.end;return new _Reader(this.uint8,this.view,actualStart,actualEnd)}cut(size=this.size()){let slice=this.slice(0,size);return this.skip(size),slice}u8(){return this.uint8[this.x++]}i8(){return this.view.getInt8(this.x++)}u16(){let x2=this.x,num3=(this.uint8[x2++]<<8)+this.uint8[x2++];return this.x=x2,num3}i16(){let num3=this.view.getInt16(this.x);return this.x+=2,num3}u32(){let num3=this.view.getUint32(this.x);return this.x+=4,num3}i32(){let num3=this.view.getInt32(this.x);return this.x+=4,num3}u64(){let num3=this.view.getBigUint64(this.x);return this.x+=8,num3}i64(){let num3=this.view.getBigInt64(this.x);return this.x+=8,num3}f32(){let pos=this.x;return this.x+=4,this.view.getFloat32(pos)}f64(){let pos=this.x;return this.x+=8,this.view.getFloat64(pos)}utf8(size){let start=this.x;return this.x+=size,(0,decodeUtf8_1.decodeUtf8)(this.uint8,start,size)}ascii(length){let uint8=this.uint8,str="",end=this.x+length;for(let i2=this.x;i2<end;i2++)str+=String.fromCharCode(uint8[i2]);return this.x=end,str}};exports.Reader=Reader}});var require_v10=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/utf8/decodeUtf8/v10.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});var fromCharCode=String.fromCharCode;exports.default=(buf,start,length)=>{let offset=start,end=offset+length,str="";for(;offset<end;){let octet1=buf[offset++];if((octet1&128)===0){str+=fromCharCode(octet1);continue}let octet2=buf[offset++]&63;if((octet1&224)===192){str+=fromCharCode((octet1&31)<<6|octet2);continue}let octet3=buf[offset++]&63;if((octet1&240)===224){str+=fromCharCode((octet1&31)<<12|octet2<<6|octet3);continue}if((octet1&248)===240){let octet4=buf[offset++]&63,unit=(octet1&7)<<18|octet2<<12|octet3<<6|octet4;if(unit>65535){unit-=65536;let unit0=unit>>>10&1023|55296;unit=56320|unit&1023,str+=fromCharCode(unit0,unit)}else str+=fromCharCode(unit)}else str+=fromCharCode(octet1)}return str}}});var require_CachedUtf8Decoder=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/utf8/CachedUtf8Decoder.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.CachedUtf8Decoder=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports)),v10_1=tslib_1.__importDefault(require_v10()),x2=1+Math.round(Math.random()*((-1>>>0)-1));function randomU32(min,max){return x2^=x2<<13,x2^=x2>>>17,x2^=x2<<5,(x2>>>0)%(max-min+1)+min}var CacheItem=class{constructor(bytes,value2){this.bytes=bytes,this.value=value2}},CachedUtf8Decoder=class{constructor(){this.caches=[];for(let i2=0;i2<31;i2++)this.caches.push([])}get(bytes,offset,size){let records=this.caches[size-1],len=records.length;FIND_CHUNK:for(let i2=0;i2<len;i2++){let record=records[i2],recordBytes=record.bytes;for(let j=0;j<size;j++)if(recordBytes[j]!==bytes[offset+j])continue FIND_CHUNK;return record.value}return null}store(bytes,value2){let records=this.caches[bytes.length-1],record=new CacheItem(bytes,value2);records.length>=16?records[randomU32(0,15)]=record:records.push(record)}decode(bytes,offset,size){if(!size)return"";let cachedValue=this.get(bytes,offset,size);if(cachedValue!==null)return cachedValue;let value2=(0,v10_1.default)(bytes,offset,size),copy=Uint8Array.prototype.slice.call(bytes,offset,offset+size);return this.store(copy,value2),value2}};exports.CachedUtf8Decoder=CachedUtf8Decoder}});var require_sharedCachedUtf8Decoder=__commonJS({"node_modules/.pnpm/@jsonjoy.com+buffers@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/buffers/lib/utf8/sharedCachedUtf8Decoder.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});var CachedUtf8Decoder_1=require_CachedUtf8Decoder();exports.default=new CachedUtf8Decoder_1.CachedUtf8Decoder}});var require_CborDecoderBase=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/cbor/CborDecoderBase.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.CborDecoderBase=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports)),f16_1=require_f16(),JsonPackExtension_1=require_JsonPackExtension(),JsonPackValue_1=require_JsonPackValue(),Reader_1=require_Reader(),sharedCachedUtf8Decoder_1=tslib_1.__importDefault(require_sharedCachedUtf8Decoder()),CborDecoderBase=class{constructor(reader=new Reader_1.Reader,keyDecoder=sharedCachedUtf8Decoder_1.default){this.reader=reader,this.keyDecoder=keyDecoder}read(uint8){return this.reader.reset(uint8),this.readAny()}decode(uint8){return this.reader.reset(uint8),this.readAny()}val(){return this.readAny()}readAny(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;return major<4?major<2?major===0?this.readUint(minor):this.readNint(minor):major===2?this.readBin(minor):this.readStr(minor):major<6?major===4?this.readArr(minor):this.readObj(minor):major===6?this.readTag(minor):this.readTkn(minor)}readAnyRaw(octet){let major=octet>>5,minor=octet&31;return major<4?major<2?major===0?this.readUint(minor):this.readNint(minor):major===2?this.readBin(minor):this.readStr(minor):major<6?major===4?this.readArr(minor):this.readObj(minor):major===6?this.readTag(minor):this.readTkn(minor)}readMinorLen(minor){if(minor<24)return minor;switch(minor){case 24:return this.reader.u8();case 25:return this.reader.u16();case 26:return this.reader.u32();case 27:return Number(this.reader.u64());case 31:return-1;default:throw 1}}readUint(minor){if(minor<25)return minor===24?this.reader.u8():minor;if(minor<27)return minor===25?this.reader.u16():this.reader.u32();{let num3=this.reader.u64();return num3>9007199254740991?num3:Number(num3)}}readNint(minor){if(minor<25)return minor===24?-this.reader.u8()-1:-minor-1;if(minor<27)return minor===25?-this.reader.u16()-1:-this.reader.u32()-1;{let num3=this.reader.u64();return num3>9007199254740991-1?-num3-BigInt(1):-Number(num3)-1}}readBin(minor){let reader=this.reader;if(minor<=23)return reader.buf(minor);switch(minor){case 24:return reader.buf(reader.u8());case 25:return reader.buf(reader.u16());case 26:return reader.buf(reader.u32());case 27:return reader.buf(Number(reader.u64()));case 31:{let size=0,list5=[];for(;this.reader.peak()!==255;){let uint8=this.readBinChunk();size+=uint8.length,list5.push(uint8)}this.reader.x++;let res=new Uint8Array(size),offset=0,length=list5.length;for(let i2=0;i2<length;i2++){let arr=list5[i2];res.set(arr,offset),offset+=arr.length}return res}default:throw 1}}readBinChunk(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;if(major!==2)throw 2;if(minor>27)throw 3;return this.readBin(minor)}readAsStr(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;if(major!==3)throw 11;return this.readStr(minor)}readStr(minor){let reader=this.reader;if(minor<=23)return reader.utf8(minor);switch(minor){case 24:return reader.utf8(reader.u8());case 25:return reader.utf8(reader.u16());case 26:return reader.utf8(reader.u32());case 27:return reader.utf8(Number(reader.u64()));case 31:{let str="";for(;reader.peak()!==255;)str+=this.readStrChunk();return this.reader.x++,str}default:throw 1}}readStrLen(minor){if(minor<=23)return minor;switch(minor){case 24:return this.reader.u8();case 25:return this.reader.u16();case 26:return this.reader.u32();case 27:return Number(this.reader.u64());default:throw 1}}readStrChunk(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;if(major!==3)throw 4;if(minor>27)throw 5;return this.readStr(minor)}readArr(minor){let length=this.readMinorLen(minor);return length>=0?this.readArrRaw(length):this.readArrIndef()}readArrRaw(length){let arr=[];for(let i2=0;i2<length;i2++)arr.push(this.readAny());return arr}readArrIndef(){let arr=[];for(;this.reader.peak()!==255;)arr.push(this.readAny());return this.reader.x++,arr}readObj(minor){if(minor<28){let length=minor;switch(minor){case 24:length=this.reader.u8();break;case 25:length=this.reader.u16();break;case 26:length=this.reader.u32();break;case 27:length=Number(this.reader.u64());break}let obj={};for(let i2=0;i2<length;i2++){let key=this.key();if(key==="__proto__")throw 6;let value2=this.readAny();obj[key]=value2}return obj}else{if(minor===31)return this.readObjIndef();throw 1}}readObjRaw(length){let obj={};for(let i2=0;i2<length;i2++){let key=this.key(),value2=this.readAny();obj[key]=value2}return obj}readObjIndef(){let obj={};for(;this.reader.peak()!==255;){let key=this.key();if(this.reader.peak()===255)throw 7;let value2=this.readAny();obj[key]=value2}return this.reader.x++,obj}key(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;if(major!==3)return String(this.readAnyRaw(octet));let length=this.readStrLen(minor);if(length>31)return this.reader.utf8(length);let key=this.keyDecoder.decode(this.reader.uint8,this.reader.x,length);return this.reader.skip(length),key}readTag(minor){if(minor<=23)return this.readTagRaw(minor);switch(minor){case 24:return this.readTagRaw(this.reader.u8());case 25:return this.readTagRaw(this.reader.u16());case 26:return this.readTagRaw(this.reader.u32());case 27:return this.readTagRaw(Number(this.reader.u64()));default:throw 1}}readTagRaw(tag2){return new JsonPackExtension_1.JsonPackExtension(tag2,this.readAny())}readTkn(minor){switch(minor){case 20:return!1;case 21:return!0;case 22:return null;case 23:return;case 24:return new JsonPackValue_1.JsonPackValue(this.reader.u8());case 25:return this.f16();case 26:return this.reader.f32();case 27:return this.reader.f64()}if(minor<=23)return new JsonPackValue_1.JsonPackValue(minor);throw 1}f16(){return(0,f16_1.decodeF16)(this.reader.u16())}};exports.CborDecoderBase=CborDecoderBase}});var require_CborDecoder=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/cbor/CborDecoder.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.CborDecoder=void 0;var CborDecoderBase_1=require_CborDecoderBase(),JsonPackValue_1=require_JsonPackValue(),CborDecoder=class extends CborDecoderBase_1.CborDecoderBase{readAsMap(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;if(major===5)return this.readMap(minor);throw 0}readMap(minor){let length=this.readMinorLen(minor);return length>=0?this.readMapRaw(length):this.readMapIndef()}readMapRaw(length){let map5=new Map;for(let i2=0;i2<length;i2++){let key=this.readAny(),value2=this.readAny();map5.set(key,value2)}return map5}readMapIndef(){let map5=new Map;for(;this.reader.peak()!==255;){let key=this.readAny();if(this.reader.peak()===255)throw 7;let value2=this.readAny();map5.set(key,value2)}return this.reader.x++,map5}skipN(n2){for(let i2=0;i2<n2;i2++)this.skipAny()}skipAny(){this.skipAnyRaw(this.reader.u8())}skipAnyRaw(octet){let major=octet>>5,minor=octet&31;switch(major){case 0:case 1:this.skipUNint(minor);break;case 2:this.skipBin(minor);break;case 3:this.skipStr(minor);break;case 4:this.skipArr(minor);break;case 5:this.skipObj(minor);break;case 7:this.skipTkn(minor);break;case 6:this.skipTag(minor);break}}skipMinorLen(minor){if(minor<=23)return minor;switch(minor){case 24:return this.reader.u8();case 25:return this.reader.u16();case 26:return this.reader.u32();case 27:return Number(this.reader.u64());case 31:return-1;default:throw 1}}skipUNint(minor){if(!(minor<=23))switch(minor){case 24:return this.reader.skip(1);case 25:return this.reader.skip(2);case 26:return this.reader.skip(4);case 27:return this.reader.skip(8);default:throw 1}}skipBin(minor){let length=this.skipMinorLen(minor);if(length>=0)this.reader.skip(length);else{for(;this.reader.peak()!==255;)this.skipBinChunk();this.reader.x++}}skipBinChunk(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;if(major!==2)throw 2;if(minor>27)throw 3;this.skipBin(minor)}skipStr(minor){let length=this.skipMinorLen(minor);if(length>=0)this.reader.skip(length);else{for(;this.reader.peak()!==255;)this.skipStrChunk();this.reader.x++}}skipStrChunk(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;if(major!==3)throw 4;if(minor>27)throw 5;this.skipStr(minor)}skipArr(minor){let length=this.skipMinorLen(minor);if(length>=0)this.skipN(length);else{for(;this.reader.peak()!==255;)this.skipAny();this.reader.x++}}skipObj(minor){let length=this.readMinorLen(minor);if(length>=0)return this.skipN(length*2);for(;this.reader.peak()!==255;){if(this.skipAny(),this.reader.peak()===255)throw 7;this.skipAny()}this.reader.x++}skipTag(minor){if(this.skipMinorLen(minor)<0)throw 1;this.skipAny()}skipTkn(minor){switch(minor){case 24:this.reader.skip(1);return;case 25:this.reader.skip(2);return;case 26:this.reader.skip(4);return;case 27:this.reader.skip(8);return}if(!(minor<=23))throw 1}validate(value2,offset=0,size=value2.length){this.reader.reset(value2),this.reader.x=offset;let start=offset;if(this.skipAny(),this.reader.x-start!==size)throw 8}decodeLevel(value2){return this.reader.reset(value2),this.readLevel()}readLevel(){let octet=this.reader.u8(),major=octet>>5,minor=octet&31;switch(major){case 4:return this.readArrLevel(minor);case 5:return this.readObjLevel(minor);default:return super.readAnyRaw(octet)}}readPrimitiveOrVal(){switch(this.reader.peak()>>5){case 4:case 5:return this.readAsValue();default:return this.readAny()}}readAsValue(){let reader=this.reader,start=reader.x;this.skipAny();let end=reader.x;return new JsonPackValue_1.JsonPackValue(reader.uint8.subarray(start,end))}readObjLevel(minor){let length=this.readMinorLen(minor);return length>=0?this.readObjRawLevel(length):this.readObjIndefLevel()}readObjRawLevel(length){let obj={};for(let i2=0;i2<length;i2++){let key=this.key(),value2=this.readPrimitiveOrVal();obj[key]=value2}return obj}readObjIndefLevel(){let obj={};for(;this.reader.peak()!==255;){let key=this.key();if(this.reader.peak()===255)throw 7;let value2=this.readPrimitiveOrVal();obj[key]=value2}return this.reader.x++,obj}readArrLevel(minor){let length=this.readMinorLen(minor);return length>=0?this.readArrRawLevel(length):this.readArrIndefLevel()}readArrRawLevel(length){let arr=[];for(let i2=0;i2<length;i2++)arr.push(this.readPrimitiveOrVal());return arr}readArrIndefLevel(){let arr=[];for(;this.reader.peak()!==255;)arr.push(this.readPrimitiveOrVal());return this.reader.x++,arr}readHdr(expectedMajor){let octet=this.reader.u8();if(octet>>5!==expectedMajor)throw 0;let minor=octet&31;if(minor<24)return minor;switch(minor){case 24:return this.reader.u8();case 25:return this.reader.u16();case 26:return this.reader.u32();case 27:return Number(this.reader.u64());case 31:return-1}throw 1}readStrHdr(){return this.readHdr(3)}readObjHdr(){return this.readHdr(5)}readArrHdr(){return this.readHdr(4)}findKey(key){let size=this.readObjHdr();for(let i2=0;i2<size;i2++){if(this.key()===key)return this;this.skipAny()}throw 9}findIndex(index4){let size=this.readArrHdr();if(index4>=size)throw 10;for(let i2=0;i2<index4;i2++)this.skipAny();return this}find(path4){for(let i2=0;i2<path4.length;i2++){let segment=path4[i2];typeof segment=="string"?this.findKey(segment):this.findIndex(segment)}return this}};exports.CborDecoder=CborDecoder}});var require_async=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/async.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fromSnapshot=exports.toSnapshot=void 0;var shared_1=require_shared(),toSnapshot=async({fs:fs2,path:path4="/",separator="/"})=>{let stats=await fs2.lstat(path4);if(stats.isDirectory()){let list5=await fs2.readdir(path4),entries={},dir=path4.endsWith(separator)?path4:path4+separator,snapshots=await Promise.all(list5.map(child=>(0,exports.toSnapshot)({fs:fs2,path:`${dir}${child}`,separator})));for(let i2=0;i2<list5.length;i2++)snapshots[i2]&&(entries[""+list5[i2]]=snapshots[i2]);return[0,{},entries]}else if(stats.isFile()){let buf=await fs2.readFile(path4),uint8=new Uint8Array(buf.buffer,buf.byteOffset,buf.byteLength);return[1,{},uint8]}else if(stats.isSymbolicLink())return[2,{target:await fs2.readlink(path4,{encoding:"utf8"})}];return null};exports.toSnapshot=toSnapshot;var fromSnapshot=async(snapshot,{fs:fs2,path:path4="/",separator="/"})=>{if(snapshot)switch(snapshot[0]){case 0:{path4.endsWith(separator)||(path4=path4+separator);let[,,entries]=snapshot;await fs2.mkdir(path4,{recursive:!0});for(let[name,child]of Object.entries(entries))(0,shared_1.validateEntryName)(name),await(0,exports.fromSnapshot)(child,{fs:fs2,path:`${path4}${name}`,separator});break}case 1:{let[,,data]=snapshot;await fs2.writeFile(path4,data);break}case 2:{let[,{target}]=snapshot;await fs2.symlink(target,path4);break}}};exports.fromSnapshot=fromSnapshot}});var require_binary=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/binary.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fromBinarySnapshot=exports.toBinarySnapshot=exports.fromBinarySnapshotSync=exports.toBinarySnapshotSync=void 0;var CborEncoder_1=require_CborEncoder(),CborDecoder_1=require_CborDecoder(),sync_1=require_sync(),async_1=require_async(),shared_1=require_shared(),encoder=new CborEncoder_1.CborEncoder(shared_1.writer),decoder=new CborDecoder_1.CborDecoder,toBinarySnapshotSync=options2=>{let snapshot=(0,sync_1.toSnapshotSync)(options2);return encoder.encode(snapshot)};exports.toBinarySnapshotSync=toBinarySnapshotSync;var fromBinarySnapshotSync=(uint8,options2)=>{let snapshot=decoder.decode(uint8);(0,sync_1.fromSnapshotSync)(snapshot,options2)};exports.fromBinarySnapshotSync=fromBinarySnapshotSync;var toBinarySnapshot=async options2=>{let snapshot=await(0,async_1.toSnapshot)(options2);return encoder.encode(snapshot)};exports.toBinarySnapshot=toBinarySnapshot;var fromBinarySnapshot=async(uint8,options2)=>{let snapshot=decoder.decode(uint8);await(0,async_1.fromSnapshot)(snapshot,options2)};exports.fromBinarySnapshot=fromBinarySnapshot}});var require_constants5=__commonJS({"node_modules/.pnpm/@jsonjoy.com+base64@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/base64/lib/constants.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.hasBuffer=exports.alphabet=void 0;exports.alphabet="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";exports.hasBuffer=typeof import_buffer.Buffer=="function"&&typeof import_buffer.Buffer.from=="function"}});var require_createToBase64Bin=__commonJS({"node_modules/.pnpm/@jsonjoy.com+base64@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/base64/lib/createToBase64Bin.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.createToBase64Bin=void 0;var constants_1=require_constants5(),createToBase64Bin=(chars=constants_1.alphabet,pad="=")=>{if(chars.length!==64)throw new Error("chars must be 64 characters long");let table=chars.split("").map(c2=>c2.charCodeAt(0)),table2=[];for(let c1 of table)for(let c2 of table){let two=(c1<<8)+c2;table2.push(two)}let doAddPadding=pad.length===1,E=doAddPadding?pad.charCodeAt(0):0,EE=doAddPadding?E<<8|E:0;return(uint8,start,length,dest,offset)=>{let extraLength=length%3,baseLength=length-extraLength;for(;start<baseLength;start+=3){let o1=uint8[start],o2=uint8[start+1],o3=uint8[start+2],v1=o1<<4|o2>>4,v2=(o2&15)<<8|o3;dest.setInt32(offset,(table2[v1]<<16)+table2[v2]),offset+=4}if(extraLength===1){let o1=uint8[baseLength];doAddPadding?(dest.setInt32(offset,(table2[o1<<4]<<16)+EE),offset+=4):(dest.setInt16(offset,table2[o1<<4]),offset+=2)}else if(extraLength){let o1=uint8[baseLength],o2=uint8[baseLength+1],v1=o1<<4|o2>>4,v2=(o2&15)<<2;doAddPadding?(dest.setInt32(offset,(table2[v1]<<16)+(table[v2]<<8)+E),offset+=4):(dest.setInt16(offset,table2[v1]),offset+=2,dest.setInt8(offset,table[v2]),offset+=1)}return offset}};exports.createToBase64Bin=createToBase64Bin}});var require_toBase64Bin=__commonJS({"node_modules/.pnpm/@jsonjoy.com+base64@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/base64/lib/toBase64Bin.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.toBase64Bin=void 0;var createToBase64Bin_1=require_createToBase64Bin();exports.toBase64Bin=(0,createToBase64Bin_1.createToBase64Bin)()}});var require_JsonEncoder=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/json/JsonEncoder.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.JsonEncoder=void 0;var toBase64Bin_1=require_toBase64Bin(),JsonEncoder=class{constructor(writer){this.writer=writer}encode(value2){let writer=this.writer;return writer.reset(),this.writeAny(value2),writer.flush()}writeUnknown(value2){this.writeNull()}writeAny(value2){switch(typeof value2){case"boolean":return this.writeBoolean(value2);case"number":return this.writeNumber(value2);case"string":return this.writeStr(value2);case"object":{if(value2===null)return this.writeNull();switch(value2.constructor){case Object:return this.writeObj(value2);case Array:return this.writeArr(value2);case Uint8Array:return this.writeBin(value2);default:return value2 instanceof Uint8Array?this.writeBin(value2):Array.isArray(value2)?this.writeArr(value2):this.writeUnknown(value2)}}case"undefined":return this.writeUndef();default:return this.writeUnknown(value2)}}writeNull(){this.writer.u32(1853189228)}writeUndef(){let writer=this.writer;writer.ensureCapacity(35);let view=writer.view,x2=writer.x;view.setUint32(x2,577003892),x2+=4,view.setUint32(x2,1631215984),x2+=4,view.setUint32(x2,1886153059),x2+=4,view.setUint32(x2,1635019119),x2+=4,view.setUint32(x2,1848599394),x2+=4,view.setUint32(x2,1869753442),x2+=4,view.setUint32(x2,1634952502),x2+=4,view.setUint32(x2,876296567),x2+=4,view.setUint16(x2,15677),x2+=2,writer.uint8[x2++]=34,writer.x=x2}writeBoolean(bool2){bool2?this.writer.u32(1953658213):this.writer.u8u32(102,1634497381)}writeNumber(num3){let str=num3.toString();this.writer.ascii(str)}writeInteger(int3){this.writeNumber(int3>>0===int3?int3:Math.trunc(int3))}writeUInteger(uint){this.writeInteger(uint<0?-uint:uint)}writeFloat(float3){this.writeNumber(float3)}writeBin(buf){let writer=this.writer,length=buf.length;writer.ensureCapacity(41+(length<<1));let view=writer.view,x2=writer.x;view.setUint32(x2,577003892),x2+=4,view.setUint32(x2,1631215984),x2+=4,view.setUint32(x2,1886153059),x2+=4,view.setUint32(x2,1635019119),x2+=4,view.setUint32(x2,1848602467),x2+=4,view.setUint32(x2,1952805933),x2+=4,view.setUint32(x2,1937011301),x2+=4,view.setUint32(x2,1634548578),x2+=4,view.setUint32(x2,1634952502),x2+=4,view.setUint16(x2,13356),x2+=2,x2=(0,toBase64Bin_1.toBase64Bin)(buf,0,length,view,x2),writer.uint8[x2++]=34,writer.x=x2}writeStr(str){let writer=this.writer,length=str.length;if(writer.ensureCapacity(length*4+2),length<256){let startX=writer.x,x2=startX,uint8=writer.uint8;uint8[x2++]=34;for(let i2=0;i2<length;i2++){let code4=str.charCodeAt(i2);switch(code4){case 34:case 92:uint8[x2++]=92;break}if(code4<32||code4>126){writer.x=startX;let jsonStr2=JSON.stringify(str);writer.ensureCapacity(jsonStr2.length*4+4),writer.utf8(jsonStr2);return}else uint8[x2++]=code4}uint8[x2++]=34,writer.x=x2;return}let jsonStr=JSON.stringify(str);writer.ensureCapacity(jsonStr.length*4+4),writer.utf8(jsonStr)}writeAsciiStr(str){let length=str.length,writer=this.writer;writer.ensureCapacity(length*2+2);let uint8=writer.uint8,x2=writer.x;uint8[x2++]=34;for(let i2=0;i2<length;i2++){let code4=str.charCodeAt(i2);switch(code4){case 34:case 92:uint8[x2++]=92;break}uint8[x2++]=code4}uint8[x2++]=34,writer.x=x2}writeArr(arr){let writer=this.writer;writer.u8(91);let last=arr.length-1;for(let i2=0;i2<last;i2++)this.writeAny(arr[i2]),writer.u8(44);last>=0&&this.writeAny(arr[last]),writer.u8(93)}writeArrSeparator(){this.writer.u8(44)}writeObj(obj){let writer=this.writer,keys=Object.keys(obj),length=keys.length;if(!length)return writer.u16(31613);writer.u8(123);for(let i2=0;i2<length;i2++){let key=keys[i2],value2=obj[key];this.writeStr(key),writer.u8(58),this.writeAny(value2),writer.u8(44)}writer.uint8[writer.x-1]=125}writeObjSeparator(){this.writer.u8(44)}writeObjKeySeparator(){this.writer.u8(58)}writeStartStr(){throw new Error("Method not implemented.")}writeStrChunk(str){throw new Error("Method not implemented.")}writeEndStr(){throw new Error("Method not implemented.")}writeStartBin(){throw new Error("Method not implemented.")}writeBinChunk(buf){throw new Error("Method not implemented.")}writeEndBin(){throw new Error("Method not implemented.")}writeStartArr(){this.writer.u8(91)}writeArrChunk(item){throw new Error("Method not implemented.")}writeEndArr(){this.writer.u8(93)}writeStartObj(){this.writer.u8(123)}writeObjChunk(key,value2){throw new Error("Method not implemented.")}writeEndObj(){this.writer.u8(125)}};exports.JsonEncoder=JsonEncoder}});var require_createFromBase64Bin=__commonJS({"node_modules/.pnpm/@jsonjoy.com+base64@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/base64/lib/createFromBase64Bin.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.createFromBase64Bin=void 0;var constants_1=require_constants5(),createFromBase64Bin=(chars=constants_1.alphabet,pad="=")=>{if(chars.length!==64)throw new Error("chars must be 64 characters long");let max=0;for(let i2=0;i2<chars.length;i2++)max=Math.max(max,chars.charCodeAt(i2));let table=[];for(let i2=0;i2<=max;i2+=1)table[i2]=-1;for(let i2=0;i2<chars.length;i2++)table[chars.charCodeAt(i2)]=i2;let PAD=pad.length===1?pad.charCodeAt(0):0;return(view,offset,length)=>{if(!length)return new Uint8Array(0);let padding=0;if(length%4!==0)padding=4-length%4,length+=padding;else{let last=offset+length-1;view.getUint8(last)===PAD&&(padding=1,length>1&&view.getUint8(last-1)===PAD&&(padding=2))}if(length%4!==0)throw new Error("Base64 string length must be a multiple of 4");let mainEnd=offset+length-(padding?4:0),bufferLength=(length>>2)*3-padding,buf=new Uint8Array(bufferLength),j=0,i2=offset;for(;i2<mainEnd;i2+=4){let word2=view.getUint32(i2),octet02=word2>>>24,octet12=word2>>>16&255,octet2=word2>>>8&255,octet3=word2&255,sextet02=table[octet02],sextet12=table[octet12],sextet2=table[octet2],sextet3=table[octet3];if(sextet02<0||sextet12<0||sextet2<0||sextet3<0)throw new Error("INVALID_BASE64_SEQ");buf[j]=sextet02<<2|sextet12>>4,buf[j+1]=sextet12<<4|sextet2>>2,buf[j+2]=sextet2<<6|sextet3,j+=3}if(!padding)return buf;if(padding===1){let word2=view.getUint16(mainEnd),octet02=word2>>8,octet12=word2&255,octet2=view.getUint8(mainEnd+2),sextet02=table[octet02],sextet12=table[octet12],sextet2=table[octet2];if(sextet02<0||sextet12<0||sextet2<0)throw new Error("INVALID_BASE64_SEQ");return buf[j]=sextet02<<2|sextet12>>4,buf[j+1]=sextet12<<4|sextet2>>2,buf}let word=view.getUint16(mainEnd),octet0=word>>8,octet1=word&255,sextet0=table[octet0],sextet1=table[octet1];if(sextet0<0||sextet1<0)throw new Error("INVALID_BASE64_SEQ");return buf[j]=sextet0<<2|sextet1>>4,buf}};exports.createFromBase64Bin=createFromBase64Bin}});var require_fromBase64Bin=__commonJS({"node_modules/.pnpm/@jsonjoy.com+base64@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/base64/lib/fromBase64Bin.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fromBase64Bin=void 0;var createFromBase64Bin_1=require_createFromBase64Bin();exports.fromBase64Bin=(0,createFromBase64Bin_1.createFromBase64Bin)()}});var require_util5=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/json/util.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.findEndingQuote=void 0;var findEndingQuote=(uint8,x2)=>{let len=uint8.length,char=uint8[x2],prev=0;for(;x2<len&&!(char===34&&prev!==92);)char===92&&prev===92?prev=0:prev=char,char=uint8[++x2];if(x2===len)throw new Error("Invalid JSON");return x2};exports.findEndingQuote=findEndingQuote}});var require_JsonDecoder=__commonJS({"node_modules/.pnpm/@jsonjoy.com+json-pack@17.67.0_tslib@2.9.1/node_modules/@jsonjoy.com/json-pack/lib/json/JsonDecoder.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.JsonDecoder=exports.readKey=void 0;var decodeUtf8_1=require_decodeUtf8(),Reader_1=require_Reader(),fromBase64Bin_1=require_fromBase64Bin(),util_1=require_util5(),REGEX_REPLACE_ESCAPED_CHARS=/\\(b|f|n|r|t|"|\/|\\)/g,escapedCharReplacer=char=>{switch(char){case"\\b":return"\b";case"\\f":return"\f";case"\\n":return`
|
|
48
|
-
`;case"\\r":return"\r";case"\\t":return" ";case'\\"':return'"';case"\\/":return"/";case"\\\\":return"\\"}return char},hasBinaryPrefix=(u8,x2)=>u8[x2]===100&&u8[x2+1]===97&&u8[x2+2]===116&&u8[x2+3]===97&&u8[x2+4]===58&&u8[x2+5]===97&&u8[x2+6]===112&&u8[x2+7]===112&&u8[x2+8]===108&&u8[x2+9]===105&&u8[x2+10]===99&&u8[x2+11]===97&&u8[x2+12]===116&&u8[x2+13]===105&&u8[x2+14]===111&&u8[x2+15]===110&&u8[x2+16]===47&&u8[x2+17]===111&&u8[x2+18]===99&&u8[x2+19]===116&&u8[x2+20]===101&&u8[x2+21]===116&&u8[x2+22]===45&&u8[x2+23]===115&&u8[x2+24]===116&&u8[x2+25]===114&&u8[x2+26]===101&&u8[x2+27]===97&&u8[x2+28]===109&&u8[x2+29]===59&&u8[x2+30]===98&&u8[x2+31]===97&&u8[x2+32]===115&&u8[x2+33]===101&&u8[x2+34]===54&&u8[x2+35]===52&&u8[x2+36]===44,isUndefined=(u8,x2)=>u8[x2++]===97&&u8[x2++]===116&&u8[x2++]===97&&u8[x2++]===58&&u8[x2++]===97&&u8[x2++]===112&&u8[x2++]===112&&u8[x2++]===108&&u8[x2++]===105&&u8[x2++]===99&&u8[x2++]===97&&u8[x2++]===116&&u8[x2++]===105&&u8[x2++]===111&&u8[x2++]===110&&u8[x2++]===47&&u8[x2++]===99&&u8[x2++]===98&&u8[x2++]===111&&u8[x2++]===114&&u8[x2++]===44&&u8[x2++]===98&&u8[x2++]===97&&u8[x2++]===115&&u8[x2++]===101&&u8[x2++]===54&&u8[x2++]===52&&u8[x2++]===59&&u8[x2++]===57&&u8[x2++]===119&&u8[x2++]===61&&u8[x2++]===61&&u8[x2++]===34,fromCharCode=String.fromCharCode,readKey=reader=>{let buf=reader.uint8,len=buf.length,points=[],x2=reader.x,prev=0;for(;x2<len;){let code4=buf[x2++];if((code4&128)===0)if(prev===92){switch(code4){case 98:code4=8;break;case 102:code4=12;break;case 110:code4=10;break;case 114:code4=13;break;case 116:code4=9;break;case 34:code4=34;break;case 47:code4=47;break;case 92:code4=92;break;default:throw new Error("Invalid JSON")}prev=0}else{if(code4===34)break;if(prev=code4,prev===92)continue}else{let octet2=buf[x2++]&63;if((code4&224)===192)code4=(code4&31)<<6|octet2;else{let octet3=buf[x2++]&63;if((code4&240)===224)code4=(code4&31)<<12|octet2<<6|octet3;else if((code4&248)===240){let octet4=buf[x2++]&63,unit=(code4&7)<<18|octet2<<12|octet3<<6|octet4;if(unit>65535){unit-=65536;let unit0=unit>>>10&1023|55296;unit=56320|unit&1023,points.push(unit0),code4=unit}else code4=unit}}}points.push(code4)}return reader.x=x2,fromCharCode.apply(String,points)};exports.readKey=readKey;var JsonDecoder=class{constructor(){this.reader=new Reader_1.Reader}read(uint8){return this.reader.reset(uint8),this.readAny()}decode(uint8){return this.reader.reset(uint8),this.readAny()}readAny(){this.skipWhitespace();let reader=this.reader,x2=reader.x,uint8=reader.uint8,char=uint8[x2];switch(char){case 34:{if(uint8[x2+1]===100){let bin=this.tryReadBin();if(bin)return bin;if(isUndefined(uint8,x2+2)){reader.x=x2+35;return}}return this.readStr()}case 91:return this.readArr();case 102:return this.readFalse();case 110:return this.readNull();case 116:return this.readTrue();case 123:return this.readObj();default:if(char>=48&&char<=57||char===45)return this.readNum();throw new Error("Invalid JSON")}}skipWhitespace(){let reader=this.reader,uint8=reader.uint8,x2=reader.x,char=0;for(;;)switch(char=uint8[x2],char){case 32:case 9:case 10:case 13:x2++;continue;default:reader.x=x2;return}}readNull(){if(this.reader.u32()!==1853189228)throw new Error("Invalid JSON");return null}readTrue(){if(this.reader.u32()!==1953658213)throw new Error("Invalid JSON");return!0}readFalse(){let reader=this.reader;if(reader.u8()!==102||reader.u32()!==1634497381)throw new Error("Invalid JSON");return!1}readBool(){let reader=this.reader;switch(reader.uint8[reader.x]){case 102:return this.readFalse();case 116:return this.readTrue();default:throw new Error("Invalid JSON")}}readNum(){let reader=this.reader,uint8=reader.uint8,x2=reader.x,c2=uint8[x2++],c1=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c22=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c3=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c4=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c5=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c6=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c7=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c8=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c9=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c10=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c11=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c12=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c13=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c14=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c15=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c16=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c17=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c18=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c19=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c20=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c21=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c222=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21,c222);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c23=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21,c222,c23);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c24=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21,c222,c23,c24);if(num3!==num3)throw new Error("Invalid JSON");return num3}throw new Error("Invalid JSON")}readStr(){let reader=this.reader,uint8=reader.uint8;if(uint8[reader.x++]!==34)throw new Error("Invalid JSON");let x0=reader.x,x1=(0,util_1.findEndingQuote)(uint8,x0),str=(0,decodeUtf8_1.decodeUtf8)(uint8,x0,x1-x0);return str=str.replace(REGEX_REPLACE_ESCAPED_CHARS,escapedCharReplacer),reader.x=x1+1,str}tryReadBin(){let reader=this.reader,u8=reader.uint8,x2=reader.x;if(u8[x2++]!==34||!hasBinaryPrefix(u8,x2))return;x2+=37;let x0=x2;x2=(0,util_1.findEndingQuote)(u8,x2),reader.x=x0;let bin=(0,fromBase64Bin_1.fromBase64Bin)(reader.view,x0,x2-x0);return reader.x=x2+1,bin}readBin(){let reader=this.reader,u8=reader.uint8,x2=reader.x;if(u8[x2++]!==34)throw new Error("Invalid JSON");if(!hasBinaryPrefix(u8,x2))throw new Error("Invalid JSON");x2+=37;let x0=x2;x2=(0,util_1.findEndingQuote)(u8,x2),reader.x=x0;let bin=(0,fromBase64Bin_1.fromBase64Bin)(reader.view,x0,x2-x0);return reader.x=x2+1,bin}readArr(){let reader=this.reader;if(reader.u8()!==91)throw new Error("Invalid JSON");let arr=[],uint8=reader.uint8,first=!0;for(;;){this.skipWhitespace();let char=uint8[reader.x];if(char===93)return reader.x++,arr;if(char===44)reader.x++;else if(!first)throw new Error("Invalid JSON");this.skipWhitespace(),arr.push(this.readAny()),first=!1}}readObj(){let reader=this.reader;if(reader.u8()!==123)throw new Error("Invalid JSON");let obj={},uint8=reader.uint8,first=!0;for(;;){this.skipWhitespace();let char=uint8[reader.x];if(char===125)return reader.x++,obj;if(char===44)reader.x++;else if(!first)throw new Error("Invalid JSON");if(this.skipWhitespace(),char=uint8[reader.x++],char!==34)throw new Error("Invalid JSON");let key=(0,exports.readKey)(reader);if(key==="__proto__")throw new Error("Invalid JSON");if(this.skipWhitespace(),reader.u8()!==58)throw new Error("Invalid JSON");this.skipWhitespace(),obj[key]=this.readAny(),first=!1}}};exports.JsonDecoder=JsonDecoder}});var require_json2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/json.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fromJsonSnapshot=exports.toJsonSnapshot=exports.fromJsonSnapshotSync=exports.toJsonSnapshotSync=void 0;var JsonEncoder_1=require_JsonEncoder(),JsonDecoder_1=require_JsonDecoder(),sync_1=require_sync(),async_1=require_async(),shared_1=require_shared(),encoder=new JsonEncoder_1.JsonEncoder(shared_1.writer),decoder=new JsonDecoder_1.JsonDecoder,toJsonSnapshotSync=options2=>{let snapshot=(0,sync_1.toSnapshotSync)(options2);return encoder.encode(snapshot)};exports.toJsonSnapshotSync=toJsonSnapshotSync;var fromJsonSnapshotSync=(uint8,options2)=>{let snapshot=decoder.read(uint8);(0,sync_1.fromSnapshotSync)(snapshot,options2)};exports.fromJsonSnapshotSync=fromJsonSnapshotSync;var toJsonSnapshot=async options2=>{let snapshot=await(0,async_1.toSnapshot)(options2);return encoder.encode(snapshot)};exports.toJsonSnapshot=toJsonSnapshot;var fromJsonSnapshot=async(uint8,options2)=>{let snapshot=decoder.read(uint8);await(0,async_1.fromSnapshot)(snapshot,options2)};exports.fromJsonSnapshot=fromJsonSnapshot}});var require_lib9=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports));tslib_1.__exportStar(require_constants4(),exports);tslib_1.__exportStar(require_sync(),exports);tslib_1.__exportStar(require_binary(),exports);tslib_1.__exportStar(require_json2(),exports)}});var require_options=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/options.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.getWriteFileOptions=exports.writeFileDefaults=exports.getRealpathOptsAndCb=exports.getRealpathOptions=exports.getStatfsOptsAndCb=exports.getStatfsOptions=exports.getStatOptsAndCb=exports.getStatOptions=exports.getAppendFileOptsAndCb=exports.getAppendFileOpts=exports.getOpendirOptsAndCb=exports.getOpendirOptions=exports.getReaddirOptsAndCb=exports.getReaddirOptions=exports.getReadFileOptions=exports.getRmOptsAndCb=exports.getRmdirOptions=exports.getDefaultOptsAndCb=exports.getDefaultOpts=exports.optsDefaults=exports.getMkdirOptions=void 0;exports.getOptions=getOptions;exports.optsGenerator=optsGenerator;exports.optsAndCbGenerator=optsAndCbGenerator;var fs_node_utils_1=require_lib5(),util_1=require_util2(),mkdirDefaults={mode:511,recursive:!1},getMkdirOptions=options2=>typeof options2=="number"?Object.assign({},mkdirDefaults,{mode:options2}):Object.assign({},mkdirDefaults,options2);exports.getMkdirOptions=getMkdirOptions;var ERRSTR_OPTS=tipeof=>`Expected options to be either an object or a string, but got ${tipeof} instead`;function getOptions(defaults,options2){let opts;if(options2){let tipeof=typeof options2;switch(tipeof){case"string":opts=Object.assign({},defaults,{encoding:options2});break;case"object":opts=Object.assign({},defaults,options2);break;default:throw TypeError(ERRSTR_OPTS(tipeof))}}else return defaults;return opts.encoding!=="buffer"&&(0,fs_node_utils_1.assertEncoding)(opts.encoding),opts}function optsGenerator(defaults){return options2=>getOptions(defaults,options2)}function optsAndCbGenerator(getOpts){return(options2,callback)=>typeof options2=="function"?[getOpts(),options2]:[getOpts(options2),(0,util_1.validateCallback)(callback)]}exports.optsDefaults={encoding:"utf8"};exports.getDefaultOpts=optsGenerator(exports.optsDefaults);exports.getDefaultOptsAndCb=optsAndCbGenerator(exports.getDefaultOpts);var rmdirDefaults={recursive:!1},getRmdirOptions=options2=>Object.assign({},rmdirDefaults,options2);exports.getRmdirOptions=getRmdirOptions;var getRmOpts=optsGenerator(exports.optsDefaults);exports.getRmOptsAndCb=optsAndCbGenerator(getRmOpts);var readFileOptsDefaults={flag:"r"};exports.getReadFileOptions=optsGenerator(readFileOptsDefaults);var readdirDefaults={encoding:"utf8",recursive:!1,withFileTypes:!1};exports.getReaddirOptions=optsGenerator(readdirDefaults);exports.getReaddirOptsAndCb=optsAndCbGenerator(exports.getReaddirOptions);var opendirDefaults={encoding:"utf8",bufferSize:32,recursive:!1};exports.getOpendirOptions=optsGenerator(opendirDefaults);exports.getOpendirOptsAndCb=optsAndCbGenerator(exports.getOpendirOptions);var appendFileDefaults={encoding:"utf8",mode:438,flag:fs_node_utils_1.FLAGS[fs_node_utils_1.FLAGS.a]};exports.getAppendFileOpts=optsGenerator(appendFileDefaults);exports.getAppendFileOptsAndCb=optsAndCbGenerator(exports.getAppendFileOpts);var statDefaults={bigint:!1},getStatOptions=(options2={})=>Object.assign({},statDefaults,options2);exports.getStatOptions=getStatOptions;var getStatOptsAndCb=(options2,callback)=>typeof options2=="function"?[(0,exports.getStatOptions)(),options2]:[(0,exports.getStatOptions)(options2),(0,util_1.validateCallback)(callback)];exports.getStatOptsAndCb=getStatOptsAndCb;var statfsDefaults={bigint:!1},getStatfsOptions=(options2={})=>Object.assign({},statfsDefaults,options2);exports.getStatfsOptions=getStatfsOptions;var getStatfsOptsAndCb=(options2,callback)=>typeof options2=="function"?[(0,exports.getStatfsOptions)(),options2]:[(0,exports.getStatfsOptions)(options2),(0,util_1.validateCallback)(callback)];exports.getStatfsOptsAndCb=getStatfsOptsAndCb;var realpathDefaults=exports.optsDefaults;exports.getRealpathOptions=optsGenerator(realpathDefaults);exports.getRealpathOptsAndCb=optsAndCbGenerator(exports.getRealpathOptions);exports.writeFileDefaults={encoding:"utf8",mode:438,flag:fs_node_utils_1.FLAGS[fs_node_utils_1.FLAGS.w]};exports.getWriteFileOptions=optsGenerator(exports.writeFileDefaults)}});var require_Dir=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/Dir.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Dir=void 0;var fs_node_utils_1=require_lib5(),argErrors_1=require_argErrors(),validators_1=require_validators(),Dirent_1=require_Dirent(),util_1=require_util2(),DEFAULT_ENCODING={encoding:"utf8"},dirClosed=()=>(0,argErrors_1.withCode)(new Error("Directory handle was closed"),"ERR_DIR_CLOSED"),dirBusy=()=>(0,argErrors_1.withCode)(new Error("Cannot do synchronous work on directory handle with concurrent asynchronous operations"),"ERR_DIR_CONCURRENT_OPERATION"),Dir=class _Dir{constructor(handle2,path4,options2){if(this.levels=[],this.closed=!1,this.operationQueue=null,handle2==null)throw(0,argErrors_1.withCode)(new TypeError('The "handle" argument must be specified'),"ERR_MISSING_ARGS");let type=typeof options2,opts={bufferSize:32,...options2==null||type==="function"?DEFAULT_ENCODING:type==="string"?{encoding:options2}:options2};(0,validators_1.validateUint32)(opts.bufferSize,"options.bufferSize",!0),this.options=opts,this._path=path4;let parentPath=typeof path4=="string"?path4:path4.toString();this.levels.push({entries:handle2.children[Symbol.iterator](),path:path4,parentPath})}readBase(){let levels=this.levels,options2=this.options,encoding=options2.encoding,recursive=options2.recursive;for(;levels.length;){let level=levels[levels.length-1],{done,value:value2}=level.entries.next();if(done){levels.pop();continue}let name=value2[0];if(name==="."||name==="..")continue;let link2=value2[1],dirent=Dirent_1.default.build(link2,encoding,level.parentPath);return recursive&&dirent.isDirectory()&&this.descend(level.path,dirent.name,link2),dirent}return null}descend(parent,name,link2){let path4=(0,fs_node_utils_1.pathJoin)(parent,name);if(!link2.getNode().canRead())throw(0,util_1.createError)("EACCES","opendir",path4);this.levels.push({entries:link2.children[Symbol.iterator](),path:path4,parentPath:path4})}readPromise(){return new Promise((resolve2,reject)=>{this.readImpl((err,entry)=>{err?reject(err):resolve2(entry??null)})})}readImpl(callback){if(this.closed)throw dirClosed();if(callback===void 0)return this.readPromise();let cb=callback;(0,util_1.validateCallback)(cb);let queued=this.operationQueue;if(queued!==null){queued.push(()=>{try{this.readImpl(cb)}catch(err){process.nextTick(cb,err)}});return}this.operationQueue=[];let entry=null,error=null;try{entry=this.readBase()}catch(err){error=err}process.nextTick(()=>{process.nextTick(()=>{let queue2=this.operationQueue;if(this.operationQueue=null,queue2)for(let i2=0;i2<queue2.length;i2++)queue2[i2]()}),error?cb(error):cb(null,entry)})}get path(){if(!(this instanceof _Dir))throw(0,argErrors_1.invalidThis)("Dir");return this._path}close(callback){if(callback===void 0)return this.closed?Promise.reject(dirClosed()):new Promise((resolve2,reject)=>{this.close(err=>{err?reject(err):resolve2()})});let cb=callback;if((0,util_1.validateCallback)(cb),this.closed){process.nextTick(cb,dirClosed());return}let queued=this.operationQueue;if(queued!==null){queued.push(()=>{this.close(cb)});return}this.closed=!0,process.nextTick(cb,null)}closeSync(){if(this.closed)throw dirClosed();if(this.operationQueue!==null)throw dirBusy();this.closed=!0}read(callback){return arguments.length===0?this.readPromise():this.readImpl(callback)}readSync(){if(this.closed)throw dirClosed();if(this.operationQueue!==null)throw dirBusy();return this.readBase()}async*entries(){try{for(;;){let entry=await this.read();if(entry===null)break;yield entry}}finally{await this.close()}}async[Symbol.asyncDispose](){this.closed||await this.close()}[Symbol.dispose](){this.closed||this.closeSync()}};exports.Dir=Dir;Object.defineProperty(Dir.prototype,Symbol.asyncIterator,{enumerable:!1,writable:!0,configurable:!0,value:Dir.prototype.entries})}});var require_volume=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/volume.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FSWatcher=exports.StatWatcher=exports.Volume=void 0;exports.pathToSteps=pathToSteps;exports.dataToStr=dataToStr;exports.toUnixTimestamp=toUnixTimestamp;var path_1=require_path2(),fs_core_1=require_lib6(),Stats_1=require_Stats(),Dirent_1=require_Dirent(),StatFs_1=require_StatFs(),glob_1=require_glob(),buffer_1=require_buffer3(),setTimeoutUnref_1=require_setTimeoutUnref(),stream_1=require_stream2(),fs_node_utils_1=require_lib5(),events_1=require_events2(),FileHandle_1=require_FileHandle(),util_1=require_util4(),FsPromises_1=require_FsPromises(),fs_print_1=require_lib8(),fsSnapshot=require_lib9(),fs_node_utils_2=require_lib5(),argErrors_1=require_argErrors(),validators_1=require_validators(),options_1=require_options(),util_2=require_util2(),readWriteArgs_1=require_readWriteArgs(),Dir_1=require_Dir(),cp_1=require_cp(),{O_SYMLINK,F_OK,R_OK,W_OK,X_OK}=fs_node_utils_1.constants,kMinPoolSpace=128;function pathToSteps(path4){return(0,fs_core_1.filenameToSteps)((0,util_2.pathToFilename)(path4))}function dataToStr(data,encoding=fs_node_utils_1.ENCODING_UTF8){return buffer_1.Buffer.isBuffer(data)?data.toString(encoding):data instanceof Uint8Array?(0,buffer_1.bufferFrom)(data).toString(encoding):String(data)}function toUnixTimestamp(time){if(typeof time=="string"&&+time==time)return+time;if(time instanceof Date)return time.getTime()/1e3;if(isFinite(time))return time<0?Date.now()/1e3:time;throw new Error("Cannot parse time: "+time)}function validateUid(uid){if(typeof uid!="number")throw TypeError(fs_node_utils_2.ERRSTR.UID)}function validateGid(gid){if(typeof gid!="number")throw TypeError(fs_node_utils_2.ERRSTR.GID)}var Volume=class{get promises(){if(this.promisesApi===null)throw new Error("Promise is not supported in this environment.");return this.promisesApi}constructor(_core=new fs_core_1.Superblock){this._core=_core,this.promisesApi=new FsPromises_1.FsPromises(this,FileHandle_1.FileHandle),this.openSync=(path4,flags,mode=438)=>{let modeNum=(0,util_2.modeToNumber)(mode),fileName=(0,util_2.pathToFilename)(path4),flagsNum=(0,util_2.flagsToNumber)(flags);return this._core.open(fileName,flagsNum,modeNum,!(flagsNum&O_SYMLINK))},this.open=(path4,flags,a2,b2)=>{let mode=a2,callback=b2;typeof a2=="function"&&(mode=438,callback=a2),mode=mode||438;let modeNum=(0,util_2.modeToNumber)(mode),fileName=(0,util_2.pathToFilename)(path4),flagsNum=(0,util_2.flagsToNumber)(flags);this.wrapAsync(this._core.open,[fileName,flagsNum,modeNum,!(flagsNum&O_SYMLINK)],callback)},this.closeSync=fd=>{this._core.close(fd)},this.close=(fd,callback)=>{(0,fs_core_1.validateFd)(fd);let file=this._core.getFileByFdOrThrow(fd,"close");this.wrapAsync(this._core.close,[file.fd],callback)},this.readv=(fd,buffers,a2,b2)=>{(0,validators_1.validateInt32)(fd,"fd",0);let[position2,callback]=(0,readWriteArgs_1.getVectorCallbackArgs)(buffers,a2,b2);Promise.resolve().then(()=>{try{if(!buffers.length)throw(0,util_2.createError)("EINVAL","read");callback(null,this._core.readv(fd,buffers,position2),buffers)}catch(err){callback(err,0,buffers)}})},this.readvSync=(fd,buffers,position2)=>{let seek=(0,readWriteArgs_1.getVectorArgs)(buffers,position2);if((0,fs_core_1.validateFd)(fd),!buffers.length)throw(0,util_2.createError)("EINVAL","read");return this._core.readv(fd,buffers,seek)},this._readfile=(id,flagsNum,encoding)=>{let result,userOwnsFd=typeof id=="number"&&(0,fs_core_1.isFd)(id),fd;userOwnsFd?fd=id:fd=this.openSync(id,flagsNum);try{let file=this._core.getFileByFdOrThrow(fd,"fstat");if(file.node.isDirectory())throw(0,util_2.createError)("EISDIR","read");let buffer=file.getBuffer(),start=userOwnsFd?Math.min(file.position,buffer.length):0;file.position=buffer.length,result=(0,util_2.bufferToEncoding)(start?buffer.subarray(start):buffer,encoding)}finally{userOwnsFd||this.closeSync(fd)}return result},this.readFileSync=(file,options2)=>{let opts=(0,options_1.getReadFileOptions)(options2),flagsNum=(0,util_2.flagsToNumber)(opts.flag);return this._readfile(file,flagsNum,opts.encoding)},this.readFile=(id,a2,b2)=>{let[opts,callback]=(0,options_1.optsAndCbGenerator)(options_1.getReadFileOptions)(a2,b2),flagsNum=(0,util_2.flagsToNumber)(opts.flag);this.wrapAsync(this._readfile,[id,flagsNum,opts.encoding],callback)},this.writeSync=(fd,a2,b2,c2,d2)=>{let[,buf,offset,length,position2]=(0,util_2.getWriteSyncArgs)(fd,a2,b2,c2,d2);return this._write(fd,buf,offset,length,position2)},this.write=(fd,a2,b2,c2,d2,e2)=>{let[,,buf,offset,length,position2,cb]=(0,util_2.getWriteArgs)(fd,a2,b2,c2,d2,e2);Promise.resolve().then(()=>{try{cb(null,this._write(fd,buf,offset,length,position2),a2)}catch(err){cb(err,0,a2)}})},this.writev=(fd,buffers,a2,b2)=>{(0,validators_1.validateInt32)(fd,"fd",0);let[position2,callback]=(0,readWriteArgs_1.getVectorCallbackArgs)(buffers,a2,b2);if(!buffers.length){queueMicrotask(()=>callback(null,0,buffers));return}Promise.resolve().then(()=>{try{callback(null,this.writevBase(fd,buffers,position2),buffers)}catch(err){callback(err,0,buffers)}})},this.writevSync=(fd,buffers,position2)=>{let seek=(0,readWriteArgs_1.getVectorArgs)(buffers,position2);return buffers.length?((0,fs_core_1.validateFd)(fd),this.writevBase(fd,buffers,seek)):0},this.writeFileSync=(id,data,options2)=>{let opts=(0,options_1.getWriteFileOptions)(options2),flagsNum=(0,util_2.flagsToNumber)(opts.flag),modeNum=(0,util_2.modeToNumber)(opts.mode),buf=(0,fs_core_1.dataToBuffer)(data,opts.encoding);this._core.writeFile(id,buf,flagsNum,modeNum)},this.writeFile=(id,data,a2,b2)=>{let options2=a2,callback=b2;typeof a2=="function"&&([options2,callback]=[options_1.writeFileDefaults,a2]);let cb=(0,util_2.validateCallback)(callback),opts=(0,options_1.getWriteFileOptions)(options2),flagsNum=(0,util_2.flagsToNumber)(opts.flag),modeNum=(0,util_2.modeToNumber)(opts.mode),buf=(0,fs_core_1.dataToBuffer)(data,opts.encoding);this.wrapAsync(this._core.writeFile,[id,buf,flagsNum,modeNum],cb)},this.copyFileSync=(src,dest,flags)=>{let srcFilename=(0,util_2.pathToFilename)(src),destFilename=(0,util_2.pathToFilename)(dest);(0,cp_1.copyFileCore)(this._core,srcFilename,destFilename,(0,cp_1.getValidCopyFileMode)(flags))},this.copyFile=(src,dest,a2,b2)=>{let srcFilename=(0,util_2.pathToFilename)(src),destFilename=(0,util_2.pathToFilename)(dest),flags,callback;typeof a2=="function"?[flags,callback]=[0,a2]:[flags,callback]=[a2,b2],(0,util_2.validateCallback)(callback);let flagsNum=(0,cp_1.getValidCopyFileMode)(flags);Promise.resolve().then(()=>{try{(0,cp_1.copyFileCore)(this._core,srcFilename,destFilename,flagsNum)}catch(error){callback(error);return}callback(null)})},this.linkSync=(existingPath,newPath)=>{let existingPathFilename=(0,util_2.pathToFilename)(existingPath),newPathFilename=(0,util_2.pathToFilename)(newPath);this._core.link(existingPathFilename,newPathFilename)},this.link=(existingPath,newPath,callback)=>{let existingPathFilename=(0,util_2.pathToFilename)(existingPath),newPathFilename=(0,util_2.pathToFilename)(newPath);this.wrapAsync(this._core.link,[existingPathFilename,newPathFilename],callback)},this.unlinkSync=path4=>{let filename=(0,util_2.pathToFilename)(path4);this._core.unlink(filename)},this.unlink=(path4,callback)=>{let filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._core.unlink,[filename],callback)},this.symlinkSync=(target,path4,type)=>{let targetFilename=(0,util_2.pathToFilename)(target),pathFilename=(0,util_2.pathToFilename)(path4);this._core.symlink(targetFilename,pathFilename)},this.symlink=(target,path4,a2,b2)=>{let callback=(0,util_2.validateCallback)(typeof a2=="function"?a2:b2),targetFilename=(0,util_2.pathToFilename)(target),pathFilename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._core.symlink,[targetFilename,pathFilename],callback)},this._lstat=(filename,bigint=!1,throwIfNoEntry=!1)=>{let link2;try{link2=this._core.getLinkOrThrow(filename,"lstat")}catch(err){if(err.code==="ENOENT"&&!throwIfNoEntry)return;throw err}return Stats_1.default.build(link2.getNode(),bigint)},this.lstatSync=(path4,options2)=>{let{throwIfNoEntry=!0,bigint=!1}=(0,options_1.getStatOptions)(options2);return this._lstat((0,util_2.pathToFilename)(path4),bigint,throwIfNoEntry)},this.renameSync=(oldPath,newPath)=>{let oldPathFilename=(0,util_2.pathToFilename)(oldPath),newPathFilename=(0,util_2.pathToFilename)(newPath);this._core.rename(oldPathFilename,newPathFilename)},this.rename=(oldPath,newPath,callback)=>{let oldPathFilename=(0,util_2.pathToFilename)(oldPath),newPathFilename=(0,util_2.pathToFilename)(newPath);this.wrapAsync(this._core.rename,[oldPathFilename,newPathFilename],callback)},this.existsSync=path4=>{try{return this._exists((0,util_2.pathToFilename)(path4)).ok}catch{return!1}},this.exists=(path4,callback)=>{let filename=(0,util_2.pathToFilename)(path4);if(typeof callback!="function")throw Error(fs_node_utils_2.ERRSTR.CB);Promise.resolve().then(()=>{try{callback(this._exists(filename).ok)}catch{callback(!1)}})},this.accessSync=(path4,mode=F_OK)=>{let filename=(0,util_2.pathToFilename)(path4);mode=mode|0,this._access(filename,mode)},this.access=(path4,a2,b2)=>{let mode=F_OK,callback;typeof a2!="function"?[mode,callback]=[a2|0,(0,util_2.validateCallback)(b2)]:callback=a2;let filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._access,[filename,mode],callback)},this.appendFileSync=(id,data,options2)=>{let opts=(0,options_1.getAppendFileOpts)(options2);(!opts.flag||(0,fs_core_1.isFd)(id))&&(opts.flag="a"),this.writeFileSync(id,data,opts)},this.appendFile=(id,data,a2,b2)=>{let[opts,callback]=(0,options_1.getAppendFileOptsAndCb)(a2,b2);(!opts.flag||(0,fs_core_1.isFd)(id))&&(opts.flag="a"),this.writeFile(id,data,opts,callback)},this._readdir=(filename,options2)=>{let steps=(0,fs_core_1.filenameToSteps)(filename),link2=this._core.getResolvedLinkOrThrow(filename,"scandir"),node2=link2.getNode();if(!node2.isDirectory())throw(0,util_2.createError)("ENOTDIR","scandir",filename);if(!node2.canRead())throw(0,util_2.createError)("EACCES","scandir",filename);let list5=[];for(let name of link2.children.keys()){let child=link2.getChild(name);if(!(!child||name==="."||name==="..")&&(list5.push(Dirent_1.default.build(child,options2.encoding)),options2.recursive&&child.children.size)){let recurseOptions={...options2,recursive:!0,withFileTypes:!0},childList2=this._readdir(child.getPath(),recurseOptions);list5.push(...childList2)}}if(!fs_core_1.isWin&&options2.encoding!=="buffer"&&list5.sort((a2,b2)=>a2.name<b2.name?-1:a2.name>b2.name?1:0),options2.withFileTypes)return list5;let filename2=filename;return fs_core_1.isWin&&(filename2=filename2.replace(/\\/g,"/")),list5.map(dirent=>{if(options2.recursive){let fullPath=(0,fs_node_utils_2.pathJoin)(dirent.parentPath,dirent.name.toString());return fs_core_1.isWin&&(fullPath=fullPath.replace(/\\/g,"/")),fullPath.replace(filename2+path_1.posix.sep,"")}return dirent.name})},this.readdirSync=(path4,options2)=>{let opts=(0,options_1.getReaddirOptions)(options2),filename=(0,util_2.pathToFilename)(path4);return this._readdir(filename,opts)},this.readdir=(path4,a2,b2)=>{let[options2,callback]=(0,options_1.getReaddirOptsAndCb)(a2,b2),filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._readdir,[filename,options2],callback)},this._readlink=(filename,encoding)=>{let node2=this._core.getLinkOrThrow(filename,"readlink").getNode();if(!node2.isSymlink())throw(0,util_2.createError)("EINVAL","readlink",filename);return(0,fs_node_utils_1.strToEncoding)(node2.symlink,encoding)},this.readlinkSync=(path4,options2)=>{let opts=(0,options_1.getDefaultOpts)(options2),filename=(0,util_2.pathToFilename)(path4);return this._readlink(filename,opts.encoding)},this.readlink=(path4,a2,b2)=>{let[opts,callback]=(0,options_1.getDefaultOptsAndCb)(a2,b2),filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._readlink,[filename,opts.encoding],callback)},this._fsync=fd=>{this._core.getFileByFdOrThrow(fd,"fsync")},this.fsyncSync=fd=>{this._fsync(fd)},this.fsync=(fd,callback)=>{this.wrapAsync(this._fsync,[fd],callback)},this._fdatasync=fd=>{this._core.getFileByFdOrThrow(fd,"fdatasync")},this.fdatasyncSync=fd=>{this._fdatasync(fd)},this.fdatasync=(fd,callback)=>{this.wrapAsync(this._fdatasync,[fd],callback)},this._ftruncate=(fd,len)=>{this._core.ftruncate(fd,len)},this.ftruncateSync=(fd,len)=>{this._ftruncate(fd,len)},this.ftruncate=(fd,a2,b2)=>{let len=typeof a2=="number"?a2:0,callback=(0,util_2.validateCallback)(typeof a2=="number"?b2:a2);this.wrapAsync(this._ftruncate,[fd,len],callback)},this._truncate=(path4,len)=>{let fd=this.openSync(path4,"r+");try{this.ftruncateSync(fd,len)}finally{this.closeSync(fd)}},this.truncateSync=(id,len)=>{if((0,fs_core_1.isFd)(id))return this.ftruncateSync(id,len);this._truncate(id,len)},this.truncate=(id,a2,b2)=>{let len=typeof a2=="number"?a2:0,callback=(0,util_2.validateCallback)(typeof a2=="number"?b2:a2);if((0,fs_core_1.isFd)(id))return this.ftruncate(id,len,callback);this.wrapAsync(this._truncate,[id,len],callback)},this._futimes=(fd,atime,mtime)=>{this._core.futimes(fd,atime,mtime)},this.futimesSync=(fd,atime,mtime)=>{this._futimes(fd,toUnixTimestamp(atime),toUnixTimestamp(mtime))},this.futimes=(fd,atime,mtime,callback)=>{this.wrapAsync(this._futimes,[fd,toUnixTimestamp(atime),toUnixTimestamp(mtime)],callback)},this._utimes=(filename,atime,mtime,followSymlinks=!0)=>{this._core.utimes(filename,atime,mtime,followSymlinks)},this.utimesSync=(path4,atime,mtime)=>{this._utimes((0,util_2.pathToFilename)(path4),toUnixTimestamp(atime),toUnixTimestamp(mtime),!0)},this.utimes=(path4,atime,mtime,callback)=>{this.wrapAsync(this._utimes,[(0,util_2.pathToFilename)(path4),toUnixTimestamp(atime),toUnixTimestamp(mtime),!0],callback)},this.lutimesSync=(path4,atime,mtime)=>{this._utimes((0,util_2.pathToFilename)(path4),toUnixTimestamp(atime),toUnixTimestamp(mtime),!1)},this.lutimes=(path4,atime,mtime,callback)=>{this.wrapAsync(this._utimes,[(0,util_2.pathToFilename)(path4),toUnixTimestamp(atime),toUnixTimestamp(mtime),!1],callback)},this.mkdirSync=(path4,options2)=>{let opts=(0,options_1.getMkdirOptions)(options2),modeNum=(0,util_2.modeToNumber)(opts.mode,511),filename=(0,util_2.pathToFilename)(path4);if(opts.recursive)return this._core.mkdirp(filename,modeNum);this._core.mkdir(filename,modeNum)},this.mkdir=(path4,a2,b2)=>{let opts=(0,options_1.getMkdirOptions)(a2),callback=(0,util_2.validateCallback)(typeof a2=="function"?a2:b2),modeNum=(0,util_2.modeToNumber)(opts.mode,511),filename=(0,util_2.pathToFilename)(path4);opts.recursive?this.wrapAsync(this._core.mkdirp,[filename,modeNum],callback):this.wrapAsync(this._core.mkdir,[filename,modeNum],callback)},this._mkdtemp=(prefix,encoding,retry=5)=>{let filename=prefix+(0,util_2.genRndStr6)();try{return this._core.mkdir(filename,511),(0,fs_node_utils_1.strToEncoding)(filename,encoding)}catch(err){if(err.code==="EEXIST"){if(retry>1)return this._mkdtemp(prefix,encoding,retry-1);throw Error("Could not create temp dir.")}else throw err}},this.mkdtempSync=(prefix,options2)=>{let{encoding}=(0,options_1.getDefaultOpts)(options2);if(!prefix||typeof prefix!="string")throw new TypeError("filename prefix is required");return(0,util_2.nullCheck)(prefix),this._mkdtemp(prefix,encoding)},this.mkdtemp=(prefix,a2,b2)=>{let[{encoding},callback]=(0,options_1.getDefaultOptsAndCb)(a2,b2);if(!prefix||typeof prefix!="string")throw new TypeError("filename prefix is required");(0,util_2.nullCheck)(prefix)&&this.wrapAsync(this._mkdtemp,[prefix,encoding],callback)},this.rmdirSync=(path4,options2)=>{let opts=(0,options_1.getRmdirOptions)(options2);this._core.rmdir((0,util_2.pathToFilename)(path4),opts.recursive)},this.rmdir=(path4,a2,b2)=>{let opts=(0,options_1.getRmdirOptions)(a2),callback=(0,util_2.validateCallback)(typeof a2=="function"?a2:b2);this.wrapAsync(this._core.rmdir,[(0,util_2.pathToFilename)(path4),opts.recursive],callback)},this.rmSync=(path4,options2)=>{this._core.rm((0,util_2.pathToFilename)(path4),options2?.force,options2?.recursive)},this.rm=(path4,a2,b2)=>{let[opts,callback]=(0,options_1.getRmOptsAndCb)(a2,b2);this.wrapAsync(this._core.rm,[(0,util_2.pathToFilename)(path4),opts?.force,opts?.recursive],callback)},this._fchmod=(fd,modeNum)=>{this._core.fchmod(fd,modeNum)},this.fchmodSync=(fd,mode)=>{this._fchmod(fd,(0,util_2.modeToNumber)(mode))},this.fchmod=(fd,mode,callback)=>{this.wrapAsync(this._fchmod,[fd,(0,util_2.modeToNumber)(mode)],callback)},this._chmod=(filename,modeNum,followSymlinks=!0)=>{followSymlinks?this._core.chmod(filename,modeNum):this._core.lchmod(filename,modeNum)},this.chmodSync=(path4,mode)=>{let modeNum=(0,util_2.modeToNumber)(mode),filename=(0,util_2.pathToFilename)(path4);this._chmod(filename,modeNum,!0)},this.chmod=(path4,mode,callback)=>{let modeNum=(0,util_2.modeToNumber)(mode),filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._chmod,[filename,modeNum],callback)},this._lchmod=(filename,modeNum)=>{this._core.lchmod(filename,modeNum)},this.lchmodSync=(path4,mode)=>{let modeNum=(0,util_2.modeToNumber)(mode),filename=(0,util_2.pathToFilename)(path4);this._lchmod(filename,modeNum)},this.lchmod=(path4,mode,callback)=>{let modeNum=(0,util_2.modeToNumber)(mode),filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._lchmod,[filename,modeNum],callback)},this._fchown=(fd,uid,gid)=>{this._core.fchown(fd,uid,gid)},this.fchownSync=(fd,uid,gid)=>{validateUid(uid),validateGid(gid),this._fchown(fd,uid,gid)},this.fchown=(fd,uid,gid,callback)=>{validateUid(uid),validateGid(gid),this.wrapAsync(this._fchown,[fd,uid,gid],callback)},this._chown=(filename,uid,gid)=>{this._core.chown(filename,uid,gid)},this.chownSync=(path4,uid,gid)=>{validateUid(uid),validateGid(gid),this._chown((0,util_2.pathToFilename)(path4),uid,gid)},this.chown=(path4,uid,gid,callback)=>{validateUid(uid),validateGid(gid),this.wrapAsync(this._chown,[(0,util_2.pathToFilename)(path4),uid,gid],callback)},this._lchown=(filename,uid,gid)=>{this._core.lchown(filename,uid,gid)},this.lchownSync=(path4,uid,gid)=>{validateUid(uid),validateGid(gid),this._lchown((0,util_2.pathToFilename)(path4),uid,gid)},this.lchown=(path4,uid,gid,callback)=>{validateUid(uid),validateGid(gid),this.wrapAsync(this._lchown,[(0,util_2.pathToFilename)(path4),uid,gid],callback)},this.statWatchers={},this.cpSync=(src,dest,options2)=>{let opts_=(0,cp_1.getCpOptions)(options2),srcFilename=(0,util_2.pathToFilename)(src),destFilename=(0,util_2.pathToFilename)(dest);(0,cp_1.cpSync)(this,srcFilename,destFilename,opts_)},this.cp=(src,dest,a2,b2)=>{let options2,callback;typeof a2=="function"?[options2,callback]=[void 0,a2]:[options2,callback]=[a2,b2],(0,util_2.validateCallback)(callback);let opts_=(0,cp_1.getCpOptions)(options2),srcFilename=(0,util_2.pathToFilename)(src),destFilename=(0,util_2.pathToFilename)(dest);(0,cp_1.cpAsync)(this,srcFilename,destFilename,opts_).then(()=>callback(null,void 0),error=>callback(error))},this.openAsBlob=async(path4,options2)=>{let filename=(0,util_2.pathToFilename)(path4),link2;try{link2=this._core.getResolvedLinkOrThrow(filename,"open")}catch(error){throw error&&typeof error=="object"&&error.code==="ENOENT"?(0,argErrors_1.withNativeCode)(new TypeError("Unable to open file as blob"),"ERR_INVALID_ARG_VALUE"):error}let buffer=link2.getNode().getBuffer(),type=options2?.type||"";return new Blob([buffer],{type})},this.glob=(pattern,options2,callback)=>{typeof options2=="function"&&(callback=options2,options2=void 0);let cb=(0,util_2.validateCallback)(callback),walk2=(0,glob_1.globWalk)(this,pattern,options2);Promise.resolve().then(()=>{let results=[];for(let match of walk2)results.push(match);return results}).then(results=>cb(null,results),cb)},this.globSync=(pattern,options2)=>(0,glob_1.globSync)(this,pattern,options2),this._opendir=(filename,options2,path4,errorPath)=>{let result=this._core.getResolvedLinkResult(filename,"opendir");if(!result.ok)throw(0,util_2.createError)(result.err.code,"opendir",errorPath);let link2=result.value,node2=link2.getNode();if(!node2.isDirectory())throw(0,util_2.createError)("ENOTDIR","opendir",errorPath);if(!node2.canRead())throw(0,util_2.createError)("EACCES","opendir",errorPath);return new Dir_1.Dir(link2,path4,options2)},this.opendirSync=(path4,options2)=>{let filename=(0,util_2.pathToFilename)(path4),opts=(0,options_1.getOpendirOptions)(options2);return this._opendir(filename,opts,path4 instanceof Uint8Array?(0,buffer_1.bufferFrom)(path4):filename,"")},this.opendir=(path4,a2,b2)=>{let[options2,callback]=(0,options_1.getOpendirOptsAndCb)(a2,b2),filename=(0,util_2.pathToFilename)(path4),dirPath=path4 instanceof Uint8Array?(0,buffer_1.bufferFrom)(path4):filename;this.wrapAsync(this._opendir,[filename,options2,dirPath,filename],callback)};let self2=this;this.StatWatcher=class extends StatWatcher{constructor(){super(self2)}};let _ReadStream=FsReadStream;this.ReadStream=class extends _ReadStream{constructor(...args){super(self2,...args)}};let _WriteStream=FsWriteStream;this.WriteStream=class extends _WriteStream{constructor(...args){super(self2,...args)}},this.FSWatcher=class extends FSWatcher{constructor(){super(self2)}};let _realpath=(filename,encoding)=>{let realLink=this._core.getResolvedLinkOrThrow(filename,"realpath");return(0,fs_node_utils_1.strToEncoding)(realLink.getPath()||"/",encoding)},realpathImpl=(path4,a2,b2)=>{let[opts,callback]=(0,options_1.getRealpathOptsAndCb)(a2,b2),pathFilename=(0,util_2.pathToFilename)(path4);self2.wrapAsync(_realpath,[pathFilename,opts.encoding],callback)},realpathSyncImpl=(path4,options2)=>_realpath((0,util_2.pathToFilename)(path4),(0,options_1.getRealpathOptions)(options2).encoding);this.realpath=realpathImpl,this.realpath.native=realpathImpl,this.realpathSync=realpathSyncImpl,this.realpathSync.native=realpathSyncImpl,this.readSync=function(fd,a2,b2,c2,d2){let{buffer,offset,length,position:position2}=(0,readWriteArgs_1.getReadSyncArgs)(arguments.length,a2,b2,c2,d2);return(0,fs_core_1.validateFd)(fd),self2._core.read(fd,buffer,offset,length,position2)},this.read=function(fd,a2,b2,c2,d2,e2){(0,validators_1.validateInt32)(fd,"fd",0);let{buffer,offset,length,position:position2,callback}=(0,readWriteArgs_1.getReadArgs)(arguments.length,a2,b2,c2,d2,e2);if(length===0){queueMicrotask(()=>callback(null,0,buffer));return}Promise.resolve().then(()=>{try{callback(null,self2._core.read(fd,buffer,offset,length,position2),buffer)}catch(err){callback(err,0,buffer)}})}}wrapAsync(method,args,callback){(0,util_2.validateCallback)(callback),Promise.resolve().then(()=>{let result;try{result=method.apply(this,args)}catch(err){callback(err);return}callback(null,result)})}reset(){this._core.reset()}toJSON(paths,json={},isRelative=!1,asBuffer=!1){return this._core.toJSON(paths,json,isRelative,asBuffer)}fromJSON(json,cwd2){return this._core.fromJSON(json,cwd2)}fromNestedJSON(json,cwd2){return this._core.fromNestedJSON(json,cwd2)}mountSync(mountpoint,json){this._core.fromJSON(json,mountpoint)}_write(fd,buf,offset,length,position2){return this._core.write(fd,buf,offset,length,position2)}writevBase(fd,buffers,position2){this._core.getFileByFdOrThrow(fd,"write");let p2=position2,bytesWritten=0,length=buffers.length;for(let i2=0;i2<length;i2++){let buffer=buffers[i2],nodeBuf=buffer_1.Buffer.from(buffer.buffer,buffer.byteOffset,buffer.byteLength),bytes=this._core.write(fd,nodeBuf,0,nodeBuf.byteLength,p2);if(p2!==null&&(p2+=bytes),bytesWritten+=bytes,bytes<nodeBuf.byteLength)break}return bytesWritten}lstat(path4,a2,b2){let[{throwIfNoEntry=!0,bigint=!1},callback]=(0,options_1.getStatOptsAndCb)(a2,b2);this.wrapAsync(this._lstat,[(0,util_2.pathToFilename)(path4),bigint,throwIfNoEntry],callback)}_stat(filename,bigint=!1,throwIfNoEntry=!0){let result=this._core.getResolvedLinkResult(filename,"stat");return result.ok?(0,fs_core_1.Ok)(Stats_1.default.build(result.value.getNode(),bigint)):result.err.code==="ENOENT"&&!throwIfNoEntry?(0,fs_core_1.Ok)(void 0):result}_statOrThrow(filename,bigint=!1,throwIfNoEntry=!0){let result=this._stat(filename,bigint,throwIfNoEntry);if(result.ok)return result.value;throw result.err.toError()}statSync(path4,options2){let{bigint=!0,throwIfNoEntry=!0}=(0,options_1.getStatOptions)(options2),result=this._stat((0,util_2.pathToFilename)(path4),bigint,throwIfNoEntry);if(result.ok)return result.value;throw result.err.toError()}stat(path4,a2,b2){let[{bigint=!1,throwIfNoEntry=!0},callback]=(0,options_1.getStatOptsAndCb)(a2,b2);this.wrapAsync(this._statOrThrow,[(0,util_2.pathToFilename)(path4),bigint,throwIfNoEntry],callback)}fstatBase(fd,bigint=!1){let file=this._core.getFileByFd(fd);if(!file)throw(0,util_2.createError)("EBADF","fstat");return Stats_1.default.build(file.node,bigint)}fstatSync(fd,options2){return this.fstatBase(fd,(0,options_1.getStatOptions)(options2).bigint)}fstat(fd,a2,b2){let[opts,callback]=(0,options_1.getStatOptsAndCb)(a2,b2);this.wrapAsync(this.fstatBase,[fd,opts.bigint],callback)}_exists(filename){let result=this._stat(filename);return result.ok?(0,fs_core_1.Ok)(!0):result}_access(filename,mode){let node2=this._core.getResolvedLinkOrThrow(filename,"access").getNode();if(mode!==F_OK&&(mode&R_OK&&!node2.canRead()||mode&W_OK&&!node2.canWrite()||mode&X_OK&&!node2.canExecute()))throw(0,util_2.createError)("EACCES","access",filename)}watchFile(path4,a2,b2){let filename=(0,util_2.pathToFilename)(path4),options2=a2,listener=b2;if(typeof options2=="function"&&(listener=a2,options2=null),typeof listener!="function")throw new TypeError('The "listener" argument must be of type function. Received '+typeof listener);let interval=5007,persistent=!0,bigint=!1;if(options2&&typeof options2=="object"){if(options2.interval!==void 0){if(typeof options2.interval!="number")throw new TypeError('The "options.interval" property must be of type number. Received '+typeof options2.interval);if(!Number.isInteger(options2.interval)||options2.interval<0||options2.interval>4294967295)throw new RangeError(`The value of "options.interval" is out of range. It must be an integer >= 0 && <= 4294967295. Received ${options2.interval}`);interval=options2.interval}typeof options2.persistent=="boolean"&&(persistent=options2.persistent),typeof options2.bigint=="boolean"&&(bigint=options2.bigint)}let watcher=this.statWatchers[filename];return watcher||(watcher=new this.StatWatcher,watcher.start(filename,persistent,interval,bigint),this.statWatchers[filename]=watcher),watcher.addListener("change",listener),watcher}unwatchFile(path4,listener){let filename=(0,util_2.pathToFilename)(path4),watcher=this.statWatchers[filename];watcher&&(typeof listener=="function"?watcher.removeListener("change",listener):watcher.removeAllListeners("change"),watcher.listenerCount("change")===0&&(watcher.stop(),delete this.statWatchers[filename]))}createReadStream(path4,options2){return new this.ReadStream(path4,options2)}createWriteStream(path4,options2){return new this.WriteStream(path4,options2)}watch(path4,options2,listener){let filename=(0,util_2.pathToFilename)(path4),givenOptions=options2;typeof options2=="function"&&(listener=options2,givenOptions=null);let{persistent,recursive,encoding,signal,throwIfNoEntry,ignore:ignore3}=(0,options_1.getDefaultOpts)(givenOptions);persistent===void 0&&(persistent=!0),recursive===void 0&&(recursive=!1);let watcher=new this.FSWatcher;try{watcher.start(filename,persistent,recursive,encoding,ignore3)}catch(err){if(throwIfNoEntry===!1&&err.code==="ENOENT")return watcher;throw err}if(listener&&watcher.addListener("change",listener),signal)if(signal.aborted)watcher.close();else{let onAbort=()=>watcher.close();signal.addEventListener("abort",onAbort,{once:!0}),watcher.once("close",()=>signal.removeEventListener("abort",onAbort))}return watcher}_statfs(filename,bigint=!1){return this._core.getResolvedLinkOrThrow(filename,"statfs"),StatFs_1.default.build(this._core,bigint)}statfsSync(path4,options2){let{bigint=!1}=(0,options_1.getStatfsOptions)(options2);return this._statfs((0,util_2.pathToFilename)(path4),bigint)}statfs(path4,a2,b2){let[{bigint=!1},callback]=(0,options_1.getStatfsOptsAndCb)(a2,b2);this.wrapAsync(this._statfs,[(0,util_2.pathToFilename)(path4),bigint],callback)}toTree(opts={separator:path_1.sep}){return(0,fs_print_1.toTreeSync)(this,opts)}toSnapshot(path4="/"){return fsSnapshot.toSnapshotSync({fs:this,path:path4})}fromSnapshot(snapshot,path4="/"){return fsSnapshot.fromSnapshotSync(snapshot,{fs:this,path:path4})}toBinarySnapshot(path4="/"){return fsSnapshot.toBinarySnapshotSync({fs:this,path:path4})}fromBinarySnapshot(binary2,path4="/"){return fsSnapshot.fromBinarySnapshotSync(binary2,{fs:this,path:path4})}toJsonSnapshot(path4="/"){let uint8=fsSnapshot.toJsonSnapshotSync({fs:this,path:path4});return buffer_1.Buffer.from(uint8).toString("utf8")}fromJsonSnapshot(json,path4="/"){let uint8=new Uint8Array(buffer_1.Buffer.from(json,"utf8"));return fsSnapshot.fromJsonSnapshotSync(uint8,{fs:this,path:path4})}};exports.Volume=Volume;Volume.fromJSON=(json,cwd2,opts)=>new Volume(fs_core_1.Superblock.fromJSON(json,cwd2,opts));Volume.fromNestedJSON=(json,cwd2,opts)=>new Volume(fs_core_1.Superblock.fromNestedJSON(json,cwd2,opts));function emitStop(self2){self2.emit("stop")}function buildZeroStats(bigint){let stats=new Stats_1.default,zero=bigint?BigInt(0):0,epoch=new Date(0);return stats.uid=zero,stats.gid=zero,stats.rdev=zero,stats.blksize=zero,stats.ino=zero,stats.size=zero,stats.blocks=zero,stats.atime=epoch,stats.mtime=epoch,stats.ctime=epoch,stats.birthtime=epoch,stats.atimeMs=zero,stats.mtimeMs=zero,stats.ctimeMs=zero,stats.birthtimeMs=zero,bigint&&(stats.atimeNs=zero,stats.mtimeNs=zero,stats.ctimeNs=zero,stats.birthtimeNs=zero),stats.dev=zero,stats.mode=zero,stats.nlink=zero,stats}var StatWatcher=class extends events_1.EventEmitter{constructor(vol){super(),this.bigint=!1,this.fileExists=!1,this.stopped=!1,this.onInterval=()=>{if(this.stopped)return;let stats=this.statSafe();if(stats)if(this.fileExists){if(this.hasChanged(stats)){let prev=this.prev;this.prev=stats,this.emit("change",stats,prev)}}else{this.fileExists=!0;let prev=this.prev;this.prev=stats,this.emit("change",stats,prev)}else this.fileExists&&(this.fileExists=!1,this.emit("change",buildZeroStats(this.bigint),this.prev));this.loop()},this.vol=vol}loop(){clearTimeout(this.timeoutRef),this.timeoutRef=this.setTimeout(this.onInterval,this.interval)}hasChanged(stats){let prev=this.prev;return stats.mtimeMs!==prev.mtimeMs||stats.ctimeMs!==prev.ctimeMs||stats.size!==prev.size||stats.ino!==prev.ino||stats.mode!==prev.mode||stats.uid!==prev.uid||stats.gid!==prev.gid||stats.nlink!==prev.nlink}statSafe(){try{return this.bigint?this.vol.statSync(this.filename,{bigint:!0}):this.vol.statSync(this.filename)}catch{return null}}start(path4,persistent=!0,interval=5007,bigint=!1){this.filename=(0,util_2.pathToFilename)(path4),this.setTimeout=persistent?setTimeout.bind(typeof globalThis<"u"?globalThis:global):setTimeoutUnref_1.default,this.interval=interval,this.bigint=bigint;let stats=this.statSafe();stats?(this.prev=stats,this.fileExists=!0):(this.prev=buildZeroStats(bigint),this.fileExists=!1,queueMicrotask(()=>{this.stopped||this.emit("change",this.prev,this.prev)})),this.loop()}stop(){this.stopped=!0,clearTimeout(this.timeoutRef),queueMicrotask(()=>{emitStop.call(this,this)})}ref(){this.setTimeout=setTimeout.bind(typeof globalThis<"u"?globalThis:global);let ref=this.timeoutRef;return ref&&typeof ref=="object"&&typeof ref.ref=="function"&&ref.ref(),this}unref(){this.setTimeout=setTimeoutUnref_1.default;let ref=this.timeoutRef;return ref&&typeof ref=="object"&&typeof ref.unref=="function"&&ref.unref(),this}};exports.StatWatcher=StatWatcher;var pool;function allocNewPool(poolSize){pool=(0,buffer_1.bufferAllocUnsafe)(poolSize),pool.used=0}(0,util_1.inherits)(FsReadStream,stream_1.Readable);exports.ReadStream=FsReadStream;function FsReadStream(vol,path4,options2){if(!(this instanceof FsReadStream))return new FsReadStream(vol,path4,options2);if(this._vol=vol,options2=Object.assign({},(0,options_1.getOptions)(options2,{})),options2.highWaterMark===void 0&&(options2.highWaterMark=64*1024),stream_1.Readable.call(this,options2),this.path=(0,util_2.pathToFilename)(path4),this._fileHandle=options2.fd&&typeof options2.fd!="number"?options2.fd:null,this.fd=options2.fd===void 0?null:typeof options2.fd!="number"?options2.fd.fd:options2.fd,this.flags=options2.flags===void 0?"r":options2.flags,this.mode=options2.mode===void 0?438:options2.mode,this.start=options2.start,this.end=options2.end,this.autoClose=options2.autoClose===void 0?!0:options2.autoClose,this.pos=void 0,this.bytesRead=0,this.start!==void 0){if(typeof this.start!="number")throw new TypeError('"start" option must be a Number');if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw new TypeError('"end" option must be a Number');if(this.start>this.end)throw new Error('"start" option must be <= "end" option');this.pos=this.start}typeof this.fd!="number"&&this.open(),this.on("end",function(){this.autoClose&&this.destroy&&this.destroy()})}FsReadStream.prototype.open=function(){var self2=this;this._vol.open(this.path,this.flags,this.mode,(er2,fd)=>{if(er2){self2.autoClose&&self2.destroy&&self2.destroy(),self2.emit("error",er2);return}self2.fd=fd,self2.emit("open",fd),self2.read()})};FsReadStream.prototype._read=function(n2){if(typeof this.fd!="number")return this.once("open",function(){this._read(n2)});if(this.destroyed)return;(!pool||pool.length-pool.used<kMinPoolSpace)&&allocNewPool(this._readableState.highWaterMark);var thisPool=pool,toRead=Math.min(pool.length-pool.used,n2),start=pool.used;if(this.pos!==void 0&&(toRead=Math.min(this.end-this.pos+1,toRead)),toRead<=0)return this.push(null);var self2=this;this._vol.read(this.fd,pool,pool.used,toRead,this.pos,onread),this.pos!==void 0&&(this.pos+=toRead),pool.used+=toRead;function onread(er2,bytesRead){if(er2)self2.autoClose&&self2.destroy&&self2.destroy(),self2.emit("error",er2);else{var b2=null;bytesRead>0&&(self2.bytesRead+=bytesRead,b2=thisPool.slice(start,start+bytesRead)),self2.push(b2)}}};FsReadStream.prototype._destroy=function(err,cb){this.close(err2=>{cb(err||err2)})};FsReadStream.prototype.close=function(cb){if(cb&&this.once("close",cb),this.closed||typeof this.fd!="number"){if(typeof this.fd!="number"){this.once("open",closeOnOpen);return}return queueMicrotask(()=>this.emit("close"))}typeof this._readableState?.closed=="boolean"?this._readableState.closed=!0:this.closed=!0,this._fileHandle?this._fileHandle.close().then(()=>this.emit("close"),er2=>this.emit("error",er2)):this._vol.close(this.fd,er2=>{er2?this.emit("error",er2):this.emit("close")}),this.fd=null};function closeOnOpen(fd){this.close()}(0,util_1.inherits)(FsWriteStream,stream_1.Writable);exports.WriteStream=FsWriteStream;function FsWriteStream(vol,path4,options2){if(!(this instanceof FsWriteStream))return new FsWriteStream(vol,path4,options2);if(this._vol=vol,options2=Object.assign({},(0,options_1.getOptions)(options2,{})),stream_1.Writable.call(this,options2),this.path=(0,util_2.pathToFilename)(path4),this._fileHandle=options2.fd&&typeof options2.fd!="number"?options2.fd:null,this.fd=options2.fd===void 0?null:typeof options2.fd!="number"?options2.fd.fd:options2.fd,this.flags=options2.flags===void 0?"w":options2.flags,this.mode=options2.mode===void 0?438:options2.mode,this.start=options2.start,this.autoClose=options2.autoClose===void 0?!0:!!options2.autoClose,this.pos=void 0,this.bytesWritten=0,this.pending=!0,this.start!==void 0){if(typeof this.start!="number")throw new TypeError('"start" option must be a Number');if(this.start<0)throw new Error('"start" must be >= zero');this.pos=this.start}options2.encoding&&this.setDefaultEncoding(options2.encoding),typeof this.fd!="number"&&this.open(),this.once("finish",function(){this.autoClose&&this.close()})}FsWriteStream.prototype.open=function(){this._vol.open(this.path,this.flags,this.mode,function(er2,fd){if(er2){this.autoClose&&this.destroy&&this.destroy(),this.emit("error",er2);return}this.fd=fd,this.pending=!1,this.emit("open",fd)}.bind(this))};FsWriteStream.prototype._write=function(data,encoding,cb){if(!(data instanceof buffer_1.Buffer||data instanceof Uint8Array))return this.emit("error",new Error("Invalid data"));if(typeof this.fd!="number")return this.once("open",function(){this._write(data,encoding,cb)});var self2=this;this._vol.write(this.fd,data,0,data.length,this.pos,(er2,bytes)=>{if(er2)return self2.autoClose&&self2.destroy&&self2.destroy(),cb(er2);self2.bytesWritten+=bytes,cb()}),this.pos!==void 0&&(this.pos+=data.length)};FsWriteStream.prototype._writev=function(data,cb){if(typeof this.fd!="number")return this.once("open",function(){this._writev(data,cb)});let self2=this,len=data.length,chunks=new Array(len);for(var size=0,i2=0;i2<len;i2++){var chunk=data[i2].chunk;chunks[i2]=chunk,size+=chunk.length}let buf=buffer_1.Buffer.concat(chunks);this._vol.write(this.fd,buf,0,buf.length,this.pos,(er2,bytes)=>{if(er2)return self2.destroy&&self2.destroy(),cb(er2);self2.bytesWritten+=bytes,cb()}),this.pos!==void 0&&(this.pos+=size)};FsWriteStream.prototype.close=function(cb){if(cb&&this.once("close",cb),this.closed||typeof this.fd!="number"){if(typeof this.fd!="number"){this.once("open",closeOnOpen);return}return queueMicrotask(()=>this.emit("close"))}typeof this._writableState?.closed=="boolean"?this._writableState.closed=!0:this.closed=!0,this._fileHandle?this._fileHandle.close().then(()=>this.emit("close"),er2=>this.emit("error",er2)):this._vol.close(this.fd,er2=>{er2?this.emit("error",er2):this.emit("close")}),this.fd=null};FsWriteStream.prototype._destroy=FsReadStream.prototype._destroy;FsWriteStream.prototype.destroySoon=FsWriteStream.prototype.end;var FSWatcher=class extends events_1.EventEmitter{constructor(vol){super(),this._filename="",this._filenameEncoded="",this._recursive=!1,this._encoding=fs_node_utils_1.ENCODING_UTF8,this._closed=!1,this._onEvent=event=>{switch(event.type){case 0:case 1:this._emit("rename",event.steps);break;case 4:event.oldSteps&&this._emit("rename",event.oldSteps),this._emit("rename",event.steps);break;case 2:case 3:this._emit("change",event.steps);break}},this._persist=()=>{this._timer=setTimeout(this._persist,1e6)},this._vol=vol}_emit(type,relativeSteps){let filename=relativeSteps.length?relativeSteps.join(fs_node_utils_2.pathSep):this._watcher.link.getName();this._ignore&&this._ignore(filename)||this.emit("change",type,(0,fs_node_utils_1.strToEncoding)(filename,this._encoding))}ref(){return this._watcher&&!this._closed&&!this._timer&&this._persist(),this}unref(){return clearTimeout(this._timer),this._timer=void 0,this}start(path4,persistent=!0,recursive=!1,encoding=fs_node_utils_1.ENCODING_UTF8,ignore3){this._filename=(0,util_2.pathToFilename)(path4),this._steps=(0,fs_core_1.filenameToSteps)(this._filename),this._filenameEncoded=(0,fs_node_utils_1.strToEncoding)(this._filename),this._recursive=recursive,this._encoding=encoding,this._ignore=ignore3===void 0?void 0:(0,fs_node_utils_1.watchIgnoreToMatcher)(ignore3);try{this._watcher=new fs_core_1.CoreWatcher(this._vol._core,this._filename,{recursive})}catch(err){throw(0,util_2.createWatchError)(err.code,this._filename)}this._link=this._watcher.link,this._watcher.changes.listen(this._onEvent),persistent&&this._persist()}close(){clearTimeout(this._timer),this._timer=void 0,!(!this._watcher||this._closed)&&(this._closed=!0,this._watcher.close(),queueMicrotask(()=>this.emit("close")))}};exports.FSWatcher=FSWatcher}});var require_lib10=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsCommonObjectsList=exports.fsSynchronousApiList=exports.fsCallbackApiList=exports.FsPromises=exports.Dir=exports.FileHandle=exports.StatFs=exports.Dirent=exports.Stats=exports.toUnixTimestamp=exports.FSWatcher=exports.StatWatcher=exports.Volume=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports)),volume_1=require_volume();Object.defineProperty(exports,"Volume",{enumerable:!0,get:function(){return volume_1.Volume}});Object.defineProperty(exports,"StatWatcher",{enumerable:!0,get:function(){return volume_1.StatWatcher}});Object.defineProperty(exports,"FSWatcher",{enumerable:!0,get:function(){return volume_1.FSWatcher}});Object.defineProperty(exports,"toUnixTimestamp",{enumerable:!0,get:function(){return volume_1.toUnixTimestamp}});var Stats_1=require_Stats();Object.defineProperty(exports,"Stats",{enumerable:!0,get:function(){return Stats_1.default}});var Dirent_1=require_Dirent();Object.defineProperty(exports,"Dirent",{enumerable:!0,get:function(){return Dirent_1.default}});var StatFs_1=require_StatFs();Object.defineProperty(exports,"StatFs",{enumerable:!0,get:function(){return StatFs_1.default}});var FileHandle_1=require_FileHandle();Object.defineProperty(exports,"FileHandle",{enumerable:!0,get:function(){return FileHandle_1.FileHandle}});var Dir_1=require_Dir();Object.defineProperty(exports,"Dir",{enumerable:!0,get:function(){return Dir_1.Dir}});var FsPromises_1=require_FsPromises();Object.defineProperty(exports,"FsPromises",{enumerable:!0,get:function(){return FsPromises_1.FsPromises}});tslib_1.__exportStar(require_options(),exports);tslib_1.__exportStar(require_util2(),exports);tslib_1.__exportStar(require_glob(),exports);var fs_node_utils_1=require_lib5();Object.defineProperty(exports,"fsCallbackApiList",{enumerable:!0,get:function(){return fs_node_utils_1.fsCallbackApiList}});Object.defineProperty(exports,"fsSynchronousApiList",{enumerable:!0,get:function(){return fs_node_utils_1.fsSynchronousApiList}});Object.defineProperty(exports,"fsCommonObjectsList",{enumerable:!0,get:function(){return fs_node_utils_1.fsCommonObjectsList}})}});var require_lib11=__commonJS({"node_modules/.pnpm/memfs@4.80.0/node_modules/memfs/lib/index.js"(exports,module){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.memfs=exports.fs=exports.vol=exports.Volume=void 0;exports.createFsFromVolume=createFsFromVolume;var fs_node_1=require_lib10();Object.defineProperty(exports,"Volume",{enumerable:!0,get:function(){return fs_node_1.Volume}});var fs_node_utils_1=require_lib5(),{F_OK,R_OK,W_OK,X_OK}=fs_node_utils_1.constants,getGlobalProcess=()=>(typeof globalThis<"u"?globalThis.process:void 0)??{},createProcess=(cwd2,baseProcess=getGlobalProcess())=>({cwd:()=>cwd2,platform:baseProcess.platform??"linux",emitWarning:baseProcess.emitWarning?.bind(baseProcess)??(()=>{}),env:baseProcess.env??{},getuid:baseProcess.getuid?.bind(baseProcess),getgid:baseProcess.getgid?.bind(baseProcess)});exports.vol=fs_node_1.Volume.fromNestedJSON({},"/",{process:createProcess("/")});var kStreams=Symbol("streams"),streamSlot=index4=>({get(){return this[kStreams][index4]},set(value2){this[kStreams][index4]=value2},enumerable:!0,configurable:!0}),streamDescriptors={ReadStream:streamSlot(0),WriteStream:streamSlot(1),FileReadStream:streamSlot(2),FileWriteStream:streamSlot(3)};function createFsFromVolume(vol){let fs2={F_OK,R_OK,W_OK,X_OK,constants:fs_node_utils_1.constants,Stats:fs_node_1.Stats,Dir:fs_node_1.Dir,Dirent:fs_node_1.Dirent};for(let method of fs_node_1.fsSynchronousApiList)typeof vol[method]=="function"&&(fs2[method]=vol[method].bind(vol));for(let method of fs_node_1.fsCallbackApiList)typeof vol[method]=="function"&&(fs2[method]=vol[method].bind(vol));return fs2.StatWatcher=vol.StatWatcher,fs2.FSWatcher=vol.FSWatcher,fs2[kStreams]=[vol.ReadStream,vol.WriteStream,vol.ReadStream,vol.WriteStream],Object.defineProperties(fs2,streamDescriptors),fs2.promises=vol.promises,typeof vol.realpath=="function"&&(fs2.realpath=vol.realpath.bind(vol),typeof vol.realpath.native=="function"&&(fs2.realpath.native=vol.realpath.native.bind(vol))),typeof vol.realpathSync=="function"&&(fs2.realpathSync=vol.realpathSync.bind(vol),typeof vol.realpathSync.native=="function"&&(fs2.realpathSync.native=vol.realpathSync.native.bind(vol))),fs2._toUnixTimestamp=fs_node_1.toUnixTimestamp,fs2.__vol=vol,fs2}exports.fs=createFsFromVolume(exports.vol);var memfs=(json={},cwdOrOpts="/")=>{let opts=typeof cwdOrOpts=="string"?{cwd:cwdOrOpts}:cwdOrOpts,cwd2=opts.cwd??(opts.process?void 0:"/"),process2=opts.process??createProcess(cwd2??"/"),vol=fs_node_1.Volume.fromNestedJSON(json,cwd2,{process:process2});return{fs:createFsFromVolume(vol),vol}};exports.memfs=memfs;module.exports={...module.exports,...exports.fs};module.exports.semantic=!0}});var require_ignore2=__commonJS({"node_modules/.pnpm/ignore@7.0.14/node_modules/ignore/index.js"(exports,module){init_browser_globals();function makeArray(subject){return Array.isArray(subject)?subject:[subject]}var UNDEFINED=void 0,EMPTY="",SPACE=" ",ESCAPE="\\",REGEX_LITERAL_SPECIAL=/[.*+?()[\]{}^$|\\/]/,BOM2="\uFEFF",REGEX_INVALID_TRAILING_BACKSLASH=/(?:[^\\]|^)\\$/,REGEX_ANCHORED_GLOBSTAR=/^\/\*{2,}$/,REGEX_REPLACE_LEADING_EXCAPED_EXCLAMATION=/^\\!/,REGEX_REPLACE_LEADING_EXCAPED_HASH=/^\\#/,REGEX_SPLITALL_CRLF=/\r?\n/g,DOUBLE_SLASH="//",SLASH_CODE=47,DOT_CODE=46,SLASH="/",TMP_KEY_IGNORE="node-ignore";typeof Symbol<"u"&&(TMP_KEY_IGNORE=Symbol.for("node-ignore"));var KEY_IGNORE=TMP_KEY_IGNORE,define2=(object,key,value2)=>(Object.defineProperty(object,key,{value:value2}),value2),RETURN_FALSE=()=>!1,POSIX_CLASSES={alnum:"0-9A-Za-z",alpha:"A-Za-z",blank:" \\t",cntrl:"\\x00-\\x1f\\x7f",digit:"0-9",graph:"!-.0-~",lower:"a-z",print:" -.0-~",punct:"!-.:-@\\[-`{-~",space:" \\t\\n\\r",upper:"A-Z",xdigit:"0-9A-Fa-f"},CLASS_MEMBERS_TO_ESCAPE="\\]^-[",escapeMember=char=>CLASS_MEMBERS_TO_ESCAPE.indexOf(char)<0?char:ESCAPE+char,NON_SLASH="(?!\\/)",classSource=(negated,body)=>{if(negated)return`[^\\/${body}]`;let source2=`[${body}]`;return new RegExp(source2).test("/")?NON_SLASH+source2:source2},scanBracket=(pattern,start)=>{let{length}=pattern,index4=start+1,negated=EMPTY,lead=pattern[index4];(lead==="!"||lead==="^")&&(negated="^",index4++);let body=EMPTY,prev=EMPTY;for(;;){let char=pattern[index4];if(char===UNDEFINED)return null;if(char===ESCAPE){let escaped=pattern[index4+1];if(escaped===UNDEFINED)return null;body+=escapeMember(escaped),prev=escaped,index4++}else if(char==="-"&&prev&&index4+1<length&&pattern[index4+1]!=="]"){index4++;let to=pattern[index4];to===ESCAPE&&(to=pattern[index4+=1]),prev<=to&&(body+=`-${escapeMember(to)}`),prev=EMPTY}else if(char==="["&&pattern[index4+1]===":"){let nameStart=index4+2,end=nameStart;for(;end<length&&pattern[end]!=="]";)end++;if(end===length)return null;if(end>nameStart&&pattern[end-1]===":"){let name=pattern.slice(nameStart,end-1);if(!Object.prototype.hasOwnProperty.call(POSIX_CLASSES,name))return null;body+=POSIX_CLASSES[name],prev=EMPTY,index4=end}else body+=escapeMember("["),prev="[",index4=nameStart-2}else body+=escapeMember(char),prev=char;if(index4++,pattern[index4]==="]")return{end:index4,source:classSource(negated,body)}}},NEVER_MATCH="[]",PLACEHOLDER="\0",REGEX_RESTORE_PLACEHOLDER=new RegExp(`${PLACEHOLDER}(\\d+)${PLACEHOLDER}`,"g"),TRAILING_WILDCARD="\uE000",TRAILING_DOUBLESTAR="\uE001",isReserved=char=>char===PLACEHOLDER||char===TRAILING_WILDCARD||char===TRAILING_DOUBLESTAR,extractBrackets=pattern=>{let sources=[],hold=source2=>`${PLACEHOLDER}${sources.push(source2)-1}${PLACEHOLDER}`,{length}=pattern,out=EMPTY,index4=0;for(;index4<length;){let char=pattern[index4];if(char===ESCAPE){let escaped=pattern[index4+1];escaped===UNDEFINED||escaped===SLASH&&index4+2===length?out+=hold(NEVER_MATCH):escaped==="*"||escaped==="["||escaped===SPACE?out+=pattern.slice(index4,index4+2):out+=hold(REGEX_LITERAL_SPECIAL.test(escaped)?ESCAPE+escaped:isReserved(escaped)?`[${escaped}]`:escaped),index4+=2}else if(isReserved(char))out+=hold(`[${char}]`),index4++;else if(char==="["){let scanned=scanBracket(pattern,index4);scanned===null?(out+=hold(NEVER_MATCH),index4=length):(out+=hold(scanned.source),index4=scanned.end+1)}else out+=char,index4++}return{source:out,sources}},DIRECT=null,REGEX_INNER_SLASH=/\/(?!$)/,REPLACERS=[[/(\\+)( ?)/g,(_2,run,space)=>space?run.slice(0,run.length-run.length%2)+SPACE:run,ESCAPE+SPACE],[/(^|\/)\*{3,}(?=\/|$)/g,(_2,start)=>`${start}**`,"*"],[/[\\$.|*+(){^]/g,match=>`\\${match}`],[/(?!\\)\?/g,()=>"[^/]","?"],[/^\//,()=>"^",SLASH],[/\//g,()=>"\\/",SLASH],[/^\^*(?:\\\*\\\*\\\/)+/,()=>"^(?:.*\\/)?","*"],[DIRECT,(source2,pattern)=>!source2||source2[0]==="^"?source2:(REGEX_INNER_SLASH.test(pattern)?"^":"(?:^|\\/)")+source2],[/\\\/\\\*\\\*(?=\\\/|$)/g,(_2,index4,str)=>index4+6<str.length?str.slice(index4+6)==="\\/"?"(?:\\/[^\\/]+)+":"(?:\\/[^\\/]+)*":`\\/${TRAILING_DOUBLESTAR}`,"*"],[/(^|[^\\]+)(\\\*)+(?=.+)/g,(_2,p1,p2)=>{let unescaped=p2.replace(/\\\*/g,"[^\\/]*");return p1+unescaped},"*"],[/(^|[^\\])((?:\\\\)*)\\\*$/,(match,p1,p2)=>p2===EMPTY?p1+TRAILING_WILDCARD:match,"*"],[/\\\\\\(?=[$.|*+(){^])/g,()=>ESCAPE,ESCAPE+ESCAPE],[/\\\\/g,()=>ESCAPE,ESCAPE+ESCAPE],[/\\\[([^\]/]*?)($|\])/g,(match,range,close2)=>`\\[${range}${close2}`,"["],[DIRECT,source2=>{let last=source2[source2.length-1];return!last||last===TRAILING_WILDCARD||last===TRAILING_DOUBLESTAR?source2:last===SLASH?`${source2}$`:`${source2}(?=$|\\/$)`}]],REGEX_REPLACE_TRAILING_WILDCARD=/(^|\\\/)?\uE000$/,MODE_IGNORE="regex",MODE_CHECK_IGNORE="checkRegex",UNDERSCORE="_",replaceTrailingWildcard=(_2,p1)=>`${p1?`${p1}[^/]+`:"[^/]*"}(?=$|\\/$)`,REGEX_REPLACE_TRAILING_DOUBLESTAR=/\uE001$/,replaceTrailingDoublestar=()=>".+(?=$|\\/$)",WILDCARD="[^\\/]*",separatorAfter=(run,at2)=>{let separator=EMPTY;for(let index4=at2+1;index4<run.length&&!run[index4].wildcard;index4++)separator+=run[index4].single;return separator},pinWildcards=source2=>{if(source2.indexOf(WILDCARD)<0)return source2;let tokens=[],{length}=source2,index4=0;for(;index4<length;){let char=source2[index4];if(source2.startsWith(WILDCARD,index4))tokens.push({wildcard:!0}),index4+=WILDCARD.length;else if(char==="["){let end=index4+1;for(source2[end]==="^"&&end++,source2[end]==="]"&&end++;end<length&&source2[end]!=="]";)end+=source2[end]===ESCAPE?2:1;end++,tokens.push({single:source2.slice(index4,end)}),index4=end}else if(char===ESCAPE)tokens.push({single:source2.slice(index4,index4+2)}),index4+=2;else if(char==="("){let depth=0,end=index4;do source2[end]===ESCAPE?end++:source2[end]==="("?depth++:source2[end]===")"&&depth--,end++;while(end<length&&depth>0);"*+?".indexOf(source2[end])>=0&&end++,tokens.push({boundary:source2.slice(index4,end)}),index4=end}else char==="^"||char==="$"?(tokens.push({boundary:char}),index4++):(tokens.push({single:char}),index4++)}let out=EMPTY,run=[],flush=()=>{let lastWildcard;run.forEach((token,at2)=>{token.wildcard&&(lastWildcard=at2)}),run.forEach((token,at2)=>{if(!token.wildcard){out+=token.single;return}out+=at2===lastWildcard?WILDCARD:`(?:(?!${separatorAfter(run,at2)})[^\\/])*`}),run=[]};return tokens.forEach(token=>{if(token.boundary===void 0){run.push(token);return}flush(),out+=token.boundary}),flush(),out},makeRegexPrefix=pattern=>{REGEX_ANCHORED_GLOBSTAR.test(pattern)&&(pattern="**");let{source:source2,sources}=extractBrackets(pattern),replaced=REPLACERS.reduce((prev,[matcher,replacer,required])=>matcher===DIRECT?replacer(prev,pattern):required!==UNDEFINED&&prev.indexOf(required)<0?prev:matcher.test(prev)?prev.replace(matcher,replacer.bind(pattern)):prev,source2);return sources.length?replaced.replace(REGEX_RESTORE_PLACEHOLDER,(match,index4)=>sources[index4]):replaced},checkSourceOf=(body,prefix)=>{body[body.length-1]===SLASH&&(prefix=makeRegexPrefix(body.slice(0,-1)));let head=prefix.slice(0,-1),last=prefix[prefix.length-1];return last===TRAILING_WILDCARD?`${head}$`:last===TRAILING_DOUBLESTAR?`${head}.*$`:NEVER_MATCH},matchesBasename=body=>{let index4=body.indexOf(SLASH);return index4<0||index4===body.length-1},basenameOf=path4=>{let end=path4.length-1,index4=path4.lastIndexOf(SLASH,path4[end]===SLASH?end-1:end);return index4<0?path4:path4.slice(index4+1)},parentOf=path4=>{if(path4.charCodeAt(0)===SLASH_CODE||path4.indexOf(DOUBLE_SLASH)>=0){let slices=path4.split(SLASH).filter(Boolean);return slices.pop(),slices.length?slices.join(SLASH)+SLASH:EMPTY}let end=path4.length-1,cut=path4.lastIndexOf(SLASH,path4.charCodeAt(end)===SLASH_CODE?end-1:end);return cut<0?EMPTY:path4.slice(0,cut+1)},isString2=subject=>typeof subject=="string",checkPattern=pattern=>pattern&&isString2(pattern)&&!REGEX_INVALID_TRAILING_BACKSLASH.test(pattern),splitPattern=pattern=>pattern.split(REGEX_SPLITALL_CRLF).filter(Boolean),IgnoreRule=class{constructor(pattern,mark,body,ignoreCase,negative,prefix){this.pattern=pattern,this.mark=mark,this.negative=negative,define2(this,"body",body),define2(this,"ignoreCase",ignoreCase),define2(this,"regexPrefix",prefix)}get _basenameOnly(){return define2(this,"_basenameOnly",matchesBasename(this.body))}get regex(){let key=UNDERSCORE+MODE_IGNORE;return this[key]?this[key]:this._make(MODE_IGNORE,key)}get checkRegex(){let key=UNDERSCORE+MODE_CHECK_IGNORE;return this[key]?this[key]:this._make(MODE_CHECK_IGNORE,key)}_make(mode,key){let str=pinWildcards(mode===MODE_IGNORE?this.regexPrefix.replace(REGEX_REPLACE_TRAILING_WILDCARD,replaceTrailingWildcard).replace(REGEX_REPLACE_TRAILING_DOUBLESTAR,replaceTrailingDoublestar):checkSourceOf(this.body,this.regexPrefix)),regex=this.ignoreCase?new RegExp(str,"i"):new RegExp(str);return define2(this,key,regex)}},isLineEnd=char=>char==="\r"||char===`
|
|
48
|
+
`;case"\\r":return"\r";case"\\t":return" ";case'\\"':return'"';case"\\/":return"/";case"\\\\":return"\\"}return char},hasBinaryPrefix=(u8,x2)=>u8[x2]===100&&u8[x2+1]===97&&u8[x2+2]===116&&u8[x2+3]===97&&u8[x2+4]===58&&u8[x2+5]===97&&u8[x2+6]===112&&u8[x2+7]===112&&u8[x2+8]===108&&u8[x2+9]===105&&u8[x2+10]===99&&u8[x2+11]===97&&u8[x2+12]===116&&u8[x2+13]===105&&u8[x2+14]===111&&u8[x2+15]===110&&u8[x2+16]===47&&u8[x2+17]===111&&u8[x2+18]===99&&u8[x2+19]===116&&u8[x2+20]===101&&u8[x2+21]===116&&u8[x2+22]===45&&u8[x2+23]===115&&u8[x2+24]===116&&u8[x2+25]===114&&u8[x2+26]===101&&u8[x2+27]===97&&u8[x2+28]===109&&u8[x2+29]===59&&u8[x2+30]===98&&u8[x2+31]===97&&u8[x2+32]===115&&u8[x2+33]===101&&u8[x2+34]===54&&u8[x2+35]===52&&u8[x2+36]===44,isUndefined=(u8,x2)=>u8[x2++]===97&&u8[x2++]===116&&u8[x2++]===97&&u8[x2++]===58&&u8[x2++]===97&&u8[x2++]===112&&u8[x2++]===112&&u8[x2++]===108&&u8[x2++]===105&&u8[x2++]===99&&u8[x2++]===97&&u8[x2++]===116&&u8[x2++]===105&&u8[x2++]===111&&u8[x2++]===110&&u8[x2++]===47&&u8[x2++]===99&&u8[x2++]===98&&u8[x2++]===111&&u8[x2++]===114&&u8[x2++]===44&&u8[x2++]===98&&u8[x2++]===97&&u8[x2++]===115&&u8[x2++]===101&&u8[x2++]===54&&u8[x2++]===52&&u8[x2++]===59&&u8[x2++]===57&&u8[x2++]===119&&u8[x2++]===61&&u8[x2++]===61&&u8[x2++]===34,fromCharCode=String.fromCharCode,readKey=reader=>{let buf=reader.uint8,len=buf.length,points=[],x2=reader.x,prev=0;for(;x2<len;){let code4=buf[x2++];if((code4&128)===0)if(prev===92){switch(code4){case 98:code4=8;break;case 102:code4=12;break;case 110:code4=10;break;case 114:code4=13;break;case 116:code4=9;break;case 34:code4=34;break;case 47:code4=47;break;case 92:code4=92;break;default:throw new Error("Invalid JSON")}prev=0}else{if(code4===34)break;if(prev=code4,prev===92)continue}else{let octet2=buf[x2++]&63;if((code4&224)===192)code4=(code4&31)<<6|octet2;else{let octet3=buf[x2++]&63;if((code4&240)===224)code4=(code4&31)<<12|octet2<<6|octet3;else if((code4&248)===240){let octet4=buf[x2++]&63,unit=(code4&7)<<18|octet2<<12|octet3<<6|octet4;if(unit>65535){unit-=65536;let unit0=unit>>>10&1023|55296;unit=56320|unit&1023,points.push(unit0),code4=unit}else code4=unit}}}points.push(code4)}return reader.x=x2,fromCharCode.apply(String,points)};exports.readKey=readKey;var JsonDecoder=class{constructor(){this.reader=new Reader_1.Reader}read(uint8){return this.reader.reset(uint8),this.readAny()}decode(uint8){return this.reader.reset(uint8),this.readAny()}readAny(){this.skipWhitespace();let reader=this.reader,x2=reader.x,uint8=reader.uint8,char=uint8[x2];switch(char){case 34:{if(uint8[x2+1]===100){let bin=this.tryReadBin();if(bin)return bin;if(isUndefined(uint8,x2+2)){reader.x=x2+35;return}}return this.readStr()}case 91:return this.readArr();case 102:return this.readFalse();case 110:return this.readNull();case 116:return this.readTrue();case 123:return this.readObj();default:if(char>=48&&char<=57||char===45)return this.readNum();throw new Error("Invalid JSON")}}skipWhitespace(){let reader=this.reader,uint8=reader.uint8,x2=reader.x,char=0;for(;;)switch(char=uint8[x2],char){case 32:case 9:case 10:case 13:x2++;continue;default:reader.x=x2;return}}readNull(){if(this.reader.u32()!==1853189228)throw new Error("Invalid JSON");return null}readTrue(){if(this.reader.u32()!==1953658213)throw new Error("Invalid JSON");return!0}readFalse(){let reader=this.reader;if(reader.u8()!==102||reader.u32()!==1634497381)throw new Error("Invalid JSON");return!1}readBool(){let reader=this.reader;switch(reader.uint8[reader.x]){case 102:return this.readFalse();case 116:return this.readTrue();default:throw new Error("Invalid JSON")}}readNum(){let reader=this.reader,uint8=reader.uint8,x2=reader.x,c2=uint8[x2++],c1=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c22=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c3=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c4=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c5=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c6=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c7=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c8=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c9=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c10=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c11=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c12=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c13=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c14=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c15=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c16=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c17=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c18=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c19=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c20=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c21=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c222=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21,c222);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c23=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21,c222,c23);if(num3!==num3)throw new Error("Invalid JSON");return num3}let c24=c2;if(c2=uint8[x2++],!c2||(c2<45||c2>57)&&c2!==43&&c2!==69&&c2!==101){reader.x=x2-1;let num3=+fromCharCode(c1,c22,c3,c4,c5,c6,c7,c8,c9,c10,c11,c12,c13,c14,c15,c16,c17,c18,c19,c20,c21,c222,c23,c24);if(num3!==num3)throw new Error("Invalid JSON");return num3}throw new Error("Invalid JSON")}readStr(){let reader=this.reader,uint8=reader.uint8;if(uint8[reader.x++]!==34)throw new Error("Invalid JSON");let x0=reader.x,x1=(0,util_1.findEndingQuote)(uint8,x0),str=(0,decodeUtf8_1.decodeUtf8)(uint8,x0,x1-x0);return str=str.replace(REGEX_REPLACE_ESCAPED_CHARS,escapedCharReplacer),reader.x=x1+1,str}tryReadBin(){let reader=this.reader,u8=reader.uint8,x2=reader.x;if(u8[x2++]!==34||!hasBinaryPrefix(u8,x2))return;x2+=37;let x0=x2;x2=(0,util_1.findEndingQuote)(u8,x2),reader.x=x0;let bin=(0,fromBase64Bin_1.fromBase64Bin)(reader.view,x0,x2-x0);return reader.x=x2+1,bin}readBin(){let reader=this.reader,u8=reader.uint8,x2=reader.x;if(u8[x2++]!==34)throw new Error("Invalid JSON");if(!hasBinaryPrefix(u8,x2))throw new Error("Invalid JSON");x2+=37;let x0=x2;x2=(0,util_1.findEndingQuote)(u8,x2),reader.x=x0;let bin=(0,fromBase64Bin_1.fromBase64Bin)(reader.view,x0,x2-x0);return reader.x=x2+1,bin}readArr(){let reader=this.reader;if(reader.u8()!==91)throw new Error("Invalid JSON");let arr=[],uint8=reader.uint8,first=!0;for(;;){this.skipWhitespace();let char=uint8[reader.x];if(char===93)return reader.x++,arr;if(char===44)reader.x++;else if(!first)throw new Error("Invalid JSON");this.skipWhitespace(),arr.push(this.readAny()),first=!1}}readObj(){let reader=this.reader;if(reader.u8()!==123)throw new Error("Invalid JSON");let obj={},uint8=reader.uint8,first=!0;for(;;){this.skipWhitespace();let char=uint8[reader.x];if(char===125)return reader.x++,obj;if(char===44)reader.x++;else if(!first)throw new Error("Invalid JSON");if(this.skipWhitespace(),char=uint8[reader.x++],char!==34)throw new Error("Invalid JSON");let key=(0,exports.readKey)(reader);if(key==="__proto__")throw new Error("Invalid JSON");if(this.skipWhitespace(),reader.u8()!==58)throw new Error("Invalid JSON");this.skipWhitespace(),obj[key]=this.readAny(),first=!1}}};exports.JsonDecoder=JsonDecoder}});var require_json2=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/json.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fromJsonSnapshot=exports.toJsonSnapshot=exports.fromJsonSnapshotSync=exports.toJsonSnapshotSync=void 0;var JsonEncoder_1=require_JsonEncoder(),JsonDecoder_1=require_JsonDecoder(),sync_1=require_sync(),async_1=require_async(),shared_1=require_shared(),encoder=new JsonEncoder_1.JsonEncoder(shared_1.writer),decoder=new JsonDecoder_1.JsonDecoder,toJsonSnapshotSync=options2=>{let snapshot=(0,sync_1.toSnapshotSync)(options2);return encoder.encode(snapshot)};exports.toJsonSnapshotSync=toJsonSnapshotSync;var fromJsonSnapshotSync=(uint8,options2)=>{let snapshot=decoder.read(uint8);(0,sync_1.fromSnapshotSync)(snapshot,options2)};exports.fromJsonSnapshotSync=fromJsonSnapshotSync;var toJsonSnapshot=async options2=>{let snapshot=await(0,async_1.toSnapshot)(options2);return encoder.encode(snapshot)};exports.toJsonSnapshot=toJsonSnapshot;var fromJsonSnapshot=async(uint8,options2)=>{let snapshot=decoder.read(uint8);await(0,async_1.fromSnapshot)(snapshot,options2)};exports.fromJsonSnapshot=fromJsonSnapshot}});var require_lib9=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-snapshot@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-snapshot/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports));tslib_1.__exportStar(require_constants4(),exports);tslib_1.__exportStar(require_sync(),exports);tslib_1.__exportStar(require_binary(),exports);tslib_1.__exportStar(require_json2(),exports)}});var require_options=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/options.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.getWriteFileOptions=exports.writeFileDefaults=exports.getRealpathOptsAndCb=exports.getRealpathOptions=exports.getStatfsOptsAndCb=exports.getStatfsOptions=exports.getStatOptsAndCb=exports.getStatOptions=exports.getAppendFileOptsAndCb=exports.getAppendFileOpts=exports.getOpendirOptsAndCb=exports.getOpendirOptions=exports.getReaddirOptsAndCb=exports.getReaddirOptions=exports.getReadFileOptions=exports.getRmOptsAndCb=exports.getRmdirOptions=exports.getDefaultOptsAndCb=exports.getDefaultOpts=exports.optsDefaults=exports.getMkdirOptions=void 0;exports.getOptions=getOptions;exports.optsGenerator=optsGenerator;exports.optsAndCbGenerator=optsAndCbGenerator;var fs_node_utils_1=require_lib5(),util_1=require_util2(),mkdirDefaults={mode:511,recursive:!1},getMkdirOptions=options2=>typeof options2=="number"?Object.assign({},mkdirDefaults,{mode:options2}):Object.assign({},mkdirDefaults,options2);exports.getMkdirOptions=getMkdirOptions;var ERRSTR_OPTS=tipeof=>`Expected options to be either an object or a string, but got ${tipeof} instead`;function getOptions(defaults,options2){let opts;if(options2){let tipeof=typeof options2;switch(tipeof){case"string":opts=Object.assign({},defaults,{encoding:options2});break;case"object":opts=Object.assign({},defaults,options2);break;default:throw TypeError(ERRSTR_OPTS(tipeof))}}else return defaults;return opts.encoding!=="buffer"&&(0,fs_node_utils_1.assertEncoding)(opts.encoding),opts}function optsGenerator(defaults){return options2=>getOptions(defaults,options2)}function optsAndCbGenerator(getOpts){return(options2,callback)=>typeof options2=="function"?[getOpts(),options2]:[getOpts(options2),(0,util_1.validateCallback)(callback)]}exports.optsDefaults={encoding:"utf8"};exports.getDefaultOpts=optsGenerator(exports.optsDefaults);exports.getDefaultOptsAndCb=optsAndCbGenerator(exports.getDefaultOpts);var rmdirDefaults={recursive:!1},getRmdirOptions=options2=>Object.assign({},rmdirDefaults,options2);exports.getRmdirOptions=getRmdirOptions;var getRmOpts=optsGenerator(exports.optsDefaults);exports.getRmOptsAndCb=optsAndCbGenerator(getRmOpts);var readFileOptsDefaults={flag:"r"};exports.getReadFileOptions=optsGenerator(readFileOptsDefaults);var readdirDefaults={encoding:"utf8",recursive:!1,withFileTypes:!1};exports.getReaddirOptions=optsGenerator(readdirDefaults);exports.getReaddirOptsAndCb=optsAndCbGenerator(exports.getReaddirOptions);var opendirDefaults={encoding:"utf8",bufferSize:32,recursive:!1};exports.getOpendirOptions=optsGenerator(opendirDefaults);exports.getOpendirOptsAndCb=optsAndCbGenerator(exports.getOpendirOptions);var appendFileDefaults={encoding:"utf8",mode:438,flag:fs_node_utils_1.FLAGS[fs_node_utils_1.FLAGS.a]};exports.getAppendFileOpts=optsGenerator(appendFileDefaults);exports.getAppendFileOptsAndCb=optsAndCbGenerator(exports.getAppendFileOpts);var statDefaults={bigint:!1},getStatOptions=(options2={})=>Object.assign({},statDefaults,options2);exports.getStatOptions=getStatOptions;var getStatOptsAndCb=(options2,callback)=>typeof options2=="function"?[(0,exports.getStatOptions)(),options2]:[(0,exports.getStatOptions)(options2),(0,util_1.validateCallback)(callback)];exports.getStatOptsAndCb=getStatOptsAndCb;var statfsDefaults={bigint:!1},getStatfsOptions=(options2={})=>Object.assign({},statfsDefaults,options2);exports.getStatfsOptions=getStatfsOptions;var getStatfsOptsAndCb=(options2,callback)=>typeof options2=="function"?[(0,exports.getStatfsOptions)(),options2]:[(0,exports.getStatfsOptions)(options2),(0,util_1.validateCallback)(callback)];exports.getStatfsOptsAndCb=getStatfsOptsAndCb;var realpathDefaults=exports.optsDefaults;exports.getRealpathOptions=optsGenerator(realpathDefaults);exports.getRealpathOptsAndCb=optsAndCbGenerator(exports.getRealpathOptions);exports.writeFileDefaults={encoding:"utf8",mode:438,flag:fs_node_utils_1.FLAGS[fs_node_utils_1.FLAGS.w]};exports.getWriteFileOptions=optsGenerator(exports.writeFileDefaults)}});var require_Dir=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/Dir.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.Dir=void 0;var fs_node_utils_1=require_lib5(),argErrors_1=require_argErrors(),validators_1=require_validators(),Dirent_1=require_Dirent(),util_1=require_util2(),DEFAULT_ENCODING={encoding:"utf8"},dirClosed=()=>(0,argErrors_1.withCode)(new Error("Directory handle was closed"),"ERR_DIR_CLOSED"),dirBusy=()=>(0,argErrors_1.withCode)(new Error("Cannot do synchronous work on directory handle with concurrent asynchronous operations"),"ERR_DIR_CONCURRENT_OPERATION"),Dir=class _Dir{constructor(handle2,path4,options2){if(this.levels=[],this.closed=!1,this.operationQueue=null,handle2==null)throw(0,argErrors_1.withCode)(new TypeError('The "handle" argument must be specified'),"ERR_MISSING_ARGS");let type=typeof options2,opts={bufferSize:32,...options2==null||type==="function"?DEFAULT_ENCODING:type==="string"?{encoding:options2}:options2};(0,validators_1.validateUint32)(opts.bufferSize,"options.bufferSize",!0),this.options=opts,this._path=path4;let parentPath=typeof path4=="string"?path4:path4.toString();this.levels.push({entries:handle2.children[Symbol.iterator](),path:path4,parentPath})}readBase(){let levels=this.levels,options2=this.options,encoding=options2.encoding,recursive=options2.recursive;for(;levels.length;){let level=levels[levels.length-1],{done,value:value2}=level.entries.next();if(done){levels.pop();continue}let name=value2[0];if(name==="."||name==="..")continue;let link2=value2[1],dirent=Dirent_1.default.build(link2,encoding,level.parentPath);return recursive&&dirent.isDirectory()&&this.descend(level.path,dirent.name,link2),dirent}return null}descend(parent,name,link2){let path4=(0,fs_node_utils_1.pathJoin)(parent,name);if(!link2.getNode().canRead())throw(0,util_1.createError)("EACCES","opendir",path4);this.levels.push({entries:link2.children[Symbol.iterator](),path:path4,parentPath:path4})}readPromise(){return new Promise((resolve2,reject)=>{this.readImpl((err,entry)=>{err?reject(err):resolve2(entry??null)})})}readImpl(callback){if(this.closed)throw dirClosed();if(callback===void 0)return this.readPromise();let cb=callback;(0,util_1.validateCallback)(cb);let queued=this.operationQueue;if(queued!==null){queued.push(()=>{try{this.readImpl(cb)}catch(err){process.nextTick(cb,err)}});return}this.operationQueue=[];let entry=null,error=null;try{entry=this.readBase()}catch(err){error=err}process.nextTick(()=>{process.nextTick(()=>{let queue2=this.operationQueue;if(this.operationQueue=null,queue2)for(let i2=0;i2<queue2.length;i2++)queue2[i2]()}),error?cb(error):cb(null,entry)})}get path(){if(!(this instanceof _Dir))throw(0,argErrors_1.invalidThis)("Dir");return this._path}close(callback){if(callback===void 0)return this.closed?Promise.reject(dirClosed()):new Promise((resolve2,reject)=>{this.close(err=>{err?reject(err):resolve2()})});let cb=callback;if((0,util_1.validateCallback)(cb),this.closed){process.nextTick(cb,dirClosed());return}let queued=this.operationQueue;if(queued!==null){queued.push(()=>{this.close(cb)});return}this.closed=!0,process.nextTick(cb,null)}closeSync(){if(this.closed)throw dirClosed();if(this.operationQueue!==null)throw dirBusy();this.closed=!0}read(callback){return arguments.length===0?this.readPromise():this.readImpl(callback)}readSync(){if(this.closed)throw dirClosed();if(this.operationQueue!==null)throw dirBusy();return this.readBase()}async*entries(){try{for(;;){let entry=await this.read();if(entry===null)break;yield entry}}finally{await this.close()}}async[Symbol.asyncDispose](){this.closed||await this.close()}[Symbol.dispose](){this.closed||this.closeSync()}};exports.Dir=Dir;Object.defineProperty(Dir.prototype,Symbol.asyncIterator,{enumerable:!1,writable:!0,configurable:!0,value:Dir.prototype.entries})}});var require_volume=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/volume.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.FSWatcher=exports.StatWatcher=exports.Volume=void 0;exports.pathToSteps=pathToSteps;exports.dataToStr=dataToStr;exports.toUnixTimestamp=toUnixTimestamp;var path_1=require_path2(),fs_core_1=require_lib6(),Stats_1=require_Stats(),Dirent_1=require_Dirent(),StatFs_1=require_StatFs(),glob_1=require_glob(),buffer_1=require_buffer3(),setTimeoutUnref_1=require_setTimeoutUnref(),stream_1=require_stream2(),fs_node_utils_1=require_lib5(),events_1=require_events2(),FileHandle_1=require_FileHandle(),util_1=require_util4(),FsPromises_1=require_FsPromises(),fs_print_1=require_lib8(),fsSnapshot=require_lib9(),fs_node_utils_2=require_lib5(),argErrors_1=require_argErrors(),validators_1=require_validators(),options_1=require_options(),util_2=require_util2(),readWriteArgs_1=require_readWriteArgs(),Dir_1=require_Dir(),cp_1=require_cp(),{O_SYMLINK,F_OK,R_OK,W_OK,X_OK}=fs_node_utils_1.constants,kMinPoolSpace=128;function pathToSteps(path4){return(0,fs_core_1.filenameToSteps)((0,util_2.pathToFilename)(path4))}function dataToStr(data,encoding=fs_node_utils_1.ENCODING_UTF8){return buffer_1.Buffer.isBuffer(data)?data.toString(encoding):data instanceof Uint8Array?(0,buffer_1.bufferFrom)(data).toString(encoding):String(data)}function toUnixTimestamp(time){if(typeof time=="string"&&+time==time)return+time;if(time instanceof Date)return time.getTime()/1e3;if(isFinite(time))return time<0?Date.now()/1e3:time;throw new Error("Cannot parse time: "+time)}function validateUid(uid){if(typeof uid!="number")throw TypeError(fs_node_utils_2.ERRSTR.UID)}function validateGid(gid){if(typeof gid!="number")throw TypeError(fs_node_utils_2.ERRSTR.GID)}var Volume=class{get promises(){if(this.promisesApi===null)throw new Error("Promise is not supported in this environment.");return this.promisesApi}constructor(_core=new fs_core_1.Superblock){this._core=_core,this.promisesApi=new FsPromises_1.FsPromises(this,FileHandle_1.FileHandle),this.openSync=(path4,flags,mode=438)=>{let modeNum=(0,util_2.modeToNumber)(mode),fileName=(0,util_2.pathToFilename)(path4),flagsNum=(0,util_2.flagsToNumber)(flags);return this._core.open(fileName,flagsNum,modeNum,!(flagsNum&O_SYMLINK))},this.open=(path4,flags,a2,b2)=>{let mode=a2,callback=b2;typeof a2=="function"&&(mode=438,callback=a2),mode=mode||438;let modeNum=(0,util_2.modeToNumber)(mode),fileName=(0,util_2.pathToFilename)(path4),flagsNum=(0,util_2.flagsToNumber)(flags);this.wrapAsync(this._core.open,[fileName,flagsNum,modeNum,!(flagsNum&O_SYMLINK)],callback)},this.closeSync=fd=>{this._core.close(fd)},this.close=(fd,callback)=>{(0,fs_core_1.validateFd)(fd);let file=this._core.getFileByFdOrThrow(fd,"close");this.wrapAsync(this._core.close,[file.fd],callback)},this.readv=(fd,buffers,a2,b2)=>{(0,validators_1.validateInt32)(fd,"fd",0);let[position2,callback]=(0,readWriteArgs_1.getVectorCallbackArgs)(buffers,a2,b2);Promise.resolve().then(()=>{try{if(!buffers.length)throw(0,util_2.createError)("EINVAL","read");callback(null,this._core.readv(fd,buffers,position2),buffers)}catch(err){callback(err,0,buffers)}})},this.readvSync=(fd,buffers,position2)=>{let seek=(0,readWriteArgs_1.getVectorArgs)(buffers,position2);if((0,fs_core_1.validateFd)(fd),!buffers.length)throw(0,util_2.createError)("EINVAL","read");return this._core.readv(fd,buffers,seek)},this._readfile=(id,flagsNum,encoding)=>{let result,userOwnsFd=typeof id=="number"&&(0,fs_core_1.isFd)(id),fd;userOwnsFd?fd=id:fd=this.openSync(id,flagsNum);try{let file=this._core.getFileByFdOrThrow(fd,"fstat");if(file.node.isDirectory())throw(0,util_2.createError)("EISDIR","read");let buffer=file.getBuffer(),start=userOwnsFd?Math.min(file.position,buffer.length):0;file.position=buffer.length,result=(0,util_2.bufferToEncoding)(start?buffer.subarray(start):buffer,encoding)}finally{userOwnsFd||this.closeSync(fd)}return result},this.readFileSync=(file,options2)=>{let opts=(0,options_1.getReadFileOptions)(options2),flagsNum=(0,util_2.flagsToNumber)(opts.flag);return this._readfile(file,flagsNum,opts.encoding)},this.readFile=(id,a2,b2)=>{let[opts,callback]=(0,options_1.optsAndCbGenerator)(options_1.getReadFileOptions)(a2,b2),flagsNum=(0,util_2.flagsToNumber)(opts.flag);this.wrapAsync(this._readfile,[id,flagsNum,opts.encoding],callback)},this.writeSync=(fd,a2,b2,c2,d2)=>{let[,buf,offset,length,position2]=(0,util_2.getWriteSyncArgs)(fd,a2,b2,c2,d2);return this._write(fd,buf,offset,length,position2)},this.write=(fd,a2,b2,c2,d2,e2)=>{let[,,buf,offset,length,position2,cb]=(0,util_2.getWriteArgs)(fd,a2,b2,c2,d2,e2);Promise.resolve().then(()=>{try{cb(null,this._write(fd,buf,offset,length,position2),a2)}catch(err){cb(err,0,a2)}})},this.writev=(fd,buffers,a2,b2)=>{(0,validators_1.validateInt32)(fd,"fd",0);let[position2,callback]=(0,readWriteArgs_1.getVectorCallbackArgs)(buffers,a2,b2);if(!buffers.length){queueMicrotask(()=>callback(null,0,buffers));return}Promise.resolve().then(()=>{try{callback(null,this.writevBase(fd,buffers,position2),buffers)}catch(err){callback(err,0,buffers)}})},this.writevSync=(fd,buffers,position2)=>{let seek=(0,readWriteArgs_1.getVectorArgs)(buffers,position2);return buffers.length?((0,fs_core_1.validateFd)(fd),this.writevBase(fd,buffers,seek)):0},this.writeFileSync=(id,data,options2)=>{let opts=(0,options_1.getWriteFileOptions)(options2),flagsNum=(0,util_2.flagsToNumber)(opts.flag),modeNum=(0,util_2.modeToNumber)(opts.mode),buf=(0,fs_core_1.dataToBuffer)(data,opts.encoding);this._core.writeFile(id,buf,flagsNum,modeNum)},this.writeFile=(id,data,a2,b2)=>{let options2=a2,callback=b2;typeof a2=="function"&&([options2,callback]=[options_1.writeFileDefaults,a2]);let cb=(0,util_2.validateCallback)(callback),opts=(0,options_1.getWriteFileOptions)(options2),flagsNum=(0,util_2.flagsToNumber)(opts.flag),modeNum=(0,util_2.modeToNumber)(opts.mode),buf=(0,fs_core_1.dataToBuffer)(data,opts.encoding);this.wrapAsync(this._core.writeFile,[id,buf,flagsNum,modeNum],cb)},this.copyFileSync=(src,dest,flags)=>{let srcFilename=(0,util_2.pathToFilename)(src),destFilename=(0,util_2.pathToFilename)(dest);(0,cp_1.copyFileCore)(this._core,srcFilename,destFilename,(0,cp_1.getValidCopyFileMode)(flags))},this.copyFile=(src,dest,a2,b2)=>{let srcFilename=(0,util_2.pathToFilename)(src),destFilename=(0,util_2.pathToFilename)(dest),flags,callback;typeof a2=="function"?[flags,callback]=[0,a2]:[flags,callback]=[a2,b2],(0,util_2.validateCallback)(callback);let flagsNum=(0,cp_1.getValidCopyFileMode)(flags);Promise.resolve().then(()=>{try{(0,cp_1.copyFileCore)(this._core,srcFilename,destFilename,flagsNum)}catch(error){callback(error);return}callback(null)})},this.linkSync=(existingPath,newPath)=>{let existingPathFilename=(0,util_2.pathToFilename)(existingPath),newPathFilename=(0,util_2.pathToFilename)(newPath);this._core.link(existingPathFilename,newPathFilename)},this.link=(existingPath,newPath,callback)=>{let existingPathFilename=(0,util_2.pathToFilename)(existingPath),newPathFilename=(0,util_2.pathToFilename)(newPath);this.wrapAsync(this._core.link,[existingPathFilename,newPathFilename],callback)},this.unlinkSync=path4=>{let filename=(0,util_2.pathToFilename)(path4);this._core.unlink(filename)},this.unlink=(path4,callback)=>{let filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._core.unlink,[filename],callback)},this.symlinkSync=(target,path4,type)=>{let targetFilename=(0,util_2.pathToFilename)(target),pathFilename=(0,util_2.pathToFilename)(path4);this._core.symlink(targetFilename,pathFilename)},this.symlink=(target,path4,a2,b2)=>{let callback=(0,util_2.validateCallback)(typeof a2=="function"?a2:b2),targetFilename=(0,util_2.pathToFilename)(target),pathFilename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._core.symlink,[targetFilename,pathFilename],callback)},this._lstat=(filename,bigint=!1,throwIfNoEntry=!1)=>{let link2;try{link2=this._core.getLinkOrThrow(filename,"lstat")}catch(err){if(err.code==="ENOENT"&&!throwIfNoEntry)return;throw err}return Stats_1.default.build(link2.getNode(),bigint)},this.lstatSync=(path4,options2)=>{let{throwIfNoEntry=!0,bigint=!1}=(0,options_1.getStatOptions)(options2);return this._lstat((0,util_2.pathToFilename)(path4),bigint,throwIfNoEntry)},this.renameSync=(oldPath,newPath)=>{let oldPathFilename=(0,util_2.pathToFilename)(oldPath),newPathFilename=(0,util_2.pathToFilename)(newPath);this._core.rename(oldPathFilename,newPathFilename)},this.rename=(oldPath,newPath,callback)=>{let oldPathFilename=(0,util_2.pathToFilename)(oldPath),newPathFilename=(0,util_2.pathToFilename)(newPath);this.wrapAsync(this._core.rename,[oldPathFilename,newPathFilename],callback)},this.existsSync=path4=>{try{return this._exists((0,util_2.pathToFilename)(path4)).ok}catch{return!1}},this.exists=(path4,callback)=>{let filename=(0,util_2.pathToFilename)(path4);if(typeof callback!="function")throw Error(fs_node_utils_2.ERRSTR.CB);Promise.resolve().then(()=>{try{callback(this._exists(filename).ok)}catch{callback(!1)}})},this.accessSync=(path4,mode=F_OK)=>{let filename=(0,util_2.pathToFilename)(path4);mode=mode|0,this._access(filename,mode)},this.access=(path4,a2,b2)=>{let mode=F_OK,callback;typeof a2!="function"?[mode,callback]=[a2|0,(0,util_2.validateCallback)(b2)]:callback=a2;let filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._access,[filename,mode],callback)},this.appendFileSync=(id,data,options2)=>{let opts=(0,options_1.getAppendFileOpts)(options2);(!opts.flag||(0,fs_core_1.isFd)(id))&&(opts.flag="a"),this.writeFileSync(id,data,opts)},this.appendFile=(id,data,a2,b2)=>{let[opts,callback]=(0,options_1.getAppendFileOptsAndCb)(a2,b2);(!opts.flag||(0,fs_core_1.isFd)(id))&&(opts.flag="a"),this.writeFile(id,data,opts,callback)},this._readdir=(filename,options2)=>{let steps=(0,fs_core_1.filenameToSteps)(filename),link2=this._core.getResolvedLinkOrThrow(filename,"scandir"),node2=link2.getNode();if(!node2.isDirectory())throw(0,util_2.createError)("ENOTDIR","scandir",filename);if(!node2.canRead())throw(0,util_2.createError)("EACCES","scandir",filename);let list5=[];for(let name of link2.children.keys()){let child=link2.getChild(name);if(!(!child||name==="."||name==="..")&&(list5.push(Dirent_1.default.build(child,options2.encoding)),options2.recursive&&child.children.size)){let recurseOptions={...options2,recursive:!0,withFileTypes:!0},childList2=this._readdir(child.getPath(),recurseOptions);list5.push(...childList2)}}if(!fs_core_1.isWin&&options2.encoding!=="buffer"&&list5.sort((a2,b2)=>a2.name<b2.name?-1:a2.name>b2.name?1:0),options2.withFileTypes)return list5;let filename2=filename;return fs_core_1.isWin&&(filename2=filename2.replace(/\\/g,"/")),list5.map(dirent=>{if(options2.recursive){let fullPath=(0,fs_node_utils_2.pathJoin)(dirent.parentPath,dirent.name.toString());return fs_core_1.isWin&&(fullPath=fullPath.replace(/\\/g,"/")),fullPath.replace(filename2+path_1.posix.sep,"")}return dirent.name})},this.readdirSync=(path4,options2)=>{let opts=(0,options_1.getReaddirOptions)(options2),filename=(0,util_2.pathToFilename)(path4);return this._readdir(filename,opts)},this.readdir=(path4,a2,b2)=>{let[options2,callback]=(0,options_1.getReaddirOptsAndCb)(a2,b2),filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._readdir,[filename,options2],callback)},this._readlink=(filename,encoding)=>{let node2=this._core.getLinkOrThrow(filename,"readlink").getNode();if(!node2.isSymlink())throw(0,util_2.createError)("EINVAL","readlink",filename);return(0,fs_node_utils_1.strToEncoding)(node2.symlink,encoding)},this.readlinkSync=(path4,options2)=>{let opts=(0,options_1.getDefaultOpts)(options2),filename=(0,util_2.pathToFilename)(path4);return this._readlink(filename,opts.encoding)},this.readlink=(path4,a2,b2)=>{let[opts,callback]=(0,options_1.getDefaultOptsAndCb)(a2,b2),filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._readlink,[filename,opts.encoding],callback)},this._fsync=fd=>{this._core.getFileByFdOrThrow(fd,"fsync")},this.fsyncSync=fd=>{this._fsync(fd)},this.fsync=(fd,callback)=>{this.wrapAsync(this._fsync,[fd],callback)},this._fdatasync=fd=>{this._core.getFileByFdOrThrow(fd,"fdatasync")},this.fdatasyncSync=fd=>{this._fdatasync(fd)},this.fdatasync=(fd,callback)=>{this.wrapAsync(this._fdatasync,[fd],callback)},this._ftruncate=(fd,len)=>{this._core.ftruncate(fd,len)},this.ftruncateSync=(fd,len)=>{this._ftruncate(fd,len)},this.ftruncate=(fd,a2,b2)=>{let len=typeof a2=="number"?a2:0,callback=(0,util_2.validateCallback)(typeof a2=="number"?b2:a2);this.wrapAsync(this._ftruncate,[fd,len],callback)},this._truncate=(path4,len)=>{let fd=this.openSync(path4,"r+");try{this.ftruncateSync(fd,len)}finally{this.closeSync(fd)}},this.truncateSync=(id,len)=>{if((0,fs_core_1.isFd)(id))return this.ftruncateSync(id,len);this._truncate(id,len)},this.truncate=(id,a2,b2)=>{let len=typeof a2=="number"?a2:0,callback=(0,util_2.validateCallback)(typeof a2=="number"?b2:a2);if((0,fs_core_1.isFd)(id))return this.ftruncate(id,len,callback);this.wrapAsync(this._truncate,[id,len],callback)},this._futimes=(fd,atime,mtime)=>{this._core.futimes(fd,atime,mtime)},this.futimesSync=(fd,atime,mtime)=>{this._futimes(fd,toUnixTimestamp(atime),toUnixTimestamp(mtime))},this.futimes=(fd,atime,mtime,callback)=>{this.wrapAsync(this._futimes,[fd,toUnixTimestamp(atime),toUnixTimestamp(mtime)],callback)},this._utimes=(filename,atime,mtime,followSymlinks=!0)=>{this._core.utimes(filename,atime,mtime,followSymlinks)},this.utimesSync=(path4,atime,mtime)=>{this._utimes((0,util_2.pathToFilename)(path4),toUnixTimestamp(atime),toUnixTimestamp(mtime),!0)},this.utimes=(path4,atime,mtime,callback)=>{this.wrapAsync(this._utimes,[(0,util_2.pathToFilename)(path4),toUnixTimestamp(atime),toUnixTimestamp(mtime),!0],callback)},this.lutimesSync=(path4,atime,mtime)=>{this._utimes((0,util_2.pathToFilename)(path4),toUnixTimestamp(atime),toUnixTimestamp(mtime),!1)},this.lutimes=(path4,atime,mtime,callback)=>{this.wrapAsync(this._utimes,[(0,util_2.pathToFilename)(path4),toUnixTimestamp(atime),toUnixTimestamp(mtime),!1],callback)},this.mkdirSync=(path4,options2)=>{let opts=(0,options_1.getMkdirOptions)(options2),modeNum=(0,util_2.modeToNumber)(opts.mode,511),filename=(0,util_2.pathToFilename)(path4);if(opts.recursive)return this._core.mkdirp(filename,modeNum);this._core.mkdir(filename,modeNum)},this.mkdir=(path4,a2,b2)=>{let opts=(0,options_1.getMkdirOptions)(a2),callback=(0,util_2.validateCallback)(typeof a2=="function"?a2:b2),modeNum=(0,util_2.modeToNumber)(opts.mode,511),filename=(0,util_2.pathToFilename)(path4);opts.recursive?this.wrapAsync(this._core.mkdirp,[filename,modeNum],callback):this.wrapAsync(this._core.mkdir,[filename,modeNum],callback)},this._mkdtemp=(prefix,encoding,retry=5)=>{let filename=prefix+(0,util_2.genRndStr6)();try{return this._core.mkdir(filename,511),(0,fs_node_utils_1.strToEncoding)(filename,encoding)}catch(err){if(err.code==="EEXIST"){if(retry>1)return this._mkdtemp(prefix,encoding,retry-1);throw Error("Could not create temp dir.")}else throw err}},this.mkdtempSync=(prefix,options2)=>{let{encoding}=(0,options_1.getDefaultOpts)(options2);if(!prefix||typeof prefix!="string")throw new TypeError("filename prefix is required");return(0,util_2.nullCheck)(prefix),this._mkdtemp(prefix,encoding)},this.mkdtemp=(prefix,a2,b2)=>{let[{encoding},callback]=(0,options_1.getDefaultOptsAndCb)(a2,b2);if(!prefix||typeof prefix!="string")throw new TypeError("filename prefix is required");(0,util_2.nullCheck)(prefix)&&this.wrapAsync(this._mkdtemp,[prefix,encoding],callback)},this.rmdirSync=(path4,options2)=>{let opts=(0,options_1.getRmdirOptions)(options2);this._core.rmdir((0,util_2.pathToFilename)(path4),opts.recursive)},this.rmdir=(path4,a2,b2)=>{let opts=(0,options_1.getRmdirOptions)(a2),callback=(0,util_2.validateCallback)(typeof a2=="function"?a2:b2);this.wrapAsync(this._core.rmdir,[(0,util_2.pathToFilename)(path4),opts.recursive],callback)},this.rmSync=(path4,options2)=>{this._core.rm((0,util_2.pathToFilename)(path4),options2?.force,options2?.recursive)},this.rm=(path4,a2,b2)=>{let[opts,callback]=(0,options_1.getRmOptsAndCb)(a2,b2);this.wrapAsync(this._core.rm,[(0,util_2.pathToFilename)(path4),opts?.force,opts?.recursive],callback)},this._fchmod=(fd,modeNum)=>{this._core.fchmod(fd,modeNum)},this.fchmodSync=(fd,mode)=>{this._fchmod(fd,(0,util_2.modeToNumber)(mode))},this.fchmod=(fd,mode,callback)=>{this.wrapAsync(this._fchmod,[fd,(0,util_2.modeToNumber)(mode)],callback)},this._chmod=(filename,modeNum,followSymlinks=!0)=>{followSymlinks?this._core.chmod(filename,modeNum):this._core.lchmod(filename,modeNum)},this.chmodSync=(path4,mode)=>{let modeNum=(0,util_2.modeToNumber)(mode),filename=(0,util_2.pathToFilename)(path4);this._chmod(filename,modeNum,!0)},this.chmod=(path4,mode,callback)=>{let modeNum=(0,util_2.modeToNumber)(mode),filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._chmod,[filename,modeNum],callback)},this._lchmod=(filename,modeNum)=>{this._core.lchmod(filename,modeNum)},this.lchmodSync=(path4,mode)=>{let modeNum=(0,util_2.modeToNumber)(mode),filename=(0,util_2.pathToFilename)(path4);this._lchmod(filename,modeNum)},this.lchmod=(path4,mode,callback)=>{let modeNum=(0,util_2.modeToNumber)(mode),filename=(0,util_2.pathToFilename)(path4);this.wrapAsync(this._lchmod,[filename,modeNum],callback)},this._fchown=(fd,uid,gid)=>{this._core.fchown(fd,uid,gid)},this.fchownSync=(fd,uid,gid)=>{validateUid(uid),validateGid(gid),this._fchown(fd,uid,gid)},this.fchown=(fd,uid,gid,callback)=>{validateUid(uid),validateGid(gid),this.wrapAsync(this._fchown,[fd,uid,gid],callback)},this._chown=(filename,uid,gid)=>{this._core.chown(filename,uid,gid)},this.chownSync=(path4,uid,gid)=>{validateUid(uid),validateGid(gid),this._chown((0,util_2.pathToFilename)(path4),uid,gid)},this.chown=(path4,uid,gid,callback)=>{validateUid(uid),validateGid(gid),this.wrapAsync(this._chown,[(0,util_2.pathToFilename)(path4),uid,gid],callback)},this._lchown=(filename,uid,gid)=>{this._core.lchown(filename,uid,gid)},this.lchownSync=(path4,uid,gid)=>{validateUid(uid),validateGid(gid),this._lchown((0,util_2.pathToFilename)(path4),uid,gid)},this.lchown=(path4,uid,gid,callback)=>{validateUid(uid),validateGid(gid),this.wrapAsync(this._lchown,[(0,util_2.pathToFilename)(path4),uid,gid],callback)},this.statWatchers={},this.cpSync=(src,dest,options2)=>{let opts_=(0,cp_1.getCpOptions)(options2),srcFilename=(0,util_2.pathToFilename)(src),destFilename=(0,util_2.pathToFilename)(dest);(0,cp_1.cpSync)(this,srcFilename,destFilename,opts_)},this.cp=(src,dest,a2,b2)=>{let options2,callback;typeof a2=="function"?[options2,callback]=[void 0,a2]:[options2,callback]=[a2,b2],(0,util_2.validateCallback)(callback);let opts_=(0,cp_1.getCpOptions)(options2),srcFilename=(0,util_2.pathToFilename)(src),destFilename=(0,util_2.pathToFilename)(dest);(0,cp_1.cpAsync)(this,srcFilename,destFilename,opts_).then(()=>callback(null,void 0),error=>callback(error))},this.openAsBlob=async(path4,options2)=>{let filename=(0,util_2.pathToFilename)(path4),link2;try{link2=this._core.getResolvedLinkOrThrow(filename,"open")}catch(error){throw error&&typeof error=="object"&&error.code==="ENOENT"?(0,argErrors_1.withNativeCode)(new TypeError("Unable to open file as blob"),"ERR_INVALID_ARG_VALUE"):error}let buffer=link2.getNode().getBuffer(),type=options2?.type||"";return new Blob([buffer],{type})},this.glob=(pattern,options2,callback)=>{typeof options2=="function"&&(callback=options2,options2=void 0);let cb=(0,util_2.validateCallback)(callback),walk2=(0,glob_1.globWalk)(this,pattern,options2);Promise.resolve().then(()=>{let results=[];for(let match of walk2)results.push(match);return results}).then(results=>cb(null,results),cb)},this.globSync=(pattern,options2)=>(0,glob_1.globSync)(this,pattern,options2),this._opendir=(filename,options2,path4,errorPath)=>{let result=this._core.getResolvedLinkResult(filename,"opendir");if(!result.ok)throw(0,util_2.createError)(result.err.code,"opendir",errorPath);let link2=result.value,node2=link2.getNode();if(!node2.isDirectory())throw(0,util_2.createError)("ENOTDIR","opendir",errorPath);if(!node2.canRead())throw(0,util_2.createError)("EACCES","opendir",errorPath);return new Dir_1.Dir(link2,path4,options2)},this.opendirSync=(path4,options2)=>{let filename=(0,util_2.pathToFilename)(path4),opts=(0,options_1.getOpendirOptions)(options2);return this._opendir(filename,opts,path4 instanceof Uint8Array?(0,buffer_1.bufferFrom)(path4):filename,"")},this.opendir=(path4,a2,b2)=>{let[options2,callback]=(0,options_1.getOpendirOptsAndCb)(a2,b2),filename=(0,util_2.pathToFilename)(path4),dirPath=path4 instanceof Uint8Array?(0,buffer_1.bufferFrom)(path4):filename;this.wrapAsync(this._opendir,[filename,options2,dirPath,filename],callback)};let self2=this;this.StatWatcher=class extends StatWatcher{constructor(){super(self2)}};let _ReadStream=FsReadStream;this.ReadStream=class extends _ReadStream{constructor(...args){super(self2,...args)}};let _WriteStream=FsWriteStream;this.WriteStream=class extends _WriteStream{constructor(...args){super(self2,...args)}},this.FSWatcher=class extends FSWatcher{constructor(){super(self2)}};let _realpath=(filename,encoding)=>{let realLink=this._core.getResolvedLinkOrThrow(filename,"realpath");return(0,fs_node_utils_1.strToEncoding)(realLink.getPath()||"/",encoding)},realpathImpl=(path4,a2,b2)=>{let[opts,callback]=(0,options_1.getRealpathOptsAndCb)(a2,b2),pathFilename=(0,util_2.pathToFilename)(path4);self2.wrapAsync(_realpath,[pathFilename,opts.encoding],callback)},realpathSyncImpl=(path4,options2)=>_realpath((0,util_2.pathToFilename)(path4),(0,options_1.getRealpathOptions)(options2).encoding);this.realpath=realpathImpl,this.realpath.native=realpathImpl,this.realpathSync=realpathSyncImpl,this.realpathSync.native=realpathSyncImpl,this.readSync=function(fd,a2,b2,c2,d2){let{buffer,offset,length,position:position2}=(0,readWriteArgs_1.getReadSyncArgs)(arguments.length,a2,b2,c2,d2);return(0,fs_core_1.validateFd)(fd),self2._core.read(fd,buffer,offset,length,position2)},this.read=function(fd,a2,b2,c2,d2,e2){(0,validators_1.validateInt32)(fd,"fd",0);let{buffer,offset,length,position:position2,callback}=(0,readWriteArgs_1.getReadArgs)(arguments.length,a2,b2,c2,d2,e2);if(length===0){queueMicrotask(()=>callback(null,0,buffer));return}Promise.resolve().then(()=>{try{callback(null,self2._core.read(fd,buffer,offset,length,position2),buffer)}catch(err){callback(err,0,buffer)}})}}wrapAsync(method,args,callback){(0,util_2.validateCallback)(callback),Promise.resolve().then(()=>{let result;try{result=method.apply(this,args)}catch(err){callback(err);return}callback(null,result)})}reset(){this._core.reset()}toJSON(paths,json={},isRelative=!1,asBuffer=!1){return this._core.toJSON(paths,json,isRelative,asBuffer)}fromJSON(json,cwd2){return this._core.fromJSON(json,cwd2)}fromNestedJSON(json,cwd2){return this._core.fromNestedJSON(json,cwd2)}mountSync(mountpoint,json){this._core.fromJSON(json,mountpoint)}_write(fd,buf,offset,length,position2){return this._core.write(fd,buf,offset,length,position2)}writevBase(fd,buffers,position2){this._core.getFileByFdOrThrow(fd,"write");let p2=position2,bytesWritten=0,length=buffers.length;for(let i2=0;i2<length;i2++){let buffer=buffers[i2],nodeBuf=buffer_1.Buffer.from(buffer.buffer,buffer.byteOffset,buffer.byteLength),bytes=this._core.write(fd,nodeBuf,0,nodeBuf.byteLength,p2);if(p2!==null&&(p2+=bytes),bytesWritten+=bytes,bytes<nodeBuf.byteLength)break}return bytesWritten}lstat(path4,a2,b2){let[{throwIfNoEntry=!0,bigint=!1},callback]=(0,options_1.getStatOptsAndCb)(a2,b2);this.wrapAsync(this._lstat,[(0,util_2.pathToFilename)(path4),bigint,throwIfNoEntry],callback)}_stat(filename,bigint=!1,throwIfNoEntry=!0){let result=this._core.getResolvedLinkResult(filename,"stat");return result.ok?(0,fs_core_1.Ok)(Stats_1.default.build(result.value.getNode(),bigint)):result.err.code==="ENOENT"&&!throwIfNoEntry?(0,fs_core_1.Ok)(void 0):result}_statOrThrow(filename,bigint=!1,throwIfNoEntry=!0){let result=this._stat(filename,bigint,throwIfNoEntry);if(result.ok)return result.value;throw result.err.toError()}statSync(path4,options2){let{bigint=!0,throwIfNoEntry=!0}=(0,options_1.getStatOptions)(options2),result=this._stat((0,util_2.pathToFilename)(path4),bigint,throwIfNoEntry);if(result.ok)return result.value;throw result.err.toError()}stat(path4,a2,b2){let[{bigint=!1,throwIfNoEntry=!0},callback]=(0,options_1.getStatOptsAndCb)(a2,b2);this.wrapAsync(this._statOrThrow,[(0,util_2.pathToFilename)(path4),bigint,throwIfNoEntry],callback)}fstatBase(fd,bigint=!1){let file=this._core.getFileByFd(fd);if(!file)throw(0,util_2.createError)("EBADF","fstat");return Stats_1.default.build(file.node,bigint)}fstatSync(fd,options2){return this.fstatBase(fd,(0,options_1.getStatOptions)(options2).bigint)}fstat(fd,a2,b2){let[opts,callback]=(0,options_1.getStatOptsAndCb)(a2,b2);this.wrapAsync(this.fstatBase,[fd,opts.bigint],callback)}_exists(filename){let result=this._stat(filename);return result.ok?(0,fs_core_1.Ok)(!0):result}_access(filename,mode){let node2=this._core.getResolvedLinkOrThrow(filename,"access").getNode();if(mode!==F_OK&&(mode&R_OK&&!node2.canRead()||mode&W_OK&&!node2.canWrite()||mode&X_OK&&!node2.canExecute()))throw(0,util_2.createError)("EACCES","access",filename)}watchFile(path4,a2,b2){let filename=(0,util_2.pathToFilename)(path4),options2=a2,listener2=b2;if(typeof options2=="function"&&(listener2=a2,options2=null),typeof listener2!="function")throw new TypeError('The "listener" argument must be of type function. Received '+typeof listener2);let interval=5007,persistent=!0,bigint=!1;if(options2&&typeof options2=="object"){if(options2.interval!==void 0){if(typeof options2.interval!="number")throw new TypeError('The "options.interval" property must be of type number. Received '+typeof options2.interval);if(!Number.isInteger(options2.interval)||options2.interval<0||options2.interval>4294967295)throw new RangeError(`The value of "options.interval" is out of range. It must be an integer >= 0 && <= 4294967295. Received ${options2.interval}`);interval=options2.interval}typeof options2.persistent=="boolean"&&(persistent=options2.persistent),typeof options2.bigint=="boolean"&&(bigint=options2.bigint)}let watcher=this.statWatchers[filename];return watcher||(watcher=new this.StatWatcher,watcher.start(filename,persistent,interval,bigint),this.statWatchers[filename]=watcher),watcher.addListener("change",listener2),watcher}unwatchFile(path4,listener2){let filename=(0,util_2.pathToFilename)(path4),watcher=this.statWatchers[filename];watcher&&(typeof listener2=="function"?watcher.removeListener("change",listener2):watcher.removeAllListeners("change"),watcher.listenerCount("change")===0&&(watcher.stop(),delete this.statWatchers[filename]))}createReadStream(path4,options2){return new this.ReadStream(path4,options2)}createWriteStream(path4,options2){return new this.WriteStream(path4,options2)}watch(path4,options2,listener2){let filename=(0,util_2.pathToFilename)(path4),givenOptions=options2;typeof options2=="function"&&(listener2=options2,givenOptions=null);let{persistent,recursive,encoding,signal,throwIfNoEntry,ignore:ignore3}=(0,options_1.getDefaultOpts)(givenOptions);persistent===void 0&&(persistent=!0),recursive===void 0&&(recursive=!1);let watcher=new this.FSWatcher;try{watcher.start(filename,persistent,recursive,encoding,ignore3)}catch(err){if(throwIfNoEntry===!1&&err.code==="ENOENT")return watcher;throw err}if(listener2&&watcher.addListener("change",listener2),signal)if(signal.aborted)watcher.close();else{let onAbort=()=>watcher.close();signal.addEventListener("abort",onAbort,{once:!0}),watcher.once("close",()=>signal.removeEventListener("abort",onAbort))}return watcher}_statfs(filename,bigint=!1){return this._core.getResolvedLinkOrThrow(filename,"statfs"),StatFs_1.default.build(this._core,bigint)}statfsSync(path4,options2){let{bigint=!1}=(0,options_1.getStatfsOptions)(options2);return this._statfs((0,util_2.pathToFilename)(path4),bigint)}statfs(path4,a2,b2){let[{bigint=!1},callback]=(0,options_1.getStatfsOptsAndCb)(a2,b2);this.wrapAsync(this._statfs,[(0,util_2.pathToFilename)(path4),bigint],callback)}toTree(opts={separator:path_1.sep}){return(0,fs_print_1.toTreeSync)(this,opts)}toSnapshot(path4="/"){return fsSnapshot.toSnapshotSync({fs:this,path:path4})}fromSnapshot(snapshot,path4="/"){return fsSnapshot.fromSnapshotSync(snapshot,{fs:this,path:path4})}toBinarySnapshot(path4="/"){return fsSnapshot.toBinarySnapshotSync({fs:this,path:path4})}fromBinarySnapshot(binary2,path4="/"){return fsSnapshot.fromBinarySnapshotSync(binary2,{fs:this,path:path4})}toJsonSnapshot(path4="/"){let uint8=fsSnapshot.toJsonSnapshotSync({fs:this,path:path4});return buffer_1.Buffer.from(uint8).toString("utf8")}fromJsonSnapshot(json,path4="/"){let uint8=new Uint8Array(buffer_1.Buffer.from(json,"utf8"));return fsSnapshot.fromJsonSnapshotSync(uint8,{fs:this,path:path4})}};exports.Volume=Volume;Volume.fromJSON=(json,cwd2,opts)=>new Volume(fs_core_1.Superblock.fromJSON(json,cwd2,opts));Volume.fromNestedJSON=(json,cwd2,opts)=>new Volume(fs_core_1.Superblock.fromNestedJSON(json,cwd2,opts));function emitStop(self2){self2.emit("stop")}function buildZeroStats(bigint){let stats=new Stats_1.default,zero=bigint?BigInt(0):0,epoch=new Date(0);return stats.uid=zero,stats.gid=zero,stats.rdev=zero,stats.blksize=zero,stats.ino=zero,stats.size=zero,stats.blocks=zero,stats.atime=epoch,stats.mtime=epoch,stats.ctime=epoch,stats.birthtime=epoch,stats.atimeMs=zero,stats.mtimeMs=zero,stats.ctimeMs=zero,stats.birthtimeMs=zero,bigint&&(stats.atimeNs=zero,stats.mtimeNs=zero,stats.ctimeNs=zero,stats.birthtimeNs=zero),stats.dev=zero,stats.mode=zero,stats.nlink=zero,stats}var StatWatcher=class extends events_1.EventEmitter{constructor(vol){super(),this.bigint=!1,this.fileExists=!1,this.stopped=!1,this.onInterval=()=>{if(this.stopped)return;let stats=this.statSafe();if(stats)if(this.fileExists){if(this.hasChanged(stats)){let prev=this.prev;this.prev=stats,this.emit("change",stats,prev)}}else{this.fileExists=!0;let prev=this.prev;this.prev=stats,this.emit("change",stats,prev)}else this.fileExists&&(this.fileExists=!1,this.emit("change",buildZeroStats(this.bigint),this.prev));this.loop()},this.vol=vol}loop(){clearTimeout(this.timeoutRef),this.timeoutRef=this.setTimeout(this.onInterval,this.interval)}hasChanged(stats){let prev=this.prev;return stats.mtimeMs!==prev.mtimeMs||stats.ctimeMs!==prev.ctimeMs||stats.size!==prev.size||stats.ino!==prev.ino||stats.mode!==prev.mode||stats.uid!==prev.uid||stats.gid!==prev.gid||stats.nlink!==prev.nlink}statSafe(){try{return this.bigint?this.vol.statSync(this.filename,{bigint:!0}):this.vol.statSync(this.filename)}catch{return null}}start(path4,persistent=!0,interval=5007,bigint=!1){this.filename=(0,util_2.pathToFilename)(path4),this.setTimeout=persistent?setTimeout.bind(typeof globalThis<"u"?globalThis:global):setTimeoutUnref_1.default,this.interval=interval,this.bigint=bigint;let stats=this.statSafe();stats?(this.prev=stats,this.fileExists=!0):(this.prev=buildZeroStats(bigint),this.fileExists=!1,queueMicrotask(()=>{this.stopped||this.emit("change",this.prev,this.prev)})),this.loop()}stop(){this.stopped=!0,clearTimeout(this.timeoutRef),queueMicrotask(()=>{emitStop.call(this,this)})}ref(){this.setTimeout=setTimeout.bind(typeof globalThis<"u"?globalThis:global);let ref=this.timeoutRef;return ref&&typeof ref=="object"&&typeof ref.ref=="function"&&ref.ref(),this}unref(){this.setTimeout=setTimeoutUnref_1.default;let ref=this.timeoutRef;return ref&&typeof ref=="object"&&typeof ref.unref=="function"&&ref.unref(),this}};exports.StatWatcher=StatWatcher;var pool;function allocNewPool(poolSize){pool=(0,buffer_1.bufferAllocUnsafe)(poolSize),pool.used=0}(0,util_1.inherits)(FsReadStream,stream_1.Readable);exports.ReadStream=FsReadStream;function FsReadStream(vol,path4,options2){if(!(this instanceof FsReadStream))return new FsReadStream(vol,path4,options2);if(this._vol=vol,options2=Object.assign({},(0,options_1.getOptions)(options2,{})),options2.highWaterMark===void 0&&(options2.highWaterMark=64*1024),stream_1.Readable.call(this,options2),this.path=(0,util_2.pathToFilename)(path4),this._fileHandle=options2.fd&&typeof options2.fd!="number"?options2.fd:null,this.fd=options2.fd===void 0?null:typeof options2.fd!="number"?options2.fd.fd:options2.fd,this.flags=options2.flags===void 0?"r":options2.flags,this.mode=options2.mode===void 0?438:options2.mode,this.start=options2.start,this.end=options2.end,this.autoClose=options2.autoClose===void 0?!0:options2.autoClose,this.pos=void 0,this.bytesRead=0,this.start!==void 0){if(typeof this.start!="number")throw new TypeError('"start" option must be a Number');if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw new TypeError('"end" option must be a Number');if(this.start>this.end)throw new Error('"start" option must be <= "end" option');this.pos=this.start}typeof this.fd!="number"&&this.open(),this.on("end",function(){this.autoClose&&this.destroy&&this.destroy()})}FsReadStream.prototype.open=function(){var self2=this;this._vol.open(this.path,this.flags,this.mode,(er2,fd)=>{if(er2){self2.autoClose&&self2.destroy&&self2.destroy(),self2.emit("error",er2);return}self2.fd=fd,self2.emit("open",fd),self2.read()})};FsReadStream.prototype._read=function(n2){if(typeof this.fd!="number")return this.once("open",function(){this._read(n2)});if(this.destroyed)return;(!pool||pool.length-pool.used<kMinPoolSpace)&&allocNewPool(this._readableState.highWaterMark);var thisPool=pool,toRead=Math.min(pool.length-pool.used,n2),start=pool.used;if(this.pos!==void 0&&(toRead=Math.min(this.end-this.pos+1,toRead)),toRead<=0)return this.push(null);var self2=this;this._vol.read(this.fd,pool,pool.used,toRead,this.pos,onread),this.pos!==void 0&&(this.pos+=toRead),pool.used+=toRead;function onread(er2,bytesRead){if(er2)self2.autoClose&&self2.destroy&&self2.destroy(),self2.emit("error",er2);else{var b2=null;bytesRead>0&&(self2.bytesRead+=bytesRead,b2=thisPool.slice(start,start+bytesRead)),self2.push(b2)}}};FsReadStream.prototype._destroy=function(err,cb){this.close(err2=>{cb(err||err2)})};FsReadStream.prototype.close=function(cb){if(cb&&this.once("close",cb),this.closed||typeof this.fd!="number"){if(typeof this.fd!="number"){this.once("open",closeOnOpen);return}return queueMicrotask(()=>this.emit("close"))}typeof this._readableState?.closed=="boolean"?this._readableState.closed=!0:this.closed=!0,this._fileHandle?this._fileHandle.close().then(()=>this.emit("close"),er2=>this.emit("error",er2)):this._vol.close(this.fd,er2=>{er2?this.emit("error",er2):this.emit("close")}),this.fd=null};function closeOnOpen(fd){this.close()}(0,util_1.inherits)(FsWriteStream,stream_1.Writable);exports.WriteStream=FsWriteStream;function FsWriteStream(vol,path4,options2){if(!(this instanceof FsWriteStream))return new FsWriteStream(vol,path4,options2);if(this._vol=vol,options2=Object.assign({},(0,options_1.getOptions)(options2,{})),stream_1.Writable.call(this,options2),this.path=(0,util_2.pathToFilename)(path4),this._fileHandle=options2.fd&&typeof options2.fd!="number"?options2.fd:null,this.fd=options2.fd===void 0?null:typeof options2.fd!="number"?options2.fd.fd:options2.fd,this.flags=options2.flags===void 0?"w":options2.flags,this.mode=options2.mode===void 0?438:options2.mode,this.start=options2.start,this.autoClose=options2.autoClose===void 0?!0:!!options2.autoClose,this.pos=void 0,this.bytesWritten=0,this.pending=!0,this.start!==void 0){if(typeof this.start!="number")throw new TypeError('"start" option must be a Number');if(this.start<0)throw new Error('"start" must be >= zero');this.pos=this.start}options2.encoding&&this.setDefaultEncoding(options2.encoding),typeof this.fd!="number"&&this.open(),this.once("finish",function(){this.autoClose&&this.close()})}FsWriteStream.prototype.open=function(){this._vol.open(this.path,this.flags,this.mode,function(er2,fd){if(er2){this.autoClose&&this.destroy&&this.destroy(),this.emit("error",er2);return}this.fd=fd,this.pending=!1,this.emit("open",fd)}.bind(this))};FsWriteStream.prototype._write=function(data,encoding,cb){if(!(data instanceof buffer_1.Buffer||data instanceof Uint8Array))return this.emit("error",new Error("Invalid data"));if(typeof this.fd!="number")return this.once("open",function(){this._write(data,encoding,cb)});var self2=this;this._vol.write(this.fd,data,0,data.length,this.pos,(er2,bytes)=>{if(er2)return self2.autoClose&&self2.destroy&&self2.destroy(),cb(er2);self2.bytesWritten+=bytes,cb()}),this.pos!==void 0&&(this.pos+=data.length)};FsWriteStream.prototype._writev=function(data,cb){if(typeof this.fd!="number")return this.once("open",function(){this._writev(data,cb)});let self2=this,len=data.length,chunks=new Array(len);for(var size=0,i2=0;i2<len;i2++){var chunk=data[i2].chunk;chunks[i2]=chunk,size+=chunk.length}let buf=buffer_1.Buffer.concat(chunks);this._vol.write(this.fd,buf,0,buf.length,this.pos,(er2,bytes)=>{if(er2)return self2.destroy&&self2.destroy(),cb(er2);self2.bytesWritten+=bytes,cb()}),this.pos!==void 0&&(this.pos+=size)};FsWriteStream.prototype.close=function(cb){if(cb&&this.once("close",cb),this.closed||typeof this.fd!="number"){if(typeof this.fd!="number"){this.once("open",closeOnOpen);return}return queueMicrotask(()=>this.emit("close"))}typeof this._writableState?.closed=="boolean"?this._writableState.closed=!0:this.closed=!0,this._fileHandle?this._fileHandle.close().then(()=>this.emit("close"),er2=>this.emit("error",er2)):this._vol.close(this.fd,er2=>{er2?this.emit("error",er2):this.emit("close")}),this.fd=null};FsWriteStream.prototype._destroy=FsReadStream.prototype._destroy;FsWriteStream.prototype.destroySoon=FsWriteStream.prototype.end;var FSWatcher=class extends events_1.EventEmitter{constructor(vol){super(),this._filename="",this._filenameEncoded="",this._recursive=!1,this._encoding=fs_node_utils_1.ENCODING_UTF8,this._closed=!1,this._onEvent=event=>{switch(event.type){case 0:case 1:this._emit("rename",event.steps);break;case 4:event.oldSteps&&this._emit("rename",event.oldSteps),this._emit("rename",event.steps);break;case 2:case 3:this._emit("change",event.steps);break}},this._persist=()=>{this._timer=setTimeout(this._persist,1e6)},this._vol=vol}_emit(type,relativeSteps){let filename=relativeSteps.length?relativeSteps.join(fs_node_utils_2.pathSep):this._watcher.link.getName();this._ignore&&this._ignore(filename)||this.emit("change",type,(0,fs_node_utils_1.strToEncoding)(filename,this._encoding))}ref(){return this._watcher&&!this._closed&&!this._timer&&this._persist(),this}unref(){return clearTimeout(this._timer),this._timer=void 0,this}start(path4,persistent=!0,recursive=!1,encoding=fs_node_utils_1.ENCODING_UTF8,ignore3){this._filename=(0,util_2.pathToFilename)(path4),this._steps=(0,fs_core_1.filenameToSteps)(this._filename),this._filenameEncoded=(0,fs_node_utils_1.strToEncoding)(this._filename),this._recursive=recursive,this._encoding=encoding,this._ignore=ignore3===void 0?void 0:(0,fs_node_utils_1.watchIgnoreToMatcher)(ignore3);try{this._watcher=new fs_core_1.CoreWatcher(this._vol._core,this._filename,{recursive})}catch(err){throw(0,util_2.createWatchError)(err.code,this._filename)}this._link=this._watcher.link,this._watcher.changes.listen(this._onEvent),persistent&&this._persist()}close(){clearTimeout(this._timer),this._timer=void 0,!(!this._watcher||this._closed)&&(this._closed=!0,this._watcher.close(),queueMicrotask(()=>this.emit("close")))}};exports.FSWatcher=FSWatcher}});var require_lib10=__commonJS({"node_modules/.pnpm/@jsonjoy.com+fs-node@4.80.0_tslib@2.9.1/node_modules/@jsonjoy.com/fs-node/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.fsCommonObjectsList=exports.fsSynchronousApiList=exports.fsCallbackApiList=exports.FsPromises=exports.Dir=exports.FileHandle=exports.StatFs=exports.Dirent=exports.Stats=exports.toUnixTimestamp=exports.FSWatcher=exports.StatWatcher=exports.Volume=void 0;var tslib_1=(init_tslib_es6(),__toCommonJS(tslib_es6_exports)),volume_1=require_volume();Object.defineProperty(exports,"Volume",{enumerable:!0,get:function(){return volume_1.Volume}});Object.defineProperty(exports,"StatWatcher",{enumerable:!0,get:function(){return volume_1.StatWatcher}});Object.defineProperty(exports,"FSWatcher",{enumerable:!0,get:function(){return volume_1.FSWatcher}});Object.defineProperty(exports,"toUnixTimestamp",{enumerable:!0,get:function(){return volume_1.toUnixTimestamp}});var Stats_1=require_Stats();Object.defineProperty(exports,"Stats",{enumerable:!0,get:function(){return Stats_1.default}});var Dirent_1=require_Dirent();Object.defineProperty(exports,"Dirent",{enumerable:!0,get:function(){return Dirent_1.default}});var StatFs_1=require_StatFs();Object.defineProperty(exports,"StatFs",{enumerable:!0,get:function(){return StatFs_1.default}});var FileHandle_1=require_FileHandle();Object.defineProperty(exports,"FileHandle",{enumerable:!0,get:function(){return FileHandle_1.FileHandle}});var Dir_1=require_Dir();Object.defineProperty(exports,"Dir",{enumerable:!0,get:function(){return Dir_1.Dir}});var FsPromises_1=require_FsPromises();Object.defineProperty(exports,"FsPromises",{enumerable:!0,get:function(){return FsPromises_1.FsPromises}});tslib_1.__exportStar(require_options(),exports);tslib_1.__exportStar(require_util2(),exports);tslib_1.__exportStar(require_glob(),exports);var fs_node_utils_1=require_lib5();Object.defineProperty(exports,"fsCallbackApiList",{enumerable:!0,get:function(){return fs_node_utils_1.fsCallbackApiList}});Object.defineProperty(exports,"fsSynchronousApiList",{enumerable:!0,get:function(){return fs_node_utils_1.fsSynchronousApiList}});Object.defineProperty(exports,"fsCommonObjectsList",{enumerable:!0,get:function(){return fs_node_utils_1.fsCommonObjectsList}})}});var require_lib11=__commonJS({"node_modules/.pnpm/memfs@4.80.0/node_modules/memfs/lib/index.js"(exports,module){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.memfs=exports.fs=exports.vol=exports.Volume=void 0;exports.createFsFromVolume=createFsFromVolume;var fs_node_1=require_lib10();Object.defineProperty(exports,"Volume",{enumerable:!0,get:function(){return fs_node_1.Volume}});var fs_node_utils_1=require_lib5(),{F_OK,R_OK,W_OK,X_OK}=fs_node_utils_1.constants,getGlobalProcess=()=>(typeof globalThis<"u"?globalThis.process:void 0)??{},createProcess=(cwd2,baseProcess=getGlobalProcess())=>({cwd:()=>cwd2,platform:baseProcess.platform??"linux",emitWarning:baseProcess.emitWarning?.bind(baseProcess)??(()=>{}),env:baseProcess.env??{},getuid:baseProcess.getuid?.bind(baseProcess),getgid:baseProcess.getgid?.bind(baseProcess)});exports.vol=fs_node_1.Volume.fromNestedJSON({},"/",{process:createProcess("/")});var kStreams=Symbol("streams"),streamSlot=index4=>({get(){return this[kStreams][index4]},set(value2){this[kStreams][index4]=value2},enumerable:!0,configurable:!0}),streamDescriptors={ReadStream:streamSlot(0),WriteStream:streamSlot(1),FileReadStream:streamSlot(2),FileWriteStream:streamSlot(3)};function createFsFromVolume(vol){let fs2={F_OK,R_OK,W_OK,X_OK,constants:fs_node_utils_1.constants,Stats:fs_node_1.Stats,Dir:fs_node_1.Dir,Dirent:fs_node_1.Dirent};for(let method of fs_node_1.fsSynchronousApiList)typeof vol[method]=="function"&&(fs2[method]=vol[method].bind(vol));for(let method of fs_node_1.fsCallbackApiList)typeof vol[method]=="function"&&(fs2[method]=vol[method].bind(vol));return fs2.StatWatcher=vol.StatWatcher,fs2.FSWatcher=vol.FSWatcher,fs2[kStreams]=[vol.ReadStream,vol.WriteStream,vol.ReadStream,vol.WriteStream],Object.defineProperties(fs2,streamDescriptors),fs2.promises=vol.promises,typeof vol.realpath=="function"&&(fs2.realpath=vol.realpath.bind(vol),typeof vol.realpath.native=="function"&&(fs2.realpath.native=vol.realpath.native.bind(vol))),typeof vol.realpathSync=="function"&&(fs2.realpathSync=vol.realpathSync.bind(vol),typeof vol.realpathSync.native=="function"&&(fs2.realpathSync.native=vol.realpathSync.native.bind(vol))),fs2._toUnixTimestamp=fs_node_1.toUnixTimestamp,fs2.__vol=vol,fs2}exports.fs=createFsFromVolume(exports.vol);var memfs=(json={},cwdOrOpts="/")=>{let opts=typeof cwdOrOpts=="string"?{cwd:cwdOrOpts}:cwdOrOpts,cwd2=opts.cwd??(opts.process?void 0:"/"),process2=opts.process??createProcess(cwd2??"/"),vol=fs_node_1.Volume.fromNestedJSON(json,cwd2,{process:process2});return{fs:createFsFromVolume(vol),vol}};exports.memfs=memfs;module.exports={...module.exports,...exports.fs};module.exports.semantic=!0}});var require_ignore2=__commonJS({"node_modules/.pnpm/ignore@7.0.14/node_modules/ignore/index.js"(exports,module){init_browser_globals();function makeArray(subject){return Array.isArray(subject)?subject:[subject]}var UNDEFINED=void 0,EMPTY="",SPACE=" ",ESCAPE="\\",REGEX_LITERAL_SPECIAL=/[.*+?()[\]{}^$|\\/]/,BOM2="\uFEFF",REGEX_INVALID_TRAILING_BACKSLASH=/(?:[^\\]|^)\\$/,REGEX_ANCHORED_GLOBSTAR=/^\/\*{2,}$/,REGEX_REPLACE_LEADING_EXCAPED_EXCLAMATION=/^\\!/,REGEX_REPLACE_LEADING_EXCAPED_HASH=/^\\#/,REGEX_SPLITALL_CRLF=/\r?\n/g,DOUBLE_SLASH="//",SLASH_CODE=47,DOT_CODE=46,SLASH="/",TMP_KEY_IGNORE="node-ignore";typeof Symbol<"u"&&(TMP_KEY_IGNORE=Symbol.for("node-ignore"));var KEY_IGNORE=TMP_KEY_IGNORE,define2=(object,key,value2)=>(Object.defineProperty(object,key,{value:value2}),value2),RETURN_FALSE=()=>!1,POSIX_CLASSES={alnum:"0-9A-Za-z",alpha:"A-Za-z",blank:" \\t",cntrl:"\\x00-\\x1f\\x7f",digit:"0-9",graph:"!-.0-~",lower:"a-z",print:" -.0-~",punct:"!-.:-@\\[-`{-~",space:" \\t\\n\\r",upper:"A-Z",xdigit:"0-9A-Fa-f"},CLASS_MEMBERS_TO_ESCAPE="\\]^-[",escapeMember=char=>CLASS_MEMBERS_TO_ESCAPE.indexOf(char)<0?char:ESCAPE+char,NON_SLASH="(?!\\/)",classSource=(negated,body)=>{if(negated)return`[^\\/${body}]`;let source2=`[${body}]`;return new RegExp(source2).test("/")?NON_SLASH+source2:source2},scanBracket=(pattern,start)=>{let{length}=pattern,index4=start+1,negated=EMPTY,lead=pattern[index4];(lead==="!"||lead==="^")&&(negated="^",index4++);let body=EMPTY,prev=EMPTY;for(;;){let char=pattern[index4];if(char===UNDEFINED)return null;if(char===ESCAPE){let escaped=pattern[index4+1];if(escaped===UNDEFINED)return null;body+=escapeMember(escaped),prev=escaped,index4++}else if(char==="-"&&prev&&index4+1<length&&pattern[index4+1]!=="]"){index4++;let to=pattern[index4];to===ESCAPE&&(to=pattern[index4+=1]),prev<=to&&(body+=`-${escapeMember(to)}`),prev=EMPTY}else if(char==="["&&pattern[index4+1]===":"){let nameStart=index4+2,end=nameStart;for(;end<length&&pattern[end]!=="]";)end++;if(end===length)return null;if(end>nameStart&&pattern[end-1]===":"){let name=pattern.slice(nameStart,end-1);if(!Object.prototype.hasOwnProperty.call(POSIX_CLASSES,name))return null;body+=POSIX_CLASSES[name],prev=EMPTY,index4=end}else body+=escapeMember("["),prev="[",index4=nameStart-2}else body+=escapeMember(char),prev=char;if(index4++,pattern[index4]==="]")return{end:index4,source:classSource(negated,body)}}},NEVER_MATCH="[]",PLACEHOLDER="\0",REGEX_RESTORE_PLACEHOLDER=new RegExp(`${PLACEHOLDER}(\\d+)${PLACEHOLDER}`,"g"),TRAILING_WILDCARD="\uE000",TRAILING_DOUBLESTAR="\uE001",isReserved=char=>char===PLACEHOLDER||char===TRAILING_WILDCARD||char===TRAILING_DOUBLESTAR,extractBrackets=pattern=>{let sources=[],hold=source2=>`${PLACEHOLDER}${sources.push(source2)-1}${PLACEHOLDER}`,{length}=pattern,out=EMPTY,index4=0;for(;index4<length;){let char=pattern[index4];if(char===ESCAPE){let escaped=pattern[index4+1];escaped===UNDEFINED||escaped===SLASH&&index4+2===length?out+=hold(NEVER_MATCH):escaped==="*"||escaped==="["||escaped===SPACE?out+=pattern.slice(index4,index4+2):out+=hold(REGEX_LITERAL_SPECIAL.test(escaped)?ESCAPE+escaped:isReserved(escaped)?`[${escaped}]`:escaped),index4+=2}else if(isReserved(char))out+=hold(`[${char}]`),index4++;else if(char==="["){let scanned=scanBracket(pattern,index4);scanned===null?(out+=hold(NEVER_MATCH),index4=length):(out+=hold(scanned.source),index4=scanned.end+1)}else out+=char,index4++}return{source:out,sources}},DIRECT=null,REGEX_INNER_SLASH=/\/(?!$)/,REPLACERS=[[/(\\+)( ?)/g,(_2,run,space)=>space?run.slice(0,run.length-run.length%2)+SPACE:run,ESCAPE+SPACE],[/(^|\/)\*{3,}(?=\/|$)/g,(_2,start)=>`${start}**`,"*"],[/[\\$.|*+(){^]/g,match=>`\\${match}`],[/(?!\\)\?/g,()=>"[^/]","?"],[/^\//,()=>"^",SLASH],[/\//g,()=>"\\/",SLASH],[/^\^*(?:\\\*\\\*\\\/)+/,()=>"^(?:.*\\/)?","*"],[DIRECT,(source2,pattern)=>!source2||source2[0]==="^"?source2:(REGEX_INNER_SLASH.test(pattern)?"^":"(?:^|\\/)")+source2],[/\\\/\\\*\\\*(?=\\\/|$)/g,(_2,index4,str)=>index4+6<str.length?str.slice(index4+6)==="\\/"?"(?:\\/[^\\/]+)+":"(?:\\/[^\\/]+)*":`\\/${TRAILING_DOUBLESTAR}`,"*"],[/(^|[^\\]+)(\\\*)+(?=.+)/g,(_2,p1,p2)=>{let unescaped=p2.replace(/\\\*/g,"[^\\/]*");return p1+unescaped},"*"],[/(^|[^\\])((?:\\\\)*)\\\*$/,(match,p1,p2)=>p2===EMPTY?p1+TRAILING_WILDCARD:match,"*"],[/\\\\\\(?=[$.|*+(){^])/g,()=>ESCAPE,ESCAPE+ESCAPE],[/\\\\/g,()=>ESCAPE,ESCAPE+ESCAPE],[/\\\[([^\]/]*?)($|\])/g,(match,range,close2)=>`\\[${range}${close2}`,"["],[DIRECT,source2=>{let last=source2[source2.length-1];return!last||last===TRAILING_WILDCARD||last===TRAILING_DOUBLESTAR?source2:last===SLASH?`${source2}$`:`${source2}(?=$|\\/$)`}]],REGEX_REPLACE_TRAILING_WILDCARD=/(^|\\\/)?\uE000$/,MODE_IGNORE="regex",MODE_CHECK_IGNORE="checkRegex",UNDERSCORE="_",replaceTrailingWildcard=(_2,p1)=>`${p1?`${p1}[^/]+`:"[^/]*"}(?=$|\\/$)`,REGEX_REPLACE_TRAILING_DOUBLESTAR=/\uE001$/,replaceTrailingDoublestar=()=>".+(?=$|\\/$)",WILDCARD="[^\\/]*",separatorAfter=(run,at2)=>{let separator=EMPTY;for(let index4=at2+1;index4<run.length&&!run[index4].wildcard;index4++)separator+=run[index4].single;return separator},pinWildcards=source2=>{if(source2.indexOf(WILDCARD)<0)return source2;let tokens=[],{length}=source2,index4=0;for(;index4<length;){let char=source2[index4];if(source2.startsWith(WILDCARD,index4))tokens.push({wildcard:!0}),index4+=WILDCARD.length;else if(char==="["){let end=index4+1;for(source2[end]==="^"&&end++,source2[end]==="]"&&end++;end<length&&source2[end]!=="]";)end+=source2[end]===ESCAPE?2:1;end++,tokens.push({single:source2.slice(index4,end)}),index4=end}else if(char===ESCAPE)tokens.push({single:source2.slice(index4,index4+2)}),index4+=2;else if(char==="("){let depth=0,end=index4;do source2[end]===ESCAPE?end++:source2[end]==="("?depth++:source2[end]===")"&&depth--,end++;while(end<length&&depth>0);"*+?".indexOf(source2[end])>=0&&end++,tokens.push({boundary:source2.slice(index4,end)}),index4=end}else char==="^"||char==="$"?(tokens.push({boundary:char}),index4++):(tokens.push({single:char}),index4++)}let out=EMPTY,run=[],flush=()=>{let lastWildcard;run.forEach((token,at2)=>{token.wildcard&&(lastWildcard=at2)}),run.forEach((token,at2)=>{if(!token.wildcard){out+=token.single;return}out+=at2===lastWildcard?WILDCARD:`(?:(?!${separatorAfter(run,at2)})[^\\/])*`}),run=[]};return tokens.forEach(token=>{if(token.boundary===void 0){run.push(token);return}flush(),out+=token.boundary}),flush(),out},makeRegexPrefix=pattern=>{REGEX_ANCHORED_GLOBSTAR.test(pattern)&&(pattern="**");let{source:source2,sources}=extractBrackets(pattern),replaced=REPLACERS.reduce((prev,[matcher,replacer,required])=>matcher===DIRECT?replacer(prev,pattern):required!==UNDEFINED&&prev.indexOf(required)<0?prev:matcher.test(prev)?prev.replace(matcher,replacer.bind(pattern)):prev,source2);return sources.length?replaced.replace(REGEX_RESTORE_PLACEHOLDER,(match,index4)=>sources[index4]):replaced},checkSourceOf=(body,prefix)=>{body[body.length-1]===SLASH&&(prefix=makeRegexPrefix(body.slice(0,-1)));let head=prefix.slice(0,-1),last=prefix[prefix.length-1];return last===TRAILING_WILDCARD?`${head}$`:last===TRAILING_DOUBLESTAR?`${head}.*$`:NEVER_MATCH},matchesBasename=body=>{let index4=body.indexOf(SLASH);return index4<0||index4===body.length-1},basenameOf=path4=>{let end=path4.length-1,index4=path4.lastIndexOf(SLASH,path4[end]===SLASH?end-1:end);return index4<0?path4:path4.slice(index4+1)},parentOf=path4=>{if(path4.charCodeAt(0)===SLASH_CODE||path4.indexOf(DOUBLE_SLASH)>=0){let slices=path4.split(SLASH).filter(Boolean);return slices.pop(),slices.length?slices.join(SLASH)+SLASH:EMPTY}let end=path4.length-1,cut=path4.lastIndexOf(SLASH,path4.charCodeAt(end)===SLASH_CODE?end-1:end);return cut<0?EMPTY:path4.slice(0,cut+1)},isString2=subject=>typeof subject=="string",checkPattern=pattern=>pattern&&isString2(pattern)&&!REGEX_INVALID_TRAILING_BACKSLASH.test(pattern),splitPattern=pattern=>pattern.split(REGEX_SPLITALL_CRLF).filter(Boolean),IgnoreRule=class{constructor(pattern,mark,body,ignoreCase,negative,prefix){this.pattern=pattern,this.mark=mark,this.negative=negative,define2(this,"body",body),define2(this,"ignoreCase",ignoreCase),define2(this,"regexPrefix",prefix)}get _basenameOnly(){return define2(this,"_basenameOnly",matchesBasename(this.body))}get regex(){let key=UNDERSCORE+MODE_IGNORE;return this[key]?this[key]:this._make(MODE_IGNORE,key)}get checkRegex(){let key=UNDERSCORE+MODE_CHECK_IGNORE;return this[key]?this[key]:this._make(MODE_CHECK_IGNORE,key)}_make(mode,key){let str=pinWildcards(mode===MODE_IGNORE?this.regexPrefix.replace(REGEX_REPLACE_TRAILING_WILDCARD,replaceTrailingWildcard).replace(REGEX_REPLACE_TRAILING_DOUBLESTAR,replaceTrailingDoublestar):checkSourceOf(this.body,this.regexPrefix)),regex=this.ignoreCase?new RegExp(str,"i"):new RegExp(str);return define2(this,key,regex)}},isLineEnd=char=>char==="\r"||char===`
|
|
49
49
|
`,trimEnd=body=>{let end=body.length;for(;end&&isLineEnd(body[end-1]);)end--;let lineEnd=end;for(;end&&body[end-1]===SPACE;)end--;if(end===lineEnd)return body.slice(0,end);let backslashes=0;for(;backslashes<end&&body[end-backslashes-1]===ESCAPE;)backslashes++;return backslashes%2?body.slice(0,end-1)+SPACE:body.slice(0,end)},createRule=({pattern,mark},ignoreCase)=>{let body=pattern[0]===BOM2?pattern.slice(1):pattern;if(body[0]==="#")return;let negative=!1;body[0]==="!"&&(negative=!0,body=body.slice(1));let last=body[body.length-1];if((last===SPACE||last==="\r"||last===`
|
|
50
50
|
`)&&(body=trimEnd(body)),!body)return;body=body.replace(REGEX_REPLACE_LEADING_EXCAPED_EXCLAMATION,"!").replace(REGEX_REPLACE_LEADING_EXCAPED_HASH,"#");let regexPrefix=makeRegexPrefix(body);return new IgnoreRule(pattern,mark,body,ignoreCase,negative,regexPrefix)},RuleManager=class{constructor(ignoreCase){this._ignoreCase=ignoreCase,this._rules=[],this._basenameCount=0}_add(pattern){if(pattern&&pattern[KEY_IGNORE]){this._rules=this._rules.concat(pattern._rules._rules),this._basenameCount+=pattern._rules._basenameCount,this._added=!0;return}isString2(pattern)&&(pattern={pattern});let rule2=checkPattern(pattern.pattern)&&createRule(pattern,this._ignoreCase);rule2&&(this._added=!0,this._rules.push(rule2),matchesBasename(rule2.body)&&this._basenameCount++)}add(pattern){return this._added=!1,makeArray(isString2(pattern)?splitPattern(pattern):pattern).forEach(this._add,this),this._added&&(this._literalRules=UNDEFINED),this._added}testLiteral(path4){let rules=this._literalRules||(this._literalRules=this._rules.filter(({body})=>body[body.length-(body[body.length-1]===SLASH?2:1)]==="*")),ignored=!1,unignored=!1,matchedRule;for(let index4=rules.length-1;index4>=0;index4--){let rule2=rules[index4];if(rule2.checkRegex.test(path4)){ignored=!rule2.negative,unignored=rule2.negative,matchedRule=rule2.negative?UNDEFINED:rule2;break}}let ret={ignored,unignored};return matchedRule&&(ret.rule=matchedRule),ret}test(path4,mode){let rules=this._rules,{length}=rules,shortcut=this._basenameCount*2>=length,basename4=shortcut?basenameOf(path4):path4;for(let index4=length-1;index4>=0;index4--){let rule2=rules[index4];if(rule2[mode].test(shortcut&&rule2._basenameOnly?basename4:path4)){let{negative}=rule2,ret={ignored:!negative,unignored:negative};return negative||(ret.rule=rule2),ret}}return{ignored:!1,unignored:!1}}},throwError=(message,Ctor)=>{throw new Ctor(message)},checkPath=(path4,originalPath,doThrow)=>isString2(path4)?path4?checkPath.isNotRelative(path4)?doThrow(`path should be a \`path.relative()\`d string, but got "${originalPath}"`,RangeError):!0:doThrow("path must not be empty",TypeError):doThrow(`path must be a string, but got \`${originalPath}\``,TypeError),isNotRelative=path4=>{let first=path4.charCodeAt(0);if(first===SLASH_CODE)return!0;if(first!==DOT_CODE)return!1;if(path4.length===1)return!0;let second=path4.charCodeAt(1);return second===SLASH_CODE?!0:second!==DOT_CODE?!1:path4.length===2||path4.charCodeAt(2)===SLASH_CODE};checkPath.isNotRelative=isNotRelative;checkPath.convert=p2=>p2;var Ignore=class{constructor({ignorecase=!0,ignoreCase=ignorecase,allowRelativePaths=!1}={}){define2(this,KEY_IGNORE,!0),this._rules=new RuleManager(ignoreCase),this._strictPathCheck=!allowRelativePaths,this._initCache()}_initCache(){this._ignoreCache=Object.create(null),this._testCache=Object.create(null)}add(pattern){return this._rules.add(pattern)&&this._initCache(),this}addPattern(pattern){return this.add(pattern)}_test(originalPath,cache3){let path4=originalPath&&checkPath.convert(originalPath);return checkPath(path4,originalPath,this._strictPathCheck?throwError:RETURN_FALSE),this._t(path4,cache3)}checkIgnore(path4){if(path4.charCodeAt(path4.length-1)!==SLASH_CODE)return this.test(path4);let dir=this._t(path4,this._testCache);if(dir.ignored)return dir;let literal=this._rules.testLiteral(path4);return literal.ignored||literal.unignored?literal:dir}_t(path4,cache3){if(path4 in cache3)return cache3[path4];let parentPath=parentOf(path4),parent=parentPath?this._t(parentPath,cache3):UNDEFINED;return cache3[path4]=parent&&parent.ignored?parent:this._rules.test(path4,MODE_IGNORE)}ignores(path4){return this._test(path4,this._ignoreCache).ignored}createFilter(){return path4=>!this.ignores(path4)}filter(paths){return makeArray(paths).filter(this.createFilter())}test(path4){return this._test(path4,this._testCache)}},factory=options2=>new Ignore(options2),isPathValid=path4=>checkPath(path4&&checkPath.convert(path4),path4,RETURN_FALSE),setupWindows=()=>{let makePosix=str=>/^\\\\\?\\/.test(str)||/["<>|\u0000-\u001F]+/u.test(str)?str:str.replace(/\\/g,"/");checkPath.convert=makePosix;let REGEX_TEST_WINDOWS_PATH_ABSOLUTE=/^[a-z]:\//i;checkPath.isNotRelative=path4=>REGEX_TEST_WINDOWS_PATH_ABSOLUTE.test(path4)||isNotRelative(path4)};typeof process<"u"&&process.platform==="win32"&&setupWindows();module.exports=factory;factory.default=factory;module.exports.isPathValid=isPathValid;define2(module.exports,Symbol.for("setupWindows"),setupWindows)}});var require_ansi_regex=__commonJS({"node_modules/.pnpm/ansi-regex@5.0.1/node_modules/ansi-regex/index.js"(exports,module){"use strict";init_browser_globals();module.exports=({onlyFirst=!1}={})=>{let pattern=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(pattern,onlyFirst?void 0:"g")}}});var require_strip_ansi=__commonJS({"node_modules/.pnpm/strip-ansi@6.0.1/node_modules/strip-ansi/index.js"(exports,module){"use strict";init_browser_globals();var ansiRegex=require_ansi_regex();module.exports=string4=>typeof string4=="string"?string4.replace(ansiRegex(),""):string4}});var require_is_fullwidth_code_point=__commonJS({"node_modules/.pnpm/is-fullwidth-code-point@3.0.0/node_modules/is-fullwidth-code-point/index.js"(exports,module){"use strict";init_browser_globals();var isFullwidthCodePoint=codePoint=>Number.isNaN(codePoint)?!1:codePoint>=4352&&(codePoint<=4447||codePoint===9001||codePoint===9002||11904<=codePoint&&codePoint<=12871&&codePoint!==12351||12880<=codePoint&&codePoint<=19903||19968<=codePoint&&codePoint<=42182||43360<=codePoint&&codePoint<=43388||44032<=codePoint&&codePoint<=55203||63744<=codePoint&&codePoint<=64255||65040<=codePoint&&codePoint<=65049||65072<=codePoint&&codePoint<=65131||65281<=codePoint&&codePoint<=65376||65504<=codePoint&&codePoint<=65510||110592<=codePoint&&codePoint<=110593||127488<=codePoint&&codePoint<=127569||131072<=codePoint&&codePoint<=262141);module.exports=isFullwidthCodePoint;module.exports.default=isFullwidthCodePoint}});var require_emoji_regex=__commonJS({"node_modules/.pnpm/emoji-regex@8.0.0/node_modules/emoji-regex/index.js"(exports,module){"use strict";init_browser_globals();module.exports=function(){return/\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F|\uD83D\uDC68(?:\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68\uD83C\uDFFB|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|[\u2695\u2696\u2708]\uFE0F|\uD83D[\uDC66\uDC67]|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708])\uFE0F|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C[\uDFFB-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)\uD83C\uDFFB|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB\uDFFC])|\uD83D\uDC69(?:\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D\uD83D\uDC69)(?:\uD83C[\uDFFB-\uDFFD])|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|(?:(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)\uFE0F|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:(?:\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\u200D[\u2640\u2642])|\uD83C\uDFF4\u200D\u2620)\uFE0F|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF4\uD83C\uDDF2|\uD83C\uDDF6\uD83C\uDDE6|[#\*0-9]\uFE0F\u20E3|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83D\uDC69(?:\uD83C[\uDFFB-\uDFFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270A-\u270D]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC70\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDCAA\uDD74\uDD7A\uDD90\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD36\uDDB5\uDDB6\uDDBB\uDDD2-\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5\uDEEB\uDEEC\uDEF4-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFA\uDFE0-\uDFEB]|\uD83E[\uDD0D-\uDD3A\uDD3C-\uDD45\uDD47-\uDD71\uDD73-\uDD76\uDD7A-\uDDA2\uDDA5-\uDDAA\uDDAE-\uDDCA\uDDCD-\uDDFF\uDE70-\uDE73\uDE78-\uDE7A\uDE80-\uDE82\uDE90-\uDE95])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g}}});var require_string_width=__commonJS({"node_modules/.pnpm/string-width@4.2.3/node_modules/string-width/index.js"(exports,module){"use strict";init_browser_globals();var stripAnsi=require_strip_ansi(),isFullwidthCodePoint=require_is_fullwidth_code_point(),emojiRegex=require_emoji_regex(),stringWidth2=string4=>{if(typeof string4!="string"||string4.length===0||(string4=stripAnsi(string4),string4.length===0))return 0;string4=string4.replace(emojiRegex()," ");let width=0;for(let i2=0;i2<string4.length;i2++){let code4=string4.codePointAt(i2);code4<=31||code4>=127&&code4<=159||code4>=768&&code4<=879||(code4>65535&&i2++,width+=isFullwidthCodePoint(code4)?2:1)}return width};module.exports=stringWidth2;module.exports.default=stringWidth2}});var require_config=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/config.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _default=exports.default={verbose:!1}}});var require_header=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/header.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _default=exports.default=function(tuples){var state,header={};return tuples.forEach(function(tuple){var type=tuple[0],value2=tuple[1];switch(value2){case"$MEASUREMENT":{state="measurement";break}case"$INSUNITS":{state="insUnits";break}case"$EXTMIN":header.extMin={},state="extMin";break;case"$EXTMAX":header.extMax={},state="extMax";break;case"$DIMASZ":header.dimArrowSize={},state="dimArrowSize";break;default:switch(state){case"extMin":case"extMax":{switch(type){case 10:header[state].x=value2;break;case 20:header[state].y=value2;break;case 30:header[state].z=value2,state=void 0;break}break}case"measurement":case"insUnits":{type===70&&(header[state]=value2,state=void 0);break}case"dimArrowSize":{type===40&&(header[state]=value2,state=void 0);break}}}}),header}}});var require_logger=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/util/logger.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _config=_interopRequireDefault(require_config());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}function info(){_config.default.verbose&&console.info.apply(void 0,arguments)}function warn2(){_config.default.verbose&&console.warn.apply(void 0,arguments)}function error(){console.error.apply(void 0,arguments)}var _default=exports.default={info,warn:warn2,error}}});var require_tables=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/tables.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _logger=_interopRequireDefault(require_logger());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var ltypeHandler=function(tuples){var element=null,offset=null;return tuples.reduce(function(layer,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 2:layer.name=value2;break;case 3:layer.description=value2;break;case 70:layer.flag=value2;break;case 72:layer.alignment=value2;break;case 73:layer.elementCount=parseInt(value2);break;case 40:layer.patternLength=value2;break;case 49:element=Object.create({scales:[],offset:[]}),element.length=value2,layer.pattern.push(element);break;case 74:element.shape=value2;break;case 75:element.shapeNumber=value2;break;case 340:element.styleHandle=value2;break;case 46:element.scales.push(value2);break;case 50:element.rotation=value2;break;case 44:offset=Object.create({x:value2,y:0}),element.offset.push(offset);break;case 45:offset.y=value2;break;case 9:element.text=value2;break;default:}return layer},{type:"LTYPE",pattern:[]})},layerHandler=function(tuples){return tuples.reduce(function(layer,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 2:layer.name=value2;break;case 6:layer.lineTypeName=value2;break;case 62:layer.colorNumber=value2;break;case 70:layer.flags=value2;break;case 290:layer.plot=parseInt(value2)!==0;break;case 370:layer.lineWeightEnum=value2;break;default:}return layer},{type:"LAYER"})},styleHandler=function(tuples){return tuples.reduce(function(style,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 2:style.name=value2;break;case 6:style.lineTypeName=value2;break;case 40:style.fixedTextHeight=value2;break;case 41:style.widthFactor=value2;break;case 50:style.obliqueAngle=value2;break;case 71:style.flags=value2;break;case 42:style.lastHeightUsed=value2;break;case 3:style.primaryFontFileName=value2;break;case 4:style.bigFontFileName=value2;break;default:}return style},{type:"STYLE"})},vPortHandler=function(tuples){return tuples.reduce(function(vport,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 2:vport.name=value2;break;case 5:vport.handle=value2;break;case 70:vport.flags=value2;break;case 10:vport.lowerLeft.x=parseFloat(value2);break;case 20:vport.lowerLeft.y=parseFloat(value2);break;case 11:vport.upperRight.x=parseFloat(value2);break;case 21:vport.upperRight.y=parseFloat(value2);break;case 12:vport.center.x=parseFloat(value2);break;case 22:vport.center.y=parseFloat(value2);break;case 14:vport.snapSpacing.x=parseFloat(value2);break;case 24:vport.snapSpacing.y=parseFloat(value2);break;case 15:vport.gridSpacing.x=parseFloat(value2);break;case 25:vport.gridSpacing.y=parseFloat(value2);break;case 16:vport.direction.x=parseFloat(value2);break;case 26:vport.direction.y=parseFloat(value2);break;case 36:vport.direction.z=parseFloat(value2);break;case 17:vport.target.x=parseFloat(value2);break;case 27:vport.target.y=parseFloat(value2);break;case 37:vport.target.z=parseFloat(value2);break;case 45:vport.height=parseFloat(value2);break;case 50:vport.snapAngle=parseFloat(value2);break;case 51:vport.angle=parseFloat(value2);break;case 110:vport.x=parseFloat(value2);break;case 120:vport.y=parseFloat(value2);break;case 130:vport.z=parseFloat(value2);break;case 111:vport.xAxisX=parseFloat(value2);break;case 121:vport.xAxisY=parseFloat(value2);break;case 131:vport.xAxisZ=parseFloat(value2);break;case 112:vport.xAxisX=parseFloat(value2);break;case 122:vport.xAxisY=parseFloat(value2);break;case 132:vport.xAxisZ=parseFloat(value2);break;case 146:vport.elevation=parseFloat(value2);break;default:}return vport},{type:"VPORT",center:{},lowerLeft:{},upperRight:{},snap:{},snapSpacing:{},gridSpacing:{},direction:{},target:{}})},tableHandler=function(tuples,tableType,handler2){var tableRowsTuples=[],tableRowTuples;return tuples.forEach(function(tuple){var type=tuple[0],value2=tuple[1];(type===0||type===2)&&value2===tableType?(tableRowTuples=[],tableRowsTuples.push(tableRowTuples)):tableRowTuples.push(tuple)}),tableRowsTuples.reduce(function(acc,rowTuples){var tableRow=handler2(rowTuples);return tableRow.name?acc[tableRow.name]=tableRow:_logger.default.warn("table row without name:",tableRow),acc},{})},_default=exports.default=function(tuples){var tableGroups=[],tableTuples;tuples.forEach(function(tuple){var value2=tuple[1];value2==="TABLE"?(tableTuples=[],tableGroups.push(tableTuples)):value2==="ENDTAB"?tableGroups.push(tableTuples):tableTuples.push(tuple)});var stylesTuples=[],layersTuples=[],vPortTuples=[],ltypeTuples=[];return tableGroups.forEach(function(group){group[0][1]==="STYLE"?stylesTuples=group:group[0][1]==="LTYPE"?ltypeTuples=group:group[0][1]==="LAYER"?layersTuples=group:group[0][1]==="VPORT"&&(vPortTuples=group)}),{layers:tableHandler(layersTuples,"LAYER",layerHandler),styles:tableHandler(stylesTuples,"STYLE",styleHandler),vports:tableHandler(vPortTuples,"VPORT",vPortHandler),ltypes:tableHandler(ltypeTuples,"LTYPE",ltypeHandler)}}}});var require_common2=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/common.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _default=exports.default=function(type,value2){switch(type){case 5:return{handle:value2};case 6:return{lineTypeName:value2};case 8:return{layer:value2};case 48:return{lineTypeScale:value2};case 60:return{visible:value2===0};case 62:return{colorNumber:value2};case 67:return value2===0?{}:{paperSpace:value2};case 68:return{viewportOn:value2};case 69:return{viewport:value2};case 210:return{extrusionX:value2};case 220:return{extrusionY:value2};case 230:return{extrusionZ:value2};case 410:return{layout:value2};default:return{}}}}});var require_point=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/point.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="POINT",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:entity.x=value2;break;case 20:entity.y=value2;break;case 30:entity.z=value2;break;case 39:entity.thickness=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE})},_default=exports.default={TYPE,process:process2}}});var require_line=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/line.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="LINE",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:entity.start.x=value2;break;case 20:entity.start.y=value2;break;case 30:entity.start.z=value2;break;case 39:entity.thickness=value2;break;case 11:entity.end.x=value2;break;case 21:entity.end.y=value2;break;case 31:entity.end.z=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,start:{},end:{}})},_default=exports.default={TYPE,process:process2}}});var require_lwpolyline=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/lwpolyline.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="LWPOLYLINE",process2=exports.process=function(tuples){var vertex;return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 70:entity.closed=(value2&1)===1;break;case 10:vertex={x:value2,y:0},entity.vertices.push(vertex);break;case 20:vertex.y=value2;break;case 39:entity.thickness=value2;break;case 42:vertex.bulge=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,vertices:[]})},_default=exports.default={TYPE,process:process2}}});var require_polyline=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/polyline.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="POLYLINE",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 70:entity.closed=(value2&1)===1,entity.polygonMesh=(value2&16)===16,entity.polyfaceMesh=(value2&64)===64;break;case 39:entity.thickness=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,vertices:[]})},_default=exports.default={TYPE,process:process2}}});var require_vertex=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/vertex.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var TYPE=exports.TYPE="VERTEX",ensureFaces=function(entity){entity.faces=entity.faces||[],"x"in entity&&!entity.x&&delete entity.x,"y"in entity&&!entity.y&&delete entity.y,"z"in entity&&!entity.z&&delete entity.z},process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:entity.x=value2;break;case 20:entity.y=value2;break;case 30:entity.z=value2;break;case 42:entity.bulge=value2;break;case 71:ensureFaces(entity),entity.faces[0]=value2;break;case 72:ensureFaces(entity),entity.faces[1]=value2;break;case 73:ensureFaces(entity),entity.faces[2]=value2;break;case 74:ensureFaces(entity),entity.faces[3]=value2;break;default:break}return entity},{})},_default=exports.default={TYPE,process:process2}}});var require_circle=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/circle.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="CIRCLE",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:entity.x=value2;break;case 20:entity.y=value2;break;case 30:entity.z=value2;break;case 40:entity.r=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE})},_default=exports.default={TYPE,process:process2}}});var require_arc=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/arc.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="ARC",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:entity.x=value2;break;case 20:entity.y=value2;break;case 30:entity.z=value2;break;case 39:entity.thickness=value2;break;case 40:entity.r=value2;break;case 50:entity.startAngle=value2/180*Math.PI;break;case 51:entity.endAngle=value2/180*Math.PI;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE})},_default=exports.default={TYPE,process:process2}}});var require_ellipse=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/ellipse.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="ELLIPSE",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:entity.x=value2;break;case 11:entity.majorX=value2;break;case 20:entity.y=value2;break;case 21:entity.majorY=value2;break;case 30:entity.z=value2;break;case 31:entity.majorZ=value2;break;case 40:entity.axisRatio=value2;break;case 41:entity.startAngle=value2;break;case 42:entity.endAngle=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE})},_default=exports.default={TYPE,process:process2}}});var require_spline=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/spline.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="SPLINE",process2=exports.process=function(tuples){var controlPoint;return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:controlPoint={x:value2,y:0},entity.controlPoints.push(controlPoint);break;case 20:controlPoint.y=value2;break;case 30:controlPoint.z=value2;break;case 40:entity.knots.push(value2);break;case 41:entity.weights||(entity.weights=[]),entity.weights.push(value2);break;case 42:entity.knotTolerance=value2;break;case 43:entity.controlPointTolerance=value2;break;case 44:entity.fitTolerance=value2;break;case 70:entity.flag=value2,entity.closed=(value2&1)===1;break;case 71:entity.degree=value2;break;case 72:entity.numberOfKnots=value2;break;case 73:entity.numberOfControlPoints=value2;break;case 74:entity.numberOfFitPoints=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,controlPoints:[],knots:[]})},_default=exports.default={TYPE,process:process2}}});var require_solid=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/solid.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="SOLID",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:entity.corners[0].x=value2;break;case 20:entity.corners[0].y=value2;break;case 30:entity.corners[0].z=value2;break;case 11:entity.corners[1].x=value2;break;case 21:entity.corners[1].y=value2;break;case 31:entity.corners[1].z=value2;break;case 12:entity.corners[2].x=value2;break;case 22:entity.corners[2].y=value2;break;case 32:entity.corners[2].z=value2;break;case 13:entity.corners[3].x=value2;break;case 23:entity.corners[3].y=value2;break;case 33:entity.corners[3].z=value2;break;case 39:entity.thickness=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,corners:[{},{},{},{}]})},_default=exports.default={TYPE,process:process2}}});var require_hatch=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/hatch.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="HATCH",status2="IDLE",drawEntity={},drawType=0,isPolyline=!1,seed=null,loop={references:[],entities:[]},polyPoint=null,process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 100:status2="IDLE";break;case 2:entity.patternName=value2;break;case 10:status2==="IDLE"?entity.elevation.x=parseFloat(value2):status2==="POLYLINE"?(polyPoint={x:parseFloat(value2),y:0,bulge:0},loop.entities[0].points.push(polyPoint)):status2==="SEED"?(seed||(seed={x:0,y:0},entity.seeds.seeds.push(seed)),seed.x=parseFloat(value2)):fillDrawEntity(type,drawType,parseFloat(value2));break;case 20:status2==="IDLE"?entity.elevation.y=parseFloat(value2):status2==="POLYLINE"?polyPoint.y=parseFloat(value2):status2==="SEED"?(seed.y=parseFloat(value2),seed=null):fillDrawEntity(type,drawType,parseFloat(value2));break;case 30:entity.elevation.z=parseFloat(value2);break;case 63:entity.fillColor=value2;break;case 70:entity.fillType=parseFloat(value2)===1?"SOLID":"PATTERN";break;case 210:entity.extrusionDir.x=parseFloat(value2);break;case 220:entity.extrusionDir.y=parseFloat(value2);break;case 230:entity.extrusionDir.z=parseFloat(value2);break;case 91:entity.boundary.count=parseFloat(value2);break;case 92:if(loop={references:[],entities:[]},entity.boundary.loops.push(loop),loop.type=parseFloat(value2),isPolyline=(loop.type&2)===2,isPolyline){var ent={type:"POLYLINE",points:[]};loop.entities.push(ent),status2="POLYLINE"}break;case 93:status2==="IDLE"&&(status2="ENT"),loop.count=parseFloat(value2);break;case 11:case 21:case 40:case 50:case 51:case 74:case 94:case 95:case 96:drawType===4&&(status2="SPLINE"),fillDrawEntity(type,drawType,parseFloat(value2));break;case 42:isPolyline?polyPoint.bulge=parseFloat(value2):fillDrawEntity(type,drawType,parseFloat(value2));break;case 72:drawType=parseFloat(value2),loop[isPolyline?"hasBulge":"edgeType"]=drawType,isPolyline||(drawEntity=createDrawEntity(drawType),loop.entities.push(drawEntity));break;case 73:status2==="IDLE"||isPolyline?loop.entities[0].closed=value2:fillDrawEntity(type,drawType,parseFloat(value2));break;case 75:status2="IDLE",entity.style=parseFloat(value2);break;case 76:entity.hatchType=parseFloat(value2);break;case 97:status2="IDLE",isPolyline=!1,loop.sourceObjects=parseFloat(value2);break;case 98:status2="SEED",entity.seeds.count=parseFloat(value2);break;case 52:entity.shadowPatternAngle=parseFloat(value2);break;case 41:entity.spacing=parseFloat(value2);break;case 77:entity.double=parseFloat(value2)===1;break;case 78:entity.pattern.lineCount=parseFloat(value2);break;case 53:entity.pattern.angle=parseFloat(value2);break;case 43:entity.pattern.x=parseFloat(value2);break;case 44:entity.pattern.y=parseFloat(value2);break;case 45:entity.pattern.offsetX=parseFloat(value2);break;case 46:entity.pattern.offsetY=parseFloat(value2);break;case 79:entity.pattern.dashCount=parseFloat(value2);break;case 49:entity.pattern.length.push(value2);break;case 330:loop.references.push(value2);break;case 450:entity.solidOrGradient=parseFloat(value2)===0?"SOLID":"GRADIENT";break;case 453:entity.color.count=parseFloat(value2);break;case 460:entity.color.rotation=value2;break;case 461:entity.color.gradient=value2;break;case 462:entity.color.tint=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,elevation:{},extrusionDir:{x:0,y:0,z:1},pattern:{length:[]},boundary:{loops:[]},seeds:{count:0,seeds:[]},color:{}})},_default=exports.default={TYPE,process:process2};function createDrawEntity(type){if(isPolyline)return{};switch(type){case 1:return{type:"LINE",start:{x:0,y:0},end:{x:0,y:0}};case 2:return{type:"ARC",center:{x:0,y:0},radius:0,startAngle:0,endAngle:0,counterClockWise:!1};case 3:return{type:"ELLIPSE",center:{x:0,y:0},startAngle:0,endAngle:0,counterClockWise:!1,major:{x:0,y:0},minor:0};case 4:return{type:"SPLINE",degree:0,rational:0,periodic:0,knots:{count:0,knots:[]},controlPoints:{count:0,points:[]},weights:1}}return{}}function fillDrawEntity(type,drawType2,value2){switch(type){case 10:switch(drawType2){case 1:drawEntity.start.x=value2;break;case 2:drawEntity.center.x=value2;break;case 3:drawEntity.center.x=value2;break;case 4:drawEntity.controlPoints.points.push({x:value2,y:0});break}break;case 20:{switch(drawType2){case 1:drawEntity.start.y=value2;break;case 2:drawEntity.center.y=value2;break;case 3:drawEntity.center.y=value2;break;case 4:drawEntity.controlPoints.points[drawEntity.controlPoints.points.length-1].y=value2;break}break}case 11:switch(drawType2){case 1:drawEntity.end.x=value2;break;case 3:drawEntity.major.x=value2;break}break;case 21:{switch(drawType2){case 1:drawEntity.end.y=value2;break;case 3:drawEntity.major.y=value2;break}break}case 40:switch(drawType2){case 2:drawEntity.radius=value2;break;case 3:drawEntity.minor=value2;break;case 4:drawEntity.knots.knots.push(value2);break}break;case 42:drawType2===4&&(drawEntity.weights=value2);break;case 50:switch(drawType2){case 2:drawEntity.startAngle=value2;break;case 3:drawEntity.startAngle=value2;break}break;case 51:switch(drawType2){case 2:drawEntity.endAngle=value2;break;case 3:drawEntity.endAngle=value2;break}break;case 73:switch(drawType2){case 2:drawEntity.counterClockWise=parseFloat(value2)===1;break;case 3:drawEntity.counterClockWise=parseFloat(value2)===1;break;case 4:drawEntity.rational=value2;break}break;case 74:drawType2===4&&(drawEntity.periodic=value2);break;case 94:drawType2===4&&(drawEntity.degree=value2);break;case 95:drawType2===4&&(drawEntity.knots.count=value2);break;case 96:drawType2===4&&(drawEntity.controlPoints.count=value2);break}}}});var require_mtext=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/mtext.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.assign=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="MTEXT",simpleCodes={10:"x",20:"y",30:"z",40:"nominalTextHeight",41:"refRectangleWidth",71:"attachmentPoint",72:"drawingDirection",7:"styleName",11:"xAxisX",21:"xAxisY",31:"xAxisZ",42:"horizontalWidth",43:"verticalHeight",73:"lineSpacingStyle",44:"lineSpacingFactor",90:"backgroundFill",420:"bgColorRGB0",421:"bgColorRGB1",422:"bgColorRGB2",423:"bgColorRGB3",424:"bgColorRGB4",425:"bgColorRGB5",426:"bgColorRGB6",427:"bgColorRGB7",428:"bgColorRGB8",429:"bgColorRGB9",430:"bgColorName0",431:"bgColorName1",432:"bgColorName2",433:"bgColorName3",434:"bgColorName4",435:"bgColorName5",436:"bgColorName6",437:"bgColorName7",438:"bgColorName8",439:"bgColorName9",45:"fillBoxStyle",63:"bgFillColor",441:"bgFillTransparency",75:"columnType",76:"columnCount",78:"columnFlowReversed",79:"columnAutoheight",48:"columnWidth",49:"columnGutter",50:"columnHeights"},process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];return assign(entity,type,value2),entity},{type:TYPE,string:""})},assign=exports.assign=function(entity,type,value2){return simpleCodes[type]!==void 0?entity[simpleCodes[type]]=value2:type===1||type===3?entity.string+=value2:type===50?(entity.xAxisX=Math.cos(value2),entity.xAxisY=Math.sin(value2)):Object.assign(entity,(0,_common.default)(type,value2)),entity},_default=exports.default={TYPE,process:process2,assign}}});var require_text=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/text.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.assign=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="TEXT",simpleCodes={1:"string",10:"x",20:"y",30:"z",11:"x2",21:"y2",31:"z2",39:"thickness",40:"textHeight",41:"relScaleX",50:"rotation",51:"obliqueAngle",7:"styleName",71:"mirror",72:"hAlign",73:"vAlign"},process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];return assign(entity,type,value2),entity},{type:TYPE,string:""})},assign=exports.assign=function(entity,type,value2){simpleCodes[type]!==void 0?entity[simpleCodes[type]]=value2:Object.assign(entity,(0,_common.default)(type,value2))},_default=exports.default={TYPE,process:process2,assign}}});var require_attdef=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/attdef.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.assign=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2()),_mtext=require_mtext(),_text=require_text();function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="ATTDEF",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];return assign(entity,type,value2),entity},{type:TYPE,subclassMarker:"AcDbText",thickness:0,scaleX:1,mtext:{},text:{}})},assign=exports.assign=function(entity,type,value2){switch(type){case 100:{entity.subclassMarker=value2;break}case 1:switch(entity.subclassMarker){case"AcDbText":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 2:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":entity.tag=value2;break;case"AcDbXrecord":entity.attdefFlag=value2;break}break;case 3:switch(entity.subclassMarker){case"AcDbAttributeDefinition":entity.prompt=value2;break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 7:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 10:switch(entity.subclassMarker){case"AcDbText":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break;case"AcDbXrecord":entity.x=value2;break}break;case 20:switch(entity.subclassMarker){case"AcDbText":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break;case"AcDbXrecord":entity.y=value2;break}break;case 30:switch(entity.subclassMarker){case"AcDbText":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break;case"AcDbXrecord":entity.z=value2;break}break;case 11:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":entity.x2=value2;break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 21:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":entity.y2=value2;break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 31:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":entity.z2=value2;break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 39:(0,_text.assign)(entity.text,type,value2);break;case 40:switch(entity.subclassMarker){case"AcDbText":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break;case"AcDbXrecord":entity.annotationScale=value2;break}break;case 41:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 42:case 43:case 44:case 45:(0,_mtext.assign)(entity.mtext,type,value2);break;case 46:entity.mtext.annotationHeight=value2;break;case 48:case 49:(0,_mtext.assign)(entity.mtext,type,value2);break;case 50:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 51:(0,_text.assign)(entity.text,type,value2);break;case 63:(0,_mtext.assign)(entity.mtext,type,value2);break;case 70:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":entity.attributeFlags=value2;break;case"AcDbXrecord":typeof entity.mTextFlag>"u"?entity.mTextFlag=value2:typeof entity.isReallyLocked>"u"?entity.isReallyLocked=value2:entity.secondaryAttdefCount=value2;break}break;case 71:case 72:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":(0,_text.assign)(entity.text,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 73:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":entity.fieldLength=value2;break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 74:(0,_text.assign)(entity.text,73,value2);break;case 75:case 76:case 78:case 79:(0,_mtext.assign)(entity.mtext,type,value2);break;case 90:(0,_mtext.assign)(entity.mtext,type,value2);break;case 210:case 220:case 230:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":(0,_text.assign)(entity.mtext,type,value2);break;case"AcDbMText":(0,_mtext.assign)(entity.mtext,type,value2);break}break;case 280:switch(entity.subclassMarker){case"AcDbAttributeDefinition":case"AcDbAttribute":entity.lock=value2;break;case"AcDbXrecord":entity.clone=!0;break}break;case 340:entity.attdefHandle=value2;break;case 420:case 421:case 422:case 423:case 424:case 425:case 426:case 427:case 428:case 429:case 430:case 431:case 432:case 433:case 434:case 435:case 436:case 437:case 438:case 439:case 441:(0,_mtext.assign)(entity.mtext,type,value2);break;default:Object.assign(entity,(0,_common.default)(type,value2));break}},_default=exports.default={TYPE,process:process2,assign}}});var require_attrib=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/attrib.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _attdef=require_attdef(),TYPE=exports.TYPE="ATTRIB",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];return(0,_attdef.assign)(entity,type,value2),entity},{type:TYPE,subclassMarker:"AcDbText",thickness:0,scaleX:1,mtext:{},text:{}})},_default=exports.default={TYPE,process:process2}}});var require_insert=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/insert.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="INSERT",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 2:entity.block=value2;break;case 10:entity.x=value2;break;case 20:entity.y=value2;break;case 30:entity.z=value2;break;case 41:entity.scaleX=value2;break;case 42:entity.scaleY=value2;break;case 43:entity.scaleZ=value2;break;case 44:entity.columnSpacing=value2;break;case 45:entity.rowSpacing=value2;break;case 50:entity.rotation=value2;break;case 70:entity.columnCount=value2;break;case 71:entity.rowCount=value2;break;case 210:entity.extrusionX=value2;break;case 220:entity.extrusionY=value2;break;case 230:entity.extrusionZ=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE})},_default=exports.default={TYPE,process:process2}}});var require_threeDFace=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/threeDFace.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="3DFACE",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 10:entity.vertices[0].x=value2;break;case 20:entity.vertices[0].y=value2;break;case 30:entity.vertices[0].z=value2;break;case 11:entity.vertices[1].x=value2;break;case 21:entity.vertices[1].y=value2;break;case 31:entity.vertices[1].z=value2;break;case 12:entity.vertices[2].x=value2;break;case 22:entity.vertices[2].y=value2;break;case 32:entity.vertices[2].z=value2;break;case 13:entity.vertices[3].x=value2;break;case 23:entity.vertices[3].y=value2;break;case 33:entity.vertices[3].z=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,vertices:[{},{},{},{}]})},_default=exports.default={TYPE,process:process2}}});var require_dimension=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/dimension.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="DIMENSION",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 2:entity.block=value2;break;case 10:entity.start.x=value2;break;case 20:entity.start.y=value2;break;case 30:entity.start.z=value2;break;case 11:entity.textMidpoint.x=value2;break;case 21:entity.textMidpoint.y=value2;break;case 31:entity.textMidpoint.z=value2;break;case 13:entity.measureStart.x=value2;break;case 23:entity.measureStart.y=value2;break;case 33:entity.measureStart.z=value2;break;case 14:entity.measureEnd.x=value2;break;case 24:entity.measureEnd.y=value2;break;case 34:entity.measureEnd.z=value2;break;case 50:entity.rotation=value2;break;case 51:entity.horizonRotation=value2;break;case 52:entity.extensionRotation=value2;break;case 53:entity.textRotation=value2;break;case 70:{var dimType=parseBitCombinationsFromValue(value2);dimType.ordinateType&&(entity.ordinateType=!0),dimType.uniqueBlockReference&&(entity.uniqueBlockReference=!0),dimType.userDefinedLocation&&(entity.userDefinedLocation=!0),entity.dimensionType=dimType.dimensionType;break}case 71:entity.attachementPoint=value2;break;case 210:entity.extrudeDirection=entity.extrudeDirection||{},entity.extrudeDirection.x=value2;break;case 220:entity.extrudeDirection=entity.extrudeDirection||{},entity.extrudeDirection.y=value2;break;case 230:entity.extrudeDirection=entity.extrudeDirection||{},entity.extrudeDirection.z=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,start:{x:0,y:0,z:0},measureStart:{x:0,y:0,z:0},measureEnd:{x:0,y:0,z:0},textMidpoint:{x:0,y:0,z:0},attachementPoint:1,dimensionType:0})};function parseBitCombinationsFromValue(value2){var uniqueBlockReference=!1,ordinateType=!1,userDefinedLocation=!1;if(value2>6){var alt1=value2-32,alt2=value2-64,alt3=value2-32-64,alt4=value2-32-128,alt5=value2-32-64-128;alt1>=0&&alt1<=6?(uniqueBlockReference=!0,value2=alt1):alt2>=0&&alt2<=6?(ordinateType=!0,value2=alt2):alt3>=0&&alt3<=6?(uniqueBlockReference=!0,ordinateType=!0,value2=alt3):alt4>=0&&alt4<=6?(uniqueBlockReference=!0,userDefinedLocation=!0,value2=alt4):alt5>=0&&alt5<=6&&(uniqueBlockReference=!0,ordinateType=!0,userDefinedLocation=!0,value2=alt5)}return{dimensionType:value2,uniqueBlockReference,ordinateType,userDefinedLocation}}var _default=exports.default={TYPE,process:process2}}});var require_viewport=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/viewport.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="VIEWPORT",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 1:entity.layout=parseFloat(value2);break;case 10:entity.center.x=parseFloat(value2);break;case 20:entity.center.y=parseFloat(value2);break;case 30:entity.center.z=parseFloat(value2);break;case 12:entity.centerDCS.x=parseFloat(value2);break;case 22:entity.centerDCS.y=parseFloat(value2);break;case 13:entity.snap.x=parseFloat(value2);break;case 23:entity.snap.y=parseFloat(value2);break;case 14:entity.snapSpacing.x=parseFloat(value2);break;case 24:entity.snapSpacing.y=parseFloat(value2);break;case 15:entity.gridSpacing.x=parseFloat(value2);break;case 25:entity.gridSpacing.y=parseFloat(value2);break;case 16:entity.direction.x=parseFloat(value2);break;case 26:entity.direction.y=parseFloat(value2);break;case 36:entity.direction.z=parseFloat(value2);break;case 17:entity.target.x=parseFloat(value2);break;case 27:entity.target.y=parseFloat(value2);break;case 37:entity.target.z=parseFloat(value2);break;case 40:entity.width=parseFloat(value2);break;case 41:entity.height=parseFloat(value2);break;case 50:entity.snapAngle=parseFloat(value2);break;case 51:entity.angle=parseFloat(value2);break;case 68:entity.status=value2;break;case 69:entity.id=value2;break;case 90:entity.flags=value2;break;case 110:entity.x=parseFloat(value2);break;case 120:entity.y=parseFloat(value2);break;case 130:entity.z=parseFloat(value2);break;case 111:entity.xAxisX=parseFloat(value2);break;case 121:entity.xAxisY=parseFloat(value2);break;case 131:entity.xAxisZ=parseFloat(value2);break;case 112:entity.xAxisX=parseFloat(value2);break;case 122:entity.xAxisY=parseFloat(value2);break;case 132:entity.xAxisZ=parseFloat(value2);break;case 146:entity.elevation=parseFloat(value2);break;case 281:entity.render=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,center:{},centerDCS:{},snap:{},snapSpacing:{},gridSpacing:{},direction:{},target:{}})},_default=exports.default={TYPE,process:process2}}});var require_ole2Frame=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entity/ole2Frame.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.process=exports.default=exports.TYPE=void 0;var _common=_interopRequireDefault(require_common2());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var TYPE=exports.TYPE="OLE2FRAME",process2=exports.process=function(tuples){return tuples.reduce(function(entity,tuple){var type=tuple[0],value2=tuple[1];switch(type){case 70:entity.version=value2;break;case 3:entity.name=value2;break;case 10:entity.upperLeftX=value2;break;case 20:entity.upperLeftY=value2;break;case 30:entity.upperLeftZ=value2;break;case 11:entity.lowerRightX=value2;break;case 21:entity.lowerRightY=value2;break;case 31:entity.lowerRightZ=value2;break;case 71:entity.objectType=value2;break;case 72:entity.tile=value2;break;case 90:entity.length=value2;break;case 310:entity.data+=value2;break;default:Object.assign(entity,(0,_common.default)(type,value2));break}return entity},{type:TYPE,data:""})},_default=exports.default={TYPE,process:process2}}});var require_entities=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/entities.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _logger=_interopRequireDefault(require_logger()),_point=_interopRequireDefault(require_point()),_line=_interopRequireDefault(require_line()),_lwpolyline=_interopRequireDefault(require_lwpolyline()),_polyline=_interopRequireDefault(require_polyline()),_vertex=_interopRequireDefault(require_vertex()),_circle=_interopRequireDefault(require_circle()),_arc=_interopRequireDefault(require_arc()),_ellipse=_interopRequireDefault(require_ellipse()),_spline=_interopRequireDefault(require_spline()),_solid=_interopRequireDefault(require_solid()),_hatch=_interopRequireDefault(require_hatch()),_mtext=_interopRequireDefault(require_mtext()),_attdef=_interopRequireDefault(require_attdef()),_attrib=_interopRequireDefault(require_attrib()),_insert=_interopRequireDefault(require_insert()),_threeDFace=_interopRequireDefault(require_threeDFace()),_dimension=_interopRequireDefault(require_dimension()),_text=_interopRequireDefault(require_text()),_viewport=_interopRequireDefault(require_viewport()),_ole2Frame=_interopRequireDefault(require_ole2Frame());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var handlers=[_point.default,_line.default,_lwpolyline.default,_polyline.default,_vertex.default,_circle.default,_arc.default,_ellipse.default,_spline.default,_solid.default,_hatch.default,_mtext.default,_attdef.default,_attrib.default,_text.default,_insert.default,_dimension.default,_threeDFace.default,_viewport.default,_ole2Frame.default].reduce(function(acc,mod){return acc[mod.TYPE]=mod,acc},{}),_default=exports.default=function(tuples){var entities=[],entityGroups=[],currentEntityTuples;tuples.forEach(function(tuple){var type=tuple[0];type===0&&(currentEntityTuples=[],entityGroups.push(currentEntityTuples)),currentEntityTuples.push(tuple)});var currentPolyline;return entityGroups.forEach(function(tuples2){var entityType=tuples2[0][1],contentTuples=tuples2.slice(1);if(handlers[entityType]!==void 0){var e2=handlers[entityType].process(contentTuples);entityType==="POLYLINE"?(currentPolyline=e2,entities.push(e2)):entityType==="VERTEX"?currentPolyline?currentPolyline.vertices.push(e2):_logger.default.error("ignoring invalid VERTEX entity"):entityType==="SEQEND"?currentPolyline=void 0:entities.push(e2)}else _logger.default.warn("unsupported type in ENTITIES section:",entityType)}),entities}}});var require_blocks=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/blocks.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _entities=_interopRequireDefault(require_entities());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var _default=exports.default=function(tuples){var state,blocks=[],block,entitiesTuples=[];return tuples.forEach(function(tuple){var type=tuple[0],value2=tuple[1];if(value2==="BLOCK")state="block",block={},entitiesTuples=[],blocks.push(block);else if(value2==="ENDBLK")state==="entities"?block.entities=(0,_entities.default)(entitiesTuples):block.entities=[],entitiesTuples=void 0,state=void 0;else if(state==="block"&&type!==0)switch(type){case 1:block.xref=value2;break;case 2:block.name=value2;break;case 10:block.x=value2;break;case 20:block.y=value2;break;case 30:block.z=value2;break;case 67:value2!==0&&(block.paperSpace=value2);break;case 410:block.layout=value2;break;default:break}else state==="block"&&type===0?(state="entities",entitiesTuples.push(tuple)):state==="entities"&&entitiesTuples.push(tuple)}),blocks}}});var require_objects=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/handlers/objects.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _default=exports.default=function(tuples){var state,objects={layouts:[]},layout={};return tuples.forEach(function(tuple,i2){var type=tuple[0],value2=tuple[1];if(type===0&&(state="IDLE"),value2==="LAYOUT"&&(state="layout",layout={},objects.layouts.push(layout)),state==="layout"&&type!==0&&type===100&&value2==="AcDbLayout"&&(state="AcDbLayout"),state==="AcDbLayout"&&type!==0)switch(type){case 1:layout.name=value2;break;case 5:layout.handle=value2;break;case 10:layout.minLimitX=parseFloat(value2);break;case 20:layout.minLimitY=parseFloat(value2);break;case 11:layout.maxLimitX=parseFloat(value2);break;case 21:layout.maxLimitY=parseFloat(value2);break;case 12:layout.x=parseFloat(value2);break;case 22:layout.y=parseFloat(value2);break;case 32:layout.z=parseFloat(value2);break;case 14:layout.minX=parseFloat(value2);break;case 24:layout.minY=parseFloat(value2);break;case 34:layout.minZ=parseFloat(value2);break;case 15:layout.maxX=parseFloat(value2);break;case 25:layout.maxY=parseFloat(value2);break;case 35:layout.maxZ=parseFloat(value2);break;case 70:layout.flag=value2===1?"PSLTSCALE":"LIMCHECK";break;case 71:layout.tabOrder=value2;break;case 146:layout.elevation=parseFloat(value2);break;case 13:layout.ucsX=parseFloat(value2);break;case 23:layout.ucsY=parseFloat(value2);break;case 33:layout.ucsZ=parseFloat(value2);break;case 16:layout.ucsXaxisX=parseFloat(value2);break;case 26:layout.ucsXaxisY=parseFloat(value2);break;case 36:layout.ucsXaxisZ=parseFloat(value2);break;case 17:layout.ucsYaxisX=parseFloat(value2);break;case 27:layout.ucsYaxisY=parseFloat(value2);break;case 37:layout.ucsYaxisZ=parseFloat(value2);break;case 76:switch(value2){case 0:layout.ucsType="NOT ORTHOGRAPHIC";break;case 1:layout.ucsType="TOP";break;case 2:layout.ucsType="BOTTOM";break;case 3:layout.ucsType="FRONT";break;case 4:layout.ucsType="BACK";break;case 5:layout.ucsType="LEFT";break;case 6:layout.ucsType="RIGHT";break}break;case 330:layout.tableRecord=value2;break;case 331:layout.lastActiveViewport=value2;break;case 333:layout.shadePlot=value2;break}}),objects}}});var require_parseString=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/parseString.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _header=_interopRequireDefault(require_header()),_tables=_interopRequireDefault(require_tables()),_blocks=_interopRequireDefault(require_blocks()),_entities=_interopRequireDefault(require_entities()),_objects=_interopRequireDefault(require_objects()),_logger=_interopRequireDefault(require_logger());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}function _createForOfIteratorHelper(r2,e2){var t3=typeof Symbol<"u"&&r2[Symbol.iterator]||r2["@@iterator"];if(!t3){if(Array.isArray(r2)||(t3=_unsupportedIterableToArray(r2))||e2&&r2&&typeof r2.length=="number"){t3&&(r2=t3);var _n2=0,F=function(){};return{s:F,n:function(){return _n2>=r2.length?{done:!0}:{done:!1,value:r2[_n2++]}},e:function(r3){throw r3},f:F}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
51
51
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o2,a2=!0,u2=!1;return{s:function(){t3=t3.call(r2)},n:function(){var r3=t3.next();return a2=r3.done,r3},e:function(r3){u2=!0,o2=r3},f:function(){try{a2||t3.return==null||t3.return()}finally{if(u2)throw o2}}}}function _unsupportedIterableToArray(r2,a2){if(r2){if(typeof r2=="string")return _arrayLikeToArray(r2,a2);var t3={}.toString.call(r2).slice(8,-1);return t3==="Object"&&r2.constructor&&(t3=r2.constructor.name),t3==="Map"||t3==="Set"?Array.from(r2):t3==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t3)?_arrayLikeToArray(r2,a2):void 0}}function _arrayLikeToArray(r2,a2){(a2==null||a2>r2.length)&&(a2=r2.length);for(var e2=0,n2=Array(a2);e2<a2;e2++)n2[e2]=r2[e2];return n2}var parseValue2=function(type,value2){return type>=10&&type<60||type>=210&&type<240?parseFloat(value2,10):type>=60&&type<100?parseInt(value2,10):value2},convertToTypesAndValues=function(contentLines){var state="type",type,typesAndValues=[],_iterator=_createForOfIteratorHelper(contentLines),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var line2=_step.value;state==="type"?(type=parseInt(line2,10),state="value"):(typesAndValues.push([type,parseValue2(type,line2)]),state="type")}}catch(err){_iterator.e(err)}finally{_iterator.f()}return typesAndValues},separateSections=function(tuples){var sectionTuples;return tuples.reduce(function(sections,tuple){return tuple[0]===0&&tuple[1]==="SECTION"?sectionTuples=[]:tuple[0]===0&&tuple[1]==="ENDSEC"?(sections.push(sectionTuples),sectionTuples=void 0):sectionTuples!==void 0&§ionTuples.push(tuple),sections},[])},reduceSection=function(acc,section){var sectionType=section[0][1],contentTuples=section.slice(1);switch(sectionType){case"HEADER":acc.header=(0,_header.default)(contentTuples);break;case"TABLES":acc.tables=(0,_tables.default)(contentTuples);break;case"BLOCKS":acc.blocks=(0,_blocks.default)(contentTuples);break;case"ENTITIES":acc.entities=(0,_entities.default)(contentTuples);break;case"OBJECTS":acc.objects=(0,_objects.default)(contentTuples);break;default:_logger.default.warn("Unsupported section: ".concat(sectionType))}return acc},_default=exports.default=function(string4){var lines=string4.split(/\r\n|\r|\n/g),tuples=convertToTypesAndValues(lines),sections=separateSections(tuples),result=sections.reduce(reduceSection,{header:{},blocks:[],entities:[],objects:{layouts:[]},tables:{layers:{},styles:{},ltypes:{}}});return result}}});var require_listCacheClear=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_listCacheClear.js"(exports,module){init_browser_globals();function listCacheClear(){this.__data__=[],this.size=0}module.exports=listCacheClear}});var require_eq=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/eq.js"(exports,module){init_browser_globals();function eq(value2,other){return value2===other||value2!==value2&&other!==other}module.exports=eq}});var require_assocIndexOf=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_assocIndexOf.js"(exports,module){init_browser_globals();var eq=require_eq();function assocIndexOf(array,key){for(var length=array.length;length--;)if(eq(array[length][0],key))return length;return-1}module.exports=assocIndexOf}});var require_listCacheDelete=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_listCacheDelete.js"(exports,module){init_browser_globals();var assocIndexOf=require_assocIndexOf(),arrayProto=Array.prototype,splice2=arrayProto.splice;function listCacheDelete(key){var data=this.__data__,index4=assocIndexOf(data,key);if(index4<0)return!1;var lastIndex=data.length-1;return index4==lastIndex?data.pop():splice2.call(data,index4,1),--this.size,!0}module.exports=listCacheDelete}});var require_listCacheGet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_listCacheGet.js"(exports,module){init_browser_globals();var assocIndexOf=require_assocIndexOf();function listCacheGet(key){var data=this.__data__,index4=assocIndexOf(data,key);return index4<0?void 0:data[index4][1]}module.exports=listCacheGet}});var require_listCacheHas=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_listCacheHas.js"(exports,module){init_browser_globals();var assocIndexOf=require_assocIndexOf();function listCacheHas(key){return assocIndexOf(this.__data__,key)>-1}module.exports=listCacheHas}});var require_listCacheSet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_listCacheSet.js"(exports,module){init_browser_globals();var assocIndexOf=require_assocIndexOf();function listCacheSet(key,value2){var data=this.__data__,index4=assocIndexOf(data,key);return index4<0?(++this.size,data.push([key,value2])):data[index4][1]=value2,this}module.exports=listCacheSet}});var require_ListCache=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_ListCache.js"(exports,module){init_browser_globals();var listCacheClear=require_listCacheClear(),listCacheDelete=require_listCacheDelete(),listCacheGet=require_listCacheGet(),listCacheHas=require_listCacheHas(),listCacheSet=require_listCacheSet();function ListCache(entries){var index4=-1,length=entries==null?0:entries.length;for(this.clear();++index4<length;){var entry=entries[index4];this.set(entry[0],entry[1])}}ListCache.prototype.clear=listCacheClear;ListCache.prototype.delete=listCacheDelete;ListCache.prototype.get=listCacheGet;ListCache.prototype.has=listCacheHas;ListCache.prototype.set=listCacheSet;module.exports=ListCache}});var require_stackClear=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_stackClear.js"(exports,module){init_browser_globals();var ListCache=require_ListCache();function stackClear(){this.__data__=new ListCache,this.size=0}module.exports=stackClear}});var require_stackDelete=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_stackDelete.js"(exports,module){init_browser_globals();function stackDelete(key){var data=this.__data__,result=data.delete(key);return this.size=data.size,result}module.exports=stackDelete}});var require_stackGet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_stackGet.js"(exports,module){init_browser_globals();function stackGet(key){return this.__data__.get(key)}module.exports=stackGet}});var require_stackHas=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_stackHas.js"(exports,module){init_browser_globals();function stackHas(key){return this.__data__.has(key)}module.exports=stackHas}});var require_freeGlobal=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_freeGlobal.js"(exports,module){init_browser_globals();var freeGlobal=typeof global=="object"&&global&&global.Object===Object&&global;module.exports=freeGlobal}});var require_root2=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_root.js"(exports,module){init_browser_globals();var freeGlobal=require_freeGlobal(),freeSelf=typeof self=="object"&&self&&self.Object===Object&&self,root4=freeGlobal||freeSelf||Function("return this")();module.exports=root4}});var require_Symbol=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_Symbol.js"(exports,module){init_browser_globals();var root4=require_root2(),Symbol2=root4.Symbol;module.exports=Symbol2}});var require_getRawTag=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getRawTag.js"(exports,module){init_browser_globals();var Symbol2=require_Symbol(),objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty,nativeObjectToString=objectProto.toString,symToStringTag=Symbol2?Symbol2.toStringTag:void 0;function getRawTag(value2){var isOwn=hasOwnProperty2.call(value2,symToStringTag),tag2=value2[symToStringTag];try{value2[symToStringTag]=void 0;var unmasked=!0}catch{}var result=nativeObjectToString.call(value2);return unmasked&&(isOwn?value2[symToStringTag]=tag2:delete value2[symToStringTag]),result}module.exports=getRawTag}});var require_objectToString=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_objectToString.js"(exports,module){init_browser_globals();var objectProto=Object.prototype,nativeObjectToString=objectProto.toString;function objectToString(value2){return nativeObjectToString.call(value2)}module.exports=objectToString}});var require_baseGetTag=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseGetTag.js"(exports,module){init_browser_globals();var Symbol2=require_Symbol(),getRawTag=require_getRawTag(),objectToString=require_objectToString(),nullTag2="[object Null]",undefinedTag="[object Undefined]",symToStringTag=Symbol2?Symbol2.toStringTag:void 0;function baseGetTag(value2){return value2==null?value2===void 0?undefinedTag:nullTag2:symToStringTag&&symToStringTag in Object(value2)?getRawTag(value2):objectToString(value2)}module.exports=baseGetTag}});var require_isObject=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isObject.js"(exports,module){init_browser_globals();function isObject3(value2){var type=typeof value2;return value2!=null&&(type=="object"||type=="function")}module.exports=isObject3}});var require_isFunction=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isFunction.js"(exports,module){init_browser_globals();var baseGetTag=require_baseGetTag(),isObject3=require_isObject(),asyncTag="[object AsyncFunction]",funcTag="[object Function]",genTag="[object GeneratorFunction]",proxyTag="[object Proxy]";function isFunction2(value2){if(!isObject3(value2))return!1;var tag2=baseGetTag(value2);return tag2==funcTag||tag2==genTag||tag2==asyncTag||tag2==proxyTag}module.exports=isFunction2}});var require_coreJsData=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_coreJsData.js"(exports,module){init_browser_globals();var root4=require_root2(),coreJsData=root4["__core-js_shared__"];module.exports=coreJsData}});var require_isMasked=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_isMasked.js"(exports,module){init_browser_globals();var coreJsData=require_coreJsData(),maskSrcKey=(function(){var uid=/[^.]+$/.exec(coreJsData&&coreJsData.keys&&coreJsData.keys.IE_PROTO||"");return uid?"Symbol(src)_1."+uid:""})();function isMasked(func){return!!maskSrcKey&&maskSrcKey in func}module.exports=isMasked}});var require_toSource=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_toSource.js"(exports,module){init_browser_globals();var funcProto=Function.prototype,funcToString=funcProto.toString;function toSource(func){if(func!=null){try{return funcToString.call(func)}catch{}try{return func+""}catch{}}return""}module.exports=toSource}});var require_baseIsNative=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseIsNative.js"(exports,module){init_browser_globals();var isFunction2=require_isFunction(),isMasked=require_isMasked(),isObject3=require_isObject(),toSource=require_toSource(),reRegExpChar=/[\\^$.*+?()[\]{}|]/g,reIsHostCtor=/^\[object .+?Constructor\]$/,funcProto=Function.prototype,objectProto=Object.prototype,funcToString=funcProto.toString,hasOwnProperty2=objectProto.hasOwnProperty,reIsNative=RegExp("^"+funcToString.call(hasOwnProperty2).replace(reRegExpChar,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function baseIsNative(value2){if(!isObject3(value2)||isMasked(value2))return!1;var pattern=isFunction2(value2)?reIsNative:reIsHostCtor;return pattern.test(toSource(value2))}module.exports=baseIsNative}});var require_getValue=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getValue.js"(exports,module){init_browser_globals();function getValue(object,key){return object?.[key]}module.exports=getValue}});var require_getNative=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getNative.js"(exports,module){init_browser_globals();var baseIsNative=require_baseIsNative(),getValue=require_getValue();function getNative(object,key){var value2=getValue(object,key);return baseIsNative(value2)?value2:void 0}module.exports=getNative}});var require_Map=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_Map.js"(exports,module){init_browser_globals();var getNative=require_getNative(),root4=require_root2(),Map2=getNative(root4,"Map");module.exports=Map2}});var require_nativeCreate=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_nativeCreate.js"(exports,module){init_browser_globals();var getNative=require_getNative(),nativeCreate=getNative(Object,"create");module.exports=nativeCreate}});var require_hashClear=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_hashClear.js"(exports,module){init_browser_globals();var nativeCreate=require_nativeCreate();function hashClear(){this.__data__=nativeCreate?nativeCreate(null):{},this.size=0}module.exports=hashClear}});var require_hashDelete=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_hashDelete.js"(exports,module){init_browser_globals();function hashDelete(key){var result=this.has(key)&&delete this.__data__[key];return this.size-=result?1:0,result}module.exports=hashDelete}});var require_hashGet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_hashGet.js"(exports,module){init_browser_globals();var nativeCreate=require_nativeCreate(),HASH_UNDEFINED="__lodash_hash_undefined__",objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty;function hashGet(key){var data=this.__data__;if(nativeCreate){var result=data[key];return result===HASH_UNDEFINED?void 0:result}return hasOwnProperty2.call(data,key)?data[key]:void 0}module.exports=hashGet}});var require_hashHas=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_hashHas.js"(exports,module){init_browser_globals();var nativeCreate=require_nativeCreate(),objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty;function hashHas(key){var data=this.__data__;return nativeCreate?data[key]!==void 0:hasOwnProperty2.call(data,key)}module.exports=hashHas}});var require_hashSet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_hashSet.js"(exports,module){init_browser_globals();var nativeCreate=require_nativeCreate(),HASH_UNDEFINED="__lodash_hash_undefined__";function hashSet(key,value2){var data=this.__data__;return this.size+=this.has(key)?0:1,data[key]=nativeCreate&&value2===void 0?HASH_UNDEFINED:value2,this}module.exports=hashSet}});var require_Hash=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_Hash.js"(exports,module){init_browser_globals();var hashClear=require_hashClear(),hashDelete=require_hashDelete(),hashGet=require_hashGet(),hashHas=require_hashHas(),hashSet=require_hashSet();function Hash2(entries){var index4=-1,length=entries==null?0:entries.length;for(this.clear();++index4<length;){var entry=entries[index4];this.set(entry[0],entry[1])}}Hash2.prototype.clear=hashClear;Hash2.prototype.delete=hashDelete;Hash2.prototype.get=hashGet;Hash2.prototype.has=hashHas;Hash2.prototype.set=hashSet;module.exports=Hash2}});var require_mapCacheClear=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_mapCacheClear.js"(exports,module){init_browser_globals();var Hash2=require_Hash(),ListCache=require_ListCache(),Map2=require_Map();function mapCacheClear(){this.size=0,this.__data__={hash:new Hash2,map:new(Map2||ListCache),string:new Hash2}}module.exports=mapCacheClear}});var require_isKeyable=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_isKeyable.js"(exports,module){init_browser_globals();function isKeyable(value2){var type=typeof value2;return type=="string"||type=="number"||type=="symbol"||type=="boolean"?value2!=="__proto__":value2===null}module.exports=isKeyable}});var require_getMapData=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getMapData.js"(exports,module){init_browser_globals();var isKeyable=require_isKeyable();function getMapData(map5,key){var data=map5.__data__;return isKeyable(key)?data[typeof key=="string"?"string":"hash"]:data.map}module.exports=getMapData}});var require_mapCacheDelete=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_mapCacheDelete.js"(exports,module){init_browser_globals();var getMapData=require_getMapData();function mapCacheDelete(key){var result=getMapData(this,key).delete(key);return this.size-=result?1:0,result}module.exports=mapCacheDelete}});var require_mapCacheGet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_mapCacheGet.js"(exports,module){init_browser_globals();var getMapData=require_getMapData();function mapCacheGet(key){return getMapData(this,key).get(key)}module.exports=mapCacheGet}});var require_mapCacheHas=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_mapCacheHas.js"(exports,module){init_browser_globals();var getMapData=require_getMapData();function mapCacheHas(key){return getMapData(this,key).has(key)}module.exports=mapCacheHas}});var require_mapCacheSet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_mapCacheSet.js"(exports,module){init_browser_globals();var getMapData=require_getMapData();function mapCacheSet(key,value2){var data=getMapData(this,key),size=data.size;return data.set(key,value2),this.size+=data.size==size?0:1,this}module.exports=mapCacheSet}});var require_MapCache=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_MapCache.js"(exports,module){init_browser_globals();var mapCacheClear=require_mapCacheClear(),mapCacheDelete=require_mapCacheDelete(),mapCacheGet=require_mapCacheGet(),mapCacheHas=require_mapCacheHas(),mapCacheSet=require_mapCacheSet();function MapCache(entries){var index4=-1,length=entries==null?0:entries.length;for(this.clear();++index4<length;){var entry=entries[index4];this.set(entry[0],entry[1])}}MapCache.prototype.clear=mapCacheClear;MapCache.prototype.delete=mapCacheDelete;MapCache.prototype.get=mapCacheGet;MapCache.prototype.has=mapCacheHas;MapCache.prototype.set=mapCacheSet;module.exports=MapCache}});var require_stackSet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_stackSet.js"(exports,module){init_browser_globals();var ListCache=require_ListCache(),Map2=require_Map(),MapCache=require_MapCache(),LARGE_ARRAY_SIZE=200;function stackSet(key,value2){var data=this.__data__;if(data instanceof ListCache){var pairs2=data.__data__;if(!Map2||pairs2.length<LARGE_ARRAY_SIZE-1)return pairs2.push([key,value2]),this.size=++data.size,this;data=this.__data__=new MapCache(pairs2)}return data.set(key,value2),this.size=data.size,this}module.exports=stackSet}});var require_Stack=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_Stack.js"(exports,module){init_browser_globals();var ListCache=require_ListCache(),stackClear=require_stackClear(),stackDelete=require_stackDelete(),stackGet=require_stackGet(),stackHas=require_stackHas(),stackSet=require_stackSet();function Stack(entries){var data=this.__data__=new ListCache(entries);this.size=data.size}Stack.prototype.clear=stackClear;Stack.prototype.delete=stackDelete;Stack.prototype.get=stackGet;Stack.prototype.has=stackHas;Stack.prototype.set=stackSet;module.exports=Stack}});var require_arrayEach=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_arrayEach.js"(exports,module){init_browser_globals();function arrayEach(array,iteratee){for(var index4=-1,length=array==null?0:array.length;++index4<length&&iteratee(array[index4],index4,array)!==!1;);return array}module.exports=arrayEach}});var require_defineProperty=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_defineProperty.js"(exports,module){init_browser_globals();var getNative=require_getNative(),defineProperty=(function(){try{var func=getNative(Object,"defineProperty");return func({},"",{}),func}catch{}})();module.exports=defineProperty}});var require_baseAssignValue=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseAssignValue.js"(exports,module){init_browser_globals();var defineProperty=require_defineProperty();function baseAssignValue(object,key,value2){key=="__proto__"&&defineProperty?defineProperty(object,key,{configurable:!0,enumerable:!0,value:value2,writable:!0}):object[key]=value2}module.exports=baseAssignValue}});var require_assignValue=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_assignValue.js"(exports,module){init_browser_globals();var baseAssignValue=require_baseAssignValue(),eq=require_eq(),objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty;function assignValue(object,key,value2){var objValue=object[key];(!(hasOwnProperty2.call(object,key)&&eq(objValue,value2))||value2===void 0&&!(key in object))&&baseAssignValue(object,key,value2)}module.exports=assignValue}});var require_copyObject=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_copyObject.js"(exports,module){init_browser_globals();var assignValue=require_assignValue(),baseAssignValue=require_baseAssignValue();function copyObject(source2,props,object,customizer){var isNew=!object;object||(object={});for(var index4=-1,length=props.length;++index4<length;){var key=props[index4],newValue=customizer?customizer(object[key],source2[key],key,object,source2):void 0;newValue===void 0&&(newValue=source2[key]),isNew?baseAssignValue(object,key,newValue):assignValue(object,key,newValue)}return object}module.exports=copyObject}});var require_baseTimes=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseTimes.js"(exports,module){init_browser_globals();function baseTimes(n2,iteratee){for(var index4=-1,result=Array(n2);++index4<n2;)result[index4]=iteratee(index4);return result}module.exports=baseTimes}});var require_isObjectLike=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isObjectLike.js"(exports,module){init_browser_globals();function isObjectLike(value2){return value2!=null&&typeof value2=="object"}module.exports=isObjectLike}});var require_baseIsArguments=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseIsArguments.js"(exports,module){init_browser_globals();var baseGetTag=require_baseGetTag(),isObjectLike=require_isObjectLike(),argsTag="[object Arguments]";function baseIsArguments(value2){return isObjectLike(value2)&&baseGetTag(value2)==argsTag}module.exports=baseIsArguments}});var require_isArguments=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isArguments.js"(exports,module){init_browser_globals();var baseIsArguments=require_baseIsArguments(),isObjectLike=require_isObjectLike(),objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty,propertyIsEnumerable=objectProto.propertyIsEnumerable,isArguments=baseIsArguments((function(){return arguments})())?baseIsArguments:function(value2){return isObjectLike(value2)&&hasOwnProperty2.call(value2,"callee")&&!propertyIsEnumerable.call(value2,"callee")};module.exports=isArguments}});var require_isArray=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isArray.js"(exports,module){init_browser_globals();var isArray=Array.isArray;module.exports=isArray}});var require_stubFalse=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/stubFalse.js"(exports,module){init_browser_globals();function stubFalse(){return!1}module.exports=stubFalse}});var require_isBuffer=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isBuffer.js"(exports,module){init_browser_globals();var root4=require_root2(),stubFalse=require_stubFalse(),freeExports=typeof exports=="object"&&exports&&!exports.nodeType&&exports,freeModule=freeExports&&typeof module=="object"&&module&&!module.nodeType&&module,moduleExports=freeModule&&freeModule.exports===freeExports,Buffer6=moduleExports?root4.Buffer:void 0,nativeIsBuffer=Buffer6?Buffer6.isBuffer:void 0,isBuffer=nativeIsBuffer||stubFalse;module.exports=isBuffer}});var require_isIndex=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_isIndex.js"(exports,module){init_browser_globals();var MAX_SAFE_INTEGER=9007199254740991,reIsUint=/^(?:0|[1-9]\d*)$/;function isIndex(value2,length){var type=typeof value2;return length=length??MAX_SAFE_INTEGER,!!length&&(type=="number"||type!="symbol"&&reIsUint.test(value2))&&value2>-1&&value2%1==0&&value2<length}module.exports=isIndex}});var require_isLength=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isLength.js"(exports,module){init_browser_globals();var MAX_SAFE_INTEGER=9007199254740991;function isLength(value2){return typeof value2=="number"&&value2>-1&&value2%1==0&&value2<=MAX_SAFE_INTEGER}module.exports=isLength}});var require_baseIsTypedArray=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseIsTypedArray.js"(exports,module){init_browser_globals();var baseGetTag=require_baseGetTag(),isLength=require_isLength(),isObjectLike=require_isObjectLike(),argsTag="[object Arguments]",arrayTag="[object Array]",boolTag2="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",funcTag="[object Function]",mapTag="[object Map]",numberTag="[object Number]",objectTag="[object Object]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",weakMapTag="[object WeakMap]",arrayBufferTag="[object ArrayBuffer]",dataViewTag="[object DataView]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]",typedArrayTags={};typedArrayTags[float32Tag]=typedArrayTags[float64Tag]=typedArrayTags[int8Tag]=typedArrayTags[int16Tag]=typedArrayTags[int32Tag]=typedArrayTags[uint8Tag]=typedArrayTags[uint8ClampedTag]=typedArrayTags[uint16Tag]=typedArrayTags[uint32Tag]=!0;typedArrayTags[argsTag]=typedArrayTags[arrayTag]=typedArrayTags[arrayBufferTag]=typedArrayTags[boolTag2]=typedArrayTags[dataViewTag]=typedArrayTags[dateTag]=typedArrayTags[errorTag]=typedArrayTags[funcTag]=typedArrayTags[mapTag]=typedArrayTags[numberTag]=typedArrayTags[objectTag]=typedArrayTags[regexpTag]=typedArrayTags[setTag]=typedArrayTags[stringTag]=typedArrayTags[weakMapTag]=!1;function baseIsTypedArray(value2){return isObjectLike(value2)&&isLength(value2.length)&&!!typedArrayTags[baseGetTag(value2)]}module.exports=baseIsTypedArray}});var require_baseUnary=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseUnary.js"(exports,module){init_browser_globals();function baseUnary(func){return function(value2){return func(value2)}}module.exports=baseUnary}});var require_nodeUtil=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_nodeUtil.js"(exports,module){init_browser_globals();var freeGlobal=require_freeGlobal(),freeExports=typeof exports=="object"&&exports&&!exports.nodeType&&exports,freeModule=freeExports&&typeof module=="object"&&module&&!module.nodeType&&module,moduleExports=freeModule&&freeModule.exports===freeExports,freeProcess=moduleExports&&freeGlobal.process,nodeUtil=(function(){try{var types2=freeModule&&freeModule.require&&freeModule.require("util").types;return types2||freeProcess&&freeProcess.binding&&freeProcess.binding("util")}catch{}})();module.exports=nodeUtil}});var require_isTypedArray=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isTypedArray.js"(exports,module){init_browser_globals();var baseIsTypedArray=require_baseIsTypedArray(),baseUnary=require_baseUnary(),nodeUtil=require_nodeUtil(),nodeIsTypedArray=nodeUtil&&nodeUtil.isTypedArray,isTypedArray=nodeIsTypedArray?baseUnary(nodeIsTypedArray):baseIsTypedArray;module.exports=isTypedArray}});var require_arrayLikeKeys=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_arrayLikeKeys.js"(exports,module){init_browser_globals();var baseTimes=require_baseTimes(),isArguments=require_isArguments(),isArray=require_isArray(),isBuffer=require_isBuffer(),isIndex=require_isIndex(),isTypedArray=require_isTypedArray(),objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty;function arrayLikeKeys(value2,inherited){var isArr=isArray(value2),isArg=!isArr&&isArguments(value2),isBuff=!isArr&&!isArg&&isBuffer(value2),isType=!isArr&&!isArg&&!isBuff&&isTypedArray(value2),skipIndexes=isArr||isArg||isBuff||isType,result=skipIndexes?baseTimes(value2.length,String):[],length=result.length;for(var key in value2)(inherited||hasOwnProperty2.call(value2,key))&&!(skipIndexes&&(key=="length"||isBuff&&(key=="offset"||key=="parent")||isType&&(key=="buffer"||key=="byteLength"||key=="byteOffset")||isIndex(key,length)))&&result.push(key);return result}module.exports=arrayLikeKeys}});var require_isPrototype=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_isPrototype.js"(exports,module){init_browser_globals();var objectProto=Object.prototype;function isPrototype(value2){var Ctor=value2&&value2.constructor,proto=typeof Ctor=="function"&&Ctor.prototype||objectProto;return value2===proto}module.exports=isPrototype}});var require_overArg=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_overArg.js"(exports,module){init_browser_globals();function overArg(func,transform){return function(arg){return func(transform(arg))}}module.exports=overArg}});var require_nativeKeys=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_nativeKeys.js"(exports,module){init_browser_globals();var overArg=require_overArg(),nativeKeys=overArg(Object.keys,Object);module.exports=nativeKeys}});var require_baseKeys=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseKeys.js"(exports,module){init_browser_globals();var isPrototype=require_isPrototype(),nativeKeys=require_nativeKeys(),objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty;function baseKeys(object){if(!isPrototype(object))return nativeKeys(object);var result=[];for(var key in Object(object))hasOwnProperty2.call(object,key)&&key!="constructor"&&result.push(key);return result}module.exports=baseKeys}});var require_isArrayLike=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isArrayLike.js"(exports,module){init_browser_globals();var isFunction2=require_isFunction(),isLength=require_isLength();function isArrayLike(value2){return value2!=null&&isLength(value2.length)&&!isFunction2(value2)}module.exports=isArrayLike}});var require_keys=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/keys.js"(exports,module){init_browser_globals();var arrayLikeKeys=require_arrayLikeKeys(),baseKeys=require_baseKeys(),isArrayLike=require_isArrayLike();function keys(object){return isArrayLike(object)?arrayLikeKeys(object):baseKeys(object)}module.exports=keys}});var require_baseAssign=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseAssign.js"(exports,module){init_browser_globals();var copyObject=require_copyObject(),keys=require_keys();function baseAssign(object,source2){return object&©Object(source2,keys(source2),object)}module.exports=baseAssign}});var require_nativeKeysIn=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_nativeKeysIn.js"(exports,module){init_browser_globals();function nativeKeysIn(object){var result=[];if(object!=null)for(var key in Object(object))result.push(key);return result}module.exports=nativeKeysIn}});var require_baseKeysIn=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseKeysIn.js"(exports,module){init_browser_globals();var isObject3=require_isObject(),isPrototype=require_isPrototype(),nativeKeysIn=require_nativeKeysIn(),objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty;function baseKeysIn(object){if(!isObject3(object))return nativeKeysIn(object);var isProto=isPrototype(object),result=[];for(var key in object)key=="constructor"&&(isProto||!hasOwnProperty2.call(object,key))||result.push(key);return result}module.exports=baseKeysIn}});var require_keysIn=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/keysIn.js"(exports,module){init_browser_globals();var arrayLikeKeys=require_arrayLikeKeys(),baseKeysIn=require_baseKeysIn(),isArrayLike=require_isArrayLike();function keysIn(object){return isArrayLike(object)?arrayLikeKeys(object,!0):baseKeysIn(object)}module.exports=keysIn}});var require_baseAssignIn=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseAssignIn.js"(exports,module){init_browser_globals();var copyObject=require_copyObject(),keysIn=require_keysIn();function baseAssignIn(object,source2){return object&©Object(source2,keysIn(source2),object)}module.exports=baseAssignIn}});var require_cloneBuffer=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_cloneBuffer.js"(exports,module){init_browser_globals();var root4=require_root2(),freeExports=typeof exports=="object"&&exports&&!exports.nodeType&&exports,freeModule=freeExports&&typeof module=="object"&&module&&!module.nodeType&&module,moduleExports=freeModule&&freeModule.exports===freeExports,Buffer6=moduleExports?root4.Buffer:void 0,allocUnsafe=Buffer6?Buffer6.allocUnsafe:void 0;function cloneBuffer(buffer,isDeep){if(isDeep)return buffer.slice();var length=buffer.length,result=allocUnsafe?allocUnsafe(length):new buffer.constructor(length);return buffer.copy(result),result}module.exports=cloneBuffer}});var require_copyArray=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_copyArray.js"(exports,module){init_browser_globals();function copyArray(source2,array){var index4=-1,length=source2.length;for(array||(array=Array(length));++index4<length;)array[index4]=source2[index4];return array}module.exports=copyArray}});var require_arrayFilter=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_arrayFilter.js"(exports,module){init_browser_globals();function arrayFilter(array,predicate){for(var index4=-1,length=array==null?0:array.length,resIndex=0,result=[];++index4<length;){var value2=array[index4];predicate(value2,index4,array)&&(result[resIndex++]=value2)}return result}module.exports=arrayFilter}});var require_stubArray=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/stubArray.js"(exports,module){init_browser_globals();function stubArray(){return[]}module.exports=stubArray}});var require_getSymbols=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getSymbols.js"(exports,module){init_browser_globals();var arrayFilter=require_arrayFilter(),stubArray=require_stubArray(),objectProto=Object.prototype,propertyIsEnumerable=objectProto.propertyIsEnumerable,nativeGetSymbols=Object.getOwnPropertySymbols,getSymbols=nativeGetSymbols?function(object){return object==null?[]:(object=Object(object),arrayFilter(nativeGetSymbols(object),function(symbol){return propertyIsEnumerable.call(object,symbol)}))}:stubArray;module.exports=getSymbols}});var require_copySymbols=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_copySymbols.js"(exports,module){init_browser_globals();var copyObject=require_copyObject(),getSymbols=require_getSymbols();function copySymbols(source2,object){return copyObject(source2,getSymbols(source2),object)}module.exports=copySymbols}});var require_arrayPush=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_arrayPush.js"(exports,module){init_browser_globals();function arrayPush(array,values){for(var index4=-1,length=values.length,offset=array.length;++index4<length;)array[offset+index4]=values[index4];return array}module.exports=arrayPush}});var require_getPrototype=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getPrototype.js"(exports,module){init_browser_globals();var overArg=require_overArg(),getPrototype=overArg(Object.getPrototypeOf,Object);module.exports=getPrototype}});var require_getSymbolsIn=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getSymbolsIn.js"(exports,module){init_browser_globals();var arrayPush=require_arrayPush(),getPrototype=require_getPrototype(),getSymbols=require_getSymbols(),stubArray=require_stubArray(),nativeGetSymbols=Object.getOwnPropertySymbols,getSymbolsIn=nativeGetSymbols?function(object){for(var result=[];object;)arrayPush(result,getSymbols(object)),object=getPrototype(object);return result}:stubArray;module.exports=getSymbolsIn}});var require_copySymbolsIn=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_copySymbolsIn.js"(exports,module){init_browser_globals();var copyObject=require_copyObject(),getSymbolsIn=require_getSymbolsIn();function copySymbolsIn(source2,object){return copyObject(source2,getSymbolsIn(source2),object)}module.exports=copySymbolsIn}});var require_baseGetAllKeys=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseGetAllKeys.js"(exports,module){init_browser_globals();var arrayPush=require_arrayPush(),isArray=require_isArray();function baseGetAllKeys(object,keysFunc,symbolsFunc){var result=keysFunc(object);return isArray(object)?result:arrayPush(result,symbolsFunc(object))}module.exports=baseGetAllKeys}});var require_getAllKeys=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getAllKeys.js"(exports,module){init_browser_globals();var baseGetAllKeys=require_baseGetAllKeys(),getSymbols=require_getSymbols(),keys=require_keys();function getAllKeys(object){return baseGetAllKeys(object,keys,getSymbols)}module.exports=getAllKeys}});var require_getAllKeysIn=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getAllKeysIn.js"(exports,module){init_browser_globals();var baseGetAllKeys=require_baseGetAllKeys(),getSymbolsIn=require_getSymbolsIn(),keysIn=require_keysIn();function getAllKeysIn(object){return baseGetAllKeys(object,keysIn,getSymbolsIn)}module.exports=getAllKeysIn}});var require_DataView=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_DataView.js"(exports,module){init_browser_globals();var getNative=require_getNative(),root4=require_root2(),DataView2=getNative(root4,"DataView");module.exports=DataView2}});var require_Promise=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_Promise.js"(exports,module){init_browser_globals();var getNative=require_getNative(),root4=require_root2(),Promise2=getNative(root4,"Promise");module.exports=Promise2}});var require_Set=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_Set.js"(exports,module){init_browser_globals();var getNative=require_getNative(),root4=require_root2(),Set2=getNative(root4,"Set");module.exports=Set2}});var require_WeakMap=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_WeakMap.js"(exports,module){init_browser_globals();var getNative=require_getNative(),root4=require_root2(),WeakMap2=getNative(root4,"WeakMap");module.exports=WeakMap2}});var require_getTag=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_getTag.js"(exports,module){init_browser_globals();var DataView2=require_DataView(),Map2=require_Map(),Promise2=require_Promise(),Set2=require_Set(),WeakMap2=require_WeakMap(),baseGetTag=require_baseGetTag(),toSource=require_toSource(),mapTag="[object Map]",objectTag="[object Object]",promiseTag="[object Promise]",setTag="[object Set]",weakMapTag="[object WeakMap]",dataViewTag="[object DataView]",dataViewCtorString=toSource(DataView2),mapCtorString=toSource(Map2),promiseCtorString=toSource(Promise2),setCtorString=toSource(Set2),weakMapCtorString=toSource(WeakMap2),getTag=baseGetTag;(DataView2&&getTag(new DataView2(new ArrayBuffer(1)))!=dataViewTag||Map2&&getTag(new Map2)!=mapTag||Promise2&&getTag(Promise2.resolve())!=promiseTag||Set2&&getTag(new Set2)!=setTag||WeakMap2&&getTag(new WeakMap2)!=weakMapTag)&&(getTag=function(value2){var result=baseGetTag(value2),Ctor=result==objectTag?value2.constructor:void 0,ctorString=Ctor?toSource(Ctor):"";if(ctorString)switch(ctorString){case dataViewCtorString:return dataViewTag;case mapCtorString:return mapTag;case promiseCtorString:return promiseTag;case setCtorString:return setTag;case weakMapCtorString:return weakMapTag}return result});module.exports=getTag}});var require_initCloneArray=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_initCloneArray.js"(exports,module){init_browser_globals();var objectProto=Object.prototype,hasOwnProperty2=objectProto.hasOwnProperty;function initCloneArray(array){var length=array.length,result=new array.constructor(length);return length&&typeof array[0]=="string"&&hasOwnProperty2.call(array,"index")&&(result.index=array.index,result.input=array.input),result}module.exports=initCloneArray}});var require_Uint8Array=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_Uint8Array.js"(exports,module){init_browser_globals();var root4=require_root2(),Uint8Array2=root4.Uint8Array;module.exports=Uint8Array2}});var require_cloneArrayBuffer=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_cloneArrayBuffer.js"(exports,module){init_browser_globals();var Uint8Array2=require_Uint8Array();function cloneArrayBuffer(arrayBuffer){var result=new arrayBuffer.constructor(arrayBuffer.byteLength);return new Uint8Array2(result).set(new Uint8Array2(arrayBuffer)),result}module.exports=cloneArrayBuffer}});var require_cloneDataView=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_cloneDataView.js"(exports,module){init_browser_globals();var cloneArrayBuffer=require_cloneArrayBuffer();function cloneDataView(dataView,isDeep){var buffer=isDeep?cloneArrayBuffer(dataView.buffer):dataView.buffer;return new dataView.constructor(buffer,dataView.byteOffset,dataView.byteLength)}module.exports=cloneDataView}});var require_cloneRegExp=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_cloneRegExp.js"(exports,module){init_browser_globals();var reFlags=/\w*$/;function cloneRegExp(regexp){var result=new regexp.constructor(regexp.source,reFlags.exec(regexp));return result.lastIndex=regexp.lastIndex,result}module.exports=cloneRegExp}});var require_cloneSymbol=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_cloneSymbol.js"(exports,module){init_browser_globals();var Symbol2=require_Symbol(),symbolProto=Symbol2?Symbol2.prototype:void 0,symbolValueOf=symbolProto?symbolProto.valueOf:void 0;function cloneSymbol(symbol){return symbolValueOf?Object(symbolValueOf.call(symbol)):{}}module.exports=cloneSymbol}});var require_cloneTypedArray=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_cloneTypedArray.js"(exports,module){init_browser_globals();var cloneArrayBuffer=require_cloneArrayBuffer();function cloneTypedArray(typedArray,isDeep){var buffer=isDeep?cloneArrayBuffer(typedArray.buffer):typedArray.buffer;return new typedArray.constructor(buffer,typedArray.byteOffset,typedArray.length)}module.exports=cloneTypedArray}});var require_initCloneByTag=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_initCloneByTag.js"(exports,module){init_browser_globals();var cloneArrayBuffer=require_cloneArrayBuffer(),cloneDataView=require_cloneDataView(),cloneRegExp=require_cloneRegExp(),cloneSymbol=require_cloneSymbol(),cloneTypedArray=require_cloneTypedArray(),boolTag2="[object Boolean]",dateTag="[object Date]",mapTag="[object Map]",numberTag="[object Number]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",symbolTag="[object Symbol]",arrayBufferTag="[object ArrayBuffer]",dataViewTag="[object DataView]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]";function initCloneByTag(object,tag2,isDeep){var Ctor=object.constructor;switch(tag2){case arrayBufferTag:return cloneArrayBuffer(object);case boolTag2:case dateTag:return new Ctor(+object);case dataViewTag:return cloneDataView(object,isDeep);case float32Tag:case float64Tag:case int8Tag:case int16Tag:case int32Tag:case uint8Tag:case uint8ClampedTag:case uint16Tag:case uint32Tag:return cloneTypedArray(object,isDeep);case mapTag:return new Ctor;case numberTag:case stringTag:return new Ctor(object);case regexpTag:return cloneRegExp(object);case setTag:return new Ctor;case symbolTag:return cloneSymbol(object)}}module.exports=initCloneByTag}});var require_baseCreate=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseCreate.js"(exports,module){init_browser_globals();var isObject3=require_isObject(),objectCreate=Object.create,baseCreate=(function(){function object(){}return function(proto){if(!isObject3(proto))return{};if(objectCreate)return objectCreate(proto);object.prototype=proto;var result=new object;return object.prototype=void 0,result}})();module.exports=baseCreate}});var require_initCloneObject=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_initCloneObject.js"(exports,module){init_browser_globals();var baseCreate=require_baseCreate(),getPrototype=require_getPrototype(),isPrototype=require_isPrototype();function initCloneObject(object){return typeof object.constructor=="function"&&!isPrototype(object)?baseCreate(getPrototype(object)):{}}module.exports=initCloneObject}});var require_baseIsMap=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseIsMap.js"(exports,module){init_browser_globals();var getTag=require_getTag(),isObjectLike=require_isObjectLike(),mapTag="[object Map]";function baseIsMap(value2){return isObjectLike(value2)&&getTag(value2)==mapTag}module.exports=baseIsMap}});var require_isMap=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isMap.js"(exports,module){init_browser_globals();var baseIsMap=require_baseIsMap(),baseUnary=require_baseUnary(),nodeUtil=require_nodeUtil(),nodeIsMap=nodeUtil&&nodeUtil.isMap,isMap2=nodeIsMap?baseUnary(nodeIsMap):baseIsMap;module.exports=isMap2}});var require_baseIsSet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseIsSet.js"(exports,module){init_browser_globals();var getTag=require_getTag(),isObjectLike=require_isObjectLike(),setTag="[object Set]";function baseIsSet(value2){return isObjectLike(value2)&&getTag(value2)==setTag}module.exports=baseIsSet}});var require_isSet=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/isSet.js"(exports,module){init_browser_globals();var baseIsSet=require_baseIsSet(),baseUnary=require_baseUnary(),nodeUtil=require_nodeUtil(),nodeIsSet=nodeUtil&&nodeUtil.isSet,isSet=nodeIsSet?baseUnary(nodeIsSet):baseIsSet;module.exports=isSet}});var require_baseClone=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/_baseClone.js"(exports,module){init_browser_globals();var Stack=require_Stack(),arrayEach=require_arrayEach(),assignValue=require_assignValue(),baseAssign=require_baseAssign(),baseAssignIn=require_baseAssignIn(),cloneBuffer=require_cloneBuffer(),copyArray=require_copyArray(),copySymbols=require_copySymbols(),copySymbolsIn=require_copySymbolsIn(),getAllKeys=require_getAllKeys(),getAllKeysIn=require_getAllKeysIn(),getTag=require_getTag(),initCloneArray=require_initCloneArray(),initCloneByTag=require_initCloneByTag(),initCloneObject=require_initCloneObject(),isArray=require_isArray(),isBuffer=require_isBuffer(),isMap2=require_isMap(),isObject3=require_isObject(),isSet=require_isSet(),keys=require_keys(),keysIn=require_keysIn(),CLONE_DEEP_FLAG=1,CLONE_FLAT_FLAG=2,CLONE_SYMBOLS_FLAG=4,argsTag="[object Arguments]",arrayTag="[object Array]",boolTag2="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",funcTag="[object Function]",genTag="[object GeneratorFunction]",mapTag="[object Map]",numberTag="[object Number]",objectTag="[object Object]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",symbolTag="[object Symbol]",weakMapTag="[object WeakMap]",arrayBufferTag="[object ArrayBuffer]",dataViewTag="[object DataView]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]",cloneableTags={};cloneableTags[argsTag]=cloneableTags[arrayTag]=cloneableTags[arrayBufferTag]=cloneableTags[dataViewTag]=cloneableTags[boolTag2]=cloneableTags[dateTag]=cloneableTags[float32Tag]=cloneableTags[float64Tag]=cloneableTags[int8Tag]=cloneableTags[int16Tag]=cloneableTags[int32Tag]=cloneableTags[mapTag]=cloneableTags[numberTag]=cloneableTags[objectTag]=cloneableTags[regexpTag]=cloneableTags[setTag]=cloneableTags[stringTag]=cloneableTags[symbolTag]=cloneableTags[uint8Tag]=cloneableTags[uint8ClampedTag]=cloneableTags[uint16Tag]=cloneableTags[uint32Tag]=!0;cloneableTags[errorTag]=cloneableTags[funcTag]=cloneableTags[weakMapTag]=!1;function baseClone(value2,bitmask,customizer,key,object,stack){var result,isDeep=bitmask&CLONE_DEEP_FLAG,isFlat=bitmask&CLONE_FLAT_FLAG,isFull=bitmask&CLONE_SYMBOLS_FLAG;if(customizer&&(result=object?customizer(value2,key,object,stack):customizer(value2)),result!==void 0)return result;if(!isObject3(value2))return value2;var isArr=isArray(value2);if(isArr){if(result=initCloneArray(value2),!isDeep)return copyArray(value2,result)}else{var tag2=getTag(value2),isFunc=tag2==funcTag||tag2==genTag;if(isBuffer(value2))return cloneBuffer(value2,isDeep);if(tag2==objectTag||tag2==argsTag||isFunc&&!object){if(result=isFlat||isFunc?{}:initCloneObject(value2),!isDeep)return isFlat?copySymbolsIn(value2,baseAssignIn(result,value2)):copySymbols(value2,baseAssign(result,value2))}else{if(!cloneableTags[tag2])return object?value2:{};result=initCloneByTag(value2,tag2,isDeep)}}stack||(stack=new Stack);var stacked=stack.get(value2);if(stacked)return stacked;stack.set(value2,result),isSet(value2)?value2.forEach(function(subValue){result.add(baseClone(subValue,bitmask,customizer,subValue,value2,stack))}):isMap2(value2)&&value2.forEach(function(subValue,key2){result.set(key2,baseClone(subValue,bitmask,customizer,key2,value2,stack))});var keysFunc=isFull?isFlat?getAllKeysIn:getAllKeys:isFlat?keysIn:keys,props=isArr?void 0:keysFunc(value2);return arrayEach(props||value2,function(subValue,key2){props&&(key2=subValue,subValue=value2[key2]),assignValue(result,key2,baseClone(subValue,bitmask,customizer,key2,value2,stack))}),result}module.exports=baseClone}});var require_cloneDeep=__commonJS({"node_modules/.pnpm/lodash@4.18.1/node_modules/lodash/cloneDeep.js"(exports,module){init_browser_globals();var baseClone=require_baseClone(),CLONE_DEEP_FLAG=1,CLONE_SYMBOLS_FLAG=4;function cloneDeep(value2){return baseClone(value2,CLONE_DEEP_FLAG|CLONE_SYMBOLS_FLAG)}module.exports=cloneDeep}});var require_denormalise=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/denormalise.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _cloneDeep=_interopRequireDefault(require_cloneDeep()),_logger=_interopRequireDefault(require_logger());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var _default=exports.default=function(parseResult){var blocksByName=parseResult.blocks.reduce(function(acc,b2){return acc[b2.name]=b2,acc},{}),_gatherEntities=function(entities,transforms){var current=[];return entities.forEach(function(e2){if(e2.type==="INSERT"){var _insert$rowCount,_insert$columnCount,_insert$rowSpacing,_insert$columnSpacing,_insert$rotation,insert=e2,block=blocksByName[insert.block];if(!block){_logger.default.error("no block found for insert. block:",insert.block);return}var rowCount=(_insert$rowCount=insert.rowCount)!==null&&_insert$rowCount!==void 0?_insert$rowCount:1,columnCount=(_insert$columnCount=insert.columnCount)!==null&&_insert$columnCount!==void 0?_insert$columnCount:1,rowSpacing=(_insert$rowSpacing=insert.rowSpacing)!==null&&_insert$rowSpacing!==void 0?_insert$rowSpacing:0,columnSpacing=(_insert$columnSpacing=insert.columnSpacing)!==null&&_insert$columnSpacing!==void 0?_insert$columnSpacing:0,rotation=(_insert$rotation=insert.rotation)!==null&&_insert$rotation!==void 0?_insert$rotation:0,rowVec,colVec;if(rowCount>1||columnCount>1){var cos=Math.cos(rotation*Math.PI/180),sin=Math.sin(rotation*Math.PI/180);rowVec={x:-sin*rowSpacing,y:cos*rowSpacing},colVec={x:cos*columnSpacing,y:sin*columnSpacing}}else rowVec={x:0,y:0},colVec={x:0,y:0};for(var r2=0;r2<rowCount;r2++)for(var c2=0;c2<columnCount;c2++){var t3={x:insert.x+rowVec.x*r2+colVec.x*c2,y:insert.y+rowVec.y*r2+colVec.y*c2,scaleX:insert.scaleX,scaleY:insert.scaleY,scaleZ:insert.scaleZ,extrusionX:insert.extrusionX,extrusionY:insert.extrusionY,extrusionZ:insert.extrusionZ,rotation:insert.rotation},transforms2=transforms.slice(0);transforms2.push(t3);var blockEntities=block.entities.map(function(be2){var be22=(0,_cloneDeep.default)(be2);switch(be22.layer=insert.layer,be22.type){case"LINE":{be22.start.x-=block.x,be22.start.y-=block.y,be22.end.x-=block.x,be22.end.y-=block.y;break}case"LWPOLYLINE":case"POLYLINE":{be22.vertices.forEach(function(v2){v2.x-=block.x,v2.y-=block.y});break}case"CIRCLE":case"ELLIPSE":case"ARC":{be22.x-=block.x,be22.y-=block.y;break}case"SPLINE":{be22.controlPoints.forEach(function(cp){cp.x-=block.x,cp.y-=block.y});break}}return be22});current=current.concat(_gatherEntities(blockEntities,transforms2))}}else{var e22=(0,_cloneDeep.default)(e2);e22.transforms=transforms.slice().reverse(),current.push(e22)}}),current};return _gatherEntities(parseResult.entities,[])}}});var require_groupEntitiesByLayer=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/groupEntitiesByLayer.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _default=exports.default=function(entities){return entities.reduce(function(acc,entity){var layer=entity.layer;return acc[layer]||(acc[layer]=[]),acc[layer].push(entity),acc},{})}}});var require_V2=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/V2.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;function _typeof(obj){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_typeof=function(obj2){return typeof obj2}:_typeof=function(obj2){return obj2&&typeof Symbol=="function"&&obj2.constructor===Symbol&&obj2!==Symbol.prototype?"symbol":typeof obj2},_typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props){for(var i2=0;i2<props.length;i2++){var descriptor=props[i2];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Constructor}var V2=(function(){function V22(x2,y2){_classCallCheck(this,V22),_typeof(x2)==="object"?(this.x=x2.x,this.y=x2.y):(this.x=x2,this.y=y2)}return _createClass(V22,[{key:"equals",value:function(other){return this.x===other.x&&this.y===other.y}},{key:"length",value:function(){return Math.sqrt(this.dot(this))}},{key:"neg",value:function(){return new V22(-this.x,-this.y)}},{key:"add",value:function(b2){return new V22(this.x+b2.x,this.y+b2.y)}},{key:"sub",value:function(b2){return new V22(this.x-b2.x,this.y-b2.y)}},{key:"multiply",value:function(w2){return new V22(this.x*w2,this.y*w2)}},{key:"norm",value:function(){return this.multiply(1/this.length())}},{key:"dot",value:function(b2){return this.x*b2.x+this.y*b2.y}}]),V22})(),_default=V2;exports.default=_default}});var require_V3=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/V3.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;function _typeof(obj){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_typeof=function(obj2){return typeof obj2}:_typeof=function(obj2){return obj2&&typeof Symbol=="function"&&obj2.constructor===Symbol&&obj2!==Symbol.prototype?"symbol":typeof obj2},_typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props){for(var i2=0;i2<props.length;i2++){var descriptor=props[i2];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Constructor}var V3=(function(){function V32(x2,y2,z2){_classCallCheck(this,V32),_typeof(x2)==="object"?(this.x=x2.x,this.y=x2.y,this.z=x2.z):x2===void 0?(this.x=0,this.y=0,this.z=0):(this.x=x2,this.y=y2,this.z=z2)}return _createClass(V32,[{key:"equals",value:function(other,eps){return eps===void 0&&(eps=0),Math.abs(this.x-other.x)<=eps&&Math.abs(this.y-other.y)<=eps&&Math.abs(this.z-other.z)<=eps}},{key:"length",value:function(){return Math.sqrt(this.dot(this))}},{key:"neg",value:function(){return new V32(-this.x,-this.y,-this.z)}},{key:"add",value:function(b2){return new V32(this.x+b2.x,this.y+b2.y,this.z+b2.z)}},{key:"sub",value:function(b2){return new V32(this.x-b2.x,this.y-b2.y,this.z-b2.z)}},{key:"multiply",value:function(w2){return new V32(this.x*w2,this.y*w2,this.z*w2)}},{key:"norm",value:function(){return this.multiply(1/this.length())}},{key:"dot",value:function(b2){return this.x*b2.x+this.y*b2.y+this.z*b2.z}},{key:"cross",value:function(b2){return new V32(this.y*b2.z-this.z*b2.y,this.z*b2.x-this.x*b2.z,this.x*b2.y-this.y*b2.x)}}]),V32})(),_default=V3;exports.default=_default}});var require_Box2=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/Box2.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _V=_interopRequireDefault(require_V2());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _typeof(obj){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_typeof=function(obj2){return typeof obj2}:_typeof=function(obj2){return obj2&&typeof Symbol=="function"&&obj2.constructor===Symbol&&obj2!==Symbol.prototype?"symbol":typeof obj2},_typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props){for(var i2=0;i2<props.length;i2++){var descriptor=props[i2];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Constructor}var Box2=(function(){function Box22(min,max){if(_classCallCheck(this,Box22),_typeof(min)==="object"&&_typeof(max)==="object"&&min.x!==void 0&&min.y!==void 0&&max.x!==void 0&&max.y!==void 0)this.min=new _V.default(min),this.max=new _V.default(max),this.valid=!0;else if(min===void 0&&max===void 0)this.min=new _V.default(1/0,1/0),this.max=new _V.default(-1/0,-1/0),this.valid=!1;else throw Error("Illegal construction - must use { x, y } objects")}return _createClass(Box22,[{key:"equals",value:function(other){if(!this.valid)throw Error("Box2 is invalid");return this.min.equals(other.min)&&this.max.equals(other.max)}},{key:"expandByPoint",value:function(p2){return this.min=new _V.default(Math.min(this.min.x,p2.x),Math.min(this.min.y,p2.y)),this.max=new _V.default(Math.max(this.max.x,p2.x),Math.max(this.max.y,p2.y)),this.valid=!0,this}},{key:"expandByPoints",value:function(points){var _this=this;return points.forEach(function(point3){_this.expandByPoint(point3)},this),this}},{key:"isPointInside",value:function(p2){return p2.x>=this.min.x&&p2.y>=this.min.y&&p2.x<=this.max.x&&p2.y<=this.max.y}},{key:"width",get:function(){if(!this.valid)throw Error("Box2 is invalid");return this.max.x-this.min.x}},{key:"height",get:function(){if(!this.valid)throw Error("Box2 is invalid");return this.max.y-this.min.y}}]),Box22})();Box2.fromPoints=function(points){return new Box2().expandByPoints(points)};var _default=Box2;exports.default=_default}});var require_Box3=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/Box3.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _V=_interopRequireDefault(require_V3());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _typeof(obj){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_typeof=function(obj2){return typeof obj2}:_typeof=function(obj2){return obj2&&typeof Symbol=="function"&&obj2.constructor===Symbol&&obj2!==Symbol.prototype?"symbol":typeof obj2},_typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props){for(var i2=0;i2<props.length;i2++){var descriptor=props[i2];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Constructor}var Box3=(function(){function Box32(min,max){if(_classCallCheck(this,Box32),_typeof(min)==="object"&&_typeof(max)==="object"&&min.x!==void 0&&min.y!==void 0&&min.z!==void 0&&max.x!==void 0&&max.y!==void 0&&max.z!==void 0)this.min=new _V.default(min),this.max=new _V.default(max),this.valid=!0;else if(min===void 0&&max===void 0)this.min=new _V.default(1/0,1/0,1/0),this.max=new _V.default(-1/0,-1/0,-1/0),this.valid=!1;else throw Error("Illegal construction - must use { x, y, z } objects")}return _createClass(Box32,[{key:"equals",value:function(other){if(!this.valid)throw Error("Box3 is invalid");return this.min.equals(other.min)&&this.max.equals(other.max)}},{key:"expandByPoint",value:function(p2){return this.min=new _V.default(Math.min(this.min.x,p2.x),Math.min(this.min.y,p2.y),Math.min(this.min.z,p2.z)),this.max=new _V.default(Math.max(this.max.x,p2.x),Math.max(this.max.y,p2.y),Math.max(this.max.z,p2.z)),this.valid=!0,this}},{key:"expandByPoints",value:function(points){var _this=this;return points.forEach(function(point3){_this.expandByPoint(point3)},this),this}},{key:"isPointInside",value:function(p2){return p2.x>=this.min.x&&p2.y>=this.min.y&&p2.z>=this.min.z&&p2.x<=this.max.x&&p2.y<=this.max.y&&p2.z<=this.max.z}},{key:"width",get:function(){if(!this.valid)throw Error("Box3 is invalid");return this.max.x-this.min.x}},{key:"depth",get:function(){if(!this.valid)throw Error("Box3 is invalid");return this.max.y-this.min.y}},{key:"height",get:function(){if(!this.valid)throw Error("Box3 is invalid");return this.max.z-this.min.z}}]),Box32})();Box3.fromPoints=function(points){return new Box3().expandByPoints(points)};var _default=Box3;exports.default=_default}});var require_Plane3=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/Plane3.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props){for(var i2=0;i2<props.length;i2++){var descriptor=props[i2];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Constructor}var Plane3=(function(){function Plane32(a2,b2,c2,d2){_classCallCheck(this,Plane32),this.a=a2,this.b=b2,this.c=c2,this.d=d2}return _createClass(Plane32,[{key:"distanceToPoint",value:function(p0){var dd=(this.a*p0.x+this.b*p0.y+this.c*p0.z+this.d)/Math.sqrt(this.a*this.a+this.b*this.b+this.c*this.c);return dd}},{key:"equals",value:function(other){return this.a===other.a&&this.b===other.b&&this.c===other.c&&this.d===other.d}},{key:"coPlanar",value:function(other){var coPlanarAndSameNormal=this.a===other.a&&this.b===other.b&&this.c===other.c&&this.d===other.d,coPlanarAndReversedNormal=this.a===-other.a&&this.b===-other.b&&this.c===-other.c&&this.d===-other.d;return coPlanarAndSameNormal||coPlanarAndReversedNormal}}]),Plane32})();Plane3.fromPointAndNormal=function(p2,n2){var a2=n2.x,b2=n2.y,c2=n2.z,d2=-(p2.x*a2+p2.y*b2+p2.z*c2);return new Plane3(n2.x,n2.y,n2.z,d2)};Plane3.fromPoints=function(points){for(var firstCross,i2=0,il=points.length;i2<il;++i2){var ab=points[(i2+1)%il].sub(points[i2]),bc=points[(i2+2)%il].sub(points[(i2+1)%il]),cross=ab.cross(bc);if(!(isNaN(cross.length())||cross.length()===0))if(!firstCross)firstCross=cross.norm();else{var same2=cross.norm().equals(firstCross,1e-6),opposite=cross.neg().norm().equals(firstCross,1e-6);if(!(same2||opposite))throw Error("points not on a plane")}}if(!firstCross)throw Error("points not on a plane");return Plane3.fromPointAndNormal(points[0],firstCross.norm())};var _default=Plane3;exports.default=_default}});var require_Quaternion=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/Quaternion.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _V=_interopRequireDefault(require_V3());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props){for(var i2=0;i2<props.length;i2++){var descriptor=props[i2];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Constructor}var Quaternion=(function(){function Quaternion2(x2,y2,z2,w2){_classCallCheck(this,Quaternion2),this.x=x2,this.y=y2,this.z=z2,this.w=w2}return _createClass(Quaternion2,[{key:"applyToVec3",value:function(v3){var x2=v3.x,y2=v3.y,z2=v3.z,qx=this.x,qy=this.y,qz=this.z,qw=this.w,ix=qw*x2+qy*z2-qz*y2,iy=qw*y2+qz*x2-qx*z2,iz=qw*z2+qx*y2-qy*x2,iw=-qx*x2-qy*y2-qz*z2;return new _V.default(ix*qw+iw*-qx+iy*-qz-iz*-qy,iy*qw+iw*-qy+iz*-qx-ix*-qz,iz*qw+iw*-qz+ix*-qy-iy*-qx)}}]),Quaternion2})();Quaternion.fromAxisAngle=function(axis,angle){var axisNorm=axis.norm(),halfAngle=angle/2,s2=Math.sin(halfAngle);return new Quaternion(axisNorm.x*s2,axisNorm.y*s2,axisNorm.z*s2,Math.cos(halfAngle))};var _default=Quaternion;exports.default=_default}});var require_Line2=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/Line2.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _V=_interopRequireDefault(require_V2());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _typeof(obj){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_typeof=function(obj2){return typeof obj2}:_typeof=function(obj2){return obj2&&typeof Symbol=="function"&&obj2.constructor===Symbol&&obj2!==Symbol.prototype?"symbol":typeof obj2},_typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props){for(var i2=0;i2<props.length;i2++){var descriptor=props[i2];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Constructor}var turn=function(p1,p2,p3){var a2=p1.x,b2=p1.y,c2=p2.x,d2=p2.y,e2=p3.x,f2=p3.y,m2=(f2-b2)*(c2-a2),n2=(d2-b2)*(e2-a2);return m2>n2+Number.EPSILON?1:m2+Number.EPSILON<n2?-1:0},isIntersect=function(e1,e2){var p1=e1.a,p2=e1.b,p3=e2.a,p4=e2.b;return turn(p1,p3,p4)!==turn(p2,p3,p4)&&turn(p1,p2,p3)!==turn(p1,p2,p4)},_getIntersection=function(m2,n2){var x1=m2.a.x,x2=m2.b.x,y1=m2.a.y,y2=m2.b.y,x3=n2.a.x,x4=n2.b.x,y3=n2.a.y,y4=n2.b.y,x12=x1-x2,x34=x3-x4,y12=y1-y2,y34=y3-y4,c2=x12*y34-y12*x34,px=((x1*y2-y1*x2)*x34-x12*(x3*y4-y3*x4))/c2,py=((x1*y2-y1*x2)*y34-y12*(x3*y4-y3*x4))/c2;return isNaN(px)||isNaN(py)?null:new _V.default(px,py)},dist=function(a2,b2){return Math.sqrt(Math.pow(a2.x-b2.x,2)+Math.pow(a2.y-b2.y,2))},Line2=(function(){function Line22(a2,b2){if(_classCallCheck(this,Line22),_typeof(a2)!=="object"||a2.x===void 0||a2.y===void 0)throw Error("expected first argument to have x and y properties");if(_typeof(b2)!=="object"||b2.x===void 0||b2.y===void 0)throw Error("expected second argument to have x and y properties");this.a=new _V.default(a2),this.b=new _V.default(b2)}return _createClass(Line22,[{key:"length",value:function(){return this.a.sub(this.b).length()}},{key:"intersects",value:function(other){if(!(other instanceof Line22))throw new Error("expected argument to be an instance of vecks.Line2");return isIntersect(this,other)}},{key:"getIntersection",value:function(other){return this.intersects(other)?_getIntersection(this,other):null}},{key:"containsPoint",value:function(point3){var eps=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e-12;return Math.abs(dist(this.a,this.b)-dist(point3,this.a)-dist(point3,this.b))<eps}}]),Line22})(),_default=Line2;exports.default=_default}});var require_Line3=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/Line3.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _V=_interopRequireDefault(require_V3());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _typeof(obj){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_typeof=function(obj2){return typeof obj2}:_typeof=function(obj2){return obj2&&typeof Symbol=="function"&&obj2.constructor===Symbol&&obj2!==Symbol.prototype?"symbol":typeof obj2},_typeof(obj)}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor))throw new TypeError("Cannot call a class as a function")}function _defineProperties(target,props){for(var i2=0;i2<props.length;i2++){var descriptor=props[i2];descriptor.enumerable=descriptor.enumerable||!1,descriptor.configurable=!0,"value"in descriptor&&(descriptor.writable=!0),Object.defineProperty(target,descriptor.key,descriptor)}}function _createClass(Constructor,protoProps,staticProps){return protoProps&&_defineProperties(Constructor.prototype,protoProps),staticProps&&_defineProperties(Constructor,staticProps),Constructor}var dist=function(a2,b2){return Math.sqrt(Math.pow(a2.x-b2.x,2)+Math.pow(a2.y-b2.y,2)+Math.pow(a2.z-b2.z,2))},Line3=(function(){function Line32(a2,b2){if(_classCallCheck(this,Line32),_typeof(a2)!=="object"||a2.x===void 0||a2.y===void 0||a2.z===void 0)throw Error("expected first argument to have x, y and z properties");if(_typeof(b2)!=="object"||b2.x===void 0||b2.y===void 0||b2.y===void 0)throw Error("expected second argument to have x, y and z properties");this.a=new _V.default(a2),this.b=new _V.default(b2)}return _createClass(Line32,[{key:"length",value:function(){return this.a.sub(this.b).length()}},{key:"containsPoint",value:function(point3){var eps=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e-12;return Math.abs(dist(this.a,this.b)-dist(point3,this.a)-dist(point3,this.b))<eps}}]),Line32})(),_default=Line3;exports.default=_default}});var require_lib12=__commonJS({"node_modules/.pnpm/vecks@3.9.2/node_modules/vecks/lib/index.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});Object.defineProperty(exports,"V2",{enumerable:!0,get:function(){return _V.default}});Object.defineProperty(exports,"V3",{enumerable:!0,get:function(){return _V2.default}});Object.defineProperty(exports,"Box2",{enumerable:!0,get:function(){return _Box.default}});Object.defineProperty(exports,"Box3",{enumerable:!0,get:function(){return _Box2.default}});Object.defineProperty(exports,"Plane3",{enumerable:!0,get:function(){return _Plane.default}});Object.defineProperty(exports,"Quaternion",{enumerable:!0,get:function(){return _Quaternion.default}});Object.defineProperty(exports,"Line2",{enumerable:!0,get:function(){return _Line.default}});Object.defineProperty(exports,"Line3",{enumerable:!0,get:function(){return _Line2.default}});var _V=_interopRequireDefault(require_V2()),_V2=_interopRequireDefault(require_V3()),_Box=_interopRequireDefault(require_Box2()),_Box2=_interopRequireDefault(require_Box3()),_Plane=_interopRequireDefault(require_Plane3()),_Quaternion=_interopRequireDefault(require_Quaternion()),_Line=_interopRequireDefault(require_Line2()),_Line2=_interopRequireDefault(require_Line3());function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}}});var require_colors=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/util/colors.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _default=exports.default=[[0,0,0],[255,0,0],[255,255,0],[0,255,0],[0,255,255],[0,0,255],[255,0,255],[255,255,255],[65,65,65],[128,128,128],[255,0,0],[255,170,170],[189,0,0],[189,126,126],[129,0,0],[129,86,86],[104,0,0],[104,69,69],[79,0,0],[79,53,53],[255,63,0],[255,191,170],[189,46,0],[189,141,126],[129,31,0],[129,96,86],[104,25,0],[104,78,69],[79,19,0],[79,59,53],[255,127,0],[255,212,170],[189,94,0],[189,157,126],[129,64,0],[129,107,86],[104,52,0],[104,86,69],[79,39,0],[79,66,53],[255,191,0],[255,234,170],[189,141,0],[189,173,126],[129,96,0],[129,118,86],[104,78,0],[104,95,69],[79,59,0],[79,73,53],[255,255,0],[255,255,170],[189,189,0],[189,189,126],[129,129,0],[129,129,86],[104,104,0],[104,104,69],[79,79,0],[79,79,53],[191,255,0],[234,255,170],[141,189,0],[173,189,126],[96,129,0],[118,129,86],[78,104,0],[95,104,69],[59,79,0],[73,79,53],[127,255,0],[212,255,170],[94,189,0],[157,189,126],[64,129,0],[107,129,86],[52,104,0],[86,104,69],[39,79,0],[66,79,53],[63,255,0],[191,255,170],[46,189,0],[141,189,126],[31,129,0],[96,129,86],[25,104,0],[78,104,69],[19,79,0],[59,79,53],[0,255,0],[170,255,170],[0,189,0],[126,189,126],[0,129,0],[86,129,86],[0,104,0],[69,104,69],[0,79,0],[53,79,53],[0,255,63],[170,255,191],[0,189,46],[126,189,141],[0,129,31],[86,129,96],[0,104,25],[69,104,78],[0,79,19],[53,79,59],[0,255,127],[170,255,212],[0,189,94],[126,189,157],[0,129,64],[86,129,107],[0,104,52],[69,104,86],[0,79,39],[53,79,66],[0,255,191],[170,255,234],[0,189,141],[126,189,173],[0,129,96],[86,129,118],[0,104,78],[69,104,95],[0,79,59],[53,79,73],[0,255,255],[170,255,255],[0,189,189],[126,189,189],[0,129,129],[86,129,129],[0,104,104],[69,104,104],[0,79,79],[53,79,79],[0,191,255],[170,234,255],[0,141,189],[126,173,189],[0,96,129],[86,118,129],[0,78,104],[69,95,104],[0,59,79],[53,73,79],[0,127,255],[170,212,255],[0,94,189],[126,157,189],[0,64,129],[86,107,129],[0,52,104],[69,86,104],[0,39,79],[53,66,79],[0,63,255],[170,191,255],[0,46,189],[126,141,189],[0,31,129],[86,96,129],[0,25,104],[69,78,104],[0,19,79],[53,59,79],[0,0,255],[170,170,255],[0,0,189],[126,126,189],[0,0,129],[86,86,129],[0,0,104],[69,69,104],[0,0,79],[53,53,79],[63,0,255],[191,170,255],[46,0,189],[141,126,189],[31,0,129],[96,86,129],[25,0,104],[78,69,104],[19,0,79],[59,53,79],[127,0,255],[212,170,255],[94,0,189],[157,126,189],[64,0,129],[107,86,129],[52,0,104],[86,69,104],[39,0,79],[66,53,79],[191,0,255],[234,170,255],[141,0,189],[173,126,189],[96,0,129],[118,86,129],[78,0,104],[95,69,104],[59,0,79],[73,53,79],[255,0,255],[255,170,255],[189,0,189],[189,126,189],[129,0,129],[129,86,129],[104,0,104],[104,69,104],[79,0,79],[79,53,79],[255,0,191],[255,170,234],[189,0,141],[189,126,173],[129,0,96],[129,86,118],[104,0,78],[104,69,95],[79,0,59],[79,53,73],[255,0,127],[255,170,212],[189,0,94],[189,126,157],[129,0,64],[129,86,107],[104,0,52],[104,69,86],[79,0,39],[79,53,66],[255,0,63],[255,170,191],[189,0,46],[189,126,141],[129,0,31],[129,86,96],[104,0,25],[104,69,78],[79,0,19],[79,53,59],[51,51,51],[80,80,80],[105,105,105],[130,130,130],[190,190,190],[255,255,255]]}});var require_round10=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/util/round10.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _default=exports.default=function(value2,exp){return typeof exp>"u"||+exp==0?Math.round(value2):(value2=+value2,exp=+exp,isNaN(value2)||!(typeof exp=="number"&&exp%1===0)?NaN:(value2=value2.toString().split("e"),value2=Math.round(+(value2[0]+"e"+(value2[1]?+value2[1]-exp:-exp))),value2=value2.toString().split("e"),+(value2[0]+"e"+(value2[1]?+value2[1]+exp:exp))))}}});var require_bSpline=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/util/bSpline.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _round=_interopRequireDefault(require_round10());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}var _default=exports.default=function(t3,degree,points,knots,weights){var n2=points.length,d2=points[0].length;if(t3<0||t3>1)throw new Error("t out of bounds [0,1]: "+t3);if(degree<1)throw new Error("degree must be at least 1 (linear)");if(degree>n2-1)throw new Error("degree must be less than or equal to point count - 1");if(!weights){weights=[];for(var i2=0;i2<n2;i2++)weights[i2]=1}if(knots){if(knots.length!==n2+degree+1)throw new Error("bad knot vector length")}else{knots=[];for(var _i=0;_i<n2+degree+1;_i++)knots[_i]=_i}var domain2=[degree,knots.length-1-degree],low=knots[domain2[0]],high=knots[domain2[1]];t3=t3*(high-low)+low,t3=Math.max(t3,low),t3=Math.min(t3,high);var s2;for(s2=domain2[0];s2<domain2[1]&&!(t3>=knots[s2]&&t3<=knots[s2+1]);s2++);for(var v2=[],_i2=0;_i2<n2;_i2++){v2[_i2]=[];for(var j=0;j<d2;j++)v2[_i2][j]=points[_i2][j]*weights[_i2];v2[_i2][d2]=weights[_i2]}for(var alpha,l2=1;l2<=degree+1;l2++)for(var _i3=s2;_i3>s2-degree-1+l2;_i3--){alpha=(t3-knots[_i3])/(knots[_i3+degree+1-l2]-knots[_i3]);for(var _j=0;_j<d2+1;_j++)v2[_i3][_j]=(1-alpha)*v2[_i3-1][_j]+alpha*v2[_i3][_j]}for(var result=[],_i4=0;_i4<d2;_i4++)result[_i4]=(0,_round.default)(v2[s2][_i4]/v2[s2][d2],-9);return result}}});var require_createArcForLWPolyline=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/util/createArcForLWPolyline.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.default=void 0;var _vecks=require_lib12(),_default=exports.default=function(from,to,bulge,resolution){resolution||(resolution=5);var theta,a2,b2;bulge<0?(theta=Math.atan(-bulge)*4,a2=new _vecks.V2(from[0],from[1]),b2=new _vecks.V2(to[0],to[1])):(theta=Math.atan(bulge)*4,a2=new _vecks.V2(to[0],to[1]),b2=new _vecks.V2(from[0],from[1]));var ab=b2.sub(a2),lengthAB=ab.length(),c2=a2.add(ab.multiply(.5)),lengthCD=Math.abs(lengthAB/2/Math.tan(theta/2)),normAB=ab.norm(),d2;if(theta<Math.PI){var normDC=new _vecks.V2(normAB.x*Math.cos(Math.PI/2)-normAB.y*Math.sin(Math.PI/2),normAB.y*Math.cos(Math.PI/2)+normAB.x*Math.sin(Math.PI/2));d2=c2.add(normDC.multiply(-lengthCD))}else{var normCD=new _vecks.V2(normAB.x*Math.cos(Math.PI/2)-normAB.y*Math.sin(Math.PI/2),normAB.y*Math.cos(Math.PI/2)+normAB.x*Math.sin(Math.PI/2));d2=c2.add(normCD.multiply(lengthCD))}var startAngle=Math.atan2(b2.y-d2.y,b2.x-d2.x)/Math.PI*180,endAngle=Math.atan2(a2.y-d2.y,a2.x-d2.x)/Math.PI*180;endAngle<startAngle&&(endAngle+=360);for(var r2=b2.sub(d2).length(),startInter=Math.floor(startAngle/resolution)*resolution+resolution,endInter=Math.ceil(endAngle/resolution)*resolution-resolution,points=[],i2=startInter;i2<=endInter;i2+=resolution)points.push(d2.add(new _vecks.V2(Math.cos(i2/180*Math.PI)*r2,Math.sin(i2/180*Math.PI)*r2)));return bulge<0&&points.reverse(),points.map(function(p2){return[p2.x,p2.y]})}}});var require_entityToPolyline=__commonJS({"node_modules/.pnpm/dxf@5.3.1/node_modules/dxf/lib/entityToPolyline.js"(exports){"use strict";init_browser_globals();Object.defineProperty(exports,"__esModule",{value:!0});exports.polyfaceOutline=exports.interpolateBSpline=exports.default=void 0;var _bSpline=_interopRequireDefault(require_bSpline()),_logger=_interopRequireDefault(require_logger()),_createArcForLWPolyline=_interopRequireDefault(require_createArcForLWPolyline());function _interopRequireDefault(e2){return e2&&e2.__esModule?e2:{default:e2}}function _toConsumableArray(r2){return _arrayWithoutHoles(r2)||_iterableToArray(r2)||_unsupportedIterableToArray(r2)||_nonIterableSpread()}function _nonIterableSpread(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
@@ -389,12 +389,12 @@ ${lines.join(`
|
|
|
389
389
|
`||char===void 0)row.push(cell),cell="",closed=!1,char!==separator&&(i2>rowStart&&rows.push(row),row=[],rowStart=i2+1);else{if(closed||char==='"')throw new Error("Unexpected text after a quoted field");cell+=char}}if(!rows.length||rows.some(row2=>row2.length!==rows[0]?.length))throw new Error("Expected equally sized rows");return rows},parseContentSource=(language,source2,id,caption)=>{if(language==="csv"||language==="tsv")try{let[headers,...rows]=delimitedRows(source2,language==="csv"?",":" ");return{blocks:[{type:"table",dataSource:id,headers:headers??[],rows,...caption?{caption}:{}}],errors:[]}}catch(error){return{blocks:[],errors:[{line:0,message:error instanceof Error?error.message:String(error)}]}}if(language==="mermaid")return{blocks:[{type:"code",lang:language,lines:source2.split(`
|
|
390
390
|
`)}],errors:[]};if(language==="callouth"){let root4=parseMdast(source2),errors=[],allowed=new Set(["root","paragraph","text","inlineCode","link","strong","emphasis","list","listItem"]);return root4.children.length||errors.push({line:0,message:"callout is empty"}),visit(root4,(node2,_index,parent)=>{let line2=(node2.position?.start.line??1)-1;if((!allowed.has(node2.type)||parent?.type==="listItem"&&node2.type!=="paragraph"&&node2.type!=="list")&&errors.push({line:line2,message:"use paragraphs and lists with text, code, or links"}),node2.type==="link")try{if(!isReferenceUrl(node2.url))throw new Error("links require a local reference, HTTP(S) URL or email address");if(!node2.url||node2.url.startsWith("doc:"))throw new Error("Use a Markdown file link");parseDocLink(node2.url),parseFigureLink(node2.url),parseTermReference(node2.url)}catch(error){errors.push({line:line2,message:error instanceof Error?error.message:String(error)})}}),{blocks:[{type:"callout",body:root4.children.flatMap(node2=>node2.type==="paragraph"?[{type:"p",text:inlineToText(node2.children)}]:node2.type==="list"?[{type:"list",items:listItems(node2),...node2.ordered?{ordered:!0}:{}}]:[]),...caption?{title:caption}:{}}],errors}}if(language==="schemath"){let lines=source2.split(`
|
|
391
391
|
`),indent3=Math.min(...lines.filter(line2=>line2.trim()).map(line2=>/^\s*/.exec(line2)?.[0].length??0)),parsed2=parseSchemaSource(lines.map(line2=>line2.slice(indent3)).join(`
|
|
392
|
-
`));return source2.trim()||parsed2.errors.push({line:0,message:"schema is empty"}),{blocks:[{type:"schemaGraph",source:source2,graph:parsed2.model,...caption?{caption}:{}}],errors:parsed2.errors}}if(language==="graphth"){let parsed2=parseGraphSource(source2);return source2.trim()||parsed2.errors.push({line:0,message:"graph is empty"}),{blocks:[{type:"graph",source:source2,graph:parsed2.model,...caption?{caption}:{}}],errors:parsed2.errors}}if(language==="termth"){let parsed2=parseTermSource(id,source2);return{blocks:parsed2.entries.map(entry=>({type:"term",entry})),errors:parsed2.errors}}},parseContentCode=(node2,raw,file="inline")=>{if(!node2.lang||!Object.hasOwn(CODE_TEMPLATES,node2.lang))return;let errors=[],slice=raw.slice(node2.position?.start.offset,node2.position?.end.offset),opening=/^(`{3,}|~{3,})/.exec(slice)?.[1],closing=/\n {0,3}(`{3,}|~{3,})[ \t]*$/.exec(slice)?.[1];(!opening||!closing||closing[0]!==opening[0]||closing.length<opening.length)&&errors.push({line:-1,message:"close the code fence"}),node2.lang==="termth"&&node2.meta&&errors.push({line:-1,message:"termth takes no ID; write name and definition as YAML"});let parsed2=parseContentSource(node2.lang,node2.value,`${file}#L${node2.position?.start.line??1}`,node2.meta?.trim());return{blocks:parsed2?.blocks??[],errors:[...errors,...parsed2?.errors??[]]}};var ALLOWED_TYPES=new Set(["root","yaml","paragraph","heading","list","listItem","code","inlineCode","table","tableRow","tableCell","text","link","image","strong","emphasis","blockquote"]),line=n2=>n2.position?`L${n2.position.start.line}`:"L?",checkListItem=(n2,errors)=>{for(let child of n2.children)child.type!=="paragraph"&&child.type!=="list"&&child.type!=="blockquote"&&errors.push(`${line(child)}: ${child.type} is not allowed directly under listItem (paragraph / list / quote only)`)},checkLink=(n2,errors)=>{isReferenceUrl(n2.url)||errors.push(`${line(n2)}: links require a local reference, HTTP(S) URL or email address`);try{parseDocLink(n2.url),parseFigureLink(n2.url),parseTermReference(n2.url)}catch(error){errors.push(`${line(n2)}: ${error instanceof Error?error.message:error}`)}n2.url.startsWith("doc:")&&errors.push(`${line(n2)}: use a Markdown file link instead of doc:`),n2.url===""&&errors.push(`${line(n2)}: link with an empty URL`)},parseDoc=(input,settings,file)=>{let errors=[],raw=input,root4=parseMdast(raw),embeds=new Set(embeddedImages(root4)),terms=[];root4.children[0]?.type==="yaml"&&errors.push("front-matter (---) is not supported; set the title in dooc.yaml");let body=input;return visit(root4,(node2,_index,parent)=>{if(node2.type==="text"&&/(?:^|\n)[ \t]*:{2,}[a-z]+\b/.test(raw.slice(node2.position?.start.offset,node2.position?.end.offset))&&errors.push(`${line(node2)}: removed directive; use Markdown file links or callouth / schemath / graphth / termth code fences`),!ALLOWED_TYPES.has(node2.type)){let hint=node2.type==="html"?' (put "<" inside backticks or escape it as "\\<")':"";errors.push(`${line(node2)}: ${node2.type} is outside the dialect${hint}`);return}switch(node2.type){case"code":{let parsed2=parseContentCode(node2,raw,file);if(!parsed2)break;if(parent?.type!=="root"){errors.push(`${line(node2)}: ${node2.lang} must be a top-level code block`);break}for(let error of parsed2.errors)errors.push(`L${(node2.position?.start.line??0)+1+error.line}: ${node2.lang} ${error.message}`);for(let block of parsed2.blocks)block.type==="term"&&terms.push(block.entry);break}case"image":{if(!embeds.has(node2)){errors.push(`${line(node2)}: file previews must occupy a standalone paragraph`);break}try{let{range}=parseFileEmbed(node2.url,settings);range!==void 0&&parseTextfileRange(range)}catch(error){errors.push(`${line(node2)}: ${error instanceof Error?error.message:error}`)}break}case"listItem":checkListItem(node2,errors);break;case"link":checkLink(node2,errors);break;default:break}}),{body,source:raw,root:root4,errors,terms}},collectRefs=(root4,settings)=>{let figures=[],terms=[],textfiles=[];for(let image2 of embeddedImages(root4))try{let{file,kind}=parseFileEmbed(image2.url,settings);kind==="textfile"?textfiles.push(file):kind!=="external"&&figures.push(file)}catch{}for(let node2 of contentLinks(root4))try{let file=parseTermReference(node2.url);file&&terms.push(file);let figure=parseFigureLink(node2.url);figure&&figures.push(figure.file)}catch{}return{figures:[...new Set(figures)],terms:[...new Set(terms)],textfiles:[...new Set(textfiles)]}};init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();var UNDEFINED_CODE_POINTS=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),REPLACEMENT_CHARACTER="\uFFFD",CODE_POINTS;(function(CODE_POINTS2){CODE_POINTS2[CODE_POINTS2.EOF=-1]="EOF",CODE_POINTS2[CODE_POINTS2.NULL=0]="NULL",CODE_POINTS2[CODE_POINTS2.TABULATION=9]="TABULATION",CODE_POINTS2[CODE_POINTS2.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",CODE_POINTS2[CODE_POINTS2.LINE_FEED=10]="LINE_FEED",CODE_POINTS2[CODE_POINTS2.FORM_FEED=12]="FORM_FEED",CODE_POINTS2[CODE_POINTS2.SPACE=32]="SPACE",CODE_POINTS2[CODE_POINTS2.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",CODE_POINTS2[CODE_POINTS2.QUOTATION_MARK=34]="QUOTATION_MARK",CODE_POINTS2[CODE_POINTS2.AMPERSAND=38]="AMPERSAND",CODE_POINTS2[CODE_POINTS2.APOSTROPHE=39]="APOSTROPHE",CODE_POINTS2[CODE_POINTS2.HYPHEN_MINUS=45]="HYPHEN_MINUS",CODE_POINTS2[CODE_POINTS2.SOLIDUS=47]="SOLIDUS",CODE_POINTS2[CODE_POINTS2.DIGIT_0=48]="DIGIT_0",CODE_POINTS2[CODE_POINTS2.DIGIT_9=57]="DIGIT_9",CODE_POINTS2[CODE_POINTS2.SEMICOLON=59]="SEMICOLON",CODE_POINTS2[CODE_POINTS2.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",CODE_POINTS2[CODE_POINTS2.EQUALS_SIGN=61]="EQUALS_SIGN",CODE_POINTS2[CODE_POINTS2.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",CODE_POINTS2[CODE_POINTS2.QUESTION_MARK=63]="QUESTION_MARK",CODE_POINTS2[CODE_POINTS2.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",CODE_POINTS2[CODE_POINTS2.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",CODE_POINTS2[CODE_POINTS2.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",CODE_POINTS2[CODE_POINTS2.GRAVE_ACCENT=96]="GRAVE_ACCENT",CODE_POINTS2[CODE_POINTS2.LATIN_SMALL_A=97]="LATIN_SMALL_A",CODE_POINTS2[CODE_POINTS2.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(CODE_POINTS||(CODE_POINTS={}));var SEQUENCES={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function isSurrogate(cp){return cp>=55296&&cp<=57343}function isSurrogatePair(cp){return cp>=56320&&cp<=57343}function getSurrogatePairCodePoint(cp1,cp2){return(cp1-55296)*1024+9216+cp2}function isControlCodePoint(cp){return cp!==32&&cp!==10&&cp!==13&&cp!==9&&cp!==12&&cp>=1&&cp<=31||cp>=127&&cp<=159}function isUndefinedCodePoint(cp){return cp>=64976&&cp<=65007||UNDEFINED_CODE_POINTS.has(cp)}init_browser_globals();var ERR;(function(ERR2){ERR2.controlCharacterInInputStream="control-character-in-input-stream",ERR2.noncharacterInInputStream="noncharacter-in-input-stream",ERR2.surrogateInInputStream="surrogate-in-input-stream",ERR2.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",ERR2.endTagWithAttributes="end-tag-with-attributes",ERR2.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",ERR2.unexpectedSolidusInTag="unexpected-solidus-in-tag",ERR2.unexpectedNullCharacter="unexpected-null-character",ERR2.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",ERR2.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",ERR2.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",ERR2.missingEndTagName="missing-end-tag-name",ERR2.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",ERR2.unknownNamedCharacterReference="unknown-named-character-reference",ERR2.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",ERR2.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",ERR2.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",ERR2.eofBeforeTagName="eof-before-tag-name",ERR2.eofInTag="eof-in-tag",ERR2.missingAttributeValue="missing-attribute-value",ERR2.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",ERR2.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",ERR2.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",ERR2.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",ERR2.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",ERR2.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",ERR2.missingDoctypePublicIdentifier="missing-doctype-public-identifier",ERR2.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",ERR2.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",ERR2.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",ERR2.cdataInHtmlContent="cdata-in-html-content",ERR2.incorrectlyOpenedComment="incorrectly-opened-comment",ERR2.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",ERR2.eofInDoctype="eof-in-doctype",ERR2.nestedComment="nested-comment",ERR2.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",ERR2.eofInComment="eof-in-comment",ERR2.incorrectlyClosedComment="incorrectly-closed-comment",ERR2.eofInCdata="eof-in-cdata",ERR2.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",ERR2.nullCharacterReference="null-character-reference",ERR2.surrogateCharacterReference="surrogate-character-reference",ERR2.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",ERR2.controlCharacterReference="control-character-reference",ERR2.noncharacterCharacterReference="noncharacter-character-reference",ERR2.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",ERR2.missingDoctypeName="missing-doctype-name",ERR2.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",ERR2.duplicateAttribute="duplicate-attribute",ERR2.nonConformingDoctype="non-conforming-doctype",ERR2.missingDoctype="missing-doctype",ERR2.misplacedDoctype="misplaced-doctype",ERR2.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",ERR2.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",ERR2.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",ERR2.openElementsLeftAfterEof="open-elements-left-after-eof",ERR2.abandonedHeadElementChild="abandoned-head-element-child",ERR2.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",ERR2.nestedNoscriptInHead="nested-noscript-in-head",ERR2.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(ERR||(ERR={}));var DEFAULT_BUFFER_WATERLINE=65536,Preprocessor=class{constructor(handler2){this.handler=handler2,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=DEFAULT_BUFFER_WATERLINE,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(code4,cpOffset){let{line:line2,col,offset}=this,startCol=col+cpOffset,startOffset=offset+cpOffset;return{code:code4,startLine:line2,endLine:line2,startCol,endCol:startCol,startOffset,endOffset:startOffset}}_err(code4){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(code4,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(cp){if(this.pos!==this.html.length-1){let nextCp=this.html.charCodeAt(this.pos+1);if(isSurrogatePair(nextCp))return this.pos++,this._addGap(),getSurrogatePairCodePoint(cp,nextCp)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,CODE_POINTS.EOF;return this._err(ERR.surrogateInInputStream),cp}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(chunk,isLastChunk){this.html.length>0?this.html+=chunk:this.html=chunk,this.endOfChunkHit=!1,this.lastChunkWritten=isLastChunk}insertHtmlAtCurrentPos(chunk){this.html=this.html.substring(0,this.pos+1)+chunk+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(pattern,caseSensitive){if(this.pos+pattern.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(caseSensitive)return this.html.startsWith(pattern,this.pos);for(let i2=0;i2<pattern.length;i2++)if((this.html.charCodeAt(this.pos+i2)|32)!==pattern.charCodeAt(i2))return!1;return!0}peek(offset){let pos=this.pos+offset;if(pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,CODE_POINTS.EOF;let code4=this.html.charCodeAt(pos);return code4===CODE_POINTS.CARRIAGE_RETURN?CODE_POINTS.LINE_FEED:code4}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,CODE_POINTS.EOF;let cp=this.html.charCodeAt(this.pos);return cp===CODE_POINTS.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,CODE_POINTS.LINE_FEED):cp===CODE_POINTS.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,isSurrogate(cp)&&(cp=this._processSurrogate(cp)),this.handler.onParseError===null||cp>31&&cp<127||cp===CODE_POINTS.LINE_FEED||cp===CODE_POINTS.CARRIAGE_RETURN||cp>159&&cp<64976||this._checkForProblematicCharacters(cp),cp)}_checkForProblematicCharacters(cp){isControlCodePoint(cp)?this._err(ERR.controlCharacterInInputStream):isUndefinedCodePoint(cp)&&this._err(ERR.noncharacterInInputStream)}retreat(count){for(this.pos-=count;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}};init_browser_globals();var TokenType;(function(TokenType2){TokenType2[TokenType2.CHARACTER=0]="CHARACTER",TokenType2[TokenType2.NULL_CHARACTER=1]="NULL_CHARACTER",TokenType2[TokenType2.WHITESPACE_CHARACTER=2]="WHITESPACE_CHARACTER",TokenType2[TokenType2.START_TAG=3]="START_TAG",TokenType2[TokenType2.END_TAG=4]="END_TAG",TokenType2[TokenType2.COMMENT=5]="COMMENT",TokenType2[TokenType2.DOCTYPE=6]="DOCTYPE",TokenType2[TokenType2.EOF=7]="EOF",TokenType2[TokenType2.HIBERNATION=8]="HIBERNATION"})(TokenType||(TokenType={}));function getTokenAttr(token,attrName){for(let i2=token.attrs.length-1;i2>=0;i2--)if(token.attrs[i2].name===attrName)return token.attrs[i2].value;return null}init_browser_globals();init_browser_globals();var htmlDecodeTree=new Uint16Array('\u1D41<\xD5\u0131\u028A\u049D\u057B\u05D0\u0675\u06DE\u07A2\u07D6\u080F\u0A4A\u0A91\u0DA1\u0E6D\u0F09\u0F26\u10CA\u1228\u12E1\u1415\u149D\u14C3\u14DF\u1525\0\0\0\0\0\0\u156B\u16CD\u198D\u1C12\u1DDD\u1F7E\u2060\u21B0\u228D\u23C0\u23FB\u2442\u2824\u2912\u2D08\u2E48\u2FCE\u3016\u32BA\u3639\u37AC\u38FE\u3A28\u3A71\u3AE0\u3B2E\u0800EMabcfglmnoprstu\\bfms\x7F\x84\x8B\x90\x95\x98\xA6\xB3\xB9\xC8\xCFlig\u803B\xC6\u40C6P\u803B&\u4026cute\u803B\xC1\u40C1reve;\u4102\u0100iyx}rc\u803B\xC2\u40C2;\u4410r;\uC000\u{1D504}rave\u803B\xC0\u40C0pha;\u4391acr;\u4100d;\u6A53\u0100gp\x9D\xA1on;\u4104f;\uC000\u{1D538}plyFunction;\u6061ing\u803B\xC5\u40C5\u0100cs\xBE\xC3r;\uC000\u{1D49C}ign;\u6254ilde\u803B\xC3\u40C3ml\u803B\xC4\u40C4\u0400aceforsu\xE5\xFB\xFE\u0117\u011C\u0122\u0127\u012A\u0100cr\xEA\xF2kslash;\u6216\u0176\xF6\xF8;\u6AE7ed;\u6306y;\u4411\u0180crt\u0105\u010B\u0114ause;\u6235noullis;\u612Ca;\u4392r;\uC000\u{1D505}pf;\uC000\u{1D539}eve;\u42D8c\xF2\u0113mpeq;\u624E\u0700HOacdefhilorsu\u014D\u0151\u0156\u0180\u019E\u01A2\u01B5\u01B7\u01BA\u01DC\u0215\u0273\u0278\u027Ecy;\u4427PY\u803B\xA9\u40A9\u0180cpy\u015D\u0162\u017Aute;\u4106\u0100;i\u0167\u0168\u62D2talDifferentialD;\u6145leys;\u612D\u0200aeio\u0189\u018E\u0194\u0198ron;\u410Cdil\u803B\xC7\u40C7rc;\u4108nint;\u6230ot;\u410A\u0100dn\u01A7\u01ADilla;\u40B8terDot;\u40B7\xF2\u017Fi;\u43A7rcle\u0200DMPT\u01C7\u01CB\u01D1\u01D6ot;\u6299inus;\u6296lus;\u6295imes;\u6297o\u0100cs\u01E2\u01F8kwiseContourIntegral;\u6232eCurly\u0100DQ\u0203\u020FoubleQuote;\u601Duote;\u6019\u0200lnpu\u021E\u0228\u0247\u0255on\u0100;e\u0225\u0226\u6237;\u6A74\u0180git\u022F\u0236\u023Aruent;\u6261nt;\u622FourIntegral;\u622E\u0100fr\u024C\u024E;\u6102oduct;\u6210nterClockwiseContourIntegral;\u6233oss;\u6A2Fcr;\uC000\u{1D49E}p\u0100;C\u0284\u0285\u62D3ap;\u624D\u0580DJSZacefios\u02A0\u02AC\u02B0\u02B4\u02B8\u02CB\u02D7\u02E1\u02E6\u0333\u048D\u0100;o\u0179\u02A5trahd;\u6911cy;\u4402cy;\u4405cy;\u440F\u0180grs\u02BF\u02C4\u02C7ger;\u6021r;\u61A1hv;\u6AE4\u0100ay\u02D0\u02D5ron;\u410E;\u4414l\u0100;t\u02DD\u02DE\u6207a;\u4394r;\uC000\u{1D507}\u0100af\u02EB\u0327\u0100cm\u02F0\u0322ritical\u0200ADGT\u0300\u0306\u0316\u031Ccute;\u40B4o\u0174\u030B\u030D;\u42D9bleAcute;\u42DDrave;\u4060ilde;\u42DCond;\u62C4ferentialD;\u6146\u0470\u033D\0\0\0\u0342\u0354\0\u0405f;\uC000\u{1D53B}\u0180;DE\u0348\u0349\u034D\u40A8ot;\u60DCqual;\u6250ble\u0300CDLRUV\u0363\u0372\u0382\u03CF\u03E2\u03F8ontourIntegra\xEC\u0239o\u0274\u0379\0\0\u037B\xBB\u0349nArrow;\u61D3\u0100eo\u0387\u03A4ft\u0180ART\u0390\u0396\u03A1rrow;\u61D0ightArrow;\u61D4e\xE5\u02CAng\u0100LR\u03AB\u03C4eft\u0100AR\u03B3\u03B9rrow;\u67F8ightArrow;\u67FAightArrow;\u67F9ight\u0100AT\u03D8\u03DErrow;\u61D2ee;\u62A8p\u0241\u03E9\0\0\u03EFrrow;\u61D1ownArrow;\u61D5erticalBar;\u6225n\u0300ABLRTa\u0412\u042A\u0430\u045E\u047F\u037Crrow\u0180;BU\u041D\u041E\u0422\u6193ar;\u6913pArrow;\u61F5reve;\u4311eft\u02D2\u043A\0\u0446\0\u0450ightVector;\u6950eeVector;\u695Eector\u0100;B\u0459\u045A\u61BDar;\u6956ight\u01D4\u0467\0\u0471eeVector;\u695Fector\u0100;B\u047A\u047B\u61C1ar;\u6957ee\u0100;A\u0486\u0487\u62A4rrow;\u61A7\u0100ct\u0492\u0497r;\uC000\u{1D49F}rok;\u4110\u0800NTacdfglmopqstux\u04BD\u04C0\u04C4\u04CB\u04DE\u04E2\u04E7\u04EE\u04F5\u0521\u052F\u0536\u0552\u055D\u0560\u0565G;\u414AH\u803B\xD0\u40D0cute\u803B\xC9\u40C9\u0180aiy\u04D2\u04D7\u04DCron;\u411Arc\u803B\xCA\u40CA;\u442Dot;\u4116r;\uC000\u{1D508}rave\u803B\xC8\u40C8ement;\u6208\u0100ap\u04FA\u04FEcr;\u4112ty\u0253\u0506\0\0\u0512mallSquare;\u65FBerySmallSquare;\u65AB\u0100gp\u0526\u052Aon;\u4118f;\uC000\u{1D53C}silon;\u4395u\u0100ai\u053C\u0549l\u0100;T\u0542\u0543\u6A75ilde;\u6242librium;\u61CC\u0100ci\u0557\u055Ar;\u6130m;\u6A73a;\u4397ml\u803B\xCB\u40CB\u0100ip\u056A\u056Fsts;\u6203onentialE;\u6147\u0280cfios\u0585\u0588\u058D\u05B2\u05CCy;\u4424r;\uC000\u{1D509}lled\u0253\u0597\0\0\u05A3mallSquare;\u65FCerySmallSquare;\u65AA\u0370\u05BA\0\u05BF\0\0\u05C4f;\uC000\u{1D53D}All;\u6200riertrf;\u6131c\xF2\u05CB\u0600JTabcdfgorst\u05E8\u05EC\u05EF\u05FA\u0600\u0612\u0616\u061B\u061D\u0623\u066C\u0672cy;\u4403\u803B>\u403Emma\u0100;d\u05F7\u05F8\u4393;\u43DCreve;\u411E\u0180eiy\u0607\u060C\u0610dil;\u4122rc;\u411C;\u4413ot;\u4120r;\uC000\u{1D50A};\u62D9pf;\uC000\u{1D53E}eater\u0300EFGLST\u0635\u0644\u064E\u0656\u065B\u0666qual\u0100;L\u063E\u063F\u6265ess;\u62DBullEqual;\u6267reater;\u6AA2ess;\u6277lantEqual;\u6A7Eilde;\u6273cr;\uC000\u{1D4A2};\u626B\u0400Aacfiosu\u0685\u068B\u0696\u069B\u069E\u06AA\u06BE\u06CARDcy;\u442A\u0100ct\u0690\u0694ek;\u42C7;\u405Eirc;\u4124r;\u610ClbertSpace;\u610B\u01F0\u06AF\0\u06B2f;\u610DizontalLine;\u6500\u0100ct\u06C3\u06C5\xF2\u06A9rok;\u4126mp\u0144\u06D0\u06D8ownHum\xF0\u012Fqual;\u624F\u0700EJOacdfgmnostu\u06FA\u06FE\u0703\u0707\u070E\u071A\u071E\u0721\u0728\u0744\u0778\u078B\u078F\u0795cy;\u4415lig;\u4132cy;\u4401cute\u803B\xCD\u40CD\u0100iy\u0713\u0718rc\u803B\xCE\u40CE;\u4418ot;\u4130r;\u6111rave\u803B\xCC\u40CC\u0180;ap\u0720\u072F\u073F\u0100cg\u0734\u0737r;\u412AinaryI;\u6148lie\xF3\u03DD\u01F4\u0749\0\u0762\u0100;e\u074D\u074E\u622C\u0100gr\u0753\u0758ral;\u622Bsection;\u62C2isible\u0100CT\u076C\u0772omma;\u6063imes;\u6062\u0180gpt\u077F\u0783\u0788on;\u412Ef;\uC000\u{1D540}a;\u4399cr;\u6110ilde;\u4128\u01EB\u079A\0\u079Ecy;\u4406l\u803B\xCF\u40CF\u0280cfosu\u07AC\u07B7\u07BC\u07C2\u07D0\u0100iy\u07B1\u07B5rc;\u4134;\u4419r;\uC000\u{1D50D}pf;\uC000\u{1D541}\u01E3\u07C7\0\u07CCr;\uC000\u{1D4A5}rcy;\u4408kcy;\u4404\u0380HJacfos\u07E4\u07E8\u07EC\u07F1\u07FD\u0802\u0808cy;\u4425cy;\u440Cppa;\u439A\u0100ey\u07F6\u07FBdil;\u4136;\u441Ar;\uC000\u{1D50E}pf;\uC000\u{1D542}cr;\uC000\u{1D4A6}\u0580JTaceflmost\u0825\u0829\u082C\u0850\u0863\u09B3\u09B8\u09C7\u09CD\u0A37\u0A47cy;\u4409\u803B<\u403C\u0280cmnpr\u0837\u083C\u0841\u0844\u084Dute;\u4139bda;\u439Bg;\u67EAlacetrf;\u6112r;\u619E\u0180aey\u0857\u085C\u0861ron;\u413Ddil;\u413B;\u441B\u0100fs\u0868\u0970t\u0500ACDFRTUVar\u087E\u08A9\u08B1\u08E0\u08E6\u08FC\u092F\u095B\u0390\u096A\u0100nr\u0883\u088FgleBracket;\u67E8row\u0180;BR\u0899\u089A\u089E\u6190ar;\u61E4ightArrow;\u61C6eiling;\u6308o\u01F5\u08B7\0\u08C3bleBracket;\u67E6n\u01D4\u08C8\0\u08D2eeVector;\u6961ector\u0100;B\u08DB\u08DC\u61C3ar;\u6959loor;\u630Aight\u0100AV\u08EF\u08F5rrow;\u6194ector;\u694E\u0100er\u0901\u0917e\u0180;AV\u0909\u090A\u0910\u62A3rrow;\u61A4ector;\u695Aiangle\u0180;BE\u0924\u0925\u0929\u62B2ar;\u69CFqual;\u62B4p\u0180DTV\u0937\u0942\u094CownVector;\u6951eeVector;\u6960ector\u0100;B\u0956\u0957\u61BFar;\u6958ector\u0100;B\u0965\u0966\u61BCar;\u6952ight\xE1\u039Cs\u0300EFGLST\u097E\u098B\u0995\u099D\u09A2\u09ADqualGreater;\u62DAullEqual;\u6266reater;\u6276ess;\u6AA1lantEqual;\u6A7Dilde;\u6272r;\uC000\u{1D50F}\u0100;e\u09BD\u09BE\u62D8ftarrow;\u61DAidot;\u413F\u0180npw\u09D4\u0A16\u0A1Bg\u0200LRlr\u09DE\u09F7\u0A02\u0A10eft\u0100AR\u09E6\u09ECrrow;\u67F5ightArrow;\u67F7ightArrow;\u67F6eft\u0100ar\u03B3\u0A0Aight\xE1\u03BFight\xE1\u03CAf;\uC000\u{1D543}er\u0100LR\u0A22\u0A2CeftArrow;\u6199ightArrow;\u6198\u0180cht\u0A3E\u0A40\u0A42\xF2\u084C;\u61B0rok;\u4141;\u626A\u0400acefiosu\u0A5A\u0A5D\u0A60\u0A77\u0A7C\u0A85\u0A8B\u0A8Ep;\u6905y;\u441C\u0100dl\u0A65\u0A6FiumSpace;\u605Flintrf;\u6133r;\uC000\u{1D510}nusPlus;\u6213pf;\uC000\u{1D544}c\xF2\u0A76;\u439C\u0480Jacefostu\u0AA3\u0AA7\u0AAD\u0AC0\u0B14\u0B19\u0D91\u0D97\u0D9Ecy;\u440Acute;\u4143\u0180aey\u0AB4\u0AB9\u0ABEron;\u4147dil;\u4145;\u441D\u0180gsw\u0AC7\u0AF0\u0B0Eative\u0180MTV\u0AD3\u0ADF\u0AE8ediumSpace;\u600Bhi\u0100cn\u0AE6\u0AD8\xEB\u0AD9eryThi\xEE\u0AD9ted\u0100GL\u0AF8\u0B06reaterGreate\xF2\u0673essLes\xF3\u0A48Line;\u400Ar;\uC000\u{1D511}\u0200Bnpt\u0B22\u0B28\u0B37\u0B3Areak;\u6060BreakingSpace;\u40A0f;\u6115\u0680;CDEGHLNPRSTV\u0B55\u0B56\u0B6A\u0B7C\u0BA1\u0BEB\u0C04\u0C5E\u0C84\u0CA6\u0CD8\u0D61\u0D85\u6AEC\u0100ou\u0B5B\u0B64ngruent;\u6262pCap;\u626DoubleVerticalBar;\u6226\u0180lqx\u0B83\u0B8A\u0B9Bement;\u6209ual\u0100;T\u0B92\u0B93\u6260ilde;\uC000\u2242\u0338ists;\u6204reater\u0380;EFGLST\u0BB6\u0BB7\u0BBD\u0BC9\u0BD3\u0BD8\u0BE5\u626Fqual;\u6271ullEqual;\uC000\u2267\u0338reater;\uC000\u226B\u0338ess;\u6279lantEqual;\uC000\u2A7E\u0338ilde;\u6275ump\u0144\u0BF2\u0BFDownHump;\uC000\u224E\u0338qual;\uC000\u224F\u0338e\u0100fs\u0C0A\u0C27tTriangle\u0180;BE\u0C1A\u0C1B\u0C21\u62EAar;\uC000\u29CF\u0338qual;\u62ECs\u0300;EGLST\u0C35\u0C36\u0C3C\u0C44\u0C4B\u0C58\u626Equal;\u6270reater;\u6278ess;\uC000\u226A\u0338lantEqual;\uC000\u2A7D\u0338ilde;\u6274ested\u0100GL\u0C68\u0C79reaterGreater;\uC000\u2AA2\u0338essLess;\uC000\u2AA1\u0338recedes\u0180;ES\u0C92\u0C93\u0C9B\u6280qual;\uC000\u2AAF\u0338lantEqual;\u62E0\u0100ei\u0CAB\u0CB9verseElement;\u620CghtTriangle\u0180;BE\u0CCB\u0CCC\u0CD2\u62EBar;\uC000\u29D0\u0338qual;\u62ED\u0100qu\u0CDD\u0D0CuareSu\u0100bp\u0CE8\u0CF9set\u0100;E\u0CF0\u0CF3\uC000\u228F\u0338qual;\u62E2erset\u0100;E\u0D03\u0D06\uC000\u2290\u0338qual;\u62E3\u0180bcp\u0D13\u0D24\u0D4Eset\u0100;E\u0D1B\u0D1E\uC000\u2282\u20D2qual;\u6288ceeds\u0200;EST\u0D32\u0D33\u0D3B\u0D46\u6281qual;\uC000\u2AB0\u0338lantEqual;\u62E1ilde;\uC000\u227F\u0338erset\u0100;E\u0D58\u0D5B\uC000\u2283\u20D2qual;\u6289ilde\u0200;EFT\u0D6E\u0D6F\u0D75\u0D7F\u6241qual;\u6244ullEqual;\u6247ilde;\u6249erticalBar;\u6224cr;\uC000\u{1D4A9}ilde\u803B\xD1\u40D1;\u439D\u0700Eacdfgmoprstuv\u0DBD\u0DC2\u0DC9\u0DD5\u0DDB\u0DE0\u0DE7\u0DFC\u0E02\u0E20\u0E22\u0E32\u0E3F\u0E44lig;\u4152cute\u803B\xD3\u40D3\u0100iy\u0DCE\u0DD3rc\u803B\xD4\u40D4;\u441Eblac;\u4150r;\uC000\u{1D512}rave\u803B\xD2\u40D2\u0180aei\u0DEE\u0DF2\u0DF6cr;\u414Cga;\u43A9cron;\u439Fpf;\uC000\u{1D546}enCurly\u0100DQ\u0E0E\u0E1AoubleQuote;\u601Cuote;\u6018;\u6A54\u0100cl\u0E27\u0E2Cr;\uC000\u{1D4AA}ash\u803B\xD8\u40D8i\u016C\u0E37\u0E3Cde\u803B\xD5\u40D5es;\u6A37ml\u803B\xD6\u40D6er\u0100BP\u0E4B\u0E60\u0100ar\u0E50\u0E53r;\u603Eac\u0100ek\u0E5A\u0E5C;\u63DEet;\u63B4arenthesis;\u63DC\u0480acfhilors\u0E7F\u0E87\u0E8A\u0E8F\u0E92\u0E94\u0E9D\u0EB0\u0EFCrtialD;\u6202y;\u441Fr;\uC000\u{1D513}i;\u43A6;\u43A0usMinus;\u40B1\u0100ip\u0EA2\u0EADncareplan\xE5\u069Df;\u6119\u0200;eio\u0EB9\u0EBA\u0EE0\u0EE4\u6ABBcedes\u0200;EST\u0EC8\u0EC9\u0ECF\u0EDA\u627Aqual;\u6AAFlantEqual;\u627Cilde;\u627Eme;\u6033\u0100dp\u0EE9\u0EEEuct;\u620Fortion\u0100;a\u0225\u0EF9l;\u621D\u0100ci\u0F01\u0F06r;\uC000\u{1D4AB};\u43A8\u0200Ufos\u0F11\u0F16\u0F1B\u0F1FOT\u803B"\u4022r;\uC000\u{1D514}pf;\u611Acr;\uC000\u{1D4AC}\u0600BEacefhiorsu\u0F3E\u0F43\u0F47\u0F60\u0F73\u0FA7\u0FAA\u0FAD\u1096\u10A9\u10B4\u10BEarr;\u6910G\u803B\xAE\u40AE\u0180cnr\u0F4E\u0F53\u0F56ute;\u4154g;\u67EBr\u0100;t\u0F5C\u0F5D\u61A0l;\u6916\u0180aey\u0F67\u0F6C\u0F71ron;\u4158dil;\u4156;\u4420\u0100;v\u0F78\u0F79\u611Cerse\u0100EU\u0F82\u0F99\u0100lq\u0F87\u0F8Eement;\u620Builibrium;\u61CBpEquilibrium;\u696Fr\xBB\u0F79o;\u43A1ght\u0400ACDFTUVa\u0FC1\u0FEB\u0FF3\u1022\u1028\u105B\u1087\u03D8\u0100nr\u0FC6\u0FD2gleBracket;\u67E9row\u0180;BL\u0FDC\u0FDD\u0FE1\u6192ar;\u61E5eftArrow;\u61C4eiling;\u6309o\u01F5\u0FF9\0\u1005bleBracket;\u67E7n\u01D4\u100A\0\u1014eeVector;\u695Dector\u0100;B\u101D\u101E\u61C2ar;\u6955loor;\u630B\u0100er\u102D\u1043e\u0180;AV\u1035\u1036\u103C\u62A2rrow;\u61A6ector;\u695Biangle\u0180;BE\u1050\u1051\u1055\u62B3ar;\u69D0qual;\u62B5p\u0180DTV\u1063\u106E\u1078ownVector;\u694FeeVector;\u695Cector\u0100;B\u1082\u1083\u61BEar;\u6954ector\u0100;B\u1091\u1092\u61C0ar;\u6953\u0100pu\u109B\u109Ef;\u611DndImplies;\u6970ightarrow;\u61DB\u0100ch\u10B9\u10BCr;\u611B;\u61B1leDelayed;\u69F4\u0680HOacfhimoqstu\u10E4\u10F1\u10F7\u10FD\u1119\u111E\u1151\u1156\u1161\u1167\u11B5\u11BB\u11BF\u0100Cc\u10E9\u10EEHcy;\u4429y;\u4428FTcy;\u442Ccute;\u415A\u0280;aeiy\u1108\u1109\u110E\u1113\u1117\u6ABCron;\u4160dil;\u415Erc;\u415C;\u4421r;\uC000\u{1D516}ort\u0200DLRU\u112A\u1134\u113E\u1149ownArrow\xBB\u041EeftArrow\xBB\u089AightArrow\xBB\u0FDDpArrow;\u6191gma;\u43A3allCircle;\u6218pf;\uC000\u{1D54A}\u0272\u116D\0\0\u1170t;\u621Aare\u0200;ISU\u117B\u117C\u1189\u11AF\u65A1ntersection;\u6293u\u0100bp\u118F\u119Eset\u0100;E\u1197\u1198\u628Fqual;\u6291erset\u0100;E\u11A8\u11A9\u6290qual;\u6292nion;\u6294cr;\uC000\u{1D4AE}ar;\u62C6\u0200bcmp\u11C8\u11DB\u1209\u120B\u0100;s\u11CD\u11CE\u62D0et\u0100;E\u11CD\u11D5qual;\u6286\u0100ch\u11E0\u1205eeds\u0200;EST\u11ED\u11EE\u11F4\u11FF\u627Bqual;\u6AB0lantEqual;\u627Dilde;\u627FTh\xE1\u0F8C;\u6211\u0180;es\u1212\u1213\u1223\u62D1rset\u0100;E\u121C\u121D\u6283qual;\u6287et\xBB\u1213\u0580HRSacfhiors\u123E\u1244\u1249\u1255\u125E\u1271\u1276\u129F\u12C2\u12C8\u12D1ORN\u803B\xDE\u40DEADE;\u6122\u0100Hc\u124E\u1252cy;\u440By;\u4426\u0100bu\u125A\u125C;\u4009;\u43A4\u0180aey\u1265\u126A\u126Fron;\u4164dil;\u4162;\u4422r;\uC000\u{1D517}\u0100ei\u127B\u1289\u01F2\u1280\0\u1287efore;\u6234a;\u4398\u0100cn\u128E\u1298kSpace;\uC000\u205F\u200ASpace;\u6009lde\u0200;EFT\u12AB\u12AC\u12B2\u12BC\u623Cqual;\u6243ullEqual;\u6245ilde;\u6248pf;\uC000\u{1D54B}ipleDot;\u60DB\u0100ct\u12D6\u12DBr;\uC000\u{1D4AF}rok;\u4166\u0AE1\u12F7\u130E\u131A\u1326\0\u132C\u1331\0\0\0\0\0\u1338\u133D\u1377\u1385\0\u13FF\u1404\u140A\u1410\u0100cr\u12FB\u1301ute\u803B\xDA\u40DAr\u0100;o\u1307\u1308\u619Fcir;\u6949r\u01E3\u1313\0\u1316y;\u440Eve;\u416C\u0100iy\u131E\u1323rc\u803B\xDB\u40DB;\u4423blac;\u4170r;\uC000\u{1D518}rave\u803B\xD9\u40D9acr;\u416A\u0100di\u1341\u1369er\u0100BP\u1348\u135D\u0100ar\u134D\u1350r;\u405Fac\u0100ek\u1357\u1359;\u63DFet;\u63B5arenthesis;\u63DDon\u0100;P\u1370\u1371\u62C3lus;\u628E\u0100gp\u137B\u137Fon;\u4172f;\uC000\u{1D54C}\u0400ADETadps\u1395\u13AE\u13B8\u13C4\u03E8\u13D2\u13D7\u13F3rrow\u0180;BD\u1150\u13A0\u13A4ar;\u6912ownArrow;\u61C5ownArrow;\u6195quilibrium;\u696Eee\u0100;A\u13CB\u13CC\u62A5rrow;\u61A5own\xE1\u03F3er\u0100LR\u13DE\u13E8eftArrow;\u6196ightArrow;\u6197i\u0100;l\u13F9\u13FA\u43D2on;\u43A5ing;\u416Ecr;\uC000\u{1D4B0}ilde;\u4168ml\u803B\xDC\u40DC\u0480Dbcdefosv\u1427\u142C\u1430\u1433\u143E\u1485\u148A\u1490\u1496ash;\u62ABar;\u6AEBy;\u4412ash\u0100;l\u143B\u143C\u62A9;\u6AE6\u0100er\u1443\u1445;\u62C1\u0180bty\u144C\u1450\u147Aar;\u6016\u0100;i\u144F\u1455cal\u0200BLST\u1461\u1465\u146A\u1474ar;\u6223ine;\u407Ceparator;\u6758ilde;\u6240ThinSpace;\u600Ar;\uC000\u{1D519}pf;\uC000\u{1D54D}cr;\uC000\u{1D4B1}dash;\u62AA\u0280cefos\u14A7\u14AC\u14B1\u14B6\u14BCirc;\u4174dge;\u62C0r;\uC000\u{1D51A}pf;\uC000\u{1D54E}cr;\uC000\u{1D4B2}\u0200fios\u14CB\u14D0\u14D2\u14D8r;\uC000\u{1D51B};\u439Epf;\uC000\u{1D54F}cr;\uC000\u{1D4B3}\u0480AIUacfosu\u14F1\u14F5\u14F9\u14FD\u1504\u150F\u1514\u151A\u1520cy;\u442Fcy;\u4407cy;\u442Ecute\u803B\xDD\u40DD\u0100iy\u1509\u150Drc;\u4176;\u442Br;\uC000\u{1D51C}pf;\uC000\u{1D550}cr;\uC000\u{1D4B4}ml;\u4178\u0400Hacdefos\u1535\u1539\u153F\u154B\u154F\u155D\u1560\u1564cy;\u4416cute;\u4179\u0100ay\u1544\u1549ron;\u417D;\u4417ot;\u417B\u01F2\u1554\0\u155BoWidt\xE8\u0AD9a;\u4396r;\u6128pf;\u6124cr;\uC000\u{1D4B5}\u0BE1\u1583\u158A\u1590\0\u15B0\u15B6\u15BF\0\0\0\0\u15C6\u15DB\u15EB\u165F\u166D\0\u1695\u169B\u16B2\u16B9\0\u16BEcute\u803B\xE1\u40E1reve;\u4103\u0300;Ediuy\u159C\u159D\u15A1\u15A3\u15A8\u15AD\u623E;\uC000\u223E\u0333;\u623Frc\u803B\xE2\u40E2te\u80BB\xB4\u0306;\u4430lig\u803B\xE6\u40E6\u0100;r\xB2\u15BA;\uC000\u{1D51E}rave\u803B\xE0\u40E0\u0100ep\u15CA\u15D6\u0100fp\u15CF\u15D4sym;\u6135\xE8\u15D3ha;\u43B1\u0100ap\u15DFc\u0100cl\u15E4\u15E7r;\u4101g;\u6A3F\u0264\u15F0\0\0\u160A\u0280;adsv\u15FA\u15FB\u15FF\u1601\u1607\u6227nd;\u6A55;\u6A5Clope;\u6A58;\u6A5A\u0380;elmrsz\u1618\u1619\u161B\u161E\u163F\u164F\u1659\u6220;\u69A4e\xBB\u1619sd\u0100;a\u1625\u1626\u6221\u0461\u1630\u1632\u1634\u1636\u1638\u163A\u163C\u163E;\u69A8;\u69A9;\u69AA;\u69AB;\u69AC;\u69AD;\u69AE;\u69AFt\u0100;v\u1645\u1646\u621Fb\u0100;d\u164C\u164D\u62BE;\u699D\u0100pt\u1654\u1657h;\u6222\xBB\xB9arr;\u637C\u0100gp\u1663\u1667on;\u4105f;\uC000\u{1D552}\u0380;Eaeiop\u12C1\u167B\u167D\u1682\u1684\u1687\u168A;\u6A70cir;\u6A6F;\u624Ad;\u624Bs;\u4027rox\u0100;e\u12C1\u1692\xF1\u1683ing\u803B\xE5\u40E5\u0180cty\u16A1\u16A6\u16A8r;\uC000\u{1D4B6};\u402Amp\u0100;e\u12C1\u16AF\xF1\u0288ilde\u803B\xE3\u40E3ml\u803B\xE4\u40E4\u0100ci\u16C2\u16C8onin\xF4\u0272nt;\u6A11\u0800Nabcdefiklnoprsu\u16ED\u16F1\u1730\u173C\u1743\u1748\u1778\u177D\u17E0\u17E6\u1839\u1850\u170D\u193D\u1948\u1970ot;\u6AED\u0100cr\u16F6\u171Ek\u0200ceps\u1700\u1705\u170D\u1713ong;\u624Cpsilon;\u43F6rime;\u6035im\u0100;e\u171A\u171B\u623Dq;\u62CD\u0176\u1722\u1726ee;\u62BDed\u0100;g\u172C\u172D\u6305e\xBB\u172Drk\u0100;t\u135C\u1737brk;\u63B6\u0100oy\u1701\u1741;\u4431quo;\u601E\u0280cmprt\u1753\u175B\u1761\u1764\u1768aus\u0100;e\u010A\u0109ptyv;\u69B0s\xE9\u170Cno\xF5\u0113\u0180ahw\u176F\u1771\u1773;\u43B2;\u6136een;\u626Cr;\uC000\u{1D51F}g\u0380costuvw\u178D\u179D\u17B3\u17C1\u17D5\u17DB\u17DE\u0180aiu\u1794\u1796\u179A\xF0\u0760rc;\u65EFp\xBB\u1371\u0180dpt\u17A4\u17A8\u17ADot;\u6A00lus;\u6A01imes;\u6A02\u0271\u17B9\0\0\u17BEcup;\u6A06ar;\u6605riangle\u0100du\u17CD\u17D2own;\u65BDp;\u65B3plus;\u6A04e\xE5\u1444\xE5\u14ADarow;\u690D\u0180ako\u17ED\u1826\u1835\u0100cn\u17F2\u1823k\u0180lst\u17FA\u05AB\u1802ozenge;\u69EBriangle\u0200;dlr\u1812\u1813\u1818\u181D\u65B4own;\u65BEeft;\u65C2ight;\u65B8k;\u6423\u01B1\u182B\0\u1833\u01B2\u182F\0\u1831;\u6592;\u65914;\u6593ck;\u6588\u0100eo\u183E\u184D\u0100;q\u1843\u1846\uC000=\u20E5uiv;\uC000\u2261\u20E5t;\u6310\u0200ptwx\u1859\u185E\u1867\u186Cf;\uC000\u{1D553}\u0100;t\u13CB\u1863om\xBB\u13CCtie;\u62C8\u0600DHUVbdhmptuv\u1885\u1896\u18AA\u18BB\u18D7\u18DB\u18EC\u18FF\u1905\u190A\u1910\u1921\u0200LRlr\u188E\u1890\u1892\u1894;\u6557;\u6554;\u6556;\u6553\u0280;DUdu\u18A1\u18A2\u18A4\u18A6\u18A8\u6550;\u6566;\u6569;\u6564;\u6567\u0200LRlr\u18B3\u18B5\u18B7\u18B9;\u655D;\u655A;\u655C;\u6559\u0380;HLRhlr\u18CA\u18CB\u18CD\u18CF\u18D1\u18D3\u18D5\u6551;\u656C;\u6563;\u6560;\u656B;\u6562;\u655Fox;\u69C9\u0200LRlr\u18E4\u18E6\u18E8\u18EA;\u6555;\u6552;\u6510;\u650C\u0280;DUdu\u06BD\u18F7\u18F9\u18FB\u18FD;\u6565;\u6568;\u652C;\u6534inus;\u629Flus;\u629Eimes;\u62A0\u0200LRlr\u1919\u191B\u191D\u191F;\u655B;\u6558;\u6518;\u6514\u0380;HLRhlr\u1930\u1931\u1933\u1935\u1937\u1939\u193B\u6502;\u656A;\u6561;\u655E;\u653C;\u6524;\u651C\u0100ev\u0123\u1942bar\u803B\xA6\u40A6\u0200ceio\u1951\u1956\u195A\u1960r;\uC000\u{1D4B7}mi;\u604Fm\u0100;e\u171A\u171Cl\u0180;bh\u1968\u1969\u196B\u405C;\u69C5sub;\u67C8\u016C\u1974\u197El\u0100;e\u1979\u197A\u6022t\xBB\u197Ap\u0180;Ee\u012F\u1985\u1987;\u6AAE\u0100;q\u06DC\u06DB\u0CE1\u19A7\0\u19E8\u1A11\u1A15\u1A32\0\u1A37\u1A50\0\0\u1AB4\0\0\u1AC1\0\0\u1B21\u1B2E\u1B4D\u1B52\0\u1BFD\0\u1C0C\u0180cpr\u19AD\u19B2\u19DDute;\u4107\u0300;abcds\u19BF\u19C0\u19C4\u19CA\u19D5\u19D9\u6229nd;\u6A44rcup;\u6A49\u0100au\u19CF\u19D2p;\u6A4Bp;\u6A47ot;\u6A40;\uC000\u2229\uFE00\u0100eo\u19E2\u19E5t;\u6041\xEE\u0693\u0200aeiu\u19F0\u19FB\u1A01\u1A05\u01F0\u19F5\0\u19F8s;\u6A4Don;\u410Ddil\u803B\xE7\u40E7rc;\u4109ps\u0100;s\u1A0C\u1A0D\u6A4Cm;\u6A50ot;\u410B\u0180dmn\u1A1B\u1A20\u1A26il\u80BB\xB8\u01ADptyv;\u69B2t\u8100\xA2;e\u1A2D\u1A2E\u40A2r\xE4\u01B2r;\uC000\u{1D520}\u0180cei\u1A3D\u1A40\u1A4Dy;\u4447ck\u0100;m\u1A47\u1A48\u6713ark\xBB\u1A48;\u43C7r\u0380;Ecefms\u1A5F\u1A60\u1A62\u1A6B\u1AA4\u1AAA\u1AAE\u65CB;\u69C3\u0180;el\u1A69\u1A6A\u1A6D\u42C6q;\u6257e\u0261\u1A74\0\0\u1A88rrow\u0100lr\u1A7C\u1A81eft;\u61BAight;\u61BB\u0280RSacd\u1A92\u1A94\u1A96\u1A9A\u1A9F\xBB\u0F47;\u64C8st;\u629Birc;\u629Aash;\u629Dnint;\u6A10id;\u6AEFcir;\u69C2ubs\u0100;u\u1ABB\u1ABC\u6663it\xBB\u1ABC\u02EC\u1AC7\u1AD4\u1AFA\0\u1B0Aon\u0100;e\u1ACD\u1ACE\u403A\u0100;q\xC7\xC6\u026D\u1AD9\0\0\u1AE2a\u0100;t\u1ADE\u1ADF\u402C;\u4040\u0180;fl\u1AE8\u1AE9\u1AEB\u6201\xEE\u1160e\u0100mx\u1AF1\u1AF6ent\xBB\u1AE9e\xF3\u024D\u01E7\u1AFE\0\u1B07\u0100;d\u12BB\u1B02ot;\u6A6Dn\xF4\u0246\u0180fry\u1B10\u1B14\u1B17;\uC000\u{1D554}o\xE4\u0254\u8100\xA9;s\u0155\u1B1Dr;\u6117\u0100ao\u1B25\u1B29rr;\u61B5ss;\u6717\u0100cu\u1B32\u1B37r;\uC000\u{1D4B8}\u0100bp\u1B3C\u1B44\u0100;e\u1B41\u1B42\u6ACF;\u6AD1\u0100;e\u1B49\u1B4A\u6AD0;\u6AD2dot;\u62EF\u0380delprvw\u1B60\u1B6C\u1B77\u1B82\u1BAC\u1BD4\u1BF9arr\u0100lr\u1B68\u1B6A;\u6938;\u6935\u0270\u1B72\0\0\u1B75r;\u62DEc;\u62DFarr\u0100;p\u1B7F\u1B80\u61B6;\u693D\u0300;bcdos\u1B8F\u1B90\u1B96\u1BA1\u1BA5\u1BA8\u622Arcap;\u6A48\u0100au\u1B9B\u1B9Ep;\u6A46p;\u6A4Aot;\u628Dr;\u6A45;\uC000\u222A\uFE00\u0200alrv\u1BB5\u1BBF\u1BDE\u1BE3rr\u0100;m\u1BBC\u1BBD\u61B7;\u693Cy\u0180evw\u1BC7\u1BD4\u1BD8q\u0270\u1BCE\0\0\u1BD2re\xE3\u1B73u\xE3\u1B75ee;\u62CEedge;\u62CFen\u803B\xA4\u40A4earrow\u0100lr\u1BEE\u1BF3eft\xBB\u1B80ight\xBB\u1BBDe\xE4\u1BDD\u0100ci\u1C01\u1C07onin\xF4\u01F7nt;\u6231lcty;\u632D\u0980AHabcdefhijlorstuwz\u1C38\u1C3B\u1C3F\u1C5D\u1C69\u1C75\u1C8A\u1C9E\u1CAC\u1CB7\u1CFB\u1CFF\u1D0D\u1D7B\u1D91\u1DAB\u1DBB\u1DC6\u1DCDr\xF2\u0381ar;\u6965\u0200glrs\u1C48\u1C4D\u1C52\u1C54ger;\u6020eth;\u6138\xF2\u1133h\u0100;v\u1C5A\u1C5B\u6010\xBB\u090A\u016B\u1C61\u1C67arow;\u690Fa\xE3\u0315\u0100ay\u1C6E\u1C73ron;\u410F;\u4434\u0180;ao\u0332\u1C7C\u1C84\u0100gr\u02BF\u1C81r;\u61CAtseq;\u6A77\u0180glm\u1C91\u1C94\u1C98\u803B\xB0\u40B0ta;\u43B4ptyv;\u69B1\u0100ir\u1CA3\u1CA8sht;\u697F;\uC000\u{1D521}ar\u0100lr\u1CB3\u1CB5\xBB\u08DC\xBB\u101E\u0280aegsv\u1CC2\u0378\u1CD6\u1CDC\u1CE0m\u0180;os\u0326\u1CCA\u1CD4nd\u0100;s\u0326\u1CD1uit;\u6666amma;\u43DDin;\u62F2\u0180;io\u1CE7\u1CE8\u1CF8\u40F7de\u8100\xF7;o\u1CE7\u1CF0ntimes;\u62C7n\xF8\u1CF7cy;\u4452c\u026F\u1D06\0\0\u1D0Arn;\u631Eop;\u630D\u0280lptuw\u1D18\u1D1D\u1D22\u1D49\u1D55lar;\u4024f;\uC000\u{1D555}\u0280;emps\u030B\u1D2D\u1D37\u1D3D\u1D42q\u0100;d\u0352\u1D33ot;\u6251inus;\u6238lus;\u6214quare;\u62A1blebarwedg\xE5\xFAn\u0180adh\u112E\u1D5D\u1D67ownarrow\xF3\u1C83arpoon\u0100lr\u1D72\u1D76ef\xF4\u1CB4igh\xF4\u1CB6\u0162\u1D7F\u1D85karo\xF7\u0F42\u026F\u1D8A\0\0\u1D8Ern;\u631Fop;\u630C\u0180cot\u1D98\u1DA3\u1DA6\u0100ry\u1D9D\u1DA1;\uC000\u{1D4B9};\u4455l;\u69F6rok;\u4111\u0100dr\u1DB0\u1DB4ot;\u62F1i\u0100;f\u1DBA\u1816\u65BF\u0100ah\u1DC0\u1DC3r\xF2\u0429a\xF2\u0FA6angle;\u69A6\u0100ci\u1DD2\u1DD5y;\u445Fgrarr;\u67FF\u0900Dacdefglmnopqrstux\u1E01\u1E09\u1E19\u1E38\u0578\u1E3C\u1E49\u1E61\u1E7E\u1EA5\u1EAF\u1EBD\u1EE1\u1F2A\u1F37\u1F44\u1F4E\u1F5A\u0100Do\u1E06\u1D34o\xF4\u1C89\u0100cs\u1E0E\u1E14ute\u803B\xE9\u40E9ter;\u6A6E\u0200aioy\u1E22\u1E27\u1E31\u1E36ron;\u411Br\u0100;c\u1E2D\u1E2E\u6256\u803B\xEA\u40EAlon;\u6255;\u444Dot;\u4117\u0100Dr\u1E41\u1E45ot;\u6252;\uC000\u{1D522}\u0180;rs\u1E50\u1E51\u1E57\u6A9Aave\u803B\xE8\u40E8\u0100;d\u1E5C\u1E5D\u6A96ot;\u6A98\u0200;ils\u1E6A\u1E6B\u1E72\u1E74\u6A99nters;\u63E7;\u6113\u0100;d\u1E79\u1E7A\u6A95ot;\u6A97\u0180aps\u1E85\u1E89\u1E97cr;\u4113ty\u0180;sv\u1E92\u1E93\u1E95\u6205et\xBB\u1E93p\u01001;\u1E9D\u1EA4\u0133\u1EA1\u1EA3;\u6004;\u6005\u6003\u0100gs\u1EAA\u1EAC;\u414Bp;\u6002\u0100gp\u1EB4\u1EB8on;\u4119f;\uC000\u{1D556}\u0180als\u1EC4\u1ECE\u1ED2r\u0100;s\u1ECA\u1ECB\u62D5l;\u69E3us;\u6A71i\u0180;lv\u1EDA\u1EDB\u1EDF\u43B5on\xBB\u1EDB;\u43F5\u0200csuv\u1EEA\u1EF3\u1F0B\u1F23\u0100io\u1EEF\u1E31rc\xBB\u1E2E\u0269\u1EF9\0\0\u1EFB\xED\u0548ant\u0100gl\u1F02\u1F06tr\xBB\u1E5Dess\xBB\u1E7A\u0180aei\u1F12\u1F16\u1F1Als;\u403Dst;\u625Fv\u0100;D\u0235\u1F20D;\u6A78parsl;\u69E5\u0100Da\u1F2F\u1F33ot;\u6253rr;\u6971\u0180cdi\u1F3E\u1F41\u1EF8r;\u612Fo\xF4\u0352\u0100ah\u1F49\u1F4B;\u43B7\u803B\xF0\u40F0\u0100mr\u1F53\u1F57l\u803B\xEB\u40EBo;\u60AC\u0180cip\u1F61\u1F64\u1F67l;\u4021s\xF4\u056E\u0100eo\u1F6C\u1F74ctatio\xEE\u0559nential\xE5\u0579\u09E1\u1F92\0\u1F9E\0\u1FA1\u1FA7\0\0\u1FC6\u1FCC\0\u1FD3\0\u1FE6\u1FEA\u2000\0\u2008\u205Allingdotse\xF1\u1E44y;\u4444male;\u6640\u0180ilr\u1FAD\u1FB3\u1FC1lig;\u8000\uFB03\u0269\u1FB9\0\0\u1FBDg;\u8000\uFB00ig;\u8000\uFB04;\uC000\u{1D523}lig;\u8000\uFB01lig;\uC000fj\u0180alt\u1FD9\u1FDC\u1FE1t;\u666Dig;\u8000\uFB02ns;\u65B1of;\u4192\u01F0\u1FEE\0\u1FF3f;\uC000\u{1D557}\u0100ak\u05BF\u1FF7\u0100;v\u1FFC\u1FFD\u62D4;\u6AD9artint;\u6A0D\u0100ao\u200C\u2055\u0100cs\u2011\u2052\u03B1\u201A\u2030\u2038\u2045\u2048\0\u2050\u03B2\u2022\u2025\u2027\u202A\u202C\0\u202E\u803B\xBD\u40BD;\u6153\u803B\xBC\u40BC;\u6155;\u6159;\u615B\u01B3\u2034\0\u2036;\u6154;\u6156\u02B4\u203E\u2041\0\0\u2043\u803B\xBE\u40BE;\u6157;\u615C5;\u6158\u01B6\u204C\0\u204E;\u615A;\u615D8;\u615El;\u6044wn;\u6322cr;\uC000\u{1D4BB}\u0880Eabcdefgijlnorstv\u2082\u2089\u209F\u20A5\u20B0\u20B4\u20F0\u20F5\u20FA\u20FF\u2103\u2112\u2138\u0317\u213E\u2152\u219E\u0100;l\u064D\u2087;\u6A8C\u0180cmp\u2090\u2095\u209Dute;\u41F5ma\u0100;d\u209C\u1CDA\u43B3;\u6A86reve;\u411F\u0100iy\u20AA\u20AErc;\u411D;\u4433ot;\u4121\u0200;lqs\u063E\u0642\u20BD\u20C9\u0180;qs\u063E\u064C\u20C4lan\xF4\u0665\u0200;cdl\u0665\u20D2\u20D5\u20E5c;\u6AA9ot\u0100;o\u20DC\u20DD\u6A80\u0100;l\u20E2\u20E3\u6A82;\u6A84\u0100;e\u20EA\u20ED\uC000\u22DB\uFE00s;\u6A94r;\uC000\u{1D524}\u0100;g\u0673\u061Bmel;\u6137cy;\u4453\u0200;Eaj\u065A\u210C\u210E\u2110;\u6A92;\u6AA5;\u6AA4\u0200Eaes\u211B\u211D\u2129\u2134;\u6269p\u0100;p\u2123\u2124\u6A8Arox\xBB\u2124\u0100;q\u212E\u212F\u6A88\u0100;q\u212E\u211Bim;\u62E7pf;\uC000\u{1D558}\u0100ci\u2143\u2146r;\u610Am\u0180;el\u066B\u214E\u2150;\u6A8E;\u6A90\u8300>;cdlqr\u05EE\u2160\u216A\u216E\u2173\u2179\u0100ci\u2165\u2167;\u6AA7r;\u6A7Aot;\u62D7Par;\u6995uest;\u6A7C\u0280adels\u2184\u216A\u2190\u0656\u219B\u01F0\u2189\0\u218Epro\xF8\u209Er;\u6978q\u0100lq\u063F\u2196les\xF3\u2088i\xED\u066B\u0100en\u21A3\u21ADrtneqq;\uC000\u2269\uFE00\xC5\u21AA\u0500Aabcefkosy\u21C4\u21C7\u21F1\u21F5\u21FA\u2218\u221D\u222F\u2268\u227Dr\xF2\u03A0\u0200ilmr\u21D0\u21D4\u21D7\u21DBrs\xF0\u1484f\xBB\u2024il\xF4\u06A9\u0100dr\u21E0\u21E4cy;\u444A\u0180;cw\u08F4\u21EB\u21EFir;\u6948;\u61ADar;\u610Firc;\u4125\u0180alr\u2201\u220E\u2213rts\u0100;u\u2209\u220A\u6665it\xBB\u220Alip;\u6026con;\u62B9r;\uC000\u{1D525}s\u0100ew\u2223\u2229arow;\u6925arow;\u6926\u0280amopr\u223A\u223E\u2243\u225E\u2263rr;\u61FFtht;\u623Bk\u0100lr\u2249\u2253eftarrow;\u61A9ightarrow;\u61AAf;\uC000\u{1D559}bar;\u6015\u0180clt\u226F\u2274\u2278r;\uC000\u{1D4BD}as\xE8\u21F4rok;\u4127\u0100bp\u2282\u2287ull;\u6043hen\xBB\u1C5B\u0AE1\u22A3\0\u22AA\0\u22B8\u22C5\u22CE\0\u22D5\u22F3\0\0\u22F8\u2322\u2367\u2362\u237F\0\u2386\u23AA\u23B4cute\u803B\xED\u40ED\u0180;iy\u0771\u22B0\u22B5rc\u803B\xEE\u40EE;\u4438\u0100cx\u22BC\u22BFy;\u4435cl\u803B\xA1\u40A1\u0100fr\u039F\u22C9;\uC000\u{1D526}rave\u803B\xEC\u40EC\u0200;ino\u073E\u22DD\u22E9\u22EE\u0100in\u22E2\u22E6nt;\u6A0Ct;\u622Dfin;\u69DCta;\u6129lig;\u4133\u0180aop\u22FE\u231A\u231D\u0180cgt\u2305\u2308\u2317r;\u412B\u0180elp\u071F\u230F\u2313in\xE5\u078Ear\xF4\u0720h;\u4131f;\u62B7ed;\u41B5\u0280;cfot\u04F4\u232C\u2331\u233D\u2341are;\u6105in\u0100;t\u2338\u2339\u621Eie;\u69DDdo\xF4\u2319\u0280;celp\u0757\u234C\u2350\u235B\u2361al;\u62BA\u0100gr\u2355\u2359er\xF3\u1563\xE3\u234Darhk;\u6A17rod;\u6A3C\u0200cgpt\u236F\u2372\u2376\u237By;\u4451on;\u412Ff;\uC000\u{1D55A}a;\u43B9uest\u803B\xBF\u40BF\u0100ci\u238A\u238Fr;\uC000\u{1D4BE}n\u0280;Edsv\u04F4\u239B\u239D\u23A1\u04F3;\u62F9ot;\u62F5\u0100;v\u23A6\u23A7\u62F4;\u62F3\u0100;i\u0777\u23AElde;\u4129\u01EB\u23B8\0\u23BCcy;\u4456l\u803B\xEF\u40EF\u0300cfmosu\u23CC\u23D7\u23DC\u23E1\u23E7\u23F5\u0100iy\u23D1\u23D5rc;\u4135;\u4439r;\uC000\u{1D527}ath;\u4237pf;\uC000\u{1D55B}\u01E3\u23EC\0\u23F1r;\uC000\u{1D4BF}rcy;\u4458kcy;\u4454\u0400acfghjos\u240B\u2416\u2422\u2427\u242D\u2431\u2435\u243Bppa\u0100;v\u2413\u2414\u43BA;\u43F0\u0100ey\u241B\u2420dil;\u4137;\u443Ar;\uC000\u{1D528}reen;\u4138cy;\u4445cy;\u445Cpf;\uC000\u{1D55C}cr;\uC000\u{1D4C0}\u0B80ABEHabcdefghjlmnoprstuv\u2470\u2481\u2486\u248D\u2491\u250E\u253D\u255A\u2580\u264E\u265E\u2665\u2679\u267D\u269A\u26B2\u26D8\u275D\u2768\u278B\u27C0\u2801\u2812\u0180art\u2477\u247A\u247Cr\xF2\u09C6\xF2\u0395ail;\u691Barr;\u690E\u0100;g\u0994\u248B;\u6A8Bar;\u6962\u0963\u24A5\0\u24AA\0\u24B1\0\0\0\0\0\u24B5\u24BA\0\u24C6\u24C8\u24CD\0\u24F9ute;\u413Amptyv;\u69B4ra\xEE\u084Cbda;\u43BBg\u0180;dl\u088E\u24C1\u24C3;\u6991\xE5\u088E;\u6A85uo\u803B\xAB\u40ABr\u0400;bfhlpst\u0899\u24DE\u24E6\u24E9\u24EB\u24EE\u24F1\u24F5\u0100;f\u089D\u24E3s;\u691Fs;\u691D\xEB\u2252p;\u61ABl;\u6939im;\u6973l;\u61A2\u0180;ae\u24FF\u2500\u2504\u6AABil;\u6919\u0100;s\u2509\u250A\u6AAD;\uC000\u2AAD\uFE00\u0180abr\u2515\u2519\u251Drr;\u690Crk;\u6772\u0100ak\u2522\u252Cc\u0100ek\u2528\u252A;\u407B;\u405B\u0100es\u2531\u2533;\u698Bl\u0100du\u2539\u253B;\u698F;\u698D\u0200aeuy\u2546\u254B\u2556\u2558ron;\u413E\u0100di\u2550\u2554il;\u413C\xEC\u08B0\xE2\u2529;\u443B\u0200cqrs\u2563\u2566\u256D\u257Da;\u6936uo\u0100;r\u0E19\u1746\u0100du\u2572\u2577har;\u6967shar;\u694Bh;\u61B2\u0280;fgqs\u258B\u258C\u0989\u25F3\u25FF\u6264t\u0280ahlrt\u2598\u25A4\u25B7\u25C2\u25E8rrow\u0100;t\u0899\u25A1a\xE9\u24F6arpoon\u0100du\u25AF\u25B4own\xBB\u045Ap\xBB\u0966eftarrows;\u61C7ight\u0180ahs\u25CD\u25D6\u25DErrow\u0100;s\u08F4\u08A7arpoon\xF3\u0F98quigarro\xF7\u21F0hreetimes;\u62CB\u0180;qs\u258B\u0993\u25FAlan\xF4\u09AC\u0280;cdgs\u09AC\u260A\u260D\u261D\u2628c;\u6AA8ot\u0100;o\u2614\u2615\u6A7F\u0100;r\u261A\u261B\u6A81;\u6A83\u0100;e\u2622\u2625\uC000\u22DA\uFE00s;\u6A93\u0280adegs\u2633\u2639\u263D\u2649\u264Bppro\xF8\u24C6ot;\u62D6q\u0100gq\u2643\u2645\xF4\u0989gt\xF2\u248C\xF4\u099Bi\xED\u09B2\u0180ilr\u2655\u08E1\u265Asht;\u697C;\uC000\u{1D529}\u0100;E\u099C\u2663;\u6A91\u0161\u2669\u2676r\u0100du\u25B2\u266E\u0100;l\u0965\u2673;\u696Alk;\u6584cy;\u4459\u0280;acht\u0A48\u2688\u268B\u2691\u2696r\xF2\u25C1orne\xF2\u1D08ard;\u696Bri;\u65FA\u0100io\u269F\u26A4dot;\u4140ust\u0100;a\u26AC\u26AD\u63B0che\xBB\u26AD\u0200Eaes\u26BB\u26BD\u26C9\u26D4;\u6268p\u0100;p\u26C3\u26C4\u6A89rox\xBB\u26C4\u0100;q\u26CE\u26CF\u6A87\u0100;q\u26CE\u26BBim;\u62E6\u0400abnoptwz\u26E9\u26F4\u26F7\u271A\u272F\u2741\u2747\u2750\u0100nr\u26EE\u26F1g;\u67ECr;\u61FDr\xEB\u08C1g\u0180lmr\u26FF\u270D\u2714eft\u0100ar\u09E6\u2707ight\xE1\u09F2apsto;\u67FCight\xE1\u09FDparrow\u0100lr\u2725\u2729ef\xF4\u24EDight;\u61AC\u0180afl\u2736\u2739\u273Dr;\u6985;\uC000\u{1D55D}us;\u6A2Dimes;\u6A34\u0161\u274B\u274Fst;\u6217\xE1\u134E\u0180;ef\u2757\u2758\u1800\u65CAnge\xBB\u2758ar\u0100;l\u2764\u2765\u4028t;\u6993\u0280achmt\u2773\u2776\u277C\u2785\u2787r\xF2\u08A8orne\xF2\u1D8Car\u0100;d\u0F98\u2783;\u696D;\u600Eri;\u62BF\u0300achiqt\u2798\u279D\u0A40\u27A2\u27AE\u27BBquo;\u6039r;\uC000\u{1D4C1}m\u0180;eg\u09B2\u27AA\u27AC;\u6A8D;\u6A8F\u0100bu\u252A\u27B3o\u0100;r\u0E1F\u27B9;\u601Arok;\u4142\u8400<;cdhilqr\u082B\u27D2\u2639\u27DC\u27E0\u27E5\u27EA\u27F0\u0100ci\u27D7\u27D9;\u6AA6r;\u6A79re\xE5\u25F2mes;\u62C9arr;\u6976uest;\u6A7B\u0100Pi\u27F5\u27F9ar;\u6996\u0180;ef\u2800\u092D\u181B\u65C3r\u0100du\u2807\u280Dshar;\u694Ahar;\u6966\u0100en\u2817\u2821rtneqq;\uC000\u2268\uFE00\xC5\u281E\u0700Dacdefhilnopsu\u2840\u2845\u2882\u288E\u2893\u28A0\u28A5\u28A8\u28DA\u28E2\u28E4\u0A83\u28F3\u2902Dot;\u623A\u0200clpr\u284E\u2852\u2863\u287Dr\u803B\xAF\u40AF\u0100et\u2857\u2859;\u6642\u0100;e\u285E\u285F\u6720se\xBB\u285F\u0100;s\u103B\u2868to\u0200;dlu\u103B\u2873\u2877\u287Bow\xEE\u048Cef\xF4\u090F\xF0\u13D1ker;\u65AE\u0100oy\u2887\u288Cmma;\u6A29;\u443Cash;\u6014asuredangle\xBB\u1626r;\uC000\u{1D52A}o;\u6127\u0180cdn\u28AF\u28B4\u28C9ro\u803B\xB5\u40B5\u0200;acd\u1464\u28BD\u28C0\u28C4s\xF4\u16A7ir;\u6AF0ot\u80BB\xB7\u01B5us\u0180;bd\u28D2\u1903\u28D3\u6212\u0100;u\u1D3C\u28D8;\u6A2A\u0163\u28DE\u28E1p;\u6ADB\xF2\u2212\xF0\u0A81\u0100dp\u28E9\u28EEels;\u62A7f;\uC000\u{1D55E}\u0100ct\u28F8\u28FDr;\uC000\u{1D4C2}pos\xBB\u159D\u0180;lm\u2909\u290A\u290D\u43BCtimap;\u62B8\u0C00GLRVabcdefghijlmoprstuvw\u2942\u2953\u297E\u2989\u2998\u29DA\u29E9\u2A15\u2A1A\u2A58\u2A5D\u2A83\u2A95\u2AA4\u2AA8\u2B04\u2B07\u2B44\u2B7F\u2BAE\u2C34\u2C67\u2C7C\u2CE9\u0100gt\u2947\u294B;\uC000\u22D9\u0338\u0100;v\u2950\u0BCF\uC000\u226B\u20D2\u0180elt\u295A\u2972\u2976ft\u0100ar\u2961\u2967rrow;\u61CDightarrow;\u61CE;\uC000\u22D8\u0338\u0100;v\u297B\u0C47\uC000\u226A\u20D2ightarrow;\u61CF\u0100Dd\u298E\u2993ash;\u62AFash;\u62AE\u0280bcnpt\u29A3\u29A7\u29AC\u29B1\u29CCla\xBB\u02DEute;\u4144g;\uC000\u2220\u20D2\u0280;Eiop\u0D84\u29BC\u29C0\u29C5\u29C8;\uC000\u2A70\u0338d;\uC000\u224B\u0338s;\u4149ro\xF8\u0D84ur\u0100;a\u29D3\u29D4\u666El\u0100;s\u29D3\u0B38\u01F3\u29DF\0\u29E3p\u80BB\xA0\u0B37mp\u0100;e\u0BF9\u0C00\u0280aeouy\u29F4\u29FE\u2A03\u2A10\u2A13\u01F0\u29F9\0\u29FB;\u6A43on;\u4148dil;\u4146ng\u0100;d\u0D7E\u2A0Aot;\uC000\u2A6D\u0338p;\u6A42;\u443Dash;\u6013\u0380;Aadqsx\u0B92\u2A29\u2A2D\u2A3B\u2A41\u2A45\u2A50rr;\u61D7r\u0100hr\u2A33\u2A36k;\u6924\u0100;o\u13F2\u13F0ot;\uC000\u2250\u0338ui\xF6\u0B63\u0100ei\u2A4A\u2A4Ear;\u6928\xED\u0B98ist\u0100;s\u0BA0\u0B9Fr;\uC000\u{1D52B}\u0200Eest\u0BC5\u2A66\u2A79\u2A7C\u0180;qs\u0BBC\u2A6D\u0BE1\u0180;qs\u0BBC\u0BC5\u2A74lan\xF4\u0BE2i\xED\u0BEA\u0100;r\u0BB6\u2A81\xBB\u0BB7\u0180Aap\u2A8A\u2A8D\u2A91r\xF2\u2971rr;\u61AEar;\u6AF2\u0180;sv\u0F8D\u2A9C\u0F8C\u0100;d\u2AA1\u2AA2\u62FC;\u62FAcy;\u445A\u0380AEadest\u2AB7\u2ABA\u2ABE\u2AC2\u2AC5\u2AF6\u2AF9r\xF2\u2966;\uC000\u2266\u0338rr;\u619Ar;\u6025\u0200;fqs\u0C3B\u2ACE\u2AE3\u2AEFt\u0100ar\u2AD4\u2AD9rro\xF7\u2AC1ightarro\xF7\u2A90\u0180;qs\u0C3B\u2ABA\u2AEAlan\xF4\u0C55\u0100;s\u0C55\u2AF4\xBB\u0C36i\xED\u0C5D\u0100;r\u0C35\u2AFEi\u0100;e\u0C1A\u0C25i\xE4\u0D90\u0100pt\u2B0C\u2B11f;\uC000\u{1D55F}\u8180\xAC;in\u2B19\u2B1A\u2B36\u40ACn\u0200;Edv\u0B89\u2B24\u2B28\u2B2E;\uC000\u22F9\u0338ot;\uC000\u22F5\u0338\u01E1\u0B89\u2B33\u2B35;\u62F7;\u62F6i\u0100;v\u0CB8\u2B3C\u01E1\u0CB8\u2B41\u2B43;\u62FE;\u62FD\u0180aor\u2B4B\u2B63\u2B69r\u0200;ast\u0B7B\u2B55\u2B5A\u2B5Flle\xEC\u0B7Bl;\uC000\u2AFD\u20E5;\uC000\u2202\u0338lint;\u6A14\u0180;ce\u0C92\u2B70\u2B73u\xE5\u0CA5\u0100;c\u0C98\u2B78\u0100;e\u0C92\u2B7D\xF1\u0C98\u0200Aait\u2B88\u2B8B\u2B9D\u2BA7r\xF2\u2988rr\u0180;cw\u2B94\u2B95\u2B99\u619B;\uC000\u2933\u0338;\uC000\u219D\u0338ghtarrow\xBB\u2B95ri\u0100;e\u0CCB\u0CD6\u0380chimpqu\u2BBD\u2BCD\u2BD9\u2B04\u0B78\u2BE4\u2BEF\u0200;cer\u0D32\u2BC6\u0D37\u2BC9u\xE5\u0D45;\uC000\u{1D4C3}ort\u026D\u2B05\0\0\u2BD6ar\xE1\u2B56m\u0100;e\u0D6E\u2BDF\u0100;q\u0D74\u0D73su\u0100bp\u2BEB\u2BED\xE5\u0CF8\xE5\u0D0B\u0180bcp\u2BF6\u2C11\u2C19\u0200;Ees\u2BFF\u2C00\u0D22\u2C04\u6284;\uC000\u2AC5\u0338et\u0100;e\u0D1B\u2C0Bq\u0100;q\u0D23\u2C00c\u0100;e\u0D32\u2C17\xF1\u0D38\u0200;Ees\u2C22\u2C23\u0D5F\u2C27\u6285;\uC000\u2AC6\u0338et\u0100;e\u0D58\u2C2Eq\u0100;q\u0D60\u2C23\u0200gilr\u2C3D\u2C3F\u2C45\u2C47\xEC\u0BD7lde\u803B\xF1\u40F1\xE7\u0C43iangle\u0100lr\u2C52\u2C5Ceft\u0100;e\u0C1A\u2C5A\xF1\u0C26ight\u0100;e\u0CCB\u2C65\xF1\u0CD7\u0100;m\u2C6C\u2C6D\u43BD\u0180;es\u2C74\u2C75\u2C79\u4023ro;\u6116p;\u6007\u0480DHadgilrs\u2C8F\u2C94\u2C99\u2C9E\u2CA3\u2CB0\u2CB6\u2CD3\u2CE3ash;\u62ADarr;\u6904p;\uC000\u224D\u20D2ash;\u62AC\u0100et\u2CA8\u2CAC;\uC000\u2265\u20D2;\uC000>\u20D2nfin;\u69DE\u0180Aet\u2CBD\u2CC1\u2CC5rr;\u6902;\uC000\u2264\u20D2\u0100;r\u2CCA\u2CCD\uC000<\u20D2ie;\uC000\u22B4\u20D2\u0100At\u2CD8\u2CDCrr;\u6903rie;\uC000\u22B5\u20D2im;\uC000\u223C\u20D2\u0180Aan\u2CF0\u2CF4\u2D02rr;\u61D6r\u0100hr\u2CFA\u2CFDk;\u6923\u0100;o\u13E7\u13E5ear;\u6927\u1253\u1A95\0\0\0\0\0\0\0\0\0\0\0\0\0\u2D2D\0\u2D38\u2D48\u2D60\u2D65\u2D72\u2D84\u1B07\0\0\u2D8D\u2DAB\0\u2DC8\u2DCE\0\u2DDC\u2E19\u2E2B\u2E3E\u2E43\u0100cs\u2D31\u1A97ute\u803B\xF3\u40F3\u0100iy\u2D3C\u2D45r\u0100;c\u1A9E\u2D42\u803B\xF4\u40F4;\u443E\u0280abios\u1AA0\u2D52\u2D57\u01C8\u2D5Alac;\u4151v;\u6A38old;\u69BClig;\u4153\u0100cr\u2D69\u2D6Dir;\u69BF;\uC000\u{1D52C}\u036F\u2D79\0\0\u2D7C\0\u2D82n;\u42DBave\u803B\xF2\u40F2;\u69C1\u0100bm\u2D88\u0DF4ar;\u69B5\u0200acit\u2D95\u2D98\u2DA5\u2DA8r\xF2\u1A80\u0100ir\u2D9D\u2DA0r;\u69BEoss;\u69BBn\xE5\u0E52;\u69C0\u0180aei\u2DB1\u2DB5\u2DB9cr;\u414Dga;\u43C9\u0180cdn\u2DC0\u2DC5\u01CDron;\u43BF;\u69B6pf;\uC000\u{1D560}\u0180ael\u2DD4\u2DD7\u01D2r;\u69B7rp;\u69B9\u0380;adiosv\u2DEA\u2DEB\u2DEE\u2E08\u2E0D\u2E10\u2E16\u6228r\xF2\u1A86\u0200;efm\u2DF7\u2DF8\u2E02\u2E05\u6A5Dr\u0100;o\u2DFE\u2DFF\u6134f\xBB\u2DFF\u803B\xAA\u40AA\u803B\xBA\u40BAgof;\u62B6r;\u6A56lope;\u6A57;\u6A5B\u0180clo\u2E1F\u2E21\u2E27\xF2\u2E01ash\u803B\xF8\u40F8l;\u6298i\u016C\u2E2F\u2E34de\u803B\xF5\u40F5es\u0100;a\u01DB\u2E3As;\u6A36ml\u803B\xF6\u40F6bar;\u633D\u0AE1\u2E5E\0\u2E7D\0\u2E80\u2E9D\0\u2EA2\u2EB9\0\0\u2ECB\u0E9C\0\u2F13\0\0\u2F2B\u2FBC\0\u2FC8r\u0200;ast\u0403\u2E67\u2E72\u0E85\u8100\xB6;l\u2E6D\u2E6E\u40B6le\xEC\u0403\u0269\u2E78\0\0\u2E7Bm;\u6AF3;\u6AFDy;\u443Fr\u0280cimpt\u2E8B\u2E8F\u2E93\u1865\u2E97nt;\u4025od;\u402Eil;\u6030enk;\u6031r;\uC000\u{1D52D}\u0180imo\u2EA8\u2EB0\u2EB4\u0100;v\u2EAD\u2EAE\u43C6;\u43D5ma\xF4\u0A76ne;\u660E\u0180;tv\u2EBF\u2EC0\u2EC8\u43C0chfork\xBB\u1FFD;\u43D6\u0100au\u2ECF\u2EDFn\u0100ck\u2ED5\u2EDDk\u0100;h\u21F4\u2EDB;\u610E\xF6\u21F4s\u0480;abcdemst\u2EF3\u2EF4\u1908\u2EF9\u2EFD\u2F04\u2F06\u2F0A\u2F0E\u402Bcir;\u6A23ir;\u6A22\u0100ou\u1D40\u2F02;\u6A25;\u6A72n\u80BB\xB1\u0E9Dim;\u6A26wo;\u6A27\u0180ipu\u2F19\u2F20\u2F25ntint;\u6A15f;\uC000\u{1D561}nd\u803B\xA3\u40A3\u0500;Eaceinosu\u0EC8\u2F3F\u2F41\u2F44\u2F47\u2F81\u2F89\u2F92\u2F7E\u2FB6;\u6AB3p;\u6AB7u\xE5\u0ED9\u0100;c\u0ECE\u2F4C\u0300;acens\u0EC8\u2F59\u2F5F\u2F66\u2F68\u2F7Eppro\xF8\u2F43urlye\xF1\u0ED9\xF1\u0ECE\u0180aes\u2F6F\u2F76\u2F7Approx;\u6AB9qq;\u6AB5im;\u62E8i\xED\u0EDFme\u0100;s\u2F88\u0EAE\u6032\u0180Eas\u2F78\u2F90\u2F7A\xF0\u2F75\u0180dfp\u0EEC\u2F99\u2FAF\u0180als\u2FA0\u2FA5\u2FAAlar;\u632Eine;\u6312urf;\u6313\u0100;t\u0EFB\u2FB4\xEF\u0EFBrel;\u62B0\u0100ci\u2FC0\u2FC5r;\uC000\u{1D4C5};\u43C8ncsp;\u6008\u0300fiopsu\u2FDA\u22E2\u2FDF\u2FE5\u2FEB\u2FF1r;\uC000\u{1D52E}pf;\uC000\u{1D562}rime;\u6057cr;\uC000\u{1D4C6}\u0180aeo\u2FF8\u3009\u3013t\u0100ei\u2FFE\u3005rnion\xF3\u06B0nt;\u6A16st\u0100;e\u3010\u3011\u403F\xF1\u1F19\xF4\u0F14\u0A80ABHabcdefhilmnoprstux\u3040\u3051\u3055\u3059\u30E0\u310E\u312B\u3147\u3162\u3172\u318E\u3206\u3215\u3224\u3229\u3258\u326E\u3272\u3290\u32B0\u32B7\u0180art\u3047\u304A\u304Cr\xF2\u10B3\xF2\u03DDail;\u691Car\xF2\u1C65ar;\u6964\u0380cdenqrt\u3068\u3075\u3078\u307F\u308F\u3094\u30CC\u0100eu\u306D\u3071;\uC000\u223D\u0331te;\u4155i\xE3\u116Emptyv;\u69B3g\u0200;del\u0FD1\u3089\u308B\u308D;\u6992;\u69A5\xE5\u0FD1uo\u803B\xBB\u40BBr\u0580;abcfhlpstw\u0FDC\u30AC\u30AF\u30B7\u30B9\u30BC\u30BE\u30C0\u30C3\u30C7\u30CAp;\u6975\u0100;f\u0FE0\u30B4s;\u6920;\u6933s;\u691E\xEB\u225D\xF0\u272El;\u6945im;\u6974l;\u61A3;\u619D\u0100ai\u30D1\u30D5il;\u691Ao\u0100;n\u30DB\u30DC\u6236al\xF3\u0F1E\u0180abr\u30E7\u30EA\u30EEr\xF2\u17E5rk;\u6773\u0100ak\u30F3\u30FDc\u0100ek\u30F9\u30FB;\u407D;\u405D\u0100es\u3102\u3104;\u698Cl\u0100du\u310A\u310C;\u698E;\u6990\u0200aeuy\u3117\u311C\u3127\u3129ron;\u4159\u0100di\u3121\u3125il;\u4157\xEC\u0FF2\xE2\u30FA;\u4440\u0200clqs\u3134\u3137\u313D\u3144a;\u6937dhar;\u6969uo\u0100;r\u020E\u020Dh;\u61B3\u0180acg\u314E\u315F\u0F44l\u0200;ips\u0F78\u3158\u315B\u109Cn\xE5\u10BBar\xF4\u0FA9t;\u65AD\u0180ilr\u3169\u1023\u316Esht;\u697D;\uC000\u{1D52F}\u0100ao\u3177\u3186r\u0100du\u317D\u317F\xBB\u047B\u0100;l\u1091\u3184;\u696C\u0100;v\u318B\u318C\u43C1;\u43F1\u0180gns\u3195\u31F9\u31FCht\u0300ahlrst\u31A4\u31B0\u31C2\u31D8\u31E4\u31EErrow\u0100;t\u0FDC\u31ADa\xE9\u30C8arpoon\u0100du\u31BB\u31BFow\xEE\u317Ep\xBB\u1092eft\u0100ah\u31CA\u31D0rrow\xF3\u0FEAarpoon\xF3\u0551ightarrows;\u61C9quigarro\xF7\u30CBhreetimes;\u62CCg;\u42DAingdotse\xF1\u1F32\u0180ahm\u320D\u3210\u3213r\xF2\u0FEAa\xF2\u0551;\u600Foust\u0100;a\u321E\u321F\u63B1che\xBB\u321Fmid;\u6AEE\u0200abpt\u3232\u323D\u3240\u3252\u0100nr\u3237\u323Ag;\u67EDr;\u61FEr\xEB\u1003\u0180afl\u3247\u324A\u324Er;\u6986;\uC000\u{1D563}us;\u6A2Eimes;\u6A35\u0100ap\u325D\u3267r\u0100;g\u3263\u3264\u4029t;\u6994olint;\u6A12ar\xF2\u31E3\u0200achq\u327B\u3280\u10BC\u3285quo;\u603Ar;\uC000\u{1D4C7}\u0100bu\u30FB\u328Ao\u0100;r\u0214\u0213\u0180hir\u3297\u329B\u32A0re\xE5\u31F8mes;\u62CAi\u0200;efl\u32AA\u1059\u1821\u32AB\u65B9tri;\u69CEluhar;\u6968;\u611E\u0D61\u32D5\u32DB\u32DF\u332C\u3338\u3371\0\u337A\u33A4\0\0\u33EC\u33F0\0\u3428\u3448\u345A\u34AD\u34B1\u34CA\u34F1\0\u3616\0\0\u3633cute;\u415Bqu\xEF\u27BA\u0500;Eaceinpsy\u11ED\u32F3\u32F5\u32FF\u3302\u330B\u330F\u331F\u3326\u3329;\u6AB4\u01F0\u32FA\0\u32FC;\u6AB8on;\u4161u\xE5\u11FE\u0100;d\u11F3\u3307il;\u415Frc;\u415D\u0180Eas\u3316\u3318\u331B;\u6AB6p;\u6ABAim;\u62E9olint;\u6A13i\xED\u1204;\u4441ot\u0180;be\u3334\u1D47\u3335\u62C5;\u6A66\u0380Aacmstx\u3346\u334A\u3357\u335B\u335E\u3363\u336Drr;\u61D8r\u0100hr\u3350\u3352\xEB\u2228\u0100;o\u0A36\u0A34t\u803B\xA7\u40A7i;\u403Bwar;\u6929m\u0100in\u3369\xF0nu\xF3\xF1t;\u6736r\u0100;o\u3376\u2055\uC000\u{1D530}\u0200acoy\u3382\u3386\u3391\u33A0rp;\u666F\u0100hy\u338B\u338Fcy;\u4449;\u4448rt\u026D\u3399\0\0\u339Ci\xE4\u1464ara\xEC\u2E6F\u803B\xAD\u40AD\u0100gm\u33A8\u33B4ma\u0180;fv\u33B1\u33B2\u33B2\u43C3;\u43C2\u0400;deglnpr\u12AB\u33C5\u33C9\u33CE\u33D6\u33DE\u33E1\u33E6ot;\u6A6A\u0100;q\u12B1\u12B0\u0100;E\u33D3\u33D4\u6A9E;\u6AA0\u0100;E\u33DB\u33DC\u6A9D;\u6A9Fe;\u6246lus;\u6A24arr;\u6972ar\xF2\u113D\u0200aeit\u33F8\u3408\u340F\u3417\u0100ls\u33FD\u3404lsetm\xE9\u336Ahp;\u6A33parsl;\u69E4\u0100dl\u1463\u3414e;\u6323\u0100;e\u341C\u341D\u6AAA\u0100;s\u3422\u3423\u6AAC;\uC000\u2AAC\uFE00\u0180flp\u342E\u3433\u3442tcy;\u444C\u0100;b\u3438\u3439\u402F\u0100;a\u343E\u343F\u69C4r;\u633Ff;\uC000\u{1D564}a\u0100dr\u344D\u0402es\u0100;u\u3454\u3455\u6660it\xBB\u3455\u0180csu\u3460\u3479\u349F\u0100au\u3465\u346Fp\u0100;s\u1188\u346B;\uC000\u2293\uFE00p\u0100;s\u11B4\u3475;\uC000\u2294\uFE00u\u0100bp\u347F\u348F\u0180;es\u1197\u119C\u3486et\u0100;e\u1197\u348D\xF1\u119D\u0180;es\u11A8\u11AD\u3496et\u0100;e\u11A8\u349D\xF1\u11AE\u0180;af\u117B\u34A6\u05B0r\u0165\u34AB\u05B1\xBB\u117Car\xF2\u1148\u0200cemt\u34B9\u34BE\u34C2\u34C5r;\uC000\u{1D4C8}tm\xEE\xF1i\xEC\u3415ar\xE6\u11BE\u0100ar\u34CE\u34D5r\u0100;f\u34D4\u17BF\u6606\u0100an\u34DA\u34EDight\u0100ep\u34E3\u34EApsilo\xEE\u1EE0h\xE9\u2EAFs\xBB\u2852\u0280bcmnp\u34FB\u355E\u1209\u358B\u358E\u0480;Edemnprs\u350E\u350F\u3511\u3515\u351E\u3523\u352C\u3531\u3536\u6282;\u6AC5ot;\u6ABD\u0100;d\u11DA\u351Aot;\u6AC3ult;\u6AC1\u0100Ee\u3528\u352A;\u6ACB;\u628Alus;\u6ABFarr;\u6979\u0180eiu\u353D\u3552\u3555t\u0180;en\u350E\u3545\u354Bq\u0100;q\u11DA\u350Feq\u0100;q\u352B\u3528m;\u6AC7\u0100bp\u355A\u355C;\u6AD5;\u6AD3c\u0300;acens\u11ED\u356C\u3572\u3579\u357B\u3326ppro\xF8\u32FAurlye\xF1\u11FE\xF1\u11F3\u0180aes\u3582\u3588\u331Bppro\xF8\u331Aq\xF1\u3317g;\u666A\u0680123;Edehlmnps\u35A9\u35AC\u35AF\u121C\u35B2\u35B4\u35C0\u35C9\u35D5\u35DA\u35DF\u35E8\u35ED\u803B\xB9\u40B9\u803B\xB2\u40B2\u803B\xB3\u40B3;\u6AC6\u0100os\u35B9\u35BCt;\u6ABEub;\u6AD8\u0100;d\u1222\u35C5ot;\u6AC4s\u0100ou\u35CF\u35D2l;\u67C9b;\u6AD7arr;\u697Bult;\u6AC2\u0100Ee\u35E4\u35E6;\u6ACC;\u628Blus;\u6AC0\u0180eiu\u35F4\u3609\u360Ct\u0180;en\u121C\u35FC\u3602q\u0100;q\u1222\u35B2eq\u0100;q\u35E7\u35E4m;\u6AC8\u0100bp\u3611\u3613;\u6AD4;\u6AD6\u0180Aan\u361C\u3620\u362Drr;\u61D9r\u0100hr\u3626\u3628\xEB\u222E\u0100;o\u0A2B\u0A29war;\u692Alig\u803B\xDF\u40DF\u0BE1\u3651\u365D\u3660\u12CE\u3673\u3679\0\u367E\u36C2\0\0\0\0\0\u36DB\u3703\0\u3709\u376C\0\0\0\u3787\u0272\u3656\0\0\u365Bget;\u6316;\u43C4r\xEB\u0E5F\u0180aey\u3666\u366B\u3670ron;\u4165dil;\u4163;\u4442lrec;\u6315r;\uC000\u{1D531}\u0200eiko\u3686\u369D\u36B5\u36BC\u01F2\u368B\0\u3691e\u01004f\u1284\u1281a\u0180;sv\u3698\u3699\u369B\u43B8ym;\u43D1\u0100cn\u36A2\u36B2k\u0100as\u36A8\u36AEppro\xF8\u12C1im\xBB\u12ACs\xF0\u129E\u0100as\u36BA\u36AE\xF0\u12C1rn\u803B\xFE\u40FE\u01EC\u031F\u36C6\u22E7es\u8180\xD7;bd\u36CF\u36D0\u36D8\u40D7\u0100;a\u190F\u36D5r;\u6A31;\u6A30\u0180eps\u36E1\u36E3\u3700\xE1\u2A4D\u0200;bcf\u0486\u36EC\u36F0\u36F4ot;\u6336ir;\u6AF1\u0100;o\u36F9\u36FC\uC000\u{1D565}rk;\u6ADA\xE1\u3362rime;\u6034\u0180aip\u370F\u3712\u3764d\xE5\u1248\u0380adempst\u3721\u374D\u3740\u3751\u3757\u375C\u375Fngle\u0280;dlqr\u3730\u3731\u3736\u3740\u3742\u65B5own\xBB\u1DBBeft\u0100;e\u2800\u373E\xF1\u092E;\u625Cight\u0100;e\u32AA\u374B\xF1\u105Aot;\u65ECinus;\u6A3Alus;\u6A39b;\u69CDime;\u6A3Bezium;\u63E2\u0180cht\u3772\u377D\u3781\u0100ry\u3777\u377B;\uC000\u{1D4C9};\u4446cy;\u445Brok;\u4167\u0100io\u378B\u378Ex\xF4\u1777head\u0100lr\u3797\u37A0eftarro\xF7\u084Fightarrow\xBB\u0F5D\u0900AHabcdfghlmoprstuw\u37D0\u37D3\u37D7\u37E4\u37F0\u37FC\u380E\u381C\u3823\u3834\u3851\u385D\u386B\u38A9\u38CC\u38D2\u38EA\u38F6r\xF2\u03EDar;\u6963\u0100cr\u37DC\u37E2ute\u803B\xFA\u40FA\xF2\u1150r\u01E3\u37EA\0\u37EDy;\u445Eve;\u416D\u0100iy\u37F5\u37FArc\u803B\xFB\u40FB;\u4443\u0180abh\u3803\u3806\u380Br\xF2\u13ADlac;\u4171a\xF2\u13C3\u0100ir\u3813\u3818sht;\u697E;\uC000\u{1D532}rave\u803B\xF9\u40F9\u0161\u3827\u3831r\u0100lr\u382C\u382E\xBB\u0957\xBB\u1083lk;\u6580\u0100ct\u3839\u384D\u026F\u383F\0\0\u384Arn\u0100;e\u3845\u3846\u631Cr\xBB\u3846op;\u630Fri;\u65F8\u0100al\u3856\u385Acr;\u416B\u80BB\xA8\u0349\u0100gp\u3862\u3866on;\u4173f;\uC000\u{1D566}\u0300adhlsu\u114B\u3878\u387D\u1372\u3891\u38A0own\xE1\u13B3arpoon\u0100lr\u3888\u388Cef\xF4\u382Digh\xF4\u382Fi\u0180;hl\u3899\u389A\u389C\u43C5\xBB\u13FAon\xBB\u389Aparrows;\u61C8\u0180cit\u38B0\u38C4\u38C8\u026F\u38B6\0\0\u38C1rn\u0100;e\u38BC\u38BD\u631Dr\xBB\u38BDop;\u630Eng;\u416Fri;\u65F9cr;\uC000\u{1D4CA}\u0180dir\u38D9\u38DD\u38E2ot;\u62F0lde;\u4169i\u0100;f\u3730\u38E8\xBB\u1813\u0100am\u38EF\u38F2r\xF2\u38A8l\u803B\xFC\u40FCangle;\u69A7\u0780ABDacdeflnoprsz\u391C\u391F\u3929\u392D\u39B5\u39B8\u39BD\u39DF\u39E4\u39E8\u39F3\u39F9\u39FD\u3A01\u3A20r\xF2\u03F7ar\u0100;v\u3926\u3927\u6AE8;\u6AE9as\xE8\u03E1\u0100nr\u3932\u3937grt;\u699C\u0380eknprst\u34E3\u3946\u394B\u3952\u395D\u3964\u3996app\xE1\u2415othin\xE7\u1E96\u0180hir\u34EB\u2EC8\u3959op\xF4\u2FB5\u0100;h\u13B7\u3962\xEF\u318D\u0100iu\u3969\u396Dgm\xE1\u33B3\u0100bp\u3972\u3984setneq\u0100;q\u397D\u3980\uC000\u228A\uFE00;\uC000\u2ACB\uFE00setneq\u0100;q\u398F\u3992\uC000\u228B\uFE00;\uC000\u2ACC\uFE00\u0100hr\u399B\u399Fet\xE1\u369Ciangle\u0100lr\u39AA\u39AFeft\xBB\u0925ight\xBB\u1051y;\u4432ash\xBB\u1036\u0180elr\u39C4\u39D2\u39D7\u0180;be\u2DEA\u39CB\u39CFar;\u62BBq;\u625Alip;\u62EE\u0100bt\u39DC\u1468a\xF2\u1469r;\uC000\u{1D533}tr\xE9\u39AEsu\u0100bp\u39EF\u39F1\xBB\u0D1C\xBB\u0D59pf;\uC000\u{1D567}ro\xF0\u0EFBtr\xE9\u39B4\u0100cu\u3A06\u3A0Br;\uC000\u{1D4CB}\u0100bp\u3A10\u3A18n\u0100Ee\u3980\u3A16\xBB\u397En\u0100Ee\u3992\u3A1E\xBB\u3990igzag;\u699A\u0380cefoprs\u3A36\u3A3B\u3A56\u3A5B\u3A54\u3A61\u3A6Airc;\u4175\u0100di\u3A40\u3A51\u0100bg\u3A45\u3A49ar;\u6A5Fe\u0100;q\u15FA\u3A4F;\u6259erp;\u6118r;\uC000\u{1D534}pf;\uC000\u{1D568}\u0100;e\u1479\u3A66at\xE8\u1479cr;\uC000\u{1D4CC}\u0AE3\u178E\u3A87\0\u3A8B\0\u3A90\u3A9B\0\0\u3A9D\u3AA8\u3AAB\u3AAF\0\0\u3AC3\u3ACE\0\u3AD8\u17DC\u17DFtr\xE9\u17D1r;\uC000\u{1D535}\u0100Aa\u3A94\u3A97r\xF2\u03C3r\xF2\u09F6;\u43BE\u0100Aa\u3AA1\u3AA4r\xF2\u03B8r\xF2\u09EBa\xF0\u2713is;\u62FB\u0180dpt\u17A4\u3AB5\u3ABE\u0100fl\u3ABA\u17A9;\uC000\u{1D569}im\xE5\u17B2\u0100Aa\u3AC7\u3ACAr\xF2\u03CEr\xF2\u0A01\u0100cq\u3AD2\u17B8r;\uC000\u{1D4CD}\u0100pt\u17D6\u3ADCr\xE9\u17D4\u0400acefiosu\u3AF0\u3AFD\u3B08\u3B0C\u3B11\u3B15\u3B1B\u3B21c\u0100uy\u3AF6\u3AFBte\u803B\xFD\u40FD;\u444F\u0100iy\u3B02\u3B06rc;\u4177;\u444Bn\u803B\xA5\u40A5r;\uC000\u{1D536}cy;\u4457pf;\uC000\u{1D56A}cr;\uC000\u{1D4CE}\u0100cm\u3B26\u3B29y;\u444El\u803B\xFF\u40FF\u0500acdefhiosw\u3B42\u3B48\u3B54\u3B58\u3B64\u3B69\u3B6D\u3B74\u3B7A\u3B80cute;\u417A\u0100ay\u3B4D\u3B52ron;\u417E;\u4437ot;\u417C\u0100et\u3B5D\u3B61tr\xE6\u155Fa;\u43B6r;\uC000\u{1D537}cy;\u4436grarr;\u61DDpf;\uC000\u{1D56B}cr;\uC000\u{1D4CF}\u0100jn\u3B85\u3B87;\u600Dj;\u600C'.split("").map(c2=>c2.charCodeAt(0)));init_browser_globals();init_browser_globals();var _a,decodeMap=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]),fromCodePoint=(_a=String.fromCodePoint)!==null&&_a!==void 0?_a:function(codePoint){let output="";return codePoint>65535&&(codePoint-=65536,output+=String.fromCharCode(codePoint>>>10&1023|55296),codePoint=56320|codePoint&1023),output+=String.fromCharCode(codePoint),output};function replaceCodePoint(codePoint){var _a2;return codePoint>=55296&&codePoint<=57343||codePoint>1114111?65533:(_a2=decodeMap.get(codePoint))!==null&&_a2!==void 0?_a2:codePoint}var CharCodes;(function(CharCodes2){CharCodes2[CharCodes2.NUM=35]="NUM",CharCodes2[CharCodes2.SEMI=59]="SEMI",CharCodes2[CharCodes2.EQUALS=61]="EQUALS",CharCodes2[CharCodes2.ZERO=48]="ZERO",CharCodes2[CharCodes2.NINE=57]="NINE",CharCodes2[CharCodes2.LOWER_A=97]="LOWER_A",CharCodes2[CharCodes2.LOWER_F=102]="LOWER_F",CharCodes2[CharCodes2.LOWER_X=120]="LOWER_X",CharCodes2[CharCodes2.LOWER_Z=122]="LOWER_Z",CharCodes2[CharCodes2.UPPER_A=65]="UPPER_A",CharCodes2[CharCodes2.UPPER_F=70]="UPPER_F",CharCodes2[CharCodes2.UPPER_Z=90]="UPPER_Z"})(CharCodes||(CharCodes={}));var TO_LOWER_BIT=32,BinTrieFlags;(function(BinTrieFlags2){BinTrieFlags2[BinTrieFlags2.VALUE_LENGTH=49152]="VALUE_LENGTH",BinTrieFlags2[BinTrieFlags2.BRANCH_LENGTH=16256]="BRANCH_LENGTH",BinTrieFlags2[BinTrieFlags2.JUMP_TABLE=127]="JUMP_TABLE"})(BinTrieFlags||(BinTrieFlags={}));function isNumber(code4){return code4>=CharCodes.ZERO&&code4<=CharCodes.NINE}function isHexadecimalCharacter(code4){return code4>=CharCodes.UPPER_A&&code4<=CharCodes.UPPER_F||code4>=CharCodes.LOWER_A&&code4<=CharCodes.LOWER_F}function isAsciiAlphaNumeric(code4){return code4>=CharCodes.UPPER_A&&code4<=CharCodes.UPPER_Z||code4>=CharCodes.LOWER_A&&code4<=CharCodes.LOWER_Z||isNumber(code4)}function isEntityInAttributeInvalidEnd(code4){return code4===CharCodes.EQUALS||isAsciiAlphaNumeric(code4)}var EntityDecoderState;(function(EntityDecoderState2){EntityDecoderState2[EntityDecoderState2.EntityStart=0]="EntityStart",EntityDecoderState2[EntityDecoderState2.NumericStart=1]="NumericStart",EntityDecoderState2[EntityDecoderState2.NumericDecimal=2]="NumericDecimal",EntityDecoderState2[EntityDecoderState2.NumericHex=3]="NumericHex",EntityDecoderState2[EntityDecoderState2.NamedEntity=4]="NamedEntity"})(EntityDecoderState||(EntityDecoderState={}));var DecodingMode;(function(DecodingMode2){DecodingMode2[DecodingMode2.Legacy=0]="Legacy",DecodingMode2[DecodingMode2.Strict=1]="Strict",DecodingMode2[DecodingMode2.Attribute=2]="Attribute"})(DecodingMode||(DecodingMode={}));var EntityDecoder=class{constructor(decodeTree,emitCodePoint,errors){this.decodeTree=decodeTree,this.emitCodePoint=emitCodePoint,this.errors=errors,this.state=EntityDecoderState.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=DecodingMode.Strict}startEntity(decodeMode){this.decodeMode=decodeMode,this.state=EntityDecoderState.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(input,offset){switch(this.state){case EntityDecoderState.EntityStart:return input.charCodeAt(offset)===CharCodes.NUM?(this.state=EntityDecoderState.NumericStart,this.consumed+=1,this.stateNumericStart(input,offset+1)):(this.state=EntityDecoderState.NamedEntity,this.stateNamedEntity(input,offset));case EntityDecoderState.NumericStart:return this.stateNumericStart(input,offset);case EntityDecoderState.NumericDecimal:return this.stateNumericDecimal(input,offset);case EntityDecoderState.NumericHex:return this.stateNumericHex(input,offset);case EntityDecoderState.NamedEntity:return this.stateNamedEntity(input,offset)}}stateNumericStart(input,offset){return offset>=input.length?-1:(input.charCodeAt(offset)|TO_LOWER_BIT)===CharCodes.LOWER_X?(this.state=EntityDecoderState.NumericHex,this.consumed+=1,this.stateNumericHex(input,offset+1)):(this.state=EntityDecoderState.NumericDecimal,this.stateNumericDecimal(input,offset))}addToNumericResult(input,start,end,base2){if(start!==end){let digitCount=end-start;this.result=this.result*Math.pow(base2,digitCount)+Number.parseInt(input.substr(start,digitCount),base2),this.consumed+=digitCount}}stateNumericHex(input,offset){let startIndex=offset;for(;offset<input.length;){let char=input.charCodeAt(offset);if(isNumber(char)||isHexadecimalCharacter(char))offset+=1;else return this.addToNumericResult(input,startIndex,offset,16),this.emitNumericEntity(char,3)}return this.addToNumericResult(input,startIndex,offset,16),-1}stateNumericDecimal(input,offset){let startIndex=offset;for(;offset<input.length;){let char=input.charCodeAt(offset);if(isNumber(char))offset+=1;else return this.addToNumericResult(input,startIndex,offset,10),this.emitNumericEntity(char,2)}return this.addToNumericResult(input,startIndex,offset,10),-1}emitNumericEntity(lastCp,expectedLength){var _a2;if(this.consumed<=expectedLength)return(_a2=this.errors)===null||_a2===void 0||_a2.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(lastCp===CharCodes.SEMI)this.consumed+=1;else if(this.decodeMode===DecodingMode.Strict)return 0;return this.emitCodePoint(replaceCodePoint(this.result),this.consumed),this.errors&&(lastCp!==CharCodes.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(input,offset){let{decodeTree}=this,current=decodeTree[this.treeIndex],valueLength=(current&BinTrieFlags.VALUE_LENGTH)>>14;for(;offset<input.length;offset++,this.excess++){let char=input.charCodeAt(offset);if(this.treeIndex=determineBranch(decodeTree,current,this.treeIndex+Math.max(1,valueLength),char),this.treeIndex<0)return this.result===0||this.decodeMode===DecodingMode.Attribute&&(valueLength===0||isEntityInAttributeInvalidEnd(char))?0:this.emitNotTerminatedNamedEntity();if(current=decodeTree[this.treeIndex],valueLength=(current&BinTrieFlags.VALUE_LENGTH)>>14,valueLength!==0){if(char===CharCodes.SEMI)return this.emitNamedEntityData(this.treeIndex,valueLength,this.consumed+this.excess);this.decodeMode!==DecodingMode.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var _a2;let{result,decodeTree}=this,valueLength=(decodeTree[result]&BinTrieFlags.VALUE_LENGTH)>>14;return this.emitNamedEntityData(result,valueLength,this.consumed),(_a2=this.errors)===null||_a2===void 0||_a2.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(result,valueLength,consumed){let{decodeTree}=this;return this.emitCodePoint(valueLength===1?decodeTree[result]&~BinTrieFlags.VALUE_LENGTH:decodeTree[result+1],consumed),valueLength===3&&this.emitCodePoint(decodeTree[result+2],consumed),consumed}end(){var _a2;switch(this.state){case EntityDecoderState.NamedEntity:return this.result!==0&&(this.decodeMode!==DecodingMode.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case EntityDecoderState.NumericDecimal:return this.emitNumericEntity(0,2);case EntityDecoderState.NumericHex:return this.emitNumericEntity(0,3);case EntityDecoderState.NumericStart:return(_a2=this.errors)===null||_a2===void 0||_a2.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case EntityDecoderState.EntityStart:return 0}}};function determineBranch(decodeTree,current,nodeIndex,char){let branchCount=(current&BinTrieFlags.BRANCH_LENGTH)>>7,jumpOffset=current&BinTrieFlags.JUMP_TABLE;if(branchCount===0)return jumpOffset!==0&&char===jumpOffset?nodeIndex:-1;if(jumpOffset){let value2=char-jumpOffset;return value2<0||value2>=branchCount?-1:decodeTree[nodeIndex+value2]-1}let lo=nodeIndex,hi=lo+branchCount-1;for(;lo<=hi;){let mid=lo+hi>>>1,midValue=decodeTree[mid];if(midValue<char)lo=mid+1;else if(midValue>char)hi=mid-1;else return decodeTree[mid+branchCount]}return-1}init_browser_globals();var NS;(function(NS2){NS2.HTML="http://www.w3.org/1999/xhtml",NS2.MATHML="http://www.w3.org/1998/Math/MathML",NS2.SVG="http://www.w3.org/2000/svg",NS2.XLINK="http://www.w3.org/1999/xlink",NS2.XML="http://www.w3.org/XML/1998/namespace",NS2.XMLNS="http://www.w3.org/2000/xmlns/"})(NS||(NS={}));var ATTRS;(function(ATTRS2){ATTRS2.TYPE="type",ATTRS2.ACTION="action",ATTRS2.ENCODING="encoding",ATTRS2.PROMPT="prompt",ATTRS2.NAME="name",ATTRS2.COLOR="color",ATTRS2.FACE="face",ATTRS2.SIZE="size"})(ATTRS||(ATTRS={}));var DOCUMENT_MODE;(function(DOCUMENT_MODE2){DOCUMENT_MODE2.NO_QUIRKS="no-quirks",DOCUMENT_MODE2.QUIRKS="quirks",DOCUMENT_MODE2.LIMITED_QUIRKS="limited-quirks"})(DOCUMENT_MODE||(DOCUMENT_MODE={}));var TAG_NAMES;(function(TAG_NAMES2){TAG_NAMES2.A="a",TAG_NAMES2.ADDRESS="address",TAG_NAMES2.ANNOTATION_XML="annotation-xml",TAG_NAMES2.APPLET="applet",TAG_NAMES2.AREA="area",TAG_NAMES2.ARTICLE="article",TAG_NAMES2.ASIDE="aside",TAG_NAMES2.B="b",TAG_NAMES2.BASE="base",TAG_NAMES2.BASEFONT="basefont",TAG_NAMES2.BGSOUND="bgsound",TAG_NAMES2.BIG="big",TAG_NAMES2.BLOCKQUOTE="blockquote",TAG_NAMES2.BODY="body",TAG_NAMES2.BR="br",TAG_NAMES2.BUTTON="button",TAG_NAMES2.CAPTION="caption",TAG_NAMES2.CENTER="center",TAG_NAMES2.CODE="code",TAG_NAMES2.COL="col",TAG_NAMES2.COLGROUP="colgroup",TAG_NAMES2.DD="dd",TAG_NAMES2.DESC="desc",TAG_NAMES2.DETAILS="details",TAG_NAMES2.DIALOG="dialog",TAG_NAMES2.DIR="dir",TAG_NAMES2.DIV="div",TAG_NAMES2.DL="dl",TAG_NAMES2.DT="dt",TAG_NAMES2.EM="em",TAG_NAMES2.EMBED="embed",TAG_NAMES2.FIELDSET="fieldset",TAG_NAMES2.FIGCAPTION="figcaption",TAG_NAMES2.FIGURE="figure",TAG_NAMES2.FONT="font",TAG_NAMES2.FOOTER="footer",TAG_NAMES2.FOREIGN_OBJECT="foreignObject",TAG_NAMES2.FORM="form",TAG_NAMES2.FRAME="frame",TAG_NAMES2.FRAMESET="frameset",TAG_NAMES2.H1="h1",TAG_NAMES2.H2="h2",TAG_NAMES2.H3="h3",TAG_NAMES2.H4="h4",TAG_NAMES2.H5="h5",TAG_NAMES2.H6="h6",TAG_NAMES2.HEAD="head",TAG_NAMES2.HEADER="header",TAG_NAMES2.HGROUP="hgroup",TAG_NAMES2.HR="hr",TAG_NAMES2.HTML="html",TAG_NAMES2.I="i",TAG_NAMES2.IMG="img",TAG_NAMES2.IMAGE="image",TAG_NAMES2.INPUT="input",TAG_NAMES2.IFRAME="iframe",TAG_NAMES2.KEYGEN="keygen",TAG_NAMES2.LABEL="label",TAG_NAMES2.LI="li",TAG_NAMES2.LINK="link",TAG_NAMES2.LISTING="listing",TAG_NAMES2.MAIN="main",TAG_NAMES2.MALIGNMARK="malignmark",TAG_NAMES2.MARQUEE="marquee",TAG_NAMES2.MATH="math",TAG_NAMES2.MENU="menu",TAG_NAMES2.META="meta",TAG_NAMES2.MGLYPH="mglyph",TAG_NAMES2.MI="mi",TAG_NAMES2.MO="mo",TAG_NAMES2.MN="mn",TAG_NAMES2.MS="ms",TAG_NAMES2.MTEXT="mtext",TAG_NAMES2.NAV="nav",TAG_NAMES2.NOBR="nobr",TAG_NAMES2.NOFRAMES="noframes",TAG_NAMES2.NOEMBED="noembed",TAG_NAMES2.NOSCRIPT="noscript",TAG_NAMES2.OBJECT="object",TAG_NAMES2.OL="ol",TAG_NAMES2.OPTGROUP="optgroup",TAG_NAMES2.OPTION="option",TAG_NAMES2.P="p",TAG_NAMES2.PARAM="param",TAG_NAMES2.PLAINTEXT="plaintext",TAG_NAMES2.PRE="pre",TAG_NAMES2.RB="rb",TAG_NAMES2.RP="rp",TAG_NAMES2.RT="rt",TAG_NAMES2.RTC="rtc",TAG_NAMES2.RUBY="ruby",TAG_NAMES2.S="s",TAG_NAMES2.SCRIPT="script",TAG_NAMES2.SEARCH="search",TAG_NAMES2.SECTION="section",TAG_NAMES2.SELECT="select",TAG_NAMES2.SOURCE="source",TAG_NAMES2.SMALL="small",TAG_NAMES2.SPAN="span",TAG_NAMES2.STRIKE="strike",TAG_NAMES2.STRONG="strong",TAG_NAMES2.STYLE="style",TAG_NAMES2.SUB="sub",TAG_NAMES2.SUMMARY="summary",TAG_NAMES2.SUP="sup",TAG_NAMES2.TABLE="table",TAG_NAMES2.TBODY="tbody",TAG_NAMES2.TEMPLATE="template",TAG_NAMES2.TEXTAREA="textarea",TAG_NAMES2.TFOOT="tfoot",TAG_NAMES2.TD="td",TAG_NAMES2.TH="th",TAG_NAMES2.THEAD="thead",TAG_NAMES2.TITLE="title",TAG_NAMES2.TR="tr",TAG_NAMES2.TRACK="track",TAG_NAMES2.TT="tt",TAG_NAMES2.U="u",TAG_NAMES2.UL="ul",TAG_NAMES2.SVG="svg",TAG_NAMES2.VAR="var",TAG_NAMES2.WBR="wbr",TAG_NAMES2.XMP="xmp"})(TAG_NAMES||(TAG_NAMES={}));var TAG_ID;(function(TAG_ID2){TAG_ID2[TAG_ID2.UNKNOWN=0]="UNKNOWN",TAG_ID2[TAG_ID2.A=1]="A",TAG_ID2[TAG_ID2.ADDRESS=2]="ADDRESS",TAG_ID2[TAG_ID2.ANNOTATION_XML=3]="ANNOTATION_XML",TAG_ID2[TAG_ID2.APPLET=4]="APPLET",TAG_ID2[TAG_ID2.AREA=5]="AREA",TAG_ID2[TAG_ID2.ARTICLE=6]="ARTICLE",TAG_ID2[TAG_ID2.ASIDE=7]="ASIDE",TAG_ID2[TAG_ID2.B=8]="B",TAG_ID2[TAG_ID2.BASE=9]="BASE",TAG_ID2[TAG_ID2.BASEFONT=10]="BASEFONT",TAG_ID2[TAG_ID2.BGSOUND=11]="BGSOUND",TAG_ID2[TAG_ID2.BIG=12]="BIG",TAG_ID2[TAG_ID2.BLOCKQUOTE=13]="BLOCKQUOTE",TAG_ID2[TAG_ID2.BODY=14]="BODY",TAG_ID2[TAG_ID2.BR=15]="BR",TAG_ID2[TAG_ID2.BUTTON=16]="BUTTON",TAG_ID2[TAG_ID2.CAPTION=17]="CAPTION",TAG_ID2[TAG_ID2.CENTER=18]="CENTER",TAG_ID2[TAG_ID2.CODE=19]="CODE",TAG_ID2[TAG_ID2.COL=20]="COL",TAG_ID2[TAG_ID2.COLGROUP=21]="COLGROUP",TAG_ID2[TAG_ID2.DD=22]="DD",TAG_ID2[TAG_ID2.DESC=23]="DESC",TAG_ID2[TAG_ID2.DETAILS=24]="DETAILS",TAG_ID2[TAG_ID2.DIALOG=25]="DIALOG",TAG_ID2[TAG_ID2.DIR=26]="DIR",TAG_ID2[TAG_ID2.DIV=27]="DIV",TAG_ID2[TAG_ID2.DL=28]="DL",TAG_ID2[TAG_ID2.DT=29]="DT",TAG_ID2[TAG_ID2.EM=30]="EM",TAG_ID2[TAG_ID2.EMBED=31]="EMBED",TAG_ID2[TAG_ID2.FIELDSET=32]="FIELDSET",TAG_ID2[TAG_ID2.FIGCAPTION=33]="FIGCAPTION",TAG_ID2[TAG_ID2.FIGURE=34]="FIGURE",TAG_ID2[TAG_ID2.FONT=35]="FONT",TAG_ID2[TAG_ID2.FOOTER=36]="FOOTER",TAG_ID2[TAG_ID2.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",TAG_ID2[TAG_ID2.FORM=38]="FORM",TAG_ID2[TAG_ID2.FRAME=39]="FRAME",TAG_ID2[TAG_ID2.FRAMESET=40]="FRAMESET",TAG_ID2[TAG_ID2.H1=41]="H1",TAG_ID2[TAG_ID2.H2=42]="H2",TAG_ID2[TAG_ID2.H3=43]="H3",TAG_ID2[TAG_ID2.H4=44]="H4",TAG_ID2[TAG_ID2.H5=45]="H5",TAG_ID2[TAG_ID2.H6=46]="H6",TAG_ID2[TAG_ID2.HEAD=47]="HEAD",TAG_ID2[TAG_ID2.HEADER=48]="HEADER",TAG_ID2[TAG_ID2.HGROUP=49]="HGROUP",TAG_ID2[TAG_ID2.HR=50]="HR",TAG_ID2[TAG_ID2.HTML=51]="HTML",TAG_ID2[TAG_ID2.I=52]="I",TAG_ID2[TAG_ID2.IMG=53]="IMG",TAG_ID2[TAG_ID2.IMAGE=54]="IMAGE",TAG_ID2[TAG_ID2.INPUT=55]="INPUT",TAG_ID2[TAG_ID2.IFRAME=56]="IFRAME",TAG_ID2[TAG_ID2.KEYGEN=57]="KEYGEN",TAG_ID2[TAG_ID2.LABEL=58]="LABEL",TAG_ID2[TAG_ID2.LI=59]="LI",TAG_ID2[TAG_ID2.LINK=60]="LINK",TAG_ID2[TAG_ID2.LISTING=61]="LISTING",TAG_ID2[TAG_ID2.MAIN=62]="MAIN",TAG_ID2[TAG_ID2.MALIGNMARK=63]="MALIGNMARK",TAG_ID2[TAG_ID2.MARQUEE=64]="MARQUEE",TAG_ID2[TAG_ID2.MATH=65]="MATH",TAG_ID2[TAG_ID2.MENU=66]="MENU",TAG_ID2[TAG_ID2.META=67]="META",TAG_ID2[TAG_ID2.MGLYPH=68]="MGLYPH",TAG_ID2[TAG_ID2.MI=69]="MI",TAG_ID2[TAG_ID2.MO=70]="MO",TAG_ID2[TAG_ID2.MN=71]="MN",TAG_ID2[TAG_ID2.MS=72]="MS",TAG_ID2[TAG_ID2.MTEXT=73]="MTEXT",TAG_ID2[TAG_ID2.NAV=74]="NAV",TAG_ID2[TAG_ID2.NOBR=75]="NOBR",TAG_ID2[TAG_ID2.NOFRAMES=76]="NOFRAMES",TAG_ID2[TAG_ID2.NOEMBED=77]="NOEMBED",TAG_ID2[TAG_ID2.NOSCRIPT=78]="NOSCRIPT",TAG_ID2[TAG_ID2.OBJECT=79]="OBJECT",TAG_ID2[TAG_ID2.OL=80]="OL",TAG_ID2[TAG_ID2.OPTGROUP=81]="OPTGROUP",TAG_ID2[TAG_ID2.OPTION=82]="OPTION",TAG_ID2[TAG_ID2.P=83]="P",TAG_ID2[TAG_ID2.PARAM=84]="PARAM",TAG_ID2[TAG_ID2.PLAINTEXT=85]="PLAINTEXT",TAG_ID2[TAG_ID2.PRE=86]="PRE",TAG_ID2[TAG_ID2.RB=87]="RB",TAG_ID2[TAG_ID2.RP=88]="RP",TAG_ID2[TAG_ID2.RT=89]="RT",TAG_ID2[TAG_ID2.RTC=90]="RTC",TAG_ID2[TAG_ID2.RUBY=91]="RUBY",TAG_ID2[TAG_ID2.S=92]="S",TAG_ID2[TAG_ID2.SCRIPT=93]="SCRIPT",TAG_ID2[TAG_ID2.SEARCH=94]="SEARCH",TAG_ID2[TAG_ID2.SECTION=95]="SECTION",TAG_ID2[TAG_ID2.SELECT=96]="SELECT",TAG_ID2[TAG_ID2.SOURCE=97]="SOURCE",TAG_ID2[TAG_ID2.SMALL=98]="SMALL",TAG_ID2[TAG_ID2.SPAN=99]="SPAN",TAG_ID2[TAG_ID2.STRIKE=100]="STRIKE",TAG_ID2[TAG_ID2.STRONG=101]="STRONG",TAG_ID2[TAG_ID2.STYLE=102]="STYLE",TAG_ID2[TAG_ID2.SUB=103]="SUB",TAG_ID2[TAG_ID2.SUMMARY=104]="SUMMARY",TAG_ID2[TAG_ID2.SUP=105]="SUP",TAG_ID2[TAG_ID2.TABLE=106]="TABLE",TAG_ID2[TAG_ID2.TBODY=107]="TBODY",TAG_ID2[TAG_ID2.TEMPLATE=108]="TEMPLATE",TAG_ID2[TAG_ID2.TEXTAREA=109]="TEXTAREA",TAG_ID2[TAG_ID2.TFOOT=110]="TFOOT",TAG_ID2[TAG_ID2.TD=111]="TD",TAG_ID2[TAG_ID2.TH=112]="TH",TAG_ID2[TAG_ID2.THEAD=113]="THEAD",TAG_ID2[TAG_ID2.TITLE=114]="TITLE",TAG_ID2[TAG_ID2.TR=115]="TR",TAG_ID2[TAG_ID2.TRACK=116]="TRACK",TAG_ID2[TAG_ID2.TT=117]="TT",TAG_ID2[TAG_ID2.U=118]="U",TAG_ID2[TAG_ID2.UL=119]="UL",TAG_ID2[TAG_ID2.SVG=120]="SVG",TAG_ID2[TAG_ID2.VAR=121]="VAR",TAG_ID2[TAG_ID2.WBR=122]="WBR",TAG_ID2[TAG_ID2.XMP=123]="XMP"})(TAG_ID||(TAG_ID={}));var TAG_NAME_TO_ID=new Map([[TAG_NAMES.A,TAG_ID.A],[TAG_NAMES.ADDRESS,TAG_ID.ADDRESS],[TAG_NAMES.ANNOTATION_XML,TAG_ID.ANNOTATION_XML],[TAG_NAMES.APPLET,TAG_ID.APPLET],[TAG_NAMES.AREA,TAG_ID.AREA],[TAG_NAMES.ARTICLE,TAG_ID.ARTICLE],[TAG_NAMES.ASIDE,TAG_ID.ASIDE],[TAG_NAMES.B,TAG_ID.B],[TAG_NAMES.BASE,TAG_ID.BASE],[TAG_NAMES.BASEFONT,TAG_ID.BASEFONT],[TAG_NAMES.BGSOUND,TAG_ID.BGSOUND],[TAG_NAMES.BIG,TAG_ID.BIG],[TAG_NAMES.BLOCKQUOTE,TAG_ID.BLOCKQUOTE],[TAG_NAMES.BODY,TAG_ID.BODY],[TAG_NAMES.BR,TAG_ID.BR],[TAG_NAMES.BUTTON,TAG_ID.BUTTON],[TAG_NAMES.CAPTION,TAG_ID.CAPTION],[TAG_NAMES.CENTER,TAG_ID.CENTER],[TAG_NAMES.CODE,TAG_ID.CODE],[TAG_NAMES.COL,TAG_ID.COL],[TAG_NAMES.COLGROUP,TAG_ID.COLGROUP],[TAG_NAMES.DD,TAG_ID.DD],[TAG_NAMES.DESC,TAG_ID.DESC],[TAG_NAMES.DETAILS,TAG_ID.DETAILS],[TAG_NAMES.DIALOG,TAG_ID.DIALOG],[TAG_NAMES.DIR,TAG_ID.DIR],[TAG_NAMES.DIV,TAG_ID.DIV],[TAG_NAMES.DL,TAG_ID.DL],[TAG_NAMES.DT,TAG_ID.DT],[TAG_NAMES.EM,TAG_ID.EM],[TAG_NAMES.EMBED,TAG_ID.EMBED],[TAG_NAMES.FIELDSET,TAG_ID.FIELDSET],[TAG_NAMES.FIGCAPTION,TAG_ID.FIGCAPTION],[TAG_NAMES.FIGURE,TAG_ID.FIGURE],[TAG_NAMES.FONT,TAG_ID.FONT],[TAG_NAMES.FOOTER,TAG_ID.FOOTER],[TAG_NAMES.FOREIGN_OBJECT,TAG_ID.FOREIGN_OBJECT],[TAG_NAMES.FORM,TAG_ID.FORM],[TAG_NAMES.FRAME,TAG_ID.FRAME],[TAG_NAMES.FRAMESET,TAG_ID.FRAMESET],[TAG_NAMES.H1,TAG_ID.H1],[TAG_NAMES.H2,TAG_ID.H2],[TAG_NAMES.H3,TAG_ID.H3],[TAG_NAMES.H4,TAG_ID.H4],[TAG_NAMES.H5,TAG_ID.H5],[TAG_NAMES.H6,TAG_ID.H6],[TAG_NAMES.HEAD,TAG_ID.HEAD],[TAG_NAMES.HEADER,TAG_ID.HEADER],[TAG_NAMES.HGROUP,TAG_ID.HGROUP],[TAG_NAMES.HR,TAG_ID.HR],[TAG_NAMES.HTML,TAG_ID.HTML],[TAG_NAMES.I,TAG_ID.I],[TAG_NAMES.IMG,TAG_ID.IMG],[TAG_NAMES.IMAGE,TAG_ID.IMAGE],[TAG_NAMES.INPUT,TAG_ID.INPUT],[TAG_NAMES.IFRAME,TAG_ID.IFRAME],[TAG_NAMES.KEYGEN,TAG_ID.KEYGEN],[TAG_NAMES.LABEL,TAG_ID.LABEL],[TAG_NAMES.LI,TAG_ID.LI],[TAG_NAMES.LINK,TAG_ID.LINK],[TAG_NAMES.LISTING,TAG_ID.LISTING],[TAG_NAMES.MAIN,TAG_ID.MAIN],[TAG_NAMES.MALIGNMARK,TAG_ID.MALIGNMARK],[TAG_NAMES.MARQUEE,TAG_ID.MARQUEE],[TAG_NAMES.MATH,TAG_ID.MATH],[TAG_NAMES.MENU,TAG_ID.MENU],[TAG_NAMES.META,TAG_ID.META],[TAG_NAMES.MGLYPH,TAG_ID.MGLYPH],[TAG_NAMES.MI,TAG_ID.MI],[TAG_NAMES.MO,TAG_ID.MO],[TAG_NAMES.MN,TAG_ID.MN],[TAG_NAMES.MS,TAG_ID.MS],[TAG_NAMES.MTEXT,TAG_ID.MTEXT],[TAG_NAMES.NAV,TAG_ID.NAV],[TAG_NAMES.NOBR,TAG_ID.NOBR],[TAG_NAMES.NOFRAMES,TAG_ID.NOFRAMES],[TAG_NAMES.NOEMBED,TAG_ID.NOEMBED],[TAG_NAMES.NOSCRIPT,TAG_ID.NOSCRIPT],[TAG_NAMES.OBJECT,TAG_ID.OBJECT],[TAG_NAMES.OL,TAG_ID.OL],[TAG_NAMES.OPTGROUP,TAG_ID.OPTGROUP],[TAG_NAMES.OPTION,TAG_ID.OPTION],[TAG_NAMES.P,TAG_ID.P],[TAG_NAMES.PARAM,TAG_ID.PARAM],[TAG_NAMES.PLAINTEXT,TAG_ID.PLAINTEXT],[TAG_NAMES.PRE,TAG_ID.PRE],[TAG_NAMES.RB,TAG_ID.RB],[TAG_NAMES.RP,TAG_ID.RP],[TAG_NAMES.RT,TAG_ID.RT],[TAG_NAMES.RTC,TAG_ID.RTC],[TAG_NAMES.RUBY,TAG_ID.RUBY],[TAG_NAMES.S,TAG_ID.S],[TAG_NAMES.SCRIPT,TAG_ID.SCRIPT],[TAG_NAMES.SEARCH,TAG_ID.SEARCH],[TAG_NAMES.SECTION,TAG_ID.SECTION],[TAG_NAMES.SELECT,TAG_ID.SELECT],[TAG_NAMES.SOURCE,TAG_ID.SOURCE],[TAG_NAMES.SMALL,TAG_ID.SMALL],[TAG_NAMES.SPAN,TAG_ID.SPAN],[TAG_NAMES.STRIKE,TAG_ID.STRIKE],[TAG_NAMES.STRONG,TAG_ID.STRONG],[TAG_NAMES.STYLE,TAG_ID.STYLE],[TAG_NAMES.SUB,TAG_ID.SUB],[TAG_NAMES.SUMMARY,TAG_ID.SUMMARY],[TAG_NAMES.SUP,TAG_ID.SUP],[TAG_NAMES.TABLE,TAG_ID.TABLE],[TAG_NAMES.TBODY,TAG_ID.TBODY],[TAG_NAMES.TEMPLATE,TAG_ID.TEMPLATE],[TAG_NAMES.TEXTAREA,TAG_ID.TEXTAREA],[TAG_NAMES.TFOOT,TAG_ID.TFOOT],[TAG_NAMES.TD,TAG_ID.TD],[TAG_NAMES.TH,TAG_ID.TH],[TAG_NAMES.THEAD,TAG_ID.THEAD],[TAG_NAMES.TITLE,TAG_ID.TITLE],[TAG_NAMES.TR,TAG_ID.TR],[TAG_NAMES.TRACK,TAG_ID.TRACK],[TAG_NAMES.TT,TAG_ID.TT],[TAG_NAMES.U,TAG_ID.U],[TAG_NAMES.UL,TAG_ID.UL],[TAG_NAMES.SVG,TAG_ID.SVG],[TAG_NAMES.VAR,TAG_ID.VAR],[TAG_NAMES.WBR,TAG_ID.WBR],[TAG_NAMES.XMP,TAG_ID.XMP]]);function getTagID(tagName){var _a2;return(_a2=TAG_NAME_TO_ID.get(tagName))!==null&&_a2!==void 0?_a2:TAG_ID.UNKNOWN}var $2=TAG_ID,SPECIAL_ELEMENTS={[NS.HTML]:new Set([$2.ADDRESS,$2.APPLET,$2.AREA,$2.ARTICLE,$2.ASIDE,$2.BASE,$2.BASEFONT,$2.BGSOUND,$2.BLOCKQUOTE,$2.BODY,$2.BR,$2.BUTTON,$2.CAPTION,$2.CENTER,$2.COL,$2.COLGROUP,$2.DD,$2.DETAILS,$2.DIR,$2.DIV,$2.DL,$2.DT,$2.EMBED,$2.FIELDSET,$2.FIGCAPTION,$2.FIGURE,$2.FOOTER,$2.FORM,$2.FRAME,$2.FRAMESET,$2.H1,$2.H2,$2.H3,$2.H4,$2.H5,$2.H6,$2.HEAD,$2.HEADER,$2.HGROUP,$2.HR,$2.HTML,$2.IFRAME,$2.IMG,$2.INPUT,$2.LI,$2.LINK,$2.LISTING,$2.MAIN,$2.MARQUEE,$2.MENU,$2.META,$2.NAV,$2.NOEMBED,$2.NOFRAMES,$2.NOSCRIPT,$2.OBJECT,$2.OL,$2.P,$2.PARAM,$2.PLAINTEXT,$2.PRE,$2.SCRIPT,$2.SECTION,$2.SELECT,$2.SOURCE,$2.STYLE,$2.SUMMARY,$2.TABLE,$2.TBODY,$2.TD,$2.TEMPLATE,$2.TEXTAREA,$2.TFOOT,$2.TH,$2.THEAD,$2.TITLE,$2.TR,$2.TRACK,$2.UL,$2.WBR,$2.XMP]),[NS.MATHML]:new Set([$2.MI,$2.MO,$2.MN,$2.MS,$2.MTEXT,$2.ANNOTATION_XML]),[NS.SVG]:new Set([$2.TITLE,$2.FOREIGN_OBJECT,$2.DESC]),[NS.XLINK]:new Set,[NS.XML]:new Set,[NS.XMLNS]:new Set},NUMBERED_HEADERS=new Set([$2.H1,$2.H2,$2.H3,$2.H4,$2.H5,$2.H6]),UNESCAPED_TEXT=new Set([TAG_NAMES.STYLE,TAG_NAMES.SCRIPT,TAG_NAMES.XMP,TAG_NAMES.IFRAME,TAG_NAMES.NOEMBED,TAG_NAMES.NOFRAMES,TAG_NAMES.PLAINTEXT]);var State;(function(State2){State2[State2.DATA=0]="DATA",State2[State2.RCDATA=1]="RCDATA",State2[State2.RAWTEXT=2]="RAWTEXT",State2[State2.SCRIPT_DATA=3]="SCRIPT_DATA",State2[State2.PLAINTEXT=4]="PLAINTEXT",State2[State2.TAG_OPEN=5]="TAG_OPEN",State2[State2.END_TAG_OPEN=6]="END_TAG_OPEN",State2[State2.TAG_NAME=7]="TAG_NAME",State2[State2.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",State2[State2.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",State2[State2.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",State2[State2.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",State2[State2.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",State2[State2.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",State2[State2.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",State2[State2.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",State2[State2.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",State2[State2.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",State2[State2.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",State2[State2.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",State2[State2.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",State2[State2.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",State2[State2.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",State2[State2.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",State2[State2.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",State2[State2.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",State2[State2.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",State2[State2.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",State2[State2.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",State2[State2.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",State2[State2.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",State2[State2.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",State2[State2.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",State2[State2.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",State2[State2.BOGUS_COMMENT=40]="BOGUS_COMMENT",State2[State2.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",State2[State2.COMMENT_START=42]="COMMENT_START",State2[State2.COMMENT_START_DASH=43]="COMMENT_START_DASH",State2[State2.COMMENT=44]="COMMENT",State2[State2.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",State2[State2.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",State2[State2.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",State2[State2.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",State2[State2.COMMENT_END_DASH=49]="COMMENT_END_DASH",State2[State2.COMMENT_END=50]="COMMENT_END",State2[State2.COMMENT_END_BANG=51]="COMMENT_END_BANG",State2[State2.DOCTYPE=52]="DOCTYPE",State2[State2.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",State2[State2.DOCTYPE_NAME=54]="DOCTYPE_NAME",State2[State2.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",State2[State2.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",State2[State2.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",State2[State2.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",State2[State2.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",State2[State2.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",State2[State2.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",State2[State2.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",State2[State2.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",State2[State2.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",State2[State2.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",State2[State2.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",State2[State2.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",State2[State2.CDATA_SECTION=68]="CDATA_SECTION",State2[State2.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",State2[State2.CDATA_SECTION_END=70]="CDATA_SECTION_END",State2[State2.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",State2[State2.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(State||(State={}));var TokenizerMode={DATA:State.DATA,RCDATA:State.RCDATA,RAWTEXT:State.RAWTEXT,SCRIPT_DATA:State.SCRIPT_DATA,PLAINTEXT:State.PLAINTEXT,CDATA_SECTION:State.CDATA_SECTION};function isAsciiDigit(cp){return cp>=CODE_POINTS.DIGIT_0&&cp<=CODE_POINTS.DIGIT_9}function isAsciiUpper(cp){return cp>=CODE_POINTS.LATIN_CAPITAL_A&&cp<=CODE_POINTS.LATIN_CAPITAL_Z}function isAsciiLower(cp){return cp>=CODE_POINTS.LATIN_SMALL_A&&cp<=CODE_POINTS.LATIN_SMALL_Z}function isAsciiLetter(cp){return isAsciiLower(cp)||isAsciiUpper(cp)}function isAsciiAlphaNumeric2(cp){return isAsciiLetter(cp)||isAsciiDigit(cp)}function toAsciiLower(cp){return cp+32}function isWhitespace(cp){return cp===CODE_POINTS.SPACE||cp===CODE_POINTS.LINE_FEED||cp===CODE_POINTS.TABULATION||cp===CODE_POINTS.FORM_FEED}function isScriptDataDoubleEscapeSequenceEnd(cp){return isWhitespace(cp)||cp===CODE_POINTS.SOLIDUS||cp===CODE_POINTS.GREATER_THAN_SIGN}function getErrorForNumericCharacterReference(code4){return code4===CODE_POINTS.NULL?ERR.nullCharacterReference:code4>1114111?ERR.characterReferenceOutsideUnicodeRange:isSurrogate(code4)?ERR.surrogateCharacterReference:isUndefinedCodePoint(code4)?ERR.noncharacterCharacterReference:isControlCodePoint(code4)||code4===CODE_POINTS.CARRIAGE_RETURN?ERR.controlCharacterReference:null}var Tokenizer=class{constructor(options2,handler2){this.options=options2,this.handler=handler2,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=State.DATA,this.returnState=State.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new Preprocessor(handler2),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new EntityDecoder(htmlDecodeTree,(cp,consumed)=>{this.preprocessor.pos=this.entityStartPos+consumed-1,this._flushCodePointConsumedAsCharacterReference(cp)},handler2.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(ERR.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:consumed=>{this._err(ERR.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+consumed)},validateNumericCharacterReference:code4=>{let error=getErrorForNumericCharacterReference(code4);error&&this._err(error,1)}}:void 0)}_err(code4,cpOffset=0){var _a2,_b;(_b=(_a2=this.handler).onParseError)===null||_b===void 0||_b.call(_a2,this.preprocessor.getError(code4,cpOffset))}getCurrentLocation(offset){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-offset,startOffset:this.preprocessor.offset-offset,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;let cp=this._consume();this._ensureHibernation()||this._callState(cp)}this.inLoop=!1}}pause(){this.paused=!0}resume(writeCallback){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||writeCallback?.())}write(chunk,isLastChunk,writeCallback){this.active=!0,this.preprocessor.write(chunk,isLastChunk),this._runParsingLoop(),this.paused||writeCallback?.()}insertHtmlAtCurrentPos(chunk){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(chunk),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(count){this.consumedAfterSnapshot+=count;for(let i2=0;i2<count;i2++)this.preprocessor.advance()}_consumeSequenceIfMatch(pattern,caseSensitive){return this.preprocessor.startsWith(pattern,caseSensitive)?(this._advanceBy(pattern.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:TokenType.START_TAG,tagName:"",tagID:TAG_ID.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:TokenType.END_TAG,tagName:"",tagID:TAG_ID.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(offset){this.currentToken={type:TokenType.COMMENT,data:"",location:this.getCurrentLocation(offset)}}_createDoctypeToken(initialName){this.currentToken={type:TokenType.DOCTYPE,name:initialName,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(type,chars){this.currentCharacterToken={type,chars,location:this.currentLocation}}_createAttr(attrNameFirstCh){this.currentAttr={name:attrNameFirstCh,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var _a2,_b;let token=this.currentToken;if(getTokenAttr(token,this.currentAttr.name)===null){if(token.attrs.push(this.currentAttr),token.location&&this.currentLocation){let attrLocations=(_a2=(_b=token.location).attrs)!==null&&_a2!==void 0?_a2:_b.attrs=Object.create(null);attrLocations[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(ERR.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(ct2){this._emitCurrentCharacterToken(ct2.location),this.currentToken=null,ct2.location&&(ct2.location.endLine=this.preprocessor.line,ct2.location.endCol=this.preprocessor.col+1,ct2.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){let ct2=this.currentToken;this.prepareToken(ct2),ct2.tagID=getTagID(ct2.tagName),ct2.type===TokenType.START_TAG?(this.lastStartTagName=ct2.tagName,this.handler.onStartTag(ct2)):(ct2.attrs.length>0&&this._err(ERR.endTagWithAttributes),ct2.selfClosing&&this._err(ERR.endTagWithTrailingSolidus),this.handler.onEndTag(ct2)),this.preprocessor.dropParsedChunk()}emitCurrentComment(ct2){this.prepareToken(ct2),this.handler.onComment(ct2),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(ct2){this.prepareToken(ct2),this.handler.onDoctype(ct2),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(nextLocation){if(this.currentCharacterToken){switch(nextLocation&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=nextLocation.startLine,this.currentCharacterToken.location.endCol=nextLocation.startCol,this.currentCharacterToken.location.endOffset=nextLocation.startOffset),this.currentCharacterToken.type){case TokenType.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case TokenType.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case TokenType.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){let location2=this.getCurrentLocation(0);location2&&(location2.endLine=location2.startLine,location2.endCol=location2.startCol,location2.endOffset=location2.startOffset),this._emitCurrentCharacterToken(location2),this.handler.onEof({type:TokenType.EOF,location:location2}),this.active=!1}_appendCharToCurrentCharacterToken(type,ch){if(this.currentCharacterToken)if(this.currentCharacterToken.type===type){this.currentCharacterToken.chars+=ch;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(type,ch)}_emitCodePoint(cp){let type=isWhitespace(cp)?TokenType.WHITESPACE_CHARACTER:cp===CODE_POINTS.NULL?TokenType.NULL_CHARACTER:TokenType.CHARACTER;this._appendCharToCurrentCharacterToken(type,String.fromCodePoint(cp))}_emitChars(ch){this._appendCharToCurrentCharacterToken(TokenType.CHARACTER,ch)}_startCharacterReference(){this.returnState=this.state,this.state=State.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?DecodingMode.Attribute:DecodingMode.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===State.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===State.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===State.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(cp){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(cp):this._emitCodePoint(cp)}_callState(cp){switch(this.state){case State.DATA:{this._stateData(cp);break}case State.RCDATA:{this._stateRcdata(cp);break}case State.RAWTEXT:{this._stateRawtext(cp);break}case State.SCRIPT_DATA:{this._stateScriptData(cp);break}case State.PLAINTEXT:{this._statePlaintext(cp);break}case State.TAG_OPEN:{this._stateTagOpen(cp);break}case State.END_TAG_OPEN:{this._stateEndTagOpen(cp);break}case State.TAG_NAME:{this._stateTagName(cp);break}case State.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(cp);break}case State.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(cp);break}case State.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(cp);break}case State.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(cp);break}case State.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(cp);break}case State.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(cp);break}case State.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(cp);break}case State.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(cp);break}case State.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(cp);break}case State.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(cp);break}case State.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(cp);break}case State.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(cp);break}case State.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(cp);break}case State.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(cp);break}case State.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(cp);break}case State.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(cp);break}case State.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(cp);break}case State.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(cp);break}case State.ATTRIBUTE_NAME:{this._stateAttributeName(cp);break}case State.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(cp);break}case State.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(cp);break}case State.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(cp);break}case State.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(cp);break}case State.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(cp);break}case State.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(cp);break}case State.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(cp);break}case State.BOGUS_COMMENT:{this._stateBogusComment(cp);break}case State.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(cp);break}case State.COMMENT_START:{this._stateCommentStart(cp);break}case State.COMMENT_START_DASH:{this._stateCommentStartDash(cp);break}case State.COMMENT:{this._stateComment(cp);break}case State.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(cp);break}case State.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(cp);break}case State.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(cp);break}case State.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(cp);break}case State.COMMENT_END_DASH:{this._stateCommentEndDash(cp);break}case State.COMMENT_END:{this._stateCommentEnd(cp);break}case State.COMMENT_END_BANG:{this._stateCommentEndBang(cp);break}case State.DOCTYPE:{this._stateDoctype(cp);break}case State.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(cp);break}case State.DOCTYPE_NAME:{this._stateDoctypeName(cp);break}case State.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(cp);break}case State.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(cp);break}case State.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(cp);break}case State.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(cp);break}case State.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(cp);break}case State.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(cp);break}case State.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(cp);break}case State.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(cp);break}case State.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(cp);break}case State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(cp);break}case State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(cp);break}case State.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(cp);break}case State.BOGUS_DOCTYPE:{this._stateBogusDoctype(cp);break}case State.CDATA_SECTION:{this._stateCdataSection(cp);break}case State.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(cp);break}case State.CDATA_SECTION_END:{this._stateCdataSectionEnd(cp);break}case State.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case State.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(cp);break}default:throw new Error("Unknown state")}}_stateData(cp){switch(cp){case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.TAG_OPEN;break}case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitCodePoint(cp);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateRcdata(cp){switch(cp){case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.RCDATA_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateRawtext(cp){switch(cp){case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.RAWTEXT_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateScriptData(cp){switch(cp){case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_statePlaintext(cp){switch(cp){case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateTagOpen(cp){if(isAsciiLetter(cp))this._createStartTagToken(),this.state=State.TAG_NAME,this._stateTagName(cp);else switch(cp){case CODE_POINTS.EXCLAMATION_MARK:{this.state=State.MARKUP_DECLARATION_OPEN;break}case CODE_POINTS.SOLIDUS:{this.state=State.END_TAG_OPEN;break}case CODE_POINTS.QUESTION_MARK:{this._err(ERR.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=State.BOGUS_COMMENT,this._stateBogusComment(cp);break}case CODE_POINTS.EOF:{this._err(ERR.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(ERR.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=State.DATA,this._stateData(cp)}}_stateEndTagOpen(cp){if(isAsciiLetter(cp))this._createEndTagToken(),this.state=State.TAG_NAME,this._stateTagName(cp);else switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingEndTagName),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(ERR.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=State.BOGUS_COMMENT,this._stateBogusComment(cp)}}_stateTagName(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BEFORE_ATTRIBUTE_NAME;break}case CODE_POINTS.SOLIDUS:{this.state=State.SELF_CLOSING_START_TAG;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.tagName+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:token.tagName+=String.fromCodePoint(isAsciiUpper(cp)?toAsciiLower(cp):cp)}}_stateRcdataLessThanSign(cp){cp===CODE_POINTS.SOLIDUS?this.state=State.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=State.RCDATA,this._stateRcdata(cp))}_stateRcdataEndTagOpen(cp){isAsciiLetter(cp)?(this.state=State.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(cp)):(this._emitChars("</"),this.state=State.RCDATA,this._stateRcdata(cp))}handleSpecialEndTag(_cp){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();let token=this.currentToken;switch(token.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=State.BEFORE_ATTRIBUTE_NAME,!1;case CODE_POINTS.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=State.SELF_CLOSING_START_TAG,!1;case CODE_POINTS.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=State.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(cp){this.handleSpecialEndTag(cp)&&(this._emitChars("</"),this.state=State.RCDATA,this._stateRcdata(cp))}_stateRawtextLessThanSign(cp){cp===CODE_POINTS.SOLIDUS?this.state=State.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=State.RAWTEXT,this._stateRawtext(cp))}_stateRawtextEndTagOpen(cp){isAsciiLetter(cp)?(this.state=State.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(cp)):(this._emitChars("</"),this.state=State.RAWTEXT,this._stateRawtext(cp))}_stateRawtextEndTagName(cp){this.handleSpecialEndTag(cp)&&(this._emitChars("</"),this.state=State.RAWTEXT,this._stateRawtext(cp))}_stateScriptDataLessThanSign(cp){switch(cp){case CODE_POINTS.SOLIDUS:{this.state=State.SCRIPT_DATA_END_TAG_OPEN;break}case CODE_POINTS.EXCLAMATION_MARK:{this.state=State.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=State.SCRIPT_DATA,this._stateScriptData(cp)}}_stateScriptDataEndTagOpen(cp){isAsciiLetter(cp)?(this.state=State.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(cp)):(this._emitChars("</"),this.state=State.SCRIPT_DATA,this._stateScriptData(cp))}_stateScriptDataEndTagName(cp){this.handleSpecialEndTag(cp)&&(this._emitChars("</"),this.state=State.SCRIPT_DATA,this._stateScriptData(cp))}_stateScriptDataEscapeStart(cp){cp===CODE_POINTS.HYPHEN_MINUS?(this.state=State.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=State.SCRIPT_DATA,this._stateScriptData(cp))}_stateScriptDataEscapeStartDash(cp){cp===CODE_POINTS.HYPHEN_MINUS?(this.state=State.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=State.SCRIPT_DATA,this._stateScriptData(cp))}_stateScriptDataEscaped(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateScriptDataEscapedDash(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.state=State.SCRIPT_DATA_ESCAPED,this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=State.SCRIPT_DATA_ESCAPED,this._emitCodePoint(cp)}}_stateScriptDataEscapedDashDash(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.SCRIPT_DATA,this._emitChars(">");break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.state=State.SCRIPT_DATA_ESCAPED,this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=State.SCRIPT_DATA_ESCAPED,this._emitCodePoint(cp)}}_stateScriptDataEscapedLessThanSign(cp){cp===CODE_POINTS.SOLIDUS?this.state=State.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:isAsciiLetter(cp)?(this._emitChars("<"),this.state=State.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(cp)):(this._emitChars("<"),this.state=State.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(cp))}_stateScriptDataEscapedEndTagOpen(cp){isAsciiLetter(cp)?(this.state=State.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(cp)):(this._emitChars("</"),this.state=State.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(cp))}_stateScriptDataEscapedEndTagName(cp){this.handleSpecialEndTag(cp)&&(this._emitChars("</"),this.state=State.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(cp))}_stateScriptDataDoubleEscapeStart(cp){if(this.preprocessor.startsWith(SEQUENCES.SCRIPT,!1)&&isScriptDataDoubleEscapeSequenceEnd(this.preprocessor.peek(SEQUENCES.SCRIPT.length))){this._emitCodePoint(cp);for(let i2=0;i2<SEQUENCES.SCRIPT.length;i2++)this._emitCodePoint(this._consume());this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=State.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(cp))}_stateScriptDataDoubleEscaped(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateScriptDataDoubleEscapedDash(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(cp)}}_stateScriptDataDoubleEscapedDashDash(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.SCRIPT_DATA,this._emitChars(">");break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(cp)}}_stateScriptDataDoubleEscapedLessThanSign(cp){cp===CODE_POINTS.SOLIDUS?(this.state=State.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(cp))}_stateScriptDataDoubleEscapeEnd(cp){if(this.preprocessor.startsWith(SEQUENCES.SCRIPT,!1)&&isScriptDataDoubleEscapeSequenceEnd(this.preprocessor.peek(SEQUENCES.SCRIPT.length))){this._emitCodePoint(cp);for(let i2=0;i2<SEQUENCES.SCRIPT.length;i2++)this._emitCodePoint(this._consume());this.state=State.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(cp))}_stateBeforeAttributeName(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.SOLIDUS:case CODE_POINTS.GREATER_THAN_SIGN:case CODE_POINTS.EOF:{this.state=State.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(cp);break}case CODE_POINTS.EQUALS_SIGN:{this._err(ERR.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=State.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=State.ATTRIBUTE_NAME,this._stateAttributeName(cp)}}_stateAttributeName(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:case CODE_POINTS.SOLIDUS:case CODE_POINTS.GREATER_THAN_SIGN:case CODE_POINTS.EOF:{this._leaveAttrName(),this.state=State.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(cp);break}case CODE_POINTS.EQUALS_SIGN:{this._leaveAttrName(),this.state=State.BEFORE_ATTRIBUTE_VALUE;break}case CODE_POINTS.QUOTATION_MARK:case CODE_POINTS.APOSTROPHE:case CODE_POINTS.LESS_THAN_SIGN:{this._err(ERR.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(cp);break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.currentAttr.name+=REPLACEMENT_CHARACTER;break}default:this.currentAttr.name+=String.fromCodePoint(isAsciiUpper(cp)?toAsciiLower(cp):cp)}}_stateAfterAttributeName(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.SOLIDUS:{this.state=State.SELF_CLOSING_START_TAG;break}case CODE_POINTS.EQUALS_SIGN:{this.state=State.BEFORE_ATTRIBUTE_VALUE;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=State.ATTRIBUTE_NAME,this._stateAttributeName(cp)}}_stateBeforeAttributeValue(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.QUOTATION_MARK:{this.state=State.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{this.state=State.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingAttributeValue),this.state=State.DATA,this.emitCurrentTagToken();break}default:this.state=State.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(cp)}}_stateAttributeValueDoubleQuoted(cp){switch(cp){case CODE_POINTS.QUOTATION_MARK:{this.state=State.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.currentAttr.value+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(cp)}}_stateAttributeValueSingleQuoted(cp){switch(cp){case CODE_POINTS.APOSTROPHE:{this.state=State.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.currentAttr.value+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(cp)}}_stateAttributeValueUnquoted(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this._leaveAttrValue(),this.state=State.BEFORE_ATTRIBUTE_NAME;break}case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.currentAttr.value+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.QUOTATION_MARK:case CODE_POINTS.APOSTROPHE:case CODE_POINTS.LESS_THAN_SIGN:case CODE_POINTS.EQUALS_SIGN:case CODE_POINTS.GRAVE_ACCENT:{this._err(ERR.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(cp);break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(cp)}}_stateAfterAttributeValueQuoted(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this._leaveAttrValue(),this.state=State.BEFORE_ATTRIBUTE_NAME;break}case CODE_POINTS.SOLIDUS:{this._leaveAttrValue(),this.state=State.SELF_CLOSING_START_TAG;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this._err(ERR.missingWhitespaceBetweenAttributes),this.state=State.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(cp)}}_stateSelfClosingStartTag(cp){switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{let token=this.currentToken;token.selfClosing=!0,this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this._err(ERR.unexpectedSolidusInTag),this.state=State.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(cp)}}_stateBogusComment(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentComment(token);break}case CODE_POINTS.EOF:{this.emitCurrentComment(token),this._emitEOFToken();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.data+=REPLACEMENT_CHARACTER;break}default:token.data+=String.fromCodePoint(cp)}}_stateMarkupDeclarationOpen(cp){this._consumeSequenceIfMatch(SEQUENCES.DASH_DASH,!0)?(this._createCommentToken(SEQUENCES.DASH_DASH.length+1),this.state=State.COMMENT_START):this._consumeSequenceIfMatch(SEQUENCES.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(SEQUENCES.DOCTYPE.length+1),this.state=State.DOCTYPE):this._consumeSequenceIfMatch(SEQUENCES.CDATA_START,!0)?this.inForeignNode?this.state=State.CDATA_SECTION:(this._err(ERR.cdataInHtmlContent),this._createCommentToken(SEQUENCES.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=State.BOGUS_COMMENT):this._ensureHibernation()||(this._err(ERR.incorrectlyOpenedComment),this._createCommentToken(2),this.state=State.BOGUS_COMMENT,this._stateBogusComment(cp))}_stateCommentStart(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.COMMENT_START_DASH;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptClosingOfEmptyComment),this.state=State.DATA;let token=this.currentToken;this.emitCurrentComment(token);break}default:this.state=State.COMMENT,this._stateComment(cp)}}_stateCommentStartDash(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.COMMENT_END;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptClosingOfEmptyComment),this.state=State.DATA,this.emitCurrentComment(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+="-",this.state=State.COMMENT,this._stateComment(cp)}}_stateComment(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.COMMENT_END_DASH;break}case CODE_POINTS.LESS_THAN_SIGN:{token.data+="<",this.state=State.COMMENT_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.data+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+=String.fromCodePoint(cp)}}_stateCommentLessThanSign(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.EXCLAMATION_MARK:{token.data+="!",this.state=State.COMMENT_LESS_THAN_SIGN_BANG;break}case CODE_POINTS.LESS_THAN_SIGN:{token.data+="<";break}default:this.state=State.COMMENT,this._stateComment(cp)}}_stateCommentLessThanSignBang(cp){cp===CODE_POINTS.HYPHEN_MINUS?this.state=State.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=State.COMMENT,this._stateComment(cp))}_stateCommentLessThanSignBangDash(cp){cp===CODE_POINTS.HYPHEN_MINUS?this.state=State.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=State.COMMENT_END_DASH,this._stateCommentEndDash(cp))}_stateCommentLessThanSignBangDashDash(cp){cp!==CODE_POINTS.GREATER_THAN_SIGN&&cp!==CODE_POINTS.EOF&&this._err(ERR.nestedComment),this.state=State.COMMENT_END,this._stateCommentEnd(cp)}_stateCommentEndDash(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.COMMENT_END;break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+="-",this.state=State.COMMENT,this._stateComment(cp)}}_stateCommentEnd(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentComment(token);break}case CODE_POINTS.EXCLAMATION_MARK:{this.state=State.COMMENT_END_BANG;break}case CODE_POINTS.HYPHEN_MINUS:{token.data+="-";break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+="--",this.state=State.COMMENT,this._stateComment(cp)}}_stateCommentEndBang(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.HYPHEN_MINUS:{token.data+="--!",this.state=State.COMMENT_END_DASH;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.incorrectlyClosedComment),this.state=State.DATA,this.emitCurrentComment(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+="--!",this.state=State.COMMENT,this._stateComment(cp)}}_stateDoctype(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BEFORE_DOCTYPE_NAME;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(cp);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),this._createDoctypeToken(null);let token=this.currentToken;token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingWhitespaceBeforeDoctypeName),this.state=State.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(cp)}}_stateBeforeDoctypeName(cp){if(isAsciiUpper(cp))this._createDoctypeToken(String.fromCharCode(toAsciiLower(cp))),this.state=State.DOCTYPE_NAME;else switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._createDoctypeToken(REPLACEMENT_CHARACTER),this.state=State.DOCTYPE_NAME;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypeName),this._createDoctypeToken(null);let token=this.currentToken;token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),this._createDoctypeToken(null);let token=this.currentToken;token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(cp)),this.state=State.DOCTYPE_NAME}}_stateDoctypeName(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.AFTER_DOCTYPE_NAME;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.name+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.name+=String.fromCodePoint(isAsciiUpper(cp)?toAsciiLower(cp):cp)}}_stateAfterDoctypeName(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(SEQUENCES.PUBLIC,!1)?this.state=State.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(SEQUENCES.SYSTEM,!1)?this.state=State.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(ERR.invalidCharacterSequenceAfterDoctypeName),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp))}}_stateAfterDoctypePublicKeyword(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case CODE_POINTS.QUOTATION_MARK:{this._err(ERR.missingWhitespaceAfterDoctypePublicKeyword),token.publicId="",this.state=State.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{this._err(ERR.missingWhitespaceAfterDoctypePublicKeyword),token.publicId="",this.state=State.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypePublicIdentifier),token.forceQuirks=!0,this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypePublicIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateBeforeDoctypePublicIdentifier(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.QUOTATION_MARK:{token.publicId="",this.state=State.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{token.publicId="",this.state=State.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypePublicIdentifier),token.forceQuirks=!0,this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypePublicIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateDoctypePublicIdentifierDoubleQuoted(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.QUOTATION_MARK:{this.state=State.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.publicId+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptDoctypePublicIdentifier),token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.publicId+=String.fromCodePoint(cp)}}_stateDoctypePublicIdentifierSingleQuoted(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.APOSTROPHE:{this.state=State.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.publicId+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptDoctypePublicIdentifier),token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.publicId+=String.fromCodePoint(cp)}}_stateAfterDoctypePublicIdentifier(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.QUOTATION_MARK:{this._err(ERR.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{this._err(ERR.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateBetweenDoctypePublicAndSystemIdentifiers(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.GREATER_THAN_SIGN:{this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.QUOTATION_MARK:{token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateAfterDoctypeSystemKeyword(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case CODE_POINTS.QUOTATION_MARK:{this._err(ERR.missingWhitespaceAfterDoctypeSystemKeyword),token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{this._err(ERR.missingWhitespaceAfterDoctypeSystemKeyword),token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateBeforeDoctypeSystemIdentifier(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.QUOTATION_MARK:{token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateDoctypeSystemIdentifierDoubleQuoted(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.QUOTATION_MARK:{this.state=State.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.systemId+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptDoctypeSystemIdentifier),token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.systemId+=String.fromCodePoint(cp)}}_stateDoctypeSystemIdentifierSingleQuoted(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.APOSTROPHE:{this.state=State.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.systemId+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptDoctypeSystemIdentifier),token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.systemId+=String.fromCodePoint(cp)}}_stateAfterDoctypeSystemIdentifier(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.GREATER_THAN_SIGN:{this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateBogusDoctype(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter);break}case CODE_POINTS.EOF:{this.emitCurrentDoctype(token),this._emitEOFToken();break}default:}}_stateCdataSection(cp){switch(cp){case CODE_POINTS.RIGHT_SQUARE_BRACKET:{this.state=State.CDATA_SECTION_BRACKET;break}case CODE_POINTS.EOF:{this._err(ERR.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateCdataSectionBracket(cp){cp===CODE_POINTS.RIGHT_SQUARE_BRACKET?this.state=State.CDATA_SECTION_END:(this._emitChars("]"),this.state=State.CDATA_SECTION,this._stateCdataSection(cp))}_stateCdataSectionEnd(cp){switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA;break}case CODE_POINTS.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=State.CDATA_SECTION,this._stateCdataSection(cp)}}_stateCharacterReference(){let length=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(length<0)if(this.preprocessor.lastChunkWritten)length=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}length===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(CODE_POINTS.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&isAsciiAlphaNumeric2(this.preprocessor.peek(1))?State.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(cp){isAsciiAlphaNumeric2(cp)?this._flushCodePointConsumedAsCharacterReference(cp):(cp===CODE_POINTS.SEMICOLON&&this._err(ERR.unknownNamedCharacterReference),this.state=this.returnState,this._callState(cp))}};init_browser_globals();var IMPLICIT_END_TAG_REQUIRED=new Set([TAG_ID.DD,TAG_ID.DT,TAG_ID.LI,TAG_ID.OPTGROUP,TAG_ID.OPTION,TAG_ID.P,TAG_ID.RB,TAG_ID.RP,TAG_ID.RT,TAG_ID.RTC]),IMPLICIT_END_TAG_REQUIRED_THOROUGHLY=new Set([...IMPLICIT_END_TAG_REQUIRED,TAG_ID.CAPTION,TAG_ID.COLGROUP,TAG_ID.TBODY,TAG_ID.TD,TAG_ID.TFOOT,TAG_ID.TH,TAG_ID.THEAD,TAG_ID.TR]),SCOPING_ELEMENTS_HTML=new Set([TAG_ID.APPLET,TAG_ID.CAPTION,TAG_ID.HTML,TAG_ID.MARQUEE,TAG_ID.OBJECT,TAG_ID.TABLE,TAG_ID.TD,TAG_ID.TEMPLATE,TAG_ID.TH]),SCOPING_ELEMENTS_HTML_LIST=new Set([...SCOPING_ELEMENTS_HTML,TAG_ID.OL,TAG_ID.UL]),SCOPING_ELEMENTS_HTML_BUTTON=new Set([...SCOPING_ELEMENTS_HTML,TAG_ID.BUTTON]),SCOPING_ELEMENTS_MATHML=new Set([TAG_ID.ANNOTATION_XML,TAG_ID.MI,TAG_ID.MN,TAG_ID.MO,TAG_ID.MS,TAG_ID.MTEXT]),SCOPING_ELEMENTS_SVG=new Set([TAG_ID.DESC,TAG_ID.FOREIGN_OBJECT,TAG_ID.TITLE]),TABLE_ROW_CONTEXT=new Set([TAG_ID.TR,TAG_ID.TEMPLATE,TAG_ID.HTML]),TABLE_BODY_CONTEXT=new Set([TAG_ID.TBODY,TAG_ID.TFOOT,TAG_ID.THEAD,TAG_ID.TEMPLATE,TAG_ID.HTML]),TABLE_CONTEXT=new Set([TAG_ID.TABLE,TAG_ID.TEMPLATE,TAG_ID.HTML]),TABLE_CELLS=new Set([TAG_ID.TD,TAG_ID.TH]),OpenElementStack=class{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(document5,treeAdapter,handler2){this.treeAdapter=treeAdapter,this.handler=handler2,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=TAG_ID.UNKNOWN,this.current=document5}_indexOf(element){return this.items.lastIndexOf(element,this.stackTop)}_isInTemplate(){return this.currentTagId===TAG_ID.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===NS.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(element,tagID){this.stackTop++,this.items[this.stackTop]=element,this.current=element,this.tagIDs[this.stackTop]=tagID,this.currentTagId=tagID,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(element,tagID,!0)}pop(){let popped=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(popped,!0)}replace(oldElement,newElement){let idx=this._indexOf(oldElement);this.items[idx]=newElement,idx===this.stackTop&&(this.current=newElement)}insertAfter(referenceElement,newElement,newElementID){let insertionIdx=this._indexOf(referenceElement)+1;this.items.splice(insertionIdx,0,newElement),this.tagIDs.splice(insertionIdx,0,newElementID),this.stackTop++,insertionIdx===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,insertionIdx===this.stackTop)}popUntilTagNamePopped(tagName){let targetIdx=this.stackTop+1;do targetIdx=this.tagIDs.lastIndexOf(tagName,targetIdx-1);while(targetIdx>0&&this.treeAdapter.getNamespaceURI(this.items[targetIdx])!==NS.HTML);this.shortenToLength(Math.max(targetIdx,0))}shortenToLength(idx){for(;this.stackTop>=idx;){let popped=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(popped,this.stackTop<idx)}}popUntilElementPopped(element){let idx=this._indexOf(element);this.shortenToLength(Math.max(idx,0))}popUntilPopped(tagNames,targetNS){let idx=this._indexOfTagNames(tagNames,targetNS);this.shortenToLength(Math.max(idx,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(NUMBERED_HEADERS,NS.HTML)}popUntilTableCellPopped(){this.popUntilPopped(TABLE_CELLS,NS.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(tagNames,namespace){for(let i2=this.stackTop;i2>=0;i2--)if(tagNames.has(this.tagIDs[i2])&&this.treeAdapter.getNamespaceURI(this.items[i2])===namespace)return i2;return-1}clearBackTo(tagNames,targetNS){let idx=this._indexOfTagNames(tagNames,targetNS);this.shortenToLength(idx+1)}clearBackToTableContext(){this.clearBackTo(TABLE_CONTEXT,NS.HTML)}clearBackToTableBodyContext(){this.clearBackTo(TABLE_BODY_CONTEXT,NS.HTML)}clearBackToTableRowContext(){this.clearBackTo(TABLE_ROW_CONTEXT,NS.HTML)}remove(element){let idx=this._indexOf(element);idx>=0&&(idx===this.stackTop?this.pop():(this.items.splice(idx,1),this.tagIDs.splice(idx,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(element,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===TAG_ID.BODY?this.items[1]:null}contains(element){return this._indexOf(element)>-1}getCommonAncestor(element){let elementIdx=this._indexOf(element)-1;return elementIdx>=0?this.items[elementIdx]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===TAG_ID.HTML}hasInDynamicScope(tagName,htmlScope){for(let i2=this.stackTop;i2>=0;i2--){let tn2=this.tagIDs[i2];switch(this.treeAdapter.getNamespaceURI(this.items[i2])){case NS.HTML:{if(tn2===tagName)return!0;if(htmlScope.has(tn2))return!1;break}case NS.SVG:{if(SCOPING_ELEMENTS_SVG.has(tn2))return!1;break}case NS.MATHML:{if(SCOPING_ELEMENTS_MATHML.has(tn2))return!1;break}}}return!0}hasInScope(tagName){return this.hasInDynamicScope(tagName,SCOPING_ELEMENTS_HTML)}hasInListItemScope(tagName){return this.hasInDynamicScope(tagName,SCOPING_ELEMENTS_HTML_LIST)}hasInButtonScope(tagName){return this.hasInDynamicScope(tagName,SCOPING_ELEMENTS_HTML_BUTTON)}hasNumberedHeaderInScope(){for(let i2=this.stackTop;i2>=0;i2--){let tn2=this.tagIDs[i2];switch(this.treeAdapter.getNamespaceURI(this.items[i2])){case NS.HTML:{if(NUMBERED_HEADERS.has(tn2))return!0;if(SCOPING_ELEMENTS_HTML.has(tn2))return!1;break}case NS.SVG:{if(SCOPING_ELEMENTS_SVG.has(tn2))return!1;break}case NS.MATHML:{if(SCOPING_ELEMENTS_MATHML.has(tn2))return!1;break}}}return!0}hasInTableScope(tagName){for(let i2=this.stackTop;i2>=0;i2--)if(this.treeAdapter.getNamespaceURI(this.items[i2])===NS.HTML)switch(this.tagIDs[i2]){case tagName:return!0;case TAG_ID.TABLE:case TAG_ID.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let i2=this.stackTop;i2>=0;i2--)if(this.treeAdapter.getNamespaceURI(this.items[i2])===NS.HTML)switch(this.tagIDs[i2]){case TAG_ID.TBODY:case TAG_ID.THEAD:case TAG_ID.TFOOT:return!0;case TAG_ID.TABLE:case TAG_ID.HTML:return!1}return!0}hasInSelectScope(tagName){for(let i2=this.stackTop;i2>=0;i2--)if(this.treeAdapter.getNamespaceURI(this.items[i2])===NS.HTML)switch(this.tagIDs[i2]){case tagName:return!0;case TAG_ID.OPTION:case TAG_ID.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&IMPLICIT_END_TAG_REQUIRED.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&IMPLICIT_END_TAG_REQUIRED_THOROUGHLY.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(exclusionId){for(;this.currentTagId!==void 0&&this.currentTagId!==exclusionId&&IMPLICIT_END_TAG_REQUIRED_THOROUGHLY.has(this.currentTagId);)this.pop()}};init_browser_globals();var EntryType;(function(EntryType2){EntryType2[EntryType2.Marker=0]="Marker",EntryType2[EntryType2.Element=1]="Element"})(EntryType||(EntryType={}));var MARKER={type:EntryType.Marker},FormattingElementList=class{constructor(treeAdapter){this.treeAdapter=treeAdapter,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(newElement,neAttrs){let candidates2=[],neAttrsLength=neAttrs.length,neTagName=this.treeAdapter.getTagName(newElement),neNamespaceURI=this.treeAdapter.getNamespaceURI(newElement);for(let i2=0;i2<this.entries.length;i2++){let entry=this.entries[i2];if(entry.type===EntryType.Marker)break;let{element}=entry;if(this.treeAdapter.getTagName(element)===neTagName&&this.treeAdapter.getNamespaceURI(element)===neNamespaceURI){let elementAttrs=this.treeAdapter.getAttrList(element);elementAttrs.length===neAttrsLength&&candidates2.push({idx:i2,attrs:elementAttrs})}}return candidates2}_ensureNoahArkCondition(newElement){if(this.entries.length<3)return;let neAttrs=this.treeAdapter.getAttrList(newElement),candidates2=this._getNoahArkConditionCandidates(newElement,neAttrs);if(candidates2.length<3)return;let neAttrsMap=new Map(neAttrs.map(neAttr=>[neAttr.name,neAttr.value])),validCandidates=0;for(let i2=0;i2<candidates2.length;i2++){let candidate=candidates2[i2];candidate.attrs.every(cAttr=>neAttrsMap.get(cAttr.name)===cAttr.value)&&(validCandidates+=1,validCandidates>=3&&this.entries.splice(candidate.idx,1))}}insertMarker(){this.entries.unshift(MARKER)}pushElement(element,token){this._ensureNoahArkCondition(element),this.entries.unshift({type:EntryType.Element,element,token})}insertElementAfterBookmark(element,token){let bookmarkIdx=this.entries.indexOf(this.bookmark);this.entries.splice(bookmarkIdx,0,{type:EntryType.Element,element,token})}removeEntry(entry){let entryIndex=this.entries.indexOf(entry);entryIndex!==-1&&this.entries.splice(entryIndex,1)}clearToLastMarker(){let markerIdx=this.entries.indexOf(MARKER);markerIdx===-1?this.entries.length=0:this.entries.splice(0,markerIdx+1)}getElementEntryInScopeWithTagName(tagName){let entry=this.entries.find(entry2=>entry2.type===EntryType.Marker||this.treeAdapter.getTagName(entry2.element)===tagName);return entry&&entry.type===EntryType.Element?entry:null}getElementEntry(element){return this.entries.find(entry=>entry.type===EntryType.Element&&entry.element===element)}};init_browser_globals();var defaultTreeAdapter={createDocument(){return{nodeName:"#document",mode:DOCUMENT_MODE.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(tagName,namespaceURI,attrs){return{nodeName:tagName,tagName,attrs,namespaceURI,childNodes:[],parentNode:null}},createCommentNode(data){return{nodeName:"#comment",data,parentNode:null}},createTextNode(value2){return{nodeName:"#text",value:value2,parentNode:null}},appendChild(parentNode,newNode){parentNode.childNodes.push(newNode),newNode.parentNode=parentNode},insertBefore(parentNode,newNode,referenceNode){let insertionIdx=parentNode.childNodes.indexOf(referenceNode);parentNode.childNodes.splice(insertionIdx,0,newNode),newNode.parentNode=parentNode},setTemplateContent(templateElement,contentElement){templateElement.content=contentElement},getTemplateContent(templateElement){return templateElement.content},setDocumentType(document5,name,publicId,systemId){let doctypeNode=document5.childNodes.find(node2=>node2.nodeName==="#documentType");if(doctypeNode)doctypeNode.name=name,doctypeNode.publicId=publicId,doctypeNode.systemId=systemId;else{let node2={nodeName:"#documentType",name,publicId,systemId,parentNode:null};defaultTreeAdapter.appendChild(document5,node2)}},setDocumentMode(document5,mode){document5.mode=mode},getDocumentMode(document5){return document5.mode},detachNode(node2){if(node2.parentNode){let idx=node2.parentNode.childNodes.indexOf(node2);node2.parentNode.childNodes.splice(idx,1),node2.parentNode=null}},insertText(parentNode,text5){if(parentNode.childNodes.length>0){let prevNode=parentNode.childNodes[parentNode.childNodes.length-1];if(defaultTreeAdapter.isTextNode(prevNode)){prevNode.value+=text5;return}}defaultTreeAdapter.appendChild(parentNode,defaultTreeAdapter.createTextNode(text5))},insertTextBefore(parentNode,text5,referenceNode){let prevNode=parentNode.childNodes[parentNode.childNodes.indexOf(referenceNode)-1];prevNode&&defaultTreeAdapter.isTextNode(prevNode)?prevNode.value+=text5:defaultTreeAdapter.insertBefore(parentNode,defaultTreeAdapter.createTextNode(text5),referenceNode)},adoptAttributes(recipient,attrs){let recipientAttrsMap=new Set(recipient.attrs.map(attr=>attr.name));for(let j=0;j<attrs.length;j++)recipientAttrsMap.has(attrs[j].name)||recipient.attrs.push(attrs[j])},getFirstChild(node2){return node2.childNodes[0]},getChildNodes(node2){return node2.childNodes},getParentNode(node2){return node2.parentNode},getAttrList(element){return element.attrs},getTagName(element){return element.tagName},getNamespaceURI(element){return element.namespaceURI},getTextNodeContent(textNode){return textNode.value},getCommentNodeContent(commentNode){return commentNode.data},getDocumentTypeNodeName(doctypeNode){return doctypeNode.name},getDocumentTypeNodePublicId(doctypeNode){return doctypeNode.publicId},getDocumentTypeNodeSystemId(doctypeNode){return doctypeNode.systemId},isTextNode(node2){return node2.nodeName==="#text"},isCommentNode(node2){return node2.nodeName==="#comment"},isDocumentTypeNode(node2){return node2.nodeName==="#documentType"},isElementNode(node2){return Object.prototype.hasOwnProperty.call(node2,"tagName")},setNodeSourceCodeLocation(node2,location2){node2.sourceCodeLocation=location2},getNodeSourceCodeLocation(node2){return node2.sourceCodeLocation},updateNodeSourceCodeLocation(node2,endLocation){node2.sourceCodeLocation={...node2.sourceCodeLocation,...endLocation}}};init_browser_globals();var VALID_DOCTYPE_NAME="html",VALID_SYSTEM_ID="about:legacy-compat",QUIRKS_MODE_SYSTEM_ID="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",QUIRKS_MODE_PUBLIC_ID_PREFIXES=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],QUIRKS_MODE_NO_SYSTEM_ID_PUBLIC_ID_PREFIXES=[...QUIRKS_MODE_PUBLIC_ID_PREFIXES,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],QUIRKS_MODE_PUBLIC_IDS=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),LIMITED_QUIRKS_PUBLIC_ID_PREFIXES=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],LIMITED_QUIRKS_WITH_SYSTEM_ID_PUBLIC_ID_PREFIXES=[...LIMITED_QUIRKS_PUBLIC_ID_PREFIXES,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function hasPrefix(publicId,prefixes){return prefixes.some(prefix=>publicId.startsWith(prefix))}function isConforming(token){return token.name===VALID_DOCTYPE_NAME&&token.publicId===null&&(token.systemId===null||token.systemId===VALID_SYSTEM_ID)}function getDocumentMode(token){if(token.name!==VALID_DOCTYPE_NAME)return DOCUMENT_MODE.QUIRKS;let{systemId}=token;if(systemId&&systemId.toLowerCase()===QUIRKS_MODE_SYSTEM_ID)return DOCUMENT_MODE.QUIRKS;let{publicId}=token;if(publicId!==null){if(publicId=publicId.toLowerCase(),QUIRKS_MODE_PUBLIC_IDS.has(publicId))return DOCUMENT_MODE.QUIRKS;let prefixes=systemId===null?QUIRKS_MODE_NO_SYSTEM_ID_PUBLIC_ID_PREFIXES:QUIRKS_MODE_PUBLIC_ID_PREFIXES;if(hasPrefix(publicId,prefixes))return DOCUMENT_MODE.QUIRKS;if(prefixes=systemId===null?LIMITED_QUIRKS_PUBLIC_ID_PREFIXES:LIMITED_QUIRKS_WITH_SYSTEM_ID_PUBLIC_ID_PREFIXES,hasPrefix(publicId,prefixes))return DOCUMENT_MODE.LIMITED_QUIRKS}return DOCUMENT_MODE.NO_QUIRKS}init_browser_globals();var MIME_TYPES={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},DEFINITION_URL_ATTR="definitionurl",ADJUSTED_DEFINITION_URL_ATTR="definitionURL",SVG_ATTRS_ADJUSTMENT_MAP=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(attr=>[attr.toLowerCase(),attr])),XML_ATTRS_ADJUSTMENT_MAP=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:NS.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:NS.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:NS.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:NS.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:NS.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:NS.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:NS.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:NS.XML}],["xml:space",{prefix:"xml",name:"space",namespace:NS.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:NS.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:NS.XMLNS}]]),SVG_TAG_NAMES_ADJUSTMENT_MAP=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(tn2=>[tn2.toLowerCase(),tn2])),EXITS_FOREIGN_CONTENT=new Set([TAG_ID.B,TAG_ID.BIG,TAG_ID.BLOCKQUOTE,TAG_ID.BODY,TAG_ID.BR,TAG_ID.CENTER,TAG_ID.CODE,TAG_ID.DD,TAG_ID.DIV,TAG_ID.DL,TAG_ID.DT,TAG_ID.EM,TAG_ID.EMBED,TAG_ID.H1,TAG_ID.H2,TAG_ID.H3,TAG_ID.H4,TAG_ID.H5,TAG_ID.H6,TAG_ID.HEAD,TAG_ID.HR,TAG_ID.I,TAG_ID.IMG,TAG_ID.LI,TAG_ID.LISTING,TAG_ID.MENU,TAG_ID.META,TAG_ID.NOBR,TAG_ID.OL,TAG_ID.P,TAG_ID.PRE,TAG_ID.RUBY,TAG_ID.S,TAG_ID.SMALL,TAG_ID.SPAN,TAG_ID.STRONG,TAG_ID.STRIKE,TAG_ID.SUB,TAG_ID.SUP,TAG_ID.TABLE,TAG_ID.TT,TAG_ID.U,TAG_ID.UL,TAG_ID.VAR]);function causesExit(startTagToken){let tn2=startTagToken.tagID;return tn2===TAG_ID.FONT&&startTagToken.attrs.some(({name})=>name===ATTRS.COLOR||name===ATTRS.SIZE||name===ATTRS.FACE)||EXITS_FOREIGN_CONTENT.has(tn2)}function adjustTokenMathMLAttrs(token){for(let i2=0;i2<token.attrs.length;i2++)if(token.attrs[i2].name===DEFINITION_URL_ATTR){token.attrs[i2].name=ADJUSTED_DEFINITION_URL_ATTR;break}}function adjustTokenSVGAttrs(token){for(let i2=0;i2<token.attrs.length;i2++){let adjustedAttrName=SVG_ATTRS_ADJUSTMENT_MAP.get(token.attrs[i2].name);adjustedAttrName!=null&&(token.attrs[i2].name=adjustedAttrName)}}function adjustTokenXMLAttrs(token){for(let i2=0;i2<token.attrs.length;i2++){let adjustedAttrEntry=XML_ATTRS_ADJUSTMENT_MAP.get(token.attrs[i2].name);adjustedAttrEntry&&(token.attrs[i2].prefix=adjustedAttrEntry.prefix,token.attrs[i2].name=adjustedAttrEntry.name,token.attrs[i2].namespace=adjustedAttrEntry.namespace)}}function adjustTokenSVGTagName(token){let adjustedTagName=SVG_TAG_NAMES_ADJUSTMENT_MAP.get(token.tagName);adjustedTagName!=null&&(token.tagName=adjustedTagName,token.tagID=getTagID(token.tagName))}function isMathMLTextIntegrationPoint(tn2,ns){return ns===NS.MATHML&&(tn2===TAG_ID.MI||tn2===TAG_ID.MO||tn2===TAG_ID.MN||tn2===TAG_ID.MS||tn2===TAG_ID.MTEXT)}function isHtmlIntegrationPoint(tn2,ns,attrs){if(ns===NS.MATHML&&tn2===TAG_ID.ANNOTATION_XML){for(let i2=0;i2<attrs.length;i2++)if(attrs[i2].name===ATTRS.ENCODING){let value2=attrs[i2].value.toLowerCase();return value2===MIME_TYPES.TEXT_HTML||value2===MIME_TYPES.APPLICATION_XML}}return ns===NS.SVG&&(tn2===TAG_ID.FOREIGN_OBJECT||tn2===TAG_ID.DESC||tn2===TAG_ID.TITLE)}function isIntegrationPoint(tn2,ns,attrs,foreignNS){return(!foreignNS||foreignNS===NS.HTML)&&isHtmlIntegrationPoint(tn2,ns,attrs)||(!foreignNS||foreignNS===NS.MATHML)&&isMathMLTextIntegrationPoint(tn2,ns)}var HIDDEN_INPUT_TYPE="hidden",AA_OUTER_LOOP_ITER=8,AA_INNER_LOOP_ITER=3,InsertionMode;(function(InsertionMode2){InsertionMode2[InsertionMode2.INITIAL=0]="INITIAL",InsertionMode2[InsertionMode2.BEFORE_HTML=1]="BEFORE_HTML",InsertionMode2[InsertionMode2.BEFORE_HEAD=2]="BEFORE_HEAD",InsertionMode2[InsertionMode2.IN_HEAD=3]="IN_HEAD",InsertionMode2[InsertionMode2.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",InsertionMode2[InsertionMode2.AFTER_HEAD=5]="AFTER_HEAD",InsertionMode2[InsertionMode2.IN_BODY=6]="IN_BODY",InsertionMode2[InsertionMode2.TEXT=7]="TEXT",InsertionMode2[InsertionMode2.IN_TABLE=8]="IN_TABLE",InsertionMode2[InsertionMode2.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",InsertionMode2[InsertionMode2.IN_CAPTION=10]="IN_CAPTION",InsertionMode2[InsertionMode2.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",InsertionMode2[InsertionMode2.IN_TABLE_BODY=12]="IN_TABLE_BODY",InsertionMode2[InsertionMode2.IN_ROW=13]="IN_ROW",InsertionMode2[InsertionMode2.IN_CELL=14]="IN_CELL",InsertionMode2[InsertionMode2.IN_SELECT=15]="IN_SELECT",InsertionMode2[InsertionMode2.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",InsertionMode2[InsertionMode2.IN_TEMPLATE=17]="IN_TEMPLATE",InsertionMode2[InsertionMode2.AFTER_BODY=18]="AFTER_BODY",InsertionMode2[InsertionMode2.IN_FRAMESET=19]="IN_FRAMESET",InsertionMode2[InsertionMode2.AFTER_FRAMESET=20]="AFTER_FRAMESET",InsertionMode2[InsertionMode2.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",InsertionMode2[InsertionMode2.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(InsertionMode||(InsertionMode={}));var BASE_LOC={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},TABLE_STRUCTURE_TAGS=new Set([TAG_ID.TABLE,TAG_ID.TBODY,TAG_ID.TFOOT,TAG_ID.THEAD,TAG_ID.TR]),defaultParserOptions={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:defaultTreeAdapter,onParseError:null},Parser2=class{constructor(options2,document5,fragmentContext=null,scriptHandler=null){this.fragmentContext=fragmentContext,this.scriptHandler=scriptHandler,this.currentToken=null,this.stopped=!1,this.insertionMode=InsertionMode.INITIAL,this.originalInsertionMode=InsertionMode.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={...defaultParserOptions,...options2},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=document5??this.treeAdapter.createDocument(),this.tokenizer=new Tokenizer(this.options,this),this.activeFormattingElements=new FormattingElementList(this.treeAdapter),this.fragmentContextID=fragmentContext?getTagID(this.treeAdapter.getTagName(fragmentContext)):TAG_ID.UNKNOWN,this._setContextModes(fragmentContext??this.document,this.fragmentContextID),this.openElements=new OpenElementStack(this.document,this.treeAdapter,this)}static parse(html2,options2){let parser=new this(options2);return parser.tokenizer.write(html2,!0),parser.document}static getFragmentParser(fragmentContext,options2){let opts={...defaultParserOptions,...options2};fragmentContext??(fragmentContext=opts.treeAdapter.createElement(TAG_NAMES.TEMPLATE,NS.HTML,[]));let documentMock=opts.treeAdapter.createElement("documentmock",NS.HTML,[]),parser=new this(opts,documentMock,fragmentContext);return parser.fragmentContextID===TAG_ID.TEMPLATE&&parser.tmplInsertionModeStack.unshift(InsertionMode.IN_TEMPLATE),parser._initTokenizerForFragmentParsing(),parser._insertFakeRootElement(),parser._resetInsertionMode(),parser._findFormInFragmentContext(),parser}getFragment(){let rootElement=this.treeAdapter.getFirstChild(this.document),fragment=this.treeAdapter.createDocumentFragment();return this._adoptNodes(rootElement,fragment),fragment}_err(token,code4,beforeToken){var _a2;if(!this.onParseError)return;let loc=(_a2=token.location)!==null&&_a2!==void 0?_a2:BASE_LOC,err={code:code4,startLine:loc.startLine,startCol:loc.startCol,startOffset:loc.startOffset,endLine:beforeToken?loc.startLine:loc.endLine,endCol:beforeToken?loc.startCol:loc.endCol,endOffset:beforeToken?loc.startOffset:loc.endOffset};this.onParseError(err)}onItemPush(node2,tid,isTop){var _a2,_b;(_b=(_a2=this.treeAdapter).onItemPush)===null||_b===void 0||_b.call(_a2,node2),isTop&&this.openElements.stackTop>0&&this._setContextModes(node2,tid)}onItemPop(node2,isTop){var _a2,_b;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(node2,this.currentToken),(_b=(_a2=this.treeAdapter).onItemPop)===null||_b===void 0||_b.call(_a2,node2,this.openElements.current),isTop){let current,currentTagId;this.openElements.stackTop===0&&this.fragmentContext?(current=this.fragmentContext,currentTagId=this.fragmentContextID):{current,currentTagId}=this.openElements,this._setContextModes(current,currentTagId)}}_setContextModes(current,tid){let isHTML=current===this.document||current&&this.treeAdapter.getNamespaceURI(current)===NS.HTML;this.currentNotInHTML=!isHTML,this.tokenizer.inForeignNode=!isHTML&¤t!==void 0&&tid!==void 0&&!this._isIntegrationPoint(tid,current)}_switchToTextParsing(currentToken,nextTokenizerState){this._insertElement(currentToken,NS.HTML),this.tokenizer.state=nextTokenizerState,this.originalInsertionMode=this.insertionMode,this.insertionMode=InsertionMode.TEXT}switchToPlaintextParsing(){this.insertionMode=InsertionMode.TEXT,this.originalInsertionMode=InsertionMode.IN_BODY,this.tokenizer.state=TokenizerMode.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let node2=this.fragmentContext;for(;node2;){if(this.treeAdapter.getTagName(node2)===TAG_NAMES.FORM){this.formElement=node2;break}node2=this.treeAdapter.getParentNode(node2)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==NS.HTML))switch(this.fragmentContextID){case TAG_ID.TITLE:case TAG_ID.TEXTAREA:{this.tokenizer.state=TokenizerMode.RCDATA;break}case TAG_ID.STYLE:case TAG_ID.XMP:case TAG_ID.IFRAME:case TAG_ID.NOEMBED:case TAG_ID.NOFRAMES:case TAG_ID.NOSCRIPT:{this.tokenizer.state=TokenizerMode.RAWTEXT;break}case TAG_ID.SCRIPT:{this.tokenizer.state=TokenizerMode.SCRIPT_DATA;break}case TAG_ID.PLAINTEXT:{this.tokenizer.state=TokenizerMode.PLAINTEXT;break}default:}}_setDocumentType(token){let name=token.name||"",publicId=token.publicId||"",systemId=token.systemId||"";if(this.treeAdapter.setDocumentType(this.document,name,publicId,systemId),token.location){let docTypeNode=this.treeAdapter.getChildNodes(this.document).find(node2=>this.treeAdapter.isDocumentTypeNode(node2));docTypeNode&&this.treeAdapter.setNodeSourceCodeLocation(docTypeNode,token.location)}}_attachElementToTree(element,location2){if(this.options.sourceCodeLocationInfo){let loc=location2&&{...location2,startTag:location2};this.treeAdapter.setNodeSourceCodeLocation(element,loc)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(element);else{let parent=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(parent??this.document,element)}}_appendElement(token,namespaceURI){let element=this.treeAdapter.createElement(token.tagName,namespaceURI,token.attrs);this._attachElementToTree(element,token.location)}_insertElement(token,namespaceURI){let element=this.treeAdapter.createElement(token.tagName,namespaceURI,token.attrs);this._attachElementToTree(element,token.location),this.openElements.push(element,token.tagID)}_insertFakeElement(tagName,tagID){let element=this.treeAdapter.createElement(tagName,NS.HTML,[]);this._attachElementToTree(element,null),this.openElements.push(element,tagID)}_insertTemplate(token){let tmpl=this.treeAdapter.createElement(token.tagName,NS.HTML,token.attrs),content3=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(tmpl,content3),this._attachElementToTree(tmpl,token.location),this.openElements.push(tmpl,token.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(content3,null)}_insertFakeRootElement(){let element=this.treeAdapter.createElement(TAG_NAMES.HTML,NS.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(element,null),this.treeAdapter.appendChild(this.openElements.current,element),this.openElements.push(element,TAG_ID.HTML)}_appendCommentNode(token,parent){let commentNode=this.treeAdapter.createCommentNode(token.data);this.treeAdapter.appendChild(parent,commentNode),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(commentNode,token.location)}_insertCharacters(token){let parent,beforeElement;if(this._shouldFosterParentOnInsertion()?({parent,beforeElement}=this._findFosterParentingLocation(),beforeElement?this.treeAdapter.insertTextBefore(parent,token.chars,beforeElement):this.treeAdapter.insertText(parent,token.chars)):(parent=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(parent,token.chars)),!token.location)return;let siblings=this.treeAdapter.getChildNodes(parent),textNodeIdx=beforeElement?siblings.lastIndexOf(beforeElement):siblings.length,textNode=siblings[textNodeIdx-1];if(this.treeAdapter.getNodeSourceCodeLocation(textNode)){let{endLine,endCol,endOffset}=token.location;this.treeAdapter.updateNodeSourceCodeLocation(textNode,{endLine,endCol,endOffset})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(textNode,token.location)}_adoptNodes(donor,recipient){for(let child=this.treeAdapter.getFirstChild(donor);child;child=this.treeAdapter.getFirstChild(donor))this.treeAdapter.detachNode(child),this.treeAdapter.appendChild(recipient,child)}_setEndLocation(element,closingToken){if(this.treeAdapter.getNodeSourceCodeLocation(element)&&closingToken.location){let ctLoc=closingToken.location,tn2=this.treeAdapter.getTagName(element),endLoc=closingToken.type===TokenType.END_TAG&&tn2===closingToken.tagName?{endTag:{...ctLoc},endLine:ctLoc.endLine,endCol:ctLoc.endCol,endOffset:ctLoc.endOffset}:{endLine:ctLoc.startLine,endCol:ctLoc.startCol,endOffset:ctLoc.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(element,endLoc)}}shouldProcessStartTagTokenInForeignContent(token){if(!this.currentNotInHTML)return!1;let current,currentTagId;return this.openElements.stackTop===0&&this.fragmentContext?(current=this.fragmentContext,currentTagId=this.fragmentContextID):{current,currentTagId}=this.openElements,token.tagID===TAG_ID.SVG&&this.treeAdapter.getTagName(current)===TAG_NAMES.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(current)===NS.MATHML?!1:this.tokenizer.inForeignNode||(token.tagID===TAG_ID.MGLYPH||token.tagID===TAG_ID.MALIGNMARK)&¤tTagId!==void 0&&!this._isIntegrationPoint(currentTagId,current,NS.HTML)}_processToken(token){switch(token.type){case TokenType.CHARACTER:{this.onCharacter(token);break}case TokenType.NULL_CHARACTER:{this.onNullCharacter(token);break}case TokenType.COMMENT:{this.onComment(token);break}case TokenType.DOCTYPE:{this.onDoctype(token);break}case TokenType.START_TAG:{this._processStartTag(token);break}case TokenType.END_TAG:{this.onEndTag(token);break}case TokenType.EOF:{this.onEof(token);break}case TokenType.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(token);break}}}_isIntegrationPoint(tid,element,foreignNS){let ns=this.treeAdapter.getNamespaceURI(element),attrs=this.treeAdapter.getAttrList(element);return isIntegrationPoint(tid,ns,attrs,foreignNS)}_reconstructActiveFormattingElements(){let listLength=this.activeFormattingElements.entries.length;if(listLength){let endIndex=this.activeFormattingElements.entries.findIndex(entry=>entry.type===EntryType.Marker||this.openElements.contains(entry.element)),unopenIdx=endIndex===-1?listLength-1:endIndex-1;for(let i2=unopenIdx;i2>=0;i2--){let entry=this.activeFormattingElements.entries[i2];this._insertElement(entry.token,this.treeAdapter.getNamespaceURI(entry.element)),entry.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=InsertionMode.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(TAG_ID.P),this.openElements.popUntilTagNamePopped(TAG_ID.P)}_resetInsertionMode(){for(let i2=this.openElements.stackTop;i2>=0;i2--)switch(i2===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[i2]){case TAG_ID.TR:{this.insertionMode=InsertionMode.IN_ROW;return}case TAG_ID.TBODY:case TAG_ID.THEAD:case TAG_ID.TFOOT:{this.insertionMode=InsertionMode.IN_TABLE_BODY;return}case TAG_ID.CAPTION:{this.insertionMode=InsertionMode.IN_CAPTION;return}case TAG_ID.COLGROUP:{this.insertionMode=InsertionMode.IN_COLUMN_GROUP;return}case TAG_ID.TABLE:{this.insertionMode=InsertionMode.IN_TABLE;return}case TAG_ID.BODY:{this.insertionMode=InsertionMode.IN_BODY;return}case TAG_ID.FRAMESET:{this.insertionMode=InsertionMode.IN_FRAMESET;return}case TAG_ID.SELECT:{this._resetInsertionModeForSelect(i2);return}case TAG_ID.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case TAG_ID.HTML:{this.insertionMode=this.headElement?InsertionMode.AFTER_HEAD:InsertionMode.BEFORE_HEAD;return}case TAG_ID.TD:case TAG_ID.TH:{if(i2>0){this.insertionMode=InsertionMode.IN_CELL;return}break}case TAG_ID.HEAD:{if(i2>0){this.insertionMode=InsertionMode.IN_HEAD;return}break}}this.insertionMode=InsertionMode.IN_BODY}_resetInsertionModeForSelect(selectIdx){if(selectIdx>0)for(let i2=selectIdx-1;i2>0;i2--){let tn2=this.openElements.tagIDs[i2];if(tn2===TAG_ID.TEMPLATE)break;if(tn2===TAG_ID.TABLE){this.insertionMode=InsertionMode.IN_SELECT_IN_TABLE;return}}this.insertionMode=InsertionMode.IN_SELECT}_isElementCausesFosterParenting(tn2){return TABLE_STRUCTURE_TAGS.has(tn2)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let i2=this.openElements.stackTop;i2>=0;i2--){let openElement=this.openElements.items[i2];switch(this.openElements.tagIDs[i2]){case TAG_ID.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(openElement)===NS.HTML)return{parent:this.treeAdapter.getTemplateContent(openElement),beforeElement:null};break}case TAG_ID.TABLE:{let parent=this.treeAdapter.getParentNode(openElement);return parent?{parent,beforeElement:openElement}:{parent:this.openElements.items[i2-1],beforeElement:null}}default:}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(element){let location2=this._findFosterParentingLocation();location2.beforeElement?this.treeAdapter.insertBefore(location2.parent,element,location2.beforeElement):this.treeAdapter.appendChild(location2.parent,element)}_isSpecialElement(element,id){let ns=this.treeAdapter.getNamespaceURI(element);return SPECIAL_ELEMENTS[ns].has(id)}onCharacter(token){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){characterInForeignContent(this,token);return}switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{tokenBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{tokenBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{tokenInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{tokenInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{tokenAfterHead(this,token);break}case InsertionMode.IN_BODY:case InsertionMode.IN_CAPTION:case InsertionMode.IN_CELL:case InsertionMode.IN_TEMPLATE:{characterInBody(this,token);break}case InsertionMode.TEXT:case InsertionMode.IN_SELECT:case InsertionMode.IN_SELECT_IN_TABLE:{this._insertCharacters(token);break}case InsertionMode.IN_TABLE:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:{characterInTable(this,token);break}case InsertionMode.IN_TABLE_TEXT:{characterInTableText(this,token);break}case InsertionMode.IN_COLUMN_GROUP:{tokenInColumnGroup(this,token);break}case InsertionMode.AFTER_BODY:{tokenAfterBody(this,token);break}case InsertionMode.AFTER_AFTER_BODY:{tokenAfterAfterBody(this,token);break}default:}}onNullCharacter(token){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){nullCharacterInForeignContent(this,token);return}switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{tokenBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{tokenBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{tokenInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{tokenInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{tokenAfterHead(this,token);break}case InsertionMode.TEXT:{this._insertCharacters(token);break}case InsertionMode.IN_TABLE:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:{characterInTable(this,token);break}case InsertionMode.IN_COLUMN_GROUP:{tokenInColumnGroup(this,token);break}case InsertionMode.AFTER_BODY:{tokenAfterBody(this,token);break}case InsertionMode.AFTER_AFTER_BODY:{tokenAfterAfterBody(this,token);break}default:}}onComment(token){if(this.skipNextNewLine=!1,this.currentNotInHTML){appendComment(this,token);return}switch(this.insertionMode){case InsertionMode.INITIAL:case InsertionMode.BEFORE_HTML:case InsertionMode.BEFORE_HEAD:case InsertionMode.IN_HEAD:case InsertionMode.IN_HEAD_NO_SCRIPT:case InsertionMode.AFTER_HEAD:case InsertionMode.IN_BODY:case InsertionMode.IN_TABLE:case InsertionMode.IN_CAPTION:case InsertionMode.IN_COLUMN_GROUP:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:case InsertionMode.IN_CELL:case InsertionMode.IN_SELECT:case InsertionMode.IN_SELECT_IN_TABLE:case InsertionMode.IN_TEMPLATE:case InsertionMode.IN_FRAMESET:case InsertionMode.AFTER_FRAMESET:{appendComment(this,token);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}case InsertionMode.AFTER_BODY:{appendCommentToRootHtmlElement(this,token);break}case InsertionMode.AFTER_AFTER_BODY:case InsertionMode.AFTER_AFTER_FRAMESET:{appendCommentToDocument(this,token);break}default:}}onDoctype(token){switch(this.skipNextNewLine=!1,this.insertionMode){case InsertionMode.INITIAL:{doctypeInInitialMode(this,token);break}case InsertionMode.BEFORE_HEAD:case InsertionMode.IN_HEAD:case InsertionMode.IN_HEAD_NO_SCRIPT:case InsertionMode.AFTER_HEAD:{this._err(token,ERR.misplacedDoctype);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}default:}}onStartTag(token){this.skipNextNewLine=!1,this.currentToken=token,this._processStartTag(token),token.selfClosing&&!token.ackSelfClosing&&this._err(token,ERR.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(token){this.shouldProcessStartTagTokenInForeignContent(token)?startTagInForeignContent(this,token):this._startTagOutsideForeignContent(token)}_startTagOutsideForeignContent(token){switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{startTagBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{startTagBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{startTagInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{startTagInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{startTagAfterHead(this,token);break}case InsertionMode.IN_BODY:{startTagInBody(this,token);break}case InsertionMode.IN_TABLE:{startTagInTable(this,token);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}case InsertionMode.IN_CAPTION:{startTagInCaption(this,token);break}case InsertionMode.IN_COLUMN_GROUP:{startTagInColumnGroup(this,token);break}case InsertionMode.IN_TABLE_BODY:{startTagInTableBody(this,token);break}case InsertionMode.IN_ROW:{startTagInRow(this,token);break}case InsertionMode.IN_CELL:{startTagInCell(this,token);break}case InsertionMode.IN_SELECT:{startTagInSelect(this,token);break}case InsertionMode.IN_SELECT_IN_TABLE:{startTagInSelectInTable(this,token);break}case InsertionMode.IN_TEMPLATE:{startTagInTemplate(this,token);break}case InsertionMode.AFTER_BODY:{startTagAfterBody(this,token);break}case InsertionMode.IN_FRAMESET:{startTagInFrameset(this,token);break}case InsertionMode.AFTER_FRAMESET:{startTagAfterFrameset(this,token);break}case InsertionMode.AFTER_AFTER_BODY:{startTagAfterAfterBody(this,token);break}case InsertionMode.AFTER_AFTER_FRAMESET:{startTagAfterAfterFrameset(this,token);break}default:}}onEndTag(token){this.skipNextNewLine=!1,this.currentToken=token,this.currentNotInHTML?endTagInForeignContent(this,token):this._endTagOutsideForeignContent(token)}_endTagOutsideForeignContent(token){switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{endTagBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{endTagBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{endTagInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{endTagInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{endTagAfterHead(this,token);break}case InsertionMode.IN_BODY:{endTagInBody(this,token);break}case InsertionMode.TEXT:{endTagInText(this,token);break}case InsertionMode.IN_TABLE:{endTagInTable(this,token);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}case InsertionMode.IN_CAPTION:{endTagInCaption(this,token);break}case InsertionMode.IN_COLUMN_GROUP:{endTagInColumnGroup(this,token);break}case InsertionMode.IN_TABLE_BODY:{endTagInTableBody(this,token);break}case InsertionMode.IN_ROW:{endTagInRow(this,token);break}case InsertionMode.IN_CELL:{endTagInCell(this,token);break}case InsertionMode.IN_SELECT:{endTagInSelect(this,token);break}case InsertionMode.IN_SELECT_IN_TABLE:{endTagInSelectInTable(this,token);break}case InsertionMode.IN_TEMPLATE:{endTagInTemplate(this,token);break}case InsertionMode.AFTER_BODY:{endTagAfterBody(this,token);break}case InsertionMode.IN_FRAMESET:{endTagInFrameset(this,token);break}case InsertionMode.AFTER_FRAMESET:{endTagAfterFrameset(this,token);break}case InsertionMode.AFTER_AFTER_BODY:{tokenAfterAfterBody(this,token);break}default:}}onEof(token){switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{tokenBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{tokenBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{tokenInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{tokenInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{tokenAfterHead(this,token);break}case InsertionMode.IN_BODY:case InsertionMode.IN_TABLE:case InsertionMode.IN_CAPTION:case InsertionMode.IN_COLUMN_GROUP:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:case InsertionMode.IN_CELL:case InsertionMode.IN_SELECT:case InsertionMode.IN_SELECT_IN_TABLE:{eofInBody(this,token);break}case InsertionMode.TEXT:{eofInText(this,token);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}case InsertionMode.IN_TEMPLATE:{eofInTemplate(this,token);break}case InsertionMode.AFTER_BODY:case InsertionMode.IN_FRAMESET:case InsertionMode.AFTER_FRAMESET:case InsertionMode.AFTER_AFTER_BODY:case InsertionMode.AFTER_AFTER_FRAMESET:{stopParsing(this,token);break}default:}}onWhitespaceCharacter(token){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,token.chars.charCodeAt(0)===CODE_POINTS.LINE_FEED)){if(token.chars.length===1)return;token.chars=token.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(token);return}switch(this.insertionMode){case InsertionMode.IN_HEAD:case InsertionMode.IN_HEAD_NO_SCRIPT:case InsertionMode.AFTER_HEAD:case InsertionMode.TEXT:case InsertionMode.IN_COLUMN_GROUP:case InsertionMode.IN_SELECT:case InsertionMode.IN_SELECT_IN_TABLE:case InsertionMode.IN_FRAMESET:case InsertionMode.AFTER_FRAMESET:{this._insertCharacters(token);break}case InsertionMode.IN_BODY:case InsertionMode.IN_CAPTION:case InsertionMode.IN_CELL:case InsertionMode.IN_TEMPLATE:case InsertionMode.AFTER_BODY:case InsertionMode.AFTER_AFTER_BODY:case InsertionMode.AFTER_AFTER_FRAMESET:{whitespaceCharacterInBody(this,token);break}case InsertionMode.IN_TABLE:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:{characterInTable(this,token);break}case InsertionMode.IN_TABLE_TEXT:{whitespaceCharacterInTableText(this,token);break}default:}}};function aaObtainFormattingElementEntry(p2,token){let formattingElementEntry=p2.activeFormattingElements.getElementEntryInScopeWithTagName(token.tagName);return formattingElementEntry?p2.openElements.contains(formattingElementEntry.element)?p2.openElements.hasInScope(token.tagID)||(formattingElementEntry=null):(p2.activeFormattingElements.removeEntry(formattingElementEntry),formattingElementEntry=null):genericEndTagInBody(p2,token),formattingElementEntry}function aaObtainFurthestBlock(p2,formattingElementEntry){let furthestBlock=null,idx=p2.openElements.stackTop;for(;idx>=0;idx--){let element=p2.openElements.items[idx];if(element===formattingElementEntry.element)break;p2._isSpecialElement(element,p2.openElements.tagIDs[idx])&&(furthestBlock=element)}return furthestBlock||(p2.openElements.shortenToLength(Math.max(idx,0)),p2.activeFormattingElements.removeEntry(formattingElementEntry)),furthestBlock}function aaInnerLoop(p2,furthestBlock,formattingElement){let lastElement=furthestBlock,nextElement=p2.openElements.getCommonAncestor(furthestBlock);for(let i2=0,element=nextElement;element!==formattingElement;i2++,element=nextElement){nextElement=p2.openElements.getCommonAncestor(element);let elementEntry=p2.activeFormattingElements.getElementEntry(element),counterOverflow=elementEntry&&i2>=AA_INNER_LOOP_ITER;!elementEntry||counterOverflow?(counterOverflow&&p2.activeFormattingElements.removeEntry(elementEntry),p2.openElements.remove(element)):(element=aaRecreateElementFromEntry(p2,elementEntry),lastElement===furthestBlock&&(p2.activeFormattingElements.bookmark=elementEntry),p2.treeAdapter.detachNode(lastElement),p2.treeAdapter.appendChild(element,lastElement),lastElement=element)}return lastElement}function aaRecreateElementFromEntry(p2,elementEntry){let ns=p2.treeAdapter.getNamespaceURI(elementEntry.element),newElement=p2.treeAdapter.createElement(elementEntry.token.tagName,ns,elementEntry.token.attrs);return p2.openElements.replace(elementEntry.element,newElement),elementEntry.element=newElement,newElement}function aaInsertLastNodeInCommonAncestor(p2,commonAncestor,lastElement){let tn2=p2.treeAdapter.getTagName(commonAncestor),tid=getTagID(tn2);if(p2._isElementCausesFosterParenting(tid))p2._fosterParentElement(lastElement);else{let ns=p2.treeAdapter.getNamespaceURI(commonAncestor);tid===TAG_ID.TEMPLATE&&ns===NS.HTML&&(commonAncestor=p2.treeAdapter.getTemplateContent(commonAncestor)),p2.treeAdapter.appendChild(commonAncestor,lastElement)}}function aaReplaceFormattingElement(p2,furthestBlock,formattingElementEntry){let ns=p2.treeAdapter.getNamespaceURI(formattingElementEntry.element),{token}=formattingElementEntry,newElement=p2.treeAdapter.createElement(token.tagName,ns,token.attrs);p2._adoptNodes(furthestBlock,newElement),p2.treeAdapter.appendChild(furthestBlock,newElement),p2.activeFormattingElements.insertElementAfterBookmark(newElement,token),p2.activeFormattingElements.removeEntry(formattingElementEntry),p2.openElements.remove(formattingElementEntry.element),p2.openElements.insertAfter(furthestBlock,newElement,token.tagID)}function callAdoptionAgency(p2,token){for(let i2=0;i2<AA_OUTER_LOOP_ITER;i2++){let formattingElementEntry=aaObtainFormattingElementEntry(p2,token);if(!formattingElementEntry)break;let furthestBlock=aaObtainFurthestBlock(p2,formattingElementEntry);if(!furthestBlock)break;p2.activeFormattingElements.bookmark=formattingElementEntry;let lastElement=aaInnerLoop(p2,furthestBlock,formattingElementEntry.element),commonAncestor=p2.openElements.getCommonAncestor(formattingElementEntry.element);p2.treeAdapter.detachNode(lastElement),commonAncestor&&aaInsertLastNodeInCommonAncestor(p2,commonAncestor,lastElement),aaReplaceFormattingElement(p2,furthestBlock,formattingElementEntry)}}function appendComment(p2,token){p2._appendCommentNode(token,p2.openElements.currentTmplContentOrNode)}function appendCommentToRootHtmlElement(p2,token){p2._appendCommentNode(token,p2.openElements.items[0])}function appendCommentToDocument(p2,token){p2._appendCommentNode(token,p2.document)}function stopParsing(p2,token){if(p2.stopped=!0,token.location){let target=p2.fragmentContext?0:2;for(let i2=p2.openElements.stackTop;i2>=target;i2--)p2._setEndLocation(p2.openElements.items[i2],token);if(!p2.fragmentContext&&p2.openElements.stackTop>=0){let htmlElement=p2.openElements.items[0],htmlLocation=p2.treeAdapter.getNodeSourceCodeLocation(htmlElement);if(htmlLocation&&!htmlLocation.endTag&&(p2._setEndLocation(htmlElement,token),p2.openElements.stackTop>=1)){let bodyElement=p2.openElements.items[1],bodyLocation=p2.treeAdapter.getNodeSourceCodeLocation(bodyElement);bodyLocation&&!bodyLocation.endTag&&p2._setEndLocation(bodyElement,token)}}}}function doctypeInInitialMode(p2,token){p2._setDocumentType(token);let mode=token.forceQuirks?DOCUMENT_MODE.QUIRKS:getDocumentMode(token);isConforming(token)||p2._err(token,ERR.nonConformingDoctype),p2.treeAdapter.setDocumentMode(p2.document,mode),p2.insertionMode=InsertionMode.BEFORE_HTML}function tokenInInitialMode(p2,token){p2._err(token,ERR.missingDoctype,!0),p2.treeAdapter.setDocumentMode(p2.document,DOCUMENT_MODE.QUIRKS),p2.insertionMode=InsertionMode.BEFORE_HTML,p2._processToken(token)}function startTagBeforeHtml(p2,token){token.tagID===TAG_ID.HTML?(p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.BEFORE_HEAD):tokenBeforeHtml(p2,token)}function endTagBeforeHtml(p2,token){let tn2=token.tagID;(tn2===TAG_ID.HTML||tn2===TAG_ID.HEAD||tn2===TAG_ID.BODY||tn2===TAG_ID.BR)&&tokenBeforeHtml(p2,token)}function tokenBeforeHtml(p2,token){p2._insertFakeRootElement(),p2.insertionMode=InsertionMode.BEFORE_HEAD,p2._processToken(token)}function startTagBeforeHead(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.HEAD:{p2._insertElement(token,NS.HTML),p2.headElement=p2.openElements.current,p2.insertionMode=InsertionMode.IN_HEAD;break}default:tokenBeforeHead(p2,token)}}function endTagBeforeHead(p2,token){let tn2=token.tagID;tn2===TAG_ID.HEAD||tn2===TAG_ID.BODY||tn2===TAG_ID.HTML||tn2===TAG_ID.BR?tokenBeforeHead(p2,token):p2._err(token,ERR.endTagWithoutMatchingOpenElement)}function tokenBeforeHead(p2,token){p2._insertFakeElement(TAG_NAMES.HEAD,TAG_ID.HEAD),p2.headElement=p2.openElements.current,p2.insertionMode=InsertionMode.IN_HEAD,p2._processToken(token)}function startTagInHead(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.BASE:case TAG_ID.BASEFONT:case TAG_ID.BGSOUND:case TAG_ID.LINK:case TAG_ID.META:{p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0;break}case TAG_ID.TITLE:{p2._switchToTextParsing(token,TokenizerMode.RCDATA);break}case TAG_ID.NOSCRIPT:{p2.options.scriptingEnabled?p2._switchToTextParsing(token,TokenizerMode.RAWTEXT):(p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_HEAD_NO_SCRIPT);break}case TAG_ID.NOFRAMES:case TAG_ID.STYLE:{p2._switchToTextParsing(token,TokenizerMode.RAWTEXT);break}case TAG_ID.SCRIPT:{p2._switchToTextParsing(token,TokenizerMode.SCRIPT_DATA);break}case TAG_ID.TEMPLATE:{p2._insertTemplate(token),p2.activeFormattingElements.insertMarker(),p2.framesetOk=!1,p2.insertionMode=InsertionMode.IN_TEMPLATE,p2.tmplInsertionModeStack.unshift(InsertionMode.IN_TEMPLATE);break}case TAG_ID.HEAD:{p2._err(token,ERR.misplacedStartTagForHeadElement);break}default:tokenInHead(p2,token)}}function endTagInHead(p2,token){switch(token.tagID){case TAG_ID.HEAD:{p2.openElements.pop(),p2.insertionMode=InsertionMode.AFTER_HEAD;break}case TAG_ID.BODY:case TAG_ID.BR:case TAG_ID.HTML:{tokenInHead(p2,token);break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}default:p2._err(token,ERR.endTagWithoutMatchingOpenElement)}}function templateEndTagInHead(p2,token){p2.openElements.tmplCount>0?(p2.openElements.generateImpliedEndTagsThoroughly(),p2.openElements.currentTagId!==TAG_ID.TEMPLATE&&p2._err(token,ERR.closingOfElementWithOpenChildElements),p2.openElements.popUntilTagNamePopped(TAG_ID.TEMPLATE),p2.activeFormattingElements.clearToLastMarker(),p2.tmplInsertionModeStack.shift(),p2._resetInsertionMode()):p2._err(token,ERR.endTagWithoutMatchingOpenElement)}function tokenInHead(p2,token){p2.openElements.pop(),p2.insertionMode=InsertionMode.AFTER_HEAD,p2._processToken(token)}function startTagInHeadNoScript(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.BASEFONT:case TAG_ID.BGSOUND:case TAG_ID.HEAD:case TAG_ID.LINK:case TAG_ID.META:case TAG_ID.NOFRAMES:case TAG_ID.STYLE:{startTagInHead(p2,token);break}case TAG_ID.NOSCRIPT:{p2._err(token,ERR.nestedNoscriptInHead);break}default:tokenInHeadNoScript(p2,token)}}function endTagInHeadNoScript(p2,token){switch(token.tagID){case TAG_ID.NOSCRIPT:{p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_HEAD;break}case TAG_ID.BR:{tokenInHeadNoScript(p2,token);break}default:p2._err(token,ERR.endTagWithoutMatchingOpenElement)}}function tokenInHeadNoScript(p2,token){let errCode=token.type===TokenType.EOF?ERR.openElementsLeftAfterEof:ERR.disallowedContentInNoscriptInHead;p2._err(token,errCode),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_HEAD,p2._processToken(token)}function startTagAfterHead(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.BODY:{p2._insertElement(token,NS.HTML),p2.framesetOk=!1,p2.insertionMode=InsertionMode.IN_BODY;break}case TAG_ID.FRAMESET:{p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_FRAMESET;break}case TAG_ID.BASE:case TAG_ID.BASEFONT:case TAG_ID.BGSOUND:case TAG_ID.LINK:case TAG_ID.META:case TAG_ID.NOFRAMES:case TAG_ID.SCRIPT:case TAG_ID.STYLE:case TAG_ID.TEMPLATE:case TAG_ID.TITLE:{p2._err(token,ERR.abandonedHeadElementChild),p2.openElements.push(p2.headElement,TAG_ID.HEAD),startTagInHead(p2,token),p2.openElements.remove(p2.headElement);break}case TAG_ID.HEAD:{p2._err(token,ERR.misplacedStartTagForHeadElement);break}default:tokenAfterHead(p2,token)}}function endTagAfterHead(p2,token){switch(token.tagID){case TAG_ID.BODY:case TAG_ID.HTML:case TAG_ID.BR:{tokenAfterHead(p2,token);break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}default:p2._err(token,ERR.endTagWithoutMatchingOpenElement)}}function tokenAfterHead(p2,token){p2._insertFakeElement(TAG_NAMES.BODY,TAG_ID.BODY),p2.insertionMode=InsertionMode.IN_BODY,modeInBody(p2,token)}function modeInBody(p2,token){switch(token.type){case TokenType.CHARACTER:{characterInBody(p2,token);break}case TokenType.WHITESPACE_CHARACTER:{whitespaceCharacterInBody(p2,token);break}case TokenType.COMMENT:{appendComment(p2,token);break}case TokenType.START_TAG:{startTagInBody(p2,token);break}case TokenType.END_TAG:{endTagInBody(p2,token);break}case TokenType.EOF:{eofInBody(p2,token);break}default:}}function whitespaceCharacterInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertCharacters(token)}function characterInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertCharacters(token),p2.framesetOk=!1}function htmlStartTagInBody(p2,token){p2.openElements.tmplCount===0&&p2.treeAdapter.adoptAttributes(p2.openElements.items[0],token.attrs)}function bodyStartTagInBody(p2,token){let bodyElement=p2.openElements.tryPeekProperlyNestedBodyElement();bodyElement&&p2.openElements.tmplCount===0&&(p2.framesetOk=!1,p2.treeAdapter.adoptAttributes(bodyElement,token.attrs))}function framesetStartTagInBody(p2,token){let bodyElement=p2.openElements.tryPeekProperlyNestedBodyElement();p2.framesetOk&&bodyElement&&(p2.treeAdapter.detachNode(bodyElement),p2.openElements.popAllUpToHtmlElement(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_FRAMESET)}function addressStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML)}function numberedHeaderStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2.openElements.currentTagId!==void 0&&NUMBERED_HEADERS.has(p2.openElements.currentTagId)&&p2.openElements.pop(),p2._insertElement(token,NS.HTML)}function preStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML),p2.skipNextNewLine=!0,p2.framesetOk=!1}function formStartTagInBody(p2,token){let inTemplate=p2.openElements.tmplCount>0;(!p2.formElement||inTemplate)&&(p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML),inTemplate||(p2.formElement=p2.openElements.current))}function listItemStartTagInBody(p2,token){p2.framesetOk=!1;let tn2=token.tagID;for(let i2=p2.openElements.stackTop;i2>=0;i2--){let elementId=p2.openElements.tagIDs[i2];if(tn2===TAG_ID.LI&&elementId===TAG_ID.LI||(tn2===TAG_ID.DD||tn2===TAG_ID.DT)&&(elementId===TAG_ID.DD||elementId===TAG_ID.DT)){p2.openElements.generateImpliedEndTagsWithExclusion(elementId),p2.openElements.popUntilTagNamePopped(elementId);break}if(elementId!==TAG_ID.ADDRESS&&elementId!==TAG_ID.DIV&&elementId!==TAG_ID.P&&p2._isSpecialElement(p2.openElements.items[i2],elementId))break}p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML)}function plaintextStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML),p2.tokenizer.state=TokenizerMode.PLAINTEXT}function buttonStartTagInBody(p2,token){p2.openElements.hasInScope(TAG_ID.BUTTON)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(TAG_ID.BUTTON)),p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.framesetOk=!1}function aStartTagInBody(p2,token){let activeElementEntry=p2.activeFormattingElements.getElementEntryInScopeWithTagName(TAG_NAMES.A);activeElementEntry&&(callAdoptionAgency(p2,token),p2.openElements.remove(activeElementEntry.element),p2.activeFormattingElements.removeEntry(activeElementEntry)),p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.activeFormattingElements.pushElement(p2.openElements.current,token)}function bStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.activeFormattingElements.pushElement(p2.openElements.current,token)}function nobrStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2.openElements.hasInScope(TAG_ID.NOBR)&&(callAdoptionAgency(p2,token),p2._reconstructActiveFormattingElements()),p2._insertElement(token,NS.HTML),p2.activeFormattingElements.pushElement(p2.openElements.current,token)}function appletStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.activeFormattingElements.insertMarker(),p2.framesetOk=!1}function tableStartTagInBody(p2,token){p2.treeAdapter.getDocumentMode(p2.document)!==DOCUMENT_MODE.QUIRKS&&p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML),p2.framesetOk=!1,p2.insertionMode=InsertionMode.IN_TABLE}function areaStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._appendElement(token,NS.HTML),p2.framesetOk=!1,token.ackSelfClosing=!0}function isHiddenInput(token){let inputType=getTokenAttr(token,ATTRS.TYPE);return inputType!=null&&inputType.toLowerCase()===HIDDEN_INPUT_TYPE}function inputStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._appendElement(token,NS.HTML),isHiddenInput(token)||(p2.framesetOk=!1),token.ackSelfClosing=!0}function paramStartTagInBody(p2,token){p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0}function hrStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._appendElement(token,NS.HTML),p2.framesetOk=!1,token.ackSelfClosing=!0}function imageStartTagInBody(p2,token){token.tagName=TAG_NAMES.IMG,token.tagID=TAG_ID.IMG,areaStartTagInBody(p2,token)}function textareaStartTagInBody(p2,token){p2._insertElement(token,NS.HTML),p2.skipNextNewLine=!0,p2.tokenizer.state=TokenizerMode.RCDATA,p2.originalInsertionMode=p2.insertionMode,p2.framesetOk=!1,p2.insertionMode=InsertionMode.TEXT}function xmpStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._reconstructActiveFormattingElements(),p2.framesetOk=!1,p2._switchToTextParsing(token,TokenizerMode.RAWTEXT)}function iframeStartTagInBody(p2,token){p2.framesetOk=!1,p2._switchToTextParsing(token,TokenizerMode.RAWTEXT)}function rawTextStartTagInBody(p2,token){p2._switchToTextParsing(token,TokenizerMode.RAWTEXT)}function selectStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.framesetOk=!1,p2.insertionMode=p2.insertionMode===InsertionMode.IN_TABLE||p2.insertionMode===InsertionMode.IN_CAPTION||p2.insertionMode===InsertionMode.IN_TABLE_BODY||p2.insertionMode===InsertionMode.IN_ROW||p2.insertionMode===InsertionMode.IN_CELL?InsertionMode.IN_SELECT_IN_TABLE:InsertionMode.IN_SELECT}function optgroupStartTagInBody(p2,token){p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop(),p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML)}function rbStartTagInBody(p2,token){p2.openElements.hasInScope(TAG_ID.RUBY)&&p2.openElements.generateImpliedEndTags(),p2._insertElement(token,NS.HTML)}function rtStartTagInBody(p2,token){p2.openElements.hasInScope(TAG_ID.RUBY)&&p2.openElements.generateImpliedEndTagsWithExclusion(TAG_ID.RTC),p2._insertElement(token,NS.HTML)}function mathStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),adjustTokenMathMLAttrs(token),adjustTokenXMLAttrs(token),token.selfClosing?p2._appendElement(token,NS.MATHML):p2._insertElement(token,NS.MATHML),token.ackSelfClosing=!0}function svgStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),adjustTokenSVGAttrs(token),adjustTokenXMLAttrs(token),token.selfClosing?p2._appendElement(token,NS.SVG):p2._insertElement(token,NS.SVG),token.ackSelfClosing=!0}function genericStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML)}function startTagInBody(p2,token){switch(token.tagID){case TAG_ID.I:case TAG_ID.S:case TAG_ID.B:case TAG_ID.U:case TAG_ID.EM:case TAG_ID.TT:case TAG_ID.BIG:case TAG_ID.CODE:case TAG_ID.FONT:case TAG_ID.SMALL:case TAG_ID.STRIKE:case TAG_ID.STRONG:{bStartTagInBody(p2,token);break}case TAG_ID.A:{aStartTagInBody(p2,token);break}case TAG_ID.H1:case TAG_ID.H2:case TAG_ID.H3:case TAG_ID.H4:case TAG_ID.H5:case TAG_ID.H6:{numberedHeaderStartTagInBody(p2,token);break}case TAG_ID.P:case TAG_ID.DL:case TAG_ID.OL:case TAG_ID.UL:case TAG_ID.DIV:case TAG_ID.DIR:case TAG_ID.NAV:case TAG_ID.MAIN:case TAG_ID.MENU:case TAG_ID.ASIDE:case TAG_ID.CENTER:case TAG_ID.FIGURE:case TAG_ID.FOOTER:case TAG_ID.HEADER:case TAG_ID.HGROUP:case TAG_ID.DIALOG:case TAG_ID.DETAILS:case TAG_ID.ADDRESS:case TAG_ID.ARTICLE:case TAG_ID.SEARCH:case TAG_ID.SECTION:case TAG_ID.SUMMARY:case TAG_ID.FIELDSET:case TAG_ID.BLOCKQUOTE:case TAG_ID.FIGCAPTION:{addressStartTagInBody(p2,token);break}case TAG_ID.LI:case TAG_ID.DD:case TAG_ID.DT:{listItemStartTagInBody(p2,token);break}case TAG_ID.BR:case TAG_ID.IMG:case TAG_ID.WBR:case TAG_ID.AREA:case TAG_ID.EMBED:case TAG_ID.KEYGEN:{areaStartTagInBody(p2,token);break}case TAG_ID.HR:{hrStartTagInBody(p2,token);break}case TAG_ID.RB:case TAG_ID.RTC:{rbStartTagInBody(p2,token);break}case TAG_ID.RT:case TAG_ID.RP:{rtStartTagInBody(p2,token);break}case TAG_ID.PRE:case TAG_ID.LISTING:{preStartTagInBody(p2,token);break}case TAG_ID.XMP:{xmpStartTagInBody(p2,token);break}case TAG_ID.SVG:{svgStartTagInBody(p2,token);break}case TAG_ID.HTML:{htmlStartTagInBody(p2,token);break}case TAG_ID.BASE:case TAG_ID.LINK:case TAG_ID.META:case TAG_ID.STYLE:case TAG_ID.TITLE:case TAG_ID.SCRIPT:case TAG_ID.BGSOUND:case TAG_ID.BASEFONT:case TAG_ID.TEMPLATE:{startTagInHead(p2,token);break}case TAG_ID.BODY:{bodyStartTagInBody(p2,token);break}case TAG_ID.FORM:{formStartTagInBody(p2,token);break}case TAG_ID.NOBR:{nobrStartTagInBody(p2,token);break}case TAG_ID.MATH:{mathStartTagInBody(p2,token);break}case TAG_ID.TABLE:{tableStartTagInBody(p2,token);break}case TAG_ID.INPUT:{inputStartTagInBody(p2,token);break}case TAG_ID.PARAM:case TAG_ID.TRACK:case TAG_ID.SOURCE:{paramStartTagInBody(p2,token);break}case TAG_ID.IMAGE:{imageStartTagInBody(p2,token);break}case TAG_ID.BUTTON:{buttonStartTagInBody(p2,token);break}case TAG_ID.APPLET:case TAG_ID.OBJECT:case TAG_ID.MARQUEE:{appletStartTagInBody(p2,token);break}case TAG_ID.IFRAME:{iframeStartTagInBody(p2,token);break}case TAG_ID.SELECT:{selectStartTagInBody(p2,token);break}case TAG_ID.OPTION:case TAG_ID.OPTGROUP:{optgroupStartTagInBody(p2,token);break}case TAG_ID.NOEMBED:case TAG_ID.NOFRAMES:{rawTextStartTagInBody(p2,token);break}case TAG_ID.FRAMESET:{framesetStartTagInBody(p2,token);break}case TAG_ID.TEXTAREA:{textareaStartTagInBody(p2,token);break}case TAG_ID.NOSCRIPT:{p2.options.scriptingEnabled?rawTextStartTagInBody(p2,token):genericStartTagInBody(p2,token);break}case TAG_ID.PLAINTEXT:{plaintextStartTagInBody(p2,token);break}case TAG_ID.COL:case TAG_ID.TH:case TAG_ID.TD:case TAG_ID.TR:case TAG_ID.HEAD:case TAG_ID.FRAME:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:case TAG_ID.CAPTION:case TAG_ID.COLGROUP:break;default:genericStartTagInBody(p2,token)}}function bodyEndTagInBody(p2,token){if(p2.openElements.hasInScope(TAG_ID.BODY)&&(p2.insertionMode=InsertionMode.AFTER_BODY,p2.options.sourceCodeLocationInfo)){let bodyElement=p2.openElements.tryPeekProperlyNestedBodyElement();bodyElement&&p2._setEndLocation(bodyElement,token)}}function htmlEndTagInBody(p2,token){p2.openElements.hasInScope(TAG_ID.BODY)&&(p2.insertionMode=InsertionMode.AFTER_BODY,endTagAfterBody(p2,token))}function addressEndTagInBody(p2,token){let tn2=token.tagID;p2.openElements.hasInScope(tn2)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(tn2))}function formEndTagInBody(p2){let inTemplate=p2.openElements.tmplCount>0,{formElement}=p2;inTemplate||(p2.formElement=null),(formElement||inTemplate)&&p2.openElements.hasInScope(TAG_ID.FORM)&&(p2.openElements.generateImpliedEndTags(),inTemplate?p2.openElements.popUntilTagNamePopped(TAG_ID.FORM):formElement&&p2.openElements.remove(formElement))}function pEndTagInBody(p2){p2.openElements.hasInButtonScope(TAG_ID.P)||p2._insertFakeElement(TAG_NAMES.P,TAG_ID.P),p2._closePElement()}function liEndTagInBody(p2){p2.openElements.hasInListItemScope(TAG_ID.LI)&&(p2.openElements.generateImpliedEndTagsWithExclusion(TAG_ID.LI),p2.openElements.popUntilTagNamePopped(TAG_ID.LI))}function ddEndTagInBody(p2,token){let tn2=token.tagID;p2.openElements.hasInScope(tn2)&&(p2.openElements.generateImpliedEndTagsWithExclusion(tn2),p2.openElements.popUntilTagNamePopped(tn2))}function numberedHeaderEndTagInBody(p2){p2.openElements.hasNumberedHeaderInScope()&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilNumberedHeaderPopped())}function appletEndTagInBody(p2,token){let tn2=token.tagID;p2.openElements.hasInScope(tn2)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(tn2),p2.activeFormattingElements.clearToLastMarker())}function brEndTagInBody(p2){p2._reconstructActiveFormattingElements(),p2._insertFakeElement(TAG_NAMES.BR,TAG_ID.BR),p2.openElements.pop(),p2.framesetOk=!1}function genericEndTagInBody(p2,token){let tn2=token.tagName,tid=token.tagID;for(let i2=p2.openElements.stackTop;i2>0;i2--){let element=p2.openElements.items[i2],elementId=p2.openElements.tagIDs[i2];if(tid===elementId&&(tid!==TAG_ID.UNKNOWN||p2.treeAdapter.getTagName(element)===tn2)){p2.openElements.generateImpliedEndTagsWithExclusion(tid),p2.openElements.stackTop>=i2&&p2.openElements.shortenToLength(i2);break}if(p2._isSpecialElement(element,elementId))break}}function endTagInBody(p2,token){switch(token.tagID){case TAG_ID.A:case TAG_ID.B:case TAG_ID.I:case TAG_ID.S:case TAG_ID.U:case TAG_ID.EM:case TAG_ID.TT:case TAG_ID.BIG:case TAG_ID.CODE:case TAG_ID.FONT:case TAG_ID.NOBR:case TAG_ID.SMALL:case TAG_ID.STRIKE:case TAG_ID.STRONG:{callAdoptionAgency(p2,token);break}case TAG_ID.P:{pEndTagInBody(p2);break}case TAG_ID.DL:case TAG_ID.UL:case TAG_ID.OL:case TAG_ID.DIR:case TAG_ID.DIV:case TAG_ID.NAV:case TAG_ID.PRE:case TAG_ID.MAIN:case TAG_ID.MENU:case TAG_ID.ASIDE:case TAG_ID.BUTTON:case TAG_ID.CENTER:case TAG_ID.FIGURE:case TAG_ID.FOOTER:case TAG_ID.HEADER:case TAG_ID.HGROUP:case TAG_ID.DIALOG:case TAG_ID.ADDRESS:case TAG_ID.ARTICLE:case TAG_ID.DETAILS:case TAG_ID.SEARCH:case TAG_ID.SECTION:case TAG_ID.SUMMARY:case TAG_ID.LISTING:case TAG_ID.FIELDSET:case TAG_ID.BLOCKQUOTE:case TAG_ID.FIGCAPTION:{addressEndTagInBody(p2,token);break}case TAG_ID.LI:{liEndTagInBody(p2);break}case TAG_ID.DD:case TAG_ID.DT:{ddEndTagInBody(p2,token);break}case TAG_ID.H1:case TAG_ID.H2:case TAG_ID.H3:case TAG_ID.H4:case TAG_ID.H5:case TAG_ID.H6:{numberedHeaderEndTagInBody(p2);break}case TAG_ID.BR:{brEndTagInBody(p2);break}case TAG_ID.BODY:{bodyEndTagInBody(p2,token);break}case TAG_ID.HTML:{htmlEndTagInBody(p2,token);break}case TAG_ID.FORM:{formEndTagInBody(p2);break}case TAG_ID.APPLET:case TAG_ID.OBJECT:case TAG_ID.MARQUEE:{appletEndTagInBody(p2,token);break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}default:genericEndTagInBody(p2,token)}}function eofInBody(p2,token){p2.tmplInsertionModeStack.length>0?eofInTemplate(p2,token):stopParsing(p2,token)}function endTagInText(p2,token){var _a2;token.tagID===TAG_ID.SCRIPT&&((_a2=p2.scriptHandler)===null||_a2===void 0||_a2.call(p2,p2.openElements.current)),p2.openElements.pop(),p2.insertionMode=p2.originalInsertionMode}function eofInText(p2,token){p2._err(token,ERR.eofInElementThatCanContainOnlyText),p2.openElements.pop(),p2.insertionMode=p2.originalInsertionMode,p2.onEof(token)}function characterInTable(p2,token){if(p2.openElements.currentTagId!==void 0&&TABLE_STRUCTURE_TAGS.has(p2.openElements.currentTagId))switch(p2.pendingCharacterTokens.length=0,p2.hasNonWhitespacePendingCharacterToken=!1,p2.originalInsertionMode=p2.insertionMode,p2.insertionMode=InsertionMode.IN_TABLE_TEXT,token.type){case TokenType.CHARACTER:{characterInTableText(p2,token);break}case TokenType.WHITESPACE_CHARACTER:{whitespaceCharacterInTableText(p2,token);break}}else tokenInTable(p2,token)}function captionStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2.activeFormattingElements.insertMarker(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_CAPTION}function colgroupStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_COLUMN_GROUP}function colStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2._insertFakeElement(TAG_NAMES.COLGROUP,TAG_ID.COLGROUP),p2.insertionMode=InsertionMode.IN_COLUMN_GROUP,startTagInColumnGroup(p2,token)}function tbodyStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_TABLE_BODY}function tdStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2._insertFakeElement(TAG_NAMES.TBODY,TAG_ID.TBODY),p2.insertionMode=InsertionMode.IN_TABLE_BODY,startTagInTableBody(p2,token)}function tableStartTagInTable(p2,token){p2.openElements.hasInTableScope(TAG_ID.TABLE)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.TABLE),p2._resetInsertionMode(),p2._processStartTag(token))}function inputStartTagInTable(p2,token){isHiddenInput(token)?p2._appendElement(token,NS.HTML):tokenInTable(p2,token),token.ackSelfClosing=!0}function formStartTagInTable(p2,token){!p2.formElement&&p2.openElements.tmplCount===0&&(p2._insertElement(token,NS.HTML),p2.formElement=p2.openElements.current,p2.openElements.pop())}function startTagInTable(p2,token){switch(token.tagID){case TAG_ID.TD:case TAG_ID.TH:case TAG_ID.TR:{tdStartTagInTable(p2,token);break}case TAG_ID.STYLE:case TAG_ID.SCRIPT:case TAG_ID.TEMPLATE:{startTagInHead(p2,token);break}case TAG_ID.COL:{colStartTagInTable(p2,token);break}case TAG_ID.FORM:{formStartTagInTable(p2,token);break}case TAG_ID.TABLE:{tableStartTagInTable(p2,token);break}case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{tbodyStartTagInTable(p2,token);break}case TAG_ID.INPUT:{inputStartTagInTable(p2,token);break}case TAG_ID.CAPTION:{captionStartTagInTable(p2,token);break}case TAG_ID.COLGROUP:{colgroupStartTagInTable(p2,token);break}default:tokenInTable(p2,token)}}function endTagInTable(p2,token){switch(token.tagID){case TAG_ID.TABLE:{p2.openElements.hasInTableScope(TAG_ID.TABLE)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.TABLE),p2._resetInsertionMode());break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}case TAG_ID.BODY:case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:case TAG_ID.TBODY:case TAG_ID.TD:case TAG_ID.TFOOT:case TAG_ID.TH:case TAG_ID.THEAD:case TAG_ID.TR:break;default:tokenInTable(p2,token)}}function tokenInTable(p2,token){let savedFosterParentingState=p2.fosterParentingEnabled;p2.fosterParentingEnabled=!0,modeInBody(p2,token),p2.fosterParentingEnabled=savedFosterParentingState}function whitespaceCharacterInTableText(p2,token){p2.pendingCharacterTokens.push(token)}function characterInTableText(p2,token){p2.pendingCharacterTokens.push(token),p2.hasNonWhitespacePendingCharacterToken=!0}function tokenInTableText(p2,token){let i2=0;if(p2.hasNonWhitespacePendingCharacterToken)for(;i2<p2.pendingCharacterTokens.length;i2++)tokenInTable(p2,p2.pendingCharacterTokens[i2]);else for(;i2<p2.pendingCharacterTokens.length;i2++)p2._insertCharacters(p2.pendingCharacterTokens[i2]);p2.insertionMode=p2.originalInsertionMode,p2._processToken(token)}var TABLE_VOID_ELEMENTS=new Set([TAG_ID.CAPTION,TAG_ID.COL,TAG_ID.COLGROUP,TAG_ID.TBODY,TAG_ID.TD,TAG_ID.TFOOT,TAG_ID.TH,TAG_ID.THEAD,TAG_ID.TR]);function startTagInCaption(p2,token){let tn2=token.tagID;TABLE_VOID_ELEMENTS.has(tn2)?p2.openElements.hasInTableScope(TAG_ID.CAPTION)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(TAG_ID.CAPTION),p2.activeFormattingElements.clearToLastMarker(),p2.insertionMode=InsertionMode.IN_TABLE,startTagInTable(p2,token)):startTagInBody(p2,token)}function endTagInCaption(p2,token){let tn2=token.tagID;switch(tn2){case TAG_ID.CAPTION:case TAG_ID.TABLE:{p2.openElements.hasInTableScope(TAG_ID.CAPTION)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(TAG_ID.CAPTION),p2.activeFormattingElements.clearToLastMarker(),p2.insertionMode=InsertionMode.IN_TABLE,tn2===TAG_ID.TABLE&&endTagInTable(p2,token));break}case TAG_ID.BODY:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:case TAG_ID.TBODY:case TAG_ID.TD:case TAG_ID.TFOOT:case TAG_ID.TH:case TAG_ID.THEAD:case TAG_ID.TR:break;default:endTagInBody(p2,token)}}function startTagInColumnGroup(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.COL:{p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0;break}case TAG_ID.TEMPLATE:{startTagInHead(p2,token);break}default:tokenInColumnGroup(p2,token)}}function endTagInColumnGroup(p2,token){switch(token.tagID){case TAG_ID.COLGROUP:{p2.openElements.currentTagId===TAG_ID.COLGROUP&&(p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE);break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}case TAG_ID.COL:break;default:tokenInColumnGroup(p2,token)}}function tokenInColumnGroup(p2,token){p2.openElements.currentTagId===TAG_ID.COLGROUP&&(p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE,p2._processToken(token))}function startTagInTableBody(p2,token){switch(token.tagID){case TAG_ID.TR:{p2.openElements.clearBackToTableBodyContext(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_ROW;break}case TAG_ID.TH:case TAG_ID.TD:{p2.openElements.clearBackToTableBodyContext(),p2._insertFakeElement(TAG_NAMES.TR,TAG_ID.TR),p2.insertionMode=InsertionMode.IN_ROW,startTagInRow(p2,token);break}case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{p2.openElements.hasTableBodyContextInTableScope()&&(p2.openElements.clearBackToTableBodyContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE,startTagInTable(p2,token));break}default:startTagInTable(p2,token)}}function endTagInTableBody(p2,token){let tn2=token.tagID;switch(token.tagID){case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{p2.openElements.hasInTableScope(tn2)&&(p2.openElements.clearBackToTableBodyContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE);break}case TAG_ID.TABLE:{p2.openElements.hasTableBodyContextInTableScope()&&(p2.openElements.clearBackToTableBodyContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE,endTagInTable(p2,token));break}case TAG_ID.BODY:case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:case TAG_ID.TD:case TAG_ID.TH:case TAG_ID.TR:break;default:endTagInTable(p2,token)}}function startTagInRow(p2,token){switch(token.tagID){case TAG_ID.TH:case TAG_ID.TD:{p2.openElements.clearBackToTableRowContext(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_CELL,p2.activeFormattingElements.insertMarker();break}case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:case TAG_ID.TR:{p2.openElements.hasInTableScope(TAG_ID.TR)&&(p2.openElements.clearBackToTableRowContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE_BODY,startTagInTableBody(p2,token));break}default:startTagInTable(p2,token)}}function endTagInRow(p2,token){switch(token.tagID){case TAG_ID.TR:{p2.openElements.hasInTableScope(TAG_ID.TR)&&(p2.openElements.clearBackToTableRowContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE_BODY);break}case TAG_ID.TABLE:{p2.openElements.hasInTableScope(TAG_ID.TR)&&(p2.openElements.clearBackToTableRowContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE_BODY,endTagInTableBody(p2,token));break}case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{(p2.openElements.hasInTableScope(token.tagID)||p2.openElements.hasInTableScope(TAG_ID.TR))&&(p2.openElements.clearBackToTableRowContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE_BODY,endTagInTableBody(p2,token));break}case TAG_ID.BODY:case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:case TAG_ID.TD:case TAG_ID.TH:break;default:endTagInTable(p2,token)}}function startTagInCell(p2,token){let tn2=token.tagID;TABLE_VOID_ELEMENTS.has(tn2)?(p2.openElements.hasInTableScope(TAG_ID.TD)||p2.openElements.hasInTableScope(TAG_ID.TH))&&(p2._closeTableCell(),startTagInRow(p2,token)):startTagInBody(p2,token)}function endTagInCell(p2,token){let tn2=token.tagID;switch(tn2){case TAG_ID.TD:case TAG_ID.TH:{p2.openElements.hasInTableScope(tn2)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(tn2),p2.activeFormattingElements.clearToLastMarker(),p2.insertionMode=InsertionMode.IN_ROW);break}case TAG_ID.TABLE:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:case TAG_ID.TR:{p2.openElements.hasInTableScope(tn2)&&(p2._closeTableCell(),endTagInRow(p2,token));break}case TAG_ID.BODY:case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:break;default:endTagInBody(p2,token)}}function startTagInSelect(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.OPTION:{p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop(),p2._insertElement(token,NS.HTML);break}case TAG_ID.OPTGROUP:{p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop(),p2.openElements.currentTagId===TAG_ID.OPTGROUP&&p2.openElements.pop(),p2._insertElement(token,NS.HTML);break}case TAG_ID.HR:{p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop(),p2.openElements.currentTagId===TAG_ID.OPTGROUP&&p2.openElements.pop(),p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0;break}case TAG_ID.INPUT:case TAG_ID.KEYGEN:case TAG_ID.TEXTAREA:case TAG_ID.SELECT:{p2.openElements.hasInSelectScope(TAG_ID.SELECT)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.SELECT),p2._resetInsertionMode(),token.tagID!==TAG_ID.SELECT&&p2._processStartTag(token));break}case TAG_ID.SCRIPT:case TAG_ID.TEMPLATE:{startTagInHead(p2,token);break}default:}}function endTagInSelect(p2,token){switch(token.tagID){case TAG_ID.OPTGROUP:{p2.openElements.stackTop>0&&p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.tagIDs[p2.openElements.stackTop-1]===TAG_ID.OPTGROUP&&p2.openElements.pop(),p2.openElements.currentTagId===TAG_ID.OPTGROUP&&p2.openElements.pop();break}case TAG_ID.OPTION:{p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop();break}case TAG_ID.SELECT:{p2.openElements.hasInSelectScope(TAG_ID.SELECT)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.SELECT),p2._resetInsertionMode());break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}default:}}function startTagInSelectInTable(p2,token){let tn2=token.tagID;tn2===TAG_ID.CAPTION||tn2===TAG_ID.TABLE||tn2===TAG_ID.TBODY||tn2===TAG_ID.TFOOT||tn2===TAG_ID.THEAD||tn2===TAG_ID.TR||tn2===TAG_ID.TD||tn2===TAG_ID.TH?(p2.openElements.popUntilTagNamePopped(TAG_ID.SELECT),p2._resetInsertionMode(),p2._processStartTag(token)):startTagInSelect(p2,token)}function endTagInSelectInTable(p2,token){let tn2=token.tagID;tn2===TAG_ID.CAPTION||tn2===TAG_ID.TABLE||tn2===TAG_ID.TBODY||tn2===TAG_ID.TFOOT||tn2===TAG_ID.THEAD||tn2===TAG_ID.TR||tn2===TAG_ID.TD||tn2===TAG_ID.TH?p2.openElements.hasInTableScope(tn2)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.SELECT),p2._resetInsertionMode(),p2.onEndTag(token)):endTagInSelect(p2,token)}function startTagInTemplate(p2,token){switch(token.tagID){case TAG_ID.BASE:case TAG_ID.BASEFONT:case TAG_ID.BGSOUND:case TAG_ID.LINK:case TAG_ID.META:case TAG_ID.NOFRAMES:case TAG_ID.SCRIPT:case TAG_ID.STYLE:case TAG_ID.TEMPLATE:case TAG_ID.TITLE:{startTagInHead(p2,token);break}case TAG_ID.CAPTION:case TAG_ID.COLGROUP:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{p2.tmplInsertionModeStack[0]=InsertionMode.IN_TABLE,p2.insertionMode=InsertionMode.IN_TABLE,startTagInTable(p2,token);break}case TAG_ID.COL:{p2.tmplInsertionModeStack[0]=InsertionMode.IN_COLUMN_GROUP,p2.insertionMode=InsertionMode.IN_COLUMN_GROUP,startTagInColumnGroup(p2,token);break}case TAG_ID.TR:{p2.tmplInsertionModeStack[0]=InsertionMode.IN_TABLE_BODY,p2.insertionMode=InsertionMode.IN_TABLE_BODY,startTagInTableBody(p2,token);break}case TAG_ID.TD:case TAG_ID.TH:{p2.tmplInsertionModeStack[0]=InsertionMode.IN_ROW,p2.insertionMode=InsertionMode.IN_ROW,startTagInRow(p2,token);break}default:p2.tmplInsertionModeStack[0]=InsertionMode.IN_BODY,p2.insertionMode=InsertionMode.IN_BODY,startTagInBody(p2,token)}}function endTagInTemplate(p2,token){token.tagID===TAG_ID.TEMPLATE&&templateEndTagInHead(p2,token)}function eofInTemplate(p2,token){p2.openElements.tmplCount>0?(p2.openElements.popUntilTagNamePopped(TAG_ID.TEMPLATE),p2.activeFormattingElements.clearToLastMarker(),p2.tmplInsertionModeStack.shift(),p2._resetInsertionMode(),p2.onEof(token)):stopParsing(p2,token)}function startTagAfterBody(p2,token){token.tagID===TAG_ID.HTML?startTagInBody(p2,token):tokenAfterBody(p2,token)}function endTagAfterBody(p2,token){var _a2;if(token.tagID===TAG_ID.HTML){if(p2.fragmentContext||(p2.insertionMode=InsertionMode.AFTER_AFTER_BODY),p2.options.sourceCodeLocationInfo&&p2.openElements.tagIDs[0]===TAG_ID.HTML){p2._setEndLocation(p2.openElements.items[0],token);let bodyElement=p2.openElements.items[1];bodyElement&&!(!((_a2=p2.treeAdapter.getNodeSourceCodeLocation(bodyElement))===null||_a2===void 0)&&_a2.endTag)&&p2._setEndLocation(bodyElement,token)}}else tokenAfterBody(p2,token)}function tokenAfterBody(p2,token){p2.insertionMode=InsertionMode.IN_BODY,modeInBody(p2,token)}function startTagInFrameset(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.FRAMESET:{p2._insertElement(token,NS.HTML);break}case TAG_ID.FRAME:{p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0;break}case TAG_ID.NOFRAMES:{startTagInHead(p2,token);break}default:}}function endTagInFrameset(p2,token){token.tagID===TAG_ID.FRAMESET&&!p2.openElements.isRootHtmlElementCurrent()&&(p2.openElements.pop(),!p2.fragmentContext&&p2.openElements.currentTagId!==TAG_ID.FRAMESET&&(p2.insertionMode=InsertionMode.AFTER_FRAMESET))}function startTagAfterFrameset(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.NOFRAMES:{startTagInHead(p2,token);break}default:}}function endTagAfterFrameset(p2,token){token.tagID===TAG_ID.HTML&&(p2.insertionMode=InsertionMode.AFTER_AFTER_FRAMESET)}function startTagAfterAfterBody(p2,token){token.tagID===TAG_ID.HTML?startTagInBody(p2,token):tokenAfterAfterBody(p2,token)}function tokenAfterAfterBody(p2,token){p2.insertionMode=InsertionMode.IN_BODY,modeInBody(p2,token)}function startTagAfterAfterFrameset(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.NOFRAMES:{startTagInHead(p2,token);break}default:}}function nullCharacterInForeignContent(p2,token){token.chars=REPLACEMENT_CHARACTER,p2._insertCharacters(token)}function characterInForeignContent(p2,token){p2._insertCharacters(token),p2.framesetOk=!1}function popUntilHtmlOrIntegrationPoint(p2){for(;p2.treeAdapter.getNamespaceURI(p2.openElements.current)!==NS.HTML&&p2.openElements.currentTagId!==void 0&&!p2._isIntegrationPoint(p2.openElements.currentTagId,p2.openElements.current);)p2.openElements.pop()}function startTagInForeignContent(p2,token){if(causesExit(token))popUntilHtmlOrIntegrationPoint(p2),p2._startTagOutsideForeignContent(token);else{let current=p2._getAdjustedCurrentElement(),currentNs=p2.treeAdapter.getNamespaceURI(current);currentNs===NS.MATHML?adjustTokenMathMLAttrs(token):currentNs===NS.SVG&&(adjustTokenSVGTagName(token),adjustTokenSVGAttrs(token)),adjustTokenXMLAttrs(token),token.selfClosing?p2._appendElement(token,currentNs):p2._insertElement(token,currentNs),token.ackSelfClosing=!0}}function endTagInForeignContent(p2,token){if(token.tagID===TAG_ID.P||token.tagID===TAG_ID.BR){popUntilHtmlOrIntegrationPoint(p2),p2._endTagOutsideForeignContent(token);return}for(let i2=p2.openElements.stackTop;i2>0;i2--){let element=p2.openElements.items[i2];if(p2.treeAdapter.getNamespaceURI(element)===NS.HTML){p2._endTagOutsideForeignContent(token);break}let tagName=p2.treeAdapter.getTagName(element);if(tagName.toLowerCase()===token.tagName){token.tagName=tagName,p2.openElements.shortenToLength(i2);break}}}init_browser_globals();init_browser_globals();var getCodePoint=String.prototype.codePointAt==null?(c2,index4)=>(c2.charCodeAt(index4)&64512)===55296?(c2.charCodeAt(index4)-55296)*1024+c2.charCodeAt(index4+1)-56320+65536:c2.charCodeAt(index4):(input,index4)=>input.codePointAt(index4);var VOID_ELEMENTS=new Set([TAG_NAMES.AREA,TAG_NAMES.BASE,TAG_NAMES.BASEFONT,TAG_NAMES.BGSOUND,TAG_NAMES.BR,TAG_NAMES.COL,TAG_NAMES.EMBED,TAG_NAMES.FRAME,TAG_NAMES.HR,TAG_NAMES.IMG,TAG_NAMES.INPUT,TAG_NAMES.KEYGEN,TAG_NAMES.LINK,TAG_NAMES.META,TAG_NAMES.PARAM,TAG_NAMES.SOURCE,TAG_NAMES.TRACK,TAG_NAMES.WBR]);function parseFragment(fragmentContext,html2,options2){typeof fragmentContext=="string"&&(options2=html2,html2=fragmentContext,fragmentContext=null);let parser=Parser2.getFragmentParser(fragmentContext,options2);return parser.tokenizer.write(html2,!0),parser.getFragment()}init_browser_globals();var import_postcss=__toESM(require_postcss(),1),postcss_default=import_postcss.default,stringify4=import_postcss.default.stringify,fromJSON=import_postcss.default.fromJSON,plugin=import_postcss.default.plugin,parse3=import_postcss.default.parse,list4=import_postcss.default.list,document4=import_postcss.default.document,comment=import_postcss.default.comment,atRule=import_postcss.default.atRule,rule=import_postcss.default.rule,decl=import_postcss.default.decl,root2=import_postcss.default.root,CssSyntaxError=import_postcss.default.CssSyntaxError,Declaration=import_postcss.default.Declaration,Container=import_postcss.default.Container,Processor2=import_postcss.default.Processor,Document2=import_postcss.default.Document,Comment=import_postcss.default.Comment,Warning=import_postcss.default.Warning,AtRule=import_postcss.default.AtRule,Result=import_postcss.default.Result,Input=import_postcss.default.Input,Rule=import_postcss.default.Rule,Root=import_postcss.default.Root,Node2=import_postcss.default.Node;var import_postcss_value_parser=__toESM(require_lib3(),1),cssReferences=(source2,replace2)=>{let tree=postcss_default.parse(source2),value2=(source3,imports=!1)=>{let parsed2=(0,import_postcss_value_parser.default)(source3);parsed2.walk(node2=>{if(node2.type==="function"&&node2.value.toLowerCase()==="url"){let before=import_postcss_value_parser.default.stringify(node2.nodes).replace(/^(['"])(.*)\1$/,"$2"),next=replace2(before,!0);return next!==before&&(node2.nodes=(0,import_postcss_value_parser.default)(JSON.stringify(next)).nodes),!1}if(node2.type==="function"&&/^(?:-webkit-)?image-set$/i.test(node2.value))for(let child of node2.nodes)child.type==="string"&&(child.value=replace2(child.value,!0))});let first=parsed2.nodes.find(node2=>node2.type!=="space"&&node2.type!=="comment");return imports&&first?.type==="string"&&(first.value=replace2(first.value,!0)),parsed2.toString()};return tree.walkDecls(node2=>{node2.value=value2(node2.value)}),tree.walkAtRules(node2=>{node2.params=value2(node2.params,node2.name.toLowerCase()==="import")}),tree.toString()},assetReferences=(source2,extension2,replace2)=>{if(extension2==="css")return cssReferences(source2,replace2);let changes=[],walk2=parent=>{for(let node2 of parent.childNodes)if("tagName"in node2){for(let attr of node2.attrs){let next=attr.value;if(["src","poster","background"].includes(attr.name)||attr.name==="data"&&node2.tagName==="object"||["href","xlink:href"].includes(attr.name))next=replace2(attr.value,!["a","area","base"].includes(node2.tagName));else if(attr.name==="srcdoc")next=assetReferences(attr.value,"html",replace2);else if(attr.name==="style")next=cssReferences(attr.value,replace2);else if(["srcset","imagesrcset"].includes(attr.name)){let rest=attr.value;for(next="";rest;){let space=/^[\s,]*/.exec(rest)?.[0]??"";next+=space,rest=rest.slice(space.length);let token=/^\S+/.exec(rest)?.[0];if(!token)break;let url=token.replace(/,+$/,"");if(next+=replace2(url,!0)+token.slice(url.length),rest=rest.slice(token.length),!token.endsWith(",")){let descriptor=/^[^,]*,?/.exec(rest)?.[0]??"";next+=descriptor,rest=rest.slice(descriptor.length)}}}if(next===attr.value)continue;let name=attr.prefix?`${attr.prefix}:${attr.name}`:attr.name,location2=node2.sourceCodeLocation?.attrs?.[name];if(!location2)throw new Error(`Cannot update attribute: ${name}`);let raw=source2.slice(location2.startOffset,location2.endOffset),head=/^[^=]+\s*=\s*/.exec(raw)?.[0];if(!head)throw new Error(`Cannot update attribute: ${name}`);let quote=raw[head.length]==="'"?"'":'"',escaped=next.replaceAll("&","&").replaceAll("<","<").replaceAll(quote,quote==='"'?""":"'");changes.push({from:location2.startOffset,to:location2.endOffset,text:head+quote+escaped+quote})}if(node2.tagName==="style")for(let child of node2.childNodes){if(!("value"in child))continue;let next=cssReferences(child.value,replace2);if(next===child.value)continue;let location2=child.sourceCodeLocation;if(!location2)throw new Error("Cannot update style content");changes.push({from:location2.startOffset,to:location2.endOffset,text:next})}walk2("content"in node2?node2.content:node2)}};walk2(parseFragment(source2,{sourceCodeLocationInfo:!0}));for(let change of changes.sort((a2,b2)=>b2.from-a2.from))source2=source2.slice(0,change.from)+change.text+source2.slice(change.to);return source2};init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();var fromNumH=n2=>n2/2**32|0,fromNumL=n2=>n2>>>0;function setU64FromNum(view,byteOffset,n2,isLE){let h2=fromNumH(n2),l2=fromNumL(n2);view.setUint32(byteOffset,isLE?l2:h2,isLE),view.setUint32(byteOffset+4,isLE?h2:l2,isLE)}init_browser_globals();function isBytes(a2){return a2 instanceof Uint8Array||ArrayBuffer.isView(a2)&&a2.constructor.name==="Uint8Array"&&"BYTES_PER_ELEMENT"in a2&&a2.BYTES_PER_ELEMENT===1}var atitle=title=>title?`"${title}" `:"";function anumber(n2,title=""){if(typeof n2!="number")throw new TypeError(atitle(title)+"expected number, got "+typeof n2);if(!Number.isSafeInteger(n2)||n2<0)throw new RangeError(atitle(title)+"expected integer >= 0, got "+n2);return n2}function abytes(value2,length,title=""){if(isBytes(value2)&&(length===void 0||value2.length===length))return value2;length!==void 0&&anumber(length,"length");let bytes=isBytes(value2),ofLen=length!==void 0?` of length ${length}`:"",got=bytes?`length=${value2.length}`:`type=${typeof value2}`,message=atitle(title)+"expected Uint8Array"+ofLen+", got "+got;throw bytes?new RangeError(message):new TypeError(message)}var aobject=(value2,label2)=>{if(value2===null||typeof value2!="object"||Array.isArray(value2))throw new TypeError((label2==="object"?"":`"${label2}" `)+"expected object, got type="+typeof value2)},aopts=(value2,label2)=>{aobject(value2,label2);let proto=Object.getPrototypeOf(value2);if(proto!==Object.prototype&&proto!==null)throw new TypeError(`"${label2}" expected plain object`);if(Object.hasOwn(value2,"__proto__"))throw new TypeError(`"${label2}.__proto__" is not allowed`)};function aexists(instance,checkFinished=!0){if(instance.destroyed)throw new Error("hash was destroyed");if(checkFinished&&instance.finished)throw new Error("digest() was already called")}function aoutput(out,instance){abytes(out,void 0,"output");let min=instance.outputLen;if(!(out.length>=min))throw new RangeError('"output" expected length >= '+min)}function clean(...arrays){for(let i2=0;i2<arrays.length;i2++)arrays[i2].fill(0)}function createView(arr){return new DataView(arr.buffer,arr.byteOffset,arr.byteLength)}function rotr(word,shift){return word<<32-shift|word>>>shift}function checkOpts(defaults,opts,title="opts"){return aopts(defaults,"defaults"),opts!==void 0&&aopts(opts,title),Object.assign(Object.create(null),defaults,opts)}function createHasher(hashCons,info={}){if(typeof hashCons!="function")throw new TypeError('"hashCons" expected function, got type='+typeof hashCons);info=checkOpts({},info,"info");let hashC=(msg,opts)=>hashCons(opts).update(msg).digest(),tmp=hashCons(void 0);return hashC.outputLen=tmp.outputLen,hashC.blockLen=tmp.blockLen,hashC.canXOF=tmp.canXOF,hashC.create=opts=>hashCons(opts),Object.assign(hashC,info),Object.freeze(hashC)}var oidNist=suffix=>({oid:Uint8Array.from([6,9,96,134,72,1,101,3,4,2,suffix])});function Chi(a2,b2,c2){return a2&b2^~a2&c2}function Maj(a2,b2,c2){return a2&b2^a2&c2^b2&c2}var HashMD=class{blockLen;outputLen;canXOF=!1;padOffset;isLE;buffer;view;finished=!1;length=0;pos=0;destroyed=!1;constructor(blockLen,outputLen,padOffset,isLE){this.blockLen=blockLen,this.outputLen=outputLen,this.padOffset=padOffset,this.isLE=isLE,this.buffer=new Uint8Array(blockLen),this.view=createView(this.buffer)}update(data){aexists(this),abytes(data);let{view,buffer,blockLen}=this,len=data.length,processed=!1;for(let pos=0;pos<len;){let take=Math.min(blockLen-this.pos,len-pos);if(take===blockLen){let dataView=createView(data);for(;blockLen<=len-pos;pos+=blockLen)this.process(dataView,pos);processed=!0;continue}buffer.set(pos===0&&take===len?data:data.subarray(pos,pos+take),this.pos),this.pos+=take,pos+=take,this.pos===blockLen&&(this.process(view,0),this.pos=0,processed=!0)}return this.length+=data.length,processed&&this.roundClean(),this}digestInto(out){aexists(this),aoutput(out,this),this.finished=!0;let{buffer,view,blockLen,isLE}=this,{pos}=this;buffer[pos++]=128,buffer.fill(0,pos),this.padOffset>blockLen-pos&&(this.process(view,0),buffer.fill(0)),setU64FromNum(view,blockLen-8,this.length*8,isLE),this.process(view,0),this.roundClean();let oview=out===buffer?view:createView(out),len=this.outputLen,outLen=len/4,state=this.get();if(len%4||outLen>state.length)throw new Error("invalid outputLen");for(let i2=0;i2<outLen;i2++)oview.setUint32(4*i2,state[i2],isLE)}digest(){let{buffer,outputLen}=this;this.digestInto(buffer);let res=buffer.slice(0,outputLen);return this.destroy(),res}_cloneIntoMeta(to){let{buffer,length,finished,destroyed,pos}=this;return to.destroyed=destroyed,to.finished=finished,to.length=length,to.pos=pos,pos&&to.buffer.set(buffer),to}clone(){return this._cloneInto()}},SHA256_IV=Uint32Array.from([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]);var SHA256_K=Uint32Array.from([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),SHA256_W=new Uint32Array(64),SHA2_32B=class extends HashMD{A=0;B=0;C=0;D=0;E=0;F=0;G=0;H=0;constructor(outputLen,IV){super(64,outputLen,8,!1),this.A=IV[0]|0,this.B=IV[1]|0,this.C=IV[2]|0,this.D=IV[3]|0,this.E=IV[4]|0,this.F=IV[5]|0,this.G=IV[6]|0,this.H=IV[7]|0}get(){let{A:A3,B,C:C2,D:D2,E,F,G,H:H2}=this;return[A3,B,C2,D2,E,F,G,H2]}set(A3,B,C2,D2,E,F,G,H2){this.A=A3|0,this.B=B|0,this.C=C2|0,this.D=D2|0,this.E=E|0,this.F=F|0,this.G=G|0,this.H=H2|0}_cloneInto(to){return(to||=new this.constructor).set(...this.get()),this._cloneIntoMeta(to)}process(view,offset){for(let i2=0;i2<16;i2++,offset+=4)SHA256_W[i2]=view.getUint32(offset,!1);for(let i2=16;i2<64;i2++){let W15=SHA256_W[i2-15],W2=SHA256_W[i2-2],s0=rotr(W15,7)^rotr(W15,18)^W15>>>3,s1=rotr(W2,17)^rotr(W2,19)^W2>>>10;SHA256_W[i2]=s1+SHA256_W[i2-7]+s0+SHA256_W[i2-16]|0}let{A:A3,B,C:C2,D:D2,E,F,G,H:H2}=this;for(let i2=0;i2<64;i2++){let sigma1=rotr(E,6)^rotr(E,11)^rotr(E,25),T1=H2+sigma1+Chi(E,F,G)+SHA256_K[i2]+SHA256_W[i2]|0,T2=(rotr(A3,2)^rotr(A3,13)^rotr(A3,22))+Maj(A3,B,C2)|0;H2=G,G=F,F=E,E=D2+T1|0,D2=C2,C2=B,B=A3,A3=T1+T2|0}A3=A3+this.A|0,B=B+this.B|0,C2=C2+this.C|0,D2=D2+this.D|0,E=E+this.E|0,F=F+this.F|0,G=G+this.G|0,H2=H2+this.H|0,this.set(A3,B,C2,D2,E,F,G,H2)}roundClean(){clean(SHA256_W)}destroy(){this.destroyed=!0,this.set(0,0,0,0,0,0,0,0),clean(this.buffer)}},_SHA256=class extends SHA2_32B{constructor(){super(32,SHA256_IV)}};var sha256=createHasher(()=>new _SHA256,oidNist(1));var import_buffer2=__toESM(require_buffer(),1);var import_memfs=__toESM(require_lib11(),1),import_path_browserify2=__toESM(require_path_browserify(),1);init_browser_url();var{existsSync,linkSync,lstatSync,mkdirSync,readdirSync,readFileSync,realpathSync,renameSync,rmdirSync,rmSync,statSync,unlinkSync,writeFileSync}=import_memfs.fs,{open,readFile,stat}=import_memfs.fs.promises,{basename:basename3,dirname:dirname3,extname:extname2,isAbsolute:isAbsolute2,join:join4,posix,relative,resolve,sep}=import_path_browserify2.default,randomUUID=()=>crypto.randomUUID(),createHash=algorithm=>{if(algorithm!=="sha256")throw new Error(`Unsupported hash: ${algorithm}`);let digest=sha256.create(),hash={update(value2){return digest.update(typeof value2=="string"?new TextEncoder().encode(value2):value2),hash},digest(encoding){return import_buffer2.Buffer.from(digest.digest()).toString(encoding)}};return hash},isDeepStrictEqual=(left,right)=>{if(Object.is(left,right))return!0;if(!left||!right||typeof left!="object"||typeof right!="object"||Array.isArray(left)!==Array.isArray(right))return!1;let keys=Object.keys(left);return keys.length===Object.keys(right).length&&keys.every(key=>Object.hasOwn(right,key)&&isDeepStrictEqual(left[key],right[key]))};var execFileSync=()=>{throw Object.assign(new Error("External commands require the Node server"),{code:"ENOENT"})},execFile=execFileSync,spawnSync=()=>({status:null,stdout:"",stderr:"",error:Object.assign(new Error("Git runs in the workspace adapter"),{code:"ENOENT"})}),runInNewContext=(code4,context)=>{if(code4!=="render()")throw new Error("Only the built-in geometry renderer is supported");return context.render()};async function fetchPublicFile(url,validate2){let parsed2=new URL(url);if(parsed2.protocol!=="https:"||parsed2.username||parsed2.password||parsed2.port||!parsed2.hostname.includes(".")||/^(?:[\d.]+|\[.*\])$/.test(parsed2.hostname)||/(?:^|\.)(?:local|localhost)$/.test(parsed2.hostname))throw new Error("Expected a public HTTPS URL without credentials");let response=await fetch(parsed2,{credentials:"omit",redirect:"error",referrerPolicy:"no-referrer",signal:AbortSignal.timeout(12e3)});if(!response.ok)throw new Error(response.status===404?"NOT_FOUND":"Could not load file");validate2?.(response.headers.get("content-type")??"");let reader=response.body?.getReader();if(!reader)throw new Error("Empty response");let chunks=[],size=0;try{for(;;){let{value:value2,done}=await reader.read();if(done)break;if(size+=value2.length,size>2*1024*1024)throw new Error("File exceeds 2 MiB");chunks.push(value2)}}finally{await reader.cancel()}return import_buffer2.Buffer.concat(chunks)}var fileSig=path4=>{let st2;try{st2=statSync(path4)}catch{return"-"}return`${st2.mtimeMs}:${st2.size}`},createFileCache=()=>{let store=new Map;return{get:(path4,compute)=>{let raw=readFileSync(path4,"utf8"),hit=store.get(path4);if(hit?.raw===raw)return hit.value;let value2=compute(raw);return store.set(path4,{raw,value:value2}),value2}}},createSigCache=()=>{let hit;return{get:(sig,compute)=>(hit?.sig!==sig&&(hit={sig,value:compute()}),hit.value)}},dirSig=(dir,fileOf=n2=>n2)=>{let names2;try{names2=readdirSync(dir).sort()}catch{return"-"}return names2.map(n2=>`${n2}:${fileSig(join4(dir,fileOf(n2)))}`).join("|")};init_browser_globals();var import_ignore2=__toESM(require_ignore2(),1);var cached,scope,withIgnoredFilesCache=read=>{if(cached)return read();cached=new Map,scope=new Map;try{return read()}finally{cached=void 0,scope=void 0}},withinRead=(key,read)=>scope?(scope.has(key)||scope.set(key,read()),scope.get(key)):read(),ignoredFiles=(root4,files)=>{if(!cached)return readIgnoredFiles(root4,files);let key=resolve(root4),known=cached.get(key);known||(known=new Map,cached.set(key,known));let missing=[...new Set(files.filter(file=>!known.has(file)))];if(missing.length){let ignored=readIgnoredFiles(root4,missing);for(let file of missing)known.set(file,ignored.has(file))}return new Set(files.filter(file=>known.get(file)))},readIgnoredFiles=(root4,files)=>{if(!files.length)return new Set;let hasGit=directory2=>existsSync(join4(directory2,".git","HEAD"))||statSync(join4(directory2,".git"),{throwIfNoEntry:!1})?.isFile(),repository2=resolve(root4);for(;!hasGit(repository2)&&dirname3(repository2)!==repository2;)repository2=dirname3(repository2);let inRepository=hasGit(repository2);if(inRepository){let result=spawnSync("git",["-C",root4,"check-ignore","--stdin","-z"],{input:`${files.join("\0")}\0`,encoding:"utf8",timeout:2e3,maxBuffer:5e6,windowsHide:!0});if(result.status===0||result.status===1)return new Set(result.stdout.split("\0").filter(Boolean));if(result.error?.code!=="ENOENT")throw new Error(`Cannot check ignored files: ${result.error?.message??result.stderr.trim()}`)}let ignoreRoot=inRepository?repository2:root4,prefix=relative(ignoreRoot,root4).split(sep).join("/"),rules=new Map,readRules=directory2=>{let matcher=rules.get(directory2);if(!matcher){let path4=join4(ignoreRoot,directory2,".gitignore");matcher=(0,import_ignore2.default)().add(existsSync(path4)?readFileSync(path4,"utf8"):""),rules.set(directory2,matcher)}return matcher};return new Set(files.filter(file=>{let parts=posix.join(prefix,file).replace(/\/$/,"").split("/"),matchers=[];for(let i2=0;i2<parts.length;i2++){let directory2=parts.slice(0,i2).join("/");matchers.push(readRules(directory2));let ignored=!1;for(let[base2,matcher]of matchers.entries()){let path4=parts.slice(base2,i2+1).join("/")+(i2<parts.length-1||file.endsWith("/")?"/":""),result=matcher.test(path4);(result.ignored||result.unignored)&&(ignored=result.ignored)}if(ignored)return!0}return!1}))},assertNotIgnored=(root4,file)=>{let path4=join4(root4,file),resolved=existsSync(path4)?relative(realpathSync(root4),realpathSync(path4)).split(sep).join("/"):file;if(ignoredFiles(root4,[...new Set([file,resolved])]).size)throw new Error(`Referenced file is ignored by Git ignore rules: ${file}`)};init_browser_globals();init_browser_globals();var contentLanguages=iso6393.map(({iso6393:code4,name})=>({code:code4,name})).sort((a2,b2)=>a2.name.localeCompare(b2.name)),codes=new Map(iso6393.map(language=>[language.iso6393,language.name])),webLanguage=code4=>iso6393To1[code4]??code4;init_browser_globals();var manifests=new Map,parsed=createFileCache(),manifestFile=root4=>manifests.get(resolve(root4))??MANIFEST_FILE,projectRoot=(input=MANIFEST_FILE)=>{let file=resolve(input);if(!isManifestFile(basename3(file))||!existsSync(file)||!statSync(file).isFile())throw new Error(`Specify an existing dooc.yaml or <name>.dooc.yaml file: ${file}`);let root4=dirname3(file);return manifests.set(root4,basename3(file)),root4},parseManifestText=(raw,file=MANIFEST_FILE)=>{let value2;try{value2=parse2(raw)}catch(e2){return{tree:[],errors:[`${file}: invalid YAML (${e2 instanceof Error?e2.message:e2})`]}}let manifest2=parseManifest(value2);return manifest2.errors=manifest2.errors.map(error=>error.replace(/^dooc\.yaml(?=:)/,()=>file)),manifest2},readManifest=root4=>{let file=manifestFile(root4),path4=join4(root4,file);return existsSync(path4)?structuredClone(parsed.get(path4,raw=>parseManifestText(raw,file))):{tree:[],errors:[]}},writeManifest=(root4,tree,metadata={})=>{writeFileSync(join4(root4,manifestFile(root4)),serializeManifest(tree,metadata))};init_browser_globals();init_browser_globals();var TextfileUnavailable=class extends Error{constructor(reason){super(reason==="missing"?"File not found":"File could not be loaded");this.reason=reason}reason},MAX_BYTES=2*1024*1024,FETCH=`
|
|
392
|
+
`));return source2.trim()||parsed2.errors.push({line:0,message:"schema is empty"}),{blocks:[{type:"schemaGraph",source:source2,graph:parsed2.model,...caption?{caption}:{}}],errors:parsed2.errors}}if(language==="graphth"){let parsed2=parseGraphSource(source2);return source2.trim()||parsed2.errors.push({line:0,message:"graph is empty"}),{blocks:[{type:"graph",source:source2,graph:parsed2.model,...caption?{caption}:{}}],errors:parsed2.errors}}if(language==="termth"){let parsed2=parseTermSource(id,source2);return{blocks:parsed2.entries.map(entry=>({type:"term",entry})),errors:parsed2.errors}}},parseContentCode=(node2,raw,file="inline")=>{if(!node2.lang||!Object.hasOwn(CODE_TEMPLATES,node2.lang))return;let errors=[],slice=raw.slice(node2.position?.start.offset,node2.position?.end.offset),opening=/^(`{3,}|~{3,})/.exec(slice)?.[1],closing=/\n {0,3}(`{3,}|~{3,})[ \t]*$/.exec(slice)?.[1];(!opening||!closing||closing[0]!==opening[0]||closing.length<opening.length)&&errors.push({line:-1,message:"close the code fence"}),node2.lang==="termth"&&node2.meta&&errors.push({line:-1,message:"termth takes no ID; write name and definition as YAML"});let parsed2=parseContentSource(node2.lang,node2.value,`${file}#L${node2.position?.start.line??1}`,node2.meta?.trim());return{blocks:parsed2?.blocks??[],errors:[...errors,...parsed2?.errors??[]]}};var ALLOWED_TYPES=new Set(["root","yaml","paragraph","heading","list","listItem","code","inlineCode","table","tableRow","tableCell","text","link","image","strong","emphasis","blockquote"]),line=n2=>n2.position?`L${n2.position.start.line}`:"L?",checkListItem=(n2,errors)=>{for(let child of n2.children)child.type!=="paragraph"&&child.type!=="list"&&child.type!=="blockquote"&&errors.push(`${line(child)}: ${child.type} is not allowed directly under listItem (paragraph / list / quote only)`)},checkLink=(n2,errors)=>{isReferenceUrl(n2.url)||errors.push(`${line(n2)}: links require a local reference, HTTP(S) URL or email address`);try{parseDocLink(n2.url),parseFigureLink(n2.url),parseTermReference(n2.url)}catch(error){errors.push(`${line(n2)}: ${error instanceof Error?error.message:error}`)}n2.url.startsWith("doc:")&&errors.push(`${line(n2)}: use a Markdown file link instead of doc:`),n2.url===""&&errors.push(`${line(n2)}: link with an empty URL`)},parseDoc=(input,settings,file)=>{let errors=[],raw=input,root4=parseMdast(raw),embeds=new Set(embeddedImages(root4)),terms=[];root4.children[0]?.type==="yaml"&&errors.push("front-matter (---) is not supported; set the title in dooc.yaml");let body=input;return visit(root4,(node2,_index,parent)=>{if(node2.type==="text"&&/(?:^|\n)[ \t]*:{2,}[a-z]+\b/.test(raw.slice(node2.position?.start.offset,node2.position?.end.offset))&&errors.push(`${line(node2)}: removed directive; use Markdown file links or callouth / schemath / graphth / termth code fences`),!ALLOWED_TYPES.has(node2.type)){let hint=node2.type==="html"?' (put "<" inside backticks or escape it as "\\<")':"";errors.push(`${line(node2)}: ${node2.type} is outside the dialect${hint}`);return}switch(node2.type){case"code":{let parsed2=parseContentCode(node2,raw,file);if(!parsed2)break;if(parent?.type!=="root"){errors.push(`${line(node2)}: ${node2.lang} must be a top-level code block`);break}for(let error of parsed2.errors)errors.push(`L${(node2.position?.start.line??0)+1+error.line}: ${node2.lang} ${error.message}`);for(let block of parsed2.blocks)block.type==="term"&&terms.push(block.entry);break}case"image":{if(!embeds.has(node2)){errors.push(`${line(node2)}: file previews must occupy a standalone paragraph`);break}try{let{range}=parseFileEmbed(node2.url,settings);range!==void 0&&parseTextfileRange(range)}catch(error){errors.push(`${line(node2)}: ${error instanceof Error?error.message:error}`)}break}case"listItem":checkListItem(node2,errors);break;case"link":checkLink(node2,errors);break;default:break}}),{body,source:raw,root:root4,errors,terms}},collectRefs=(root4,settings)=>{let figures=[],terms=[],textfiles=[];for(let image2 of embeddedImages(root4))try{let{file,kind}=parseFileEmbed(image2.url,settings);kind==="textfile"?textfiles.push(file):kind!=="external"&&figures.push(file)}catch{}for(let node2 of contentLinks(root4))try{let file=parseTermReference(node2.url);file&&terms.push(file);let figure=parseFigureLink(node2.url);figure&&figures.push(figure.file)}catch{}return{figures:[...new Set(figures)],terms:[...new Set(terms)],textfiles:[...new Set(textfiles)]}};init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();var UNDEFINED_CODE_POINTS=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),REPLACEMENT_CHARACTER="\uFFFD",CODE_POINTS;(function(CODE_POINTS2){CODE_POINTS2[CODE_POINTS2.EOF=-1]="EOF",CODE_POINTS2[CODE_POINTS2.NULL=0]="NULL",CODE_POINTS2[CODE_POINTS2.TABULATION=9]="TABULATION",CODE_POINTS2[CODE_POINTS2.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",CODE_POINTS2[CODE_POINTS2.LINE_FEED=10]="LINE_FEED",CODE_POINTS2[CODE_POINTS2.FORM_FEED=12]="FORM_FEED",CODE_POINTS2[CODE_POINTS2.SPACE=32]="SPACE",CODE_POINTS2[CODE_POINTS2.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",CODE_POINTS2[CODE_POINTS2.QUOTATION_MARK=34]="QUOTATION_MARK",CODE_POINTS2[CODE_POINTS2.AMPERSAND=38]="AMPERSAND",CODE_POINTS2[CODE_POINTS2.APOSTROPHE=39]="APOSTROPHE",CODE_POINTS2[CODE_POINTS2.HYPHEN_MINUS=45]="HYPHEN_MINUS",CODE_POINTS2[CODE_POINTS2.SOLIDUS=47]="SOLIDUS",CODE_POINTS2[CODE_POINTS2.DIGIT_0=48]="DIGIT_0",CODE_POINTS2[CODE_POINTS2.DIGIT_9=57]="DIGIT_9",CODE_POINTS2[CODE_POINTS2.SEMICOLON=59]="SEMICOLON",CODE_POINTS2[CODE_POINTS2.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",CODE_POINTS2[CODE_POINTS2.EQUALS_SIGN=61]="EQUALS_SIGN",CODE_POINTS2[CODE_POINTS2.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",CODE_POINTS2[CODE_POINTS2.QUESTION_MARK=63]="QUESTION_MARK",CODE_POINTS2[CODE_POINTS2.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",CODE_POINTS2[CODE_POINTS2.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",CODE_POINTS2[CODE_POINTS2.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",CODE_POINTS2[CODE_POINTS2.GRAVE_ACCENT=96]="GRAVE_ACCENT",CODE_POINTS2[CODE_POINTS2.LATIN_SMALL_A=97]="LATIN_SMALL_A",CODE_POINTS2[CODE_POINTS2.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(CODE_POINTS||(CODE_POINTS={}));var SEQUENCES={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function isSurrogate(cp){return cp>=55296&&cp<=57343}function isSurrogatePair(cp){return cp>=56320&&cp<=57343}function getSurrogatePairCodePoint(cp1,cp2){return(cp1-55296)*1024+9216+cp2}function isControlCodePoint(cp){return cp!==32&&cp!==10&&cp!==13&&cp!==9&&cp!==12&&cp>=1&&cp<=31||cp>=127&&cp<=159}function isUndefinedCodePoint(cp){return cp>=64976&&cp<=65007||UNDEFINED_CODE_POINTS.has(cp)}init_browser_globals();var ERR;(function(ERR2){ERR2.controlCharacterInInputStream="control-character-in-input-stream",ERR2.noncharacterInInputStream="noncharacter-in-input-stream",ERR2.surrogateInInputStream="surrogate-in-input-stream",ERR2.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",ERR2.endTagWithAttributes="end-tag-with-attributes",ERR2.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",ERR2.unexpectedSolidusInTag="unexpected-solidus-in-tag",ERR2.unexpectedNullCharacter="unexpected-null-character",ERR2.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",ERR2.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",ERR2.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",ERR2.missingEndTagName="missing-end-tag-name",ERR2.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",ERR2.unknownNamedCharacterReference="unknown-named-character-reference",ERR2.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",ERR2.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",ERR2.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",ERR2.eofBeforeTagName="eof-before-tag-name",ERR2.eofInTag="eof-in-tag",ERR2.missingAttributeValue="missing-attribute-value",ERR2.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",ERR2.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",ERR2.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",ERR2.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",ERR2.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",ERR2.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",ERR2.missingDoctypePublicIdentifier="missing-doctype-public-identifier",ERR2.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",ERR2.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",ERR2.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",ERR2.cdataInHtmlContent="cdata-in-html-content",ERR2.incorrectlyOpenedComment="incorrectly-opened-comment",ERR2.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",ERR2.eofInDoctype="eof-in-doctype",ERR2.nestedComment="nested-comment",ERR2.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",ERR2.eofInComment="eof-in-comment",ERR2.incorrectlyClosedComment="incorrectly-closed-comment",ERR2.eofInCdata="eof-in-cdata",ERR2.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",ERR2.nullCharacterReference="null-character-reference",ERR2.surrogateCharacterReference="surrogate-character-reference",ERR2.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",ERR2.controlCharacterReference="control-character-reference",ERR2.noncharacterCharacterReference="noncharacter-character-reference",ERR2.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",ERR2.missingDoctypeName="missing-doctype-name",ERR2.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",ERR2.duplicateAttribute="duplicate-attribute",ERR2.nonConformingDoctype="non-conforming-doctype",ERR2.missingDoctype="missing-doctype",ERR2.misplacedDoctype="misplaced-doctype",ERR2.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",ERR2.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",ERR2.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",ERR2.openElementsLeftAfterEof="open-elements-left-after-eof",ERR2.abandonedHeadElementChild="abandoned-head-element-child",ERR2.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",ERR2.nestedNoscriptInHead="nested-noscript-in-head",ERR2.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(ERR||(ERR={}));var DEFAULT_BUFFER_WATERLINE=65536,Preprocessor=class{constructor(handler2){this.handler=handler2,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=DEFAULT_BUFFER_WATERLINE,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(code4,cpOffset){let{line:line2,col,offset}=this,startCol=col+cpOffset,startOffset=offset+cpOffset;return{code:code4,startLine:line2,endLine:line2,startCol,endCol:startCol,startOffset,endOffset:startOffset}}_err(code4){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(code4,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(cp){if(this.pos!==this.html.length-1){let nextCp=this.html.charCodeAt(this.pos+1);if(isSurrogatePair(nextCp))return this.pos++,this._addGap(),getSurrogatePairCodePoint(cp,nextCp)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,CODE_POINTS.EOF;return this._err(ERR.surrogateInInputStream),cp}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(chunk,isLastChunk){this.html.length>0?this.html+=chunk:this.html=chunk,this.endOfChunkHit=!1,this.lastChunkWritten=isLastChunk}insertHtmlAtCurrentPos(chunk){this.html=this.html.substring(0,this.pos+1)+chunk+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(pattern,caseSensitive){if(this.pos+pattern.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(caseSensitive)return this.html.startsWith(pattern,this.pos);for(let i2=0;i2<pattern.length;i2++)if((this.html.charCodeAt(this.pos+i2)|32)!==pattern.charCodeAt(i2))return!1;return!0}peek(offset){let pos=this.pos+offset;if(pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,CODE_POINTS.EOF;let code4=this.html.charCodeAt(pos);return code4===CODE_POINTS.CARRIAGE_RETURN?CODE_POINTS.LINE_FEED:code4}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,CODE_POINTS.EOF;let cp=this.html.charCodeAt(this.pos);return cp===CODE_POINTS.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,CODE_POINTS.LINE_FEED):cp===CODE_POINTS.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,isSurrogate(cp)&&(cp=this._processSurrogate(cp)),this.handler.onParseError===null||cp>31&&cp<127||cp===CODE_POINTS.LINE_FEED||cp===CODE_POINTS.CARRIAGE_RETURN||cp>159&&cp<64976||this._checkForProblematicCharacters(cp),cp)}_checkForProblematicCharacters(cp){isControlCodePoint(cp)?this._err(ERR.controlCharacterInInputStream):isUndefinedCodePoint(cp)&&this._err(ERR.noncharacterInInputStream)}retreat(count){for(this.pos-=count;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}};init_browser_globals();var TokenType;(function(TokenType2){TokenType2[TokenType2.CHARACTER=0]="CHARACTER",TokenType2[TokenType2.NULL_CHARACTER=1]="NULL_CHARACTER",TokenType2[TokenType2.WHITESPACE_CHARACTER=2]="WHITESPACE_CHARACTER",TokenType2[TokenType2.START_TAG=3]="START_TAG",TokenType2[TokenType2.END_TAG=4]="END_TAG",TokenType2[TokenType2.COMMENT=5]="COMMENT",TokenType2[TokenType2.DOCTYPE=6]="DOCTYPE",TokenType2[TokenType2.EOF=7]="EOF",TokenType2[TokenType2.HIBERNATION=8]="HIBERNATION"})(TokenType||(TokenType={}));function getTokenAttr(token,attrName){for(let i2=token.attrs.length-1;i2>=0;i2--)if(token.attrs[i2].name===attrName)return token.attrs[i2].value;return null}init_browser_globals();init_browser_globals();var htmlDecodeTree=new Uint16Array('\u1D41<\xD5\u0131\u028A\u049D\u057B\u05D0\u0675\u06DE\u07A2\u07D6\u080F\u0A4A\u0A91\u0DA1\u0E6D\u0F09\u0F26\u10CA\u1228\u12E1\u1415\u149D\u14C3\u14DF\u1525\0\0\0\0\0\0\u156B\u16CD\u198D\u1C12\u1DDD\u1F7E\u2060\u21B0\u228D\u23C0\u23FB\u2442\u2824\u2912\u2D08\u2E48\u2FCE\u3016\u32BA\u3639\u37AC\u38FE\u3A28\u3A71\u3AE0\u3B2E\u0800EMabcfglmnoprstu\\bfms\x7F\x84\x8B\x90\x95\x98\xA6\xB3\xB9\xC8\xCFlig\u803B\xC6\u40C6P\u803B&\u4026cute\u803B\xC1\u40C1reve;\u4102\u0100iyx}rc\u803B\xC2\u40C2;\u4410r;\uC000\u{1D504}rave\u803B\xC0\u40C0pha;\u4391acr;\u4100d;\u6A53\u0100gp\x9D\xA1on;\u4104f;\uC000\u{1D538}plyFunction;\u6061ing\u803B\xC5\u40C5\u0100cs\xBE\xC3r;\uC000\u{1D49C}ign;\u6254ilde\u803B\xC3\u40C3ml\u803B\xC4\u40C4\u0400aceforsu\xE5\xFB\xFE\u0117\u011C\u0122\u0127\u012A\u0100cr\xEA\xF2kslash;\u6216\u0176\xF6\xF8;\u6AE7ed;\u6306y;\u4411\u0180crt\u0105\u010B\u0114ause;\u6235noullis;\u612Ca;\u4392r;\uC000\u{1D505}pf;\uC000\u{1D539}eve;\u42D8c\xF2\u0113mpeq;\u624E\u0700HOacdefhilorsu\u014D\u0151\u0156\u0180\u019E\u01A2\u01B5\u01B7\u01BA\u01DC\u0215\u0273\u0278\u027Ecy;\u4427PY\u803B\xA9\u40A9\u0180cpy\u015D\u0162\u017Aute;\u4106\u0100;i\u0167\u0168\u62D2talDifferentialD;\u6145leys;\u612D\u0200aeio\u0189\u018E\u0194\u0198ron;\u410Cdil\u803B\xC7\u40C7rc;\u4108nint;\u6230ot;\u410A\u0100dn\u01A7\u01ADilla;\u40B8terDot;\u40B7\xF2\u017Fi;\u43A7rcle\u0200DMPT\u01C7\u01CB\u01D1\u01D6ot;\u6299inus;\u6296lus;\u6295imes;\u6297o\u0100cs\u01E2\u01F8kwiseContourIntegral;\u6232eCurly\u0100DQ\u0203\u020FoubleQuote;\u601Duote;\u6019\u0200lnpu\u021E\u0228\u0247\u0255on\u0100;e\u0225\u0226\u6237;\u6A74\u0180git\u022F\u0236\u023Aruent;\u6261nt;\u622FourIntegral;\u622E\u0100fr\u024C\u024E;\u6102oduct;\u6210nterClockwiseContourIntegral;\u6233oss;\u6A2Fcr;\uC000\u{1D49E}p\u0100;C\u0284\u0285\u62D3ap;\u624D\u0580DJSZacefios\u02A0\u02AC\u02B0\u02B4\u02B8\u02CB\u02D7\u02E1\u02E6\u0333\u048D\u0100;o\u0179\u02A5trahd;\u6911cy;\u4402cy;\u4405cy;\u440F\u0180grs\u02BF\u02C4\u02C7ger;\u6021r;\u61A1hv;\u6AE4\u0100ay\u02D0\u02D5ron;\u410E;\u4414l\u0100;t\u02DD\u02DE\u6207a;\u4394r;\uC000\u{1D507}\u0100af\u02EB\u0327\u0100cm\u02F0\u0322ritical\u0200ADGT\u0300\u0306\u0316\u031Ccute;\u40B4o\u0174\u030B\u030D;\u42D9bleAcute;\u42DDrave;\u4060ilde;\u42DCond;\u62C4ferentialD;\u6146\u0470\u033D\0\0\0\u0342\u0354\0\u0405f;\uC000\u{1D53B}\u0180;DE\u0348\u0349\u034D\u40A8ot;\u60DCqual;\u6250ble\u0300CDLRUV\u0363\u0372\u0382\u03CF\u03E2\u03F8ontourIntegra\xEC\u0239o\u0274\u0379\0\0\u037B\xBB\u0349nArrow;\u61D3\u0100eo\u0387\u03A4ft\u0180ART\u0390\u0396\u03A1rrow;\u61D0ightArrow;\u61D4e\xE5\u02CAng\u0100LR\u03AB\u03C4eft\u0100AR\u03B3\u03B9rrow;\u67F8ightArrow;\u67FAightArrow;\u67F9ight\u0100AT\u03D8\u03DErrow;\u61D2ee;\u62A8p\u0241\u03E9\0\0\u03EFrrow;\u61D1ownArrow;\u61D5erticalBar;\u6225n\u0300ABLRTa\u0412\u042A\u0430\u045E\u047F\u037Crrow\u0180;BU\u041D\u041E\u0422\u6193ar;\u6913pArrow;\u61F5reve;\u4311eft\u02D2\u043A\0\u0446\0\u0450ightVector;\u6950eeVector;\u695Eector\u0100;B\u0459\u045A\u61BDar;\u6956ight\u01D4\u0467\0\u0471eeVector;\u695Fector\u0100;B\u047A\u047B\u61C1ar;\u6957ee\u0100;A\u0486\u0487\u62A4rrow;\u61A7\u0100ct\u0492\u0497r;\uC000\u{1D49F}rok;\u4110\u0800NTacdfglmopqstux\u04BD\u04C0\u04C4\u04CB\u04DE\u04E2\u04E7\u04EE\u04F5\u0521\u052F\u0536\u0552\u055D\u0560\u0565G;\u414AH\u803B\xD0\u40D0cute\u803B\xC9\u40C9\u0180aiy\u04D2\u04D7\u04DCron;\u411Arc\u803B\xCA\u40CA;\u442Dot;\u4116r;\uC000\u{1D508}rave\u803B\xC8\u40C8ement;\u6208\u0100ap\u04FA\u04FEcr;\u4112ty\u0253\u0506\0\0\u0512mallSquare;\u65FBerySmallSquare;\u65AB\u0100gp\u0526\u052Aon;\u4118f;\uC000\u{1D53C}silon;\u4395u\u0100ai\u053C\u0549l\u0100;T\u0542\u0543\u6A75ilde;\u6242librium;\u61CC\u0100ci\u0557\u055Ar;\u6130m;\u6A73a;\u4397ml\u803B\xCB\u40CB\u0100ip\u056A\u056Fsts;\u6203onentialE;\u6147\u0280cfios\u0585\u0588\u058D\u05B2\u05CCy;\u4424r;\uC000\u{1D509}lled\u0253\u0597\0\0\u05A3mallSquare;\u65FCerySmallSquare;\u65AA\u0370\u05BA\0\u05BF\0\0\u05C4f;\uC000\u{1D53D}All;\u6200riertrf;\u6131c\xF2\u05CB\u0600JTabcdfgorst\u05E8\u05EC\u05EF\u05FA\u0600\u0612\u0616\u061B\u061D\u0623\u066C\u0672cy;\u4403\u803B>\u403Emma\u0100;d\u05F7\u05F8\u4393;\u43DCreve;\u411E\u0180eiy\u0607\u060C\u0610dil;\u4122rc;\u411C;\u4413ot;\u4120r;\uC000\u{1D50A};\u62D9pf;\uC000\u{1D53E}eater\u0300EFGLST\u0635\u0644\u064E\u0656\u065B\u0666qual\u0100;L\u063E\u063F\u6265ess;\u62DBullEqual;\u6267reater;\u6AA2ess;\u6277lantEqual;\u6A7Eilde;\u6273cr;\uC000\u{1D4A2};\u626B\u0400Aacfiosu\u0685\u068B\u0696\u069B\u069E\u06AA\u06BE\u06CARDcy;\u442A\u0100ct\u0690\u0694ek;\u42C7;\u405Eirc;\u4124r;\u610ClbertSpace;\u610B\u01F0\u06AF\0\u06B2f;\u610DizontalLine;\u6500\u0100ct\u06C3\u06C5\xF2\u06A9rok;\u4126mp\u0144\u06D0\u06D8ownHum\xF0\u012Fqual;\u624F\u0700EJOacdfgmnostu\u06FA\u06FE\u0703\u0707\u070E\u071A\u071E\u0721\u0728\u0744\u0778\u078B\u078F\u0795cy;\u4415lig;\u4132cy;\u4401cute\u803B\xCD\u40CD\u0100iy\u0713\u0718rc\u803B\xCE\u40CE;\u4418ot;\u4130r;\u6111rave\u803B\xCC\u40CC\u0180;ap\u0720\u072F\u073F\u0100cg\u0734\u0737r;\u412AinaryI;\u6148lie\xF3\u03DD\u01F4\u0749\0\u0762\u0100;e\u074D\u074E\u622C\u0100gr\u0753\u0758ral;\u622Bsection;\u62C2isible\u0100CT\u076C\u0772omma;\u6063imes;\u6062\u0180gpt\u077F\u0783\u0788on;\u412Ef;\uC000\u{1D540}a;\u4399cr;\u6110ilde;\u4128\u01EB\u079A\0\u079Ecy;\u4406l\u803B\xCF\u40CF\u0280cfosu\u07AC\u07B7\u07BC\u07C2\u07D0\u0100iy\u07B1\u07B5rc;\u4134;\u4419r;\uC000\u{1D50D}pf;\uC000\u{1D541}\u01E3\u07C7\0\u07CCr;\uC000\u{1D4A5}rcy;\u4408kcy;\u4404\u0380HJacfos\u07E4\u07E8\u07EC\u07F1\u07FD\u0802\u0808cy;\u4425cy;\u440Cppa;\u439A\u0100ey\u07F6\u07FBdil;\u4136;\u441Ar;\uC000\u{1D50E}pf;\uC000\u{1D542}cr;\uC000\u{1D4A6}\u0580JTaceflmost\u0825\u0829\u082C\u0850\u0863\u09B3\u09B8\u09C7\u09CD\u0A37\u0A47cy;\u4409\u803B<\u403C\u0280cmnpr\u0837\u083C\u0841\u0844\u084Dute;\u4139bda;\u439Bg;\u67EAlacetrf;\u6112r;\u619E\u0180aey\u0857\u085C\u0861ron;\u413Ddil;\u413B;\u441B\u0100fs\u0868\u0970t\u0500ACDFRTUVar\u087E\u08A9\u08B1\u08E0\u08E6\u08FC\u092F\u095B\u0390\u096A\u0100nr\u0883\u088FgleBracket;\u67E8row\u0180;BR\u0899\u089A\u089E\u6190ar;\u61E4ightArrow;\u61C6eiling;\u6308o\u01F5\u08B7\0\u08C3bleBracket;\u67E6n\u01D4\u08C8\0\u08D2eeVector;\u6961ector\u0100;B\u08DB\u08DC\u61C3ar;\u6959loor;\u630Aight\u0100AV\u08EF\u08F5rrow;\u6194ector;\u694E\u0100er\u0901\u0917e\u0180;AV\u0909\u090A\u0910\u62A3rrow;\u61A4ector;\u695Aiangle\u0180;BE\u0924\u0925\u0929\u62B2ar;\u69CFqual;\u62B4p\u0180DTV\u0937\u0942\u094CownVector;\u6951eeVector;\u6960ector\u0100;B\u0956\u0957\u61BFar;\u6958ector\u0100;B\u0965\u0966\u61BCar;\u6952ight\xE1\u039Cs\u0300EFGLST\u097E\u098B\u0995\u099D\u09A2\u09ADqualGreater;\u62DAullEqual;\u6266reater;\u6276ess;\u6AA1lantEqual;\u6A7Dilde;\u6272r;\uC000\u{1D50F}\u0100;e\u09BD\u09BE\u62D8ftarrow;\u61DAidot;\u413F\u0180npw\u09D4\u0A16\u0A1Bg\u0200LRlr\u09DE\u09F7\u0A02\u0A10eft\u0100AR\u09E6\u09ECrrow;\u67F5ightArrow;\u67F7ightArrow;\u67F6eft\u0100ar\u03B3\u0A0Aight\xE1\u03BFight\xE1\u03CAf;\uC000\u{1D543}er\u0100LR\u0A22\u0A2CeftArrow;\u6199ightArrow;\u6198\u0180cht\u0A3E\u0A40\u0A42\xF2\u084C;\u61B0rok;\u4141;\u626A\u0400acefiosu\u0A5A\u0A5D\u0A60\u0A77\u0A7C\u0A85\u0A8B\u0A8Ep;\u6905y;\u441C\u0100dl\u0A65\u0A6FiumSpace;\u605Flintrf;\u6133r;\uC000\u{1D510}nusPlus;\u6213pf;\uC000\u{1D544}c\xF2\u0A76;\u439C\u0480Jacefostu\u0AA3\u0AA7\u0AAD\u0AC0\u0B14\u0B19\u0D91\u0D97\u0D9Ecy;\u440Acute;\u4143\u0180aey\u0AB4\u0AB9\u0ABEron;\u4147dil;\u4145;\u441D\u0180gsw\u0AC7\u0AF0\u0B0Eative\u0180MTV\u0AD3\u0ADF\u0AE8ediumSpace;\u600Bhi\u0100cn\u0AE6\u0AD8\xEB\u0AD9eryThi\xEE\u0AD9ted\u0100GL\u0AF8\u0B06reaterGreate\xF2\u0673essLes\xF3\u0A48Line;\u400Ar;\uC000\u{1D511}\u0200Bnpt\u0B22\u0B28\u0B37\u0B3Areak;\u6060BreakingSpace;\u40A0f;\u6115\u0680;CDEGHLNPRSTV\u0B55\u0B56\u0B6A\u0B7C\u0BA1\u0BEB\u0C04\u0C5E\u0C84\u0CA6\u0CD8\u0D61\u0D85\u6AEC\u0100ou\u0B5B\u0B64ngruent;\u6262pCap;\u626DoubleVerticalBar;\u6226\u0180lqx\u0B83\u0B8A\u0B9Bement;\u6209ual\u0100;T\u0B92\u0B93\u6260ilde;\uC000\u2242\u0338ists;\u6204reater\u0380;EFGLST\u0BB6\u0BB7\u0BBD\u0BC9\u0BD3\u0BD8\u0BE5\u626Fqual;\u6271ullEqual;\uC000\u2267\u0338reater;\uC000\u226B\u0338ess;\u6279lantEqual;\uC000\u2A7E\u0338ilde;\u6275ump\u0144\u0BF2\u0BFDownHump;\uC000\u224E\u0338qual;\uC000\u224F\u0338e\u0100fs\u0C0A\u0C27tTriangle\u0180;BE\u0C1A\u0C1B\u0C21\u62EAar;\uC000\u29CF\u0338qual;\u62ECs\u0300;EGLST\u0C35\u0C36\u0C3C\u0C44\u0C4B\u0C58\u626Equal;\u6270reater;\u6278ess;\uC000\u226A\u0338lantEqual;\uC000\u2A7D\u0338ilde;\u6274ested\u0100GL\u0C68\u0C79reaterGreater;\uC000\u2AA2\u0338essLess;\uC000\u2AA1\u0338recedes\u0180;ES\u0C92\u0C93\u0C9B\u6280qual;\uC000\u2AAF\u0338lantEqual;\u62E0\u0100ei\u0CAB\u0CB9verseElement;\u620CghtTriangle\u0180;BE\u0CCB\u0CCC\u0CD2\u62EBar;\uC000\u29D0\u0338qual;\u62ED\u0100qu\u0CDD\u0D0CuareSu\u0100bp\u0CE8\u0CF9set\u0100;E\u0CF0\u0CF3\uC000\u228F\u0338qual;\u62E2erset\u0100;E\u0D03\u0D06\uC000\u2290\u0338qual;\u62E3\u0180bcp\u0D13\u0D24\u0D4Eset\u0100;E\u0D1B\u0D1E\uC000\u2282\u20D2qual;\u6288ceeds\u0200;EST\u0D32\u0D33\u0D3B\u0D46\u6281qual;\uC000\u2AB0\u0338lantEqual;\u62E1ilde;\uC000\u227F\u0338erset\u0100;E\u0D58\u0D5B\uC000\u2283\u20D2qual;\u6289ilde\u0200;EFT\u0D6E\u0D6F\u0D75\u0D7F\u6241qual;\u6244ullEqual;\u6247ilde;\u6249erticalBar;\u6224cr;\uC000\u{1D4A9}ilde\u803B\xD1\u40D1;\u439D\u0700Eacdfgmoprstuv\u0DBD\u0DC2\u0DC9\u0DD5\u0DDB\u0DE0\u0DE7\u0DFC\u0E02\u0E20\u0E22\u0E32\u0E3F\u0E44lig;\u4152cute\u803B\xD3\u40D3\u0100iy\u0DCE\u0DD3rc\u803B\xD4\u40D4;\u441Eblac;\u4150r;\uC000\u{1D512}rave\u803B\xD2\u40D2\u0180aei\u0DEE\u0DF2\u0DF6cr;\u414Cga;\u43A9cron;\u439Fpf;\uC000\u{1D546}enCurly\u0100DQ\u0E0E\u0E1AoubleQuote;\u601Cuote;\u6018;\u6A54\u0100cl\u0E27\u0E2Cr;\uC000\u{1D4AA}ash\u803B\xD8\u40D8i\u016C\u0E37\u0E3Cde\u803B\xD5\u40D5es;\u6A37ml\u803B\xD6\u40D6er\u0100BP\u0E4B\u0E60\u0100ar\u0E50\u0E53r;\u603Eac\u0100ek\u0E5A\u0E5C;\u63DEet;\u63B4arenthesis;\u63DC\u0480acfhilors\u0E7F\u0E87\u0E8A\u0E8F\u0E92\u0E94\u0E9D\u0EB0\u0EFCrtialD;\u6202y;\u441Fr;\uC000\u{1D513}i;\u43A6;\u43A0usMinus;\u40B1\u0100ip\u0EA2\u0EADncareplan\xE5\u069Df;\u6119\u0200;eio\u0EB9\u0EBA\u0EE0\u0EE4\u6ABBcedes\u0200;EST\u0EC8\u0EC9\u0ECF\u0EDA\u627Aqual;\u6AAFlantEqual;\u627Cilde;\u627Eme;\u6033\u0100dp\u0EE9\u0EEEuct;\u620Fortion\u0100;a\u0225\u0EF9l;\u621D\u0100ci\u0F01\u0F06r;\uC000\u{1D4AB};\u43A8\u0200Ufos\u0F11\u0F16\u0F1B\u0F1FOT\u803B"\u4022r;\uC000\u{1D514}pf;\u611Acr;\uC000\u{1D4AC}\u0600BEacefhiorsu\u0F3E\u0F43\u0F47\u0F60\u0F73\u0FA7\u0FAA\u0FAD\u1096\u10A9\u10B4\u10BEarr;\u6910G\u803B\xAE\u40AE\u0180cnr\u0F4E\u0F53\u0F56ute;\u4154g;\u67EBr\u0100;t\u0F5C\u0F5D\u61A0l;\u6916\u0180aey\u0F67\u0F6C\u0F71ron;\u4158dil;\u4156;\u4420\u0100;v\u0F78\u0F79\u611Cerse\u0100EU\u0F82\u0F99\u0100lq\u0F87\u0F8Eement;\u620Builibrium;\u61CBpEquilibrium;\u696Fr\xBB\u0F79o;\u43A1ght\u0400ACDFTUVa\u0FC1\u0FEB\u0FF3\u1022\u1028\u105B\u1087\u03D8\u0100nr\u0FC6\u0FD2gleBracket;\u67E9row\u0180;BL\u0FDC\u0FDD\u0FE1\u6192ar;\u61E5eftArrow;\u61C4eiling;\u6309o\u01F5\u0FF9\0\u1005bleBracket;\u67E7n\u01D4\u100A\0\u1014eeVector;\u695Dector\u0100;B\u101D\u101E\u61C2ar;\u6955loor;\u630B\u0100er\u102D\u1043e\u0180;AV\u1035\u1036\u103C\u62A2rrow;\u61A6ector;\u695Biangle\u0180;BE\u1050\u1051\u1055\u62B3ar;\u69D0qual;\u62B5p\u0180DTV\u1063\u106E\u1078ownVector;\u694FeeVector;\u695Cector\u0100;B\u1082\u1083\u61BEar;\u6954ector\u0100;B\u1091\u1092\u61C0ar;\u6953\u0100pu\u109B\u109Ef;\u611DndImplies;\u6970ightarrow;\u61DB\u0100ch\u10B9\u10BCr;\u611B;\u61B1leDelayed;\u69F4\u0680HOacfhimoqstu\u10E4\u10F1\u10F7\u10FD\u1119\u111E\u1151\u1156\u1161\u1167\u11B5\u11BB\u11BF\u0100Cc\u10E9\u10EEHcy;\u4429y;\u4428FTcy;\u442Ccute;\u415A\u0280;aeiy\u1108\u1109\u110E\u1113\u1117\u6ABCron;\u4160dil;\u415Erc;\u415C;\u4421r;\uC000\u{1D516}ort\u0200DLRU\u112A\u1134\u113E\u1149ownArrow\xBB\u041EeftArrow\xBB\u089AightArrow\xBB\u0FDDpArrow;\u6191gma;\u43A3allCircle;\u6218pf;\uC000\u{1D54A}\u0272\u116D\0\0\u1170t;\u621Aare\u0200;ISU\u117B\u117C\u1189\u11AF\u65A1ntersection;\u6293u\u0100bp\u118F\u119Eset\u0100;E\u1197\u1198\u628Fqual;\u6291erset\u0100;E\u11A8\u11A9\u6290qual;\u6292nion;\u6294cr;\uC000\u{1D4AE}ar;\u62C6\u0200bcmp\u11C8\u11DB\u1209\u120B\u0100;s\u11CD\u11CE\u62D0et\u0100;E\u11CD\u11D5qual;\u6286\u0100ch\u11E0\u1205eeds\u0200;EST\u11ED\u11EE\u11F4\u11FF\u627Bqual;\u6AB0lantEqual;\u627Dilde;\u627FTh\xE1\u0F8C;\u6211\u0180;es\u1212\u1213\u1223\u62D1rset\u0100;E\u121C\u121D\u6283qual;\u6287et\xBB\u1213\u0580HRSacfhiors\u123E\u1244\u1249\u1255\u125E\u1271\u1276\u129F\u12C2\u12C8\u12D1ORN\u803B\xDE\u40DEADE;\u6122\u0100Hc\u124E\u1252cy;\u440By;\u4426\u0100bu\u125A\u125C;\u4009;\u43A4\u0180aey\u1265\u126A\u126Fron;\u4164dil;\u4162;\u4422r;\uC000\u{1D517}\u0100ei\u127B\u1289\u01F2\u1280\0\u1287efore;\u6234a;\u4398\u0100cn\u128E\u1298kSpace;\uC000\u205F\u200ASpace;\u6009lde\u0200;EFT\u12AB\u12AC\u12B2\u12BC\u623Cqual;\u6243ullEqual;\u6245ilde;\u6248pf;\uC000\u{1D54B}ipleDot;\u60DB\u0100ct\u12D6\u12DBr;\uC000\u{1D4AF}rok;\u4166\u0AE1\u12F7\u130E\u131A\u1326\0\u132C\u1331\0\0\0\0\0\u1338\u133D\u1377\u1385\0\u13FF\u1404\u140A\u1410\u0100cr\u12FB\u1301ute\u803B\xDA\u40DAr\u0100;o\u1307\u1308\u619Fcir;\u6949r\u01E3\u1313\0\u1316y;\u440Eve;\u416C\u0100iy\u131E\u1323rc\u803B\xDB\u40DB;\u4423blac;\u4170r;\uC000\u{1D518}rave\u803B\xD9\u40D9acr;\u416A\u0100di\u1341\u1369er\u0100BP\u1348\u135D\u0100ar\u134D\u1350r;\u405Fac\u0100ek\u1357\u1359;\u63DFet;\u63B5arenthesis;\u63DDon\u0100;P\u1370\u1371\u62C3lus;\u628E\u0100gp\u137B\u137Fon;\u4172f;\uC000\u{1D54C}\u0400ADETadps\u1395\u13AE\u13B8\u13C4\u03E8\u13D2\u13D7\u13F3rrow\u0180;BD\u1150\u13A0\u13A4ar;\u6912ownArrow;\u61C5ownArrow;\u6195quilibrium;\u696Eee\u0100;A\u13CB\u13CC\u62A5rrow;\u61A5own\xE1\u03F3er\u0100LR\u13DE\u13E8eftArrow;\u6196ightArrow;\u6197i\u0100;l\u13F9\u13FA\u43D2on;\u43A5ing;\u416Ecr;\uC000\u{1D4B0}ilde;\u4168ml\u803B\xDC\u40DC\u0480Dbcdefosv\u1427\u142C\u1430\u1433\u143E\u1485\u148A\u1490\u1496ash;\u62ABar;\u6AEBy;\u4412ash\u0100;l\u143B\u143C\u62A9;\u6AE6\u0100er\u1443\u1445;\u62C1\u0180bty\u144C\u1450\u147Aar;\u6016\u0100;i\u144F\u1455cal\u0200BLST\u1461\u1465\u146A\u1474ar;\u6223ine;\u407Ceparator;\u6758ilde;\u6240ThinSpace;\u600Ar;\uC000\u{1D519}pf;\uC000\u{1D54D}cr;\uC000\u{1D4B1}dash;\u62AA\u0280cefos\u14A7\u14AC\u14B1\u14B6\u14BCirc;\u4174dge;\u62C0r;\uC000\u{1D51A}pf;\uC000\u{1D54E}cr;\uC000\u{1D4B2}\u0200fios\u14CB\u14D0\u14D2\u14D8r;\uC000\u{1D51B};\u439Epf;\uC000\u{1D54F}cr;\uC000\u{1D4B3}\u0480AIUacfosu\u14F1\u14F5\u14F9\u14FD\u1504\u150F\u1514\u151A\u1520cy;\u442Fcy;\u4407cy;\u442Ecute\u803B\xDD\u40DD\u0100iy\u1509\u150Drc;\u4176;\u442Br;\uC000\u{1D51C}pf;\uC000\u{1D550}cr;\uC000\u{1D4B4}ml;\u4178\u0400Hacdefos\u1535\u1539\u153F\u154B\u154F\u155D\u1560\u1564cy;\u4416cute;\u4179\u0100ay\u1544\u1549ron;\u417D;\u4417ot;\u417B\u01F2\u1554\0\u155BoWidt\xE8\u0AD9a;\u4396r;\u6128pf;\u6124cr;\uC000\u{1D4B5}\u0BE1\u1583\u158A\u1590\0\u15B0\u15B6\u15BF\0\0\0\0\u15C6\u15DB\u15EB\u165F\u166D\0\u1695\u169B\u16B2\u16B9\0\u16BEcute\u803B\xE1\u40E1reve;\u4103\u0300;Ediuy\u159C\u159D\u15A1\u15A3\u15A8\u15AD\u623E;\uC000\u223E\u0333;\u623Frc\u803B\xE2\u40E2te\u80BB\xB4\u0306;\u4430lig\u803B\xE6\u40E6\u0100;r\xB2\u15BA;\uC000\u{1D51E}rave\u803B\xE0\u40E0\u0100ep\u15CA\u15D6\u0100fp\u15CF\u15D4sym;\u6135\xE8\u15D3ha;\u43B1\u0100ap\u15DFc\u0100cl\u15E4\u15E7r;\u4101g;\u6A3F\u0264\u15F0\0\0\u160A\u0280;adsv\u15FA\u15FB\u15FF\u1601\u1607\u6227nd;\u6A55;\u6A5Clope;\u6A58;\u6A5A\u0380;elmrsz\u1618\u1619\u161B\u161E\u163F\u164F\u1659\u6220;\u69A4e\xBB\u1619sd\u0100;a\u1625\u1626\u6221\u0461\u1630\u1632\u1634\u1636\u1638\u163A\u163C\u163E;\u69A8;\u69A9;\u69AA;\u69AB;\u69AC;\u69AD;\u69AE;\u69AFt\u0100;v\u1645\u1646\u621Fb\u0100;d\u164C\u164D\u62BE;\u699D\u0100pt\u1654\u1657h;\u6222\xBB\xB9arr;\u637C\u0100gp\u1663\u1667on;\u4105f;\uC000\u{1D552}\u0380;Eaeiop\u12C1\u167B\u167D\u1682\u1684\u1687\u168A;\u6A70cir;\u6A6F;\u624Ad;\u624Bs;\u4027rox\u0100;e\u12C1\u1692\xF1\u1683ing\u803B\xE5\u40E5\u0180cty\u16A1\u16A6\u16A8r;\uC000\u{1D4B6};\u402Amp\u0100;e\u12C1\u16AF\xF1\u0288ilde\u803B\xE3\u40E3ml\u803B\xE4\u40E4\u0100ci\u16C2\u16C8onin\xF4\u0272nt;\u6A11\u0800Nabcdefiklnoprsu\u16ED\u16F1\u1730\u173C\u1743\u1748\u1778\u177D\u17E0\u17E6\u1839\u1850\u170D\u193D\u1948\u1970ot;\u6AED\u0100cr\u16F6\u171Ek\u0200ceps\u1700\u1705\u170D\u1713ong;\u624Cpsilon;\u43F6rime;\u6035im\u0100;e\u171A\u171B\u623Dq;\u62CD\u0176\u1722\u1726ee;\u62BDed\u0100;g\u172C\u172D\u6305e\xBB\u172Drk\u0100;t\u135C\u1737brk;\u63B6\u0100oy\u1701\u1741;\u4431quo;\u601E\u0280cmprt\u1753\u175B\u1761\u1764\u1768aus\u0100;e\u010A\u0109ptyv;\u69B0s\xE9\u170Cno\xF5\u0113\u0180ahw\u176F\u1771\u1773;\u43B2;\u6136een;\u626Cr;\uC000\u{1D51F}g\u0380costuvw\u178D\u179D\u17B3\u17C1\u17D5\u17DB\u17DE\u0180aiu\u1794\u1796\u179A\xF0\u0760rc;\u65EFp\xBB\u1371\u0180dpt\u17A4\u17A8\u17ADot;\u6A00lus;\u6A01imes;\u6A02\u0271\u17B9\0\0\u17BEcup;\u6A06ar;\u6605riangle\u0100du\u17CD\u17D2own;\u65BDp;\u65B3plus;\u6A04e\xE5\u1444\xE5\u14ADarow;\u690D\u0180ako\u17ED\u1826\u1835\u0100cn\u17F2\u1823k\u0180lst\u17FA\u05AB\u1802ozenge;\u69EBriangle\u0200;dlr\u1812\u1813\u1818\u181D\u65B4own;\u65BEeft;\u65C2ight;\u65B8k;\u6423\u01B1\u182B\0\u1833\u01B2\u182F\0\u1831;\u6592;\u65914;\u6593ck;\u6588\u0100eo\u183E\u184D\u0100;q\u1843\u1846\uC000=\u20E5uiv;\uC000\u2261\u20E5t;\u6310\u0200ptwx\u1859\u185E\u1867\u186Cf;\uC000\u{1D553}\u0100;t\u13CB\u1863om\xBB\u13CCtie;\u62C8\u0600DHUVbdhmptuv\u1885\u1896\u18AA\u18BB\u18D7\u18DB\u18EC\u18FF\u1905\u190A\u1910\u1921\u0200LRlr\u188E\u1890\u1892\u1894;\u6557;\u6554;\u6556;\u6553\u0280;DUdu\u18A1\u18A2\u18A4\u18A6\u18A8\u6550;\u6566;\u6569;\u6564;\u6567\u0200LRlr\u18B3\u18B5\u18B7\u18B9;\u655D;\u655A;\u655C;\u6559\u0380;HLRhlr\u18CA\u18CB\u18CD\u18CF\u18D1\u18D3\u18D5\u6551;\u656C;\u6563;\u6560;\u656B;\u6562;\u655Fox;\u69C9\u0200LRlr\u18E4\u18E6\u18E8\u18EA;\u6555;\u6552;\u6510;\u650C\u0280;DUdu\u06BD\u18F7\u18F9\u18FB\u18FD;\u6565;\u6568;\u652C;\u6534inus;\u629Flus;\u629Eimes;\u62A0\u0200LRlr\u1919\u191B\u191D\u191F;\u655B;\u6558;\u6518;\u6514\u0380;HLRhlr\u1930\u1931\u1933\u1935\u1937\u1939\u193B\u6502;\u656A;\u6561;\u655E;\u653C;\u6524;\u651C\u0100ev\u0123\u1942bar\u803B\xA6\u40A6\u0200ceio\u1951\u1956\u195A\u1960r;\uC000\u{1D4B7}mi;\u604Fm\u0100;e\u171A\u171Cl\u0180;bh\u1968\u1969\u196B\u405C;\u69C5sub;\u67C8\u016C\u1974\u197El\u0100;e\u1979\u197A\u6022t\xBB\u197Ap\u0180;Ee\u012F\u1985\u1987;\u6AAE\u0100;q\u06DC\u06DB\u0CE1\u19A7\0\u19E8\u1A11\u1A15\u1A32\0\u1A37\u1A50\0\0\u1AB4\0\0\u1AC1\0\0\u1B21\u1B2E\u1B4D\u1B52\0\u1BFD\0\u1C0C\u0180cpr\u19AD\u19B2\u19DDute;\u4107\u0300;abcds\u19BF\u19C0\u19C4\u19CA\u19D5\u19D9\u6229nd;\u6A44rcup;\u6A49\u0100au\u19CF\u19D2p;\u6A4Bp;\u6A47ot;\u6A40;\uC000\u2229\uFE00\u0100eo\u19E2\u19E5t;\u6041\xEE\u0693\u0200aeiu\u19F0\u19FB\u1A01\u1A05\u01F0\u19F5\0\u19F8s;\u6A4Don;\u410Ddil\u803B\xE7\u40E7rc;\u4109ps\u0100;s\u1A0C\u1A0D\u6A4Cm;\u6A50ot;\u410B\u0180dmn\u1A1B\u1A20\u1A26il\u80BB\xB8\u01ADptyv;\u69B2t\u8100\xA2;e\u1A2D\u1A2E\u40A2r\xE4\u01B2r;\uC000\u{1D520}\u0180cei\u1A3D\u1A40\u1A4Dy;\u4447ck\u0100;m\u1A47\u1A48\u6713ark\xBB\u1A48;\u43C7r\u0380;Ecefms\u1A5F\u1A60\u1A62\u1A6B\u1AA4\u1AAA\u1AAE\u65CB;\u69C3\u0180;el\u1A69\u1A6A\u1A6D\u42C6q;\u6257e\u0261\u1A74\0\0\u1A88rrow\u0100lr\u1A7C\u1A81eft;\u61BAight;\u61BB\u0280RSacd\u1A92\u1A94\u1A96\u1A9A\u1A9F\xBB\u0F47;\u64C8st;\u629Birc;\u629Aash;\u629Dnint;\u6A10id;\u6AEFcir;\u69C2ubs\u0100;u\u1ABB\u1ABC\u6663it\xBB\u1ABC\u02EC\u1AC7\u1AD4\u1AFA\0\u1B0Aon\u0100;e\u1ACD\u1ACE\u403A\u0100;q\xC7\xC6\u026D\u1AD9\0\0\u1AE2a\u0100;t\u1ADE\u1ADF\u402C;\u4040\u0180;fl\u1AE8\u1AE9\u1AEB\u6201\xEE\u1160e\u0100mx\u1AF1\u1AF6ent\xBB\u1AE9e\xF3\u024D\u01E7\u1AFE\0\u1B07\u0100;d\u12BB\u1B02ot;\u6A6Dn\xF4\u0246\u0180fry\u1B10\u1B14\u1B17;\uC000\u{1D554}o\xE4\u0254\u8100\xA9;s\u0155\u1B1Dr;\u6117\u0100ao\u1B25\u1B29rr;\u61B5ss;\u6717\u0100cu\u1B32\u1B37r;\uC000\u{1D4B8}\u0100bp\u1B3C\u1B44\u0100;e\u1B41\u1B42\u6ACF;\u6AD1\u0100;e\u1B49\u1B4A\u6AD0;\u6AD2dot;\u62EF\u0380delprvw\u1B60\u1B6C\u1B77\u1B82\u1BAC\u1BD4\u1BF9arr\u0100lr\u1B68\u1B6A;\u6938;\u6935\u0270\u1B72\0\0\u1B75r;\u62DEc;\u62DFarr\u0100;p\u1B7F\u1B80\u61B6;\u693D\u0300;bcdos\u1B8F\u1B90\u1B96\u1BA1\u1BA5\u1BA8\u622Arcap;\u6A48\u0100au\u1B9B\u1B9Ep;\u6A46p;\u6A4Aot;\u628Dr;\u6A45;\uC000\u222A\uFE00\u0200alrv\u1BB5\u1BBF\u1BDE\u1BE3rr\u0100;m\u1BBC\u1BBD\u61B7;\u693Cy\u0180evw\u1BC7\u1BD4\u1BD8q\u0270\u1BCE\0\0\u1BD2re\xE3\u1B73u\xE3\u1B75ee;\u62CEedge;\u62CFen\u803B\xA4\u40A4earrow\u0100lr\u1BEE\u1BF3eft\xBB\u1B80ight\xBB\u1BBDe\xE4\u1BDD\u0100ci\u1C01\u1C07onin\xF4\u01F7nt;\u6231lcty;\u632D\u0980AHabcdefhijlorstuwz\u1C38\u1C3B\u1C3F\u1C5D\u1C69\u1C75\u1C8A\u1C9E\u1CAC\u1CB7\u1CFB\u1CFF\u1D0D\u1D7B\u1D91\u1DAB\u1DBB\u1DC6\u1DCDr\xF2\u0381ar;\u6965\u0200glrs\u1C48\u1C4D\u1C52\u1C54ger;\u6020eth;\u6138\xF2\u1133h\u0100;v\u1C5A\u1C5B\u6010\xBB\u090A\u016B\u1C61\u1C67arow;\u690Fa\xE3\u0315\u0100ay\u1C6E\u1C73ron;\u410F;\u4434\u0180;ao\u0332\u1C7C\u1C84\u0100gr\u02BF\u1C81r;\u61CAtseq;\u6A77\u0180glm\u1C91\u1C94\u1C98\u803B\xB0\u40B0ta;\u43B4ptyv;\u69B1\u0100ir\u1CA3\u1CA8sht;\u697F;\uC000\u{1D521}ar\u0100lr\u1CB3\u1CB5\xBB\u08DC\xBB\u101E\u0280aegsv\u1CC2\u0378\u1CD6\u1CDC\u1CE0m\u0180;os\u0326\u1CCA\u1CD4nd\u0100;s\u0326\u1CD1uit;\u6666amma;\u43DDin;\u62F2\u0180;io\u1CE7\u1CE8\u1CF8\u40F7de\u8100\xF7;o\u1CE7\u1CF0ntimes;\u62C7n\xF8\u1CF7cy;\u4452c\u026F\u1D06\0\0\u1D0Arn;\u631Eop;\u630D\u0280lptuw\u1D18\u1D1D\u1D22\u1D49\u1D55lar;\u4024f;\uC000\u{1D555}\u0280;emps\u030B\u1D2D\u1D37\u1D3D\u1D42q\u0100;d\u0352\u1D33ot;\u6251inus;\u6238lus;\u6214quare;\u62A1blebarwedg\xE5\xFAn\u0180adh\u112E\u1D5D\u1D67ownarrow\xF3\u1C83arpoon\u0100lr\u1D72\u1D76ef\xF4\u1CB4igh\xF4\u1CB6\u0162\u1D7F\u1D85karo\xF7\u0F42\u026F\u1D8A\0\0\u1D8Ern;\u631Fop;\u630C\u0180cot\u1D98\u1DA3\u1DA6\u0100ry\u1D9D\u1DA1;\uC000\u{1D4B9};\u4455l;\u69F6rok;\u4111\u0100dr\u1DB0\u1DB4ot;\u62F1i\u0100;f\u1DBA\u1816\u65BF\u0100ah\u1DC0\u1DC3r\xF2\u0429a\xF2\u0FA6angle;\u69A6\u0100ci\u1DD2\u1DD5y;\u445Fgrarr;\u67FF\u0900Dacdefglmnopqrstux\u1E01\u1E09\u1E19\u1E38\u0578\u1E3C\u1E49\u1E61\u1E7E\u1EA5\u1EAF\u1EBD\u1EE1\u1F2A\u1F37\u1F44\u1F4E\u1F5A\u0100Do\u1E06\u1D34o\xF4\u1C89\u0100cs\u1E0E\u1E14ute\u803B\xE9\u40E9ter;\u6A6E\u0200aioy\u1E22\u1E27\u1E31\u1E36ron;\u411Br\u0100;c\u1E2D\u1E2E\u6256\u803B\xEA\u40EAlon;\u6255;\u444Dot;\u4117\u0100Dr\u1E41\u1E45ot;\u6252;\uC000\u{1D522}\u0180;rs\u1E50\u1E51\u1E57\u6A9Aave\u803B\xE8\u40E8\u0100;d\u1E5C\u1E5D\u6A96ot;\u6A98\u0200;ils\u1E6A\u1E6B\u1E72\u1E74\u6A99nters;\u63E7;\u6113\u0100;d\u1E79\u1E7A\u6A95ot;\u6A97\u0180aps\u1E85\u1E89\u1E97cr;\u4113ty\u0180;sv\u1E92\u1E93\u1E95\u6205et\xBB\u1E93p\u01001;\u1E9D\u1EA4\u0133\u1EA1\u1EA3;\u6004;\u6005\u6003\u0100gs\u1EAA\u1EAC;\u414Bp;\u6002\u0100gp\u1EB4\u1EB8on;\u4119f;\uC000\u{1D556}\u0180als\u1EC4\u1ECE\u1ED2r\u0100;s\u1ECA\u1ECB\u62D5l;\u69E3us;\u6A71i\u0180;lv\u1EDA\u1EDB\u1EDF\u43B5on\xBB\u1EDB;\u43F5\u0200csuv\u1EEA\u1EF3\u1F0B\u1F23\u0100io\u1EEF\u1E31rc\xBB\u1E2E\u0269\u1EF9\0\0\u1EFB\xED\u0548ant\u0100gl\u1F02\u1F06tr\xBB\u1E5Dess\xBB\u1E7A\u0180aei\u1F12\u1F16\u1F1Als;\u403Dst;\u625Fv\u0100;D\u0235\u1F20D;\u6A78parsl;\u69E5\u0100Da\u1F2F\u1F33ot;\u6253rr;\u6971\u0180cdi\u1F3E\u1F41\u1EF8r;\u612Fo\xF4\u0352\u0100ah\u1F49\u1F4B;\u43B7\u803B\xF0\u40F0\u0100mr\u1F53\u1F57l\u803B\xEB\u40EBo;\u60AC\u0180cip\u1F61\u1F64\u1F67l;\u4021s\xF4\u056E\u0100eo\u1F6C\u1F74ctatio\xEE\u0559nential\xE5\u0579\u09E1\u1F92\0\u1F9E\0\u1FA1\u1FA7\0\0\u1FC6\u1FCC\0\u1FD3\0\u1FE6\u1FEA\u2000\0\u2008\u205Allingdotse\xF1\u1E44y;\u4444male;\u6640\u0180ilr\u1FAD\u1FB3\u1FC1lig;\u8000\uFB03\u0269\u1FB9\0\0\u1FBDg;\u8000\uFB00ig;\u8000\uFB04;\uC000\u{1D523}lig;\u8000\uFB01lig;\uC000fj\u0180alt\u1FD9\u1FDC\u1FE1t;\u666Dig;\u8000\uFB02ns;\u65B1of;\u4192\u01F0\u1FEE\0\u1FF3f;\uC000\u{1D557}\u0100ak\u05BF\u1FF7\u0100;v\u1FFC\u1FFD\u62D4;\u6AD9artint;\u6A0D\u0100ao\u200C\u2055\u0100cs\u2011\u2052\u03B1\u201A\u2030\u2038\u2045\u2048\0\u2050\u03B2\u2022\u2025\u2027\u202A\u202C\0\u202E\u803B\xBD\u40BD;\u6153\u803B\xBC\u40BC;\u6155;\u6159;\u615B\u01B3\u2034\0\u2036;\u6154;\u6156\u02B4\u203E\u2041\0\0\u2043\u803B\xBE\u40BE;\u6157;\u615C5;\u6158\u01B6\u204C\0\u204E;\u615A;\u615D8;\u615El;\u6044wn;\u6322cr;\uC000\u{1D4BB}\u0880Eabcdefgijlnorstv\u2082\u2089\u209F\u20A5\u20B0\u20B4\u20F0\u20F5\u20FA\u20FF\u2103\u2112\u2138\u0317\u213E\u2152\u219E\u0100;l\u064D\u2087;\u6A8C\u0180cmp\u2090\u2095\u209Dute;\u41F5ma\u0100;d\u209C\u1CDA\u43B3;\u6A86reve;\u411F\u0100iy\u20AA\u20AErc;\u411D;\u4433ot;\u4121\u0200;lqs\u063E\u0642\u20BD\u20C9\u0180;qs\u063E\u064C\u20C4lan\xF4\u0665\u0200;cdl\u0665\u20D2\u20D5\u20E5c;\u6AA9ot\u0100;o\u20DC\u20DD\u6A80\u0100;l\u20E2\u20E3\u6A82;\u6A84\u0100;e\u20EA\u20ED\uC000\u22DB\uFE00s;\u6A94r;\uC000\u{1D524}\u0100;g\u0673\u061Bmel;\u6137cy;\u4453\u0200;Eaj\u065A\u210C\u210E\u2110;\u6A92;\u6AA5;\u6AA4\u0200Eaes\u211B\u211D\u2129\u2134;\u6269p\u0100;p\u2123\u2124\u6A8Arox\xBB\u2124\u0100;q\u212E\u212F\u6A88\u0100;q\u212E\u211Bim;\u62E7pf;\uC000\u{1D558}\u0100ci\u2143\u2146r;\u610Am\u0180;el\u066B\u214E\u2150;\u6A8E;\u6A90\u8300>;cdlqr\u05EE\u2160\u216A\u216E\u2173\u2179\u0100ci\u2165\u2167;\u6AA7r;\u6A7Aot;\u62D7Par;\u6995uest;\u6A7C\u0280adels\u2184\u216A\u2190\u0656\u219B\u01F0\u2189\0\u218Epro\xF8\u209Er;\u6978q\u0100lq\u063F\u2196les\xF3\u2088i\xED\u066B\u0100en\u21A3\u21ADrtneqq;\uC000\u2269\uFE00\xC5\u21AA\u0500Aabcefkosy\u21C4\u21C7\u21F1\u21F5\u21FA\u2218\u221D\u222F\u2268\u227Dr\xF2\u03A0\u0200ilmr\u21D0\u21D4\u21D7\u21DBrs\xF0\u1484f\xBB\u2024il\xF4\u06A9\u0100dr\u21E0\u21E4cy;\u444A\u0180;cw\u08F4\u21EB\u21EFir;\u6948;\u61ADar;\u610Firc;\u4125\u0180alr\u2201\u220E\u2213rts\u0100;u\u2209\u220A\u6665it\xBB\u220Alip;\u6026con;\u62B9r;\uC000\u{1D525}s\u0100ew\u2223\u2229arow;\u6925arow;\u6926\u0280amopr\u223A\u223E\u2243\u225E\u2263rr;\u61FFtht;\u623Bk\u0100lr\u2249\u2253eftarrow;\u61A9ightarrow;\u61AAf;\uC000\u{1D559}bar;\u6015\u0180clt\u226F\u2274\u2278r;\uC000\u{1D4BD}as\xE8\u21F4rok;\u4127\u0100bp\u2282\u2287ull;\u6043hen\xBB\u1C5B\u0AE1\u22A3\0\u22AA\0\u22B8\u22C5\u22CE\0\u22D5\u22F3\0\0\u22F8\u2322\u2367\u2362\u237F\0\u2386\u23AA\u23B4cute\u803B\xED\u40ED\u0180;iy\u0771\u22B0\u22B5rc\u803B\xEE\u40EE;\u4438\u0100cx\u22BC\u22BFy;\u4435cl\u803B\xA1\u40A1\u0100fr\u039F\u22C9;\uC000\u{1D526}rave\u803B\xEC\u40EC\u0200;ino\u073E\u22DD\u22E9\u22EE\u0100in\u22E2\u22E6nt;\u6A0Ct;\u622Dfin;\u69DCta;\u6129lig;\u4133\u0180aop\u22FE\u231A\u231D\u0180cgt\u2305\u2308\u2317r;\u412B\u0180elp\u071F\u230F\u2313in\xE5\u078Ear\xF4\u0720h;\u4131f;\u62B7ed;\u41B5\u0280;cfot\u04F4\u232C\u2331\u233D\u2341are;\u6105in\u0100;t\u2338\u2339\u621Eie;\u69DDdo\xF4\u2319\u0280;celp\u0757\u234C\u2350\u235B\u2361al;\u62BA\u0100gr\u2355\u2359er\xF3\u1563\xE3\u234Darhk;\u6A17rod;\u6A3C\u0200cgpt\u236F\u2372\u2376\u237By;\u4451on;\u412Ff;\uC000\u{1D55A}a;\u43B9uest\u803B\xBF\u40BF\u0100ci\u238A\u238Fr;\uC000\u{1D4BE}n\u0280;Edsv\u04F4\u239B\u239D\u23A1\u04F3;\u62F9ot;\u62F5\u0100;v\u23A6\u23A7\u62F4;\u62F3\u0100;i\u0777\u23AElde;\u4129\u01EB\u23B8\0\u23BCcy;\u4456l\u803B\xEF\u40EF\u0300cfmosu\u23CC\u23D7\u23DC\u23E1\u23E7\u23F5\u0100iy\u23D1\u23D5rc;\u4135;\u4439r;\uC000\u{1D527}ath;\u4237pf;\uC000\u{1D55B}\u01E3\u23EC\0\u23F1r;\uC000\u{1D4BF}rcy;\u4458kcy;\u4454\u0400acfghjos\u240B\u2416\u2422\u2427\u242D\u2431\u2435\u243Bppa\u0100;v\u2413\u2414\u43BA;\u43F0\u0100ey\u241B\u2420dil;\u4137;\u443Ar;\uC000\u{1D528}reen;\u4138cy;\u4445cy;\u445Cpf;\uC000\u{1D55C}cr;\uC000\u{1D4C0}\u0B80ABEHabcdefghjlmnoprstuv\u2470\u2481\u2486\u248D\u2491\u250E\u253D\u255A\u2580\u264E\u265E\u2665\u2679\u267D\u269A\u26B2\u26D8\u275D\u2768\u278B\u27C0\u2801\u2812\u0180art\u2477\u247A\u247Cr\xF2\u09C6\xF2\u0395ail;\u691Barr;\u690E\u0100;g\u0994\u248B;\u6A8Bar;\u6962\u0963\u24A5\0\u24AA\0\u24B1\0\0\0\0\0\u24B5\u24BA\0\u24C6\u24C8\u24CD\0\u24F9ute;\u413Amptyv;\u69B4ra\xEE\u084Cbda;\u43BBg\u0180;dl\u088E\u24C1\u24C3;\u6991\xE5\u088E;\u6A85uo\u803B\xAB\u40ABr\u0400;bfhlpst\u0899\u24DE\u24E6\u24E9\u24EB\u24EE\u24F1\u24F5\u0100;f\u089D\u24E3s;\u691Fs;\u691D\xEB\u2252p;\u61ABl;\u6939im;\u6973l;\u61A2\u0180;ae\u24FF\u2500\u2504\u6AABil;\u6919\u0100;s\u2509\u250A\u6AAD;\uC000\u2AAD\uFE00\u0180abr\u2515\u2519\u251Drr;\u690Crk;\u6772\u0100ak\u2522\u252Cc\u0100ek\u2528\u252A;\u407B;\u405B\u0100es\u2531\u2533;\u698Bl\u0100du\u2539\u253B;\u698F;\u698D\u0200aeuy\u2546\u254B\u2556\u2558ron;\u413E\u0100di\u2550\u2554il;\u413C\xEC\u08B0\xE2\u2529;\u443B\u0200cqrs\u2563\u2566\u256D\u257Da;\u6936uo\u0100;r\u0E19\u1746\u0100du\u2572\u2577har;\u6967shar;\u694Bh;\u61B2\u0280;fgqs\u258B\u258C\u0989\u25F3\u25FF\u6264t\u0280ahlrt\u2598\u25A4\u25B7\u25C2\u25E8rrow\u0100;t\u0899\u25A1a\xE9\u24F6arpoon\u0100du\u25AF\u25B4own\xBB\u045Ap\xBB\u0966eftarrows;\u61C7ight\u0180ahs\u25CD\u25D6\u25DErrow\u0100;s\u08F4\u08A7arpoon\xF3\u0F98quigarro\xF7\u21F0hreetimes;\u62CB\u0180;qs\u258B\u0993\u25FAlan\xF4\u09AC\u0280;cdgs\u09AC\u260A\u260D\u261D\u2628c;\u6AA8ot\u0100;o\u2614\u2615\u6A7F\u0100;r\u261A\u261B\u6A81;\u6A83\u0100;e\u2622\u2625\uC000\u22DA\uFE00s;\u6A93\u0280adegs\u2633\u2639\u263D\u2649\u264Bppro\xF8\u24C6ot;\u62D6q\u0100gq\u2643\u2645\xF4\u0989gt\xF2\u248C\xF4\u099Bi\xED\u09B2\u0180ilr\u2655\u08E1\u265Asht;\u697C;\uC000\u{1D529}\u0100;E\u099C\u2663;\u6A91\u0161\u2669\u2676r\u0100du\u25B2\u266E\u0100;l\u0965\u2673;\u696Alk;\u6584cy;\u4459\u0280;acht\u0A48\u2688\u268B\u2691\u2696r\xF2\u25C1orne\xF2\u1D08ard;\u696Bri;\u65FA\u0100io\u269F\u26A4dot;\u4140ust\u0100;a\u26AC\u26AD\u63B0che\xBB\u26AD\u0200Eaes\u26BB\u26BD\u26C9\u26D4;\u6268p\u0100;p\u26C3\u26C4\u6A89rox\xBB\u26C4\u0100;q\u26CE\u26CF\u6A87\u0100;q\u26CE\u26BBim;\u62E6\u0400abnoptwz\u26E9\u26F4\u26F7\u271A\u272F\u2741\u2747\u2750\u0100nr\u26EE\u26F1g;\u67ECr;\u61FDr\xEB\u08C1g\u0180lmr\u26FF\u270D\u2714eft\u0100ar\u09E6\u2707ight\xE1\u09F2apsto;\u67FCight\xE1\u09FDparrow\u0100lr\u2725\u2729ef\xF4\u24EDight;\u61AC\u0180afl\u2736\u2739\u273Dr;\u6985;\uC000\u{1D55D}us;\u6A2Dimes;\u6A34\u0161\u274B\u274Fst;\u6217\xE1\u134E\u0180;ef\u2757\u2758\u1800\u65CAnge\xBB\u2758ar\u0100;l\u2764\u2765\u4028t;\u6993\u0280achmt\u2773\u2776\u277C\u2785\u2787r\xF2\u08A8orne\xF2\u1D8Car\u0100;d\u0F98\u2783;\u696D;\u600Eri;\u62BF\u0300achiqt\u2798\u279D\u0A40\u27A2\u27AE\u27BBquo;\u6039r;\uC000\u{1D4C1}m\u0180;eg\u09B2\u27AA\u27AC;\u6A8D;\u6A8F\u0100bu\u252A\u27B3o\u0100;r\u0E1F\u27B9;\u601Arok;\u4142\u8400<;cdhilqr\u082B\u27D2\u2639\u27DC\u27E0\u27E5\u27EA\u27F0\u0100ci\u27D7\u27D9;\u6AA6r;\u6A79re\xE5\u25F2mes;\u62C9arr;\u6976uest;\u6A7B\u0100Pi\u27F5\u27F9ar;\u6996\u0180;ef\u2800\u092D\u181B\u65C3r\u0100du\u2807\u280Dshar;\u694Ahar;\u6966\u0100en\u2817\u2821rtneqq;\uC000\u2268\uFE00\xC5\u281E\u0700Dacdefhilnopsu\u2840\u2845\u2882\u288E\u2893\u28A0\u28A5\u28A8\u28DA\u28E2\u28E4\u0A83\u28F3\u2902Dot;\u623A\u0200clpr\u284E\u2852\u2863\u287Dr\u803B\xAF\u40AF\u0100et\u2857\u2859;\u6642\u0100;e\u285E\u285F\u6720se\xBB\u285F\u0100;s\u103B\u2868to\u0200;dlu\u103B\u2873\u2877\u287Bow\xEE\u048Cef\xF4\u090F\xF0\u13D1ker;\u65AE\u0100oy\u2887\u288Cmma;\u6A29;\u443Cash;\u6014asuredangle\xBB\u1626r;\uC000\u{1D52A}o;\u6127\u0180cdn\u28AF\u28B4\u28C9ro\u803B\xB5\u40B5\u0200;acd\u1464\u28BD\u28C0\u28C4s\xF4\u16A7ir;\u6AF0ot\u80BB\xB7\u01B5us\u0180;bd\u28D2\u1903\u28D3\u6212\u0100;u\u1D3C\u28D8;\u6A2A\u0163\u28DE\u28E1p;\u6ADB\xF2\u2212\xF0\u0A81\u0100dp\u28E9\u28EEels;\u62A7f;\uC000\u{1D55E}\u0100ct\u28F8\u28FDr;\uC000\u{1D4C2}pos\xBB\u159D\u0180;lm\u2909\u290A\u290D\u43BCtimap;\u62B8\u0C00GLRVabcdefghijlmoprstuvw\u2942\u2953\u297E\u2989\u2998\u29DA\u29E9\u2A15\u2A1A\u2A58\u2A5D\u2A83\u2A95\u2AA4\u2AA8\u2B04\u2B07\u2B44\u2B7F\u2BAE\u2C34\u2C67\u2C7C\u2CE9\u0100gt\u2947\u294B;\uC000\u22D9\u0338\u0100;v\u2950\u0BCF\uC000\u226B\u20D2\u0180elt\u295A\u2972\u2976ft\u0100ar\u2961\u2967rrow;\u61CDightarrow;\u61CE;\uC000\u22D8\u0338\u0100;v\u297B\u0C47\uC000\u226A\u20D2ightarrow;\u61CF\u0100Dd\u298E\u2993ash;\u62AFash;\u62AE\u0280bcnpt\u29A3\u29A7\u29AC\u29B1\u29CCla\xBB\u02DEute;\u4144g;\uC000\u2220\u20D2\u0280;Eiop\u0D84\u29BC\u29C0\u29C5\u29C8;\uC000\u2A70\u0338d;\uC000\u224B\u0338s;\u4149ro\xF8\u0D84ur\u0100;a\u29D3\u29D4\u666El\u0100;s\u29D3\u0B38\u01F3\u29DF\0\u29E3p\u80BB\xA0\u0B37mp\u0100;e\u0BF9\u0C00\u0280aeouy\u29F4\u29FE\u2A03\u2A10\u2A13\u01F0\u29F9\0\u29FB;\u6A43on;\u4148dil;\u4146ng\u0100;d\u0D7E\u2A0Aot;\uC000\u2A6D\u0338p;\u6A42;\u443Dash;\u6013\u0380;Aadqsx\u0B92\u2A29\u2A2D\u2A3B\u2A41\u2A45\u2A50rr;\u61D7r\u0100hr\u2A33\u2A36k;\u6924\u0100;o\u13F2\u13F0ot;\uC000\u2250\u0338ui\xF6\u0B63\u0100ei\u2A4A\u2A4Ear;\u6928\xED\u0B98ist\u0100;s\u0BA0\u0B9Fr;\uC000\u{1D52B}\u0200Eest\u0BC5\u2A66\u2A79\u2A7C\u0180;qs\u0BBC\u2A6D\u0BE1\u0180;qs\u0BBC\u0BC5\u2A74lan\xF4\u0BE2i\xED\u0BEA\u0100;r\u0BB6\u2A81\xBB\u0BB7\u0180Aap\u2A8A\u2A8D\u2A91r\xF2\u2971rr;\u61AEar;\u6AF2\u0180;sv\u0F8D\u2A9C\u0F8C\u0100;d\u2AA1\u2AA2\u62FC;\u62FAcy;\u445A\u0380AEadest\u2AB7\u2ABA\u2ABE\u2AC2\u2AC5\u2AF6\u2AF9r\xF2\u2966;\uC000\u2266\u0338rr;\u619Ar;\u6025\u0200;fqs\u0C3B\u2ACE\u2AE3\u2AEFt\u0100ar\u2AD4\u2AD9rro\xF7\u2AC1ightarro\xF7\u2A90\u0180;qs\u0C3B\u2ABA\u2AEAlan\xF4\u0C55\u0100;s\u0C55\u2AF4\xBB\u0C36i\xED\u0C5D\u0100;r\u0C35\u2AFEi\u0100;e\u0C1A\u0C25i\xE4\u0D90\u0100pt\u2B0C\u2B11f;\uC000\u{1D55F}\u8180\xAC;in\u2B19\u2B1A\u2B36\u40ACn\u0200;Edv\u0B89\u2B24\u2B28\u2B2E;\uC000\u22F9\u0338ot;\uC000\u22F5\u0338\u01E1\u0B89\u2B33\u2B35;\u62F7;\u62F6i\u0100;v\u0CB8\u2B3C\u01E1\u0CB8\u2B41\u2B43;\u62FE;\u62FD\u0180aor\u2B4B\u2B63\u2B69r\u0200;ast\u0B7B\u2B55\u2B5A\u2B5Flle\xEC\u0B7Bl;\uC000\u2AFD\u20E5;\uC000\u2202\u0338lint;\u6A14\u0180;ce\u0C92\u2B70\u2B73u\xE5\u0CA5\u0100;c\u0C98\u2B78\u0100;e\u0C92\u2B7D\xF1\u0C98\u0200Aait\u2B88\u2B8B\u2B9D\u2BA7r\xF2\u2988rr\u0180;cw\u2B94\u2B95\u2B99\u619B;\uC000\u2933\u0338;\uC000\u219D\u0338ghtarrow\xBB\u2B95ri\u0100;e\u0CCB\u0CD6\u0380chimpqu\u2BBD\u2BCD\u2BD9\u2B04\u0B78\u2BE4\u2BEF\u0200;cer\u0D32\u2BC6\u0D37\u2BC9u\xE5\u0D45;\uC000\u{1D4C3}ort\u026D\u2B05\0\0\u2BD6ar\xE1\u2B56m\u0100;e\u0D6E\u2BDF\u0100;q\u0D74\u0D73su\u0100bp\u2BEB\u2BED\xE5\u0CF8\xE5\u0D0B\u0180bcp\u2BF6\u2C11\u2C19\u0200;Ees\u2BFF\u2C00\u0D22\u2C04\u6284;\uC000\u2AC5\u0338et\u0100;e\u0D1B\u2C0Bq\u0100;q\u0D23\u2C00c\u0100;e\u0D32\u2C17\xF1\u0D38\u0200;Ees\u2C22\u2C23\u0D5F\u2C27\u6285;\uC000\u2AC6\u0338et\u0100;e\u0D58\u2C2Eq\u0100;q\u0D60\u2C23\u0200gilr\u2C3D\u2C3F\u2C45\u2C47\xEC\u0BD7lde\u803B\xF1\u40F1\xE7\u0C43iangle\u0100lr\u2C52\u2C5Ceft\u0100;e\u0C1A\u2C5A\xF1\u0C26ight\u0100;e\u0CCB\u2C65\xF1\u0CD7\u0100;m\u2C6C\u2C6D\u43BD\u0180;es\u2C74\u2C75\u2C79\u4023ro;\u6116p;\u6007\u0480DHadgilrs\u2C8F\u2C94\u2C99\u2C9E\u2CA3\u2CB0\u2CB6\u2CD3\u2CE3ash;\u62ADarr;\u6904p;\uC000\u224D\u20D2ash;\u62AC\u0100et\u2CA8\u2CAC;\uC000\u2265\u20D2;\uC000>\u20D2nfin;\u69DE\u0180Aet\u2CBD\u2CC1\u2CC5rr;\u6902;\uC000\u2264\u20D2\u0100;r\u2CCA\u2CCD\uC000<\u20D2ie;\uC000\u22B4\u20D2\u0100At\u2CD8\u2CDCrr;\u6903rie;\uC000\u22B5\u20D2im;\uC000\u223C\u20D2\u0180Aan\u2CF0\u2CF4\u2D02rr;\u61D6r\u0100hr\u2CFA\u2CFDk;\u6923\u0100;o\u13E7\u13E5ear;\u6927\u1253\u1A95\0\0\0\0\0\0\0\0\0\0\0\0\0\u2D2D\0\u2D38\u2D48\u2D60\u2D65\u2D72\u2D84\u1B07\0\0\u2D8D\u2DAB\0\u2DC8\u2DCE\0\u2DDC\u2E19\u2E2B\u2E3E\u2E43\u0100cs\u2D31\u1A97ute\u803B\xF3\u40F3\u0100iy\u2D3C\u2D45r\u0100;c\u1A9E\u2D42\u803B\xF4\u40F4;\u443E\u0280abios\u1AA0\u2D52\u2D57\u01C8\u2D5Alac;\u4151v;\u6A38old;\u69BClig;\u4153\u0100cr\u2D69\u2D6Dir;\u69BF;\uC000\u{1D52C}\u036F\u2D79\0\0\u2D7C\0\u2D82n;\u42DBave\u803B\xF2\u40F2;\u69C1\u0100bm\u2D88\u0DF4ar;\u69B5\u0200acit\u2D95\u2D98\u2DA5\u2DA8r\xF2\u1A80\u0100ir\u2D9D\u2DA0r;\u69BEoss;\u69BBn\xE5\u0E52;\u69C0\u0180aei\u2DB1\u2DB5\u2DB9cr;\u414Dga;\u43C9\u0180cdn\u2DC0\u2DC5\u01CDron;\u43BF;\u69B6pf;\uC000\u{1D560}\u0180ael\u2DD4\u2DD7\u01D2r;\u69B7rp;\u69B9\u0380;adiosv\u2DEA\u2DEB\u2DEE\u2E08\u2E0D\u2E10\u2E16\u6228r\xF2\u1A86\u0200;efm\u2DF7\u2DF8\u2E02\u2E05\u6A5Dr\u0100;o\u2DFE\u2DFF\u6134f\xBB\u2DFF\u803B\xAA\u40AA\u803B\xBA\u40BAgof;\u62B6r;\u6A56lope;\u6A57;\u6A5B\u0180clo\u2E1F\u2E21\u2E27\xF2\u2E01ash\u803B\xF8\u40F8l;\u6298i\u016C\u2E2F\u2E34de\u803B\xF5\u40F5es\u0100;a\u01DB\u2E3As;\u6A36ml\u803B\xF6\u40F6bar;\u633D\u0AE1\u2E5E\0\u2E7D\0\u2E80\u2E9D\0\u2EA2\u2EB9\0\0\u2ECB\u0E9C\0\u2F13\0\0\u2F2B\u2FBC\0\u2FC8r\u0200;ast\u0403\u2E67\u2E72\u0E85\u8100\xB6;l\u2E6D\u2E6E\u40B6le\xEC\u0403\u0269\u2E78\0\0\u2E7Bm;\u6AF3;\u6AFDy;\u443Fr\u0280cimpt\u2E8B\u2E8F\u2E93\u1865\u2E97nt;\u4025od;\u402Eil;\u6030enk;\u6031r;\uC000\u{1D52D}\u0180imo\u2EA8\u2EB0\u2EB4\u0100;v\u2EAD\u2EAE\u43C6;\u43D5ma\xF4\u0A76ne;\u660E\u0180;tv\u2EBF\u2EC0\u2EC8\u43C0chfork\xBB\u1FFD;\u43D6\u0100au\u2ECF\u2EDFn\u0100ck\u2ED5\u2EDDk\u0100;h\u21F4\u2EDB;\u610E\xF6\u21F4s\u0480;abcdemst\u2EF3\u2EF4\u1908\u2EF9\u2EFD\u2F04\u2F06\u2F0A\u2F0E\u402Bcir;\u6A23ir;\u6A22\u0100ou\u1D40\u2F02;\u6A25;\u6A72n\u80BB\xB1\u0E9Dim;\u6A26wo;\u6A27\u0180ipu\u2F19\u2F20\u2F25ntint;\u6A15f;\uC000\u{1D561}nd\u803B\xA3\u40A3\u0500;Eaceinosu\u0EC8\u2F3F\u2F41\u2F44\u2F47\u2F81\u2F89\u2F92\u2F7E\u2FB6;\u6AB3p;\u6AB7u\xE5\u0ED9\u0100;c\u0ECE\u2F4C\u0300;acens\u0EC8\u2F59\u2F5F\u2F66\u2F68\u2F7Eppro\xF8\u2F43urlye\xF1\u0ED9\xF1\u0ECE\u0180aes\u2F6F\u2F76\u2F7Approx;\u6AB9qq;\u6AB5im;\u62E8i\xED\u0EDFme\u0100;s\u2F88\u0EAE\u6032\u0180Eas\u2F78\u2F90\u2F7A\xF0\u2F75\u0180dfp\u0EEC\u2F99\u2FAF\u0180als\u2FA0\u2FA5\u2FAAlar;\u632Eine;\u6312urf;\u6313\u0100;t\u0EFB\u2FB4\xEF\u0EFBrel;\u62B0\u0100ci\u2FC0\u2FC5r;\uC000\u{1D4C5};\u43C8ncsp;\u6008\u0300fiopsu\u2FDA\u22E2\u2FDF\u2FE5\u2FEB\u2FF1r;\uC000\u{1D52E}pf;\uC000\u{1D562}rime;\u6057cr;\uC000\u{1D4C6}\u0180aeo\u2FF8\u3009\u3013t\u0100ei\u2FFE\u3005rnion\xF3\u06B0nt;\u6A16st\u0100;e\u3010\u3011\u403F\xF1\u1F19\xF4\u0F14\u0A80ABHabcdefhilmnoprstux\u3040\u3051\u3055\u3059\u30E0\u310E\u312B\u3147\u3162\u3172\u318E\u3206\u3215\u3224\u3229\u3258\u326E\u3272\u3290\u32B0\u32B7\u0180art\u3047\u304A\u304Cr\xF2\u10B3\xF2\u03DDail;\u691Car\xF2\u1C65ar;\u6964\u0380cdenqrt\u3068\u3075\u3078\u307F\u308F\u3094\u30CC\u0100eu\u306D\u3071;\uC000\u223D\u0331te;\u4155i\xE3\u116Emptyv;\u69B3g\u0200;del\u0FD1\u3089\u308B\u308D;\u6992;\u69A5\xE5\u0FD1uo\u803B\xBB\u40BBr\u0580;abcfhlpstw\u0FDC\u30AC\u30AF\u30B7\u30B9\u30BC\u30BE\u30C0\u30C3\u30C7\u30CAp;\u6975\u0100;f\u0FE0\u30B4s;\u6920;\u6933s;\u691E\xEB\u225D\xF0\u272El;\u6945im;\u6974l;\u61A3;\u619D\u0100ai\u30D1\u30D5il;\u691Ao\u0100;n\u30DB\u30DC\u6236al\xF3\u0F1E\u0180abr\u30E7\u30EA\u30EEr\xF2\u17E5rk;\u6773\u0100ak\u30F3\u30FDc\u0100ek\u30F9\u30FB;\u407D;\u405D\u0100es\u3102\u3104;\u698Cl\u0100du\u310A\u310C;\u698E;\u6990\u0200aeuy\u3117\u311C\u3127\u3129ron;\u4159\u0100di\u3121\u3125il;\u4157\xEC\u0FF2\xE2\u30FA;\u4440\u0200clqs\u3134\u3137\u313D\u3144a;\u6937dhar;\u6969uo\u0100;r\u020E\u020Dh;\u61B3\u0180acg\u314E\u315F\u0F44l\u0200;ips\u0F78\u3158\u315B\u109Cn\xE5\u10BBar\xF4\u0FA9t;\u65AD\u0180ilr\u3169\u1023\u316Esht;\u697D;\uC000\u{1D52F}\u0100ao\u3177\u3186r\u0100du\u317D\u317F\xBB\u047B\u0100;l\u1091\u3184;\u696C\u0100;v\u318B\u318C\u43C1;\u43F1\u0180gns\u3195\u31F9\u31FCht\u0300ahlrst\u31A4\u31B0\u31C2\u31D8\u31E4\u31EErrow\u0100;t\u0FDC\u31ADa\xE9\u30C8arpoon\u0100du\u31BB\u31BFow\xEE\u317Ep\xBB\u1092eft\u0100ah\u31CA\u31D0rrow\xF3\u0FEAarpoon\xF3\u0551ightarrows;\u61C9quigarro\xF7\u30CBhreetimes;\u62CCg;\u42DAingdotse\xF1\u1F32\u0180ahm\u320D\u3210\u3213r\xF2\u0FEAa\xF2\u0551;\u600Foust\u0100;a\u321E\u321F\u63B1che\xBB\u321Fmid;\u6AEE\u0200abpt\u3232\u323D\u3240\u3252\u0100nr\u3237\u323Ag;\u67EDr;\u61FEr\xEB\u1003\u0180afl\u3247\u324A\u324Er;\u6986;\uC000\u{1D563}us;\u6A2Eimes;\u6A35\u0100ap\u325D\u3267r\u0100;g\u3263\u3264\u4029t;\u6994olint;\u6A12ar\xF2\u31E3\u0200achq\u327B\u3280\u10BC\u3285quo;\u603Ar;\uC000\u{1D4C7}\u0100bu\u30FB\u328Ao\u0100;r\u0214\u0213\u0180hir\u3297\u329B\u32A0re\xE5\u31F8mes;\u62CAi\u0200;efl\u32AA\u1059\u1821\u32AB\u65B9tri;\u69CEluhar;\u6968;\u611E\u0D61\u32D5\u32DB\u32DF\u332C\u3338\u3371\0\u337A\u33A4\0\0\u33EC\u33F0\0\u3428\u3448\u345A\u34AD\u34B1\u34CA\u34F1\0\u3616\0\0\u3633cute;\u415Bqu\xEF\u27BA\u0500;Eaceinpsy\u11ED\u32F3\u32F5\u32FF\u3302\u330B\u330F\u331F\u3326\u3329;\u6AB4\u01F0\u32FA\0\u32FC;\u6AB8on;\u4161u\xE5\u11FE\u0100;d\u11F3\u3307il;\u415Frc;\u415D\u0180Eas\u3316\u3318\u331B;\u6AB6p;\u6ABAim;\u62E9olint;\u6A13i\xED\u1204;\u4441ot\u0180;be\u3334\u1D47\u3335\u62C5;\u6A66\u0380Aacmstx\u3346\u334A\u3357\u335B\u335E\u3363\u336Drr;\u61D8r\u0100hr\u3350\u3352\xEB\u2228\u0100;o\u0A36\u0A34t\u803B\xA7\u40A7i;\u403Bwar;\u6929m\u0100in\u3369\xF0nu\xF3\xF1t;\u6736r\u0100;o\u3376\u2055\uC000\u{1D530}\u0200acoy\u3382\u3386\u3391\u33A0rp;\u666F\u0100hy\u338B\u338Fcy;\u4449;\u4448rt\u026D\u3399\0\0\u339Ci\xE4\u1464ara\xEC\u2E6F\u803B\xAD\u40AD\u0100gm\u33A8\u33B4ma\u0180;fv\u33B1\u33B2\u33B2\u43C3;\u43C2\u0400;deglnpr\u12AB\u33C5\u33C9\u33CE\u33D6\u33DE\u33E1\u33E6ot;\u6A6A\u0100;q\u12B1\u12B0\u0100;E\u33D3\u33D4\u6A9E;\u6AA0\u0100;E\u33DB\u33DC\u6A9D;\u6A9Fe;\u6246lus;\u6A24arr;\u6972ar\xF2\u113D\u0200aeit\u33F8\u3408\u340F\u3417\u0100ls\u33FD\u3404lsetm\xE9\u336Ahp;\u6A33parsl;\u69E4\u0100dl\u1463\u3414e;\u6323\u0100;e\u341C\u341D\u6AAA\u0100;s\u3422\u3423\u6AAC;\uC000\u2AAC\uFE00\u0180flp\u342E\u3433\u3442tcy;\u444C\u0100;b\u3438\u3439\u402F\u0100;a\u343E\u343F\u69C4r;\u633Ff;\uC000\u{1D564}a\u0100dr\u344D\u0402es\u0100;u\u3454\u3455\u6660it\xBB\u3455\u0180csu\u3460\u3479\u349F\u0100au\u3465\u346Fp\u0100;s\u1188\u346B;\uC000\u2293\uFE00p\u0100;s\u11B4\u3475;\uC000\u2294\uFE00u\u0100bp\u347F\u348F\u0180;es\u1197\u119C\u3486et\u0100;e\u1197\u348D\xF1\u119D\u0180;es\u11A8\u11AD\u3496et\u0100;e\u11A8\u349D\xF1\u11AE\u0180;af\u117B\u34A6\u05B0r\u0165\u34AB\u05B1\xBB\u117Car\xF2\u1148\u0200cemt\u34B9\u34BE\u34C2\u34C5r;\uC000\u{1D4C8}tm\xEE\xF1i\xEC\u3415ar\xE6\u11BE\u0100ar\u34CE\u34D5r\u0100;f\u34D4\u17BF\u6606\u0100an\u34DA\u34EDight\u0100ep\u34E3\u34EApsilo\xEE\u1EE0h\xE9\u2EAFs\xBB\u2852\u0280bcmnp\u34FB\u355E\u1209\u358B\u358E\u0480;Edemnprs\u350E\u350F\u3511\u3515\u351E\u3523\u352C\u3531\u3536\u6282;\u6AC5ot;\u6ABD\u0100;d\u11DA\u351Aot;\u6AC3ult;\u6AC1\u0100Ee\u3528\u352A;\u6ACB;\u628Alus;\u6ABFarr;\u6979\u0180eiu\u353D\u3552\u3555t\u0180;en\u350E\u3545\u354Bq\u0100;q\u11DA\u350Feq\u0100;q\u352B\u3528m;\u6AC7\u0100bp\u355A\u355C;\u6AD5;\u6AD3c\u0300;acens\u11ED\u356C\u3572\u3579\u357B\u3326ppro\xF8\u32FAurlye\xF1\u11FE\xF1\u11F3\u0180aes\u3582\u3588\u331Bppro\xF8\u331Aq\xF1\u3317g;\u666A\u0680123;Edehlmnps\u35A9\u35AC\u35AF\u121C\u35B2\u35B4\u35C0\u35C9\u35D5\u35DA\u35DF\u35E8\u35ED\u803B\xB9\u40B9\u803B\xB2\u40B2\u803B\xB3\u40B3;\u6AC6\u0100os\u35B9\u35BCt;\u6ABEub;\u6AD8\u0100;d\u1222\u35C5ot;\u6AC4s\u0100ou\u35CF\u35D2l;\u67C9b;\u6AD7arr;\u697Bult;\u6AC2\u0100Ee\u35E4\u35E6;\u6ACC;\u628Blus;\u6AC0\u0180eiu\u35F4\u3609\u360Ct\u0180;en\u121C\u35FC\u3602q\u0100;q\u1222\u35B2eq\u0100;q\u35E7\u35E4m;\u6AC8\u0100bp\u3611\u3613;\u6AD4;\u6AD6\u0180Aan\u361C\u3620\u362Drr;\u61D9r\u0100hr\u3626\u3628\xEB\u222E\u0100;o\u0A2B\u0A29war;\u692Alig\u803B\xDF\u40DF\u0BE1\u3651\u365D\u3660\u12CE\u3673\u3679\0\u367E\u36C2\0\0\0\0\0\u36DB\u3703\0\u3709\u376C\0\0\0\u3787\u0272\u3656\0\0\u365Bget;\u6316;\u43C4r\xEB\u0E5F\u0180aey\u3666\u366B\u3670ron;\u4165dil;\u4163;\u4442lrec;\u6315r;\uC000\u{1D531}\u0200eiko\u3686\u369D\u36B5\u36BC\u01F2\u368B\0\u3691e\u01004f\u1284\u1281a\u0180;sv\u3698\u3699\u369B\u43B8ym;\u43D1\u0100cn\u36A2\u36B2k\u0100as\u36A8\u36AEppro\xF8\u12C1im\xBB\u12ACs\xF0\u129E\u0100as\u36BA\u36AE\xF0\u12C1rn\u803B\xFE\u40FE\u01EC\u031F\u36C6\u22E7es\u8180\xD7;bd\u36CF\u36D0\u36D8\u40D7\u0100;a\u190F\u36D5r;\u6A31;\u6A30\u0180eps\u36E1\u36E3\u3700\xE1\u2A4D\u0200;bcf\u0486\u36EC\u36F0\u36F4ot;\u6336ir;\u6AF1\u0100;o\u36F9\u36FC\uC000\u{1D565}rk;\u6ADA\xE1\u3362rime;\u6034\u0180aip\u370F\u3712\u3764d\xE5\u1248\u0380adempst\u3721\u374D\u3740\u3751\u3757\u375C\u375Fngle\u0280;dlqr\u3730\u3731\u3736\u3740\u3742\u65B5own\xBB\u1DBBeft\u0100;e\u2800\u373E\xF1\u092E;\u625Cight\u0100;e\u32AA\u374B\xF1\u105Aot;\u65ECinus;\u6A3Alus;\u6A39b;\u69CDime;\u6A3Bezium;\u63E2\u0180cht\u3772\u377D\u3781\u0100ry\u3777\u377B;\uC000\u{1D4C9};\u4446cy;\u445Brok;\u4167\u0100io\u378B\u378Ex\xF4\u1777head\u0100lr\u3797\u37A0eftarro\xF7\u084Fightarrow\xBB\u0F5D\u0900AHabcdfghlmoprstuw\u37D0\u37D3\u37D7\u37E4\u37F0\u37FC\u380E\u381C\u3823\u3834\u3851\u385D\u386B\u38A9\u38CC\u38D2\u38EA\u38F6r\xF2\u03EDar;\u6963\u0100cr\u37DC\u37E2ute\u803B\xFA\u40FA\xF2\u1150r\u01E3\u37EA\0\u37EDy;\u445Eve;\u416D\u0100iy\u37F5\u37FArc\u803B\xFB\u40FB;\u4443\u0180abh\u3803\u3806\u380Br\xF2\u13ADlac;\u4171a\xF2\u13C3\u0100ir\u3813\u3818sht;\u697E;\uC000\u{1D532}rave\u803B\xF9\u40F9\u0161\u3827\u3831r\u0100lr\u382C\u382E\xBB\u0957\xBB\u1083lk;\u6580\u0100ct\u3839\u384D\u026F\u383F\0\0\u384Arn\u0100;e\u3845\u3846\u631Cr\xBB\u3846op;\u630Fri;\u65F8\u0100al\u3856\u385Acr;\u416B\u80BB\xA8\u0349\u0100gp\u3862\u3866on;\u4173f;\uC000\u{1D566}\u0300adhlsu\u114B\u3878\u387D\u1372\u3891\u38A0own\xE1\u13B3arpoon\u0100lr\u3888\u388Cef\xF4\u382Digh\xF4\u382Fi\u0180;hl\u3899\u389A\u389C\u43C5\xBB\u13FAon\xBB\u389Aparrows;\u61C8\u0180cit\u38B0\u38C4\u38C8\u026F\u38B6\0\0\u38C1rn\u0100;e\u38BC\u38BD\u631Dr\xBB\u38BDop;\u630Eng;\u416Fri;\u65F9cr;\uC000\u{1D4CA}\u0180dir\u38D9\u38DD\u38E2ot;\u62F0lde;\u4169i\u0100;f\u3730\u38E8\xBB\u1813\u0100am\u38EF\u38F2r\xF2\u38A8l\u803B\xFC\u40FCangle;\u69A7\u0780ABDacdeflnoprsz\u391C\u391F\u3929\u392D\u39B5\u39B8\u39BD\u39DF\u39E4\u39E8\u39F3\u39F9\u39FD\u3A01\u3A20r\xF2\u03F7ar\u0100;v\u3926\u3927\u6AE8;\u6AE9as\xE8\u03E1\u0100nr\u3932\u3937grt;\u699C\u0380eknprst\u34E3\u3946\u394B\u3952\u395D\u3964\u3996app\xE1\u2415othin\xE7\u1E96\u0180hir\u34EB\u2EC8\u3959op\xF4\u2FB5\u0100;h\u13B7\u3962\xEF\u318D\u0100iu\u3969\u396Dgm\xE1\u33B3\u0100bp\u3972\u3984setneq\u0100;q\u397D\u3980\uC000\u228A\uFE00;\uC000\u2ACB\uFE00setneq\u0100;q\u398F\u3992\uC000\u228B\uFE00;\uC000\u2ACC\uFE00\u0100hr\u399B\u399Fet\xE1\u369Ciangle\u0100lr\u39AA\u39AFeft\xBB\u0925ight\xBB\u1051y;\u4432ash\xBB\u1036\u0180elr\u39C4\u39D2\u39D7\u0180;be\u2DEA\u39CB\u39CFar;\u62BBq;\u625Alip;\u62EE\u0100bt\u39DC\u1468a\xF2\u1469r;\uC000\u{1D533}tr\xE9\u39AEsu\u0100bp\u39EF\u39F1\xBB\u0D1C\xBB\u0D59pf;\uC000\u{1D567}ro\xF0\u0EFBtr\xE9\u39B4\u0100cu\u3A06\u3A0Br;\uC000\u{1D4CB}\u0100bp\u3A10\u3A18n\u0100Ee\u3980\u3A16\xBB\u397En\u0100Ee\u3992\u3A1E\xBB\u3990igzag;\u699A\u0380cefoprs\u3A36\u3A3B\u3A56\u3A5B\u3A54\u3A61\u3A6Airc;\u4175\u0100di\u3A40\u3A51\u0100bg\u3A45\u3A49ar;\u6A5Fe\u0100;q\u15FA\u3A4F;\u6259erp;\u6118r;\uC000\u{1D534}pf;\uC000\u{1D568}\u0100;e\u1479\u3A66at\xE8\u1479cr;\uC000\u{1D4CC}\u0AE3\u178E\u3A87\0\u3A8B\0\u3A90\u3A9B\0\0\u3A9D\u3AA8\u3AAB\u3AAF\0\0\u3AC3\u3ACE\0\u3AD8\u17DC\u17DFtr\xE9\u17D1r;\uC000\u{1D535}\u0100Aa\u3A94\u3A97r\xF2\u03C3r\xF2\u09F6;\u43BE\u0100Aa\u3AA1\u3AA4r\xF2\u03B8r\xF2\u09EBa\xF0\u2713is;\u62FB\u0180dpt\u17A4\u3AB5\u3ABE\u0100fl\u3ABA\u17A9;\uC000\u{1D569}im\xE5\u17B2\u0100Aa\u3AC7\u3ACAr\xF2\u03CEr\xF2\u0A01\u0100cq\u3AD2\u17B8r;\uC000\u{1D4CD}\u0100pt\u17D6\u3ADCr\xE9\u17D4\u0400acefiosu\u3AF0\u3AFD\u3B08\u3B0C\u3B11\u3B15\u3B1B\u3B21c\u0100uy\u3AF6\u3AFBte\u803B\xFD\u40FD;\u444F\u0100iy\u3B02\u3B06rc;\u4177;\u444Bn\u803B\xA5\u40A5r;\uC000\u{1D536}cy;\u4457pf;\uC000\u{1D56A}cr;\uC000\u{1D4CE}\u0100cm\u3B26\u3B29y;\u444El\u803B\xFF\u40FF\u0500acdefhiosw\u3B42\u3B48\u3B54\u3B58\u3B64\u3B69\u3B6D\u3B74\u3B7A\u3B80cute;\u417A\u0100ay\u3B4D\u3B52ron;\u417E;\u4437ot;\u417C\u0100et\u3B5D\u3B61tr\xE6\u155Fa;\u43B6r;\uC000\u{1D537}cy;\u4436grarr;\u61DDpf;\uC000\u{1D56B}cr;\uC000\u{1D4CF}\u0100jn\u3B85\u3B87;\u600Dj;\u600C'.split("").map(c2=>c2.charCodeAt(0)));init_browser_globals();init_browser_globals();var _a,decodeMap=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]),fromCodePoint=(_a=String.fromCodePoint)!==null&&_a!==void 0?_a:function(codePoint){let output="";return codePoint>65535&&(codePoint-=65536,output+=String.fromCharCode(codePoint>>>10&1023|55296),codePoint=56320|codePoint&1023),output+=String.fromCharCode(codePoint),output};function replaceCodePoint(codePoint){var _a2;return codePoint>=55296&&codePoint<=57343||codePoint>1114111?65533:(_a2=decodeMap.get(codePoint))!==null&&_a2!==void 0?_a2:codePoint}var CharCodes;(function(CharCodes2){CharCodes2[CharCodes2.NUM=35]="NUM",CharCodes2[CharCodes2.SEMI=59]="SEMI",CharCodes2[CharCodes2.EQUALS=61]="EQUALS",CharCodes2[CharCodes2.ZERO=48]="ZERO",CharCodes2[CharCodes2.NINE=57]="NINE",CharCodes2[CharCodes2.LOWER_A=97]="LOWER_A",CharCodes2[CharCodes2.LOWER_F=102]="LOWER_F",CharCodes2[CharCodes2.LOWER_X=120]="LOWER_X",CharCodes2[CharCodes2.LOWER_Z=122]="LOWER_Z",CharCodes2[CharCodes2.UPPER_A=65]="UPPER_A",CharCodes2[CharCodes2.UPPER_F=70]="UPPER_F",CharCodes2[CharCodes2.UPPER_Z=90]="UPPER_Z"})(CharCodes||(CharCodes={}));var TO_LOWER_BIT=32,BinTrieFlags;(function(BinTrieFlags2){BinTrieFlags2[BinTrieFlags2.VALUE_LENGTH=49152]="VALUE_LENGTH",BinTrieFlags2[BinTrieFlags2.BRANCH_LENGTH=16256]="BRANCH_LENGTH",BinTrieFlags2[BinTrieFlags2.JUMP_TABLE=127]="JUMP_TABLE"})(BinTrieFlags||(BinTrieFlags={}));function isNumber(code4){return code4>=CharCodes.ZERO&&code4<=CharCodes.NINE}function isHexadecimalCharacter(code4){return code4>=CharCodes.UPPER_A&&code4<=CharCodes.UPPER_F||code4>=CharCodes.LOWER_A&&code4<=CharCodes.LOWER_F}function isAsciiAlphaNumeric(code4){return code4>=CharCodes.UPPER_A&&code4<=CharCodes.UPPER_Z||code4>=CharCodes.LOWER_A&&code4<=CharCodes.LOWER_Z||isNumber(code4)}function isEntityInAttributeInvalidEnd(code4){return code4===CharCodes.EQUALS||isAsciiAlphaNumeric(code4)}var EntityDecoderState;(function(EntityDecoderState2){EntityDecoderState2[EntityDecoderState2.EntityStart=0]="EntityStart",EntityDecoderState2[EntityDecoderState2.NumericStart=1]="NumericStart",EntityDecoderState2[EntityDecoderState2.NumericDecimal=2]="NumericDecimal",EntityDecoderState2[EntityDecoderState2.NumericHex=3]="NumericHex",EntityDecoderState2[EntityDecoderState2.NamedEntity=4]="NamedEntity"})(EntityDecoderState||(EntityDecoderState={}));var DecodingMode;(function(DecodingMode2){DecodingMode2[DecodingMode2.Legacy=0]="Legacy",DecodingMode2[DecodingMode2.Strict=1]="Strict",DecodingMode2[DecodingMode2.Attribute=2]="Attribute"})(DecodingMode||(DecodingMode={}));var EntityDecoder=class{constructor(decodeTree,emitCodePoint,errors){this.decodeTree=decodeTree,this.emitCodePoint=emitCodePoint,this.errors=errors,this.state=EntityDecoderState.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=DecodingMode.Strict}startEntity(decodeMode){this.decodeMode=decodeMode,this.state=EntityDecoderState.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(input,offset){switch(this.state){case EntityDecoderState.EntityStart:return input.charCodeAt(offset)===CharCodes.NUM?(this.state=EntityDecoderState.NumericStart,this.consumed+=1,this.stateNumericStart(input,offset+1)):(this.state=EntityDecoderState.NamedEntity,this.stateNamedEntity(input,offset));case EntityDecoderState.NumericStart:return this.stateNumericStart(input,offset);case EntityDecoderState.NumericDecimal:return this.stateNumericDecimal(input,offset);case EntityDecoderState.NumericHex:return this.stateNumericHex(input,offset);case EntityDecoderState.NamedEntity:return this.stateNamedEntity(input,offset)}}stateNumericStart(input,offset){return offset>=input.length?-1:(input.charCodeAt(offset)|TO_LOWER_BIT)===CharCodes.LOWER_X?(this.state=EntityDecoderState.NumericHex,this.consumed+=1,this.stateNumericHex(input,offset+1)):(this.state=EntityDecoderState.NumericDecimal,this.stateNumericDecimal(input,offset))}addToNumericResult(input,start,end,base2){if(start!==end){let digitCount=end-start;this.result=this.result*Math.pow(base2,digitCount)+Number.parseInt(input.substr(start,digitCount),base2),this.consumed+=digitCount}}stateNumericHex(input,offset){let startIndex=offset;for(;offset<input.length;){let char=input.charCodeAt(offset);if(isNumber(char)||isHexadecimalCharacter(char))offset+=1;else return this.addToNumericResult(input,startIndex,offset,16),this.emitNumericEntity(char,3)}return this.addToNumericResult(input,startIndex,offset,16),-1}stateNumericDecimal(input,offset){let startIndex=offset;for(;offset<input.length;){let char=input.charCodeAt(offset);if(isNumber(char))offset+=1;else return this.addToNumericResult(input,startIndex,offset,10),this.emitNumericEntity(char,2)}return this.addToNumericResult(input,startIndex,offset,10),-1}emitNumericEntity(lastCp,expectedLength){var _a2;if(this.consumed<=expectedLength)return(_a2=this.errors)===null||_a2===void 0||_a2.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(lastCp===CharCodes.SEMI)this.consumed+=1;else if(this.decodeMode===DecodingMode.Strict)return 0;return this.emitCodePoint(replaceCodePoint(this.result),this.consumed),this.errors&&(lastCp!==CharCodes.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(input,offset){let{decodeTree}=this,current=decodeTree[this.treeIndex],valueLength=(current&BinTrieFlags.VALUE_LENGTH)>>14;for(;offset<input.length;offset++,this.excess++){let char=input.charCodeAt(offset);if(this.treeIndex=determineBranch(decodeTree,current,this.treeIndex+Math.max(1,valueLength),char),this.treeIndex<0)return this.result===0||this.decodeMode===DecodingMode.Attribute&&(valueLength===0||isEntityInAttributeInvalidEnd(char))?0:this.emitNotTerminatedNamedEntity();if(current=decodeTree[this.treeIndex],valueLength=(current&BinTrieFlags.VALUE_LENGTH)>>14,valueLength!==0){if(char===CharCodes.SEMI)return this.emitNamedEntityData(this.treeIndex,valueLength,this.consumed+this.excess);this.decodeMode!==DecodingMode.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var _a2;let{result,decodeTree}=this,valueLength=(decodeTree[result]&BinTrieFlags.VALUE_LENGTH)>>14;return this.emitNamedEntityData(result,valueLength,this.consumed),(_a2=this.errors)===null||_a2===void 0||_a2.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(result,valueLength,consumed){let{decodeTree}=this;return this.emitCodePoint(valueLength===1?decodeTree[result]&~BinTrieFlags.VALUE_LENGTH:decodeTree[result+1],consumed),valueLength===3&&this.emitCodePoint(decodeTree[result+2],consumed),consumed}end(){var _a2;switch(this.state){case EntityDecoderState.NamedEntity:return this.result!==0&&(this.decodeMode!==DecodingMode.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case EntityDecoderState.NumericDecimal:return this.emitNumericEntity(0,2);case EntityDecoderState.NumericHex:return this.emitNumericEntity(0,3);case EntityDecoderState.NumericStart:return(_a2=this.errors)===null||_a2===void 0||_a2.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case EntityDecoderState.EntityStart:return 0}}};function determineBranch(decodeTree,current,nodeIndex,char){let branchCount=(current&BinTrieFlags.BRANCH_LENGTH)>>7,jumpOffset=current&BinTrieFlags.JUMP_TABLE;if(branchCount===0)return jumpOffset!==0&&char===jumpOffset?nodeIndex:-1;if(jumpOffset){let value2=char-jumpOffset;return value2<0||value2>=branchCount?-1:decodeTree[nodeIndex+value2]-1}let lo=nodeIndex,hi=lo+branchCount-1;for(;lo<=hi;){let mid=lo+hi>>>1,midValue=decodeTree[mid];if(midValue<char)lo=mid+1;else if(midValue>char)hi=mid-1;else return decodeTree[mid+branchCount]}return-1}init_browser_globals();var NS;(function(NS2){NS2.HTML="http://www.w3.org/1999/xhtml",NS2.MATHML="http://www.w3.org/1998/Math/MathML",NS2.SVG="http://www.w3.org/2000/svg",NS2.XLINK="http://www.w3.org/1999/xlink",NS2.XML="http://www.w3.org/XML/1998/namespace",NS2.XMLNS="http://www.w3.org/2000/xmlns/"})(NS||(NS={}));var ATTRS;(function(ATTRS2){ATTRS2.TYPE="type",ATTRS2.ACTION="action",ATTRS2.ENCODING="encoding",ATTRS2.PROMPT="prompt",ATTRS2.NAME="name",ATTRS2.COLOR="color",ATTRS2.FACE="face",ATTRS2.SIZE="size"})(ATTRS||(ATTRS={}));var DOCUMENT_MODE;(function(DOCUMENT_MODE2){DOCUMENT_MODE2.NO_QUIRKS="no-quirks",DOCUMENT_MODE2.QUIRKS="quirks",DOCUMENT_MODE2.LIMITED_QUIRKS="limited-quirks"})(DOCUMENT_MODE||(DOCUMENT_MODE={}));var TAG_NAMES;(function(TAG_NAMES2){TAG_NAMES2.A="a",TAG_NAMES2.ADDRESS="address",TAG_NAMES2.ANNOTATION_XML="annotation-xml",TAG_NAMES2.APPLET="applet",TAG_NAMES2.AREA="area",TAG_NAMES2.ARTICLE="article",TAG_NAMES2.ASIDE="aside",TAG_NAMES2.B="b",TAG_NAMES2.BASE="base",TAG_NAMES2.BASEFONT="basefont",TAG_NAMES2.BGSOUND="bgsound",TAG_NAMES2.BIG="big",TAG_NAMES2.BLOCKQUOTE="blockquote",TAG_NAMES2.BODY="body",TAG_NAMES2.BR="br",TAG_NAMES2.BUTTON="button",TAG_NAMES2.CAPTION="caption",TAG_NAMES2.CENTER="center",TAG_NAMES2.CODE="code",TAG_NAMES2.COL="col",TAG_NAMES2.COLGROUP="colgroup",TAG_NAMES2.DD="dd",TAG_NAMES2.DESC="desc",TAG_NAMES2.DETAILS="details",TAG_NAMES2.DIALOG="dialog",TAG_NAMES2.DIR="dir",TAG_NAMES2.DIV="div",TAG_NAMES2.DL="dl",TAG_NAMES2.DT="dt",TAG_NAMES2.EM="em",TAG_NAMES2.EMBED="embed",TAG_NAMES2.FIELDSET="fieldset",TAG_NAMES2.FIGCAPTION="figcaption",TAG_NAMES2.FIGURE="figure",TAG_NAMES2.FONT="font",TAG_NAMES2.FOOTER="footer",TAG_NAMES2.FOREIGN_OBJECT="foreignObject",TAG_NAMES2.FORM="form",TAG_NAMES2.FRAME="frame",TAG_NAMES2.FRAMESET="frameset",TAG_NAMES2.H1="h1",TAG_NAMES2.H2="h2",TAG_NAMES2.H3="h3",TAG_NAMES2.H4="h4",TAG_NAMES2.H5="h5",TAG_NAMES2.H6="h6",TAG_NAMES2.HEAD="head",TAG_NAMES2.HEADER="header",TAG_NAMES2.HGROUP="hgroup",TAG_NAMES2.HR="hr",TAG_NAMES2.HTML="html",TAG_NAMES2.I="i",TAG_NAMES2.IMG="img",TAG_NAMES2.IMAGE="image",TAG_NAMES2.INPUT="input",TAG_NAMES2.IFRAME="iframe",TAG_NAMES2.KEYGEN="keygen",TAG_NAMES2.LABEL="label",TAG_NAMES2.LI="li",TAG_NAMES2.LINK="link",TAG_NAMES2.LISTING="listing",TAG_NAMES2.MAIN="main",TAG_NAMES2.MALIGNMARK="malignmark",TAG_NAMES2.MARQUEE="marquee",TAG_NAMES2.MATH="math",TAG_NAMES2.MENU="menu",TAG_NAMES2.META="meta",TAG_NAMES2.MGLYPH="mglyph",TAG_NAMES2.MI="mi",TAG_NAMES2.MO="mo",TAG_NAMES2.MN="mn",TAG_NAMES2.MS="ms",TAG_NAMES2.MTEXT="mtext",TAG_NAMES2.NAV="nav",TAG_NAMES2.NOBR="nobr",TAG_NAMES2.NOFRAMES="noframes",TAG_NAMES2.NOEMBED="noembed",TAG_NAMES2.NOSCRIPT="noscript",TAG_NAMES2.OBJECT="object",TAG_NAMES2.OL="ol",TAG_NAMES2.OPTGROUP="optgroup",TAG_NAMES2.OPTION="option",TAG_NAMES2.P="p",TAG_NAMES2.PARAM="param",TAG_NAMES2.PLAINTEXT="plaintext",TAG_NAMES2.PRE="pre",TAG_NAMES2.RB="rb",TAG_NAMES2.RP="rp",TAG_NAMES2.RT="rt",TAG_NAMES2.RTC="rtc",TAG_NAMES2.RUBY="ruby",TAG_NAMES2.S="s",TAG_NAMES2.SCRIPT="script",TAG_NAMES2.SEARCH="search",TAG_NAMES2.SECTION="section",TAG_NAMES2.SELECT="select",TAG_NAMES2.SOURCE="source",TAG_NAMES2.SMALL="small",TAG_NAMES2.SPAN="span",TAG_NAMES2.STRIKE="strike",TAG_NAMES2.STRONG="strong",TAG_NAMES2.STYLE="style",TAG_NAMES2.SUB="sub",TAG_NAMES2.SUMMARY="summary",TAG_NAMES2.SUP="sup",TAG_NAMES2.TABLE="table",TAG_NAMES2.TBODY="tbody",TAG_NAMES2.TEMPLATE="template",TAG_NAMES2.TEXTAREA="textarea",TAG_NAMES2.TFOOT="tfoot",TAG_NAMES2.TD="td",TAG_NAMES2.TH="th",TAG_NAMES2.THEAD="thead",TAG_NAMES2.TITLE="title",TAG_NAMES2.TR="tr",TAG_NAMES2.TRACK="track",TAG_NAMES2.TT="tt",TAG_NAMES2.U="u",TAG_NAMES2.UL="ul",TAG_NAMES2.SVG="svg",TAG_NAMES2.VAR="var",TAG_NAMES2.WBR="wbr",TAG_NAMES2.XMP="xmp"})(TAG_NAMES||(TAG_NAMES={}));var TAG_ID;(function(TAG_ID2){TAG_ID2[TAG_ID2.UNKNOWN=0]="UNKNOWN",TAG_ID2[TAG_ID2.A=1]="A",TAG_ID2[TAG_ID2.ADDRESS=2]="ADDRESS",TAG_ID2[TAG_ID2.ANNOTATION_XML=3]="ANNOTATION_XML",TAG_ID2[TAG_ID2.APPLET=4]="APPLET",TAG_ID2[TAG_ID2.AREA=5]="AREA",TAG_ID2[TAG_ID2.ARTICLE=6]="ARTICLE",TAG_ID2[TAG_ID2.ASIDE=7]="ASIDE",TAG_ID2[TAG_ID2.B=8]="B",TAG_ID2[TAG_ID2.BASE=9]="BASE",TAG_ID2[TAG_ID2.BASEFONT=10]="BASEFONT",TAG_ID2[TAG_ID2.BGSOUND=11]="BGSOUND",TAG_ID2[TAG_ID2.BIG=12]="BIG",TAG_ID2[TAG_ID2.BLOCKQUOTE=13]="BLOCKQUOTE",TAG_ID2[TAG_ID2.BODY=14]="BODY",TAG_ID2[TAG_ID2.BR=15]="BR",TAG_ID2[TAG_ID2.BUTTON=16]="BUTTON",TAG_ID2[TAG_ID2.CAPTION=17]="CAPTION",TAG_ID2[TAG_ID2.CENTER=18]="CENTER",TAG_ID2[TAG_ID2.CODE=19]="CODE",TAG_ID2[TAG_ID2.COL=20]="COL",TAG_ID2[TAG_ID2.COLGROUP=21]="COLGROUP",TAG_ID2[TAG_ID2.DD=22]="DD",TAG_ID2[TAG_ID2.DESC=23]="DESC",TAG_ID2[TAG_ID2.DETAILS=24]="DETAILS",TAG_ID2[TAG_ID2.DIALOG=25]="DIALOG",TAG_ID2[TAG_ID2.DIR=26]="DIR",TAG_ID2[TAG_ID2.DIV=27]="DIV",TAG_ID2[TAG_ID2.DL=28]="DL",TAG_ID2[TAG_ID2.DT=29]="DT",TAG_ID2[TAG_ID2.EM=30]="EM",TAG_ID2[TAG_ID2.EMBED=31]="EMBED",TAG_ID2[TAG_ID2.FIELDSET=32]="FIELDSET",TAG_ID2[TAG_ID2.FIGCAPTION=33]="FIGCAPTION",TAG_ID2[TAG_ID2.FIGURE=34]="FIGURE",TAG_ID2[TAG_ID2.FONT=35]="FONT",TAG_ID2[TAG_ID2.FOOTER=36]="FOOTER",TAG_ID2[TAG_ID2.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",TAG_ID2[TAG_ID2.FORM=38]="FORM",TAG_ID2[TAG_ID2.FRAME=39]="FRAME",TAG_ID2[TAG_ID2.FRAMESET=40]="FRAMESET",TAG_ID2[TAG_ID2.H1=41]="H1",TAG_ID2[TAG_ID2.H2=42]="H2",TAG_ID2[TAG_ID2.H3=43]="H3",TAG_ID2[TAG_ID2.H4=44]="H4",TAG_ID2[TAG_ID2.H5=45]="H5",TAG_ID2[TAG_ID2.H6=46]="H6",TAG_ID2[TAG_ID2.HEAD=47]="HEAD",TAG_ID2[TAG_ID2.HEADER=48]="HEADER",TAG_ID2[TAG_ID2.HGROUP=49]="HGROUP",TAG_ID2[TAG_ID2.HR=50]="HR",TAG_ID2[TAG_ID2.HTML=51]="HTML",TAG_ID2[TAG_ID2.I=52]="I",TAG_ID2[TAG_ID2.IMG=53]="IMG",TAG_ID2[TAG_ID2.IMAGE=54]="IMAGE",TAG_ID2[TAG_ID2.INPUT=55]="INPUT",TAG_ID2[TAG_ID2.IFRAME=56]="IFRAME",TAG_ID2[TAG_ID2.KEYGEN=57]="KEYGEN",TAG_ID2[TAG_ID2.LABEL=58]="LABEL",TAG_ID2[TAG_ID2.LI=59]="LI",TAG_ID2[TAG_ID2.LINK=60]="LINK",TAG_ID2[TAG_ID2.LISTING=61]="LISTING",TAG_ID2[TAG_ID2.MAIN=62]="MAIN",TAG_ID2[TAG_ID2.MALIGNMARK=63]="MALIGNMARK",TAG_ID2[TAG_ID2.MARQUEE=64]="MARQUEE",TAG_ID2[TAG_ID2.MATH=65]="MATH",TAG_ID2[TAG_ID2.MENU=66]="MENU",TAG_ID2[TAG_ID2.META=67]="META",TAG_ID2[TAG_ID2.MGLYPH=68]="MGLYPH",TAG_ID2[TAG_ID2.MI=69]="MI",TAG_ID2[TAG_ID2.MO=70]="MO",TAG_ID2[TAG_ID2.MN=71]="MN",TAG_ID2[TAG_ID2.MS=72]="MS",TAG_ID2[TAG_ID2.MTEXT=73]="MTEXT",TAG_ID2[TAG_ID2.NAV=74]="NAV",TAG_ID2[TAG_ID2.NOBR=75]="NOBR",TAG_ID2[TAG_ID2.NOFRAMES=76]="NOFRAMES",TAG_ID2[TAG_ID2.NOEMBED=77]="NOEMBED",TAG_ID2[TAG_ID2.NOSCRIPT=78]="NOSCRIPT",TAG_ID2[TAG_ID2.OBJECT=79]="OBJECT",TAG_ID2[TAG_ID2.OL=80]="OL",TAG_ID2[TAG_ID2.OPTGROUP=81]="OPTGROUP",TAG_ID2[TAG_ID2.OPTION=82]="OPTION",TAG_ID2[TAG_ID2.P=83]="P",TAG_ID2[TAG_ID2.PARAM=84]="PARAM",TAG_ID2[TAG_ID2.PLAINTEXT=85]="PLAINTEXT",TAG_ID2[TAG_ID2.PRE=86]="PRE",TAG_ID2[TAG_ID2.RB=87]="RB",TAG_ID2[TAG_ID2.RP=88]="RP",TAG_ID2[TAG_ID2.RT=89]="RT",TAG_ID2[TAG_ID2.RTC=90]="RTC",TAG_ID2[TAG_ID2.RUBY=91]="RUBY",TAG_ID2[TAG_ID2.S=92]="S",TAG_ID2[TAG_ID2.SCRIPT=93]="SCRIPT",TAG_ID2[TAG_ID2.SEARCH=94]="SEARCH",TAG_ID2[TAG_ID2.SECTION=95]="SECTION",TAG_ID2[TAG_ID2.SELECT=96]="SELECT",TAG_ID2[TAG_ID2.SOURCE=97]="SOURCE",TAG_ID2[TAG_ID2.SMALL=98]="SMALL",TAG_ID2[TAG_ID2.SPAN=99]="SPAN",TAG_ID2[TAG_ID2.STRIKE=100]="STRIKE",TAG_ID2[TAG_ID2.STRONG=101]="STRONG",TAG_ID2[TAG_ID2.STYLE=102]="STYLE",TAG_ID2[TAG_ID2.SUB=103]="SUB",TAG_ID2[TAG_ID2.SUMMARY=104]="SUMMARY",TAG_ID2[TAG_ID2.SUP=105]="SUP",TAG_ID2[TAG_ID2.TABLE=106]="TABLE",TAG_ID2[TAG_ID2.TBODY=107]="TBODY",TAG_ID2[TAG_ID2.TEMPLATE=108]="TEMPLATE",TAG_ID2[TAG_ID2.TEXTAREA=109]="TEXTAREA",TAG_ID2[TAG_ID2.TFOOT=110]="TFOOT",TAG_ID2[TAG_ID2.TD=111]="TD",TAG_ID2[TAG_ID2.TH=112]="TH",TAG_ID2[TAG_ID2.THEAD=113]="THEAD",TAG_ID2[TAG_ID2.TITLE=114]="TITLE",TAG_ID2[TAG_ID2.TR=115]="TR",TAG_ID2[TAG_ID2.TRACK=116]="TRACK",TAG_ID2[TAG_ID2.TT=117]="TT",TAG_ID2[TAG_ID2.U=118]="U",TAG_ID2[TAG_ID2.UL=119]="UL",TAG_ID2[TAG_ID2.SVG=120]="SVG",TAG_ID2[TAG_ID2.VAR=121]="VAR",TAG_ID2[TAG_ID2.WBR=122]="WBR",TAG_ID2[TAG_ID2.XMP=123]="XMP"})(TAG_ID||(TAG_ID={}));var TAG_NAME_TO_ID=new Map([[TAG_NAMES.A,TAG_ID.A],[TAG_NAMES.ADDRESS,TAG_ID.ADDRESS],[TAG_NAMES.ANNOTATION_XML,TAG_ID.ANNOTATION_XML],[TAG_NAMES.APPLET,TAG_ID.APPLET],[TAG_NAMES.AREA,TAG_ID.AREA],[TAG_NAMES.ARTICLE,TAG_ID.ARTICLE],[TAG_NAMES.ASIDE,TAG_ID.ASIDE],[TAG_NAMES.B,TAG_ID.B],[TAG_NAMES.BASE,TAG_ID.BASE],[TAG_NAMES.BASEFONT,TAG_ID.BASEFONT],[TAG_NAMES.BGSOUND,TAG_ID.BGSOUND],[TAG_NAMES.BIG,TAG_ID.BIG],[TAG_NAMES.BLOCKQUOTE,TAG_ID.BLOCKQUOTE],[TAG_NAMES.BODY,TAG_ID.BODY],[TAG_NAMES.BR,TAG_ID.BR],[TAG_NAMES.BUTTON,TAG_ID.BUTTON],[TAG_NAMES.CAPTION,TAG_ID.CAPTION],[TAG_NAMES.CENTER,TAG_ID.CENTER],[TAG_NAMES.CODE,TAG_ID.CODE],[TAG_NAMES.COL,TAG_ID.COL],[TAG_NAMES.COLGROUP,TAG_ID.COLGROUP],[TAG_NAMES.DD,TAG_ID.DD],[TAG_NAMES.DESC,TAG_ID.DESC],[TAG_NAMES.DETAILS,TAG_ID.DETAILS],[TAG_NAMES.DIALOG,TAG_ID.DIALOG],[TAG_NAMES.DIR,TAG_ID.DIR],[TAG_NAMES.DIV,TAG_ID.DIV],[TAG_NAMES.DL,TAG_ID.DL],[TAG_NAMES.DT,TAG_ID.DT],[TAG_NAMES.EM,TAG_ID.EM],[TAG_NAMES.EMBED,TAG_ID.EMBED],[TAG_NAMES.FIELDSET,TAG_ID.FIELDSET],[TAG_NAMES.FIGCAPTION,TAG_ID.FIGCAPTION],[TAG_NAMES.FIGURE,TAG_ID.FIGURE],[TAG_NAMES.FONT,TAG_ID.FONT],[TAG_NAMES.FOOTER,TAG_ID.FOOTER],[TAG_NAMES.FOREIGN_OBJECT,TAG_ID.FOREIGN_OBJECT],[TAG_NAMES.FORM,TAG_ID.FORM],[TAG_NAMES.FRAME,TAG_ID.FRAME],[TAG_NAMES.FRAMESET,TAG_ID.FRAMESET],[TAG_NAMES.H1,TAG_ID.H1],[TAG_NAMES.H2,TAG_ID.H2],[TAG_NAMES.H3,TAG_ID.H3],[TAG_NAMES.H4,TAG_ID.H4],[TAG_NAMES.H5,TAG_ID.H5],[TAG_NAMES.H6,TAG_ID.H6],[TAG_NAMES.HEAD,TAG_ID.HEAD],[TAG_NAMES.HEADER,TAG_ID.HEADER],[TAG_NAMES.HGROUP,TAG_ID.HGROUP],[TAG_NAMES.HR,TAG_ID.HR],[TAG_NAMES.HTML,TAG_ID.HTML],[TAG_NAMES.I,TAG_ID.I],[TAG_NAMES.IMG,TAG_ID.IMG],[TAG_NAMES.IMAGE,TAG_ID.IMAGE],[TAG_NAMES.INPUT,TAG_ID.INPUT],[TAG_NAMES.IFRAME,TAG_ID.IFRAME],[TAG_NAMES.KEYGEN,TAG_ID.KEYGEN],[TAG_NAMES.LABEL,TAG_ID.LABEL],[TAG_NAMES.LI,TAG_ID.LI],[TAG_NAMES.LINK,TAG_ID.LINK],[TAG_NAMES.LISTING,TAG_ID.LISTING],[TAG_NAMES.MAIN,TAG_ID.MAIN],[TAG_NAMES.MALIGNMARK,TAG_ID.MALIGNMARK],[TAG_NAMES.MARQUEE,TAG_ID.MARQUEE],[TAG_NAMES.MATH,TAG_ID.MATH],[TAG_NAMES.MENU,TAG_ID.MENU],[TAG_NAMES.META,TAG_ID.META],[TAG_NAMES.MGLYPH,TAG_ID.MGLYPH],[TAG_NAMES.MI,TAG_ID.MI],[TAG_NAMES.MO,TAG_ID.MO],[TAG_NAMES.MN,TAG_ID.MN],[TAG_NAMES.MS,TAG_ID.MS],[TAG_NAMES.MTEXT,TAG_ID.MTEXT],[TAG_NAMES.NAV,TAG_ID.NAV],[TAG_NAMES.NOBR,TAG_ID.NOBR],[TAG_NAMES.NOFRAMES,TAG_ID.NOFRAMES],[TAG_NAMES.NOEMBED,TAG_ID.NOEMBED],[TAG_NAMES.NOSCRIPT,TAG_ID.NOSCRIPT],[TAG_NAMES.OBJECT,TAG_ID.OBJECT],[TAG_NAMES.OL,TAG_ID.OL],[TAG_NAMES.OPTGROUP,TAG_ID.OPTGROUP],[TAG_NAMES.OPTION,TAG_ID.OPTION],[TAG_NAMES.P,TAG_ID.P],[TAG_NAMES.PARAM,TAG_ID.PARAM],[TAG_NAMES.PLAINTEXT,TAG_ID.PLAINTEXT],[TAG_NAMES.PRE,TAG_ID.PRE],[TAG_NAMES.RB,TAG_ID.RB],[TAG_NAMES.RP,TAG_ID.RP],[TAG_NAMES.RT,TAG_ID.RT],[TAG_NAMES.RTC,TAG_ID.RTC],[TAG_NAMES.RUBY,TAG_ID.RUBY],[TAG_NAMES.S,TAG_ID.S],[TAG_NAMES.SCRIPT,TAG_ID.SCRIPT],[TAG_NAMES.SEARCH,TAG_ID.SEARCH],[TAG_NAMES.SECTION,TAG_ID.SECTION],[TAG_NAMES.SELECT,TAG_ID.SELECT],[TAG_NAMES.SOURCE,TAG_ID.SOURCE],[TAG_NAMES.SMALL,TAG_ID.SMALL],[TAG_NAMES.SPAN,TAG_ID.SPAN],[TAG_NAMES.STRIKE,TAG_ID.STRIKE],[TAG_NAMES.STRONG,TAG_ID.STRONG],[TAG_NAMES.STYLE,TAG_ID.STYLE],[TAG_NAMES.SUB,TAG_ID.SUB],[TAG_NAMES.SUMMARY,TAG_ID.SUMMARY],[TAG_NAMES.SUP,TAG_ID.SUP],[TAG_NAMES.TABLE,TAG_ID.TABLE],[TAG_NAMES.TBODY,TAG_ID.TBODY],[TAG_NAMES.TEMPLATE,TAG_ID.TEMPLATE],[TAG_NAMES.TEXTAREA,TAG_ID.TEXTAREA],[TAG_NAMES.TFOOT,TAG_ID.TFOOT],[TAG_NAMES.TD,TAG_ID.TD],[TAG_NAMES.TH,TAG_ID.TH],[TAG_NAMES.THEAD,TAG_ID.THEAD],[TAG_NAMES.TITLE,TAG_ID.TITLE],[TAG_NAMES.TR,TAG_ID.TR],[TAG_NAMES.TRACK,TAG_ID.TRACK],[TAG_NAMES.TT,TAG_ID.TT],[TAG_NAMES.U,TAG_ID.U],[TAG_NAMES.UL,TAG_ID.UL],[TAG_NAMES.SVG,TAG_ID.SVG],[TAG_NAMES.VAR,TAG_ID.VAR],[TAG_NAMES.WBR,TAG_ID.WBR],[TAG_NAMES.XMP,TAG_ID.XMP]]);function getTagID(tagName){var _a2;return(_a2=TAG_NAME_TO_ID.get(tagName))!==null&&_a2!==void 0?_a2:TAG_ID.UNKNOWN}var $2=TAG_ID,SPECIAL_ELEMENTS={[NS.HTML]:new Set([$2.ADDRESS,$2.APPLET,$2.AREA,$2.ARTICLE,$2.ASIDE,$2.BASE,$2.BASEFONT,$2.BGSOUND,$2.BLOCKQUOTE,$2.BODY,$2.BR,$2.BUTTON,$2.CAPTION,$2.CENTER,$2.COL,$2.COLGROUP,$2.DD,$2.DETAILS,$2.DIR,$2.DIV,$2.DL,$2.DT,$2.EMBED,$2.FIELDSET,$2.FIGCAPTION,$2.FIGURE,$2.FOOTER,$2.FORM,$2.FRAME,$2.FRAMESET,$2.H1,$2.H2,$2.H3,$2.H4,$2.H5,$2.H6,$2.HEAD,$2.HEADER,$2.HGROUP,$2.HR,$2.HTML,$2.IFRAME,$2.IMG,$2.INPUT,$2.LI,$2.LINK,$2.LISTING,$2.MAIN,$2.MARQUEE,$2.MENU,$2.META,$2.NAV,$2.NOEMBED,$2.NOFRAMES,$2.NOSCRIPT,$2.OBJECT,$2.OL,$2.P,$2.PARAM,$2.PLAINTEXT,$2.PRE,$2.SCRIPT,$2.SECTION,$2.SELECT,$2.SOURCE,$2.STYLE,$2.SUMMARY,$2.TABLE,$2.TBODY,$2.TD,$2.TEMPLATE,$2.TEXTAREA,$2.TFOOT,$2.TH,$2.THEAD,$2.TITLE,$2.TR,$2.TRACK,$2.UL,$2.WBR,$2.XMP]),[NS.MATHML]:new Set([$2.MI,$2.MO,$2.MN,$2.MS,$2.MTEXT,$2.ANNOTATION_XML]),[NS.SVG]:new Set([$2.TITLE,$2.FOREIGN_OBJECT,$2.DESC]),[NS.XLINK]:new Set,[NS.XML]:new Set,[NS.XMLNS]:new Set},NUMBERED_HEADERS=new Set([$2.H1,$2.H2,$2.H3,$2.H4,$2.H5,$2.H6]),UNESCAPED_TEXT=new Set([TAG_NAMES.STYLE,TAG_NAMES.SCRIPT,TAG_NAMES.XMP,TAG_NAMES.IFRAME,TAG_NAMES.NOEMBED,TAG_NAMES.NOFRAMES,TAG_NAMES.PLAINTEXT]);var State;(function(State2){State2[State2.DATA=0]="DATA",State2[State2.RCDATA=1]="RCDATA",State2[State2.RAWTEXT=2]="RAWTEXT",State2[State2.SCRIPT_DATA=3]="SCRIPT_DATA",State2[State2.PLAINTEXT=4]="PLAINTEXT",State2[State2.TAG_OPEN=5]="TAG_OPEN",State2[State2.END_TAG_OPEN=6]="END_TAG_OPEN",State2[State2.TAG_NAME=7]="TAG_NAME",State2[State2.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",State2[State2.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",State2[State2.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",State2[State2.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",State2[State2.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",State2[State2.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",State2[State2.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",State2[State2.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",State2[State2.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",State2[State2.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",State2[State2.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",State2[State2.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",State2[State2.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",State2[State2.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",State2[State2.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",State2[State2.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",State2[State2.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",State2[State2.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",State2[State2.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",State2[State2.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",State2[State2.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",State2[State2.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",State2[State2.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",State2[State2.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",State2[State2.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",State2[State2.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",State2[State2.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",State2[State2.BOGUS_COMMENT=40]="BOGUS_COMMENT",State2[State2.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",State2[State2.COMMENT_START=42]="COMMENT_START",State2[State2.COMMENT_START_DASH=43]="COMMENT_START_DASH",State2[State2.COMMENT=44]="COMMENT",State2[State2.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",State2[State2.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",State2[State2.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",State2[State2.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",State2[State2.COMMENT_END_DASH=49]="COMMENT_END_DASH",State2[State2.COMMENT_END=50]="COMMENT_END",State2[State2.COMMENT_END_BANG=51]="COMMENT_END_BANG",State2[State2.DOCTYPE=52]="DOCTYPE",State2[State2.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",State2[State2.DOCTYPE_NAME=54]="DOCTYPE_NAME",State2[State2.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",State2[State2.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",State2[State2.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",State2[State2.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",State2[State2.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",State2[State2.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",State2[State2.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",State2[State2.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",State2[State2.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",State2[State2.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",State2[State2.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",State2[State2.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",State2[State2.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",State2[State2.CDATA_SECTION=68]="CDATA_SECTION",State2[State2.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",State2[State2.CDATA_SECTION_END=70]="CDATA_SECTION_END",State2[State2.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",State2[State2.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(State||(State={}));var TokenizerMode={DATA:State.DATA,RCDATA:State.RCDATA,RAWTEXT:State.RAWTEXT,SCRIPT_DATA:State.SCRIPT_DATA,PLAINTEXT:State.PLAINTEXT,CDATA_SECTION:State.CDATA_SECTION};function isAsciiDigit(cp){return cp>=CODE_POINTS.DIGIT_0&&cp<=CODE_POINTS.DIGIT_9}function isAsciiUpper(cp){return cp>=CODE_POINTS.LATIN_CAPITAL_A&&cp<=CODE_POINTS.LATIN_CAPITAL_Z}function isAsciiLower(cp){return cp>=CODE_POINTS.LATIN_SMALL_A&&cp<=CODE_POINTS.LATIN_SMALL_Z}function isAsciiLetter(cp){return isAsciiLower(cp)||isAsciiUpper(cp)}function isAsciiAlphaNumeric2(cp){return isAsciiLetter(cp)||isAsciiDigit(cp)}function toAsciiLower(cp){return cp+32}function isWhitespace(cp){return cp===CODE_POINTS.SPACE||cp===CODE_POINTS.LINE_FEED||cp===CODE_POINTS.TABULATION||cp===CODE_POINTS.FORM_FEED}function isScriptDataDoubleEscapeSequenceEnd(cp){return isWhitespace(cp)||cp===CODE_POINTS.SOLIDUS||cp===CODE_POINTS.GREATER_THAN_SIGN}function getErrorForNumericCharacterReference(code4){return code4===CODE_POINTS.NULL?ERR.nullCharacterReference:code4>1114111?ERR.characterReferenceOutsideUnicodeRange:isSurrogate(code4)?ERR.surrogateCharacterReference:isUndefinedCodePoint(code4)?ERR.noncharacterCharacterReference:isControlCodePoint(code4)||code4===CODE_POINTS.CARRIAGE_RETURN?ERR.controlCharacterReference:null}var Tokenizer=class{constructor(options2,handler2){this.options=options2,this.handler=handler2,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=State.DATA,this.returnState=State.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new Preprocessor(handler2),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new EntityDecoder(htmlDecodeTree,(cp,consumed)=>{this.preprocessor.pos=this.entityStartPos+consumed-1,this._flushCodePointConsumedAsCharacterReference(cp)},handler2.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(ERR.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:consumed=>{this._err(ERR.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+consumed)},validateNumericCharacterReference:code4=>{let error=getErrorForNumericCharacterReference(code4);error&&this._err(error,1)}}:void 0)}_err(code4,cpOffset=0){var _a2,_b;(_b=(_a2=this.handler).onParseError)===null||_b===void 0||_b.call(_a2,this.preprocessor.getError(code4,cpOffset))}getCurrentLocation(offset){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-offset,startOffset:this.preprocessor.offset-offset,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;let cp=this._consume();this._ensureHibernation()||this._callState(cp)}this.inLoop=!1}}pause(){this.paused=!0}resume(writeCallback){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||writeCallback?.())}write(chunk,isLastChunk,writeCallback){this.active=!0,this.preprocessor.write(chunk,isLastChunk),this._runParsingLoop(),this.paused||writeCallback?.()}insertHtmlAtCurrentPos(chunk){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(chunk),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(count){this.consumedAfterSnapshot+=count;for(let i2=0;i2<count;i2++)this.preprocessor.advance()}_consumeSequenceIfMatch(pattern,caseSensitive){return this.preprocessor.startsWith(pattern,caseSensitive)?(this._advanceBy(pattern.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:TokenType.START_TAG,tagName:"",tagID:TAG_ID.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:TokenType.END_TAG,tagName:"",tagID:TAG_ID.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(offset){this.currentToken={type:TokenType.COMMENT,data:"",location:this.getCurrentLocation(offset)}}_createDoctypeToken(initialName){this.currentToken={type:TokenType.DOCTYPE,name:initialName,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(type,chars){this.currentCharacterToken={type,chars,location:this.currentLocation}}_createAttr(attrNameFirstCh){this.currentAttr={name:attrNameFirstCh,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var _a2,_b;let token=this.currentToken;if(getTokenAttr(token,this.currentAttr.name)===null){if(token.attrs.push(this.currentAttr),token.location&&this.currentLocation){let attrLocations=(_a2=(_b=token.location).attrs)!==null&&_a2!==void 0?_a2:_b.attrs=Object.create(null);attrLocations[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(ERR.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(ct2){this._emitCurrentCharacterToken(ct2.location),this.currentToken=null,ct2.location&&(ct2.location.endLine=this.preprocessor.line,ct2.location.endCol=this.preprocessor.col+1,ct2.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){let ct2=this.currentToken;this.prepareToken(ct2),ct2.tagID=getTagID(ct2.tagName),ct2.type===TokenType.START_TAG?(this.lastStartTagName=ct2.tagName,this.handler.onStartTag(ct2)):(ct2.attrs.length>0&&this._err(ERR.endTagWithAttributes),ct2.selfClosing&&this._err(ERR.endTagWithTrailingSolidus),this.handler.onEndTag(ct2)),this.preprocessor.dropParsedChunk()}emitCurrentComment(ct2){this.prepareToken(ct2),this.handler.onComment(ct2),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(ct2){this.prepareToken(ct2),this.handler.onDoctype(ct2),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(nextLocation){if(this.currentCharacterToken){switch(nextLocation&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=nextLocation.startLine,this.currentCharacterToken.location.endCol=nextLocation.startCol,this.currentCharacterToken.location.endOffset=nextLocation.startOffset),this.currentCharacterToken.type){case TokenType.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case TokenType.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case TokenType.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){let location2=this.getCurrentLocation(0);location2&&(location2.endLine=location2.startLine,location2.endCol=location2.startCol,location2.endOffset=location2.startOffset),this._emitCurrentCharacterToken(location2),this.handler.onEof({type:TokenType.EOF,location:location2}),this.active=!1}_appendCharToCurrentCharacterToken(type,ch){if(this.currentCharacterToken)if(this.currentCharacterToken.type===type){this.currentCharacterToken.chars+=ch;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(type,ch)}_emitCodePoint(cp){let type=isWhitespace(cp)?TokenType.WHITESPACE_CHARACTER:cp===CODE_POINTS.NULL?TokenType.NULL_CHARACTER:TokenType.CHARACTER;this._appendCharToCurrentCharacterToken(type,String.fromCodePoint(cp))}_emitChars(ch){this._appendCharToCurrentCharacterToken(TokenType.CHARACTER,ch)}_startCharacterReference(){this.returnState=this.state,this.state=State.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?DecodingMode.Attribute:DecodingMode.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===State.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===State.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===State.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(cp){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(cp):this._emitCodePoint(cp)}_callState(cp){switch(this.state){case State.DATA:{this._stateData(cp);break}case State.RCDATA:{this._stateRcdata(cp);break}case State.RAWTEXT:{this._stateRawtext(cp);break}case State.SCRIPT_DATA:{this._stateScriptData(cp);break}case State.PLAINTEXT:{this._statePlaintext(cp);break}case State.TAG_OPEN:{this._stateTagOpen(cp);break}case State.END_TAG_OPEN:{this._stateEndTagOpen(cp);break}case State.TAG_NAME:{this._stateTagName(cp);break}case State.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(cp);break}case State.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(cp);break}case State.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(cp);break}case State.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(cp);break}case State.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(cp);break}case State.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(cp);break}case State.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(cp);break}case State.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(cp);break}case State.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(cp);break}case State.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(cp);break}case State.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(cp);break}case State.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(cp);break}case State.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(cp);break}case State.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(cp);break}case State.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(cp);break}case State.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(cp);break}case State.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(cp);break}case State.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(cp);break}case State.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(cp);break}case State.ATTRIBUTE_NAME:{this._stateAttributeName(cp);break}case State.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(cp);break}case State.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(cp);break}case State.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(cp);break}case State.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(cp);break}case State.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(cp);break}case State.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(cp);break}case State.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(cp);break}case State.BOGUS_COMMENT:{this._stateBogusComment(cp);break}case State.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(cp);break}case State.COMMENT_START:{this._stateCommentStart(cp);break}case State.COMMENT_START_DASH:{this._stateCommentStartDash(cp);break}case State.COMMENT:{this._stateComment(cp);break}case State.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(cp);break}case State.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(cp);break}case State.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(cp);break}case State.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(cp);break}case State.COMMENT_END_DASH:{this._stateCommentEndDash(cp);break}case State.COMMENT_END:{this._stateCommentEnd(cp);break}case State.COMMENT_END_BANG:{this._stateCommentEndBang(cp);break}case State.DOCTYPE:{this._stateDoctype(cp);break}case State.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(cp);break}case State.DOCTYPE_NAME:{this._stateDoctypeName(cp);break}case State.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(cp);break}case State.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(cp);break}case State.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(cp);break}case State.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(cp);break}case State.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(cp);break}case State.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(cp);break}case State.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(cp);break}case State.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(cp);break}case State.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(cp);break}case State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(cp);break}case State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(cp);break}case State.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(cp);break}case State.BOGUS_DOCTYPE:{this._stateBogusDoctype(cp);break}case State.CDATA_SECTION:{this._stateCdataSection(cp);break}case State.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(cp);break}case State.CDATA_SECTION_END:{this._stateCdataSectionEnd(cp);break}case State.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case State.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(cp);break}default:throw new Error("Unknown state")}}_stateData(cp){switch(cp){case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.TAG_OPEN;break}case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitCodePoint(cp);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateRcdata(cp){switch(cp){case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.RCDATA_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateRawtext(cp){switch(cp){case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.RAWTEXT_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateScriptData(cp){switch(cp){case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_statePlaintext(cp){switch(cp){case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateTagOpen(cp){if(isAsciiLetter(cp))this._createStartTagToken(),this.state=State.TAG_NAME,this._stateTagName(cp);else switch(cp){case CODE_POINTS.EXCLAMATION_MARK:{this.state=State.MARKUP_DECLARATION_OPEN;break}case CODE_POINTS.SOLIDUS:{this.state=State.END_TAG_OPEN;break}case CODE_POINTS.QUESTION_MARK:{this._err(ERR.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=State.BOGUS_COMMENT,this._stateBogusComment(cp);break}case CODE_POINTS.EOF:{this._err(ERR.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(ERR.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=State.DATA,this._stateData(cp)}}_stateEndTagOpen(cp){if(isAsciiLetter(cp))this._createEndTagToken(),this.state=State.TAG_NAME,this._stateTagName(cp);else switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingEndTagName),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(ERR.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=State.BOGUS_COMMENT,this._stateBogusComment(cp)}}_stateTagName(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BEFORE_ATTRIBUTE_NAME;break}case CODE_POINTS.SOLIDUS:{this.state=State.SELF_CLOSING_START_TAG;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.tagName+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:token.tagName+=String.fromCodePoint(isAsciiUpper(cp)?toAsciiLower(cp):cp)}}_stateRcdataLessThanSign(cp){cp===CODE_POINTS.SOLIDUS?this.state=State.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=State.RCDATA,this._stateRcdata(cp))}_stateRcdataEndTagOpen(cp){isAsciiLetter(cp)?(this.state=State.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(cp)):(this._emitChars("</"),this.state=State.RCDATA,this._stateRcdata(cp))}handleSpecialEndTag(_cp){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();let token=this.currentToken;switch(token.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=State.BEFORE_ATTRIBUTE_NAME,!1;case CODE_POINTS.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=State.SELF_CLOSING_START_TAG,!1;case CODE_POINTS.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=State.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(cp){this.handleSpecialEndTag(cp)&&(this._emitChars("</"),this.state=State.RCDATA,this._stateRcdata(cp))}_stateRawtextLessThanSign(cp){cp===CODE_POINTS.SOLIDUS?this.state=State.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=State.RAWTEXT,this._stateRawtext(cp))}_stateRawtextEndTagOpen(cp){isAsciiLetter(cp)?(this.state=State.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(cp)):(this._emitChars("</"),this.state=State.RAWTEXT,this._stateRawtext(cp))}_stateRawtextEndTagName(cp){this.handleSpecialEndTag(cp)&&(this._emitChars("</"),this.state=State.RAWTEXT,this._stateRawtext(cp))}_stateScriptDataLessThanSign(cp){switch(cp){case CODE_POINTS.SOLIDUS:{this.state=State.SCRIPT_DATA_END_TAG_OPEN;break}case CODE_POINTS.EXCLAMATION_MARK:{this.state=State.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=State.SCRIPT_DATA,this._stateScriptData(cp)}}_stateScriptDataEndTagOpen(cp){isAsciiLetter(cp)?(this.state=State.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(cp)):(this._emitChars("</"),this.state=State.SCRIPT_DATA,this._stateScriptData(cp))}_stateScriptDataEndTagName(cp){this.handleSpecialEndTag(cp)&&(this._emitChars("</"),this.state=State.SCRIPT_DATA,this._stateScriptData(cp))}_stateScriptDataEscapeStart(cp){cp===CODE_POINTS.HYPHEN_MINUS?(this.state=State.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=State.SCRIPT_DATA,this._stateScriptData(cp))}_stateScriptDataEscapeStartDash(cp){cp===CODE_POINTS.HYPHEN_MINUS?(this.state=State.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=State.SCRIPT_DATA,this._stateScriptData(cp))}_stateScriptDataEscaped(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateScriptDataEscapedDash(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.state=State.SCRIPT_DATA_ESCAPED,this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=State.SCRIPT_DATA_ESCAPED,this._emitCodePoint(cp)}}_stateScriptDataEscapedDashDash(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.SCRIPT_DATA,this._emitChars(">");break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.state=State.SCRIPT_DATA_ESCAPED,this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=State.SCRIPT_DATA_ESCAPED,this._emitCodePoint(cp)}}_stateScriptDataEscapedLessThanSign(cp){cp===CODE_POINTS.SOLIDUS?this.state=State.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:isAsciiLetter(cp)?(this._emitChars("<"),this.state=State.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(cp)):(this._emitChars("<"),this.state=State.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(cp))}_stateScriptDataEscapedEndTagOpen(cp){isAsciiLetter(cp)?(this.state=State.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(cp)):(this._emitChars("</"),this.state=State.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(cp))}_stateScriptDataEscapedEndTagName(cp){this.handleSpecialEndTag(cp)&&(this._emitChars("</"),this.state=State.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(cp))}_stateScriptDataDoubleEscapeStart(cp){if(this.preprocessor.startsWith(SEQUENCES.SCRIPT,!1)&&isScriptDataDoubleEscapeSequenceEnd(this.preprocessor.peek(SEQUENCES.SCRIPT.length))){this._emitCodePoint(cp);for(let i2=0;i2<SEQUENCES.SCRIPT.length;i2++)this._emitCodePoint(this._consume());this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=State.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(cp))}_stateScriptDataDoubleEscaped(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateScriptDataDoubleEscapedDash(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(cp)}}_stateScriptDataDoubleEscapedDashDash(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this._emitChars("-");break}case CODE_POINTS.LESS_THAN_SIGN:{this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.SCRIPT_DATA,this._emitChars(">");break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(REPLACEMENT_CHARACTER);break}case CODE_POINTS.EOF:{this._err(ERR.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(cp)}}_stateScriptDataDoubleEscapedLessThanSign(cp){cp===CODE_POINTS.SOLIDUS?(this.state=State.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(cp))}_stateScriptDataDoubleEscapeEnd(cp){if(this.preprocessor.startsWith(SEQUENCES.SCRIPT,!1)&&isScriptDataDoubleEscapeSequenceEnd(this.preprocessor.peek(SEQUENCES.SCRIPT.length))){this._emitCodePoint(cp);for(let i2=0;i2<SEQUENCES.SCRIPT.length;i2++)this._emitCodePoint(this._consume());this.state=State.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=State.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(cp))}_stateBeforeAttributeName(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.SOLIDUS:case CODE_POINTS.GREATER_THAN_SIGN:case CODE_POINTS.EOF:{this.state=State.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(cp);break}case CODE_POINTS.EQUALS_SIGN:{this._err(ERR.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=State.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=State.ATTRIBUTE_NAME,this._stateAttributeName(cp)}}_stateAttributeName(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:case CODE_POINTS.SOLIDUS:case CODE_POINTS.GREATER_THAN_SIGN:case CODE_POINTS.EOF:{this._leaveAttrName(),this.state=State.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(cp);break}case CODE_POINTS.EQUALS_SIGN:{this._leaveAttrName(),this.state=State.BEFORE_ATTRIBUTE_VALUE;break}case CODE_POINTS.QUOTATION_MARK:case CODE_POINTS.APOSTROPHE:case CODE_POINTS.LESS_THAN_SIGN:{this._err(ERR.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(cp);break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.currentAttr.name+=REPLACEMENT_CHARACTER;break}default:this.currentAttr.name+=String.fromCodePoint(isAsciiUpper(cp)?toAsciiLower(cp):cp)}}_stateAfterAttributeName(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.SOLIDUS:{this.state=State.SELF_CLOSING_START_TAG;break}case CODE_POINTS.EQUALS_SIGN:{this.state=State.BEFORE_ATTRIBUTE_VALUE;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=State.ATTRIBUTE_NAME,this._stateAttributeName(cp)}}_stateBeforeAttributeValue(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.QUOTATION_MARK:{this.state=State.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{this.state=State.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingAttributeValue),this.state=State.DATA,this.emitCurrentTagToken();break}default:this.state=State.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(cp)}}_stateAttributeValueDoubleQuoted(cp){switch(cp){case CODE_POINTS.QUOTATION_MARK:{this.state=State.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.currentAttr.value+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(cp)}}_stateAttributeValueSingleQuoted(cp){switch(cp){case CODE_POINTS.APOSTROPHE:{this.state=State.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.currentAttr.value+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(cp)}}_stateAttributeValueUnquoted(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this._leaveAttrValue(),this.state=State.BEFORE_ATTRIBUTE_NAME;break}case CODE_POINTS.AMPERSAND:{this._startCharacterReference();break}case CODE_POINTS.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this.currentAttr.value+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.QUOTATION_MARK:case CODE_POINTS.APOSTROPHE:case CODE_POINTS.LESS_THAN_SIGN:case CODE_POINTS.EQUALS_SIGN:case CODE_POINTS.GRAVE_ACCENT:{this._err(ERR.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(cp);break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(cp)}}_stateAfterAttributeValueQuoted(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this._leaveAttrValue(),this.state=State.BEFORE_ATTRIBUTE_NAME;break}case CODE_POINTS.SOLIDUS:{this._leaveAttrValue(),this.state=State.SELF_CLOSING_START_TAG;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this._err(ERR.missingWhitespaceBetweenAttributes),this.state=State.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(cp)}}_stateSelfClosingStartTag(cp){switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{let token=this.currentToken;token.selfClosing=!0,this.state=State.DATA,this.emitCurrentTagToken();break}case CODE_POINTS.EOF:{this._err(ERR.eofInTag),this._emitEOFToken();break}default:this._err(ERR.unexpectedSolidusInTag),this.state=State.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(cp)}}_stateBogusComment(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentComment(token);break}case CODE_POINTS.EOF:{this.emitCurrentComment(token),this._emitEOFToken();break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.data+=REPLACEMENT_CHARACTER;break}default:token.data+=String.fromCodePoint(cp)}}_stateMarkupDeclarationOpen(cp){this._consumeSequenceIfMatch(SEQUENCES.DASH_DASH,!0)?(this._createCommentToken(SEQUENCES.DASH_DASH.length+1),this.state=State.COMMENT_START):this._consumeSequenceIfMatch(SEQUENCES.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(SEQUENCES.DOCTYPE.length+1),this.state=State.DOCTYPE):this._consumeSequenceIfMatch(SEQUENCES.CDATA_START,!0)?this.inForeignNode?this.state=State.CDATA_SECTION:(this._err(ERR.cdataInHtmlContent),this._createCommentToken(SEQUENCES.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=State.BOGUS_COMMENT):this._ensureHibernation()||(this._err(ERR.incorrectlyOpenedComment),this._createCommentToken(2),this.state=State.BOGUS_COMMENT,this._stateBogusComment(cp))}_stateCommentStart(cp){switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.COMMENT_START_DASH;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptClosingOfEmptyComment),this.state=State.DATA;let token=this.currentToken;this.emitCurrentComment(token);break}default:this.state=State.COMMENT,this._stateComment(cp)}}_stateCommentStartDash(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.COMMENT_END;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptClosingOfEmptyComment),this.state=State.DATA,this.emitCurrentComment(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+="-",this.state=State.COMMENT,this._stateComment(cp)}}_stateComment(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.COMMENT_END_DASH;break}case CODE_POINTS.LESS_THAN_SIGN:{token.data+="<",this.state=State.COMMENT_LESS_THAN_SIGN;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.data+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+=String.fromCodePoint(cp)}}_stateCommentLessThanSign(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.EXCLAMATION_MARK:{token.data+="!",this.state=State.COMMENT_LESS_THAN_SIGN_BANG;break}case CODE_POINTS.LESS_THAN_SIGN:{token.data+="<";break}default:this.state=State.COMMENT,this._stateComment(cp)}}_stateCommentLessThanSignBang(cp){cp===CODE_POINTS.HYPHEN_MINUS?this.state=State.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=State.COMMENT,this._stateComment(cp))}_stateCommentLessThanSignBangDash(cp){cp===CODE_POINTS.HYPHEN_MINUS?this.state=State.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=State.COMMENT_END_DASH,this._stateCommentEndDash(cp))}_stateCommentLessThanSignBangDashDash(cp){cp!==CODE_POINTS.GREATER_THAN_SIGN&&cp!==CODE_POINTS.EOF&&this._err(ERR.nestedComment),this.state=State.COMMENT_END,this._stateCommentEnd(cp)}_stateCommentEndDash(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.HYPHEN_MINUS:{this.state=State.COMMENT_END;break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+="-",this.state=State.COMMENT,this._stateComment(cp)}}_stateCommentEnd(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentComment(token);break}case CODE_POINTS.EXCLAMATION_MARK:{this.state=State.COMMENT_END_BANG;break}case CODE_POINTS.HYPHEN_MINUS:{token.data+="-";break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+="--",this.state=State.COMMENT,this._stateComment(cp)}}_stateCommentEndBang(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.HYPHEN_MINUS:{token.data+="--!",this.state=State.COMMENT_END_DASH;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.incorrectlyClosedComment),this.state=State.DATA,this.emitCurrentComment(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInComment),this.emitCurrentComment(token),this._emitEOFToken();break}default:token.data+="--!",this.state=State.COMMENT,this._stateComment(cp)}}_stateDoctype(cp){switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BEFORE_DOCTYPE_NAME;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(cp);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),this._createDoctypeToken(null);let token=this.currentToken;token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingWhitespaceBeforeDoctypeName),this.state=State.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(cp)}}_stateBeforeDoctypeName(cp){if(isAsciiUpper(cp))this._createDoctypeToken(String.fromCharCode(toAsciiLower(cp))),this.state=State.DOCTYPE_NAME;else switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),this._createDoctypeToken(REPLACEMENT_CHARACTER),this.state=State.DOCTYPE_NAME;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypeName),this._createDoctypeToken(null);let token=this.currentToken;token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),this._createDoctypeToken(null);let token=this.currentToken;token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(cp)),this.state=State.DOCTYPE_NAME}}_stateDoctypeName(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.AFTER_DOCTYPE_NAME;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.name+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.name+=String.fromCodePoint(isAsciiUpper(cp)?toAsciiLower(cp):cp)}}_stateAfterDoctypeName(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(SEQUENCES.PUBLIC,!1)?this.state=State.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(SEQUENCES.SYSTEM,!1)?this.state=State.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(ERR.invalidCharacterSequenceAfterDoctypeName),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp))}}_stateAfterDoctypePublicKeyword(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case CODE_POINTS.QUOTATION_MARK:{this._err(ERR.missingWhitespaceAfterDoctypePublicKeyword),token.publicId="",this.state=State.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{this._err(ERR.missingWhitespaceAfterDoctypePublicKeyword),token.publicId="",this.state=State.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypePublicIdentifier),token.forceQuirks=!0,this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypePublicIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateBeforeDoctypePublicIdentifier(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.QUOTATION_MARK:{token.publicId="",this.state=State.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{token.publicId="",this.state=State.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypePublicIdentifier),token.forceQuirks=!0,this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypePublicIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateDoctypePublicIdentifierDoubleQuoted(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.QUOTATION_MARK:{this.state=State.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.publicId+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptDoctypePublicIdentifier),token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.publicId+=String.fromCodePoint(cp)}}_stateDoctypePublicIdentifierSingleQuoted(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.APOSTROPHE:{this.state=State.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.publicId+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptDoctypePublicIdentifier),token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.publicId+=String.fromCodePoint(cp)}}_stateAfterDoctypePublicIdentifier(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.QUOTATION_MARK:{this._err(ERR.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{this._err(ERR.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateBetweenDoctypePublicAndSystemIdentifiers(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.GREATER_THAN_SIGN:{this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.QUOTATION_MARK:{token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateAfterDoctypeSystemKeyword(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:{this.state=State.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case CODE_POINTS.QUOTATION_MARK:{this._err(ERR.missingWhitespaceAfterDoctypeSystemKeyword),token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{this._err(ERR.missingWhitespaceAfterDoctypeSystemKeyword),token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateBeforeDoctypeSystemIdentifier(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.QUOTATION_MARK:{token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case CODE_POINTS.APOSTROPHE:{token.systemId="",this.state=State.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.missingDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.DATA,this.emitCurrentDoctype(token);break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.missingQuoteBeforeDoctypeSystemIdentifier),token.forceQuirks=!0,this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateDoctypeSystemIdentifierDoubleQuoted(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.QUOTATION_MARK:{this.state=State.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.systemId+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptDoctypeSystemIdentifier),token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.systemId+=String.fromCodePoint(cp)}}_stateDoctypeSystemIdentifierSingleQuoted(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.APOSTROPHE:{this.state=State.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter),token.systemId+=REPLACEMENT_CHARACTER;break}case CODE_POINTS.GREATER_THAN_SIGN:{this._err(ERR.abruptDoctypeSystemIdentifier),token.forceQuirks=!0,this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:token.systemId+=String.fromCodePoint(cp)}}_stateAfterDoctypeSystemIdentifier(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.SPACE:case CODE_POINTS.LINE_FEED:case CODE_POINTS.TABULATION:case CODE_POINTS.FORM_FEED:break;case CODE_POINTS.GREATER_THAN_SIGN:{this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.EOF:{this._err(ERR.eofInDoctype),token.forceQuirks=!0,this.emitCurrentDoctype(token),this._emitEOFToken();break}default:this._err(ERR.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=State.BOGUS_DOCTYPE,this._stateBogusDoctype(cp)}}_stateBogusDoctype(cp){let token=this.currentToken;switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this.emitCurrentDoctype(token),this.state=State.DATA;break}case CODE_POINTS.NULL:{this._err(ERR.unexpectedNullCharacter);break}case CODE_POINTS.EOF:{this.emitCurrentDoctype(token),this._emitEOFToken();break}default:}}_stateCdataSection(cp){switch(cp){case CODE_POINTS.RIGHT_SQUARE_BRACKET:{this.state=State.CDATA_SECTION_BRACKET;break}case CODE_POINTS.EOF:{this._err(ERR.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(cp)}}_stateCdataSectionBracket(cp){cp===CODE_POINTS.RIGHT_SQUARE_BRACKET?this.state=State.CDATA_SECTION_END:(this._emitChars("]"),this.state=State.CDATA_SECTION,this._stateCdataSection(cp))}_stateCdataSectionEnd(cp){switch(cp){case CODE_POINTS.GREATER_THAN_SIGN:{this.state=State.DATA;break}case CODE_POINTS.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=State.CDATA_SECTION,this._stateCdataSection(cp)}}_stateCharacterReference(){let length=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(length<0)if(this.preprocessor.lastChunkWritten)length=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}length===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(CODE_POINTS.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&isAsciiAlphaNumeric2(this.preprocessor.peek(1))?State.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(cp){isAsciiAlphaNumeric2(cp)?this._flushCodePointConsumedAsCharacterReference(cp):(cp===CODE_POINTS.SEMICOLON&&this._err(ERR.unknownNamedCharacterReference),this.state=this.returnState,this._callState(cp))}};init_browser_globals();var IMPLICIT_END_TAG_REQUIRED=new Set([TAG_ID.DD,TAG_ID.DT,TAG_ID.LI,TAG_ID.OPTGROUP,TAG_ID.OPTION,TAG_ID.P,TAG_ID.RB,TAG_ID.RP,TAG_ID.RT,TAG_ID.RTC]),IMPLICIT_END_TAG_REQUIRED_THOROUGHLY=new Set([...IMPLICIT_END_TAG_REQUIRED,TAG_ID.CAPTION,TAG_ID.COLGROUP,TAG_ID.TBODY,TAG_ID.TD,TAG_ID.TFOOT,TAG_ID.TH,TAG_ID.THEAD,TAG_ID.TR]),SCOPING_ELEMENTS_HTML=new Set([TAG_ID.APPLET,TAG_ID.CAPTION,TAG_ID.HTML,TAG_ID.MARQUEE,TAG_ID.OBJECT,TAG_ID.TABLE,TAG_ID.TD,TAG_ID.TEMPLATE,TAG_ID.TH]),SCOPING_ELEMENTS_HTML_LIST=new Set([...SCOPING_ELEMENTS_HTML,TAG_ID.OL,TAG_ID.UL]),SCOPING_ELEMENTS_HTML_BUTTON=new Set([...SCOPING_ELEMENTS_HTML,TAG_ID.BUTTON]),SCOPING_ELEMENTS_MATHML=new Set([TAG_ID.ANNOTATION_XML,TAG_ID.MI,TAG_ID.MN,TAG_ID.MO,TAG_ID.MS,TAG_ID.MTEXT]),SCOPING_ELEMENTS_SVG=new Set([TAG_ID.DESC,TAG_ID.FOREIGN_OBJECT,TAG_ID.TITLE]),TABLE_ROW_CONTEXT=new Set([TAG_ID.TR,TAG_ID.TEMPLATE,TAG_ID.HTML]),TABLE_BODY_CONTEXT=new Set([TAG_ID.TBODY,TAG_ID.TFOOT,TAG_ID.THEAD,TAG_ID.TEMPLATE,TAG_ID.HTML]),TABLE_CONTEXT=new Set([TAG_ID.TABLE,TAG_ID.TEMPLATE,TAG_ID.HTML]),TABLE_CELLS=new Set([TAG_ID.TD,TAG_ID.TH]),OpenElementStack=class{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(document5,treeAdapter,handler2){this.treeAdapter=treeAdapter,this.handler=handler2,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=TAG_ID.UNKNOWN,this.current=document5}_indexOf(element){return this.items.lastIndexOf(element,this.stackTop)}_isInTemplate(){return this.currentTagId===TAG_ID.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===NS.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(element,tagID){this.stackTop++,this.items[this.stackTop]=element,this.current=element,this.tagIDs[this.stackTop]=tagID,this.currentTagId=tagID,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(element,tagID,!0)}pop(){let popped=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(popped,!0)}replace(oldElement,newElement){let idx=this._indexOf(oldElement);this.items[idx]=newElement,idx===this.stackTop&&(this.current=newElement)}insertAfter(referenceElement,newElement,newElementID){let insertionIdx=this._indexOf(referenceElement)+1;this.items.splice(insertionIdx,0,newElement),this.tagIDs.splice(insertionIdx,0,newElementID),this.stackTop++,insertionIdx===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,insertionIdx===this.stackTop)}popUntilTagNamePopped(tagName){let targetIdx=this.stackTop+1;do targetIdx=this.tagIDs.lastIndexOf(tagName,targetIdx-1);while(targetIdx>0&&this.treeAdapter.getNamespaceURI(this.items[targetIdx])!==NS.HTML);this.shortenToLength(Math.max(targetIdx,0))}shortenToLength(idx){for(;this.stackTop>=idx;){let popped=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(popped,this.stackTop<idx)}}popUntilElementPopped(element){let idx=this._indexOf(element);this.shortenToLength(Math.max(idx,0))}popUntilPopped(tagNames,targetNS){let idx=this._indexOfTagNames(tagNames,targetNS);this.shortenToLength(Math.max(idx,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(NUMBERED_HEADERS,NS.HTML)}popUntilTableCellPopped(){this.popUntilPopped(TABLE_CELLS,NS.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(tagNames,namespace){for(let i2=this.stackTop;i2>=0;i2--)if(tagNames.has(this.tagIDs[i2])&&this.treeAdapter.getNamespaceURI(this.items[i2])===namespace)return i2;return-1}clearBackTo(tagNames,targetNS){let idx=this._indexOfTagNames(tagNames,targetNS);this.shortenToLength(idx+1)}clearBackToTableContext(){this.clearBackTo(TABLE_CONTEXT,NS.HTML)}clearBackToTableBodyContext(){this.clearBackTo(TABLE_BODY_CONTEXT,NS.HTML)}clearBackToTableRowContext(){this.clearBackTo(TABLE_ROW_CONTEXT,NS.HTML)}remove(element){let idx=this._indexOf(element);idx>=0&&(idx===this.stackTop?this.pop():(this.items.splice(idx,1),this.tagIDs.splice(idx,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(element,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===TAG_ID.BODY?this.items[1]:null}contains(element){return this._indexOf(element)>-1}getCommonAncestor(element){let elementIdx=this._indexOf(element)-1;return elementIdx>=0?this.items[elementIdx]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===TAG_ID.HTML}hasInDynamicScope(tagName,htmlScope){for(let i2=this.stackTop;i2>=0;i2--){let tn2=this.tagIDs[i2];switch(this.treeAdapter.getNamespaceURI(this.items[i2])){case NS.HTML:{if(tn2===tagName)return!0;if(htmlScope.has(tn2))return!1;break}case NS.SVG:{if(SCOPING_ELEMENTS_SVG.has(tn2))return!1;break}case NS.MATHML:{if(SCOPING_ELEMENTS_MATHML.has(tn2))return!1;break}}}return!0}hasInScope(tagName){return this.hasInDynamicScope(tagName,SCOPING_ELEMENTS_HTML)}hasInListItemScope(tagName){return this.hasInDynamicScope(tagName,SCOPING_ELEMENTS_HTML_LIST)}hasInButtonScope(tagName){return this.hasInDynamicScope(tagName,SCOPING_ELEMENTS_HTML_BUTTON)}hasNumberedHeaderInScope(){for(let i2=this.stackTop;i2>=0;i2--){let tn2=this.tagIDs[i2];switch(this.treeAdapter.getNamespaceURI(this.items[i2])){case NS.HTML:{if(NUMBERED_HEADERS.has(tn2))return!0;if(SCOPING_ELEMENTS_HTML.has(tn2))return!1;break}case NS.SVG:{if(SCOPING_ELEMENTS_SVG.has(tn2))return!1;break}case NS.MATHML:{if(SCOPING_ELEMENTS_MATHML.has(tn2))return!1;break}}}return!0}hasInTableScope(tagName){for(let i2=this.stackTop;i2>=0;i2--)if(this.treeAdapter.getNamespaceURI(this.items[i2])===NS.HTML)switch(this.tagIDs[i2]){case tagName:return!0;case TAG_ID.TABLE:case TAG_ID.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let i2=this.stackTop;i2>=0;i2--)if(this.treeAdapter.getNamespaceURI(this.items[i2])===NS.HTML)switch(this.tagIDs[i2]){case TAG_ID.TBODY:case TAG_ID.THEAD:case TAG_ID.TFOOT:return!0;case TAG_ID.TABLE:case TAG_ID.HTML:return!1}return!0}hasInSelectScope(tagName){for(let i2=this.stackTop;i2>=0;i2--)if(this.treeAdapter.getNamespaceURI(this.items[i2])===NS.HTML)switch(this.tagIDs[i2]){case tagName:return!0;case TAG_ID.OPTION:case TAG_ID.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&IMPLICIT_END_TAG_REQUIRED.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&IMPLICIT_END_TAG_REQUIRED_THOROUGHLY.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(exclusionId){for(;this.currentTagId!==void 0&&this.currentTagId!==exclusionId&&IMPLICIT_END_TAG_REQUIRED_THOROUGHLY.has(this.currentTagId);)this.pop()}};init_browser_globals();var EntryType;(function(EntryType2){EntryType2[EntryType2.Marker=0]="Marker",EntryType2[EntryType2.Element=1]="Element"})(EntryType||(EntryType={}));var MARKER={type:EntryType.Marker},FormattingElementList=class{constructor(treeAdapter){this.treeAdapter=treeAdapter,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(newElement,neAttrs){let candidates2=[],neAttrsLength=neAttrs.length,neTagName=this.treeAdapter.getTagName(newElement),neNamespaceURI=this.treeAdapter.getNamespaceURI(newElement);for(let i2=0;i2<this.entries.length;i2++){let entry=this.entries[i2];if(entry.type===EntryType.Marker)break;let{element}=entry;if(this.treeAdapter.getTagName(element)===neTagName&&this.treeAdapter.getNamespaceURI(element)===neNamespaceURI){let elementAttrs=this.treeAdapter.getAttrList(element);elementAttrs.length===neAttrsLength&&candidates2.push({idx:i2,attrs:elementAttrs})}}return candidates2}_ensureNoahArkCondition(newElement){if(this.entries.length<3)return;let neAttrs=this.treeAdapter.getAttrList(newElement),candidates2=this._getNoahArkConditionCandidates(newElement,neAttrs);if(candidates2.length<3)return;let neAttrsMap=new Map(neAttrs.map(neAttr=>[neAttr.name,neAttr.value])),validCandidates=0;for(let i2=0;i2<candidates2.length;i2++){let candidate=candidates2[i2];candidate.attrs.every(cAttr=>neAttrsMap.get(cAttr.name)===cAttr.value)&&(validCandidates+=1,validCandidates>=3&&this.entries.splice(candidate.idx,1))}}insertMarker(){this.entries.unshift(MARKER)}pushElement(element,token){this._ensureNoahArkCondition(element),this.entries.unshift({type:EntryType.Element,element,token})}insertElementAfterBookmark(element,token){let bookmarkIdx=this.entries.indexOf(this.bookmark);this.entries.splice(bookmarkIdx,0,{type:EntryType.Element,element,token})}removeEntry(entry){let entryIndex=this.entries.indexOf(entry);entryIndex!==-1&&this.entries.splice(entryIndex,1)}clearToLastMarker(){let markerIdx=this.entries.indexOf(MARKER);markerIdx===-1?this.entries.length=0:this.entries.splice(0,markerIdx+1)}getElementEntryInScopeWithTagName(tagName){let entry=this.entries.find(entry2=>entry2.type===EntryType.Marker||this.treeAdapter.getTagName(entry2.element)===tagName);return entry&&entry.type===EntryType.Element?entry:null}getElementEntry(element){return this.entries.find(entry=>entry.type===EntryType.Element&&entry.element===element)}};init_browser_globals();var defaultTreeAdapter={createDocument(){return{nodeName:"#document",mode:DOCUMENT_MODE.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(tagName,namespaceURI,attrs){return{nodeName:tagName,tagName,attrs,namespaceURI,childNodes:[],parentNode:null}},createCommentNode(data){return{nodeName:"#comment",data,parentNode:null}},createTextNode(value2){return{nodeName:"#text",value:value2,parentNode:null}},appendChild(parentNode,newNode){parentNode.childNodes.push(newNode),newNode.parentNode=parentNode},insertBefore(parentNode,newNode,referenceNode){let insertionIdx=parentNode.childNodes.indexOf(referenceNode);parentNode.childNodes.splice(insertionIdx,0,newNode),newNode.parentNode=parentNode},setTemplateContent(templateElement,contentElement){templateElement.content=contentElement},getTemplateContent(templateElement){return templateElement.content},setDocumentType(document5,name,publicId,systemId){let doctypeNode=document5.childNodes.find(node2=>node2.nodeName==="#documentType");if(doctypeNode)doctypeNode.name=name,doctypeNode.publicId=publicId,doctypeNode.systemId=systemId;else{let node2={nodeName:"#documentType",name,publicId,systemId,parentNode:null};defaultTreeAdapter.appendChild(document5,node2)}},setDocumentMode(document5,mode){document5.mode=mode},getDocumentMode(document5){return document5.mode},detachNode(node2){if(node2.parentNode){let idx=node2.parentNode.childNodes.indexOf(node2);node2.parentNode.childNodes.splice(idx,1),node2.parentNode=null}},insertText(parentNode,text5){if(parentNode.childNodes.length>0){let prevNode=parentNode.childNodes[parentNode.childNodes.length-1];if(defaultTreeAdapter.isTextNode(prevNode)){prevNode.value+=text5;return}}defaultTreeAdapter.appendChild(parentNode,defaultTreeAdapter.createTextNode(text5))},insertTextBefore(parentNode,text5,referenceNode){let prevNode=parentNode.childNodes[parentNode.childNodes.indexOf(referenceNode)-1];prevNode&&defaultTreeAdapter.isTextNode(prevNode)?prevNode.value+=text5:defaultTreeAdapter.insertBefore(parentNode,defaultTreeAdapter.createTextNode(text5),referenceNode)},adoptAttributes(recipient,attrs){let recipientAttrsMap=new Set(recipient.attrs.map(attr=>attr.name));for(let j=0;j<attrs.length;j++)recipientAttrsMap.has(attrs[j].name)||recipient.attrs.push(attrs[j])},getFirstChild(node2){return node2.childNodes[0]},getChildNodes(node2){return node2.childNodes},getParentNode(node2){return node2.parentNode},getAttrList(element){return element.attrs},getTagName(element){return element.tagName},getNamespaceURI(element){return element.namespaceURI},getTextNodeContent(textNode){return textNode.value},getCommentNodeContent(commentNode){return commentNode.data},getDocumentTypeNodeName(doctypeNode){return doctypeNode.name},getDocumentTypeNodePublicId(doctypeNode){return doctypeNode.publicId},getDocumentTypeNodeSystemId(doctypeNode){return doctypeNode.systemId},isTextNode(node2){return node2.nodeName==="#text"},isCommentNode(node2){return node2.nodeName==="#comment"},isDocumentTypeNode(node2){return node2.nodeName==="#documentType"},isElementNode(node2){return Object.prototype.hasOwnProperty.call(node2,"tagName")},setNodeSourceCodeLocation(node2,location2){node2.sourceCodeLocation=location2},getNodeSourceCodeLocation(node2){return node2.sourceCodeLocation},updateNodeSourceCodeLocation(node2,endLocation){node2.sourceCodeLocation={...node2.sourceCodeLocation,...endLocation}}};init_browser_globals();var VALID_DOCTYPE_NAME="html",VALID_SYSTEM_ID="about:legacy-compat",QUIRKS_MODE_SYSTEM_ID="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",QUIRKS_MODE_PUBLIC_ID_PREFIXES=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],QUIRKS_MODE_NO_SYSTEM_ID_PUBLIC_ID_PREFIXES=[...QUIRKS_MODE_PUBLIC_ID_PREFIXES,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],QUIRKS_MODE_PUBLIC_IDS=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),LIMITED_QUIRKS_PUBLIC_ID_PREFIXES=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],LIMITED_QUIRKS_WITH_SYSTEM_ID_PUBLIC_ID_PREFIXES=[...LIMITED_QUIRKS_PUBLIC_ID_PREFIXES,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function hasPrefix(publicId,prefixes){return prefixes.some(prefix=>publicId.startsWith(prefix))}function isConforming(token){return token.name===VALID_DOCTYPE_NAME&&token.publicId===null&&(token.systemId===null||token.systemId===VALID_SYSTEM_ID)}function getDocumentMode(token){if(token.name!==VALID_DOCTYPE_NAME)return DOCUMENT_MODE.QUIRKS;let{systemId}=token;if(systemId&&systemId.toLowerCase()===QUIRKS_MODE_SYSTEM_ID)return DOCUMENT_MODE.QUIRKS;let{publicId}=token;if(publicId!==null){if(publicId=publicId.toLowerCase(),QUIRKS_MODE_PUBLIC_IDS.has(publicId))return DOCUMENT_MODE.QUIRKS;let prefixes=systemId===null?QUIRKS_MODE_NO_SYSTEM_ID_PUBLIC_ID_PREFIXES:QUIRKS_MODE_PUBLIC_ID_PREFIXES;if(hasPrefix(publicId,prefixes))return DOCUMENT_MODE.QUIRKS;if(prefixes=systemId===null?LIMITED_QUIRKS_PUBLIC_ID_PREFIXES:LIMITED_QUIRKS_WITH_SYSTEM_ID_PUBLIC_ID_PREFIXES,hasPrefix(publicId,prefixes))return DOCUMENT_MODE.LIMITED_QUIRKS}return DOCUMENT_MODE.NO_QUIRKS}init_browser_globals();var MIME_TYPES={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},DEFINITION_URL_ATTR="definitionurl",ADJUSTED_DEFINITION_URL_ATTR="definitionURL",SVG_ATTRS_ADJUSTMENT_MAP=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(attr=>[attr.toLowerCase(),attr])),XML_ATTRS_ADJUSTMENT_MAP=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:NS.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:NS.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:NS.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:NS.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:NS.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:NS.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:NS.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:NS.XML}],["xml:space",{prefix:"xml",name:"space",namespace:NS.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:NS.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:NS.XMLNS}]]),SVG_TAG_NAMES_ADJUSTMENT_MAP=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(tn2=>[tn2.toLowerCase(),tn2])),EXITS_FOREIGN_CONTENT=new Set([TAG_ID.B,TAG_ID.BIG,TAG_ID.BLOCKQUOTE,TAG_ID.BODY,TAG_ID.BR,TAG_ID.CENTER,TAG_ID.CODE,TAG_ID.DD,TAG_ID.DIV,TAG_ID.DL,TAG_ID.DT,TAG_ID.EM,TAG_ID.EMBED,TAG_ID.H1,TAG_ID.H2,TAG_ID.H3,TAG_ID.H4,TAG_ID.H5,TAG_ID.H6,TAG_ID.HEAD,TAG_ID.HR,TAG_ID.I,TAG_ID.IMG,TAG_ID.LI,TAG_ID.LISTING,TAG_ID.MENU,TAG_ID.META,TAG_ID.NOBR,TAG_ID.OL,TAG_ID.P,TAG_ID.PRE,TAG_ID.RUBY,TAG_ID.S,TAG_ID.SMALL,TAG_ID.SPAN,TAG_ID.STRONG,TAG_ID.STRIKE,TAG_ID.SUB,TAG_ID.SUP,TAG_ID.TABLE,TAG_ID.TT,TAG_ID.U,TAG_ID.UL,TAG_ID.VAR]);function causesExit(startTagToken){let tn2=startTagToken.tagID;return tn2===TAG_ID.FONT&&startTagToken.attrs.some(({name})=>name===ATTRS.COLOR||name===ATTRS.SIZE||name===ATTRS.FACE)||EXITS_FOREIGN_CONTENT.has(tn2)}function adjustTokenMathMLAttrs(token){for(let i2=0;i2<token.attrs.length;i2++)if(token.attrs[i2].name===DEFINITION_URL_ATTR){token.attrs[i2].name=ADJUSTED_DEFINITION_URL_ATTR;break}}function adjustTokenSVGAttrs(token){for(let i2=0;i2<token.attrs.length;i2++){let adjustedAttrName=SVG_ATTRS_ADJUSTMENT_MAP.get(token.attrs[i2].name);adjustedAttrName!=null&&(token.attrs[i2].name=adjustedAttrName)}}function adjustTokenXMLAttrs(token){for(let i2=0;i2<token.attrs.length;i2++){let adjustedAttrEntry=XML_ATTRS_ADJUSTMENT_MAP.get(token.attrs[i2].name);adjustedAttrEntry&&(token.attrs[i2].prefix=adjustedAttrEntry.prefix,token.attrs[i2].name=adjustedAttrEntry.name,token.attrs[i2].namespace=adjustedAttrEntry.namespace)}}function adjustTokenSVGTagName(token){let adjustedTagName=SVG_TAG_NAMES_ADJUSTMENT_MAP.get(token.tagName);adjustedTagName!=null&&(token.tagName=adjustedTagName,token.tagID=getTagID(token.tagName))}function isMathMLTextIntegrationPoint(tn2,ns){return ns===NS.MATHML&&(tn2===TAG_ID.MI||tn2===TAG_ID.MO||tn2===TAG_ID.MN||tn2===TAG_ID.MS||tn2===TAG_ID.MTEXT)}function isHtmlIntegrationPoint(tn2,ns,attrs){if(ns===NS.MATHML&&tn2===TAG_ID.ANNOTATION_XML){for(let i2=0;i2<attrs.length;i2++)if(attrs[i2].name===ATTRS.ENCODING){let value2=attrs[i2].value.toLowerCase();return value2===MIME_TYPES.TEXT_HTML||value2===MIME_TYPES.APPLICATION_XML}}return ns===NS.SVG&&(tn2===TAG_ID.FOREIGN_OBJECT||tn2===TAG_ID.DESC||tn2===TAG_ID.TITLE)}function isIntegrationPoint(tn2,ns,attrs,foreignNS){return(!foreignNS||foreignNS===NS.HTML)&&isHtmlIntegrationPoint(tn2,ns,attrs)||(!foreignNS||foreignNS===NS.MATHML)&&isMathMLTextIntegrationPoint(tn2,ns)}var HIDDEN_INPUT_TYPE="hidden",AA_OUTER_LOOP_ITER=8,AA_INNER_LOOP_ITER=3,InsertionMode;(function(InsertionMode2){InsertionMode2[InsertionMode2.INITIAL=0]="INITIAL",InsertionMode2[InsertionMode2.BEFORE_HTML=1]="BEFORE_HTML",InsertionMode2[InsertionMode2.BEFORE_HEAD=2]="BEFORE_HEAD",InsertionMode2[InsertionMode2.IN_HEAD=3]="IN_HEAD",InsertionMode2[InsertionMode2.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",InsertionMode2[InsertionMode2.AFTER_HEAD=5]="AFTER_HEAD",InsertionMode2[InsertionMode2.IN_BODY=6]="IN_BODY",InsertionMode2[InsertionMode2.TEXT=7]="TEXT",InsertionMode2[InsertionMode2.IN_TABLE=8]="IN_TABLE",InsertionMode2[InsertionMode2.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",InsertionMode2[InsertionMode2.IN_CAPTION=10]="IN_CAPTION",InsertionMode2[InsertionMode2.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",InsertionMode2[InsertionMode2.IN_TABLE_BODY=12]="IN_TABLE_BODY",InsertionMode2[InsertionMode2.IN_ROW=13]="IN_ROW",InsertionMode2[InsertionMode2.IN_CELL=14]="IN_CELL",InsertionMode2[InsertionMode2.IN_SELECT=15]="IN_SELECT",InsertionMode2[InsertionMode2.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",InsertionMode2[InsertionMode2.IN_TEMPLATE=17]="IN_TEMPLATE",InsertionMode2[InsertionMode2.AFTER_BODY=18]="AFTER_BODY",InsertionMode2[InsertionMode2.IN_FRAMESET=19]="IN_FRAMESET",InsertionMode2[InsertionMode2.AFTER_FRAMESET=20]="AFTER_FRAMESET",InsertionMode2[InsertionMode2.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",InsertionMode2[InsertionMode2.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(InsertionMode||(InsertionMode={}));var BASE_LOC={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},TABLE_STRUCTURE_TAGS=new Set([TAG_ID.TABLE,TAG_ID.TBODY,TAG_ID.TFOOT,TAG_ID.THEAD,TAG_ID.TR]),defaultParserOptions={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:defaultTreeAdapter,onParseError:null},Parser2=class{constructor(options2,document5,fragmentContext=null,scriptHandler=null){this.fragmentContext=fragmentContext,this.scriptHandler=scriptHandler,this.currentToken=null,this.stopped=!1,this.insertionMode=InsertionMode.INITIAL,this.originalInsertionMode=InsertionMode.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={...defaultParserOptions,...options2},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=document5??this.treeAdapter.createDocument(),this.tokenizer=new Tokenizer(this.options,this),this.activeFormattingElements=new FormattingElementList(this.treeAdapter),this.fragmentContextID=fragmentContext?getTagID(this.treeAdapter.getTagName(fragmentContext)):TAG_ID.UNKNOWN,this._setContextModes(fragmentContext??this.document,this.fragmentContextID),this.openElements=new OpenElementStack(this.document,this.treeAdapter,this)}static parse(html2,options2){let parser=new this(options2);return parser.tokenizer.write(html2,!0),parser.document}static getFragmentParser(fragmentContext,options2){let opts={...defaultParserOptions,...options2};fragmentContext??(fragmentContext=opts.treeAdapter.createElement(TAG_NAMES.TEMPLATE,NS.HTML,[]));let documentMock=opts.treeAdapter.createElement("documentmock",NS.HTML,[]),parser=new this(opts,documentMock,fragmentContext);return parser.fragmentContextID===TAG_ID.TEMPLATE&&parser.tmplInsertionModeStack.unshift(InsertionMode.IN_TEMPLATE),parser._initTokenizerForFragmentParsing(),parser._insertFakeRootElement(),parser._resetInsertionMode(),parser._findFormInFragmentContext(),parser}getFragment(){let rootElement=this.treeAdapter.getFirstChild(this.document),fragment=this.treeAdapter.createDocumentFragment();return this._adoptNodes(rootElement,fragment),fragment}_err(token,code4,beforeToken){var _a2;if(!this.onParseError)return;let loc=(_a2=token.location)!==null&&_a2!==void 0?_a2:BASE_LOC,err={code:code4,startLine:loc.startLine,startCol:loc.startCol,startOffset:loc.startOffset,endLine:beforeToken?loc.startLine:loc.endLine,endCol:beforeToken?loc.startCol:loc.endCol,endOffset:beforeToken?loc.startOffset:loc.endOffset};this.onParseError(err)}onItemPush(node2,tid,isTop){var _a2,_b;(_b=(_a2=this.treeAdapter).onItemPush)===null||_b===void 0||_b.call(_a2,node2),isTop&&this.openElements.stackTop>0&&this._setContextModes(node2,tid)}onItemPop(node2,isTop){var _a2,_b;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(node2,this.currentToken),(_b=(_a2=this.treeAdapter).onItemPop)===null||_b===void 0||_b.call(_a2,node2,this.openElements.current),isTop){let current,currentTagId;this.openElements.stackTop===0&&this.fragmentContext?(current=this.fragmentContext,currentTagId=this.fragmentContextID):{current,currentTagId}=this.openElements,this._setContextModes(current,currentTagId)}}_setContextModes(current,tid){let isHTML=current===this.document||current&&this.treeAdapter.getNamespaceURI(current)===NS.HTML;this.currentNotInHTML=!isHTML,this.tokenizer.inForeignNode=!isHTML&¤t!==void 0&&tid!==void 0&&!this._isIntegrationPoint(tid,current)}_switchToTextParsing(currentToken,nextTokenizerState){this._insertElement(currentToken,NS.HTML),this.tokenizer.state=nextTokenizerState,this.originalInsertionMode=this.insertionMode,this.insertionMode=InsertionMode.TEXT}switchToPlaintextParsing(){this.insertionMode=InsertionMode.TEXT,this.originalInsertionMode=InsertionMode.IN_BODY,this.tokenizer.state=TokenizerMode.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let node2=this.fragmentContext;for(;node2;){if(this.treeAdapter.getTagName(node2)===TAG_NAMES.FORM){this.formElement=node2;break}node2=this.treeAdapter.getParentNode(node2)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==NS.HTML))switch(this.fragmentContextID){case TAG_ID.TITLE:case TAG_ID.TEXTAREA:{this.tokenizer.state=TokenizerMode.RCDATA;break}case TAG_ID.STYLE:case TAG_ID.XMP:case TAG_ID.IFRAME:case TAG_ID.NOEMBED:case TAG_ID.NOFRAMES:case TAG_ID.NOSCRIPT:{this.tokenizer.state=TokenizerMode.RAWTEXT;break}case TAG_ID.SCRIPT:{this.tokenizer.state=TokenizerMode.SCRIPT_DATA;break}case TAG_ID.PLAINTEXT:{this.tokenizer.state=TokenizerMode.PLAINTEXT;break}default:}}_setDocumentType(token){let name=token.name||"",publicId=token.publicId||"",systemId=token.systemId||"";if(this.treeAdapter.setDocumentType(this.document,name,publicId,systemId),token.location){let docTypeNode=this.treeAdapter.getChildNodes(this.document).find(node2=>this.treeAdapter.isDocumentTypeNode(node2));docTypeNode&&this.treeAdapter.setNodeSourceCodeLocation(docTypeNode,token.location)}}_attachElementToTree(element,location2){if(this.options.sourceCodeLocationInfo){let loc=location2&&{...location2,startTag:location2};this.treeAdapter.setNodeSourceCodeLocation(element,loc)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(element);else{let parent=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(parent??this.document,element)}}_appendElement(token,namespaceURI){let element=this.treeAdapter.createElement(token.tagName,namespaceURI,token.attrs);this._attachElementToTree(element,token.location)}_insertElement(token,namespaceURI){let element=this.treeAdapter.createElement(token.tagName,namespaceURI,token.attrs);this._attachElementToTree(element,token.location),this.openElements.push(element,token.tagID)}_insertFakeElement(tagName,tagID){let element=this.treeAdapter.createElement(tagName,NS.HTML,[]);this._attachElementToTree(element,null),this.openElements.push(element,tagID)}_insertTemplate(token){let tmpl=this.treeAdapter.createElement(token.tagName,NS.HTML,token.attrs),content3=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(tmpl,content3),this._attachElementToTree(tmpl,token.location),this.openElements.push(tmpl,token.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(content3,null)}_insertFakeRootElement(){let element=this.treeAdapter.createElement(TAG_NAMES.HTML,NS.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(element,null),this.treeAdapter.appendChild(this.openElements.current,element),this.openElements.push(element,TAG_ID.HTML)}_appendCommentNode(token,parent){let commentNode=this.treeAdapter.createCommentNode(token.data);this.treeAdapter.appendChild(parent,commentNode),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(commentNode,token.location)}_insertCharacters(token){let parent,beforeElement;if(this._shouldFosterParentOnInsertion()?({parent,beforeElement}=this._findFosterParentingLocation(),beforeElement?this.treeAdapter.insertTextBefore(parent,token.chars,beforeElement):this.treeAdapter.insertText(parent,token.chars)):(parent=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(parent,token.chars)),!token.location)return;let siblings=this.treeAdapter.getChildNodes(parent),textNodeIdx=beforeElement?siblings.lastIndexOf(beforeElement):siblings.length,textNode=siblings[textNodeIdx-1];if(this.treeAdapter.getNodeSourceCodeLocation(textNode)){let{endLine,endCol,endOffset}=token.location;this.treeAdapter.updateNodeSourceCodeLocation(textNode,{endLine,endCol,endOffset})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(textNode,token.location)}_adoptNodes(donor,recipient){for(let child=this.treeAdapter.getFirstChild(donor);child;child=this.treeAdapter.getFirstChild(donor))this.treeAdapter.detachNode(child),this.treeAdapter.appendChild(recipient,child)}_setEndLocation(element,closingToken){if(this.treeAdapter.getNodeSourceCodeLocation(element)&&closingToken.location){let ctLoc=closingToken.location,tn2=this.treeAdapter.getTagName(element),endLoc=closingToken.type===TokenType.END_TAG&&tn2===closingToken.tagName?{endTag:{...ctLoc},endLine:ctLoc.endLine,endCol:ctLoc.endCol,endOffset:ctLoc.endOffset}:{endLine:ctLoc.startLine,endCol:ctLoc.startCol,endOffset:ctLoc.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(element,endLoc)}}shouldProcessStartTagTokenInForeignContent(token){if(!this.currentNotInHTML)return!1;let current,currentTagId;return this.openElements.stackTop===0&&this.fragmentContext?(current=this.fragmentContext,currentTagId=this.fragmentContextID):{current,currentTagId}=this.openElements,token.tagID===TAG_ID.SVG&&this.treeAdapter.getTagName(current)===TAG_NAMES.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(current)===NS.MATHML?!1:this.tokenizer.inForeignNode||(token.tagID===TAG_ID.MGLYPH||token.tagID===TAG_ID.MALIGNMARK)&¤tTagId!==void 0&&!this._isIntegrationPoint(currentTagId,current,NS.HTML)}_processToken(token){switch(token.type){case TokenType.CHARACTER:{this.onCharacter(token);break}case TokenType.NULL_CHARACTER:{this.onNullCharacter(token);break}case TokenType.COMMENT:{this.onComment(token);break}case TokenType.DOCTYPE:{this.onDoctype(token);break}case TokenType.START_TAG:{this._processStartTag(token);break}case TokenType.END_TAG:{this.onEndTag(token);break}case TokenType.EOF:{this.onEof(token);break}case TokenType.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(token);break}}}_isIntegrationPoint(tid,element,foreignNS){let ns=this.treeAdapter.getNamespaceURI(element),attrs=this.treeAdapter.getAttrList(element);return isIntegrationPoint(tid,ns,attrs,foreignNS)}_reconstructActiveFormattingElements(){let listLength=this.activeFormattingElements.entries.length;if(listLength){let endIndex=this.activeFormattingElements.entries.findIndex(entry=>entry.type===EntryType.Marker||this.openElements.contains(entry.element)),unopenIdx=endIndex===-1?listLength-1:endIndex-1;for(let i2=unopenIdx;i2>=0;i2--){let entry=this.activeFormattingElements.entries[i2];this._insertElement(entry.token,this.treeAdapter.getNamespaceURI(entry.element)),entry.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=InsertionMode.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(TAG_ID.P),this.openElements.popUntilTagNamePopped(TAG_ID.P)}_resetInsertionMode(){for(let i2=this.openElements.stackTop;i2>=0;i2--)switch(i2===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[i2]){case TAG_ID.TR:{this.insertionMode=InsertionMode.IN_ROW;return}case TAG_ID.TBODY:case TAG_ID.THEAD:case TAG_ID.TFOOT:{this.insertionMode=InsertionMode.IN_TABLE_BODY;return}case TAG_ID.CAPTION:{this.insertionMode=InsertionMode.IN_CAPTION;return}case TAG_ID.COLGROUP:{this.insertionMode=InsertionMode.IN_COLUMN_GROUP;return}case TAG_ID.TABLE:{this.insertionMode=InsertionMode.IN_TABLE;return}case TAG_ID.BODY:{this.insertionMode=InsertionMode.IN_BODY;return}case TAG_ID.FRAMESET:{this.insertionMode=InsertionMode.IN_FRAMESET;return}case TAG_ID.SELECT:{this._resetInsertionModeForSelect(i2);return}case TAG_ID.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case TAG_ID.HTML:{this.insertionMode=this.headElement?InsertionMode.AFTER_HEAD:InsertionMode.BEFORE_HEAD;return}case TAG_ID.TD:case TAG_ID.TH:{if(i2>0){this.insertionMode=InsertionMode.IN_CELL;return}break}case TAG_ID.HEAD:{if(i2>0){this.insertionMode=InsertionMode.IN_HEAD;return}break}}this.insertionMode=InsertionMode.IN_BODY}_resetInsertionModeForSelect(selectIdx){if(selectIdx>0)for(let i2=selectIdx-1;i2>0;i2--){let tn2=this.openElements.tagIDs[i2];if(tn2===TAG_ID.TEMPLATE)break;if(tn2===TAG_ID.TABLE){this.insertionMode=InsertionMode.IN_SELECT_IN_TABLE;return}}this.insertionMode=InsertionMode.IN_SELECT}_isElementCausesFosterParenting(tn2){return TABLE_STRUCTURE_TAGS.has(tn2)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let i2=this.openElements.stackTop;i2>=0;i2--){let openElement=this.openElements.items[i2];switch(this.openElements.tagIDs[i2]){case TAG_ID.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(openElement)===NS.HTML)return{parent:this.treeAdapter.getTemplateContent(openElement),beforeElement:null};break}case TAG_ID.TABLE:{let parent=this.treeAdapter.getParentNode(openElement);return parent?{parent,beforeElement:openElement}:{parent:this.openElements.items[i2-1],beforeElement:null}}default:}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(element){let location2=this._findFosterParentingLocation();location2.beforeElement?this.treeAdapter.insertBefore(location2.parent,element,location2.beforeElement):this.treeAdapter.appendChild(location2.parent,element)}_isSpecialElement(element,id){let ns=this.treeAdapter.getNamespaceURI(element);return SPECIAL_ELEMENTS[ns].has(id)}onCharacter(token){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){characterInForeignContent(this,token);return}switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{tokenBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{tokenBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{tokenInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{tokenInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{tokenAfterHead(this,token);break}case InsertionMode.IN_BODY:case InsertionMode.IN_CAPTION:case InsertionMode.IN_CELL:case InsertionMode.IN_TEMPLATE:{characterInBody(this,token);break}case InsertionMode.TEXT:case InsertionMode.IN_SELECT:case InsertionMode.IN_SELECT_IN_TABLE:{this._insertCharacters(token);break}case InsertionMode.IN_TABLE:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:{characterInTable(this,token);break}case InsertionMode.IN_TABLE_TEXT:{characterInTableText(this,token);break}case InsertionMode.IN_COLUMN_GROUP:{tokenInColumnGroup(this,token);break}case InsertionMode.AFTER_BODY:{tokenAfterBody(this,token);break}case InsertionMode.AFTER_AFTER_BODY:{tokenAfterAfterBody(this,token);break}default:}}onNullCharacter(token){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){nullCharacterInForeignContent(this,token);return}switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{tokenBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{tokenBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{tokenInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{tokenInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{tokenAfterHead(this,token);break}case InsertionMode.TEXT:{this._insertCharacters(token);break}case InsertionMode.IN_TABLE:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:{characterInTable(this,token);break}case InsertionMode.IN_COLUMN_GROUP:{tokenInColumnGroup(this,token);break}case InsertionMode.AFTER_BODY:{tokenAfterBody(this,token);break}case InsertionMode.AFTER_AFTER_BODY:{tokenAfterAfterBody(this,token);break}default:}}onComment(token){if(this.skipNextNewLine=!1,this.currentNotInHTML){appendComment(this,token);return}switch(this.insertionMode){case InsertionMode.INITIAL:case InsertionMode.BEFORE_HTML:case InsertionMode.BEFORE_HEAD:case InsertionMode.IN_HEAD:case InsertionMode.IN_HEAD_NO_SCRIPT:case InsertionMode.AFTER_HEAD:case InsertionMode.IN_BODY:case InsertionMode.IN_TABLE:case InsertionMode.IN_CAPTION:case InsertionMode.IN_COLUMN_GROUP:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:case InsertionMode.IN_CELL:case InsertionMode.IN_SELECT:case InsertionMode.IN_SELECT_IN_TABLE:case InsertionMode.IN_TEMPLATE:case InsertionMode.IN_FRAMESET:case InsertionMode.AFTER_FRAMESET:{appendComment(this,token);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}case InsertionMode.AFTER_BODY:{appendCommentToRootHtmlElement(this,token);break}case InsertionMode.AFTER_AFTER_BODY:case InsertionMode.AFTER_AFTER_FRAMESET:{appendCommentToDocument(this,token);break}default:}}onDoctype(token){switch(this.skipNextNewLine=!1,this.insertionMode){case InsertionMode.INITIAL:{doctypeInInitialMode(this,token);break}case InsertionMode.BEFORE_HEAD:case InsertionMode.IN_HEAD:case InsertionMode.IN_HEAD_NO_SCRIPT:case InsertionMode.AFTER_HEAD:{this._err(token,ERR.misplacedDoctype);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}default:}}onStartTag(token){this.skipNextNewLine=!1,this.currentToken=token,this._processStartTag(token),token.selfClosing&&!token.ackSelfClosing&&this._err(token,ERR.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(token){this.shouldProcessStartTagTokenInForeignContent(token)?startTagInForeignContent(this,token):this._startTagOutsideForeignContent(token)}_startTagOutsideForeignContent(token){switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{startTagBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{startTagBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{startTagInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{startTagInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{startTagAfterHead(this,token);break}case InsertionMode.IN_BODY:{startTagInBody(this,token);break}case InsertionMode.IN_TABLE:{startTagInTable(this,token);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}case InsertionMode.IN_CAPTION:{startTagInCaption(this,token);break}case InsertionMode.IN_COLUMN_GROUP:{startTagInColumnGroup(this,token);break}case InsertionMode.IN_TABLE_BODY:{startTagInTableBody(this,token);break}case InsertionMode.IN_ROW:{startTagInRow(this,token);break}case InsertionMode.IN_CELL:{startTagInCell(this,token);break}case InsertionMode.IN_SELECT:{startTagInSelect(this,token);break}case InsertionMode.IN_SELECT_IN_TABLE:{startTagInSelectInTable(this,token);break}case InsertionMode.IN_TEMPLATE:{startTagInTemplate(this,token);break}case InsertionMode.AFTER_BODY:{startTagAfterBody(this,token);break}case InsertionMode.IN_FRAMESET:{startTagInFrameset(this,token);break}case InsertionMode.AFTER_FRAMESET:{startTagAfterFrameset(this,token);break}case InsertionMode.AFTER_AFTER_BODY:{startTagAfterAfterBody(this,token);break}case InsertionMode.AFTER_AFTER_FRAMESET:{startTagAfterAfterFrameset(this,token);break}default:}}onEndTag(token){this.skipNextNewLine=!1,this.currentToken=token,this.currentNotInHTML?endTagInForeignContent(this,token):this._endTagOutsideForeignContent(token)}_endTagOutsideForeignContent(token){switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{endTagBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{endTagBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{endTagInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{endTagInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{endTagAfterHead(this,token);break}case InsertionMode.IN_BODY:{endTagInBody(this,token);break}case InsertionMode.TEXT:{endTagInText(this,token);break}case InsertionMode.IN_TABLE:{endTagInTable(this,token);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}case InsertionMode.IN_CAPTION:{endTagInCaption(this,token);break}case InsertionMode.IN_COLUMN_GROUP:{endTagInColumnGroup(this,token);break}case InsertionMode.IN_TABLE_BODY:{endTagInTableBody(this,token);break}case InsertionMode.IN_ROW:{endTagInRow(this,token);break}case InsertionMode.IN_CELL:{endTagInCell(this,token);break}case InsertionMode.IN_SELECT:{endTagInSelect(this,token);break}case InsertionMode.IN_SELECT_IN_TABLE:{endTagInSelectInTable(this,token);break}case InsertionMode.IN_TEMPLATE:{endTagInTemplate(this,token);break}case InsertionMode.AFTER_BODY:{endTagAfterBody(this,token);break}case InsertionMode.IN_FRAMESET:{endTagInFrameset(this,token);break}case InsertionMode.AFTER_FRAMESET:{endTagAfterFrameset(this,token);break}case InsertionMode.AFTER_AFTER_BODY:{tokenAfterAfterBody(this,token);break}default:}}onEof(token){switch(this.insertionMode){case InsertionMode.INITIAL:{tokenInInitialMode(this,token);break}case InsertionMode.BEFORE_HTML:{tokenBeforeHtml(this,token);break}case InsertionMode.BEFORE_HEAD:{tokenBeforeHead(this,token);break}case InsertionMode.IN_HEAD:{tokenInHead(this,token);break}case InsertionMode.IN_HEAD_NO_SCRIPT:{tokenInHeadNoScript(this,token);break}case InsertionMode.AFTER_HEAD:{tokenAfterHead(this,token);break}case InsertionMode.IN_BODY:case InsertionMode.IN_TABLE:case InsertionMode.IN_CAPTION:case InsertionMode.IN_COLUMN_GROUP:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:case InsertionMode.IN_CELL:case InsertionMode.IN_SELECT:case InsertionMode.IN_SELECT_IN_TABLE:{eofInBody(this,token);break}case InsertionMode.TEXT:{eofInText(this,token);break}case InsertionMode.IN_TABLE_TEXT:{tokenInTableText(this,token);break}case InsertionMode.IN_TEMPLATE:{eofInTemplate(this,token);break}case InsertionMode.AFTER_BODY:case InsertionMode.IN_FRAMESET:case InsertionMode.AFTER_FRAMESET:case InsertionMode.AFTER_AFTER_BODY:case InsertionMode.AFTER_AFTER_FRAMESET:{stopParsing(this,token);break}default:}}onWhitespaceCharacter(token){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,token.chars.charCodeAt(0)===CODE_POINTS.LINE_FEED)){if(token.chars.length===1)return;token.chars=token.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(token);return}switch(this.insertionMode){case InsertionMode.IN_HEAD:case InsertionMode.IN_HEAD_NO_SCRIPT:case InsertionMode.AFTER_HEAD:case InsertionMode.TEXT:case InsertionMode.IN_COLUMN_GROUP:case InsertionMode.IN_SELECT:case InsertionMode.IN_SELECT_IN_TABLE:case InsertionMode.IN_FRAMESET:case InsertionMode.AFTER_FRAMESET:{this._insertCharacters(token);break}case InsertionMode.IN_BODY:case InsertionMode.IN_CAPTION:case InsertionMode.IN_CELL:case InsertionMode.IN_TEMPLATE:case InsertionMode.AFTER_BODY:case InsertionMode.AFTER_AFTER_BODY:case InsertionMode.AFTER_AFTER_FRAMESET:{whitespaceCharacterInBody(this,token);break}case InsertionMode.IN_TABLE:case InsertionMode.IN_TABLE_BODY:case InsertionMode.IN_ROW:{characterInTable(this,token);break}case InsertionMode.IN_TABLE_TEXT:{whitespaceCharacterInTableText(this,token);break}default:}}};function aaObtainFormattingElementEntry(p2,token){let formattingElementEntry=p2.activeFormattingElements.getElementEntryInScopeWithTagName(token.tagName);return formattingElementEntry?p2.openElements.contains(formattingElementEntry.element)?p2.openElements.hasInScope(token.tagID)||(formattingElementEntry=null):(p2.activeFormattingElements.removeEntry(formattingElementEntry),formattingElementEntry=null):genericEndTagInBody(p2,token),formattingElementEntry}function aaObtainFurthestBlock(p2,formattingElementEntry){let furthestBlock=null,idx=p2.openElements.stackTop;for(;idx>=0;idx--){let element=p2.openElements.items[idx];if(element===formattingElementEntry.element)break;p2._isSpecialElement(element,p2.openElements.tagIDs[idx])&&(furthestBlock=element)}return furthestBlock||(p2.openElements.shortenToLength(Math.max(idx,0)),p2.activeFormattingElements.removeEntry(formattingElementEntry)),furthestBlock}function aaInnerLoop(p2,furthestBlock,formattingElement){let lastElement=furthestBlock,nextElement=p2.openElements.getCommonAncestor(furthestBlock);for(let i2=0,element=nextElement;element!==formattingElement;i2++,element=nextElement){nextElement=p2.openElements.getCommonAncestor(element);let elementEntry=p2.activeFormattingElements.getElementEntry(element),counterOverflow=elementEntry&&i2>=AA_INNER_LOOP_ITER;!elementEntry||counterOverflow?(counterOverflow&&p2.activeFormattingElements.removeEntry(elementEntry),p2.openElements.remove(element)):(element=aaRecreateElementFromEntry(p2,elementEntry),lastElement===furthestBlock&&(p2.activeFormattingElements.bookmark=elementEntry),p2.treeAdapter.detachNode(lastElement),p2.treeAdapter.appendChild(element,lastElement),lastElement=element)}return lastElement}function aaRecreateElementFromEntry(p2,elementEntry){let ns=p2.treeAdapter.getNamespaceURI(elementEntry.element),newElement=p2.treeAdapter.createElement(elementEntry.token.tagName,ns,elementEntry.token.attrs);return p2.openElements.replace(elementEntry.element,newElement),elementEntry.element=newElement,newElement}function aaInsertLastNodeInCommonAncestor(p2,commonAncestor,lastElement){let tn2=p2.treeAdapter.getTagName(commonAncestor),tid=getTagID(tn2);if(p2._isElementCausesFosterParenting(tid))p2._fosterParentElement(lastElement);else{let ns=p2.treeAdapter.getNamespaceURI(commonAncestor);tid===TAG_ID.TEMPLATE&&ns===NS.HTML&&(commonAncestor=p2.treeAdapter.getTemplateContent(commonAncestor)),p2.treeAdapter.appendChild(commonAncestor,lastElement)}}function aaReplaceFormattingElement(p2,furthestBlock,formattingElementEntry){let ns=p2.treeAdapter.getNamespaceURI(formattingElementEntry.element),{token}=formattingElementEntry,newElement=p2.treeAdapter.createElement(token.tagName,ns,token.attrs);p2._adoptNodes(furthestBlock,newElement),p2.treeAdapter.appendChild(furthestBlock,newElement),p2.activeFormattingElements.insertElementAfterBookmark(newElement,token),p2.activeFormattingElements.removeEntry(formattingElementEntry),p2.openElements.remove(formattingElementEntry.element),p2.openElements.insertAfter(furthestBlock,newElement,token.tagID)}function callAdoptionAgency(p2,token){for(let i2=0;i2<AA_OUTER_LOOP_ITER;i2++){let formattingElementEntry=aaObtainFormattingElementEntry(p2,token);if(!formattingElementEntry)break;let furthestBlock=aaObtainFurthestBlock(p2,formattingElementEntry);if(!furthestBlock)break;p2.activeFormattingElements.bookmark=formattingElementEntry;let lastElement=aaInnerLoop(p2,furthestBlock,formattingElementEntry.element),commonAncestor=p2.openElements.getCommonAncestor(formattingElementEntry.element);p2.treeAdapter.detachNode(lastElement),commonAncestor&&aaInsertLastNodeInCommonAncestor(p2,commonAncestor,lastElement),aaReplaceFormattingElement(p2,furthestBlock,formattingElementEntry)}}function appendComment(p2,token){p2._appendCommentNode(token,p2.openElements.currentTmplContentOrNode)}function appendCommentToRootHtmlElement(p2,token){p2._appendCommentNode(token,p2.openElements.items[0])}function appendCommentToDocument(p2,token){p2._appendCommentNode(token,p2.document)}function stopParsing(p2,token){if(p2.stopped=!0,token.location){let target=p2.fragmentContext?0:2;for(let i2=p2.openElements.stackTop;i2>=target;i2--)p2._setEndLocation(p2.openElements.items[i2],token);if(!p2.fragmentContext&&p2.openElements.stackTop>=0){let htmlElement=p2.openElements.items[0],htmlLocation=p2.treeAdapter.getNodeSourceCodeLocation(htmlElement);if(htmlLocation&&!htmlLocation.endTag&&(p2._setEndLocation(htmlElement,token),p2.openElements.stackTop>=1)){let bodyElement=p2.openElements.items[1],bodyLocation=p2.treeAdapter.getNodeSourceCodeLocation(bodyElement);bodyLocation&&!bodyLocation.endTag&&p2._setEndLocation(bodyElement,token)}}}}function doctypeInInitialMode(p2,token){p2._setDocumentType(token);let mode=token.forceQuirks?DOCUMENT_MODE.QUIRKS:getDocumentMode(token);isConforming(token)||p2._err(token,ERR.nonConformingDoctype),p2.treeAdapter.setDocumentMode(p2.document,mode),p2.insertionMode=InsertionMode.BEFORE_HTML}function tokenInInitialMode(p2,token){p2._err(token,ERR.missingDoctype,!0),p2.treeAdapter.setDocumentMode(p2.document,DOCUMENT_MODE.QUIRKS),p2.insertionMode=InsertionMode.BEFORE_HTML,p2._processToken(token)}function startTagBeforeHtml(p2,token){token.tagID===TAG_ID.HTML?(p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.BEFORE_HEAD):tokenBeforeHtml(p2,token)}function endTagBeforeHtml(p2,token){let tn2=token.tagID;(tn2===TAG_ID.HTML||tn2===TAG_ID.HEAD||tn2===TAG_ID.BODY||tn2===TAG_ID.BR)&&tokenBeforeHtml(p2,token)}function tokenBeforeHtml(p2,token){p2._insertFakeRootElement(),p2.insertionMode=InsertionMode.BEFORE_HEAD,p2._processToken(token)}function startTagBeforeHead(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.HEAD:{p2._insertElement(token,NS.HTML),p2.headElement=p2.openElements.current,p2.insertionMode=InsertionMode.IN_HEAD;break}default:tokenBeforeHead(p2,token)}}function endTagBeforeHead(p2,token){let tn2=token.tagID;tn2===TAG_ID.HEAD||tn2===TAG_ID.BODY||tn2===TAG_ID.HTML||tn2===TAG_ID.BR?tokenBeforeHead(p2,token):p2._err(token,ERR.endTagWithoutMatchingOpenElement)}function tokenBeforeHead(p2,token){p2._insertFakeElement(TAG_NAMES.HEAD,TAG_ID.HEAD),p2.headElement=p2.openElements.current,p2.insertionMode=InsertionMode.IN_HEAD,p2._processToken(token)}function startTagInHead(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.BASE:case TAG_ID.BASEFONT:case TAG_ID.BGSOUND:case TAG_ID.LINK:case TAG_ID.META:{p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0;break}case TAG_ID.TITLE:{p2._switchToTextParsing(token,TokenizerMode.RCDATA);break}case TAG_ID.NOSCRIPT:{p2.options.scriptingEnabled?p2._switchToTextParsing(token,TokenizerMode.RAWTEXT):(p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_HEAD_NO_SCRIPT);break}case TAG_ID.NOFRAMES:case TAG_ID.STYLE:{p2._switchToTextParsing(token,TokenizerMode.RAWTEXT);break}case TAG_ID.SCRIPT:{p2._switchToTextParsing(token,TokenizerMode.SCRIPT_DATA);break}case TAG_ID.TEMPLATE:{p2._insertTemplate(token),p2.activeFormattingElements.insertMarker(),p2.framesetOk=!1,p2.insertionMode=InsertionMode.IN_TEMPLATE,p2.tmplInsertionModeStack.unshift(InsertionMode.IN_TEMPLATE);break}case TAG_ID.HEAD:{p2._err(token,ERR.misplacedStartTagForHeadElement);break}default:tokenInHead(p2,token)}}function endTagInHead(p2,token){switch(token.tagID){case TAG_ID.HEAD:{p2.openElements.pop(),p2.insertionMode=InsertionMode.AFTER_HEAD;break}case TAG_ID.BODY:case TAG_ID.BR:case TAG_ID.HTML:{tokenInHead(p2,token);break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}default:p2._err(token,ERR.endTagWithoutMatchingOpenElement)}}function templateEndTagInHead(p2,token){p2.openElements.tmplCount>0?(p2.openElements.generateImpliedEndTagsThoroughly(),p2.openElements.currentTagId!==TAG_ID.TEMPLATE&&p2._err(token,ERR.closingOfElementWithOpenChildElements),p2.openElements.popUntilTagNamePopped(TAG_ID.TEMPLATE),p2.activeFormattingElements.clearToLastMarker(),p2.tmplInsertionModeStack.shift(),p2._resetInsertionMode()):p2._err(token,ERR.endTagWithoutMatchingOpenElement)}function tokenInHead(p2,token){p2.openElements.pop(),p2.insertionMode=InsertionMode.AFTER_HEAD,p2._processToken(token)}function startTagInHeadNoScript(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.BASEFONT:case TAG_ID.BGSOUND:case TAG_ID.HEAD:case TAG_ID.LINK:case TAG_ID.META:case TAG_ID.NOFRAMES:case TAG_ID.STYLE:{startTagInHead(p2,token);break}case TAG_ID.NOSCRIPT:{p2._err(token,ERR.nestedNoscriptInHead);break}default:tokenInHeadNoScript(p2,token)}}function endTagInHeadNoScript(p2,token){switch(token.tagID){case TAG_ID.NOSCRIPT:{p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_HEAD;break}case TAG_ID.BR:{tokenInHeadNoScript(p2,token);break}default:p2._err(token,ERR.endTagWithoutMatchingOpenElement)}}function tokenInHeadNoScript(p2,token){let errCode=token.type===TokenType.EOF?ERR.openElementsLeftAfterEof:ERR.disallowedContentInNoscriptInHead;p2._err(token,errCode),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_HEAD,p2._processToken(token)}function startTagAfterHead(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.BODY:{p2._insertElement(token,NS.HTML),p2.framesetOk=!1,p2.insertionMode=InsertionMode.IN_BODY;break}case TAG_ID.FRAMESET:{p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_FRAMESET;break}case TAG_ID.BASE:case TAG_ID.BASEFONT:case TAG_ID.BGSOUND:case TAG_ID.LINK:case TAG_ID.META:case TAG_ID.NOFRAMES:case TAG_ID.SCRIPT:case TAG_ID.STYLE:case TAG_ID.TEMPLATE:case TAG_ID.TITLE:{p2._err(token,ERR.abandonedHeadElementChild),p2.openElements.push(p2.headElement,TAG_ID.HEAD),startTagInHead(p2,token),p2.openElements.remove(p2.headElement);break}case TAG_ID.HEAD:{p2._err(token,ERR.misplacedStartTagForHeadElement);break}default:tokenAfterHead(p2,token)}}function endTagAfterHead(p2,token){switch(token.tagID){case TAG_ID.BODY:case TAG_ID.HTML:case TAG_ID.BR:{tokenAfterHead(p2,token);break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}default:p2._err(token,ERR.endTagWithoutMatchingOpenElement)}}function tokenAfterHead(p2,token){p2._insertFakeElement(TAG_NAMES.BODY,TAG_ID.BODY),p2.insertionMode=InsertionMode.IN_BODY,modeInBody(p2,token)}function modeInBody(p2,token){switch(token.type){case TokenType.CHARACTER:{characterInBody(p2,token);break}case TokenType.WHITESPACE_CHARACTER:{whitespaceCharacterInBody(p2,token);break}case TokenType.COMMENT:{appendComment(p2,token);break}case TokenType.START_TAG:{startTagInBody(p2,token);break}case TokenType.END_TAG:{endTagInBody(p2,token);break}case TokenType.EOF:{eofInBody(p2,token);break}default:}}function whitespaceCharacterInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertCharacters(token)}function characterInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertCharacters(token),p2.framesetOk=!1}function htmlStartTagInBody(p2,token){p2.openElements.tmplCount===0&&p2.treeAdapter.adoptAttributes(p2.openElements.items[0],token.attrs)}function bodyStartTagInBody(p2,token){let bodyElement=p2.openElements.tryPeekProperlyNestedBodyElement();bodyElement&&p2.openElements.tmplCount===0&&(p2.framesetOk=!1,p2.treeAdapter.adoptAttributes(bodyElement,token.attrs))}function framesetStartTagInBody(p2,token){let bodyElement=p2.openElements.tryPeekProperlyNestedBodyElement();p2.framesetOk&&bodyElement&&(p2.treeAdapter.detachNode(bodyElement),p2.openElements.popAllUpToHtmlElement(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_FRAMESET)}function addressStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML)}function numberedHeaderStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2.openElements.currentTagId!==void 0&&NUMBERED_HEADERS.has(p2.openElements.currentTagId)&&p2.openElements.pop(),p2._insertElement(token,NS.HTML)}function preStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML),p2.skipNextNewLine=!0,p2.framesetOk=!1}function formStartTagInBody(p2,token){let inTemplate=p2.openElements.tmplCount>0;(!p2.formElement||inTemplate)&&(p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML),inTemplate||(p2.formElement=p2.openElements.current))}function listItemStartTagInBody(p2,token){p2.framesetOk=!1;let tn2=token.tagID;for(let i2=p2.openElements.stackTop;i2>=0;i2--){let elementId=p2.openElements.tagIDs[i2];if(tn2===TAG_ID.LI&&elementId===TAG_ID.LI||(tn2===TAG_ID.DD||tn2===TAG_ID.DT)&&(elementId===TAG_ID.DD||elementId===TAG_ID.DT)){p2.openElements.generateImpliedEndTagsWithExclusion(elementId),p2.openElements.popUntilTagNamePopped(elementId);break}if(elementId!==TAG_ID.ADDRESS&&elementId!==TAG_ID.DIV&&elementId!==TAG_ID.P&&p2._isSpecialElement(p2.openElements.items[i2],elementId))break}p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML)}function plaintextStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML),p2.tokenizer.state=TokenizerMode.PLAINTEXT}function buttonStartTagInBody(p2,token){p2.openElements.hasInScope(TAG_ID.BUTTON)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(TAG_ID.BUTTON)),p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.framesetOk=!1}function aStartTagInBody(p2,token){let activeElementEntry=p2.activeFormattingElements.getElementEntryInScopeWithTagName(TAG_NAMES.A);activeElementEntry&&(callAdoptionAgency(p2,token),p2.openElements.remove(activeElementEntry.element),p2.activeFormattingElements.removeEntry(activeElementEntry)),p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.activeFormattingElements.pushElement(p2.openElements.current,token)}function bStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.activeFormattingElements.pushElement(p2.openElements.current,token)}function nobrStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2.openElements.hasInScope(TAG_ID.NOBR)&&(callAdoptionAgency(p2,token),p2._reconstructActiveFormattingElements()),p2._insertElement(token,NS.HTML),p2.activeFormattingElements.pushElement(p2.openElements.current,token)}function appletStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.activeFormattingElements.insertMarker(),p2.framesetOk=!1}function tableStartTagInBody(p2,token){p2.treeAdapter.getDocumentMode(p2.document)!==DOCUMENT_MODE.QUIRKS&&p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._insertElement(token,NS.HTML),p2.framesetOk=!1,p2.insertionMode=InsertionMode.IN_TABLE}function areaStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._appendElement(token,NS.HTML),p2.framesetOk=!1,token.ackSelfClosing=!0}function isHiddenInput(token){let inputType=getTokenAttr(token,ATTRS.TYPE);return inputType!=null&&inputType.toLowerCase()===HIDDEN_INPUT_TYPE}function inputStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._appendElement(token,NS.HTML),isHiddenInput(token)||(p2.framesetOk=!1),token.ackSelfClosing=!0}function paramStartTagInBody(p2,token){p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0}function hrStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._appendElement(token,NS.HTML),p2.framesetOk=!1,token.ackSelfClosing=!0}function imageStartTagInBody(p2,token){token.tagName=TAG_NAMES.IMG,token.tagID=TAG_ID.IMG,areaStartTagInBody(p2,token)}function textareaStartTagInBody(p2,token){p2._insertElement(token,NS.HTML),p2.skipNextNewLine=!0,p2.tokenizer.state=TokenizerMode.RCDATA,p2.originalInsertionMode=p2.insertionMode,p2.framesetOk=!1,p2.insertionMode=InsertionMode.TEXT}function xmpStartTagInBody(p2,token){p2.openElements.hasInButtonScope(TAG_ID.P)&&p2._closePElement(),p2._reconstructActiveFormattingElements(),p2.framesetOk=!1,p2._switchToTextParsing(token,TokenizerMode.RAWTEXT)}function iframeStartTagInBody(p2,token){p2.framesetOk=!1,p2._switchToTextParsing(token,TokenizerMode.RAWTEXT)}function rawTextStartTagInBody(p2,token){p2._switchToTextParsing(token,TokenizerMode.RAWTEXT)}function selectStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML),p2.framesetOk=!1,p2.insertionMode=p2.insertionMode===InsertionMode.IN_TABLE||p2.insertionMode===InsertionMode.IN_CAPTION||p2.insertionMode===InsertionMode.IN_TABLE_BODY||p2.insertionMode===InsertionMode.IN_ROW||p2.insertionMode===InsertionMode.IN_CELL?InsertionMode.IN_SELECT_IN_TABLE:InsertionMode.IN_SELECT}function optgroupStartTagInBody(p2,token){p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop(),p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML)}function rbStartTagInBody(p2,token){p2.openElements.hasInScope(TAG_ID.RUBY)&&p2.openElements.generateImpliedEndTags(),p2._insertElement(token,NS.HTML)}function rtStartTagInBody(p2,token){p2.openElements.hasInScope(TAG_ID.RUBY)&&p2.openElements.generateImpliedEndTagsWithExclusion(TAG_ID.RTC),p2._insertElement(token,NS.HTML)}function mathStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),adjustTokenMathMLAttrs(token),adjustTokenXMLAttrs(token),token.selfClosing?p2._appendElement(token,NS.MATHML):p2._insertElement(token,NS.MATHML),token.ackSelfClosing=!0}function svgStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),adjustTokenSVGAttrs(token),adjustTokenXMLAttrs(token),token.selfClosing?p2._appendElement(token,NS.SVG):p2._insertElement(token,NS.SVG),token.ackSelfClosing=!0}function genericStartTagInBody(p2,token){p2._reconstructActiveFormattingElements(),p2._insertElement(token,NS.HTML)}function startTagInBody(p2,token){switch(token.tagID){case TAG_ID.I:case TAG_ID.S:case TAG_ID.B:case TAG_ID.U:case TAG_ID.EM:case TAG_ID.TT:case TAG_ID.BIG:case TAG_ID.CODE:case TAG_ID.FONT:case TAG_ID.SMALL:case TAG_ID.STRIKE:case TAG_ID.STRONG:{bStartTagInBody(p2,token);break}case TAG_ID.A:{aStartTagInBody(p2,token);break}case TAG_ID.H1:case TAG_ID.H2:case TAG_ID.H3:case TAG_ID.H4:case TAG_ID.H5:case TAG_ID.H6:{numberedHeaderStartTagInBody(p2,token);break}case TAG_ID.P:case TAG_ID.DL:case TAG_ID.OL:case TAG_ID.UL:case TAG_ID.DIV:case TAG_ID.DIR:case TAG_ID.NAV:case TAG_ID.MAIN:case TAG_ID.MENU:case TAG_ID.ASIDE:case TAG_ID.CENTER:case TAG_ID.FIGURE:case TAG_ID.FOOTER:case TAG_ID.HEADER:case TAG_ID.HGROUP:case TAG_ID.DIALOG:case TAG_ID.DETAILS:case TAG_ID.ADDRESS:case TAG_ID.ARTICLE:case TAG_ID.SEARCH:case TAG_ID.SECTION:case TAG_ID.SUMMARY:case TAG_ID.FIELDSET:case TAG_ID.BLOCKQUOTE:case TAG_ID.FIGCAPTION:{addressStartTagInBody(p2,token);break}case TAG_ID.LI:case TAG_ID.DD:case TAG_ID.DT:{listItemStartTagInBody(p2,token);break}case TAG_ID.BR:case TAG_ID.IMG:case TAG_ID.WBR:case TAG_ID.AREA:case TAG_ID.EMBED:case TAG_ID.KEYGEN:{areaStartTagInBody(p2,token);break}case TAG_ID.HR:{hrStartTagInBody(p2,token);break}case TAG_ID.RB:case TAG_ID.RTC:{rbStartTagInBody(p2,token);break}case TAG_ID.RT:case TAG_ID.RP:{rtStartTagInBody(p2,token);break}case TAG_ID.PRE:case TAG_ID.LISTING:{preStartTagInBody(p2,token);break}case TAG_ID.XMP:{xmpStartTagInBody(p2,token);break}case TAG_ID.SVG:{svgStartTagInBody(p2,token);break}case TAG_ID.HTML:{htmlStartTagInBody(p2,token);break}case TAG_ID.BASE:case TAG_ID.LINK:case TAG_ID.META:case TAG_ID.STYLE:case TAG_ID.TITLE:case TAG_ID.SCRIPT:case TAG_ID.BGSOUND:case TAG_ID.BASEFONT:case TAG_ID.TEMPLATE:{startTagInHead(p2,token);break}case TAG_ID.BODY:{bodyStartTagInBody(p2,token);break}case TAG_ID.FORM:{formStartTagInBody(p2,token);break}case TAG_ID.NOBR:{nobrStartTagInBody(p2,token);break}case TAG_ID.MATH:{mathStartTagInBody(p2,token);break}case TAG_ID.TABLE:{tableStartTagInBody(p2,token);break}case TAG_ID.INPUT:{inputStartTagInBody(p2,token);break}case TAG_ID.PARAM:case TAG_ID.TRACK:case TAG_ID.SOURCE:{paramStartTagInBody(p2,token);break}case TAG_ID.IMAGE:{imageStartTagInBody(p2,token);break}case TAG_ID.BUTTON:{buttonStartTagInBody(p2,token);break}case TAG_ID.APPLET:case TAG_ID.OBJECT:case TAG_ID.MARQUEE:{appletStartTagInBody(p2,token);break}case TAG_ID.IFRAME:{iframeStartTagInBody(p2,token);break}case TAG_ID.SELECT:{selectStartTagInBody(p2,token);break}case TAG_ID.OPTION:case TAG_ID.OPTGROUP:{optgroupStartTagInBody(p2,token);break}case TAG_ID.NOEMBED:case TAG_ID.NOFRAMES:{rawTextStartTagInBody(p2,token);break}case TAG_ID.FRAMESET:{framesetStartTagInBody(p2,token);break}case TAG_ID.TEXTAREA:{textareaStartTagInBody(p2,token);break}case TAG_ID.NOSCRIPT:{p2.options.scriptingEnabled?rawTextStartTagInBody(p2,token):genericStartTagInBody(p2,token);break}case TAG_ID.PLAINTEXT:{plaintextStartTagInBody(p2,token);break}case TAG_ID.COL:case TAG_ID.TH:case TAG_ID.TD:case TAG_ID.TR:case TAG_ID.HEAD:case TAG_ID.FRAME:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:case TAG_ID.CAPTION:case TAG_ID.COLGROUP:break;default:genericStartTagInBody(p2,token)}}function bodyEndTagInBody(p2,token){if(p2.openElements.hasInScope(TAG_ID.BODY)&&(p2.insertionMode=InsertionMode.AFTER_BODY,p2.options.sourceCodeLocationInfo)){let bodyElement=p2.openElements.tryPeekProperlyNestedBodyElement();bodyElement&&p2._setEndLocation(bodyElement,token)}}function htmlEndTagInBody(p2,token){p2.openElements.hasInScope(TAG_ID.BODY)&&(p2.insertionMode=InsertionMode.AFTER_BODY,endTagAfterBody(p2,token))}function addressEndTagInBody(p2,token){let tn2=token.tagID;p2.openElements.hasInScope(tn2)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(tn2))}function formEndTagInBody(p2){let inTemplate=p2.openElements.tmplCount>0,{formElement}=p2;inTemplate||(p2.formElement=null),(formElement||inTemplate)&&p2.openElements.hasInScope(TAG_ID.FORM)&&(p2.openElements.generateImpliedEndTags(),inTemplate?p2.openElements.popUntilTagNamePopped(TAG_ID.FORM):formElement&&p2.openElements.remove(formElement))}function pEndTagInBody(p2){p2.openElements.hasInButtonScope(TAG_ID.P)||p2._insertFakeElement(TAG_NAMES.P,TAG_ID.P),p2._closePElement()}function liEndTagInBody(p2){p2.openElements.hasInListItemScope(TAG_ID.LI)&&(p2.openElements.generateImpliedEndTagsWithExclusion(TAG_ID.LI),p2.openElements.popUntilTagNamePopped(TAG_ID.LI))}function ddEndTagInBody(p2,token){let tn2=token.tagID;p2.openElements.hasInScope(tn2)&&(p2.openElements.generateImpliedEndTagsWithExclusion(tn2),p2.openElements.popUntilTagNamePopped(tn2))}function numberedHeaderEndTagInBody(p2){p2.openElements.hasNumberedHeaderInScope()&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilNumberedHeaderPopped())}function appletEndTagInBody(p2,token){let tn2=token.tagID;p2.openElements.hasInScope(tn2)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(tn2),p2.activeFormattingElements.clearToLastMarker())}function brEndTagInBody(p2){p2._reconstructActiveFormattingElements(),p2._insertFakeElement(TAG_NAMES.BR,TAG_ID.BR),p2.openElements.pop(),p2.framesetOk=!1}function genericEndTagInBody(p2,token){let tn2=token.tagName,tid=token.tagID;for(let i2=p2.openElements.stackTop;i2>0;i2--){let element=p2.openElements.items[i2],elementId=p2.openElements.tagIDs[i2];if(tid===elementId&&(tid!==TAG_ID.UNKNOWN||p2.treeAdapter.getTagName(element)===tn2)){p2.openElements.generateImpliedEndTagsWithExclusion(tid),p2.openElements.stackTop>=i2&&p2.openElements.shortenToLength(i2);break}if(p2._isSpecialElement(element,elementId))break}}function endTagInBody(p2,token){switch(token.tagID){case TAG_ID.A:case TAG_ID.B:case TAG_ID.I:case TAG_ID.S:case TAG_ID.U:case TAG_ID.EM:case TAG_ID.TT:case TAG_ID.BIG:case TAG_ID.CODE:case TAG_ID.FONT:case TAG_ID.NOBR:case TAG_ID.SMALL:case TAG_ID.STRIKE:case TAG_ID.STRONG:{callAdoptionAgency(p2,token);break}case TAG_ID.P:{pEndTagInBody(p2);break}case TAG_ID.DL:case TAG_ID.UL:case TAG_ID.OL:case TAG_ID.DIR:case TAG_ID.DIV:case TAG_ID.NAV:case TAG_ID.PRE:case TAG_ID.MAIN:case TAG_ID.MENU:case TAG_ID.ASIDE:case TAG_ID.BUTTON:case TAG_ID.CENTER:case TAG_ID.FIGURE:case TAG_ID.FOOTER:case TAG_ID.HEADER:case TAG_ID.HGROUP:case TAG_ID.DIALOG:case TAG_ID.ADDRESS:case TAG_ID.ARTICLE:case TAG_ID.DETAILS:case TAG_ID.SEARCH:case TAG_ID.SECTION:case TAG_ID.SUMMARY:case TAG_ID.LISTING:case TAG_ID.FIELDSET:case TAG_ID.BLOCKQUOTE:case TAG_ID.FIGCAPTION:{addressEndTagInBody(p2,token);break}case TAG_ID.LI:{liEndTagInBody(p2);break}case TAG_ID.DD:case TAG_ID.DT:{ddEndTagInBody(p2,token);break}case TAG_ID.H1:case TAG_ID.H2:case TAG_ID.H3:case TAG_ID.H4:case TAG_ID.H5:case TAG_ID.H6:{numberedHeaderEndTagInBody(p2);break}case TAG_ID.BR:{brEndTagInBody(p2);break}case TAG_ID.BODY:{bodyEndTagInBody(p2,token);break}case TAG_ID.HTML:{htmlEndTagInBody(p2,token);break}case TAG_ID.FORM:{formEndTagInBody(p2);break}case TAG_ID.APPLET:case TAG_ID.OBJECT:case TAG_ID.MARQUEE:{appletEndTagInBody(p2,token);break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}default:genericEndTagInBody(p2,token)}}function eofInBody(p2,token){p2.tmplInsertionModeStack.length>0?eofInTemplate(p2,token):stopParsing(p2,token)}function endTagInText(p2,token){var _a2;token.tagID===TAG_ID.SCRIPT&&((_a2=p2.scriptHandler)===null||_a2===void 0||_a2.call(p2,p2.openElements.current)),p2.openElements.pop(),p2.insertionMode=p2.originalInsertionMode}function eofInText(p2,token){p2._err(token,ERR.eofInElementThatCanContainOnlyText),p2.openElements.pop(),p2.insertionMode=p2.originalInsertionMode,p2.onEof(token)}function characterInTable(p2,token){if(p2.openElements.currentTagId!==void 0&&TABLE_STRUCTURE_TAGS.has(p2.openElements.currentTagId))switch(p2.pendingCharacterTokens.length=0,p2.hasNonWhitespacePendingCharacterToken=!1,p2.originalInsertionMode=p2.insertionMode,p2.insertionMode=InsertionMode.IN_TABLE_TEXT,token.type){case TokenType.CHARACTER:{characterInTableText(p2,token);break}case TokenType.WHITESPACE_CHARACTER:{whitespaceCharacterInTableText(p2,token);break}}else tokenInTable(p2,token)}function captionStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2.activeFormattingElements.insertMarker(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_CAPTION}function colgroupStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_COLUMN_GROUP}function colStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2._insertFakeElement(TAG_NAMES.COLGROUP,TAG_ID.COLGROUP),p2.insertionMode=InsertionMode.IN_COLUMN_GROUP,startTagInColumnGroup(p2,token)}function tbodyStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_TABLE_BODY}function tdStartTagInTable(p2,token){p2.openElements.clearBackToTableContext(),p2._insertFakeElement(TAG_NAMES.TBODY,TAG_ID.TBODY),p2.insertionMode=InsertionMode.IN_TABLE_BODY,startTagInTableBody(p2,token)}function tableStartTagInTable(p2,token){p2.openElements.hasInTableScope(TAG_ID.TABLE)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.TABLE),p2._resetInsertionMode(),p2._processStartTag(token))}function inputStartTagInTable(p2,token){isHiddenInput(token)?p2._appendElement(token,NS.HTML):tokenInTable(p2,token),token.ackSelfClosing=!0}function formStartTagInTable(p2,token){!p2.formElement&&p2.openElements.tmplCount===0&&(p2._insertElement(token,NS.HTML),p2.formElement=p2.openElements.current,p2.openElements.pop())}function startTagInTable(p2,token){switch(token.tagID){case TAG_ID.TD:case TAG_ID.TH:case TAG_ID.TR:{tdStartTagInTable(p2,token);break}case TAG_ID.STYLE:case TAG_ID.SCRIPT:case TAG_ID.TEMPLATE:{startTagInHead(p2,token);break}case TAG_ID.COL:{colStartTagInTable(p2,token);break}case TAG_ID.FORM:{formStartTagInTable(p2,token);break}case TAG_ID.TABLE:{tableStartTagInTable(p2,token);break}case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{tbodyStartTagInTable(p2,token);break}case TAG_ID.INPUT:{inputStartTagInTable(p2,token);break}case TAG_ID.CAPTION:{captionStartTagInTable(p2,token);break}case TAG_ID.COLGROUP:{colgroupStartTagInTable(p2,token);break}default:tokenInTable(p2,token)}}function endTagInTable(p2,token){switch(token.tagID){case TAG_ID.TABLE:{p2.openElements.hasInTableScope(TAG_ID.TABLE)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.TABLE),p2._resetInsertionMode());break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}case TAG_ID.BODY:case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:case TAG_ID.TBODY:case TAG_ID.TD:case TAG_ID.TFOOT:case TAG_ID.TH:case TAG_ID.THEAD:case TAG_ID.TR:break;default:tokenInTable(p2,token)}}function tokenInTable(p2,token){let savedFosterParentingState=p2.fosterParentingEnabled;p2.fosterParentingEnabled=!0,modeInBody(p2,token),p2.fosterParentingEnabled=savedFosterParentingState}function whitespaceCharacterInTableText(p2,token){p2.pendingCharacterTokens.push(token)}function characterInTableText(p2,token){p2.pendingCharacterTokens.push(token),p2.hasNonWhitespacePendingCharacterToken=!0}function tokenInTableText(p2,token){let i2=0;if(p2.hasNonWhitespacePendingCharacterToken)for(;i2<p2.pendingCharacterTokens.length;i2++)tokenInTable(p2,p2.pendingCharacterTokens[i2]);else for(;i2<p2.pendingCharacterTokens.length;i2++)p2._insertCharacters(p2.pendingCharacterTokens[i2]);p2.insertionMode=p2.originalInsertionMode,p2._processToken(token)}var TABLE_VOID_ELEMENTS=new Set([TAG_ID.CAPTION,TAG_ID.COL,TAG_ID.COLGROUP,TAG_ID.TBODY,TAG_ID.TD,TAG_ID.TFOOT,TAG_ID.TH,TAG_ID.THEAD,TAG_ID.TR]);function startTagInCaption(p2,token){let tn2=token.tagID;TABLE_VOID_ELEMENTS.has(tn2)?p2.openElements.hasInTableScope(TAG_ID.CAPTION)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(TAG_ID.CAPTION),p2.activeFormattingElements.clearToLastMarker(),p2.insertionMode=InsertionMode.IN_TABLE,startTagInTable(p2,token)):startTagInBody(p2,token)}function endTagInCaption(p2,token){let tn2=token.tagID;switch(tn2){case TAG_ID.CAPTION:case TAG_ID.TABLE:{p2.openElements.hasInTableScope(TAG_ID.CAPTION)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(TAG_ID.CAPTION),p2.activeFormattingElements.clearToLastMarker(),p2.insertionMode=InsertionMode.IN_TABLE,tn2===TAG_ID.TABLE&&endTagInTable(p2,token));break}case TAG_ID.BODY:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:case TAG_ID.TBODY:case TAG_ID.TD:case TAG_ID.TFOOT:case TAG_ID.TH:case TAG_ID.THEAD:case TAG_ID.TR:break;default:endTagInBody(p2,token)}}function startTagInColumnGroup(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.COL:{p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0;break}case TAG_ID.TEMPLATE:{startTagInHead(p2,token);break}default:tokenInColumnGroup(p2,token)}}function endTagInColumnGroup(p2,token){switch(token.tagID){case TAG_ID.COLGROUP:{p2.openElements.currentTagId===TAG_ID.COLGROUP&&(p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE);break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}case TAG_ID.COL:break;default:tokenInColumnGroup(p2,token)}}function tokenInColumnGroup(p2,token){p2.openElements.currentTagId===TAG_ID.COLGROUP&&(p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE,p2._processToken(token))}function startTagInTableBody(p2,token){switch(token.tagID){case TAG_ID.TR:{p2.openElements.clearBackToTableBodyContext(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_ROW;break}case TAG_ID.TH:case TAG_ID.TD:{p2.openElements.clearBackToTableBodyContext(),p2._insertFakeElement(TAG_NAMES.TR,TAG_ID.TR),p2.insertionMode=InsertionMode.IN_ROW,startTagInRow(p2,token);break}case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{p2.openElements.hasTableBodyContextInTableScope()&&(p2.openElements.clearBackToTableBodyContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE,startTagInTable(p2,token));break}default:startTagInTable(p2,token)}}function endTagInTableBody(p2,token){let tn2=token.tagID;switch(token.tagID){case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{p2.openElements.hasInTableScope(tn2)&&(p2.openElements.clearBackToTableBodyContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE);break}case TAG_ID.TABLE:{p2.openElements.hasTableBodyContextInTableScope()&&(p2.openElements.clearBackToTableBodyContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE,endTagInTable(p2,token));break}case TAG_ID.BODY:case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:case TAG_ID.TD:case TAG_ID.TH:case TAG_ID.TR:break;default:endTagInTable(p2,token)}}function startTagInRow(p2,token){switch(token.tagID){case TAG_ID.TH:case TAG_ID.TD:{p2.openElements.clearBackToTableRowContext(),p2._insertElement(token,NS.HTML),p2.insertionMode=InsertionMode.IN_CELL,p2.activeFormattingElements.insertMarker();break}case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:case TAG_ID.TR:{p2.openElements.hasInTableScope(TAG_ID.TR)&&(p2.openElements.clearBackToTableRowContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE_BODY,startTagInTableBody(p2,token));break}default:startTagInTable(p2,token)}}function endTagInRow(p2,token){switch(token.tagID){case TAG_ID.TR:{p2.openElements.hasInTableScope(TAG_ID.TR)&&(p2.openElements.clearBackToTableRowContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE_BODY);break}case TAG_ID.TABLE:{p2.openElements.hasInTableScope(TAG_ID.TR)&&(p2.openElements.clearBackToTableRowContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE_BODY,endTagInTableBody(p2,token));break}case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{(p2.openElements.hasInTableScope(token.tagID)||p2.openElements.hasInTableScope(TAG_ID.TR))&&(p2.openElements.clearBackToTableRowContext(),p2.openElements.pop(),p2.insertionMode=InsertionMode.IN_TABLE_BODY,endTagInTableBody(p2,token));break}case TAG_ID.BODY:case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:case TAG_ID.TD:case TAG_ID.TH:break;default:endTagInTable(p2,token)}}function startTagInCell(p2,token){let tn2=token.tagID;TABLE_VOID_ELEMENTS.has(tn2)?(p2.openElements.hasInTableScope(TAG_ID.TD)||p2.openElements.hasInTableScope(TAG_ID.TH))&&(p2._closeTableCell(),startTagInRow(p2,token)):startTagInBody(p2,token)}function endTagInCell(p2,token){let tn2=token.tagID;switch(tn2){case TAG_ID.TD:case TAG_ID.TH:{p2.openElements.hasInTableScope(tn2)&&(p2.openElements.generateImpliedEndTags(),p2.openElements.popUntilTagNamePopped(tn2),p2.activeFormattingElements.clearToLastMarker(),p2.insertionMode=InsertionMode.IN_ROW);break}case TAG_ID.TABLE:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:case TAG_ID.TR:{p2.openElements.hasInTableScope(tn2)&&(p2._closeTableCell(),endTagInRow(p2,token));break}case TAG_ID.BODY:case TAG_ID.CAPTION:case TAG_ID.COL:case TAG_ID.COLGROUP:case TAG_ID.HTML:break;default:endTagInBody(p2,token)}}function startTagInSelect(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.OPTION:{p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop(),p2._insertElement(token,NS.HTML);break}case TAG_ID.OPTGROUP:{p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop(),p2.openElements.currentTagId===TAG_ID.OPTGROUP&&p2.openElements.pop(),p2._insertElement(token,NS.HTML);break}case TAG_ID.HR:{p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop(),p2.openElements.currentTagId===TAG_ID.OPTGROUP&&p2.openElements.pop(),p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0;break}case TAG_ID.INPUT:case TAG_ID.KEYGEN:case TAG_ID.TEXTAREA:case TAG_ID.SELECT:{p2.openElements.hasInSelectScope(TAG_ID.SELECT)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.SELECT),p2._resetInsertionMode(),token.tagID!==TAG_ID.SELECT&&p2._processStartTag(token));break}case TAG_ID.SCRIPT:case TAG_ID.TEMPLATE:{startTagInHead(p2,token);break}default:}}function endTagInSelect(p2,token){switch(token.tagID){case TAG_ID.OPTGROUP:{p2.openElements.stackTop>0&&p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.tagIDs[p2.openElements.stackTop-1]===TAG_ID.OPTGROUP&&p2.openElements.pop(),p2.openElements.currentTagId===TAG_ID.OPTGROUP&&p2.openElements.pop();break}case TAG_ID.OPTION:{p2.openElements.currentTagId===TAG_ID.OPTION&&p2.openElements.pop();break}case TAG_ID.SELECT:{p2.openElements.hasInSelectScope(TAG_ID.SELECT)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.SELECT),p2._resetInsertionMode());break}case TAG_ID.TEMPLATE:{templateEndTagInHead(p2,token);break}default:}}function startTagInSelectInTable(p2,token){let tn2=token.tagID;tn2===TAG_ID.CAPTION||tn2===TAG_ID.TABLE||tn2===TAG_ID.TBODY||tn2===TAG_ID.TFOOT||tn2===TAG_ID.THEAD||tn2===TAG_ID.TR||tn2===TAG_ID.TD||tn2===TAG_ID.TH?(p2.openElements.popUntilTagNamePopped(TAG_ID.SELECT),p2._resetInsertionMode(),p2._processStartTag(token)):startTagInSelect(p2,token)}function endTagInSelectInTable(p2,token){let tn2=token.tagID;tn2===TAG_ID.CAPTION||tn2===TAG_ID.TABLE||tn2===TAG_ID.TBODY||tn2===TAG_ID.TFOOT||tn2===TAG_ID.THEAD||tn2===TAG_ID.TR||tn2===TAG_ID.TD||tn2===TAG_ID.TH?p2.openElements.hasInTableScope(tn2)&&(p2.openElements.popUntilTagNamePopped(TAG_ID.SELECT),p2._resetInsertionMode(),p2.onEndTag(token)):endTagInSelect(p2,token)}function startTagInTemplate(p2,token){switch(token.tagID){case TAG_ID.BASE:case TAG_ID.BASEFONT:case TAG_ID.BGSOUND:case TAG_ID.LINK:case TAG_ID.META:case TAG_ID.NOFRAMES:case TAG_ID.SCRIPT:case TAG_ID.STYLE:case TAG_ID.TEMPLATE:case TAG_ID.TITLE:{startTagInHead(p2,token);break}case TAG_ID.CAPTION:case TAG_ID.COLGROUP:case TAG_ID.TBODY:case TAG_ID.TFOOT:case TAG_ID.THEAD:{p2.tmplInsertionModeStack[0]=InsertionMode.IN_TABLE,p2.insertionMode=InsertionMode.IN_TABLE,startTagInTable(p2,token);break}case TAG_ID.COL:{p2.tmplInsertionModeStack[0]=InsertionMode.IN_COLUMN_GROUP,p2.insertionMode=InsertionMode.IN_COLUMN_GROUP,startTagInColumnGroup(p2,token);break}case TAG_ID.TR:{p2.tmplInsertionModeStack[0]=InsertionMode.IN_TABLE_BODY,p2.insertionMode=InsertionMode.IN_TABLE_BODY,startTagInTableBody(p2,token);break}case TAG_ID.TD:case TAG_ID.TH:{p2.tmplInsertionModeStack[0]=InsertionMode.IN_ROW,p2.insertionMode=InsertionMode.IN_ROW,startTagInRow(p2,token);break}default:p2.tmplInsertionModeStack[0]=InsertionMode.IN_BODY,p2.insertionMode=InsertionMode.IN_BODY,startTagInBody(p2,token)}}function endTagInTemplate(p2,token){token.tagID===TAG_ID.TEMPLATE&&templateEndTagInHead(p2,token)}function eofInTemplate(p2,token){p2.openElements.tmplCount>0?(p2.openElements.popUntilTagNamePopped(TAG_ID.TEMPLATE),p2.activeFormattingElements.clearToLastMarker(),p2.tmplInsertionModeStack.shift(),p2._resetInsertionMode(),p2.onEof(token)):stopParsing(p2,token)}function startTagAfterBody(p2,token){token.tagID===TAG_ID.HTML?startTagInBody(p2,token):tokenAfterBody(p2,token)}function endTagAfterBody(p2,token){var _a2;if(token.tagID===TAG_ID.HTML){if(p2.fragmentContext||(p2.insertionMode=InsertionMode.AFTER_AFTER_BODY),p2.options.sourceCodeLocationInfo&&p2.openElements.tagIDs[0]===TAG_ID.HTML){p2._setEndLocation(p2.openElements.items[0],token);let bodyElement=p2.openElements.items[1];bodyElement&&!(!((_a2=p2.treeAdapter.getNodeSourceCodeLocation(bodyElement))===null||_a2===void 0)&&_a2.endTag)&&p2._setEndLocation(bodyElement,token)}}else tokenAfterBody(p2,token)}function tokenAfterBody(p2,token){p2.insertionMode=InsertionMode.IN_BODY,modeInBody(p2,token)}function startTagInFrameset(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.FRAMESET:{p2._insertElement(token,NS.HTML);break}case TAG_ID.FRAME:{p2._appendElement(token,NS.HTML),token.ackSelfClosing=!0;break}case TAG_ID.NOFRAMES:{startTagInHead(p2,token);break}default:}}function endTagInFrameset(p2,token){token.tagID===TAG_ID.FRAMESET&&!p2.openElements.isRootHtmlElementCurrent()&&(p2.openElements.pop(),!p2.fragmentContext&&p2.openElements.currentTagId!==TAG_ID.FRAMESET&&(p2.insertionMode=InsertionMode.AFTER_FRAMESET))}function startTagAfterFrameset(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.NOFRAMES:{startTagInHead(p2,token);break}default:}}function endTagAfterFrameset(p2,token){token.tagID===TAG_ID.HTML&&(p2.insertionMode=InsertionMode.AFTER_AFTER_FRAMESET)}function startTagAfterAfterBody(p2,token){token.tagID===TAG_ID.HTML?startTagInBody(p2,token):tokenAfterAfterBody(p2,token)}function tokenAfterAfterBody(p2,token){p2.insertionMode=InsertionMode.IN_BODY,modeInBody(p2,token)}function startTagAfterAfterFrameset(p2,token){switch(token.tagID){case TAG_ID.HTML:{startTagInBody(p2,token);break}case TAG_ID.NOFRAMES:{startTagInHead(p2,token);break}default:}}function nullCharacterInForeignContent(p2,token){token.chars=REPLACEMENT_CHARACTER,p2._insertCharacters(token)}function characterInForeignContent(p2,token){p2._insertCharacters(token),p2.framesetOk=!1}function popUntilHtmlOrIntegrationPoint(p2){for(;p2.treeAdapter.getNamespaceURI(p2.openElements.current)!==NS.HTML&&p2.openElements.currentTagId!==void 0&&!p2._isIntegrationPoint(p2.openElements.currentTagId,p2.openElements.current);)p2.openElements.pop()}function startTagInForeignContent(p2,token){if(causesExit(token))popUntilHtmlOrIntegrationPoint(p2),p2._startTagOutsideForeignContent(token);else{let current=p2._getAdjustedCurrentElement(),currentNs=p2.treeAdapter.getNamespaceURI(current);currentNs===NS.MATHML?adjustTokenMathMLAttrs(token):currentNs===NS.SVG&&(adjustTokenSVGTagName(token),adjustTokenSVGAttrs(token)),adjustTokenXMLAttrs(token),token.selfClosing?p2._appendElement(token,currentNs):p2._insertElement(token,currentNs),token.ackSelfClosing=!0}}function endTagInForeignContent(p2,token){if(token.tagID===TAG_ID.P||token.tagID===TAG_ID.BR){popUntilHtmlOrIntegrationPoint(p2),p2._endTagOutsideForeignContent(token);return}for(let i2=p2.openElements.stackTop;i2>0;i2--){let element=p2.openElements.items[i2];if(p2.treeAdapter.getNamespaceURI(element)===NS.HTML){p2._endTagOutsideForeignContent(token);break}let tagName=p2.treeAdapter.getTagName(element);if(tagName.toLowerCase()===token.tagName){token.tagName=tagName,p2.openElements.shortenToLength(i2);break}}}init_browser_globals();init_browser_globals();var getCodePoint=String.prototype.codePointAt==null?(c2,index4)=>(c2.charCodeAt(index4)&64512)===55296?(c2.charCodeAt(index4)-55296)*1024+c2.charCodeAt(index4+1)-56320+65536:c2.charCodeAt(index4):(input,index4)=>input.codePointAt(index4);var VOID_ELEMENTS=new Set([TAG_NAMES.AREA,TAG_NAMES.BASE,TAG_NAMES.BASEFONT,TAG_NAMES.BGSOUND,TAG_NAMES.BR,TAG_NAMES.COL,TAG_NAMES.EMBED,TAG_NAMES.FRAME,TAG_NAMES.HR,TAG_NAMES.IMG,TAG_NAMES.INPUT,TAG_NAMES.KEYGEN,TAG_NAMES.LINK,TAG_NAMES.META,TAG_NAMES.PARAM,TAG_NAMES.SOURCE,TAG_NAMES.TRACK,TAG_NAMES.WBR]);function parseFragment(fragmentContext,html2,options2){typeof fragmentContext=="string"&&(options2=html2,html2=fragmentContext,fragmentContext=null);let parser=Parser2.getFragmentParser(fragmentContext,options2);return parser.tokenizer.write(html2,!0),parser.getFragment()}init_browser_globals();var import_postcss=__toESM(require_postcss(),1),postcss_default=import_postcss.default,stringify4=import_postcss.default.stringify,fromJSON=import_postcss.default.fromJSON,plugin=import_postcss.default.plugin,parse3=import_postcss.default.parse,list4=import_postcss.default.list,document4=import_postcss.default.document,comment=import_postcss.default.comment,atRule=import_postcss.default.atRule,rule=import_postcss.default.rule,decl=import_postcss.default.decl,root2=import_postcss.default.root,CssSyntaxError=import_postcss.default.CssSyntaxError,Declaration=import_postcss.default.Declaration,Container=import_postcss.default.Container,Processor2=import_postcss.default.Processor,Document2=import_postcss.default.Document,Comment=import_postcss.default.Comment,Warning=import_postcss.default.Warning,AtRule=import_postcss.default.AtRule,Result=import_postcss.default.Result,Input=import_postcss.default.Input,Rule=import_postcss.default.Rule,Root=import_postcss.default.Root,Node2=import_postcss.default.Node;var import_postcss_value_parser=__toESM(require_lib3(),1),cssReferences=(source2,replace2)=>{let tree=postcss_default.parse(source2),value2=(source3,imports=!1)=>{let parsed2=(0,import_postcss_value_parser.default)(source3);parsed2.walk(node2=>{if(node2.type==="function"&&node2.value.toLowerCase()==="url"){let before=import_postcss_value_parser.default.stringify(node2.nodes).replace(/^(['"])(.*)\1$/,"$2"),next=replace2(before,!0);return next!==before&&(node2.nodes=(0,import_postcss_value_parser.default)(JSON.stringify(next)).nodes),!1}if(node2.type==="function"&&/^(?:-webkit-)?image-set$/i.test(node2.value))for(let child of node2.nodes)child.type==="string"&&(child.value=replace2(child.value,!0))});let first=parsed2.nodes.find(node2=>node2.type!=="space"&&node2.type!=="comment");return imports&&first?.type==="string"&&(first.value=replace2(first.value,!0)),parsed2.toString()};return tree.walkDecls(node2=>{node2.value=value2(node2.value)}),tree.walkAtRules(node2=>{node2.params=value2(node2.params,node2.name.toLowerCase()==="import")}),tree.toString()},assetReferences=(source2,extension2,replace2)=>{if(extension2==="css")return cssReferences(source2,replace2);let changes=[],walk2=parent=>{for(let node2 of parent.childNodes)if("tagName"in node2){for(let attr of node2.attrs){let next=attr.value;if(["src","poster","background"].includes(attr.name)||attr.name==="data"&&node2.tagName==="object"||["href","xlink:href"].includes(attr.name))next=replace2(attr.value,!["a","area","base"].includes(node2.tagName));else if(attr.name==="srcdoc")next=assetReferences(attr.value,"html",replace2);else if(attr.name==="style")next=cssReferences(attr.value,replace2);else if(["srcset","imagesrcset"].includes(attr.name)){let rest=attr.value;for(next="";rest;){let space=/^[\s,]*/.exec(rest)?.[0]??"";next+=space,rest=rest.slice(space.length);let token=/^\S+/.exec(rest)?.[0];if(!token)break;let url=token.replace(/,+$/,"");if(next+=replace2(url,!0)+token.slice(url.length),rest=rest.slice(token.length),!token.endsWith(",")){let descriptor=/^[^,]*,?/.exec(rest)?.[0]??"";next+=descriptor,rest=rest.slice(descriptor.length)}}}if(next===attr.value)continue;let name=attr.prefix?`${attr.prefix}:${attr.name}`:attr.name,location2=node2.sourceCodeLocation?.attrs?.[name];if(!location2)throw new Error(`Cannot update attribute: ${name}`);let raw=source2.slice(location2.startOffset,location2.endOffset),head=/^[^=]+\s*=\s*/.exec(raw)?.[0];if(!head)throw new Error(`Cannot update attribute: ${name}`);let quote=raw[head.length]==="'"?"'":'"',escaped=next.replaceAll("&","&").replaceAll("<","<").replaceAll(quote,quote==='"'?""":"'");changes.push({from:location2.startOffset,to:location2.endOffset,text:head+quote+escaped+quote})}if(node2.tagName==="style")for(let child of node2.childNodes){if(!("value"in child))continue;let next=cssReferences(child.value,replace2);if(next===child.value)continue;let location2=child.sourceCodeLocation;if(!location2)throw new Error("Cannot update style content");changes.push({from:location2.startOffset,to:location2.endOffset,text:next})}walk2("content"in node2?node2.content:node2)}};walk2(parseFragment(source2,{sourceCodeLocationInfo:!0}));for(let change of changes.sort((a2,b2)=>b2.from-a2.from))source2=source2.slice(0,change.from)+change.text+source2.slice(change.to);return source2};init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();var fromNumH=n2=>n2/2**32|0,fromNumL=n2=>n2>>>0;function setU64FromNum(view,byteOffset,n2,isLE){let h2=fromNumH(n2),l2=fromNumL(n2);view.setUint32(byteOffset,isLE?l2:h2,isLE),view.setUint32(byteOffset+4,isLE?h2:l2,isLE)}init_browser_globals();function isBytes(a2){return a2 instanceof Uint8Array||ArrayBuffer.isView(a2)&&a2.constructor.name==="Uint8Array"&&"BYTES_PER_ELEMENT"in a2&&a2.BYTES_PER_ELEMENT===1}var atitle=title=>title?`"${title}" `:"";function anumber(n2,title=""){if(typeof n2!="number")throw new TypeError(atitle(title)+"expected number, got "+typeof n2);if(!Number.isSafeInteger(n2)||n2<0)throw new RangeError(atitle(title)+"expected integer >= 0, got "+n2);return n2}function abytes(value2,length,title=""){if(isBytes(value2)&&(length===void 0||value2.length===length))return value2;length!==void 0&&anumber(length,"length");let bytes=isBytes(value2),ofLen=length!==void 0?` of length ${length}`:"",got=bytes?`length=${value2.length}`:`type=${typeof value2}`,message=atitle(title)+"expected Uint8Array"+ofLen+", got "+got;throw bytes?new RangeError(message):new TypeError(message)}var aobject=(value2,label2)=>{if(value2===null||typeof value2!="object"||Array.isArray(value2))throw new TypeError((label2==="object"?"":`"${label2}" `)+"expected object, got type="+typeof value2)},aopts=(value2,label2)=>{aobject(value2,label2);let proto=Object.getPrototypeOf(value2);if(proto!==Object.prototype&&proto!==null)throw new TypeError(`"${label2}" expected plain object`);if(Object.hasOwn(value2,"__proto__"))throw new TypeError(`"${label2}.__proto__" is not allowed`)};function aexists(instance,checkFinished=!0){if(instance.destroyed)throw new Error("hash was destroyed");if(checkFinished&&instance.finished)throw new Error("digest() was already called")}function aoutput(out,instance){abytes(out,void 0,"output");let min=instance.outputLen;if(!(out.length>=min))throw new RangeError('"output" expected length >= '+min)}function clean(...arrays){for(let i2=0;i2<arrays.length;i2++)arrays[i2].fill(0)}function createView(arr){return new DataView(arr.buffer,arr.byteOffset,arr.byteLength)}function rotr(word,shift){return word<<32-shift|word>>>shift}function checkOpts(defaults,opts,title="opts"){return aopts(defaults,"defaults"),opts!==void 0&&aopts(opts,title),Object.assign(Object.create(null),defaults,opts)}function createHasher(hashCons,info={}){if(typeof hashCons!="function")throw new TypeError('"hashCons" expected function, got type='+typeof hashCons);info=checkOpts({},info,"info");let hashC=(msg,opts)=>hashCons(opts).update(msg).digest(),tmp=hashCons(void 0);return hashC.outputLen=tmp.outputLen,hashC.blockLen=tmp.blockLen,hashC.canXOF=tmp.canXOF,hashC.create=opts=>hashCons(opts),Object.assign(hashC,info),Object.freeze(hashC)}var oidNist=suffix=>({oid:Uint8Array.from([6,9,96,134,72,1,101,3,4,2,suffix])});function Chi(a2,b2,c2){return a2&b2^~a2&c2}function Maj(a2,b2,c2){return a2&b2^a2&c2^b2&c2}var HashMD=class{blockLen;outputLen;canXOF=!1;padOffset;isLE;buffer;view;finished=!1;length=0;pos=0;destroyed=!1;constructor(blockLen,outputLen,padOffset,isLE){this.blockLen=blockLen,this.outputLen=outputLen,this.padOffset=padOffset,this.isLE=isLE,this.buffer=new Uint8Array(blockLen),this.view=createView(this.buffer)}update(data){aexists(this),abytes(data);let{view,buffer,blockLen}=this,len=data.length,processed=!1;for(let pos=0;pos<len;){let take=Math.min(blockLen-this.pos,len-pos);if(take===blockLen){let dataView=createView(data);for(;blockLen<=len-pos;pos+=blockLen)this.process(dataView,pos);processed=!0;continue}buffer.set(pos===0&&take===len?data:data.subarray(pos,pos+take),this.pos),this.pos+=take,pos+=take,this.pos===blockLen&&(this.process(view,0),this.pos=0,processed=!0)}return this.length+=data.length,processed&&this.roundClean(),this}digestInto(out){aexists(this),aoutput(out,this),this.finished=!0;let{buffer,view,blockLen,isLE}=this,{pos}=this;buffer[pos++]=128,buffer.fill(0,pos),this.padOffset>blockLen-pos&&(this.process(view,0),buffer.fill(0)),setU64FromNum(view,blockLen-8,this.length*8,isLE),this.process(view,0),this.roundClean();let oview=out===buffer?view:createView(out),len=this.outputLen,outLen=len/4,state=this.get();if(len%4||outLen>state.length)throw new Error("invalid outputLen");for(let i2=0;i2<outLen;i2++)oview.setUint32(4*i2,state[i2],isLE)}digest(){let{buffer,outputLen}=this;this.digestInto(buffer);let res=buffer.slice(0,outputLen);return this.destroy(),res}_cloneIntoMeta(to){let{buffer,length,finished,destroyed,pos}=this;return to.destroyed=destroyed,to.finished=finished,to.length=length,to.pos=pos,pos&&to.buffer.set(buffer),to}clone(){return this._cloneInto()}},SHA256_IV=Uint32Array.from([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]);var SHA256_K=Uint32Array.from([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),SHA256_W=new Uint32Array(64),SHA2_32B=class extends HashMD{A=0;B=0;C=0;D=0;E=0;F=0;G=0;H=0;constructor(outputLen,IV){super(64,outputLen,8,!1),this.A=IV[0]|0,this.B=IV[1]|0,this.C=IV[2]|0,this.D=IV[3]|0,this.E=IV[4]|0,this.F=IV[5]|0,this.G=IV[6]|0,this.H=IV[7]|0}get(){let{A:A3,B,C:C2,D:D2,E,F,G,H:H2}=this;return[A3,B,C2,D2,E,F,G,H2]}set(A3,B,C2,D2,E,F,G,H2){this.A=A3|0,this.B=B|0,this.C=C2|0,this.D=D2|0,this.E=E|0,this.F=F|0,this.G=G|0,this.H=H2|0}_cloneInto(to){return(to||=new this.constructor).set(...this.get()),this._cloneIntoMeta(to)}process(view,offset){for(let i2=0;i2<16;i2++,offset+=4)SHA256_W[i2]=view.getUint32(offset,!1);for(let i2=16;i2<64;i2++){let W15=SHA256_W[i2-15],W2=SHA256_W[i2-2],s0=rotr(W15,7)^rotr(W15,18)^W15>>>3,s1=rotr(W2,17)^rotr(W2,19)^W2>>>10;SHA256_W[i2]=s1+SHA256_W[i2-7]+s0+SHA256_W[i2-16]|0}let{A:A3,B,C:C2,D:D2,E,F,G,H:H2}=this;for(let i2=0;i2<64;i2++){let sigma1=rotr(E,6)^rotr(E,11)^rotr(E,25),T1=H2+sigma1+Chi(E,F,G)+SHA256_K[i2]+SHA256_W[i2]|0,T2=(rotr(A3,2)^rotr(A3,13)^rotr(A3,22))+Maj(A3,B,C2)|0;H2=G,G=F,F=E,E=D2+T1|0,D2=C2,C2=B,B=A3,A3=T1+T2|0}A3=A3+this.A|0,B=B+this.B|0,C2=C2+this.C|0,D2=D2+this.D|0,E=E+this.E|0,F=F+this.F|0,G=G+this.G|0,H2=H2+this.H|0,this.set(A3,B,C2,D2,E,F,G,H2)}roundClean(){clean(SHA256_W)}destroy(){this.destroyed=!0,this.set(0,0,0,0,0,0,0,0),clean(this.buffer)}},_SHA256=class extends SHA2_32B{constructor(){super(32,SHA256_IV)}};var sha256=createHasher(()=>new _SHA256,oidNist(1));var import_buffer2=__toESM(require_buffer(),1);var import_memfs=__toESM(require_lib11(),1),import_path_browserify2=__toESM(require_path_browserify(),1);init_browser_url();var{existsSync,linkSync,lstatSync,mkdirSync,readdirSync,readFileSync,realpathSync,renameSync,rmdirSync,rmSync,statSync,unlinkSync,writeFileSync}=import_memfs.fs,{open,readFile,stat}=import_memfs.fs.promises,{basename:basename3,dirname:dirname3,extname:extname2,isAbsolute:isAbsolute2,join:join4,posix,relative,resolve,sep}=import_path_browserify2.default,randomUUID=()=>crypto.randomUUID(),createHash=algorithm=>{if(algorithm!=="sha256")throw new Error(`Unsupported hash: ${algorithm}`);let digest=sha256.create(),hash={update(value2){return digest.update(typeof value2=="string"?new TextEncoder().encode(value2):value2),hash},digest(encoding){return import_buffer2.Buffer.from(digest.digest()).toString(encoding)}};return hash},isDeepStrictEqual=(left,right)=>{if(Object.is(left,right))return!0;if(!left||!right||typeof left!="object"||typeof right!="object"||Array.isArray(left)!==Array.isArray(right))return!1;let keys=Object.keys(left);return keys.length===Object.keys(right).length&&keys.every(key=>Object.hasOwn(right,key)&&isDeepStrictEqual(left[key],right[key]))};var execFileSync=()=>{throw Object.assign(new Error("External commands require the Node server"),{code:"ENOENT"})},execFile=execFileSync,spawnSync=()=>({status:null,stdout:"",stderr:"",error:Object.assign(new Error("Git runs in the workspace adapter"),{code:"ENOENT"})}),runInNewContext=(code4,context)=>{if(code4!=="render()")throw new Error("Only the built-in geometry renderer is supported");return context.render()};async function fetchPublicFile(url,validate2,progress){let parsed2=new URL(url);if(parsed2.protocol!=="https:"||parsed2.username||parsed2.password||parsed2.port||!parsed2.hostname.includes(".")||/^(?:[\d.]+|\[.*\])$/.test(parsed2.hostname)||/(?:^|\.)(?:local|localhost)$/.test(parsed2.hostname))throw new Error("Expected a public HTTPS URL without credentials");let response=await fetch(parsed2,{credentials:"omit",redirect:"error",referrerPolicy:"no-referrer",signal:AbortSignal.timeout(12e3)});if(!response.ok)throw new Error(response.status===404?"NOT_FOUND":"Could not load file");validate2?.(response.headers.get("content-type")??"");let reader=response.body?.getReader();if(!reader)throw new Error("Empty response");let chunks=[],length=response.headers.get("content-length"),total=length!==null&&/^\d+$/.test(length)&&Number.isSafeInteger(Number(length))&&!response.headers.get("content-encoding")?Number(length):void 0,size=0;try{for(progress?.(0,total);;){let{value:value2,done}=await reader.read();if(done)break;if(size+=value2.length,progress?.(size,total),size>2*1024*1024)throw new Error("File exceeds 2 MiB");chunks.push(value2)}}finally{await reader.cancel()}return import_buffer2.Buffer.concat(chunks)}var fileSig=path4=>{let st2;try{st2=statSync(path4)}catch{return"-"}return`${st2.mtimeMs}:${st2.size}`},createFileCache=()=>{let store=new Map;return{get:(path4,compute)=>{let raw=readFileSync(path4,"utf8"),hit=store.get(path4);if(hit?.raw===raw)return hit.value;let value2=compute(raw);return store.set(path4,{raw,value:value2}),value2}}},createSigCache=()=>{let hit;return{get:(sig,compute)=>(hit?.sig!==sig&&(hit={sig,value:compute()}),hit.value)}},dirSig=(dir,fileOf=n2=>n2)=>{let names2;try{names2=readdirSync(dir).sort()}catch{return"-"}return names2.map(n2=>`${n2}:${fileSig(join4(dir,fileOf(n2)))}`).join("|")};init_browser_globals();var import_ignore2=__toESM(require_ignore2(),1);var cached,scope,withIgnoredFilesCache=read=>{if(cached)return read();cached=new Map,scope=new Map;try{return read()}finally{cached=void 0,scope=void 0}},withinRead=(key,read)=>scope?(scope.has(key)||scope.set(key,read()),scope.get(key)):read(),ignoredFiles=(root4,files)=>{if(!cached)return readIgnoredFiles(root4,files);let key=resolve(root4),known=cached.get(key);known||(known=new Map,cached.set(key,known));let missing=[...new Set(files.filter(file=>!known.has(file)))];if(missing.length){let ignored=readIgnoredFiles(root4,missing);for(let file of missing)known.set(file,ignored.has(file))}return new Set(files.filter(file=>known.get(file)))},readIgnoredFiles=(root4,files)=>{if(!files.length)return new Set;let hasGit=directory2=>existsSync(join4(directory2,".git","HEAD"))||statSync(join4(directory2,".git"),{throwIfNoEntry:!1})?.isFile(),repository2=resolve(root4);for(;!hasGit(repository2)&&dirname3(repository2)!==repository2;)repository2=dirname3(repository2);let inRepository=hasGit(repository2);if(inRepository){let result=spawnSync("git",["-C",root4,"check-ignore","--stdin","-z"],{input:`${files.join("\0")}\0`,encoding:"utf8",timeout:2e3,maxBuffer:5e6,windowsHide:!0});if(result.status===0||result.status===1)return new Set(result.stdout.split("\0").filter(Boolean));if(result.error?.code!=="ENOENT")throw new Error(`Cannot check ignored files: ${result.error?.message??result.stderr.trim()}`)}let ignoreRoot=inRepository?repository2:root4,prefix=relative(ignoreRoot,root4).split(sep).join("/"),rules=new Map,readRules=directory2=>{let matcher=rules.get(directory2);if(!matcher){let path4=join4(ignoreRoot,directory2,".gitignore");matcher=(0,import_ignore2.default)().add(existsSync(path4)?readFileSync(path4,"utf8"):""),rules.set(directory2,matcher)}return matcher};return new Set(files.filter(file=>{let parts=posix.join(prefix,file).replace(/\/$/,"").split("/"),matchers=[];for(let i2=0;i2<parts.length;i2++){let directory2=parts.slice(0,i2).join("/");matchers.push(readRules(directory2));let ignored=!1;for(let[base2,matcher]of matchers.entries()){let path4=parts.slice(base2,i2+1).join("/")+(i2<parts.length-1||file.endsWith("/")?"/":""),result=matcher.test(path4);(result.ignored||result.unignored)&&(ignored=result.ignored)}if(ignored)return!0}return!1}))},assertNotIgnored=(root4,file)=>{let path4=join4(root4,file),resolved=existsSync(path4)?relative(realpathSync(root4),realpathSync(path4)).split(sep).join("/"):file;if(ignoredFiles(root4,[...new Set([file,resolved])]).size)throw new Error(`Referenced file is ignored by Git ignore rules: ${file}`)};init_browser_globals();init_browser_globals();var contentLanguages=iso6393.map(({iso6393:code4,name})=>({code:code4,name})).sort((a2,b2)=>a2.name.localeCompare(b2.name)),codes=new Map(iso6393.map(language=>[language.iso6393,language.name])),webLanguage=code4=>iso6393To1[code4]??code4;init_browser_globals();var manifests=new Map,parsed=createFileCache(),manifestFile=root4=>manifests.get(resolve(root4))??MANIFEST_FILE,projectRoot=(input=MANIFEST_FILE)=>{let file=resolve(input);if(!isManifestFile(basename3(file))||!existsSync(file)||!statSync(file).isFile())throw new Error(`Specify an existing dooc.yaml or <name>.dooc.yaml file: ${file}`);let root4=dirname3(file);return manifests.set(root4,basename3(file)),root4},parseManifestText=(raw,file=MANIFEST_FILE)=>{let value2;try{value2=parse2(raw)}catch(e2){return{tree:[],errors:[`${file}: invalid YAML (${e2 instanceof Error?e2.message:e2})`]}}let manifest2=parseManifest(value2);return manifest2.errors=manifest2.errors.map(error=>error.replace(/^dooc\.yaml(?=:)/,()=>file)),manifest2},readManifest=root4=>{let file=manifestFile(root4),path4=join4(root4,file);return existsSync(path4)?structuredClone(parsed.get(path4,raw=>parseManifestText(raw,file))):{tree:[],errors:[]}},writeManifest=(root4,tree,metadata={})=>{writeFileSync(join4(root4,manifestFile(root4)),serializeManifest(tree,metadata))};init_browser_globals();init_browser_globals();init_browser_globals();var listener;var reportDownloadProgress=event=>{try{listener?.(event)}catch{}};var TextfileUnavailable=class extends Error{constructor(reason){super(reason==="missing"?"File not found":"File could not be loaded");this.reason=reason}reason},MAX_BYTES=2*1024*1024,FETCH=`
|
|
393
393
|
const __name = (value) => value;
|
|
394
394
|
(${fetchPublicFile.toString()})(process.argv[1])
|
|
395
395
|
.then(data => process.stdout.write(data))
|
|
396
396
|
.catch(error => process.exit(error.message === "NOT_FOUND" ? 44 : error.message === "BLOCKED" ? 45 : 1));
|
|
397
|
-
`,remoteTextfileSource=file=>{let url=new URL(file);if(!/^https?:$/.test(url.protocol)||url.username||url.password)throw new Error("expected an HTTP(S) URL without embedded credentials");if(url.pathname.endsWith(".git")){let match=/^#([^:]+):(.+)$/.exec(url.hash),ref=decodeURIComponent(match?.[1]??""),path4=decodeURIComponent(match?.[2]??"");if(!ref||ref.startsWith("-")||/[\s\0~^:?*[\\]/.test(ref)||ref.includes("..")||ref.includes("@{")||!path4||path4.startsWith("/")||/[\0\r\n\\]/.test(path4)||path4.split("/").some(part=>!part||part==="."||part===".."))throw new Error("use https://host/repo.git#ref:path/to/file.ext");return url.hash="",{url:url.href,ref,path:path4}}return url.hostname==="github.com"&&/^\/[^/]+\/[^/]+\/blob\//.test(url.pathname)&&(url.hostname="raw.githubusercontent.com",url.pathname=url.pathname.replace("/blob/","/")),url.hash="",{url:url.href}},cache=new Map,pending=new Map,readRemoteTextfileAsync=async(file,domains,refresh=!1)=>{allowedPreviewUrl(file,domains);let source2=remoteTextfileSource(file);if(source2.ref)throw new Error("Git repositories require a dedicated preview protocol; use a public HTTPS file URL");allowedPreviewUrl(source2.url,domains);let cached2=cache.get(file);if(!refresh&&cached2&&cached2.expires>Date.now()){if(cached2.result instanceof Error)throw cached2.result;return cached2.result}let active=pending.get(file);if(active)return active;let task=(async()=>{let result;try{result=await fetchPublicFile(source2.url)}catch(error){if(error.message==="BLOCKED")throw new Error("External previews require a public network address");result=new TextfileUnavailable(error.message==="NOT_FOUND"?"missing":"unreachable")}if(cache.size>=64&&cache.clear(),cache.set(file,{result,expires:Date.now()+6e4}),result instanceof Error)throw result;return result})();pending.set(file,task);try{return await task}finally{pending.delete(file)}},readRemoteTextfile=(file,domains,refresh=!1)=>{allowedPreviewUrl(file,domains);let source2=remoteTextfileSource(file);if(source2.ref)throw new Error("Git repositories require a dedicated preview protocol; use a public HTTPS file URL");allowedPreviewUrl(source2.url,domains);let cached2=cache.get(file);if(!refresh&&cached2&&cached2.expires>Date.now()){if(cached2.result instanceof Error)throw cached2.result;return cached2.result}let result;try{result=execFileSync(process.execPath,["--input-type=module","-e",FETCH,source2.url],{timeout:12e3,maxBuffer:MAX_BYTES,stdio:["ignore","pipe","pipe"],env:{PATH:process.env.PATH}})}catch(error){if(error.status===45)throw new Error("External previews require a public network address");result=new TextfileUnavailable(error.status===44?"missing":"unreachable")}if(cache.size>=64&&cache.clear(),cache.set(file,{result,expires:Date.now()+6e4}),result instanceof Error)throw result;return result};var selectTextfileRange=(text5,range)=>{if(range===void 0)return text5;let[start,end]=parseTextfileRange(range),starts=[0,...[...text5.matchAll(/\r\n|\n|\r/g)].map(match=>match.index+match[0].length).filter(offset=>offset<text5.length)],from=starts[start-1];if(from===void 0)throw new Error(`range line ${start} does not exist`);if(starts[end-1]===void 0)throw new Error(`range line ${end} does not exist`);return text5.slice(from,starts[end]??text5.length).replace(/(?:\r\n|\n|\r)$/,"")},textfilePath=(root4,file)=>withinRead(`path\0${root4}\0${file}`,()=>resolveTextfilePath(root4,file)),resolveTextfilePath=(root4,file)=>{if(!file.trim()||/^[a-z][a-z\d+.-]*:/i.test(file)||/[\0\r\n]/.test(file)||isAbsolute2(file)||file.includes("\\")||file.split("/").includes(".."))throw new Error("expected a relative file path inside the docs root");let path4=resolve(root4,file),ancestor=path4;for(;!lstatSync(ancestor,{throwIfNoEntry:!1});)ancestor=dirname3(ancestor);let resolvedAncestor;try{resolvedAncestor=realpathSync(ancestor)}catch{throw new Error("cannot resolve the file path (check symlink targets)")}let resolved=resolve(resolvedAncestor,relative(ancestor,path4)),rel=relative(realpathSync(root4),resolved);if(rel===".."||rel.startsWith(`..${sep}`)||isAbsolute2(rel))throw new Error("file is outside the docs root");return resolved},readTextfile=(root4,file,refresh=!1,domains=[])=>{let data;if(isRemoteTextfile(file))data=readRemoteTextfile(file,domains,refresh);else{let path4=textfilePath(root4,file);if(assertNotIgnored(root4,file),!statSync(path4).isFile())throw new Error("expected a regular UTF-8 text file");data=readFileSync(path4)}return decodeTextfile(data)},decodeTextfile=data=>{let text5=new TextDecoder("utf-8",{fatal:!0,ignoreBOM:!0}).decode(data);if(text5.includes("\0"))throw new Error("expected a UTF-8 text file, not binary data");return text5},readTextfileAsync=async(root4,file,refresh=!1,domains=[])=>{if(isRemoteTextfile(file))return decodeTextfile(await readRemoteTextfileAsync(file,domains,refresh));let path4=textfilePath(root4,file);if(assertNotIgnored(root4,file),!(await stat(path4)).isFile())throw new Error("expected a regular UTF-8 text file");let handle2=await open(path4,"r");try{if(!(await handle2.stat()).isFile())throw new Error("expected a regular UTF-8 text file");return decodeTextfile(await handle2.readFile())}finally{await handle2.close()}},writeTextfile=(root4,file,content3,base2)=>{if(/[\0\uD800-\uDFFF]/u.test(content3))throw new Error("expected UTF-8 text");let path4=textfilePath(root4,file),current=lstatSync(path4,{throwIfNoEntry:!1})?readTextfile(root4,file):null;if(current!==base2)return!1;mkdirSync(dirname3(path4),{recursive:!0});let temp=join4(dirname3(path4),`.textfile-${randomUUID()}.tmp`);try{writeFileSync(temp,content3,{flag:"wx",mode:current===null?438:statSync(path4).mode}),current===null?linkSync(temp,path4):renameSync(temp,path4)}finally{rmSync(temp,{force:!0})}return!0};var translationFile=(file,language)=>{if(!isContentLanguage(language))throw new Error("Expected an ISO 639-3 language code");if(!localFile(file)||!file.endsWith(".md"))throw new Error("Expected a Markdown file path");return`locales/${language}/${file}`},translationLanguages=root4=>{let dir=textfilePath(root4,"locales");return existsSync(dir)?readdirSync(dir,{withFileTypes:!0}).filter(entry=>entry.isDirectory()&&isContentLanguage(entry.name)).map(entry=>entry.name).sort():[]},siteContentLanguages=(root4,manifest2=readManifest(root4))=>manifest2.languages??[...new Set([contentLanguageCode(manifest2.defaultLang??DEFAULT_LANG),...translationLanguages(root4)])],translationFiles=root4=>{let files=translationLanguages(root4).flatMap(language=>{let directory2=`locales/${language}`;return readdirSync(textfilePath(root4,directory2),{recursive:!0,withFileTypes:!0}).filter(entry=>entry.isFile()&&entry.name.endsWith(".md")).map(entry=>relative(root4,join4(entry.parentPath,entry.name)).replaceAll("\\","/")).filter(localFile).sort()}),ignored=ignoredFiles(root4,files);return files.filter(file=>!ignored.has(file))},setDocTranslation=(root4,sourceLanguage,id,language,added)=>{if(!isDocId(id))throw new Error("Invalid document id");if(language===sourceLanguage)throw new Error("Source language cannot be removed");let manifest2=readManifest(root4);if(manifest2.errors.length)throw new Error(manifest2.errors.join(`
|
|
397
|
+
`,remoteTextfileSource=file=>{let url=new URL(file);if(!/^https?:$/.test(url.protocol)||url.username||url.password)throw new Error("expected an HTTP(S) URL without embedded credentials");if(url.pathname.endsWith(".git")){let match=/^#([^:]+):(.+)$/.exec(url.hash),ref=decodeURIComponent(match?.[1]??""),path4=decodeURIComponent(match?.[2]??"");if(!ref||ref.startsWith("-")||/[\s\0~^:?*[\\]/.test(ref)||ref.includes("..")||ref.includes("@{")||!path4||path4.startsWith("/")||/[\0\r\n\\]/.test(path4)||path4.split("/").some(part=>!part||part==="."||part===".."))throw new Error("use https://host/repo.git#ref:path/to/file.ext");return url.hash="",{url:url.href,ref,path:path4}}return url.hostname==="github.com"&&/^\/[^/]+\/[^/]+\/blob\//.test(url.pathname)&&(url.hostname="raw.githubusercontent.com",url.pathname=url.pathname.replace("/blob/","/")),url.hash="",{url:url.href}},cache=new Map,pending=new Map,readRemoteTextfileAsync=async(file,domains,refresh=!1)=>{allowedPreviewUrl(file,domains);let source2=remoteTextfileSource(file);if(source2.ref)throw new Error("Git repositories require a dedicated preview protocol; use a public HTTPS file URL");allowedPreviewUrl(source2.url,domains);let cached2=cache.get(file);if(!refresh&&cached2&&cached2.expires>Date.now()){if(cached2.result instanceof Error)throw cached2.result;return cached2.result}let active=pending.get(file);if(active)return active;let task=(async()=>{let result,received=0,total;reportDownloadProgress({url:source2.url,state:"start",received});try{result=await fetchPublicFile(source2.url,void 0,(size,length)=>{received=size,total=length,reportDownloadProgress({url:source2.url,state:"progress",received,total})}),reportDownloadProgress({url:source2.url,state:"complete",received:result.length,total})}catch(error){if(reportDownloadProgress({url:source2.url,state:"error",received,total}),error.message==="BLOCKED")throw new Error("External previews require a public network address");result=new TextfileUnavailable(error.message==="NOT_FOUND"?"missing":"unreachable")}if(cache.size>=64&&cache.clear(),cache.set(file,{result,expires:Date.now()+6e4}),result instanceof Error)throw result;return result})();pending.set(file,task);try{return await task}finally{pending.delete(file)}},readRemoteTextfile=(file,domains,refresh=!1)=>{allowedPreviewUrl(file,domains);let source2=remoteTextfileSource(file);if(source2.ref)throw new Error("Git repositories require a dedicated preview protocol; use a public HTTPS file URL");allowedPreviewUrl(source2.url,domains);let cached2=cache.get(file);if(!refresh&&cached2&&cached2.expires>Date.now()){if(cached2.result instanceof Error)throw cached2.result;return cached2.result}let result;reportDownloadProgress({url:source2.url,state:"start",received:0});try{result=execFileSync(process.execPath,["--input-type=module","-e",FETCH,source2.url],{timeout:12e3,maxBuffer:MAX_BYTES,stdio:["ignore","pipe","pipe"],env:{PATH:process.env.PATH}}),reportDownloadProgress({url:source2.url,state:"complete",received:result.length})}catch(error){if(reportDownloadProgress({url:source2.url,state:"error",received:0}),error.status===45)throw new Error("External previews require a public network address");result=new TextfileUnavailable(error.status===44?"missing":"unreachable")}if(cache.size>=64&&cache.clear(),cache.set(file,{result,expires:Date.now()+6e4}),result instanceof Error)throw result;return result};var selectTextfileRange=(text5,range)=>{if(range===void 0)return text5;let[start,end]=parseTextfileRange(range),starts=[0,...[...text5.matchAll(/\r\n|\n|\r/g)].map(match=>match.index+match[0].length).filter(offset=>offset<text5.length)],from=starts[start-1];if(from===void 0)throw new Error(`range line ${start} does not exist`);if(starts[end-1]===void 0)throw new Error(`range line ${end} does not exist`);return text5.slice(from,starts[end]??text5.length).replace(/(?:\r\n|\n|\r)$/,"")},textfilePath=(root4,file)=>withinRead(`path\0${root4}\0${file}`,()=>resolveTextfilePath(root4,file)),resolveTextfilePath=(root4,file)=>{if(!file.trim()||/^[a-z][a-z\d+.-]*:/i.test(file)||/[\0\r\n]/.test(file)||isAbsolute2(file)||file.includes("\\")||file.split("/").includes(".."))throw new Error("expected a relative file path inside the docs root");let path4=resolve(root4,file),ancestor=path4;for(;!lstatSync(ancestor,{throwIfNoEntry:!1});)ancestor=dirname3(ancestor);let resolvedAncestor;try{resolvedAncestor=realpathSync(ancestor)}catch{throw new Error("cannot resolve the file path (check symlink targets)")}let resolved=resolve(resolvedAncestor,relative(ancestor,path4)),rel=relative(realpathSync(root4),resolved);if(rel===".."||rel.startsWith(`..${sep}`)||isAbsolute2(rel))throw new Error("file is outside the docs root");return resolved},readTextfile=(root4,file,refresh=!1,domains=[])=>{let data;if(isRemoteTextfile(file))data=readRemoteTextfile(file,domains,refresh);else{let path4=textfilePath(root4,file);if(assertNotIgnored(root4,file),!statSync(path4).isFile())throw new Error("expected a regular UTF-8 text file");data=readFileSync(path4)}return decodeTextfile(data)},decodeTextfile=data=>{let text5=new TextDecoder("utf-8",{fatal:!0,ignoreBOM:!0}).decode(data);if(text5.includes("\0"))throw new Error("expected a UTF-8 text file, not binary data");return text5},readTextfileAsync=async(root4,file,refresh=!1,domains=[])=>{if(isRemoteTextfile(file))return decodeTextfile(await readRemoteTextfileAsync(file,domains,refresh));let path4=textfilePath(root4,file);if(assertNotIgnored(root4,file),!(await stat(path4)).isFile())throw new Error("expected a regular UTF-8 text file");let handle2=await open(path4,"r");try{if(!(await handle2.stat()).isFile())throw new Error("expected a regular UTF-8 text file");return decodeTextfile(await handle2.readFile())}finally{await handle2.close()}},writeTextfile=(root4,file,content3,base2)=>{if(/[\0\uD800-\uDFFF]/u.test(content3))throw new Error("expected UTF-8 text");let path4=textfilePath(root4,file),current=lstatSync(path4,{throwIfNoEntry:!1})?readTextfile(root4,file):null;if(current!==base2)return!1;mkdirSync(dirname3(path4),{recursive:!0});let temp=join4(dirname3(path4),`.textfile-${randomUUID()}.tmp`);try{writeFileSync(temp,content3,{flag:"wx",mode:current===null?438:statSync(path4).mode}),current===null?linkSync(temp,path4):renameSync(temp,path4)}finally{rmSync(temp,{force:!0})}return!0};var translationFile=(file,language)=>{if(!isContentLanguage(language))throw new Error("Expected an ISO 639-3 language code");if(!localFile(file)||!file.endsWith(".md"))throw new Error("Expected a Markdown file path");return`locales/${language}/${file}`},translationLanguages=root4=>{let dir=textfilePath(root4,"locales");return existsSync(dir)?readdirSync(dir,{withFileTypes:!0}).filter(entry=>entry.isDirectory()&&isContentLanguage(entry.name)).map(entry=>entry.name).sort():[]},siteContentLanguages=(root4,manifest2=readManifest(root4))=>manifest2.languages??[...new Set([contentLanguageCode(manifest2.defaultLang??DEFAULT_LANG),...translationLanguages(root4)])],translationFiles=root4=>{let files=translationLanguages(root4).flatMap(language=>{let directory2=`locales/${language}`;return readdirSync(textfilePath(root4,directory2),{recursive:!0,withFileTypes:!0}).filter(entry=>entry.isFile()&&entry.name.endsWith(".md")).map(entry=>relative(root4,join4(entry.parentPath,entry.name)).replaceAll("\\","/")).filter(localFile).sort()}),ignored=ignoredFiles(root4,files);return files.filter(file=>!ignored.has(file))},setDocTranslation=(root4,sourceLanguage,id,language,added)=>{if(!isDocId(id))throw new Error("Invalid document id");if(language===sourceLanguage)throw new Error("Source language cannot be removed");let manifest2=readManifest(root4);if(manifest2.errors.length)throw new Error(manifest2.errors.join(`
|
|
398
398
|
`));if(manifest2.languages&&!manifest2.languages.includes(language))throw new Error(`Language ${language} is not declared in dooc.yaml languages`);let file=docFile(id,manifest2.files),translated=translationFile(file,language),path4=textfilePath(root4,translated),source2=readTextfile(root4,file);added!==existsSync(path4)&&(added?writeTextfile(root4,translated,source2,null):unlinkSync(path4))};init_browser_globals();init_browser_globals();var validation_default={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://json-schema.org/draft/2020-12/meta/validation",$vocabulary:{"https://json-schema.org/draft/2020-12/vocab/validation":!0},$dynamicAnchor:"meta",title:"Validation vocabulary meta-schema",type:["object","boolean"],properties:{type:{anyOf:[{$ref:"#/$defs/simpleTypes"},{type:"array",items:{$ref:"#/$defs/simpleTypes"},minItems:1,uniqueItems:!0}]},const:!0,enum:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/$defs/nonNegativeInteger"},minLength:{$ref:"#/$defs/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},maxItems:{$ref:"#/$defs/nonNegativeInteger"},minItems:{$ref:"#/$defs/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxContains:{$ref:"#/$defs/nonNegativeInteger"},minContains:{$ref:"#/$defs/nonNegativeInteger",default:1},maxProperties:{$ref:"#/$defs/nonNegativeInteger"},minProperties:{$ref:"#/$defs/nonNegativeIntegerDefault0"},required:{$ref:"#/$defs/stringArray"},dependentRequired:{type:"object",additionalProperties:{$ref:"#/$defs/stringArray"}}},$defs:{nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{$ref:"#/$defs/nonNegativeInteger",default:0},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}}};var schemaTypes=validation_default.$defs.simpleTypes.enum,schemaObject=value2=>!!value2&&typeof value2=="object"&&!Array.isArray(value2);init_browser_globals();var visitSchema=(schema5,base2,visit5)=>{if(schemaObject(schema5)){typeof schema5.$id=="string"&&(base2=new URL(schema5.$id,base2).href),visit5(schema5,base2);for(let key of["properties","patternProperties","$defs","definitions","dependentSchemas"])if(schemaObject(schema5[key]))for(let child of Object.values(schema5[key]))visitSchema(child,base2,visit5);for(let key of["allOf","anyOf","oneOf","prefixItems"])if(Array.isArray(schema5[key]))for(let child of schema5[key])visitSchema(child,base2,visit5);for(let key of["items","additionalProperties","unevaluatedProperties","unevaluatedItems","contains","propertyNames","not","if","then","else"])visitSchema(schema5[key],base2,visit5)}},schemaResolver=(schema5,context)=>{let base2=context?.uri??"file:///schema.json",resources=new Map,bases=new WeakMap;for(let[uri,document5]of Object.entries({...context?.schemas,[base2]:schema5}))resources.set(uri,document5),visitSchema(document5,uri,(node2,resolved)=>{bases.set(node2,resolved),(node2===document5||typeof node2.$id=="string")&&resources.set(resolved,node2);for(let key of["$anchor","$dynamicAnchor"])typeof node2[key]=="string"&&resources.set(`${resolved.split("#")[0]}#${node2[key]}`,node2)});return(definition3,onRef)=>{let current=schemaObject(definition3)?definition3:{},result=current,seen=new Set;for(;typeof current.$ref=="string"&&!seen.has(current);){seen.add(current);let uri=new URL(current.$ref,bases.get(current)??base2);onRef?.(uri.href);let target=resources.get(uri.href);if(target===void 0){let fragment=decodeURIComponent(uri.hash.slice(1));if(uri.hash="",target=resources.get(uri.href),fragment&&!fragment.startsWith("/"))break;for(let key of fragment?fragment.slice(1).split("/"):[]){let name=key.replaceAll("~1","/").replaceAll("~0","~");target=target&&typeof target=="object"&&Object.hasOwn(target,name)?target[name]:void 0}}if(!schemaObject(target))break;let{$ref:_ref,...siblings}=result;result={...target,...siblings},current=target}return result}};var rewriteSchemaFiles=(root4,registered,files,moves)=>{let writes=new Map;if(!moves.size)return writes;let uri=file=>`file:///${file.split("/").map(encodeURIComponent).join("/")}`,local=url=>url.protocol==="file:"&&!url.host&&!url.search?decodeURIComponent(url.pathname.slice(1)):void 0,available=new Set(files),pending2=new Set(registered.filter(file=>available.has(file))),sources=new Map;for(let file of pending2){let raw=readFileSync(textfilePath(root4,file),"utf8"),schema5;try{schema5=JSON.parse(raw)}catch{continue}schemaObject(schema5)&&(sources.set(file,{raw,schema:schema5}),visitSchema(schema5,uri(file),(node2,base2)=>{for(let key of["$ref","$dynamicRef"]){if(typeof node2[key]!="string")continue;let target=local(new URL(node2[key],base2));target&&available.has(target)&&pending2.add(target)}}))}let bases=new WeakMap,resources=new Map;for(let[file,{schema:schema5}]of sources)visitSchema(schema5,uri(moves.get(file)??file),(node2,base2)=>bases.set(node2,base2)),visitSchema(schema5,uri(file),(node2,base2)=>{(node2===schema5||typeof node2.$id=="string")&&resources.set(base2,bases.get(node2))});for(let[file,{raw,schema:schema5}]of sources){let changed=!1;visitSchema(schema5,uri(file),(node2,base2)=>{let nextBase=bases.get(node2);for(let key of["$ref","$dynamicRef"]){let ref=node2[key];if(typeof ref!="string")continue;let target=new URL(ref,base2),path4=local(target);if(path4===void 0)continue;let fragment=target.hash;target.hash="";let destination=new URL(resources.get(target.href)??uri(moves.get(path4)??path4));if(destination.hash=fragment,new URL(ref,nextBase).href===destination.href)continue;let owner=new URL(nextBase);node2[key]=ref.startsWith("file:")?destination.href:(owner.pathname===destination.pathname?"":posix.relative(posix.dirname(owner.pathname),destination.pathname))+destination.hash,changed=!0}}),changed&&writes.set(file,JSON.stringify(schema5,null,raw.match(/\n([\t ]+)"/)?.[1]??2)+(raw.endsWith(`
|
|
399
399
|
`)?`
|
|
400
400
|
`:""))}return writes};init_browser_globals();init_browser_globals();var themeVariantFile=(file,theme)=>{if(!localFile(file)||!/^[a-z][a-z0-9-]*$/.test(theme))throw new Error("Expected a local file and a theme name");return`themes/${theme}/${file}`},mountThemeVariants=doc=>{let media=matchMedia("(prefers-color-scheme: dark)"),apply=()=>{for(let group of doc.querySelectorAll("[data-theme-variants]")){let choice=group.closest("[data-theme]")?.dataset.theme,theme=!choice||choice==="auto"?media.matches?"dark":"light":choice,children=[...group.children],selected=children.find(child=>child.dataset.themeVariant===theme)??children.find(child=>child.dataset.themeVariant==="");for(let child of children){let hidden=child!==selected;if(child.hidden!==hidden&&(child.hidden=hidden,!hidden))for(let frame of child.querySelectorAll("iframe"))frame.replaceWith(frame.cloneNode(!0))}}};new MutationObserver(apply).observe(doc.documentElement,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["data-theme"]}),media.addEventListener("change",apply),apply()};var themeNames=root4=>{let directory2=textfilePath(root4,"themes");return existsSync(directory2)?readdirSync(directory2,{withFileTypes:!0}).filter(entry=>entry.isDirectory()&&/^[a-z][a-z0-9-]*$/.test(entry.name)).map(entry=>entry.name).sort():[]},siteThemes=(root4,manifest2=readManifest(root4))=>manifest2.themes??themeNames(root4),themeVariants=(root4,file,themes=siteThemes(root4))=>{if(!localFile(file)||file.startsWith("themes/"))return{};let variants=themes.map(theme=>[theme,themeVariantFile(file,theme)]).filter(([,path4])=>existsSync(textfilePath(root4,path4))),ignored=ignoredFiles(root4,variants.map(([,path4])=>path4));return Object.fromEntries(variants.filter(([,path4])=>!ignored.has(path4)))};var reserved=new Set(["docs.config.mjs","node_modules","dist","locales"]),managedFile=file=>localFile(file)&&!isManifestFile(file.split("/")[0]??"")&&!reserved.has(file.split("/")[0]??""),names=new Intl.Collator("en",{numeric:!0}),compareFilePaths=(a2,b2)=>{let left=a2.split("/"),right=b2.split("/");for(let i2=0;i2<Math.min(left.length,right.length);i2++){let first=left[i2],second=right[i2];if(first!==second)return+(i2<right.length-1)-+(i2<left.length-1)||names.compare(first,second)||(first<second?-1:1)}return left.length-right.length},completeFilePaths=(root4,prefix)=>{if(typeof prefix!="string"||prefix.length>4096)throw new Error("Invalid file prefix");let slash=prefix.lastIndexOf("/"),directory2=prefix.slice(0,slash+1);if(prefix&&!managedFile(prefix.replace(/\/$/,"")))throw new Error("Expected a relative project path");let path4=directory2?textfilePath(root4,directory2):root4;if(!existsSync(path4))return[];let entries=readdirSync(path4,{withFileTypes:!0}).filter(entry=>!entry.isSymbolicLink()&&(entry.isFile()||entry.isDirectory())&&managedFile(directory2+entry.name)&&(directory2+entry.name).toLowerCase().startsWith(prefix.toLowerCase())).map(entry=>directory2+entry.name+(entry.isDirectory()?"/":"")),ignored=ignoredFiles(root4,entries);return entries.filter(file=>!ignored.has(file)).sort(compareFilePaths).slice(0,200)},projectFiles=root4=>[...withinRead(`files\0${root4}`,()=>walkProjectFiles(root4))],walkProjectFiles=root4=>{let result=[],walk2=directory2=>{for(let entry of readdirSync(join4(root4,directory2),{withFileTypes:!0})){let path4=directory2?`${directory2}/${entry.name}`:entry.name;!managedFile(path4)||entry.isSymbolicLink()||(entry.isDirectory()?walk2(path4):entry.isFile()&&result.push({path:path4,size:statSync(textfilePath(root4,path4)).size,extension:fileExtension(path4)}))}};walk2("");let ignored=ignoredFiles(root4,result.map(file=>file.path));return result.filter(file=>!ignored.has(file.path)).sort((a2,b2)=>compareFilePaths(a2.path,b2.path))},filesSnapshot=root4=>{let manifest2=readManifest(root4);if(manifest2.errors.length)throw new Error(manifest2.errors.join(`
|
|
@@ -457,15 +457,15 @@ ${node2.value}
|
|
|
457
457
|
${marker}`}return preserve(node2)}}}).stringify(parseMdast(body));return body.includes(`\r
|
|
458
458
|
`)?formatted.replaceAll(`
|
|
459
459
|
`,`\r
|
|
460
|
-
`):formatted}function command(value2){if(!Array.isArray(value2)||!value2.length||value2.some(v2=>typeof v2!="string"||v2.includes("\0"))||!value2[0])throw new Error("Tool command must be a nonempty array of strings");return value2}function execute(args,cwd2,input,lint){return new Promise((resolve2,reject)=>{let child=execFile(args[0],args.slice(1),{cwd:cwd2,timeout:1e4,killSignal:"SIGKILL",maxBuffer:1048576,encoding:"utf8"},(error,stdout,stderr)=>{error&&!(lint&&error.code===1&&!error.killed)?reject(new Error(stderr.trim().slice(0,2e3)||error.message)):resolve2(stdout)});child.stdin?.on("error",()=>{}),child.stdin?.end(input)})}async function runCodeTool(root4,body,position2,action){let block=codeBlockAt(body,position2);if(!/^[a-zA-Z0-9][a-zA-Z0-9_+-]*$/.test(block.language))throw new Error("Unsupported code language identifier");let path4=join4(root4,".dooc","editor-tools",`${block.language}.json`),config;try{config=JSON.parse(await readFile(path4,"utf8"))}catch(error){if(error.code!=="ENOENT")throw error;if(block.language!=="json")throw new Error(`Create .dooc/editor-tools/${block.language}.json to configure this language`)
|
|
460
|
+
`):formatted}function command(value2){if(!Array.isArray(value2)||!value2.length||value2.some(v2=>typeof v2!="string"||v2.includes("\0"))||!value2[0])throw new Error("Tool command must be a nonempty array of strings");return value2}function execute(args,cwd2,input,lint){return new Promise((resolve2,reject)=>{let child=execFile(args[0],args.slice(1),{cwd:cwd2,timeout:1e4,killSignal:"SIGKILL",maxBuffer:1048576,encoding:"utf8"},(error,stdout,stderr)=>{error&&!(lint&&error.code===1&&!error.killed)?reject(new Error(stderr.trim().slice(0,2e3)||error.message)):resolve2(stdout)});child.stdin?.on("error",()=>{}),child.stdin?.end(input)})}async function runCodeTool(root4,body,position2,action,allowExternal=!0){let block=codeBlockAt(body,position2);if(!/^[a-zA-Z0-9][a-zA-Z0-9_+-]*$/.test(block.language))throw new Error("Unsupported code language identifier");let path4=join4(root4,".dooc","editor-tools",`${block.language}.json`),config={};if(allowExternal)try{config=JSON.parse(await readFile(path4,"utf8"))}catch(error){if(error.code!=="ENOENT")throw error;if(block.language!=="json")throw new Error(`Create .dooc/editor-tools/${block.language}.json to configure this language`)}else if(block.language!=="json")throw new Error("External editor tools are disabled in remote sessions");if(!config||typeof config!="object")throw new Error("Invalid editor tool configuration");let tool=config[action==="format"?"formatter":"linter"],output;if(block.language==="json"&&tool==null){if(action==="lint")try{return JSON.parse(block.code),{findings:[]}}catch(error){return{findings:[{range:[block.from,block.to],message:String(error),ruleId:"error"}]}}output=formatJson(block.code)}else output=await execute(command(tool),root4,`${block.code}
|
|
461
461
|
`,action==="lint");if(action==="format"){let normalized=output.replace(/\r\n/g,`
|
|
462
462
|
`).replace(/\n$/,"");if(!normalized&&block.code.trim())throw new Error("Formatter returned empty output; code was kept unchanged");let lines2=normalized?normalized.split(`
|
|
463
463
|
`):[],fence3=new RegExp(`^ {0,3}${block.marker[0]}{${block.marker.length},}[ \\t]*$`);if(lines2.some(line2=>fence3.test(line2)))throw new Error("Formatter output would close the code fence");return{change:{from:block.from,to:block.to,insert:lines2.map(line2=>block.indent+line2+block.eol).join("")}}}let diagnostics=JSON.parse(output);if(!Array.isArray(diagnostics))throw new Error("Linter must return a JSON array");let lines=block.code.split(`
|
|
464
|
-
`),at2=(line2,column)=>{if(typeof line2!="number"||typeof column!="number"||!Number.isInteger(line2)||!Number.isInteger(column)||line2<1||line2>block.offsets.length||column<1||column>(lines[line2-1]?.length??0)+1)throw new Error("Invalid diagnostic position");return(block.offsets[line2-1]??block.from)+column-1};return{findings:diagnostics.map(d2=>{if(!d2||typeof d2!="object"||!("message"in d2)||typeof d2.message!="string")throw new Error("Invalid diagnostic");let item=d2,from=at2(item.line,item.column),to=item.endLine==null&&item.endColumn==null?Math.min(from+1,block.to):at2(item.endLine,item.endColumn);if(to<from)throw new Error("Invalid diagnostic range");let severity=item.severity??"warning";if(!["error","warning","info"].includes(String(severity)))throw new Error("Invalid diagnostic severity");return{range:[from,to],message:d2.message,ruleId:String(severity)}})}}async function validateCodeTools(root4,body){let original=body,configuredBlocks=async(text5,tool)=>{let blocks=[],nodes=[];visit(parseMdast(text5),node2=>{node2.type==="code"&&nodes.push(node2)});for(let node2 of nodes){if(node2.position){let position2=offsetAt(text5,node2.position.start.line,node2.position.start.column);/^ {0,3}(`{3,}|~{3,})/.test(text5.slice(position2))&&codeBlockAt(text5,position2)}if(node2.type!=="code"||node2.position?.start.offset==null||!node2.lang||!/^[a-zA-Z0-9][a-zA-Z0-9_+-]*$/.test(node2.lang))continue;let raw;try{raw=await readFile(join4(root4,".dooc/editor-tools",`${node2.lang}.json`),"utf8")}catch(error){if(error.code==="ENOENT"){node2.lang==="json"&&blocks.push(node2.position.start.offset);continue}throw error}let config=JSON.parse(raw);if(!config||typeof config!="object")throw new Error("Invalid editor tool configuration");(config[tool]!=null||node2.lang==="json")&&blocks.push(offsetAt(text5,node2.position.start.line,node2.position.start.column))}return blocks},originalFindings=[];for(let position2 of await configuredBlocks(body,"linter")){let result=await runCodeTool(root4,body,position2,"lint");originalFindings.push(...result.findings??[])}if(originalFindings.some(finding=>finding.ruleId==="error"))return{changes:[],findings:originalFindings};for(let position2 of(await configuredBlocks(body,"formatter")).reverse()){let{change}=await runCodeTool(root4,body,position2,"format");change&&body.slice(change.from,change.to)!==change.insert&&(body=body.slice(0,change.from)+change.insert+body.slice(change.to))}if(body=formatMarkdown(body),body===original)return{changes:[],findings:originalFindings};let findings=[];for(let position2 of await configuredBlocks(body,"linter")){let result=await runCodeTool(root4,body,position2,"lint");findings.push(...result.findings??[])}if(findings.some(finding=>finding.ruleId==="error"))throw new Error("Formatted code failed validation; code was kept unchanged");let from=0;for(;from<original.length&&from<body.length&&original[from]===body[from];)from++;let to=original.length,end=body.length;for(;to>from&&end>from&&original[to-1]===body[end-1];)to--,end--;return{changes:from===to&&from===end?[]:[{from,to,insert:body.slice(from,end)}],findings}}async function validateTextfileCode(root4,language,content3){if(!/^[a-zA-Z0-9][a-zA-Z0-9_+-]*$/.test(language)||content3.includes("\0"))throw new Error("Invalid text file tool request");let eol2=content3.includes(`\r
|
|
464
|
+
`),at2=(line2,column)=>{if(typeof line2!="number"||typeof column!="number"||!Number.isInteger(line2)||!Number.isInteger(column)||line2<1||line2>block.offsets.length||column<1||column>(lines[line2-1]?.length??0)+1)throw new Error("Invalid diagnostic position");return(block.offsets[line2-1]??block.from)+column-1};return{findings:diagnostics.map(d2=>{if(!d2||typeof d2!="object"||!("message"in d2)||typeof d2.message!="string")throw new Error("Invalid diagnostic");let item=d2,from=at2(item.line,item.column),to=item.endLine==null&&item.endColumn==null?Math.min(from+1,block.to):at2(item.endLine,item.endColumn);if(to<from)throw new Error("Invalid diagnostic range");let severity=item.severity??"warning";if(!["error","warning","info"].includes(String(severity)))throw new Error("Invalid diagnostic severity");return{range:[from,to],message:d2.message,ruleId:String(severity)}})}}async function validateCodeTools(root4,body,allowExternal=!0){let original=body,configuredBlocks=async(text5,tool)=>{let blocks=[],nodes=[];visit(parseMdast(text5),node2=>{node2.type==="code"&&nodes.push(node2)});for(let node2 of nodes){if(node2.position){let position2=offsetAt(text5,node2.position.start.line,node2.position.start.column);/^ {0,3}(`{3,}|~{3,})/.test(text5.slice(position2))&&codeBlockAt(text5,position2)}if(node2.type!=="code"||node2.position?.start.offset==null||!node2.lang||!/^[a-zA-Z0-9][a-zA-Z0-9_+-]*$/.test(node2.lang))continue;if(!allowExternal){node2.lang==="json"&&blocks.push(node2.position.start.offset);continue}let raw;try{raw=await readFile(join4(root4,".dooc/editor-tools",`${node2.lang}.json`),"utf8")}catch(error){if(error.code==="ENOENT"){node2.lang==="json"&&blocks.push(node2.position.start.offset);continue}throw error}let config=JSON.parse(raw);if(!config||typeof config!="object")throw new Error("Invalid editor tool configuration");(config[tool]!=null||node2.lang==="json")&&blocks.push(offsetAt(text5,node2.position.start.line,node2.position.start.column))}return blocks},originalFindings=[];for(let position2 of await configuredBlocks(body,"linter")){let result=await runCodeTool(root4,body,position2,"lint",allowExternal);originalFindings.push(...result.findings??[])}if(originalFindings.some(finding=>finding.ruleId==="error"))return{changes:[],findings:originalFindings};for(let position2 of(await configuredBlocks(body,"formatter")).reverse()){let{change}=await runCodeTool(root4,body,position2,"format",allowExternal);change&&body.slice(change.from,change.to)!==change.insert&&(body=body.slice(0,change.from)+change.insert+body.slice(change.to))}if(body=formatMarkdown(body),body===original)return{changes:[],findings:originalFindings};let findings=[];for(let position2 of await configuredBlocks(body,"linter")){let result=await runCodeTool(root4,body,position2,"lint",allowExternal);findings.push(...result.findings??[])}if(findings.some(finding=>finding.ruleId==="error"))throw new Error("Formatted code failed validation; code was kept unchanged");let from=0;for(;from<original.length&&from<body.length&&original[from]===body[from];)from++;let to=original.length,end=body.length;for(;to>from&&end>from&&original[to-1]===body[end-1];)to--,end--;return{changes:from===to&&from===end?[]:[{from,to,insert:body.slice(from,end)}],findings}}async function validateTextfileCode(root4,language,content3,allowExternal=!0){if(!/^[a-zA-Z0-9][a-zA-Z0-9_+-]*$/.test(language)||content3.includes("\0"))throw new Error("Invalid text file tool request");let eol2=content3.includes(`\r
|
|
465
465
|
`)?`\r
|
|
466
466
|
`:`
|
|
467
467
|
`,marker="`".repeat([...content3.matchAll(/`+/g)].reduce((length,match)=>Math.max(length,match[0].length+1),3)),prefix=`${marker}${language}${eol2}`,separator=content3&&!content3.endsWith(`
|
|
468
|
-
`)?eol2:"",body=`${prefix}${content3}${separator}${marker}${eol2}`,result=await validateCodeTools(root4,body);for(let change of[...result.changes].reverse())body=body.slice(0,change.from)+change.insert+body.slice(change.to);let block=codeBlockAt(body,0),formatted=body.slice(block.from,block.to);return separator&&(formatted=formatted.replace(/\r?\n$/,"")),{content:formatted,findings:result.findings.map(finding=>({...finding,range:finding.range.map(offset=>Math.max(0,Math.min(formatted.length,offset-block.from)))}))}}init_browser_globals();init_browser_globals();var createWorkspaceServer=(ops,info={})=>{let ports=new Set,hello={protocol:1,ops:Object.keys(ops),...info};return{connect(port,session){return ports.add(port),port.receive(message=>{if(!ports.has(port)||typeof message!="object"||message===null)return;let{id,op,args}=message;if(typeof id!="number")return;let reply=response=>{ports.has(port)&&port.send(response)};(async()=>{if(op==="hello")return hello;if(typeof op!="string"||!Object.hasOwn(ops,op))throw new Error(`Unknown workspace operation: ${String(op)}`);return ops[op]?.(typeof args=="object"&&args!==null&&!Array.isArray(args)?args:{},session)})().then(value2=>reply({id,value:value2}),error=>reply({id,error:error instanceof Error?error.message:String(error)}))}),()=>{ports.delete(port)}},broadcast(event,data){let message={event,data};for(let port of ports)port.send(message)}}};init_browser_globals();var applicationRequest=async(app2,mode,request2)=>{if(typeof request2.url!="string"||!request2.url.startsWith("/")||request2.url.startsWith("//")||!["GET","POST"].includes(request2.method)||typeof request2.body!="string")throw new Error("Invalid document request");if(!request2.headers||typeof request2.headers!="object"||Array.isArray(request2.headers)||Object.entries(request2.headers).some(([key,value2])=>!/^[-a-z0-9]+$/i.test(key)||typeof value2!="string"||/[\r\n\0]/.test(value2)))throw new Error("Invalid request headers");if(request2={...request2,headers:Object.fromEntries(Object.entries(request2.headers).map(([key,value2])=>[key.toLowerCase(),value2]))},new TextEncoder().encode(request2.body).length>5e6)throw new Error("Request body is too large");let status2=200,headers={},body="";return await app2.handle(mode,request2,{setHeader(name,value2){headers[name]=value2},writeHead(code4,values){status2=code4,Object.assign(headers,values)},end(value2){body=value2??""}}),{status:status2,headers,body}};init_browser_globals();init_browser_globals();init_browser_globals();var walkBlocks=blocks=>{let listBlocks=items=>items.flatMap(item=>typeof item=="string"?[]:"blocks"in item?walkBlocks(item.blocks):listBlocks(item.children));return blocks.flatMap(block=>[block,...block.type==="themeVariants"?walkBlocks([block.default,...Object.values(block.variants)]):block.type==="quote"?walkBlocks(block.blocks):block.type==="list"?listBlocks(block.items):[]])},slugify=text5=>text5.normalize("NFKD").toLowerCase().replace(/[^a-z0-9_\- ]/g,"").trim().replace(/\s+/g,"-").replace(/^-+|-+$/g,"");init_browser_globals();var termMap=terms=>new Map(terms.map(entry=>[entry.id,entry])),inlineSegmenter=(ctx={})=>{let terms=termMap(ctx.terms??[]),segments=nodes=>nodes.flatMap(node2=>{if(node2.type==="inlineCode")return[{kind:"code",text:node2.value}];if("value"in node2)return[{kind:"text",text:node2.value}];if(!("children"in node2))return[];let children=segments(node2.children),text5=children.map(child=>child.text).join("");if(node2.type==="strong"||node2.type==="emphasis")return[{kind:node2.type,text:text5,children}];if(node2.type==="link"){let id;try{id=parseTermReference(node2.url)}catch{}let formatted=children.some(child=>child.kind!=="text")?{children}:{};return[id?{kind:"term",id,text:text5||terms.get(id)?.name||node2.url,...formatted}:{kind:"link",text:text5,url:node2.url,...formatted}]}return children});return text5=>segments(parseMdast(text5).children)};init_browser_globals();var subformatReferences=tree=>{let references=[],definitions=new Map;return visit(tree,"definition",node2=>{definitions.set(node2.identifier,node2.url)}),visit(tree,node2=>{if(node2.type==="code"&&node2.lang?.toLowerCase()==="callouth")for(let ref of subformatReferences(parseMdast(node2.value)))references.push({...ref,line:ref.line+(node2.position?.start.line??1)});let target=node2.type==="link"||node2.type==="image"?node2.url:node2.type==="linkReference"||node2.type==="imageReference"?definitions.get(node2.identifier):void 0;if(!(!target||/^(?:[a-z][a-z\d+.-]*:|\/\/)/i.test(target)))try{let file=parseFileReference(target).file.replace(/^(\.\/)+/,"");localFile(file)&&references.push({file,line:node2.position?.start.line??1})}catch{}}),references};init_browser_globals();init_browser_globals();var escapeHtml=s2=>s2.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""");init_browser_globals();var unescapeXml=s2=>s2.replace(/&#(\d+);/g,(_2,d2)=>String.fromCodePoint(Number(d2))).replace(/&#x([0-9a-fA-F]+);/g,(_2,h2)=>String.fromCodePoint(Number.parseInt(h2,16))).replace(/</g,"<").replace(/>/g,">").replace(/"/g,'"').replace(/'/g,"'").replace(/&/g,"&"),DEFAULT_PAGE_NAMES=new Set(["page-1","\u30DA\u30FC\u30B8-1","page 1","untitled",""]),CONTENT_ATTR=/\scontent="(?:[^"\\]|\\.)*"/,rootHead=raw=>{let start=raw.indexOf("<svg");if(start<0)return;let end=raw.indexOf(">",start);return raw.slice(start,end<0?void 0:end+1)},extractMxfile=raw=>{let head=rootHead(raw),m2=head?/\scontent="([^"]*)"/.exec(head):null,xml=m2?.[1]?unescapeXml(m2[1]):void 0;return xml?.includes("<mxfile")||xml?.includes("<mxGraphModel")?xml:void 0},mxfilePageName=mxfile=>{let m2=/<diagram[^>]*\sname="([^"]*)"/.exec(mxfile),name=m2?.[1]?unescapeXml(m2[1]).trim():"";return name||void 0},isDrawioSvg=raw=>{if(extractMxfile(raw)||raw.includes("Text is not SVG - cannot display")||raw.includes("--ge-"))return!0;let head=rootHead(raw);return!!head&&/\sstyle="[^"]*color-scheme\s*:/.test(head)},PROLOG_ITEM=/^\s*(?:<\?xml[^>]*\?>|<!DOCTYPE[^>[]*(?:\[[\s\S]*?\])?>|<!--[\s\S]*?-->)\s*/i,stripProlog=s2=>{let out=s2.replace(/^\uFEFF/,"");for(let m2=PROLOG_ITEM.exec(out);m2;m2=PROLOG_ITEM.exec(out))out=out.slice(m2[0].length);return out.trim()},stripFallbackLink=s2=>s2.replace(/<switch>\s*<g\s+requiredFeatures="[^"]*"\s*\/>\s*<a\b[^>]*>[\s\S]*?<\/a>\s*<\/switch>/g,""),DARK_SURFACE="--ge-dark-color: var(--doc-panel, #161b22)",adaptRootStyle=markup=>{let open2=markup.indexOf(">");if(!markup.startsWith("<svg")||open2<0)return markup;let head=markup.slice(0,open2),rest=markup.slice(open2),m2=/\sstyle="([^"]*)"/.exec(head);if(!m2)return`${head} style="${DARK_SURFACE}"${rest}`;let decls=(m2[1]??"").split(";").map(d2=>d2.trim()).filter(d2=>d2&&!/^color-scheme\s*:/i.test(d2));return decls.push(DARK_SURFACE),`${head.slice(0,m2.index)} style="${decls.join("; ")}"${head.slice(m2.index+m2[0].length)}${rest}`},normalizeDrawioSvg=(name,raw)=>{let mxfile=extractMxfile(raw),markup=stripProlog(raw),headEnd=markup.indexOf(">");headEnd>=0&&(markup=markup.slice(0,headEnd).replace(CONTENT_ATTR,"")+markup.slice(headEnd)),markup=stripFallbackLink(markup).trim(),markup=adaptRootStyle(markup);let page=mxfile?mxfilePageName(mxfile):void 0,desc=page&&!DEFAULT_PAGE_NAMES.has(page.toLowerCase())?page:void 0,esc2=v2=>v2.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">"),open2=markup.indexOf(">");if(open2>=0){let body=markup.slice(open2+1).replace(/^\s*<title[^>]*>[\s\S]*?<\/title>/,"").replace(/^\s*<desc[^>]*>[\s\S]*?<\/desc>/,""),meta=`<title>Fig.${esc2(name)}</title>${desc?`<desc>${esc2(desc)}</desc>`:""}`;markup=`${markup.slice(0,open2+1)}${meta}${body}`}return{markup,desc}};init_browser_globals();var import_dxf=__toESM(require_lib13(),1);var dxfSvg=source2=>{if(source2=source2.replace(/\r\n?/g,`
|
|
468
|
+
`)?eol2:"",body=`${prefix}${content3}${separator}${marker}${eol2}`,result=await validateCodeTools(root4,body,allowExternal);for(let change of[...result.changes].reverse())body=body.slice(0,change.from)+change.insert+body.slice(change.to);let block=codeBlockAt(body,0),formatted=body.slice(block.from,block.to);return separator&&(formatted=formatted.replace(/\r?\n$/,"")),{content:formatted,findings:result.findings.map(finding=>({...finding,range:finding.range.map(offset=>Math.max(0,Math.min(formatted.length,offset-block.from)))}))}}init_browser_globals();init_browser_globals();var createWorkspaceServer=(ops,info={})=>{let ports=new Set,hello={protocol:1,ops:Object.keys(ops),...info};return{connect(port,session){return ports.add(port),port.receive(message=>{if(!ports.has(port)||typeof message!="object"||message===null)return;let{id,op,args}=message;if(typeof id!="number")return;let reply=response=>{ports.has(port)&&port.send(response)};(async()=>{if(op==="hello")return hello;if(typeof op!="string"||!Object.hasOwn(ops,op))throw new Error(`Unknown workspace operation: ${String(op)}`);return ops[op]?.(typeof args=="object"&&args!==null&&!Array.isArray(args)?args:{},session)})().then(value2=>reply({id,value:value2}),error=>reply({id,error:error instanceof Error?error.message:String(error)}))}),()=>{ports.delete(port)}},broadcast(event,data){let message={event,data};for(let port of ports)port.send(message)}}};init_browser_globals();var applicationRequest=async(app2,mode,request2)=>{if(typeof request2.url!="string"||!request2.url.startsWith("/")||request2.url.startsWith("//")||!["GET","POST"].includes(request2.method)||typeof request2.body!="string")throw new Error("Invalid document request");if(!request2.headers||typeof request2.headers!="object"||Array.isArray(request2.headers)||Object.entries(request2.headers).some(([key,value2])=>!/^[-a-z0-9]+$/i.test(key)||typeof value2!="string"||/[\r\n\0]/.test(value2)))throw new Error("Invalid request headers");if(request2={...request2,headers:Object.fromEntries(Object.entries(request2.headers).map(([key,value2])=>[key.toLowerCase(),value2]))},new TextEncoder().encode(request2.body).length>5e6)throw new Error("Request body is too large");let status2=200,headers={},body="";return await app2.handle(mode,request2,{setHeader(name,value2){headers[name]=value2},writeHead(code4,values){status2=code4,Object.assign(headers,values)},end(value2){body=value2??""}}),{status:status2,headers,body}};init_browser_globals();init_browser_globals();init_browser_globals();var walkBlocks=blocks=>{let listBlocks=items=>items.flatMap(item=>typeof item=="string"?[]:"blocks"in item?walkBlocks(item.blocks):listBlocks(item.children));return blocks.flatMap(block=>[block,...block.type==="themeVariants"?walkBlocks([block.default,...Object.values(block.variants)]):block.type==="quote"?walkBlocks(block.blocks):block.type==="list"?listBlocks(block.items):[]])},slugify=text5=>text5.normalize("NFKD").toLowerCase().replace(/[^a-z0-9_\- ]/g,"").trim().replace(/\s+/g,"-").replace(/^-+|-+$/g,"");init_browser_globals();var termMap=terms=>new Map(terms.map(entry=>[entry.id,entry])),inlineSegmenter=(ctx={})=>{let terms=termMap(ctx.terms??[]),segments=nodes=>nodes.flatMap(node2=>{if(node2.type==="inlineCode")return[{kind:"code",text:node2.value}];if("value"in node2)return[{kind:"text",text:node2.value}];if(!("children"in node2))return[];let children=segments(node2.children),text5=children.map(child=>child.text).join("");if(node2.type==="strong"||node2.type==="emphasis")return[{kind:node2.type,text:text5,children}];if(node2.type==="link"){let id;try{id=parseTermReference(node2.url)}catch{}let formatted=children.some(child=>child.kind!=="text")?{children}:{};return[id?{kind:"term",id,text:text5||terms.get(id)?.name||node2.url,...formatted}:{kind:"link",text:text5,url:node2.url,...formatted}]}return children});return text5=>segments(parseMdast(text5).children)};init_browser_globals();var subformatReferences=tree=>{let references=[],definitions=new Map;return visit(tree,"definition",node2=>{definitions.set(node2.identifier,node2.url)}),visit(tree,node2=>{if(node2.type==="code"&&node2.lang?.toLowerCase()==="callouth")for(let ref of subformatReferences(parseMdast(node2.value)))references.push({...ref,line:ref.line+(node2.position?.start.line??1)});let target=node2.type==="link"||node2.type==="image"?node2.url:node2.type==="linkReference"||node2.type==="imageReference"?definitions.get(node2.identifier):void 0;if(!(!target||/^(?:[a-z][a-z\d+.-]*:|\/\/)/i.test(target)))try{let file=parseFileReference(target).file.replace(/^(\.\/)+/,"");localFile(file)&&references.push({file,line:node2.position?.start.line??1})}catch{}}),references};init_browser_globals();init_browser_globals();var escapeHtml=s2=>s2.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""");init_browser_globals();var unescapeXml=s2=>s2.replace(/&#(\d+);/g,(_2,d2)=>String.fromCodePoint(Number(d2))).replace(/&#x([0-9a-fA-F]+);/g,(_2,h2)=>String.fromCodePoint(Number.parseInt(h2,16))).replace(/</g,"<").replace(/>/g,">").replace(/"/g,'"').replace(/'/g,"'").replace(/&/g,"&"),DEFAULT_PAGE_NAMES=new Set(["page-1","\u30DA\u30FC\u30B8-1","page 1","untitled",""]),CONTENT_ATTR=/\scontent="(?:[^"\\]|\\.)*"/,rootHead=raw=>{let start=raw.indexOf("<svg");if(start<0)return;let end=raw.indexOf(">",start);return raw.slice(start,end<0?void 0:end+1)},extractMxfile=raw=>{let head=rootHead(raw),m2=head?/\scontent="([^"]*)"/.exec(head):null,xml=m2?.[1]?unescapeXml(m2[1]):void 0;return xml?.includes("<mxfile")||xml?.includes("<mxGraphModel")?xml:void 0},mxfilePageName=mxfile=>{let m2=/<diagram[^>]*\sname="([^"]*)"/.exec(mxfile),name=m2?.[1]?unescapeXml(m2[1]).trim():"";return name||void 0},isDrawioSvg=raw=>{if(extractMxfile(raw)||raw.includes("Text is not SVG - cannot display")||raw.includes("--ge-"))return!0;let head=rootHead(raw);return!!head&&/\sstyle="[^"]*color-scheme\s*:/.test(head)},PROLOG_ITEM=/^\s*(?:<\?xml[^>]*\?>|<!DOCTYPE[^>[]*(?:\[[\s\S]*?\])?>|<!--[\s\S]*?-->)\s*/i,stripProlog=s2=>{let out=s2.replace(/^\uFEFF/,"");for(let m2=PROLOG_ITEM.exec(out);m2;m2=PROLOG_ITEM.exec(out))out=out.slice(m2[0].length);return out.trim()},stripFallbackLink=s2=>s2.replace(/<switch>\s*<g\s+requiredFeatures="[^"]*"\s*\/>\s*<a\b[^>]*>[\s\S]*?<\/a>\s*<\/switch>/g,""),DARK_SURFACE="--ge-dark-color: var(--doc-panel, #161b22)",adaptRootStyle=markup=>{let open2=markup.indexOf(">");if(!markup.startsWith("<svg")||open2<0)return markup;let head=markup.slice(0,open2),rest=markup.slice(open2),m2=/\sstyle="([^"]*)"/.exec(head);if(!m2)return`${head} style="${DARK_SURFACE}"${rest}`;let decls=(m2[1]??"").split(";").map(d2=>d2.trim()).filter(d2=>d2&&!/^color-scheme\s*:/i.test(d2));return decls.push(DARK_SURFACE),`${head.slice(0,m2.index)} style="${decls.join("; ")}"${head.slice(m2.index+m2[0].length)}${rest}`},normalizeDrawioSvg=(name,raw)=>{let mxfile=extractMxfile(raw),markup=stripProlog(raw),headEnd=markup.indexOf(">");headEnd>=0&&(markup=markup.slice(0,headEnd).replace(CONTENT_ATTR,"")+markup.slice(headEnd)),markup=stripFallbackLink(markup).trim(),markup=adaptRootStyle(markup);let page=mxfile?mxfilePageName(mxfile):void 0,desc=page&&!DEFAULT_PAGE_NAMES.has(page.toLowerCase())?page:void 0,esc2=v2=>v2.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">"),open2=markup.indexOf(">");if(open2>=0){let body=markup.slice(open2+1).replace(/^\s*<title[^>]*>[\s\S]*?<\/title>/,"").replace(/^\s*<desc[^>]*>[\s\S]*?<\/desc>/,""),meta=`<title>Fig.${esc2(name)}</title>${desc?`<desc>${esc2(desc)}</desc>`:""}`;markup=`${markup.slice(0,open2+1)}${meta}${body}`}return{markup,desc}};init_browser_globals();var import_dxf=__toESM(require_lib13(),1);var dxfSvg=source2=>{if(source2=source2.replace(/\r\n?/g,`
|
|
469
469
|
`).trim(),source2.includes("\0")||!/^\s*0\s*\nSECTION\s*$/m.test(source2)||!/\n\s*0\s*\nEOF$/.test(source2))throw new Error("Expected an ASCII DXF file");let output=runInNewContext("render()",{render:()=>{let helper=new import_dxf.Helper(source2);return{svg:helper.toSVG(),texts:helper.parsed?.entities.filter(entity=>entity.type==="TEXT")??[]}}},{timeout:2e3}),svg=output.svg.replace(/^<\?xml[^>]*>\s*/,""),bounds=/viewBox="([^"]+)"/.exec(svg)?.[1]?.split(/\s+/).map(Number);if(!bounds||bounds.length!==4||!bounds.every(Number.isFinite)||/NaN|Infinity/.test(svg))throw new Error("DXF contains no supported 2D geometry");let[x2=0,y2=0,width=0,height=0]=bounds,geometry=/<(?:path|circle|ellipse)\b/.test(svg),minX=geometry?x2:Number.POSITIVE_INFINITY,minY=geometry?y2:Number.POSITIVE_INFINITY,maxX=geometry?x2+width:Number.NEGATIVE_INFINITY,maxY=geometry?y2+height:Number.NEGATIVE_INFINITY,labels=[];for(let text5 of output.texts){if(!text5.string||text5.visible===!1)continue;let aligned=text5.hAlign||text5.vAlign,tx=(aligned?text5.x2:text5.x)??text5.x??0,ty=-((aligned?text5.y2:text5.y)??text5.y??0),size=text5.textHeight??2.5,rotation=-(text5.rotation??0),scale=text5.relScaleX??1;if(![tx,ty,size,rotation,scale].every(Number.isFinite)||size<=0||scale<=0)throw new Error("DXF text requires finite coordinates and a positive height and width scale");let value2=text5.string.replace(/%%c/gi,"\u2300").replace(/%%d/gi,"\xB0").replace(/%%p/gi,"\xB1"),anchor=text5.hAlign===1?"middle":text5.hAlign===2?"end":"start",baseline=["auto","text-after-edge","central","text-before-edge"][text5.vAlign??0]??"auto",span=value2.length*size*scale,left=anchor==="middle"?-span/2:anchor==="end"?-span:0,angle=rotation/180*Math.PI;for(let dx of[left,left+span])for(let dy of[-size,size]){let px=tx+dx*Math.cos(angle)-dy*Math.sin(angle),py=ty+dx*Math.sin(angle)+dy*Math.cos(angle);minX=Math.min(minX,px),minY=Math.min(minY,py),maxX=Math.max(maxX,px),maxY=Math.max(maxY,py)}labels.push(`<text transform="translate(${tx} ${ty}) rotate(${rotation}) scale(${scale} 1)" font-family="sans-serif" font-size="${size}" text-anchor="${anchor}" dominant-baseline="${baseline}" fill="var(--doc-fg, #000000)">${escapeHtml(value2)}</text>`)}if(!geometry&&!labels.length)throw new Error("DXF contains no supported 2D geometry or text");let padding=Math.max(maxX-minX,maxY-minY,1)*.04,viewBox=[minX-padding,minY-padding,maxX-minX+padding*2,maxY-minY+padding*2];if(!viewBox.every(Number.isFinite))throw new Error("DXF text exceeds finite preview bounds");return svg.replace(/viewBox="[^"]+"/,`viewBox="${viewBox.join(" ")}"`).replace('width="100%"','width="800"').replace(/<(path|circle|ellipse)\b/g,'<$1 vector-effect="non-scaling-stroke" stroke-width="1.25"').replace(/stroke="(?:#000000|rgb\(0, 0, 0\))"/g,'stroke="var(--doc-fg, #000000)"').replace("</svg>",()=>`${labels.join("")}</svg>`)};var EXT_RE=/\.(drawio\.svg|svg|html|png|webp|gif|mp4|webm|jpe?g|pdf|dxf)$/i,FILE_RE=/^[a-z0-9][a-z0-9_-]*\.(drawio\.svg|svg|html|png|webp|gif|mp4|webm|jpe?g|pdf|dxf)$/,IMAGE_MIME={png:"image/png",webp:"image/webp",gif:"image/gif",jpg:"image/jpeg",jpeg:"image/jpeg"},figureName=file=>FILE_RE.test(file.replace(/^figures\//,""))?file.replace(/^figures\//,"").replace(EXT_RE,""):`file-${createHash("sha256").update(file).digest("hex").slice(0,24)}`,figureUploadName=raw=>{let lower2=raw.toLowerCase().split(/[\\/]/).pop()??"",ext=EXT_RE.exec(lower2)?.[1];return ext==null?void 0:`${lower2.slice(0,-ext.length-1).replace(/[^a-z0-9_-]+/g,"-").replace(/^[^a-z0-9]+|-+$/g,"")||"figure"}.${ext}`},LIGHT_VARS="--doc-bg:#ffffff;--doc-bg-2:#f6f8fb;--doc-bg-3:#eef2f7;--doc-panel:#ffffff;--doc-panel-2:#f1f5fa;--doc-rail:#f3f6fa;--doc-border:#dde3eb;--doc-border-2:#c4ccd8;--doc-fg:#000000;--doc-fg-2:#2a3140;--doc-fg-3:#5b6271;--doc-fg-4:#9099a8;--doc-accent:#1b4994;--doc-accent-2:#0277bd;--doc-accent-fg:#ffffff;--doc-ok:#1f7a32;--doc-ok-2:#2ea043;--doc-warn:#b97600;--doc-warn-2:#f59f00;--doc-danger:#b53030;--doc-danger-2:#f04848;--doc-info:#0277bd;--doc-info-2:#4a8bff;",DARK_VARS="--doc-bg:#000000;--doc-bg-2:#0a0d12;--doc-bg-3:#11161c;--doc-panel:#161b22;--doc-panel-2:#1e2530;--doc-rail:#0d1117;--doc-border:#222831;--doc-border-2:#323a47;--doc-fg:#ffffff;--doc-fg-2:#c9d1d9;--doc-fg-3:#8b939e;--doc-fg-4:#525a66;--doc-accent:#4a8bff;--doc-accent-2:#1b4994;--doc-accent-fg:#ffffff;--doc-ok:#2ea043;--doc-ok-2:#56d364;--doc-warn:#f59f00;--doc-warn-2:#ffc14d;--doc-danger:#f04848;--doc-danger-2:#ff7a7a;--doc-info:#4a8bff;--doc-info-2:#79b0ff;",FIGURE_THEME_STYLE=`<style data-doc-figure-theme>[data-doc-figure]{color-scheme:light;${LIGHT_VARS}}@media (prefers-color-scheme: dark){[data-doc-figure]{color-scheme:dark;${DARK_VARS}}}:root[data-theme="light"] [data-doc-figure],[data-doc-theme="light"] [data-doc-figure],[data-doc-figure][data-doc-theme="light"]{color-scheme:light;${LIGHT_VARS}}:root[data-theme="dark"] [data-doc-figure],[data-doc-theme="dark"] [data-doc-figure],[data-doc-figure][data-doc-theme="dark"]{color-scheme:dark;${DARK_VARS}}</style>`,firstTag=(svg,tag2)=>{let m2=new RegExp(`<${tag2}[^>]*>([\\s\\S]*?)</${tag2}>`).exec(svg);return m2?m2[1]?.replace(/</g,"<").replace(/>/g,">").trim():void 0},HTML_META_RE=/^<!--fig\n([\s\S]*?)-->\n?/,normalizeHardcodedSurfaces=markup=>markup.replace(/background-color:\s*#fff(?:fff)?(?=[;}])/gi,"background-color:var(--doc-panel, #ffffff)").replace(/background:\s*#fff(?:fff)?(?=[;}])/gi,"background:var(--doc-panel, #ffffff)"),withSvgTheme=markup=>{let headEnd=markup.indexOf(">");if(headEnd<0)return markup;let head=markup.slice(0,headEnd);return`${head.includes("data-doc-figure")?head:`${head} data-doc-figure=""`}>${FIGURE_THEME_STYLE}${markup.slice(headEnd+1)}`},withHtmlTheme=markup=>{let themed=normalizeHardcodedSurfaces(markup);return themed.includes("data-doc-figure")||!themed.startsWith("<")?themed:`<div data-doc-figure="">${FIGURE_THEME_STYLE}${themed}</div>`},parseSvg=(file,raw,errors)=>{let markup=withSvgTheme(normalizeHardcodedSurfaces(raw.trim()));(!markup.startsWith("<svg")||!markup.endsWith("</svg>"))&&errors.push(`${file}: a single root <svg>\u2026</svg> is required`);let head=markup.slice(0,markup.indexOf(">"));return head.includes("xmlns=")||errors.push(`${file}: root <svg> requires xmlns (for standalone publishing)`),head.includes("viewBox=")||errors.push(`${file}: root <svg> requires viewBox (to scale with the width)`),{kind:"svg",markup,title:firstTag(markup,"title"),desc:firstTag(markup,"desc")}},parseHtml=(file,raw,errors)=>{let m2=HTML_META_RE.exec(raw);if(!m2)return errors.push(`${file}: a <!--fig\\ntitle: ...\\n--> meta comment is required at the top`),{kind:"html",markup:raw.trim()};let meta=new Map((m2[1]??"").split(`
|
|
470
470
|
`).filter(l2=>l2.includes(":")).map(l2=>[l2.slice(0,l2.indexOf(":")).trim(),l2.slice(l2.indexOf(":")+1).trim()])),markup=withHtmlTheme(raw.slice(m2[0].length).trim());return meta.get("title")||errors.push(`${file}: the meta comment requires title:`),markup.startsWith("<")||errors.push(`${file}: the meta comment must be followed by an HTML fragment`),/<script/i.test(markup)&&errors.push(`${file}: <script> is not allowed (self-contained static fragments only)`),{kind:"html",markup,title:meta.get("title"),desc:meta.get("desc")}},loadFigures=(figuresDir,extraFiles=[])=>{let errors=[],figures=[],root4=dirname3(figuresDir),files=[];try{files=readdirSync(textfilePath(root4,basename3(figuresDir))).filter(f2=>EXT_RE.test(f2)).sort()}catch(error){error.code!=="ENOENT"&&errors.push(`figures/: ${error instanceof Error?error.message:error}`)}files=[...new Set([...files.map(file=>`figures/${file}`),...extraFiles])];let ignored=ignoredFiles(dirname3(figuresDir),files),keyframeOwner=new Map;for(let file of files){if(ignored.has(file))continue;if(file.startsWith("figures/")&&!file.slice(8).includes("/")&&!FILE_RE.test(file.slice(8))){errors.push(`${file}: file name must be <name>.<extension> using [a-z0-9_-] and a supported image, html, video, pdf or dxf extension`);continue}let name=figureName(file),dup=figures.find(f2=>f2.name===name);if(dup){errors.push(`${file}: duplicate name "${name}" (also used by ${dup.file})`);continue}let path4;try{let relative2=file.startsWith("figures/")?`${basename3(figuresDir)}/${file.slice(8)}`:file;path4=textfilePath(root4,relative2),assertNotIgnored(root4,relative2)}catch(error){errors.push(`${file}: ${error instanceof Error?error.message:error}`);continue}if(/\.(pdf|dxf)$/i.test(file)){try{let data=readFileSync(path4);if(/\.dxf$/i.test(file)){let raw2=new TextDecoder("utf-8",{fatal:!0}).decode(data);figures.push({name,file,...parseSvg(file,dxfSvg(raw2),errors)})}else{if(data.subarray(0,5).toString("ascii")!=="%PDF-")throw new Error("Expected a PDF file beginning with %PDF-");let uri=`data:application/pdf;base64,${data.toString("base64")}`,download=`<a href="${uri}" download="${escapeHtml(file.split("/").at(-1)??"document.pdf")}" data-i18n="Download PDF">Download PDF</a>`;figures.push({name,file,kind:"pdf",markup:`<object type="application/pdf" data="${uri}" aria-label="PDF preview" style="display:block;width:100%;height:640px;max-height:80vh;min-height:320px">${download}</object>${download}`})}}catch(error){errors.push(`${file}: ${error instanceof Error?error.message:String(error)}`)}continue}if(/\.(mp4|webm)$/i.test(file)){let data=readFileSync(path4);figures.push({name,file,kind:"video",markup:`<video data-dooc-video controls playsinline preload="metadata" aria-label="Video preview" src="data:video/${file.toLowerCase().endsWith(".mp4")?"mp4":"webm"};base64,${data.toString("base64")}"></video>`});continue}let mime=IMAGE_MIME[file.slice(file.lastIndexOf(".")+1).toLowerCase()];if(mime!=null){let data=readFileSync(path4).toString("base64");figures.push({name,file,kind:"image",markup:`<img src="data:${mime};base64,${data}" alt="${name}">`});continue}let raw=readFileSync(path4,"utf8"),editable=file.toLowerCase().endsWith(".drawio.svg");editable&&!extractMxfile(raw)&&errors.push(`${file}: .drawio.svg doubles as the editable source, so it requires a copy of the mxfile (content=) (save it as .drawio.svg via File > Save as in draw.io)`);let parsed2=file.toLowerCase().endsWith(".svg")?parseSvg(file,editable||isDrawioSvg(raw)?normalizeDrawioSvg(name,raw).markup:raw,errors):parseHtml(file,raw,errors);/var\(--doc-[a-z0-9-]+\)/.test(parsed2.markup)&&errors.push(`${file}: contains var(--doc-*) without a fallback (use the var(--doc-x, #hex) form)`);for(let km of parsed2.markup.matchAll(/@keyframes\s+([A-Za-z0-9_-]+)\s*\{/g)){let kname=km[1]??"",depth=1,i2=(km.index??0)+km[0].length;for(;i2<parsed2.markup.length&&depth>0;){let ch=parsed2.markup[i2];depth+=ch==="{"?1:ch==="}"?-1:0,i2+=1}let body=parsed2.markup.slice((km.index??0)+km[0].length,i2).replace(/\s+/g,""),key=`${kname}`,owner=keyframeOwner.get(key);owner&&owner.file!==file&&owner.body!==body&&errors.push(`${file}: @keyframes "${kname}" conflicts with a different definition in ${owner.file}`),keyframeOwner.set(key,{file,body})}figures.push({name,file,...parsed2})}return{figures,errors}};init_browser_globals();var tableBlock=t3=>{let[head,...rows]=t3.children;return{type:"table",headers:(head?.children??[]).map(c2=>inlineToText(c2.children)),rows:rows.map(r2=>r2.children.map(c2=>inlineToText(c2.children)))}},toBlocks=(root4,raw,settings,file)=>{let toc=[],lines=[],seen=new Map,unslugged=0,inline=inlineSegmenter(),convert2=(nodes,topLevel=!1)=>{let blocks=[];for(let n2 of nodes){let add2=b2=>{blocks.push(b2),topLevel&&lines.push(n2.position?.start.line??1)};switch(n2.type){case"yaml":break;case"heading":{let h2=n2,depth=h2.depth,text5=inlineToText(h2.children),label2=inline(text5).map(part=>part.text).join(""),base2=slugify(label2)||`section-${++unslugged}`,dup=seen.get(base2)??0;seen.set(base2,dup+1);let slug=dup===0?base2:`${base2}-${dup}`;toc.push({depth,text:label2,slug}),add2({type:"h",level:depth,text:text5,slug});break}case"blockquote":add2({type:"quote",blocks:convert2(n2.children)});break;case"paragraph":{let images=standaloneImages(n2);images.length||add2({type:"p",text:inlineToText(n2.children)});for(let image2 of images)try{let{file:file2,range,tableMode,kind}=parseFileEmbed(image2.url,settings);if(kind==="external"){add2({type:"external",url:file2,...image2.alt?{alt:image2.alt}:{}}),topLevel&&(lines[lines.length-1]=image2.position?.start.line??1);continue}if(kind!=="textfile"){add2({type:"figureRef",name:figureName(file2),alt:image2.alt??""}),topLevel&&(lines[lines.length-1]=image2.position?.start.line??1);continue}add2({type:"code",filename:file2,...range!==void 0?{range}:{},...tableMode?{tableMode}:{},...image2.alt?{alt:image2.alt}:{},lang:(extname2(textfileName(file2)).slice(1)||basename3(textfileName(file2))).toLowerCase(),lines:[]}),topLevel&&(lines[lines.length-1]=image2.position?.start.line??1)}catch{}break}case"list":add2({type:"list",items:listItems(n2,convert2),...n2.ordered?{ordered:!0}:{}});break;case"code":{let parsed2=parseContentCode(n2,raw,file);if(parsed2){for(let block of parsed2.blocks)add2(block);break}add2({type:"code",lines:n2.value.split(`
|
|
471
471
|
`),...n2.lang!=null?{lang:n2.lang}:{}});break}case"table":add2(tableBlock(n2));break;default:break}}return blocks};return{blocks:convert2(root4.children,!0),toc,lines}};init_browser_globals();var ICONS_DIR="icons",ownsDocIcon=(id,manifest2)=>{let file=docIconFile(id,manifest2.files);return!Object.hasOwn(manifest2.files?.icons??{},id)&&![manifest2.icon,...Object.values(manifest2.themeIcons??{}),...Object.values(manifest2.files?.icons??{})].includes(file)},ROOT_SVG_RE=/<svg\b[^>]*>/i,num2=v2=>{let n2=v2==null?Number.NaN:Number.parseFloat(v2);return Number.isFinite(n2)&&n2>0?n2:void 0},squareSvg=svg=>{let root4=ROOT_SVG_RE.exec(svg)?.[0];if(!root4)return;let attr=name=>new RegExp(`\\s${name}\\s*=\\s*["']([^"']*)["']`,"i").exec(root4)?.[1],vb=attr("viewBox")?.trim().split(/[\s,]+/).map(Number),[x2,y2,w2,h2]=vb&&vb.length===4&&vb.every(Number.isFinite)?vb:[0,0,num2(attr("width")),num2(attr("height"))];if(x2==null||y2==null||w2==null||h2==null||w2<=0||h2<=0)return;let side=Math.max(w2,h2);x2-=(side-w2)/2,y2-=(side-h2)/2;let round=n2=>Math.round(n2*1e3)/1e3,xmlns=/\sxmlns\s*=/.test(root4)?"":' xmlns="http://www.w3.org/2000/svg"',next=root4.replace(/\s(viewBox|width|height|preserveAspectRatio)\s*=\s*(["'])[^"']*\2/gi,"").replace(/^<svg\b/i,`<svg${xmlns} viewBox="${[x2,y2,side,side].map(round).join(" ")}" preserveAspectRatio="xMidYMid meet"`);return svg.replace(root4,next)},loadIcons=(root4,docIds,siteIconFile,layout,siteIcons=[])=>{let icons=new Map,errors=[],files=[];try{let dir=textfilePath(root4,ICONS_DIR);files=existsSync(dir)?readdirSync(dir):[]}catch(error){errors.push(`${ICONS_DIR}: ${error}`)}let ignored=ignoredFiles(root4,files.map(file=>`${ICONS_DIR}/${file}`));for(let f2 of files){if(ignored.has(`${ICONS_DIR}/${f2}`)||f2.startsWith("."))continue;let id=f2.endsWith(".svg")?f2.slice(0,-4):"";if(!docIds.has(id)){if(siteIconFile?.replace(/^\.\//,"")===`${ICONS_DIR}/${f2}`||siteIcons.includes(`${ICONS_DIR}/${f2}`)||Object.values(layout?.icons??{}).includes(`${ICONS_DIR}/${f2}`))continue;errors.push(`${ICONS_DIR}/${f2}: no matching doc (content/${id||f2}.md)`);continue}try{let svg=readTextfile(root4,`${ICONS_DIR}/${f2}`);if(!ROOT_SVG_RE.test(svg))throw new Error("not an svg");icons.set(id,svg)}catch(error){errors.push(`${ICONS_DIR}/${f2}: ${error instanceof Error?error.message:error}`)}}for(let id of docIds)if(layout?.icons?.[id])try{let file=textfilePath(root4,docIconFile(id,layout));if(assertNotIgnored(root4,docIconFile(id,layout)),!existsSync(file))continue;let svg=readFileSync(file,"utf8");if(!ROOT_SVG_RE.test(svg))throw new Error("not an svg");icons.set(id,svg)}catch(error){errors.push(`${docIconFile(id,layout)}: ${error}`)}return{icons,errors}};init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();init_browser_globals();function getLineColFromPtr(string4,ptr){let lines=string4.slice(0,ptr).split(/\r?\n/);return[lines.length,lines.pop().length+1]}function makeCodeBlock(string4,line2,column){let lines=string4.split(/\r?\n/),codeblock="",numberLen=(Math.log10(line2+1)|0)+1;for(let i2=line2-1;i2<=line2+1;i2++){let l2=lines[i2-1];l2&&(codeblock+=i2.toString().padEnd(numberLen," "),codeblock+=": ",codeblock+=l2,codeblock+=`
|