@batijs/core 0.0.544 → 0.0.547

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/dist/index.d.ts CHANGED
@@ -93,6 +93,7 @@ declare class MarkdownV2 implements StringTransformer {
93
93
  interface PackageJsonDeps {
94
94
  dependencies?: Record<string, string>;
95
95
  devDependencies?: Record<string, string>;
96
+ peerDependencies?: Record<string, string>;
96
97
  }
97
98
  interface PackageJsonScripts {
98
99
  scripts?: Record<string, string>;
package/dist/index.js CHANGED
@@ -1135,7 +1135,7 @@ ${t}
1135
1135
  Old \`scripts.${t}\`: ${zct(e)}
1136
1136
  New \`scripts.${t}\`: ${zct(r)}
1137
1137
  You can check https://batijs.dev for more details.
1138
- `))}var HIe=class t{static previousScripts={};static forcedDependencies=new Set;static dependenciesScriptsRelation=new Map;pendingAddedDependencies;pendingReplacedScripts;packageJson;scopedPackageJson;constructor(e,r){this.packageJson=structuredClone(e),this.scopedPackageJson=r,this.pendingAddedDependencies=[],this.pendingReplacedScripts=[]}setScript(e,r,i=!0){if(!i)return this;let a=t.previousScripts[e]??{precedence:-1/0};return r.precedence>a.precedence?(a.warnIfReplaced&&a.value&&cir(e,a.value,r.value),this.packageJson.scripts??={},this.packageJson.scripts[e]=r.value,t.previousScripts[e]=Object.assign({precedence:-1/0},r),a.value&&this.pendingReplacedScripts.push(e)):r.warnIfReplaced&&a.value&&cir(e,r.value,a.value),this}removeScript(e,r=!0){return r?(t.previousScripts[e]={precedence:-1/0},this.pendingReplacedScripts.push(e),delete this.packageJson.scripts[e],this):this}addDependencies(e,r,i){return typeof r=="boolean"?(i=r,r=[]):typeof i!="boolean"&&(i=!0,r??=[]),i?(this._addDependencies("dependencies",e),this._onlyUsedBy(e,r),this):this}addDevDependencies(e,r,i){return typeof r=="boolean"?(i=r,r=[]):typeof i!="boolean"&&(i=!0,r??=[]),i?(this._addDependencies("devDependencies",e),this._onlyUsedBy(e,r),this):this}finalize(){for(let e of this.pendingAddedDependencies)t.dependenciesScriptsRelation.has(e)||t.forcedDependencies.add(e);for(let e of this.pendingReplacedScripts)if(!t.forcedDependencies.has(e))for(let[r,i]of t.dependenciesScriptsRelation.entries())i.has(e)&&(i.delete(e),i.size===0&&(this.removeDependency(r),t.dependenciesScriptsRelation.delete(r)));return JSON.stringify(this.packageJson,void 0,2)}static clear(){t.previousScripts={},t.forcedDependencies=new Set,t.dependenciesScriptsRelation=new Map}_onlyUsedBy(e,r=[]){for(let i of e){t.dependenciesScriptsRelation.has(i)||t.dependenciesScriptsRelation.set(i,new Set);for(let a of r)t.dependenciesScriptsRelation.get(i).add(a)}}_addDependencies(e,r){let i=e==="devDependencies"?"dependencies":"devDependencies";this.packageJson[e]??={};let a=new Map(uni(this.scopedPackageJson));for(let[l,u]of pni(a,r)){let f=this.packageJson[i]??{};l in f||(this.packageJson[e][l]=u,this.pendingAddedDependencies.push(l))}}removeDependency(e){return this.packageJson.devDependencies?.[e]&&delete this.packageJson.devDependencies[e],this.packageJson.dependencies?.[e]&&delete this.packageJson.dependencies[e],this.packageJson}};async function PEs({readfile:t}){let e=await t?.();return tir(e??"")}async function kEs({readfile:t,source:e,target:r}){let i=await t?.();return Ehe(typeof i=="string",`Unable to load previous JSON module ("${e}" -> "${r}")`),JSON.parse(i)}async function NEs({readfile:t,source:e,target:r},i){let a=await t?.();return Ehe(typeof a=="string",`Unable to load previous JSON module ("${e}" -> "${r}")`),new HIe(JSON.parse(a),i)}async function IEs({readfile:t,source:e,target:r}){let i=await t?.();return Ehe(typeof i=="string",`Unable to load previous module ("${e}" -> "${r}")`),Wme(i)}async function OEs(t,e){let r=dni(e.url),i=fni(r);return ANe(_ni(i,t))}async function FEs({readfile:t,source:e,target:r},i){let a=await t?.();return Ehe(typeof a=="string"||i?.fallbackEmpty,`Unable to load previous YAML module ("${e}" -> "${r}")`),(0,lir.parseDocument)(a??"",i)}function uir(t,e){if(typeof e=="object"&&e!==null)for(let r in e){let i=t[r],a=e[r];i!==a&&(typeof i=="object"&&i!==null&&typeof a=="object"&&a!==null?uir(i,a):t[r]=a)}}function mni(t){return pir(t.exports.default)}function hni(t){if(t.exports.default.$type!=="identifier")throw new NT(`Not supported: Cannot modify this kind of default export (${t.exports.default.$type})`);let e=t.exports.default.$name;for(let r of t.$ast.body)if(r.type==="VariableDeclaration"){for(let i of r.declarations)if(i.id.type==="Identifier"&&i.id.name===e&&i.init){let a=aR(i.init.type==="TSSatisfiesExpression"?i.init.expression:i.init).code;return{declaration:i,config:pir(CNe(a))}}}throw new NT("Couldn't find config declaration")}function pir(t){return t.$type==="function-call"?t.$args[0]:t}function gni(t,e){let r=mni(t);return r.$type==="identifier"?yni(t,e):fir(e,r),t.imports.$prepend({from:e.from,local:e.constructor,imported:e.imported||"default"}),!0}function yni(t,e){let{config:r,declaration:i}=hni(t);fir(e,r),i.init&&(i.init.type==="ObjectExpression"?i.init=aR(r).code:i.init.type==="CallExpression"&&i.init.callee.type==="Identifier"?i.init=aR(EK.functionCall(i.init.callee.name,r)).code:i.init.type==="TSSatisfiesExpression"&&(i.init.expression.type==="ObjectExpression"&&(i.init.expression=aR(r).code),i.init.expression.type==="CallExpression"&&i.init.expression.callee.type==="Identifier"&&(i.init.expression=aR(EK.functionCall(i.init.expression.callee.name,r)).code)))}function fir(t,e){let r=t.index??e.plugins?.length??0;e.plugins||=[],e.plugins.splice(r,0,t.options?EK.functionCall(t.constructor,t.options):EK.functionCall(t.constructor))}var Mkr=w_(Gie(),1);import Lkr from"path";function uye(t,e){let r=t.replace(/[\\/]+/g,"/"),i=e.replace(/[\\/]+/g,"/"),a=Lkr.posix.relative(Lkr.dirname(r),i);return a.startsWith("../")?a:`./${a}`}function c6e(t){return t.match(/^@batijs\/[^/]+\/(.+)$/)}function l6e(t,e){let r=c6e(e.source.value),i=Hie(t);if(r){let a=uye(t.filename,r[1]);i?.addImport(a),t.report({node:e,message:"bati/module-imports",*fix(l){yield l.replaceTextRange([e.source.range[0]+1,e.source.range[1]-1],a)}})}else(e.source.value.startsWith("./")||e.source.value.startsWith("../"))&&i?.addImport(e.source.value)}function owi(){return new Mkr.Linter({configType:"flat"})}var Bmt=class{flags;imports;filename;constructor(e){this.filename=e,this.flags=new Set,this.imports=new Set}addImport(e){let r=c6e(e);r?this.imports.add(uye(this.filename,r[1])):this.imports.add(e)}deleteImport(e){let r=c6e(e);r?this.imports.delete(uye(this.filename,r[1])):this.imports.delete(e)}addFlag(e){this.flags.add(e)}};function Hie(t){return t.settings?.extractor}function Rkr(t,e,r){let i=owi(),a=new Bmt(r),l=i.verifyAndFix(t.replaceAll("eslint-disable-next-line","__BATI_EDNL"),[...e,{settings:{extractor:a}}],{filename:r});if(l.messages.length>0)throw new Error(`[eslint] Error while parsing or fixing file ${r}:
1138
+ `))}var HIe=class t{static previousScripts={};static forcedDependencies=new Set;static dependenciesScriptsRelation=new Map;pendingAddedDependencies;pendingReplacedScripts;packageJson;scopedPackageJson;constructor(e,r){this.packageJson=structuredClone(e),this.scopedPackageJson=r,this.pendingAddedDependencies=[],this.pendingReplacedScripts=[]}setScript(e,r,i=!0){if(!i)return this;let a=t.previousScripts[e]??{precedence:-1/0};return r.precedence>a.precedence?(a.warnIfReplaced&&a.value&&cir(e,a.value,r.value),this.packageJson.scripts??={},this.packageJson.scripts[e]=r.value,t.previousScripts[e]=Object.assign({precedence:-1/0},r),a.value&&this.pendingReplacedScripts.push(e)):r.warnIfReplaced&&a.value&&cir(e,r.value,a.value),this}removeScript(e,r=!0){return r?(t.previousScripts[e]={precedence:-1/0},this.pendingReplacedScripts.push(e),delete this.packageJson.scripts[e],this):this}addDependencies(e,r,i){return typeof r=="boolean"?(i=r,r=[]):typeof i!="boolean"&&(i=!0,r??=[]),i?(this._addDependencies("dependencies",e),this._onlyUsedBy(e,r),this):this}addDevDependencies(e,r,i){return typeof r=="boolean"?(i=r,r=[]):typeof i!="boolean"&&(i=!0,r??=[]),i?(this._addDependencies("devDependencies",e),this._onlyUsedBy(e,r),this):this}finalize(){for(let e of this.pendingAddedDependencies)t.dependenciesScriptsRelation.has(e)||t.forcedDependencies.add(e);for(let e of this.pendingReplacedScripts)if(!t.forcedDependencies.has(e))for(let[r,i]of t.dependenciesScriptsRelation.entries())i.has(e)&&(i.delete(e),i.size===0&&(this.removeDependency(r),t.dependenciesScriptsRelation.delete(r)));return this.packageJson.dependencies&&(this.packageJson.dependencies=Object.fromEntries(Object.entries(this.packageJson.dependencies).sort(([e],[r])=>e.localeCompare(r)))),this.packageJson.devDependencies&&(this.packageJson.devDependencies=Object.fromEntries(Object.entries(this.packageJson.devDependencies).sort(([e],[r])=>e.localeCompare(r)))),this.packageJson.peerDependencies&&(this.packageJson.peerDependencies=Object.fromEntries(Object.entries(this.packageJson.peerDependencies).sort(([e],[r])=>e.localeCompare(r)))),JSON.stringify(this.packageJson,void 0,2)}static clear(){t.previousScripts={},t.forcedDependencies=new Set,t.dependenciesScriptsRelation=new Map}_onlyUsedBy(e,r=[]){for(let i of e){t.dependenciesScriptsRelation.has(i)||t.dependenciesScriptsRelation.set(i,new Set);for(let a of r)t.dependenciesScriptsRelation.get(i).add(a)}}_addDependencies(e,r){let i=e==="devDependencies"?"dependencies":"devDependencies";this.packageJson[e]??={};let a=new Map(uni(this.scopedPackageJson));for(let[l,u]of pni(a,r)){let f=this.packageJson[i]??{};l in f||(this.packageJson[e][l]=u,this.pendingAddedDependencies.push(l))}}removeDependency(e){return this.packageJson.devDependencies?.[e]&&delete this.packageJson.devDependencies[e],this.packageJson.dependencies?.[e]&&delete this.packageJson.dependencies[e],this.packageJson}};async function PEs({readfile:t}){let e=await t?.();return tir(e??"")}async function kEs({readfile:t,source:e,target:r}){let i=await t?.();return Ehe(typeof i=="string",`Unable to load previous JSON module ("${e}" -> "${r}")`),JSON.parse(i)}async function NEs({readfile:t,source:e,target:r},i){let a=await t?.();return Ehe(typeof a=="string",`Unable to load previous JSON module ("${e}" -> "${r}")`),new HIe(JSON.parse(a),i)}async function IEs({readfile:t,source:e,target:r}){let i=await t?.();return Ehe(typeof i=="string",`Unable to load previous module ("${e}" -> "${r}")`),Wme(i)}async function OEs(t,e){let r=dni(e.url),i=fni(r);return ANe(_ni(i,t))}async function FEs({readfile:t,source:e,target:r},i){let a=await t?.();return Ehe(typeof a=="string"||i?.fallbackEmpty,`Unable to load previous YAML module ("${e}" -> "${r}")`),(0,lir.parseDocument)(a??"",i)}function uir(t,e){if(typeof e=="object"&&e!==null)for(let r in e){let i=t[r],a=e[r];i!==a&&(typeof i=="object"&&i!==null&&typeof a=="object"&&a!==null?uir(i,a):t[r]=a)}}function mni(t){return pir(t.exports.default)}function hni(t){if(t.exports.default.$type!=="identifier")throw new NT(`Not supported: Cannot modify this kind of default export (${t.exports.default.$type})`);let e=t.exports.default.$name;for(let r of t.$ast.body)if(r.type==="VariableDeclaration"){for(let i of r.declarations)if(i.id.type==="Identifier"&&i.id.name===e&&i.init){let a=aR(i.init.type==="TSSatisfiesExpression"?i.init.expression:i.init).code;return{declaration:i,config:pir(CNe(a))}}}throw new NT("Couldn't find config declaration")}function pir(t){return t.$type==="function-call"?t.$args[0]:t}function gni(t,e){let r=mni(t);return r.$type==="identifier"?yni(t,e):fir(e,r),t.imports.$prepend({from:e.from,local:e.constructor,imported:e.imported||"default"}),!0}function yni(t,e){let{config:r,declaration:i}=hni(t);fir(e,r),i.init&&(i.init.type==="ObjectExpression"?i.init=aR(r).code:i.init.type==="CallExpression"&&i.init.callee.type==="Identifier"?i.init=aR(EK.functionCall(i.init.callee.name,r)).code:i.init.type==="TSSatisfiesExpression"&&(i.init.expression.type==="ObjectExpression"&&(i.init.expression=aR(r).code),i.init.expression.type==="CallExpression"&&i.init.expression.callee.type==="Identifier"&&(i.init.expression=aR(EK.functionCall(i.init.expression.callee.name,r)).code)))}function fir(t,e){let r=t.index??e.plugins?.length??0;e.plugins||=[],e.plugins.splice(r,0,t.options?EK.functionCall(t.constructor,t.options):EK.functionCall(t.constructor))}var Mkr=w_(Gie(),1);import Lkr from"path";function uye(t,e){let r=t.replace(/[\\/]+/g,"/"),i=e.replace(/[\\/]+/g,"/"),a=Lkr.posix.relative(Lkr.dirname(r),i);return a.startsWith("../")?a:`./${a}`}function c6e(t){return t.match(/^@batijs\/[^/]+\/(.+)$/)}function l6e(t,e){let r=c6e(e.source.value),i=Hie(t);if(r){let a=uye(t.filename,r[1]);i?.addImport(a),t.report({node:e,message:"bati/module-imports",*fix(l){yield l.replaceTextRange([e.source.range[0]+1,e.source.range[1]-1],a)}})}else(e.source.value.startsWith("./")||e.source.value.startsWith("../"))&&i?.addImport(e.source.value)}function owi(){return new Mkr.Linter({configType:"flat"})}var Bmt=class{flags;imports;filename;constructor(e){this.filename=e,this.flags=new Set,this.imports=new Set}addImport(e){let r=c6e(e);r?this.imports.add(uye(this.filename,r[1])):this.imports.add(e)}deleteImport(e){let r=c6e(e);r?this.imports.delete(uye(this.filename,r[1])):this.imports.delete(e)}addFlag(e){this.flags.add(e)}};function Hie(t){return t.settings?.extractor}function Rkr(t,e,r){let i=owi(),a=new Bmt(r),l=i.verifyAndFix(t.replaceAll("eslint-disable-next-line","__BATI_EDNL"),[...e,{settings:{extractor:a}}],{filename:r});if(l.messages.length>0)throw new Error(`[eslint] Error while parsing or fixing file ${r}:
1139
1139
  ${l.messages.map(u=>`${r}:${u.line}:${u.column} => ${u.message}`).join(`
1140
1140
  `)}`);return{code:l.output.replaceAll("__BATI_EDNL","eslint-disable-next-line"),context:a}}var rRr=w_(W8e(),1);var n5r=w_(ns(),1),l5r=w_(ns(),1),n5e=w_(ns(),1),f5r=w_(ns(),1),d5r=w_(ns(),1),i5e=w_(ns(),1),g5r=w_(ns(),1),b5r=w_(ns(),1),s5e=w_(ns(),1),a5e=w_(ns(),1),S5r=w_(zMr(),1),x5r=w_(ns(),1),A5r=w_(ns(),1),w5r=w_(ns(),1),k5r=w_(ns(),1),I5r=w_(ns(),1),o5e=w_(ns(),1),L5r=w_(ns(),1),c5e=w_(ns(),1),R5r=w_(T3e(),1),B5r=w_(ns(),1),l5e=w_(ns(),1),V5r=w_(WMr(),1),z5r=w_(KMr(),1);var t8r=w_(e8r(),1);function r8r(t,e){let r=null;if(!t||typeof t!="string")return r;let i=(0,t8r.default)(t),a=typeof e=="function";return i.forEach(l=>{if(l.type!=="declaration")return;let{property:u,value:f}=l;a?e(u,f,l):f&&(r=r||{},r[u]=f)}),r}var W5r=w_(ns(),1);var t5r=Object.getOwnPropertyNames;var D0=(t,e)=>function(){return t&&(e=(0,t[t5r(t)[0]])(t=0)),e},r5r=(t,e)=>function(){return e||(0,t[t5r(t)[0]])((e={exports:{}}).exports,e),e.exports};function bA(t){return typeof t.getSourceCode=="function"?t.getSourceCode():t.sourceCode}function f0e(t,e){let r=bA(t);return typeof r.getScope=="function"?r.getScope(e):typeof t.getScope=="function"?t.getScope():t.sourceCode.getScope(e)}function dL(t,e){return n5r.ASTUtils.findVariable(f0e(t,e),e)}function x1t(t,e,r){typeof t.markVariableAsUsed=="function"?t.markVariableAsUsed(e):bA(t).markVariableAsUsed(e,r)}var ON=D0({"src/compat.ts"(){"use strict"}});function C1t(t,e){return t.parent?L1t(t.parent,e):null}function _0e(t,e){if(t.type==="Identifier"){let r=dL(e,t);if(!r)return t;let i=r.defs[0];switch(i?.type){case"FunctionName":case"ClassName":case"ImportBinding":return i.node;case"Variable":if((i.node.parent.kind==="const"||r.references.every(a=>a.init||a.isReadOnly()))&&i.node.id.type==="Identifier"&&i.node.init)return _0e(i.node.init,e)}}return t}function O1t(t,e=!1){if(t.type==="TSAsExpression"||t.type==="TSNonNullExpression"||t.type==="TSSatisfiesExpression"){let r=e?t.parent:t.expression;if(r)return O1t(r,e)}return t}function CWi(t,e,r){let i=L1t(t,a=>a===e||r(a));return i===e&&!r(t)?null:i}function i5r(t,e,r,i){let a=i.join(", "),u=r.specifiers.slice().reverse().find(_=>_.type==="ImportSpecifier");if(u)return t.insertTextAfter(u,`, ${a}`);let f=r.specifiers.find(_=>_.type==="ImportDefaultSpecifier"||_.type==="ImportNamespaceSpecifier");if(f)return t.insertTextAfter(f,`, { ${a} }`);if(r.specifiers.length===0){let[_,g]=e.getFirstTokens(r,{count:2});return g?.value==="{"?t.insertTextAfter(g,` ${a} `):_?t.insertTextAfter(_,` { ${a} } from`):null}return null}function s5r(t,e,r,i,a,l=!1){let u=i.join(", "),f=e.ast,_=a??f.body.find(g=>g.type==="ImportDeclaration");return _?t.insertTextBeforeRange((c5r(_,e)??_).range,`import ${l?"type ":""}{ ${u} } from "${r}";
1141
1141
  `):t.insertTextBeforeRange([0,0],`import ${l?"type ":""}{ ${u} } from "${r}";
@@ -1157,7 +1157,7 @@ ${R} return (`),yield _.insertTextAfter(z,`);
1157
1157
 
1158
1158
  `+a.message+`
1159
1159
  `+Array(a.message.length+1).join("=")+`
1160
- `+IWr(t,r)):a}}var VEt=da("fs"),REt=da("path"),Nps=/^\uFEFF/;function jEt(t,e,r){var i=REt.resolve(r?e:REt.dirname(e),t),a=REt.extname(t);return a||(i+=".sqrl"),i}function Ips(t,e){var r,i,a=e.views,l=/^[A-Za-z]+:\\|^\//.exec(t);if(l&&l.length)r=jEt(t.replace(/^\/*/,""),e.root||"/",!0);else if(e.filename&&(i=jEt(t,e.filename),VEt.existsSync(i)&&(r=i)),r||Array.isArray(a)&&a.some(function(u){return i=jEt(t,u,!0),VEt.existsSync(i)})&&(r=i),!r)throw Zv('Could not find the include file "'+t+'"');return r}function jWr(t){return VEt.readFileSync(t).toString().replace(Nps,"")}function Ops(t,e){var r=m7e(e),i=jWr(t);try{var a=YEt(i,r);return r.storage.templates.define(r.filename,a),a}catch{throw Zv("Loading file: "+t+" failed")}}function Fps(t){var e=t.filename;if(t.cache){var r=t.storage.templates.get(e);return r||Ops(e,t)}return YEt(jWr(e),t)}function BWr(t,e){var r=m7e({filename:Ips(t,e)},e);return Fps(r)}function Lps(t,e,r){if(e&&e.length>0)throw Zv("Helper 'includeFile' doesn't accept blocks");return BWr(t.params[0],r)(t.params[1],r)}function Mps(t,e,r){var i=t.params[1]||{};i.content=t.exec();for(var a=0;a<e.length;a++){var l=e[a];i[l.name]=l.exec()}return BWr(t.params[0],r)(i,r)}function BEt(t,e){var r;return e.cache&&e.name&&e.storage.templates.get(e.name)?e.storage.templates.get(e.name):(typeof t=="function"?r=t:r=YEt(t,e),e.cache&&e.name&&e.storage.templates.define(e.name,r),r)}function UWr(t,e,r,i){var a=m7e(r||{});if(a.async){var l;if(i)try{BEt(t,a)(e,a,i)}catch(u){return i(u)}else{if(typeof kWr=="function")return new kWr(function(u,f){try{l=BEt(t,a)(e,a),u(l)}catch(_){f(_)}});throw Zv("Please provide a callback function, this env doesn't support Promises")}}else return BEt(t,a)(e,a)}zEt.define("includeFile",Lps);zEt.define("extendsFile",Mps);var WEt=["/*{","}*/"];function qWr(t,e){return UWr(t,e,{tags:WEt})}function Rps(t,e){return{eslint:(t.includes("BATI.has")||t.includes("BATI_TEST")||t.includes("/*# BATI ")||t.includes("@batijs/")||e.endsWith(".ts")||e.endsWith(".tsx"))&&!e.endsWith(".css"),squirelly:t.includes(WEt[0])}}var jps=/\/\/\s*eslint(?:-disable|-enable|-disable-next-line|-disable-line)?[^\n]*/gim,Bps=/\/\/\s*biome-ignore[^\n]*/gim,Ups=/\/\*+\s*eslint(?:-disable|-enable|-disable-next-line|-disable-line)?[^\n*]*\*+\//gim,qps=/\/\*+\s*biome-ignore[^\n*]*\*+\//gim,VWr=new RegExp(`${jps.source}|${Ups.source}`,"gim"),zWr=new RegExp(`${Bps.source}|${qps.source}`,"gim");async function Vps(t,e,r){let{eslint:i,squirelly:a}=Rps(t,r.filepath),l=t,u,f=!1;if(a&&(l=qWr(l,e),f=!0),i){let _=PWr(l,r.filepath,e);l=_.code,u=_.context,f=!0}return!e.BATI.has("eslint")&&VWr.test(l)&&(l=l.replace(VWr,""),f=!0),!e.BATI.has("biome")&&zWr.test(l)&&(l=l.replace(zWr,""),f=!0),{code:f?await lst(l,r):l,context:u}}import{randomBytes as cjs}from"crypto";var JEt={name:"@batijs/core",version:"0.0.544",description:"",type:"module",types:"./dist/index.d.ts",scripts:{"check-types":"tsc --noEmit",vue:"tsx src/parse/linters/vue.ts",test:"vitest run","test:ci":"vitest run",build:"tsup"},keywords:[],author:"Jo\xEBl Charles <joel.charles91@gmail.com>",repository:"https://github.com/vikejs/bati",license:"MIT",devDependencies:{"@batijs/features":"workspace:*","@types/eslint":"^9.6.1","@types/estree":"^1.0.8","@types/node":"^20.19.25","@types/which":"^3.0.4","@typescript-eslint/parser":"^8.48.1","@typescript-eslint/utils":"^8.48.1","attributes-parser":"^2.2.3",colorette:"^2.0.20",esbuild:"^0.27.1",eslint:"^9.39.1","eslint-plugin-solid":"^0.14.5","eslint-rule-composer":"^0.3.0",espree:"^11.0.0",magicast:"^0.5.1","mdast-builder":"^1.1.1","mdast-util-from-markdown":"^2.0.2","mdast-util-to-markdown":"^2.1.2","mdast-util-to-string":"^4.0.0","mdast-util-toc":"^7.1.0",prettier:"^3.7.4",squirrelly:"^9.1.0",tsup:"^8.5.1",tsx:"^4.21.0",typescript:"^5.9.3","unplugin-purge-polyfills":"^0.1.0",vitest:"^4.0.15","vue-eslint-parser":"^10.2.0",which:"^6.0.0",yaml:"^2.8.2"},exports:{".":"./dist/index.js","./config":"./dist/config.js","./types":{types:"./global.d.ts"}},typesVersions:{"*":{config:["./dist/config.d.ts"],types:["./global.d.ts"]}},files:["dist/"]};function Yps(){return process.env.npm_config_user_agent?Wps(process.env.npm_config_user_agent):{name:"npm",run:"npm run",exec:"npx"}}function Wps(t){let e=t.split(" ")[0],r=e.lastIndexOf("/"),i=e.substring(0,r);i=i==="npminstall"?"cnpm":i;let a;switch(i){case"pnpm":a="pnpm dlx";break;case"yarn":a="yarn dlx";break;case"bun":a="bunx";break;case"cnpm":a="cnpx";break;default:a="npx"}return{name:i,version:e.substring(r+1),run:i==="npm"?"npm run":i,exec:a}}function fjs(){switch(Yps().name){case"pnpm":return"pnpm create vike@latest";case"yarn":return"yarn create vike@latest";case"bun":return"bun create vike@latest";default:return"npm create vike@latest ---"}}function _js(){let t=JEt.version.split("."),e=t[0],r=t[1],i=t.slice(2).join(".");return{version:JEt.version,semver:[e,r,i]}}function mjs(t,e,r,i){t??="",t.endsWith(`
1160
+ `+IWr(t,r)):a}}var VEt=da("fs"),REt=da("path"),Nps=/^\uFEFF/;function jEt(t,e,r){var i=REt.resolve(r?e:REt.dirname(e),t),a=REt.extname(t);return a||(i+=".sqrl"),i}function Ips(t,e){var r,i,a=e.views,l=/^[A-Za-z]+:\\|^\//.exec(t);if(l&&l.length)r=jEt(t.replace(/^\/*/,""),e.root||"/",!0);else if(e.filename&&(i=jEt(t,e.filename),VEt.existsSync(i)&&(r=i)),r||Array.isArray(a)&&a.some(function(u){return i=jEt(t,u,!0),VEt.existsSync(i)})&&(r=i),!r)throw Zv('Could not find the include file "'+t+'"');return r}function jWr(t){return VEt.readFileSync(t).toString().replace(Nps,"")}function Ops(t,e){var r=m7e(e),i=jWr(t);try{var a=YEt(i,r);return r.storage.templates.define(r.filename,a),a}catch{throw Zv("Loading file: "+t+" failed")}}function Fps(t){var e=t.filename;if(t.cache){var r=t.storage.templates.get(e);return r||Ops(e,t)}return YEt(jWr(e),t)}function BWr(t,e){var r=m7e({filename:Ips(t,e)},e);return Fps(r)}function Lps(t,e,r){if(e&&e.length>0)throw Zv("Helper 'includeFile' doesn't accept blocks");return BWr(t.params[0],r)(t.params[1],r)}function Mps(t,e,r){var i=t.params[1]||{};i.content=t.exec();for(var a=0;a<e.length;a++){var l=e[a];i[l.name]=l.exec()}return BWr(t.params[0],r)(i,r)}function BEt(t,e){var r;return e.cache&&e.name&&e.storage.templates.get(e.name)?e.storage.templates.get(e.name):(typeof t=="function"?r=t:r=YEt(t,e),e.cache&&e.name&&e.storage.templates.define(e.name,r),r)}function UWr(t,e,r,i){var a=m7e(r||{});if(a.async){var l;if(i)try{BEt(t,a)(e,a,i)}catch(u){return i(u)}else{if(typeof kWr=="function")return new kWr(function(u,f){try{l=BEt(t,a)(e,a),u(l)}catch(_){f(_)}});throw Zv("Please provide a callback function, this env doesn't support Promises")}}else return BEt(t,a)(e,a)}zEt.define("includeFile",Lps);zEt.define("extendsFile",Mps);var WEt=["/*{","}*/"];function qWr(t,e){return UWr(t,e,{tags:WEt})}function Rps(t,e){return{eslint:(t.includes("BATI.has")||t.includes("BATI_TEST")||t.includes("/*# BATI ")||t.includes("@batijs/")||e.endsWith(".ts")||e.endsWith(".tsx"))&&!e.endsWith(".css"),squirelly:t.includes(WEt[0])}}var jps=/\/\/\s*eslint(?:-disable|-enable|-disable-next-line|-disable-line)?[^\n]*/gim,Bps=/\/\/\s*biome-ignore[^\n]*/gim,Ups=/\/\*+\s*eslint(?:-disable|-enable|-disable-next-line|-disable-line)?[^\n*]*\*+\//gim,qps=/\/\*+\s*biome-ignore[^\n*]*\*+\//gim,VWr=new RegExp(`${jps.source}|${Ups.source}`,"gim"),zWr=new RegExp(`${Bps.source}|${qps.source}`,"gim");async function Vps(t,e,r){let{eslint:i,squirelly:a}=Rps(t,r.filepath),l=t,u,f=!1;if(a&&(l=qWr(l,e),f=!0),i){let _=PWr(l,r.filepath,e);l=_.code,u=_.context,f=!0}return!e.BATI.has("eslint")&&VWr.test(l)&&(l=l.replace(VWr,""),f=!0),!e.BATI.has("biome")&&zWr.test(l)&&(l=l.replace(zWr,""),f=!0),{code:f?await lst(l,r):l,context:u}}import{randomBytes as cjs}from"crypto";var JEt={name:"@batijs/core",version:"0.0.547",description:"",type:"module",types:"./dist/index.d.ts",scripts:{"check-types":"tsc --noEmit",vue:"tsx src/parse/linters/vue.ts",test:"vitest run","test:ci":"vitest run",build:"tsup"},keywords:[],author:"Jo\xEBl Charles <joel.charles91@gmail.com>",repository:"https://github.com/vikejs/bati",license:"MIT",devDependencies:{"@batijs/features":"workspace:*","@types/eslint":"^9.6.1","@types/estree":"^1.0.8","@types/node":"^20.19.25","@types/which":"^3.0.4","@typescript-eslint/parser":"^8.48.1","@typescript-eslint/utils":"^8.48.1","attributes-parser":"^2.2.3",colorette:"^2.0.20",esbuild:"^0.27.1",eslint:"^9.39.1","eslint-plugin-solid":"^0.14.5","eslint-rule-composer":"^0.3.0",espree:"^11.0.0",magicast:"^0.5.1","mdast-builder":"^1.1.1","mdast-util-from-markdown":"^2.0.2","mdast-util-to-markdown":"^2.1.2","mdast-util-to-string":"^4.0.0","mdast-util-toc":"^7.1.0",prettier:"^3.7.4",squirrelly:"^9.1.0",tsup:"^8.5.1",tsx:"^4.21.0",typescript:"^5.9.3","unplugin-purge-polyfills":"^0.1.0",vitest:"^4.0.15","vue-eslint-parser":"^10.2.0",which:"^6.0.0",yaml:"^2.8.2"},exports:{".":"./dist/index.js","./config":"./dist/config.js","./types":{types:"./global.d.ts"}},typesVersions:{"*":{config:["./dist/config.d.ts"],types:["./global.d.ts"]}},files:["dist/"]};function Yps(){return process.env.npm_config_user_agent?Wps(process.env.npm_config_user_agent):{name:"npm",run:"npm run",exec:"npx"}}function Wps(t){let e=t.split(" ")[0],r=e.lastIndexOf("/"),i=e.substring(0,r);i=i==="npminstall"?"cnpm":i;let a;switch(i){case"pnpm":a="pnpm dlx";break;case"yarn":a="yarn dlx";break;case"bun":a="bunx";break;case"cnpm":a="cnpx";break;default:a="npx"}return{name:i,version:e.substring(r+1),run:i==="npm"?"npm run":i,exec:a}}function fjs(){switch(Yps().name){case"pnpm":return"pnpm create vike@latest";case"yarn":return"yarn create vike@latest";case"bun":return"bun create vike@latest";default:return"npm create vike@latest ---"}}function _js(){let t=JEt.version.split("."),e=t[0],r=t[1],i=t.slice(2).join(".");return{version:JEt.version,semver:[e,r,i]}}function mjs(t,e,r,i){t??="",t.endsWith(`
1161
1161
 
1162
1162
  `)||(t.endsWith(`
1163
1163
  `)?t=`${t}
@@ -0,0 +1,22 @@
1
+ import { createRequire as BATI_core_createRequire } from 'module';
2
+ import { fileURLToPath as BATI_fileURLToPath } from "node:url";
3
+ import { dirname as BATI_dirname } from "node:path";
4
+ const require = BATI_core_createRequire(import.meta.url);
5
+
6
+ const __filename = BATI_fileURLToPath(import.meta.url);
7
+ const __dirname = BATI_dirname(__filename);
8
+
9
+ import{a as B,b as Cr,c as Ir,e as kr}from"./chunk-C2T5VISX.js";var Bi=Ir((Or,ji)=>{"use strict";(()=>{var Y={"./node_modules/.pnpm/mlly@1.8.0/node_modules/mlly/dist lazy recursive":function(T){function A(j){return Promise.resolve().then(function(){var bt=new Error("Cannot find module '"+j+"'");throw bt.code="MODULE_NOT_FOUND",bt})}A.keys=()=>[],A.resolve=A,A.id="./node_modules/.pnpm/mlly@1.8.0/node_modules/mlly/dist lazy recursive",T.exports=A}},nt={};function H(T){var A=nt[T];if(A!==void 0)return A.exports;var j=nt[T]={exports:{}};return Y[T](j,j.exports,H),j.exports}H.n=T=>{var A=T&&T.__esModule?()=>T.default:()=>T;return H.d(A,{a:A}),A},H.d=(T,A)=>{for(var j in A)H.o(A,j)&&!H.o(T,j)&&Object.defineProperty(T,j,{enumerable:!0,get:A[j]})},H.o=(T,A)=>Object.prototype.hasOwnProperty.call(T,A);var Se={};(()=>{"use strict";H.d(Se,{default:()=>Mi});let T=B("os");var A=[509,0,227,0,150,4,294,9,1368,2,2,1,6,3,41,2,5,0,166,1,574,3,9,9,7,9,32,4,318,1,80,3,71,10,50,3,123,2,54,14,32,10,3,1,11,3,46,10,8,0,46,9,7,2,37,13,2,9,6,1,45,0,13,2,49,13,9,3,2,11,83,11,7,0,3,0,158,11,6,9,7,3,56,1,2,6,3,1,3,2,10,0,11,1,3,6,4,4,68,8,2,0,3,0,2,3,2,4,2,0,15,1,83,17,10,9,5,0,82,19,13,9,214,6,3,8,28,1,83,16,16,9,82,12,9,9,7,19,58,14,5,9,243,14,166,9,71,5,2,1,3,3,2,0,2,1,13,9,120,6,3,6,4,0,29,9,41,6,2,3,9,0,10,10,47,15,343,9,54,7,2,7,17,9,57,21,2,13,123,5,4,0,2,1,2,6,2,0,9,9,49,4,2,1,2,4,9,9,330,3,10,1,2,0,49,6,4,4,14,10,5350,0,7,14,11465,27,2343,9,87,9,39,4,60,6,26,9,535,9,470,0,2,54,8,3,82,0,12,1,19628,1,4178,9,519,45,3,22,543,4,4,5,9,7,3,6,31,3,149,2,1418,49,513,54,5,49,9,0,15,0,23,4,2,14,1361,6,2,16,3,6,2,1,2,4,101,0,161,6,10,9,357,0,62,13,499,13,245,1,2,9,726,6,110,6,6,9,4759,9,787719,239],j=[0,11,2,25,2,18,2,1,2,14,3,13,35,122,70,52,268,28,4,48,48,31,14,29,6,37,11,29,3,35,5,7,2,4,43,157,19,35,5,35,5,39,9,51,13,10,2,14,2,6,2,1,2,10,2,14,2,6,2,1,4,51,13,310,10,21,11,7,25,5,2,41,2,8,70,5,3,0,2,43,2,1,4,0,3,22,11,22,10,30,66,18,2,1,11,21,11,25,71,55,7,1,65,0,16,3,2,2,2,28,43,28,4,28,36,7,2,27,28,53,11,21,11,18,14,17,111,72,56,50,14,50,14,35,39,27,10,22,251,41,7,1,17,2,60,28,11,0,9,21,43,17,47,20,28,22,13,52,58,1,3,0,14,44,33,24,27,35,30,0,3,0,9,34,4,0,13,47,15,3,22,0,2,0,36,17,2,24,20,1,64,6,2,0,2,3,2,14,2,9,8,46,39,7,3,1,3,21,2,6,2,1,2,4,4,0,19,0,13,4,31,9,2,0,3,0,2,37,2,0,26,0,2,0,45,52,19,3,21,2,31,47,21,1,2,0,185,46,42,3,37,47,21,0,60,42,14,0,72,26,38,6,186,43,117,63,32,7,3,0,3,7,2,1,2,23,16,0,2,0,95,7,3,38,17,0,2,0,29,0,11,39,8,0,22,0,12,45,20,0,19,72,200,32,32,8,2,36,18,0,50,29,113,6,2,1,2,37,22,0,26,5,2,1,2,31,15,0,328,18,16,0,2,12,2,33,125,0,80,921,103,110,18,195,2637,96,16,1071,18,5,26,3994,6,582,6842,29,1763,568,8,30,18,78,18,29,19,47,17,3,32,20,6,18,433,44,212,63,129,74,6,0,67,12,65,1,2,0,29,6135,9,1237,42,9,8936,3,2,6,2,1,2,290,16,0,30,2,3,0,15,3,9,395,2309,106,6,12,4,8,8,9,5991,84,2,70,2,1,3,0,3,1,3,3,2,11,2,0,2,6,2,64,2,3,3,7,2,6,2,27,2,3,2,4,2,0,4,6,2,339,3,24,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,30,2,24,2,7,1845,30,7,5,262,61,147,44,11,6,17,0,322,29,19,43,485,27,229,29,3,0,496,6,2,3,2,1,2,14,2,196,60,67,8,0,1205,3,2,26,2,1,2,0,3,0,2,9,2,3,2,0,2,0,7,0,5,0,2,0,2,0,2,2,2,1,2,0,3,0,2,0,2,0,2,0,2,0,2,1,2,0,3,3,2,6,2,3,2,3,2,0,2,9,2,16,6,2,2,4,2,16,4421,42719,33,4153,7,221,3,5761,15,7472,16,621,2467,541,1507,4938,6,4191],bt="\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C8A\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CD\uA7D0\uA7D1\uA7D3\uA7D5-\uA7DC\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC",Ht={3:"abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile",5:"class enum extends super const export import",6:"enum",strict:"implements interface let package private protected public static yield",strictBind:"eval arguments"},Kt="break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this",qi={5:Kt,"5module":Kt+" export import",6:Kt+" const class extends export import super"},Wi=/^in(stanceof)?$/,Gi=new RegExp("["+bt+"]"),Hi=new RegExp("["+bt+"\u200C\u200D\xB7\u0300-\u036F\u0387\u0483-\u0487\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u0669\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07C0-\u07C9\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0966-\u096F\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09E6-\u09EF\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A66-\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AE6-\u0AEF\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B66-\u0B6F\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0BE6-\u0BEF\u0C00-\u0C04\u0C3C\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CE6-\u0CEF\u0CF3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D66-\u0D6F\u0D81-\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0E50-\u0E59\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0ED0-\u0ED9\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1040-\u1049\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F-\u109D\u135D-\u135F\u1369-\u1371\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u17E0-\u17E9\u180B-\u180D\u180F-\u1819\u18A9\u1920-\u192B\u1930-\u193B\u1946-\u194F\u19D0-\u19DA\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AB0-\u1ABD\u1ABF-\u1ACE\u1B00-\u1B04\u1B34-\u1B44\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BB0-\u1BB9\u1BE6-\u1BF3\u1C24-\u1C37\u1C40-\u1C49\u1C50-\u1C59\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DFF\u200C\u200D\u203F\u2040\u2054\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\u30FB\uA620-\uA629\uA66F\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA82C\uA880\uA881\uA8B4-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F1\uA8FF-\uA909\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9D0-\uA9D9\uA9E5\uA9F0-\uA9F9\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA50-\uAA59\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uABF0-\uABF9\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFF10-\uFF19\uFF3F\uFF65]");function zt(t,e){for(var i=65536,s=0;s<e.length;s+=2){if((i+=e[s])>t)return!1;if((i+=e[s+1])>=t)return!0}return!1}function K(t,e){return t<65?t===36:t<91||(t<97?t===95:t<123||(t<=65535?t>=170&&Gi.test(String.fromCharCode(t)):e!==!1&&zt(t,j)))}function X(t,e){return t<48?t===36:t<58||!(t<65)&&(t<91||(t<97?t===95:t<123||(t<=65535?t>=170&&Hi.test(String.fromCharCode(t)):e!==!1&&(zt(t,j)||zt(t,A)))))}var S=function(t,e){e===void 0&&(e={}),this.label=t,this.keyword=e.keyword,this.beforeExpr=!!e.beforeExpr,this.startsExpr=!!e.startsExpr,this.isLoop=!!e.isLoop,this.isAssign=!!e.isAssign,this.prefix=!!e.prefix,this.postfix=!!e.postfix,this.binop=e.binop||null,this.updateContext=null};function F(t,e){return new S(t,{beforeExpr:!0,binop:e})}var $={beforeExpr:!0},U={startsExpr:!0},Jt={};function b(t,e){return e===void 0&&(e={}),e.keyword=t,Jt[t]=new S(t,e)}var n={num:new S("num",U),regexp:new S("regexp",U),string:new S("string",U),name:new S("name",U),privateId:new S("privateId",U),eof:new S("eof"),bracketL:new S("[",{beforeExpr:!0,startsExpr:!0}),bracketR:new S("]"),braceL:new S("{",{beforeExpr:!0,startsExpr:!0}),braceR:new S("}"),parenL:new S("(",{beforeExpr:!0,startsExpr:!0}),parenR:new S(")"),comma:new S(",",$),semi:new S(";",$),colon:new S(":",$),dot:new S("."),question:new S("?",$),questionDot:new S("?."),arrow:new S("=>",$),template:new S("template"),invalidTemplate:new S("invalidTemplate"),ellipsis:new S("...",$),backQuote:new S("`",U),dollarBraceL:new S("${",{beforeExpr:!0,startsExpr:!0}),eq:new S("=",{beforeExpr:!0,isAssign:!0}),assign:new S("_=",{beforeExpr:!0,isAssign:!0}),incDec:new S("++/--",{prefix:!0,postfix:!0,startsExpr:!0}),prefix:new S("!/~",{beforeExpr:!0,prefix:!0,startsExpr:!0}),logicalOR:F("||",1),logicalAND:F("&&",2),bitwiseOR:F("|",3),bitwiseXOR:F("^",4),bitwiseAND:F("&",5),equality:F("==/!=/===/!==",6),relational:F("</>/<=/>=",7),bitShift:F("<</>>/>>>",8),plusMin:new S("+/-",{beforeExpr:!0,binop:9,prefix:!0,startsExpr:!0}),modulo:F("%",10),star:F("*",10),slash:F("/",10),starstar:new S("**",{beforeExpr:!0}),coalesce:F("??",1),_break:b("break"),_case:b("case",$),_catch:b("catch"),_continue:b("continue"),_debugger:b("debugger"),_default:b("default",$),_do:b("do",{isLoop:!0,beforeExpr:!0}),_else:b("else",$),_finally:b("finally"),_for:b("for",{isLoop:!0}),_function:b("function",U),_if:b("if"),_return:b("return",$),_switch:b("switch"),_throw:b("throw",$),_try:b("try"),_var:b("var"),_const:b("const"),_while:b("while",{isLoop:!0}),_with:b("with"),_new:b("new",{beforeExpr:!0,startsExpr:!0}),_this:b("this",U),_super:b("super",U),_class:b("class",U),_extends:b("extends",$),_export:b("export"),_import:b("import",U),_null:b("null",U),_true:b("true",U),_false:b("false",U),_in:b("in",{beforeExpr:!0,binop:7}),_instanceof:b("instanceof",{beforeExpr:!0,binop:7}),_typeof:b("typeof",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_void:b("void",{beforeExpr:!0,prefix:!0,startsExpr:!0}),_delete:b("delete",{beforeExpr:!0,prefix:!0,startsExpr:!0})},M=/\r\n?|\n|\u2028|\u2029/,Ki=new RegExp(M.source,"g");function ut(t){return t===10||t===13||t===8232||t===8233}function Ce(t,e,i){i===void 0&&(i=t.length);for(var s=e;s<i;s++){var r=t.charCodeAt(s);if(ut(r))return s<i-1&&r===13&&t.charCodeAt(s+1)===10?s+2:s+1}return-1}var Ie=/[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/,L=/(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g,ke=Object.prototype,zi=ke.hasOwnProperty,Ji=ke.toString,ft=Object.hasOwn||function(t,e){return zi.call(t,e)},we=Array.isArray||function(t){return Ji.call(t)==="[object Array]"},Re=Object.create(null);function tt(t){return Re[t]||(Re[t]=new RegExp("^(?:"+t.replace(/ /g,"|")+")$"))}function Q(t){return t<=65535?String.fromCharCode(t):(t-=65536,String.fromCharCode(55296+(t>>10),56320+(1023&t)))}var Yi=/(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/,St=function(t,e){this.line=t,this.column=e};St.prototype.offset=function(t){return new St(this.line,this.column+t)};var Pt=function(t,e,i){this.start=e,this.end=i,t.sourceFile!==null&&(this.source=t.sourceFile)};function Ae(t,e){for(var i=1,s=0;;){var r=Ce(t,s,e);if(r<0)return new St(i,e-s);++i,s=r}}var Yt={ecmaVersion:null,sourceType:"script",onInsertedSemicolon:null,onTrailingComma:null,allowReserved:null,allowReturnOutsideFunction:!1,allowImportExportEverywhere:!1,allowAwaitOutsideFunction:null,allowSuperOutsideMethod:null,allowHashBang:!1,checkPrivateFields:!0,locations:!1,onToken:null,onComment:null,ranges:!1,program:null,sourceFile:null,directSourceFile:null,preserveParens:!1},Te=!1;function Qi(t){var e={};for(var i in Yt)e[i]=t&&ft(t,i)?t[i]:Yt[i];if(e.ecmaVersion==="latest"?e.ecmaVersion=1e8:e.ecmaVersion==null?(!Te&&typeof console=="object"&&console.warn&&(Te=!0,console.warn(`Since Acorn 8.0.0, options.ecmaVersion is required.
10
+ Defaulting to 2020, but this will stop working in the future.`)),e.ecmaVersion=11):e.ecmaVersion>=2015&&(e.ecmaVersion-=2009),e.allowReserved==null&&(e.allowReserved=e.ecmaVersion<5),t&&t.allowHashBang!=null||(e.allowHashBang=e.ecmaVersion>=14),we(e.onToken)){var s=e.onToken;e.onToken=function(r){return s.push(r)}}return we(e.onComment)&&(e.onComment=(function(r,a){return function(o,h,c,l,p,f){var u={type:o?"Block":"Line",value:h,start:c,end:l};r.locations&&(u.loc=new Pt(this,p,f)),r.ranges&&(u.range=[c,l]),a.push(u)}})(e,e.onComment)),e}var Zi=256,Pe=259;function Qt(t,e){return 2|(t?4:0)|(e?8:0)}var N=function(t,e,i){this.options=t=Qi(t),this.sourceFile=t.sourceFile,this.keywords=tt(qi[t.ecmaVersion>=6?6:t.sourceType==="module"?"5module":5]);var s="";t.allowReserved!==!0&&(s=Ht[t.ecmaVersion>=6?6:t.ecmaVersion===5?5:3],t.sourceType==="module"&&(s+=" await")),this.reservedWords=tt(s);var r=(s?s+" ":"")+Ht.strict;this.reservedWordsStrict=tt(r),this.reservedWordsStrictBind=tt(r+" "+Ht.strictBind),this.input=String(e),this.containsEsc=!1,i?(this.pos=i,this.lineStart=this.input.lastIndexOf(`
11
+ `,i-1)+1,this.curLine=this.input.slice(0,this.lineStart).split(M).length):(this.pos=this.lineStart=0,this.curLine=1),this.type=n.eof,this.value=null,this.start=this.end=this.pos,this.startLoc=this.endLoc=this.curPosition(),this.lastTokEndLoc=this.lastTokStartLoc=null,this.lastTokStart=this.lastTokEnd=this.pos,this.context=this.initialContext(),this.exprAllowed=!0,this.inModule=t.sourceType==="module",this.strict=this.inModule||this.strictDirective(this.pos),this.potentialArrowAt=-1,this.potentialArrowInForAwait=!1,this.yieldPos=this.awaitPos=this.awaitIdentPos=0,this.labels=[],this.undefinedExports=Object.create(null),this.pos===0&&t.allowHashBang&&this.input.slice(0,2)==="#!"&&this.skipLineComment(2),this.scopeStack=[],this.enterScope(1),this.regexpState=null,this.privateNameStack=[]},z={inFunction:{configurable:!0},inGenerator:{configurable:!0},inAsync:{configurable:!0},canAwait:{configurable:!0},allowSuper:{configurable:!0},allowDirectSuper:{configurable:!0},treatFunctionsAsVar:{configurable:!0},allowNewDotTarget:{configurable:!0},inClassStaticBlock:{configurable:!0}};N.prototype.parse=function(){var t=this.options.program||this.startNode();return this.nextToken(),this.parseTopLevel(t)},z.inFunction.get=function(){return(2&this.currentVarScope().flags)>0},z.inGenerator.get=function(){return(8&this.currentVarScope().flags)>0},z.inAsync.get=function(){return(4&this.currentVarScope().flags)>0},z.canAwait.get=function(){for(var t=this.scopeStack.length-1;t>=0;t--){var e=this.scopeStack[t].flags;if(768&e)return!1;if(2&e)return(4&e)>0}return this.inModule&&this.options.ecmaVersion>=13||this.options.allowAwaitOutsideFunction},z.allowSuper.get=function(){return(64&this.currentThisScope().flags)>0||this.options.allowSuperOutsideMethod},z.allowDirectSuper.get=function(){return(128&this.currentThisScope().flags)>0},z.treatFunctionsAsVar.get=function(){return this.treatFunctionsAsVarInScope(this.currentScope())},z.allowNewDotTarget.get=function(){for(var t=this.scopeStack.length-1;t>=0;t--){var e=this.scopeStack[t].flags;if(768&e||2&e&&!(16&e))return!0}return!1},z.inClassStaticBlock.get=function(){return(this.currentVarScope().flags&Zi)>0},N.extend=function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];for(var i=this,s=0;s<t.length;s++)i=t[s](i);return i},N.parse=function(t,e){return new this(e,t).parse()},N.parseExpressionAt=function(t,e,i){var s=new this(i,t,e);return s.nextToken(),s.parseExpression()},N.tokenizer=function(t,e){return new this(e,t)},Object.defineProperties(N.prototype,z);var O=N.prototype,Xi=/^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;O.strictDirective=function(t){if(this.options.ecmaVersion<5)return!1;for(;;){L.lastIndex=t,t+=L.exec(this.input)[0].length;var e=Xi.exec(this.input.slice(t));if(!e)return!1;if((e[1]||e[2])==="use strict"){L.lastIndex=t+e[0].length;var i=L.exec(this.input),s=i.index+i[0].length,r=this.input.charAt(s);return r===";"||r==="}"||M.test(i[0])&&!(/[(`.[+\-/*%<>=,?^&]/.test(r)||r==="!"&&this.input.charAt(s+1)==="=")}t+=e[0].length,L.lastIndex=t,t+=L.exec(this.input)[0].length,this.input[t]===";"&&t++}},O.eat=function(t){return this.type===t&&(this.next(),!0)},O.isContextual=function(t){return this.type===n.name&&this.value===t&&!this.containsEsc},O.eatContextual=function(t){return!!this.isContextual(t)&&(this.next(),!0)},O.expectContextual=function(t){this.eatContextual(t)||this.unexpected()},O.canInsertSemicolon=function(){return this.type===n.eof||this.type===n.braceR||M.test(this.input.slice(this.lastTokEnd,this.start))},O.insertSemicolon=function(){if(this.canInsertSemicolon())return this.options.onInsertedSemicolon&&this.options.onInsertedSemicolon(this.lastTokEnd,this.lastTokEndLoc),!0},O.semicolon=function(){this.eat(n.semi)||this.insertSemicolon()||this.unexpected()},O.afterTrailingComma=function(t,e){if(this.type===t)return this.options.onTrailingComma&&this.options.onTrailingComma(this.lastTokStart,this.lastTokStartLoc),e||this.next(),!0},O.expect=function(t){this.eat(t)||this.unexpected()},O.unexpected=function(t){this.raise(t??this.start,"Unexpected token")};var Nt=function(){this.shorthandAssign=this.trailingComma=this.parenthesizedAssign=this.parenthesizedBind=this.doubleProto=-1};O.checkPatternErrors=function(t,e){if(t){t.trailingComma>-1&&this.raiseRecoverable(t.trailingComma,"Comma is not permitted after the rest element");var i=e?t.parenthesizedAssign:t.parenthesizedBind;i>-1&&this.raiseRecoverable(i,e?"Assigning to rvalue":"Parenthesized pattern")}},O.checkExpressionErrors=function(t,e){if(!t)return!1;var i=t.shorthandAssign,s=t.doubleProto;if(!e)return i>=0||s>=0;i>=0&&this.raise(i,"Shorthand property assignments are valid only in destructuring patterns"),s>=0&&this.raiseRecoverable(s,"Redefinition of __proto__ property")},O.checkYieldAwaitInDefaultParams=function(){this.yieldPos&&(!this.awaitPos||this.yieldPos<this.awaitPos)&&this.raise(this.yieldPos,"Yield expression cannot be a default value"),this.awaitPos&&this.raise(this.awaitPos,"Await expression cannot be a default value")},O.isSimpleAssignTarget=function(t){return t.type==="ParenthesizedExpression"?this.isSimpleAssignTarget(t.expression):t.type==="Identifier"||t.type==="MemberExpression"};var m=N.prototype;m.parseTopLevel=function(t){var e=Object.create(null);for(t.body||(t.body=[]);this.type!==n.eof;){var i=this.parseStatement(null,!0,e);t.body.push(i)}if(this.inModule)for(var s=0,r=Object.keys(this.undefinedExports);s<r.length;s+=1){var a=r[s];this.raiseRecoverable(this.undefinedExports[a].start,"Export '"+a+"' is not defined")}return this.adaptDirectivePrologue(t.body),this.next(),t.sourceType=this.options.sourceType,this.finishNode(t,"Program")};var Zt={kind:"loop"},ts={kind:"switch"};m.isLet=function(t){if(this.options.ecmaVersion<6||!this.isContextual("let"))return!1;L.lastIndex=this.pos;var e=L.exec(this.input),i=this.pos+e[0].length,s=this.input.charCodeAt(i);if(s===91||s===92)return!0;if(t)return!1;if(s===123||s>55295&&s<56320)return!0;if(K(s,!0)){for(var r=i+1;X(s=this.input.charCodeAt(r),!0);)++r;if(s===92||s>55295&&s<56320)return!0;var a=this.input.slice(i,r);if(!Wi.test(a))return!0}return!1},m.isAsyncFunction=function(){if(this.options.ecmaVersion<8||!this.isContextual("async"))return!1;L.lastIndex=this.pos;var t,e=L.exec(this.input),i=this.pos+e[0].length;return!(M.test(this.input.slice(this.pos,i))||this.input.slice(i,i+8)!=="function"||i+8!==this.input.length&&(X(t=this.input.charCodeAt(i+8))||t>55295&&t<56320))},m.isUsingKeyword=function(t,e){if(this.options.ecmaVersion<17||!this.isContextual(t?"await":"using"))return!1;L.lastIndex=this.pos;var i=L.exec(this.input),s=this.pos+i[0].length;if(M.test(this.input.slice(this.pos,s)))return!1;if(t){var r,a=s+5;if(this.input.slice(s,a)!=="using"||a===this.input.length||X(r=this.input.charCodeAt(a))||r>55295&&r<56320)return!1;L.lastIndex=a;var o=L.exec(this.input);if(o&&M.test(this.input.slice(a,a+o[0].length)))return!1}if(e){var h,c=s+2;if(!(this.input.slice(s,c)!=="of"||c!==this.input.length&&(X(h=this.input.charCodeAt(c))||h>55295&&h<56320)))return!1}var l=this.input.charCodeAt(s);return K(l,!0)||l===92},m.isAwaitUsing=function(t){return this.isUsingKeyword(!0,t)},m.isUsing=function(t){return this.isUsingKeyword(!1,t)},m.parseStatement=function(t,e,i){var s,r=this.type,a=this.startNode();switch(this.isLet(t)&&(r=n._var,s="let"),r){case n._break:case n._continue:return this.parseBreakContinueStatement(a,r.keyword);case n._debugger:return this.parseDebuggerStatement(a);case n._do:return this.parseDoStatement(a);case n._for:return this.parseForStatement(a);case n._function:return t&&(this.strict||t!=="if"&&t!=="label")&&this.options.ecmaVersion>=6&&this.unexpected(),this.parseFunctionStatement(a,!1,!t);case n._class:return t&&this.unexpected(),this.parseClass(a,!0);case n._if:return this.parseIfStatement(a);case n._return:return this.parseReturnStatement(a);case n._switch:return this.parseSwitchStatement(a);case n._throw:return this.parseThrowStatement(a);case n._try:return this.parseTryStatement(a);case n._const:case n._var:return s=s||this.value,t&&s!=="var"&&this.unexpected(),this.parseVarStatement(a,s);case n._while:return this.parseWhileStatement(a);case n._with:return this.parseWithStatement(a);case n.braceL:return this.parseBlock(!0,a);case n.semi:return this.parseEmptyStatement(a);case n._export:case n._import:if(this.options.ecmaVersion>10&&r===n._import){L.lastIndex=this.pos;var o=L.exec(this.input),h=this.pos+o[0].length,c=this.input.charCodeAt(h);if(c===40||c===46)return this.parseExpressionStatement(a,this.parseExpression())}return this.options.allowImportExportEverywhere||(e||this.raise(this.start,"'import' and 'export' may only appear at the top level"),this.inModule||this.raise(this.start,"'import' and 'export' may appear only with 'sourceType: module'")),r===n._import?this.parseImport(a):this.parseExport(a,i);default:if(this.isAsyncFunction())return t&&this.unexpected(),this.next(),this.parseFunctionStatement(a,!0,!t);var l=this.isAwaitUsing(!1)?"await using":this.isUsing(!1)?"using":null;if(l)return e&&this.options.sourceType==="script"&&this.raise(this.start,"Using declaration cannot appear in the top level when source type is `script`"),l==="await using"&&(this.canAwait||this.raise(this.start,"Await using cannot appear outside of async function"),this.next()),this.next(),this.parseVar(a,!1,l),this.semicolon(),this.finishNode(a,"VariableDeclaration");var p=this.value,f=this.parseExpression();return r===n.name&&f.type==="Identifier"&&this.eat(n.colon)?this.parseLabeledStatement(a,p,f,t):this.parseExpressionStatement(a,f)}},m.parseBreakContinueStatement=function(t,e){var i=e==="break";this.next(),this.eat(n.semi)||this.insertSemicolon()?t.label=null:this.type!==n.name?this.unexpected():(t.label=this.parseIdent(),this.semicolon());for(var s=0;s<this.labels.length;++s){var r=this.labels[s];if((t.label==null||r.name===t.label.name)&&(r.kind!=null&&(i||r.kind==="loop")||t.label&&i))break}return s===this.labels.length&&this.raise(t.start,"Unsyntactic "+e),this.finishNode(t,i?"BreakStatement":"ContinueStatement")},m.parseDebuggerStatement=function(t){return this.next(),this.semicolon(),this.finishNode(t,"DebuggerStatement")},m.parseDoStatement=function(t){return this.next(),this.labels.push(Zt),t.body=this.parseStatement("do"),this.labels.pop(),this.expect(n._while),t.test=this.parseParenExpression(),this.options.ecmaVersion>=6?this.eat(n.semi):this.semicolon(),this.finishNode(t,"DoWhileStatement")},m.parseForStatement=function(t){this.next();var e=this.options.ecmaVersion>=9&&this.canAwait&&this.eatContextual("await")?this.lastTokStart:-1;if(this.labels.push(Zt),this.enterScope(0),this.expect(n.parenL),this.type===n.semi)return e>-1&&this.unexpected(e),this.parseFor(t,null);var i=this.isLet();if(this.type===n._var||this.type===n._const||i){var s=this.startNode(),r=i?"let":this.value;return this.next(),this.parseVar(s,!0,r),this.finishNode(s,"VariableDeclaration"),this.parseForAfterInit(t,s,e)}var a=this.isContextual("let"),o=!1,h=this.isUsing(!0)?"using":this.isAwaitUsing(!0)?"await using":null;if(h){var c=this.startNode();return this.next(),h==="await using"&&this.next(),this.parseVar(c,!0,h),this.finishNode(c,"VariableDeclaration"),this.parseForAfterInit(t,c,e)}var l=this.containsEsc,p=new Nt,f=this.start,u=e>-1?this.parseExprSubscripts(p,"await"):this.parseExpression(!0,p);return this.type===n._in||(o=this.options.ecmaVersion>=6&&this.isContextual("of"))?(e>-1?(this.type===n._in&&this.unexpected(e),t.await=!0):o&&this.options.ecmaVersion>=8&&(u.start!==f||l||u.type!=="Identifier"||u.name!=="async"?this.options.ecmaVersion>=9&&(t.await=!1):this.unexpected()),a&&o&&this.raise(u.start,"The left-hand side of a for-of loop may not start with 'let'."),this.toAssignable(u,!1,p),this.checkLValPattern(u),this.parseForIn(t,u)):(this.checkExpressionErrors(p,!0),e>-1&&this.unexpected(e),this.parseFor(t,u))},m.parseForAfterInit=function(t,e,i){return(this.type===n._in||this.options.ecmaVersion>=6&&this.isContextual("of"))&&e.declarations.length===1?(this.options.ecmaVersion>=9&&(this.type===n._in?i>-1&&this.unexpected(i):t.await=i>-1),this.parseForIn(t,e)):(i>-1&&this.unexpected(i),this.parseFor(t,e))},m.parseFunctionStatement=function(t,e,i){return this.next(),this.parseFunction(t,Ct|(i?0:Xt),!1,e)},m.parseIfStatement=function(t){return this.next(),t.test=this.parseParenExpression(),t.consequent=this.parseStatement("if"),t.alternate=this.eat(n._else)?this.parseStatement("if"):null,this.finishNode(t,"IfStatement")},m.parseReturnStatement=function(t){return this.inFunction||this.options.allowReturnOutsideFunction||this.raise(this.start,"'return' outside of function"),this.next(),this.eat(n.semi)||this.insertSemicolon()?t.argument=null:(t.argument=this.parseExpression(),this.semicolon()),this.finishNode(t,"ReturnStatement")},m.parseSwitchStatement=function(t){var e;this.next(),t.discriminant=this.parseParenExpression(),t.cases=[],this.expect(n.braceL),this.labels.push(ts),this.enterScope(0);for(var i=!1;this.type!==n.braceR;)if(this.type===n._case||this.type===n._default){var s=this.type===n._case;e&&this.finishNode(e,"SwitchCase"),t.cases.push(e=this.startNode()),e.consequent=[],this.next(),s?e.test=this.parseExpression():(i&&this.raiseRecoverable(this.lastTokStart,"Multiple default clauses"),i=!0,e.test=null),this.expect(n.colon)}else e||this.unexpected(),e.consequent.push(this.parseStatement(null));return this.exitScope(),e&&this.finishNode(e,"SwitchCase"),this.next(),this.labels.pop(),this.finishNode(t,"SwitchStatement")},m.parseThrowStatement=function(t){return this.next(),M.test(this.input.slice(this.lastTokEnd,this.start))&&this.raise(this.lastTokEnd,"Illegal newline after throw"),t.argument=this.parseExpression(),this.semicolon(),this.finishNode(t,"ThrowStatement")};var es=[];m.parseCatchClauseParam=function(){var t=this.parseBindingAtom(),e=t.type==="Identifier";return this.enterScope(e?32:0),this.checkLValPattern(t,e?4:2),this.expect(n.parenR),t},m.parseTryStatement=function(t){if(this.next(),t.block=this.parseBlock(),t.handler=null,this.type===n._catch){var e=this.startNode();this.next(),this.eat(n.parenL)?e.param=this.parseCatchClauseParam():(this.options.ecmaVersion<10&&this.unexpected(),e.param=null,this.enterScope(0)),e.body=this.parseBlock(!1),this.exitScope(),t.handler=this.finishNode(e,"CatchClause")}return t.finalizer=this.eat(n._finally)?this.parseBlock():null,t.handler||t.finalizer||this.raise(t.start,"Missing catch or finally clause"),this.finishNode(t,"TryStatement")},m.parseVarStatement=function(t,e,i){return this.next(),this.parseVar(t,!1,e,i),this.semicolon(),this.finishNode(t,"VariableDeclaration")},m.parseWhileStatement=function(t){return this.next(),t.test=this.parseParenExpression(),this.labels.push(Zt),t.body=this.parseStatement("while"),this.labels.pop(),this.finishNode(t,"WhileStatement")},m.parseWithStatement=function(t){return this.strict&&this.raise(this.start,"'with' in strict mode"),this.next(),t.object=this.parseParenExpression(),t.body=this.parseStatement("with"),this.finishNode(t,"WithStatement")},m.parseEmptyStatement=function(t){return this.next(),this.finishNode(t,"EmptyStatement")},m.parseLabeledStatement=function(t,e,i,s){for(var r=0,a=this.labels;r<a.length;r+=1)a[r].name===e&&this.raise(i.start,"Label '"+e+"' is already declared");for(var o=this.type.isLoop?"loop":this.type===n._switch?"switch":null,h=this.labels.length-1;h>=0;h--){var c=this.labels[h];if(c.statementStart!==t.start)break;c.statementStart=this.start,c.kind=o}return this.labels.push({name:e,kind:o,statementStart:this.start}),t.body=this.parseStatement(s?s.indexOf("label")===-1?s+"label":s:"label"),this.labels.pop(),t.label=i,this.finishNode(t,"LabeledStatement")},m.parseExpressionStatement=function(t,e){return t.expression=e,this.semicolon(),this.finishNode(t,"ExpressionStatement")},m.parseBlock=function(t,e,i){for(t===void 0&&(t=!0),e===void 0&&(e=this.startNode()),e.body=[],this.expect(n.braceL),t&&this.enterScope(0);this.type!==n.braceR;){var s=this.parseStatement(null);e.body.push(s)}return i&&(this.strict=!1),this.next(),t&&this.exitScope(),this.finishNode(e,"BlockStatement")},m.parseFor=function(t,e){return t.init=e,this.expect(n.semi),t.test=this.type===n.semi?null:this.parseExpression(),this.expect(n.semi),t.update=this.type===n.parenR?null:this.parseExpression(),this.expect(n.parenR),t.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(t,"ForStatement")},m.parseForIn=function(t,e){var i=this.type===n._in;return this.next(),e.type==="VariableDeclaration"&&e.declarations[0].init!=null&&(!i||this.options.ecmaVersion<8||this.strict||e.kind!=="var"||e.declarations[0].id.type!=="Identifier")&&this.raise(e.start,(i?"for-in":"for-of")+" loop variable declaration may not have an initializer"),t.left=e,t.right=i?this.parseExpression():this.parseMaybeAssign(),this.expect(n.parenR),t.body=this.parseStatement("for"),this.exitScope(),this.labels.pop(),this.finishNode(t,i?"ForInStatement":"ForOfStatement")},m.parseVar=function(t,e,i,s){for(t.declarations=[],t.kind=i;;){var r=this.startNode();if(this.parseVarId(r,i),this.eat(n.eq)?r.init=this.parseMaybeAssign(e):s||i!=="const"||this.type===n._in||this.options.ecmaVersion>=6&&this.isContextual("of")?s||i!=="using"&&i!=="await using"||!(this.options.ecmaVersion>=17)||this.type===n._in||this.isContextual("of")?s||r.id.type==="Identifier"||e&&(this.type===n._in||this.isContextual("of"))?r.init=null:this.raise(this.lastTokEnd,"Complex binding patterns require an initialization value"):this.raise(this.lastTokEnd,"Missing initializer in "+i+" declaration"):this.unexpected(),t.declarations.push(this.finishNode(r,"VariableDeclarator")),!this.eat(n.comma))break}return t},m.parseVarId=function(t,e){t.id=e==="using"||e==="await using"?this.parseIdent():this.parseBindingAtom(),this.checkLValPattern(t.id,e==="var"?1:2,!1)};var Ct=1,Xt=2;function is(t,e){var i=e.key.name,s=t[i],r="true";return e.type!=="MethodDefinition"||e.kind!=="get"&&e.kind!=="set"||(r=(e.static?"s":"i")+e.kind),s==="iget"&&r==="iset"||s==="iset"&&r==="iget"||s==="sget"&&r==="sset"||s==="sset"&&r==="sget"?(t[i]="true",!1):!!s||(t[i]=r,!1)}function Lt(t,e){var i=t.computed,s=t.key;return!i&&(s.type==="Identifier"&&s.name===e||s.type==="Literal"&&s.value===e)}m.parseFunction=function(t,e,i,s,r){this.initFunction(t),(this.options.ecmaVersion>=9||this.options.ecmaVersion>=6&&!s)&&(this.type===n.star&&e&Xt&&this.unexpected(),t.generator=this.eat(n.star)),this.options.ecmaVersion>=8&&(t.async=!!s),e&Ct&&(t.id=4&e&&this.type!==n.name?null:this.parseIdent(),!t.id||e&Xt||this.checkLValSimple(t.id,this.strict||t.generator||t.async?this.treatFunctionsAsVar?1:2:3));var a=this.yieldPos,o=this.awaitPos,h=this.awaitIdentPos;return this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(Qt(t.async,t.generator)),e&Ct||(t.id=this.type===n.name?this.parseIdent():null),this.parseFunctionParams(t),this.parseFunctionBody(t,i,!1,r),this.yieldPos=a,this.awaitPos=o,this.awaitIdentPos=h,this.finishNode(t,e&Ct?"FunctionDeclaration":"FunctionExpression")},m.parseFunctionParams=function(t){this.expect(n.parenL),t.params=this.parseBindingList(n.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams()},m.parseClass=function(t,e){this.next();var i=this.strict;this.strict=!0,this.parseClassId(t,e),this.parseClassSuper(t);var s=this.enterClassBody(),r=this.startNode(),a=!1;for(r.body=[],this.expect(n.braceL);this.type!==n.braceR;){var o=this.parseClassElement(t.superClass!==null);o&&(r.body.push(o),o.type==="MethodDefinition"&&o.kind==="constructor"?(a&&this.raiseRecoverable(o.start,"Duplicate constructor in the same class"),a=!0):o.key&&o.key.type==="PrivateIdentifier"&&is(s,o)&&this.raiseRecoverable(o.key.start,"Identifier '#"+o.key.name+"' has already been declared"))}return this.strict=i,this.next(),t.body=this.finishNode(r,"ClassBody"),this.exitClassBody(),this.finishNode(t,e?"ClassDeclaration":"ClassExpression")},m.parseClassElement=function(t){if(this.eat(n.semi))return null;var e=this.options.ecmaVersion,i=this.startNode(),s="",r=!1,a=!1,o="method",h=!1;if(this.eatContextual("static")){if(e>=13&&this.eat(n.braceL))return this.parseClassStaticBlock(i),i;this.isClassElementNameStart()||this.type===n.star?h=!0:s="static"}if(i.static=h,!s&&e>=8&&this.eatContextual("async")&&(!this.isClassElementNameStart()&&this.type!==n.star||this.canInsertSemicolon()?s="async":a=!0),!s&&(e>=9||!a)&&this.eat(n.star)&&(r=!0),!s&&!a&&!r){var c=this.value;(this.eatContextual("get")||this.eatContextual("set"))&&(this.isClassElementNameStart()?o=c:s=c)}if(s?(i.computed=!1,i.key=this.startNodeAt(this.lastTokStart,this.lastTokStartLoc),i.key.name=s,this.finishNode(i.key,"Identifier")):this.parseClassElementName(i),e<13||this.type===n.parenL||o!=="method"||r||a){var l=!i.static&&Lt(i,"constructor"),p=l&&t;l&&o!=="method"&&this.raise(i.key.start,"Constructor can't have get/set modifier"),i.kind=l?"constructor":o,this.parseClassMethod(i,r,a,p)}else this.parseClassField(i);return i},m.isClassElementNameStart=function(){return this.type===n.name||this.type===n.privateId||this.type===n.num||this.type===n.string||this.type===n.bracketL||this.type.keyword},m.parseClassElementName=function(t){this.type===n.privateId?(this.value==="constructor"&&this.raise(this.start,"Classes can't have an element named '#constructor'"),t.computed=!1,t.key=this.parsePrivateIdent()):this.parsePropertyName(t)},m.parseClassMethod=function(t,e,i,s){var r=t.key;t.kind==="constructor"?(e&&this.raise(r.start,"Constructor can't be a generator"),i&&this.raise(r.start,"Constructor can't be an async method")):t.static&&Lt(t,"prototype")&&this.raise(r.start,"Classes may not have a static property named prototype");var a=t.value=this.parseMethod(e,i,s);return t.kind==="get"&&a.params.length!==0&&this.raiseRecoverable(a.start,"getter should have no params"),t.kind==="set"&&a.params.length!==1&&this.raiseRecoverable(a.start,"setter should have exactly one param"),t.kind==="set"&&a.params[0].type==="RestElement"&&this.raiseRecoverable(a.params[0].start,"Setter cannot use rest params"),this.finishNode(t,"MethodDefinition")},m.parseClassField=function(t){return Lt(t,"constructor")?this.raise(t.key.start,"Classes can't have a field named 'constructor'"):t.static&&Lt(t,"prototype")&&this.raise(t.key.start,"Classes can't have a static field named 'prototype'"),this.eat(n.eq)?(this.enterScope(576),t.value=this.parseMaybeAssign(),this.exitScope()):t.value=null,this.semicolon(),this.finishNode(t,"PropertyDefinition")},m.parseClassStaticBlock=function(t){t.body=[];var e=this.labels;for(this.labels=[],this.enterScope(320);this.type!==n.braceR;){var i=this.parseStatement(null);t.body.push(i)}return this.next(),this.exitScope(),this.labels=e,this.finishNode(t,"StaticBlock")},m.parseClassId=function(t,e){this.type===n.name?(t.id=this.parseIdent(),e&&this.checkLValSimple(t.id,2,!1)):(e===!0&&this.unexpected(),t.id=null)},m.parseClassSuper=function(t){t.superClass=this.eat(n._extends)?this.parseExprSubscripts(null,!1):null},m.enterClassBody=function(){var t={declared:Object.create(null),used:[]};return this.privateNameStack.push(t),t.declared},m.exitClassBody=function(){var t=this.privateNameStack.pop(),e=t.declared,i=t.used;if(this.options.checkPrivateFields)for(var s=this.privateNameStack.length,r=s===0?null:this.privateNameStack[s-1],a=0;a<i.length;++a){var o=i[a];ft(e,o.name)||(r?r.used.push(o):this.raiseRecoverable(o.start,"Private field '#"+o.name+"' must be declared in an enclosing class"))}},m.parseExportAllDeclaration=function(t,e){return this.options.ecmaVersion>=11&&(this.eatContextual("as")?(t.exported=this.parseModuleExportName(),this.checkExport(e,t.exported,this.lastTokStart)):t.exported=null),this.expectContextual("from"),this.type!==n.string&&this.unexpected(),t.source=this.parseExprAtom(),this.options.ecmaVersion>=16&&(t.attributes=this.parseWithClause()),this.semicolon(),this.finishNode(t,"ExportAllDeclaration")},m.parseExport=function(t,e){if(this.next(),this.eat(n.star))return this.parseExportAllDeclaration(t,e);if(this.eat(n._default))return this.checkExport(e,"default",this.lastTokStart),t.declaration=this.parseExportDefaultDeclaration(),this.finishNode(t,"ExportDefaultDeclaration");if(this.shouldParseExportStatement())t.declaration=this.parseExportDeclaration(t),t.declaration.type==="VariableDeclaration"?this.checkVariableExport(e,t.declaration.declarations):this.checkExport(e,t.declaration.id,t.declaration.id.start),t.specifiers=[],t.source=null,this.options.ecmaVersion>=16&&(t.attributes=[]);else{if(t.declaration=null,t.specifiers=this.parseExportSpecifiers(e),this.eatContextual("from"))this.type!==n.string&&this.unexpected(),t.source=this.parseExprAtom(),this.options.ecmaVersion>=16&&(t.attributes=this.parseWithClause());else{for(var i=0,s=t.specifiers;i<s.length;i+=1){var r=s[i];this.checkUnreserved(r.local),this.checkLocalExport(r.local),r.local.type==="Literal"&&this.raise(r.local.start,"A string literal cannot be used as an exported binding without `from`.")}t.source=null,this.options.ecmaVersion>=16&&(t.attributes=[])}this.semicolon()}return this.finishNode(t,"ExportNamedDeclaration")},m.parseExportDeclaration=function(t){return this.parseStatement(null)},m.parseExportDefaultDeclaration=function(){var t;if(this.type===n._function||(t=this.isAsyncFunction())){var e=this.startNode();return this.next(),t&&this.next(),this.parseFunction(e,4|Ct,!1,t)}if(this.type===n._class){var i=this.startNode();return this.parseClass(i,"nullableID")}var s=this.parseMaybeAssign();return this.semicolon(),s},m.checkExport=function(t,e,i){t&&(typeof e!="string"&&(e=e.type==="Identifier"?e.name:e.value),ft(t,e)&&this.raiseRecoverable(i,"Duplicate export '"+e+"'"),t[e]=!0)},m.checkPatternExport=function(t,e){var i=e.type;if(i==="Identifier")this.checkExport(t,e,e.start);else if(i==="ObjectPattern")for(var s=0,r=e.properties;s<r.length;s+=1){var a=r[s];this.checkPatternExport(t,a)}else if(i==="ArrayPattern")for(var o=0,h=e.elements;o<h.length;o+=1){var c=h[o];c&&this.checkPatternExport(t,c)}else i==="Property"?this.checkPatternExport(t,e.value):i==="AssignmentPattern"?this.checkPatternExport(t,e.left):i==="RestElement"&&this.checkPatternExport(t,e.argument)},m.checkVariableExport=function(t,e){if(t)for(var i=0,s=e;i<s.length;i+=1){var r=s[i];this.checkPatternExport(t,r.id)}},m.shouldParseExportStatement=function(){return this.type.keyword==="var"||this.type.keyword==="const"||this.type.keyword==="class"||this.type.keyword==="function"||this.isLet()||this.isAsyncFunction()},m.parseExportSpecifier=function(t){var e=this.startNode();return e.local=this.parseModuleExportName(),e.exported=this.eatContextual("as")?this.parseModuleExportName():e.local,this.checkExport(t,e.exported,e.exported.start),this.finishNode(e,"ExportSpecifier")},m.parseExportSpecifiers=function(t){var e=[],i=!0;for(this.expect(n.braceL);!this.eat(n.braceR);){if(i)i=!1;else if(this.expect(n.comma),this.afterTrailingComma(n.braceR))break;e.push(this.parseExportSpecifier(t))}return e},m.parseImport=function(t){return this.next(),this.type===n.string?(t.specifiers=es,t.source=this.parseExprAtom()):(t.specifiers=this.parseImportSpecifiers(),this.expectContextual("from"),t.source=this.type===n.string?this.parseExprAtom():this.unexpected()),this.options.ecmaVersion>=16&&(t.attributes=this.parseWithClause()),this.semicolon(),this.finishNode(t,"ImportDeclaration")},m.parseImportSpecifier=function(){var t=this.startNode();return t.imported=this.parseModuleExportName(),this.eatContextual("as")?t.local=this.parseIdent():(this.checkUnreserved(t.imported),t.local=t.imported),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportSpecifier")},m.parseImportDefaultSpecifier=function(){var t=this.startNode();return t.local=this.parseIdent(),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportDefaultSpecifier")},m.parseImportNamespaceSpecifier=function(){var t=this.startNode();return this.next(),this.expectContextual("as"),t.local=this.parseIdent(),this.checkLValSimple(t.local,2),this.finishNode(t,"ImportNamespaceSpecifier")},m.parseImportSpecifiers=function(){var t=[],e=!0;if(this.type===n.name&&(t.push(this.parseImportDefaultSpecifier()),!this.eat(n.comma)))return t;if(this.type===n.star)return t.push(this.parseImportNamespaceSpecifier()),t;for(this.expect(n.braceL);!this.eat(n.braceR);){if(e)e=!1;else if(this.expect(n.comma),this.afterTrailingComma(n.braceR))break;t.push(this.parseImportSpecifier())}return t},m.parseWithClause=function(){var t=[];if(!this.eat(n._with))return t;this.expect(n.braceL);for(var e={},i=!0;!this.eat(n.braceR);){if(i)i=!1;else if(this.expect(n.comma),this.afterTrailingComma(n.braceR))break;var s=this.parseImportAttribute(),r=s.key.type==="Identifier"?s.key.name:s.key.value;ft(e,r)&&this.raiseRecoverable(s.key.start,"Duplicate attribute key '"+r+"'"),e[r]=!0,t.push(s)}return t},m.parseImportAttribute=function(){var t=this.startNode();return t.key=this.type===n.string?this.parseExprAtom():this.parseIdent(this.options.allowReserved!=="never"),this.expect(n.colon),this.type!==n.string&&this.unexpected(),t.value=this.parseExprAtom(),this.finishNode(t,"ImportAttribute")},m.parseModuleExportName=function(){if(this.options.ecmaVersion>=13&&this.type===n.string){var t=this.parseLiteral(this.value);return Yi.test(t.value)&&this.raise(t.start,"An export name cannot include a lone surrogate."),t}return this.parseIdent(!0)},m.adaptDirectivePrologue=function(t){for(var e=0;e<t.length&&this.isDirectiveCandidate(t[e]);++e)t[e].directive=t[e].expression.raw.slice(1,-1)},m.isDirectiveCandidate=function(t){return this.options.ecmaVersion>=5&&t.type==="ExpressionStatement"&&t.expression.type==="Literal"&&typeof t.expression.value=="string"&&(this.input[t.start]==='"'||this.input[t.start]==="'")};var q=N.prototype;q.toAssignable=function(t,e,i){if(this.options.ecmaVersion>=6&&t)switch(t.type){case"Identifier":this.inAsync&&t.name==="await"&&this.raise(t.start,"Cannot use 'await' as identifier inside an async function");break;case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":case"RestElement":break;case"ObjectExpression":t.type="ObjectPattern",i&&this.checkPatternErrors(i,!0);for(var s=0,r=t.properties;s<r.length;s+=1){var a=r[s];this.toAssignable(a,e),a.type!=="RestElement"||a.argument.type!=="ArrayPattern"&&a.argument.type!=="ObjectPattern"||this.raise(a.argument.start,"Unexpected token")}break;case"Property":t.kind!=="init"&&this.raise(t.key.start,"Object pattern can't contain getter or setter"),this.toAssignable(t.value,e);break;case"ArrayExpression":t.type="ArrayPattern",i&&this.checkPatternErrors(i,!0),this.toAssignableList(t.elements,e);break;case"SpreadElement":t.type="RestElement",this.toAssignable(t.argument,e),t.argument.type==="AssignmentPattern"&&this.raise(t.argument.start,"Rest elements cannot have a default value");break;case"AssignmentExpression":t.operator!=="="&&this.raise(t.left.end,"Only '=' operator can be used for specifying default value."),t.type="AssignmentPattern",delete t.operator,this.toAssignable(t.left,e);break;case"ParenthesizedExpression":this.toAssignable(t.expression,e,i);break;case"ChainExpression":this.raiseRecoverable(t.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":if(!e)break;default:this.raise(t.start,"Assigning to rvalue")}else i&&this.checkPatternErrors(i,!0);return t},q.toAssignableList=function(t,e){for(var i=t.length,s=0;s<i;s++){var r=t[s];r&&this.toAssignable(r,e)}if(i){var a=t[i-1];this.options.ecmaVersion===6&&e&&a&&a.type==="RestElement"&&a.argument.type!=="Identifier"&&this.unexpected(a.argument.start)}return t},q.parseSpread=function(t){var e=this.startNode();return this.next(),e.argument=this.parseMaybeAssign(!1,t),this.finishNode(e,"SpreadElement")},q.parseRestBinding=function(){var t=this.startNode();return this.next(),this.options.ecmaVersion===6&&this.type!==n.name&&this.unexpected(),t.argument=this.parseBindingAtom(),this.finishNode(t,"RestElement")},q.parseBindingAtom=function(){if(this.options.ecmaVersion>=6)switch(this.type){case n.bracketL:var t=this.startNode();return this.next(),t.elements=this.parseBindingList(n.bracketR,!0,!0),this.finishNode(t,"ArrayPattern");case n.braceL:return this.parseObj(!0)}return this.parseIdent()},q.parseBindingList=function(t,e,i,s){for(var r=[],a=!0;!this.eat(t);)if(a?a=!1:this.expect(n.comma),e&&this.type===n.comma)r.push(null);else{if(i&&this.afterTrailingComma(t))break;if(this.type===n.ellipsis){var o=this.parseRestBinding();this.parseBindingListItem(o),r.push(o),this.type===n.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.expect(t);break}r.push(this.parseAssignableListItem(s))}return r},q.parseAssignableListItem=function(t){var e=this.parseMaybeDefault(this.start,this.startLoc);return this.parseBindingListItem(e),e},q.parseBindingListItem=function(t){return t},q.parseMaybeDefault=function(t,e,i){if(i=i||this.parseBindingAtom(),this.options.ecmaVersion<6||!this.eat(n.eq))return i;var s=this.startNodeAt(t,e);return s.left=i,s.right=this.parseMaybeAssign(),this.finishNode(s,"AssignmentPattern")},q.checkLValSimple=function(t,e,i){e===void 0&&(e=0);var s=e!==0;switch(t.type){case"Identifier":this.strict&&this.reservedWordsStrictBind.test(t.name)&&this.raiseRecoverable(t.start,(s?"Binding ":"Assigning to ")+t.name+" in strict mode"),s&&(e===2&&t.name==="let"&&this.raiseRecoverable(t.start,"let is disallowed as a lexically bound name"),i&&(ft(i,t.name)&&this.raiseRecoverable(t.start,"Argument name clash"),i[t.name]=!0),e!==5&&this.declareName(t.name,e,t.start));break;case"ChainExpression":this.raiseRecoverable(t.start,"Optional chaining cannot appear in left-hand side");break;case"MemberExpression":s&&this.raiseRecoverable(t.start,"Binding member expression");break;case"ParenthesizedExpression":return s&&this.raiseRecoverable(t.start,"Binding parenthesized expression"),this.checkLValSimple(t.expression,e,i);default:this.raise(t.start,(s?"Binding":"Assigning to")+" rvalue")}},q.checkLValPattern=function(t,e,i){switch(e===void 0&&(e=0),t.type){case"ObjectPattern":for(var s=0,r=t.properties;s<r.length;s+=1){var a=r[s];this.checkLValInnerPattern(a,e,i)}break;case"ArrayPattern":for(var o=0,h=t.elements;o<h.length;o+=1){var c=h[o];c&&this.checkLValInnerPattern(c,e,i)}break;default:this.checkLValSimple(t,e,i)}},q.checkLValInnerPattern=function(t,e,i){switch(e===void 0&&(e=0),t.type){case"Property":this.checkLValInnerPattern(t.value,e,i);break;case"AssignmentPattern":this.checkLValPattern(t.left,e,i);break;case"RestElement":this.checkLValPattern(t.argument,e,i);break;default:this.checkLValPattern(t,e,i)}};var G=function(t,e,i,s,r){this.token=t,this.isExpr=!!e,this.preserveSpace=!!i,this.override=s,this.generator=!!r},R={b_stat:new G("{",!1),b_expr:new G("{",!0),b_tmpl:new G("${",!1),p_stat:new G("(",!1),p_expr:new G("(",!0),q_tmpl:new G("`",!0,!0,function(t){return t.tryReadTemplateToken()}),f_stat:new G("function",!1),f_expr:new G("function",!0),f_expr_gen:new G("function",!0,!1,null,!0),f_gen:new G("function",!1,!1,null,!0)},dt=N.prototype;dt.initialContext=function(){return[R.b_stat]},dt.curContext=function(){return this.context[this.context.length-1]},dt.braceIsBlock=function(t){var e=this.curContext();return e===R.f_expr||e===R.f_stat||(t!==n.colon||e!==R.b_stat&&e!==R.b_expr?t===n._return||t===n.name&&this.exprAllowed?M.test(this.input.slice(this.lastTokEnd,this.start)):t===n._else||t===n.semi||t===n.eof||t===n.parenR||t===n.arrow||(t===n.braceL?e===R.b_stat:t!==n._var&&t!==n._const&&t!==n.name&&!this.exprAllowed):!e.isExpr)},dt.inGeneratorContext=function(){for(var t=this.context.length-1;t>=1;t--){var e=this.context[t];if(e.token==="function")return e.generator}return!1},dt.updateContext=function(t){var e,i=this.type;i.keyword&&t===n.dot?this.exprAllowed=!1:(e=i.updateContext)?e.call(this,t):this.exprAllowed=i.beforeExpr},dt.overrideContext=function(t){this.curContext()!==t&&(this.context[this.context.length-1]=t)},n.parenR.updateContext=n.braceR.updateContext=function(){if(this.context.length!==1){var t=this.context.pop();t===R.b_stat&&this.curContext().token==="function"&&(t=this.context.pop()),this.exprAllowed=!t.isExpr}else this.exprAllowed=!0},n.braceL.updateContext=function(t){this.context.push(this.braceIsBlock(t)?R.b_stat:R.b_expr),this.exprAllowed=!0},n.dollarBraceL.updateContext=function(){this.context.push(R.b_tmpl),this.exprAllowed=!0},n.parenL.updateContext=function(t){var e=t===n._if||t===n._for||t===n._with||t===n._while;this.context.push(e?R.p_stat:R.p_expr),this.exprAllowed=!0},n.incDec.updateContext=function(){},n._function.updateContext=n._class.updateContext=function(t){!t.beforeExpr||t===n._else||t===n.semi&&this.curContext()!==R.p_stat||t===n._return&&M.test(this.input.slice(this.lastTokEnd,this.start))||(t===n.colon||t===n.braceL)&&this.curContext()===R.b_stat?this.context.push(R.f_stat):this.context.push(R.f_expr),this.exprAllowed=!1},n.colon.updateContext=function(){this.curContext().token==="function"&&this.context.pop(),this.exprAllowed=!0},n.backQuote.updateContext=function(){this.curContext()===R.q_tmpl?this.context.pop():this.context.push(R.q_tmpl),this.exprAllowed=!1},n.star.updateContext=function(t){if(t===n._function){var e=this.context.length-1;this.context[e]===R.f_expr?this.context[e]=R.f_expr_gen:this.context[e]=R.f_gen}this.exprAllowed=!0},n.name.updateContext=function(t){var e=!1;this.options.ecmaVersion>=6&&t!==n.dot&&(this.value==="of"&&!this.exprAllowed||this.value==="yield"&&this.inGeneratorContext())&&(e=!0),this.exprAllowed=e};var x=N.prototype;function Ne(t){return t.type==="Identifier"||t.type==="ParenthesizedExpression"&&Ne(t.expression)}function te(t){return t.type==="MemberExpression"&&t.property.type==="PrivateIdentifier"||t.type==="ChainExpression"&&te(t.expression)||t.type==="ParenthesizedExpression"&&te(t.expression)}x.checkPropClash=function(t,e,i){if(!(this.options.ecmaVersion>=9&&t.type==="SpreadElement"||this.options.ecmaVersion>=6&&(t.computed||t.method||t.shorthand))){var s,r=t.key;switch(r.type){case"Identifier":s=r.name;break;case"Literal":s=String(r.value);break;default:return}var a=t.kind;if(this.options.ecmaVersion>=6)s==="__proto__"&&a==="init"&&(e.proto&&(i?i.doubleProto<0&&(i.doubleProto=r.start):this.raiseRecoverable(r.start,"Redefinition of __proto__ property")),e.proto=!0);else{var o=e[s="$"+s];o?(a==="init"?this.strict&&o.init||o.get||o.set:o.init||o[a])&&this.raiseRecoverable(r.start,"Redefinition of property"):o=e[s]={init:!1,get:!1,set:!1},o[a]=!0}}},x.parseExpression=function(t,e){var i=this.start,s=this.startLoc,r=this.parseMaybeAssign(t,e);if(this.type===n.comma){var a=this.startNodeAt(i,s);for(a.expressions=[r];this.eat(n.comma);)a.expressions.push(this.parseMaybeAssign(t,e));return this.finishNode(a,"SequenceExpression")}return r},x.parseMaybeAssign=function(t,e,i){if(this.isContextual("yield")){if(this.inGenerator)return this.parseYield(t);this.exprAllowed=!1}var s=!1,r=-1,a=-1,o=-1;e?(r=e.parenthesizedAssign,a=e.trailingComma,o=e.doubleProto,e.parenthesizedAssign=e.trailingComma=-1):(e=new Nt,s=!0);var h=this.start,c=this.startLoc;this.type!==n.parenL&&this.type!==n.name||(this.potentialArrowAt=this.start,this.potentialArrowInForAwait=t==="await");var l=this.parseMaybeConditional(t,e);if(i&&(l=i.call(this,l,h,c)),this.type.isAssign){var p=this.startNodeAt(h,c);return p.operator=this.value,this.type===n.eq&&(l=this.toAssignable(l,!1,e)),s||(e.parenthesizedAssign=e.trailingComma=e.doubleProto=-1),e.shorthandAssign>=l.start&&(e.shorthandAssign=-1),this.type===n.eq?this.checkLValPattern(l):this.checkLValSimple(l),p.left=l,this.next(),p.right=this.parseMaybeAssign(t),o>-1&&(e.doubleProto=o),this.finishNode(p,"AssignmentExpression")}return s&&this.checkExpressionErrors(e,!0),r>-1&&(e.parenthesizedAssign=r),a>-1&&(e.trailingComma=a),l},x.parseMaybeConditional=function(t,e){var i=this.start,s=this.startLoc,r=this.parseExprOps(t,e);if(this.checkExpressionErrors(e))return r;if(this.eat(n.question)){var a=this.startNodeAt(i,s);return a.test=r,a.consequent=this.parseMaybeAssign(),this.expect(n.colon),a.alternate=this.parseMaybeAssign(t),this.finishNode(a,"ConditionalExpression")}return r},x.parseExprOps=function(t,e){var i=this.start,s=this.startLoc,r=this.parseMaybeUnary(e,!1,!1,t);return this.checkExpressionErrors(e)||r.start===i&&r.type==="ArrowFunctionExpression"?r:this.parseExprOp(r,i,s,-1,t)},x.parseExprOp=function(t,e,i,s,r){var a=this.type.binop;if(a!=null&&(!r||this.type!==n._in)&&a>s){var o=this.type===n.logicalOR||this.type===n.logicalAND,h=this.type===n.coalesce;h&&(a=n.logicalAND.binop);var c=this.value;this.next();var l=this.start,p=this.startLoc,f=this.parseExprOp(this.parseMaybeUnary(null,!1,!1,r),l,p,a,r),u=this.buildBinary(e,i,t,f,c,o||h);return(o&&this.type===n.coalesce||h&&(this.type===n.logicalOR||this.type===n.logicalAND))&&this.raiseRecoverable(this.start,"Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses"),this.parseExprOp(u,e,i,s,r)}return t},x.buildBinary=function(t,e,i,s,r,a){s.type==="PrivateIdentifier"&&this.raise(s.start,"Private identifier can only be left side of binary expression");var o=this.startNodeAt(t,e);return o.left=i,o.operator=r,o.right=s,this.finishNode(o,a?"LogicalExpression":"BinaryExpression")},x.parseMaybeUnary=function(t,e,i,s){var r,a=this.start,o=this.startLoc;if(this.isContextual("await")&&this.canAwait)r=this.parseAwait(s),e=!0;else if(this.type.prefix){var h=this.startNode(),c=this.type===n.incDec;h.operator=this.value,h.prefix=!0,this.next(),h.argument=this.parseMaybeUnary(null,!0,c,s),this.checkExpressionErrors(t,!0),c?this.checkLValSimple(h.argument):this.strict&&h.operator==="delete"&&Ne(h.argument)?this.raiseRecoverable(h.start,"Deleting local variable in strict mode"):h.operator==="delete"&&te(h.argument)?this.raiseRecoverable(h.start,"Private fields can not be deleted"):e=!0,r=this.finishNode(h,c?"UpdateExpression":"UnaryExpression")}else if(e||this.type!==n.privateId){if(r=this.parseExprSubscripts(t,s),this.checkExpressionErrors(t))return r;for(;this.type.postfix&&!this.canInsertSemicolon();){var l=this.startNodeAt(a,o);l.operator=this.value,l.prefix=!1,l.argument=r,this.checkLValSimple(r),this.next(),r=this.finishNode(l,"UpdateExpression")}}else(s||this.privateNameStack.length===0)&&this.options.checkPrivateFields&&this.unexpected(),r=this.parsePrivateIdent(),this.type!==n._in&&this.unexpected();return i||!this.eat(n.starstar)?r:e?void this.unexpected(this.lastTokStart):this.buildBinary(a,o,r,this.parseMaybeUnary(null,!1,!1,s),"**",!1)},x.parseExprSubscripts=function(t,e){var i=this.start,s=this.startLoc,r=this.parseExprAtom(t,e);if(r.type==="ArrowFunctionExpression"&&this.input.slice(this.lastTokStart,this.lastTokEnd)!==")")return r;var a=this.parseSubscripts(r,i,s,!1,e);return t&&a.type==="MemberExpression"&&(t.parenthesizedAssign>=a.start&&(t.parenthesizedAssign=-1),t.parenthesizedBind>=a.start&&(t.parenthesizedBind=-1),t.trailingComma>=a.start&&(t.trailingComma=-1)),a},x.parseSubscripts=function(t,e,i,s,r){for(var a=this.options.ecmaVersion>=8&&t.type==="Identifier"&&t.name==="async"&&this.lastTokEnd===t.end&&!this.canInsertSemicolon()&&t.end-t.start===5&&this.potentialArrowAt===t.start,o=!1;;){var h=this.parseSubscript(t,e,i,s,a,o,r);if(h.optional&&(o=!0),h===t||h.type==="ArrowFunctionExpression"){if(o){var c=this.startNodeAt(e,i);c.expression=h,h=this.finishNode(c,"ChainExpression")}return h}t=h}},x.shouldParseAsyncArrow=function(){return!this.canInsertSemicolon()&&this.eat(n.arrow)},x.parseSubscriptAsyncArrow=function(t,e,i,s){return this.parseArrowExpression(this.startNodeAt(t,e),i,!0,s)},x.parseSubscript=function(t,e,i,s,r,a,o){var h=this.options.ecmaVersion>=11,c=h&&this.eat(n.questionDot);s&&c&&this.raise(this.lastTokStart,"Optional chaining cannot appear in the callee of new expressions");var l=this.eat(n.bracketL);if(l||c&&this.type!==n.parenL&&this.type!==n.backQuote||this.eat(n.dot)){var p=this.startNodeAt(e,i);p.object=t,l?(p.property=this.parseExpression(),this.expect(n.bracketR)):this.type===n.privateId&&t.type!=="Super"?p.property=this.parsePrivateIdent():p.property=this.parseIdent(this.options.allowReserved!=="never"),p.computed=!!l,h&&(p.optional=c),t=this.finishNode(p,"MemberExpression")}else if(!s&&this.eat(n.parenL)){var f=new Nt,u=this.yieldPos,v=this.awaitPos,w=this.awaitIdentPos;this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0;var y=this.parseExprList(n.parenR,this.options.ecmaVersion>=8,!1,f);if(r&&!c&&this.shouldParseAsyncArrow())return this.checkPatternErrors(f,!1),this.checkYieldAwaitInDefaultParams(),this.awaitIdentPos>0&&this.raise(this.awaitIdentPos,"Cannot use 'await' as identifier inside an async function"),this.yieldPos=u,this.awaitPos=v,this.awaitIdentPos=w,this.parseSubscriptAsyncArrow(e,i,y,o);this.checkExpressionErrors(f,!0),this.yieldPos=u||this.yieldPos,this.awaitPos=v||this.awaitPos,this.awaitIdentPos=w||this.awaitIdentPos;var I=this.startNodeAt(e,i);I.callee=t,I.arguments=y,h&&(I.optional=c),t=this.finishNode(I,"CallExpression")}else if(this.type===n.backQuote){(c||a)&&this.raise(this.start,"Optional chaining cannot appear in the tag of tagged template expressions");var C=this.startNodeAt(e,i);C.tag=t,C.quasi=this.parseTemplate({isTagged:!0}),t=this.finishNode(C,"TaggedTemplateExpression")}return t},x.parseExprAtom=function(t,e,i){this.type===n.slash&&this.readRegexp();var s,r=this.potentialArrowAt===this.start;switch(this.type){case n._super:return this.allowSuper||this.raise(this.start,"'super' keyword outside a method"),s=this.startNode(),this.next(),this.type!==n.parenL||this.allowDirectSuper||this.raise(s.start,"super() call outside constructor of a subclass"),this.type!==n.dot&&this.type!==n.bracketL&&this.type!==n.parenL&&this.unexpected(),this.finishNode(s,"Super");case n._this:return s=this.startNode(),this.next(),this.finishNode(s,"ThisExpression");case n.name:var a=this.start,o=this.startLoc,h=this.containsEsc,c=this.parseIdent(!1);if(this.options.ecmaVersion>=8&&!h&&c.name==="async"&&!this.canInsertSemicolon()&&this.eat(n._function))return this.overrideContext(R.f_expr),this.parseFunction(this.startNodeAt(a,o),0,!1,!0,e);if(r&&!this.canInsertSemicolon()){if(this.eat(n.arrow))return this.parseArrowExpression(this.startNodeAt(a,o),[c],!1,e);if(this.options.ecmaVersion>=8&&c.name==="async"&&this.type===n.name&&!h&&(!this.potentialArrowInForAwait||this.value!=="of"||this.containsEsc))return c=this.parseIdent(!1),!this.canInsertSemicolon()&&this.eat(n.arrow)||this.unexpected(),this.parseArrowExpression(this.startNodeAt(a,o),[c],!0,e)}return c;case n.regexp:var l=this.value;return(s=this.parseLiteral(l.value)).regex={pattern:l.pattern,flags:l.flags},s;case n.num:case n.string:return this.parseLiteral(this.value);case n._null:case n._true:case n._false:return(s=this.startNode()).value=this.type===n._null?null:this.type===n._true,s.raw=this.type.keyword,this.next(),this.finishNode(s,"Literal");case n.parenL:var p=this.start,f=this.parseParenAndDistinguishExpression(r,e);return t&&(t.parenthesizedAssign<0&&!this.isSimpleAssignTarget(f)&&(t.parenthesizedAssign=p),t.parenthesizedBind<0&&(t.parenthesizedBind=p)),f;case n.bracketL:return s=this.startNode(),this.next(),s.elements=this.parseExprList(n.bracketR,!0,!0,t),this.finishNode(s,"ArrayExpression");case n.braceL:return this.overrideContext(R.b_expr),this.parseObj(!1,t);case n._function:return s=this.startNode(),this.next(),this.parseFunction(s,0);case n._class:return this.parseClass(this.startNode(),!1);case n._new:return this.parseNew();case n.backQuote:return this.parseTemplate();case n._import:return this.options.ecmaVersion>=11?this.parseExprImport(i):this.unexpected();default:return this.parseExprAtomDefault()}},x.parseExprAtomDefault=function(){this.unexpected()},x.parseExprImport=function(t){var e=this.startNode();if(this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword import"),this.next(),this.type===n.parenL&&!t)return this.parseDynamicImport(e);if(this.type===n.dot){var i=this.startNodeAt(e.start,e.loc&&e.loc.start);return i.name="import",e.meta=this.finishNode(i,"Identifier"),this.parseImportMeta(e)}this.unexpected()},x.parseDynamicImport=function(t){if(this.next(),t.source=this.parseMaybeAssign(),this.options.ecmaVersion>=16)this.eat(n.parenR)?t.options=null:(this.expect(n.comma),this.afterTrailingComma(n.parenR)?t.options=null:(t.options=this.parseMaybeAssign(),this.eat(n.parenR)||(this.expect(n.comma),this.afterTrailingComma(n.parenR)||this.unexpected())));else if(!this.eat(n.parenR)){var e=this.start;this.eat(n.comma)&&this.eat(n.parenR)?this.raiseRecoverable(e,"Trailing comma is not allowed in import()"):this.unexpected(e)}return this.finishNode(t,"ImportExpression")},x.parseImportMeta=function(t){this.next();var e=this.containsEsc;return t.property=this.parseIdent(!0),t.property.name!=="meta"&&this.raiseRecoverable(t.property.start,"The only valid meta property for import is 'import.meta'"),e&&this.raiseRecoverable(t.start,"'import.meta' must not contain escaped characters"),this.options.sourceType==="module"||this.options.allowImportExportEverywhere||this.raiseRecoverable(t.start,"Cannot use 'import.meta' outside a module"),this.finishNode(t,"MetaProperty")},x.parseLiteral=function(t){var e=this.startNode();return e.value=t,e.raw=this.input.slice(this.start,this.end),e.raw.charCodeAt(e.raw.length-1)===110&&(e.bigint=e.value!=null?e.value.toString():e.raw.slice(0,-1).replace(/_/g,"")),this.next(),this.finishNode(e,"Literal")},x.parseParenExpression=function(){this.expect(n.parenL);var t=this.parseExpression();return this.expect(n.parenR),t},x.shouldParseArrow=function(t){return!this.canInsertSemicolon()},x.parseParenAndDistinguishExpression=function(t,e){var i,s=this.start,r=this.startLoc,a=this.options.ecmaVersion>=8;if(this.options.ecmaVersion>=6){this.next();var o,h=this.start,c=this.startLoc,l=[],p=!0,f=!1,u=new Nt,v=this.yieldPos,w=this.awaitPos;for(this.yieldPos=0,this.awaitPos=0;this.type!==n.parenR;){if(p?p=!1:this.expect(n.comma),a&&this.afterTrailingComma(n.parenR,!0)){f=!0;break}if(this.type===n.ellipsis){o=this.start,l.push(this.parseParenItem(this.parseRestBinding())),this.type===n.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element");break}l.push(this.parseMaybeAssign(!1,u,this.parseParenItem))}var y=this.lastTokEnd,I=this.lastTokEndLoc;if(this.expect(n.parenR),t&&this.shouldParseArrow(l)&&this.eat(n.arrow))return this.checkPatternErrors(u,!1),this.checkYieldAwaitInDefaultParams(),this.yieldPos=v,this.awaitPos=w,this.parseParenArrowList(s,r,l,e);l.length&&!f||this.unexpected(this.lastTokStart),o&&this.unexpected(o),this.checkExpressionErrors(u,!0),this.yieldPos=v||this.yieldPos,this.awaitPos=w||this.awaitPos,l.length>1?((i=this.startNodeAt(h,c)).expressions=l,this.finishNodeAt(i,"SequenceExpression",y,I)):i=l[0]}else i=this.parseParenExpression();if(this.options.preserveParens){var C=this.startNodeAt(s,r);return C.expression=i,this.finishNode(C,"ParenthesizedExpression")}return i},x.parseParenItem=function(t){return t},x.parseParenArrowList=function(t,e,i,s){return this.parseArrowExpression(this.startNodeAt(t,e),i,!1,s)};var ss=[];x.parseNew=function(){this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword new");var t=this.startNode();if(this.next(),this.options.ecmaVersion>=6&&this.type===n.dot){var e=this.startNodeAt(t.start,t.loc&&t.loc.start);e.name="new",t.meta=this.finishNode(e,"Identifier"),this.next();var i=this.containsEsc;return t.property=this.parseIdent(!0),t.property.name!=="target"&&this.raiseRecoverable(t.property.start,"The only valid meta property for new is 'new.target'"),i&&this.raiseRecoverable(t.start,"'new.target' must not contain escaped characters"),this.allowNewDotTarget||this.raiseRecoverable(t.start,"'new.target' can only be used in functions and class static block"),this.finishNode(t,"MetaProperty")}var s=this.start,r=this.startLoc;return t.callee=this.parseSubscripts(this.parseExprAtom(null,!1,!0),s,r,!0,!1),this.eat(n.parenL)?t.arguments=this.parseExprList(n.parenR,this.options.ecmaVersion>=8,!1):t.arguments=ss,this.finishNode(t,"NewExpression")},x.parseTemplateElement=function(t){var e=t.isTagged,i=this.startNode();return this.type===n.invalidTemplate?(e||this.raiseRecoverable(this.start,"Bad escape sequence in untagged template literal"),i.value={raw:this.value.replace(/\r\n?/g,`
12
+ `),cooked:null}):i.value={raw:this.input.slice(this.start,this.end).replace(/\r\n?/g,`
13
+ `),cooked:this.value},this.next(),i.tail=this.type===n.backQuote,this.finishNode(i,"TemplateElement")},x.parseTemplate=function(t){t===void 0&&(t={});var e=t.isTagged;e===void 0&&(e=!1);var i=this.startNode();this.next(),i.expressions=[];var s=this.parseTemplateElement({isTagged:e});for(i.quasis=[s];!s.tail;)this.type===n.eof&&this.raise(this.pos,"Unterminated template literal"),this.expect(n.dollarBraceL),i.expressions.push(this.parseExpression()),this.expect(n.braceR),i.quasis.push(s=this.parseTemplateElement({isTagged:e}));return this.next(),this.finishNode(i,"TemplateLiteral")},x.isAsyncProp=function(t){return!t.computed&&t.key.type==="Identifier"&&t.key.name==="async"&&(this.type===n.name||this.type===n.num||this.type===n.string||this.type===n.bracketL||this.type.keyword||this.options.ecmaVersion>=9&&this.type===n.star)&&!M.test(this.input.slice(this.lastTokEnd,this.start))},x.parseObj=function(t,e){var i=this.startNode(),s=!0,r={};for(i.properties=[],this.next();!this.eat(n.braceR);){if(s)s=!1;else if(this.expect(n.comma),this.options.ecmaVersion>=5&&this.afterTrailingComma(n.braceR))break;var a=this.parseProperty(t,e);t||this.checkPropClash(a,r,e),i.properties.push(a)}return this.finishNode(i,t?"ObjectPattern":"ObjectExpression")},x.parseProperty=function(t,e){var i,s,r,a,o=this.startNode();if(this.options.ecmaVersion>=9&&this.eat(n.ellipsis))return t?(o.argument=this.parseIdent(!1),this.type===n.comma&&this.raiseRecoverable(this.start,"Comma is not permitted after the rest element"),this.finishNode(o,"RestElement")):(o.argument=this.parseMaybeAssign(!1,e),this.type===n.comma&&e&&e.trailingComma<0&&(e.trailingComma=this.start),this.finishNode(o,"SpreadElement"));this.options.ecmaVersion>=6&&(o.method=!1,o.shorthand=!1,(t||e)&&(r=this.start,a=this.startLoc),t||(i=this.eat(n.star)));var h=this.containsEsc;return this.parsePropertyName(o),!t&&!h&&this.options.ecmaVersion>=8&&!i&&this.isAsyncProp(o)?(s=!0,i=this.options.ecmaVersion>=9&&this.eat(n.star),this.parsePropertyName(o)):s=!1,this.parsePropertyValue(o,t,i,s,r,a,e,h),this.finishNode(o,"Property")},x.parseGetterSetter=function(t){var e=t.key.name;this.parsePropertyName(t),t.value=this.parseMethod(!1),t.kind=e;var i=t.kind==="get"?0:1;if(t.value.params.length!==i){var s=t.value.start;t.kind==="get"?this.raiseRecoverable(s,"getter should have no params"):this.raiseRecoverable(s,"setter should have exactly one param")}else t.kind==="set"&&t.value.params[0].type==="RestElement"&&this.raiseRecoverable(t.value.params[0].start,"Setter cannot use rest params")},x.parsePropertyValue=function(t,e,i,s,r,a,o,h){(i||s)&&this.type===n.colon&&this.unexpected(),this.eat(n.colon)?(t.value=e?this.parseMaybeDefault(this.start,this.startLoc):this.parseMaybeAssign(!1,o),t.kind="init"):this.options.ecmaVersion>=6&&this.type===n.parenL?(e&&this.unexpected(),t.method=!0,t.value=this.parseMethod(i,s),t.kind="init"):e||h||!(this.options.ecmaVersion>=5)||t.computed||t.key.type!=="Identifier"||t.key.name!=="get"&&t.key.name!=="set"||this.type===n.comma||this.type===n.braceR||this.type===n.eq?this.options.ecmaVersion>=6&&!t.computed&&t.key.type==="Identifier"?((i||s)&&this.unexpected(),this.checkUnreserved(t.key),t.key.name!=="await"||this.awaitIdentPos||(this.awaitIdentPos=r),e?t.value=this.parseMaybeDefault(r,a,this.copyNode(t.key)):this.type===n.eq&&o?(o.shorthandAssign<0&&(o.shorthandAssign=this.start),t.value=this.parseMaybeDefault(r,a,this.copyNode(t.key))):t.value=this.copyNode(t.key),t.kind="init",t.shorthand=!0):this.unexpected():((i||s)&&this.unexpected(),this.parseGetterSetter(t))},x.parsePropertyName=function(t){if(this.options.ecmaVersion>=6){if(this.eat(n.bracketL))return t.computed=!0,t.key=this.parseMaybeAssign(),this.expect(n.bracketR),t.key;t.computed=!1}return t.key=this.type===n.num||this.type===n.string?this.parseExprAtom():this.parseIdent(this.options.allowReserved!=="never")},x.initFunction=function(t){t.id=null,this.options.ecmaVersion>=6&&(t.generator=t.expression=!1),this.options.ecmaVersion>=8&&(t.async=!1)},x.parseMethod=function(t,e,i){var s=this.startNode(),r=this.yieldPos,a=this.awaitPos,o=this.awaitIdentPos;return this.initFunction(s),this.options.ecmaVersion>=6&&(s.generator=t),this.options.ecmaVersion>=8&&(s.async=!!e),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,this.enterScope(64|Qt(e,s.generator)|(i?128:0)),this.expect(n.parenL),s.params=this.parseBindingList(n.parenR,!1,this.options.ecmaVersion>=8),this.checkYieldAwaitInDefaultParams(),this.parseFunctionBody(s,!1,!0,!1),this.yieldPos=r,this.awaitPos=a,this.awaitIdentPos=o,this.finishNode(s,"FunctionExpression")},x.parseArrowExpression=function(t,e,i,s){var r=this.yieldPos,a=this.awaitPos,o=this.awaitIdentPos;return this.enterScope(16|Qt(i,!1)),this.initFunction(t),this.options.ecmaVersion>=8&&(t.async=!!i),this.yieldPos=0,this.awaitPos=0,this.awaitIdentPos=0,t.params=this.toAssignableList(e,!0),this.parseFunctionBody(t,!0,!1,s),this.yieldPos=r,this.awaitPos=a,this.awaitIdentPos=o,this.finishNode(t,"ArrowFunctionExpression")},x.parseFunctionBody=function(t,e,i,s){var r=e&&this.type!==n.braceL,a=this.strict,o=!1;if(r)t.body=this.parseMaybeAssign(s),t.expression=!0,this.checkParams(t,!1);else{var h=this.options.ecmaVersion>=7&&!this.isSimpleParamList(t.params);a&&!h||(o=this.strictDirective(this.end))&&h&&this.raiseRecoverable(t.start,"Illegal 'use strict' directive in function with non-simple parameter list");var c=this.labels;this.labels=[],o&&(this.strict=!0),this.checkParams(t,!a&&!o&&!e&&!i&&this.isSimpleParamList(t.params)),this.strict&&t.id&&this.checkLValSimple(t.id,5),t.body=this.parseBlock(!1,void 0,o&&!a),t.expression=!1,this.adaptDirectivePrologue(t.body.body),this.labels=c}this.exitScope()},x.isSimpleParamList=function(t){for(var e=0,i=t;e<i.length;e+=1)if(i[e].type!=="Identifier")return!1;return!0},x.checkParams=function(t,e){for(var i=Object.create(null),s=0,r=t.params;s<r.length;s+=1){var a=r[s];this.checkLValInnerPattern(a,1,e?null:i)}},x.parseExprList=function(t,e,i,s){for(var r=[],a=!0;!this.eat(t);){if(a)a=!1;else if(this.expect(n.comma),e&&this.afterTrailingComma(t))break;var o=void 0;i&&this.type===n.comma?o=null:this.type===n.ellipsis?(o=this.parseSpread(s),s&&this.type===n.comma&&s.trailingComma<0&&(s.trailingComma=this.start)):o=this.parseMaybeAssign(!1,s),r.push(o)}return r},x.checkUnreserved=function(t){var e=t.start,i=t.end,s=t.name;this.inGenerator&&s==="yield"&&this.raiseRecoverable(e,"Cannot use 'yield' as identifier inside a generator"),this.inAsync&&s==="await"&&this.raiseRecoverable(e,"Cannot use 'await' as identifier inside an async function"),this.currentThisScope().flags&Pe||s!=="arguments"||this.raiseRecoverable(e,"Cannot use 'arguments' in class field initializer"),!this.inClassStaticBlock||s!=="arguments"&&s!=="await"||this.raise(e,"Cannot use "+s+" in class static initialization block"),this.keywords.test(s)&&this.raise(e,"Unexpected keyword '"+s+"'"),this.options.ecmaVersion<6&&this.input.slice(e,i).indexOf("\\")!==-1||(this.strict?this.reservedWordsStrict:this.reservedWords).test(s)&&(this.inAsync||s!=="await"||this.raiseRecoverable(e,"Cannot use keyword 'await' outside an async function"),this.raiseRecoverable(e,"The keyword '"+s+"' is reserved"))},x.parseIdent=function(t){var e=this.parseIdentNode();return this.next(!!t),this.finishNode(e,"Identifier"),t||(this.checkUnreserved(e),e.name!=="await"||this.awaitIdentPos||(this.awaitIdentPos=e.start)),e},x.parseIdentNode=function(){var t=this.startNode();return this.type===n.name?t.name=this.value:this.type.keyword?(t.name=this.type.keyword,t.name!=="class"&&t.name!=="function"||this.lastTokEnd===this.lastTokStart+1&&this.input.charCodeAt(this.lastTokStart)===46||this.context.pop(),this.type=n.name):this.unexpected(),t},x.parsePrivateIdent=function(){var t=this.startNode();return this.type===n.privateId?t.name=this.value:this.unexpected(),this.next(),this.finishNode(t,"PrivateIdentifier"),this.options.checkPrivateFields&&(this.privateNameStack.length===0?this.raise(t.start,"Private field '#"+t.name+"' must be declared in an enclosing class"):this.privateNameStack[this.privateNameStack.length-1].used.push(t)),t},x.parseYield=function(t){this.yieldPos||(this.yieldPos=this.start);var e=this.startNode();return this.next(),this.type===n.semi||this.canInsertSemicolon()||this.type!==n.star&&!this.type.startsExpr?(e.delegate=!1,e.argument=null):(e.delegate=this.eat(n.star),e.argument=this.parseMaybeAssign(t)),this.finishNode(e,"YieldExpression")},x.parseAwait=function(t){this.awaitPos||(this.awaitPos=this.start);var e=this.startNode();return this.next(),e.argument=this.parseMaybeUnary(null,!0,!1,t),this.finishNode(e,"AwaitExpression")};var Ot=N.prototype;Ot.raise=function(t,e){var i=Ae(this.input,t);e+=" ("+i.line+":"+i.column+")",this.sourceFile&&(e+=" in "+this.sourceFile);var s=new SyntaxError(e);throw s.pos=t,s.loc=i,s.raisedAt=this.pos,s},Ot.raiseRecoverable=Ot.raise,Ot.curPosition=function(){if(this.options.locations)return new St(this.curLine,this.pos-this.lineStart)};var et=N.prototype,rs=function(t){this.flags=t,this.var=[],this.lexical=[],this.functions=[]};et.enterScope=function(t){this.scopeStack.push(new rs(t))},et.exitScope=function(){this.scopeStack.pop()},et.treatFunctionsAsVarInScope=function(t){return 2&t.flags||!this.inModule&&1&t.flags},et.declareName=function(t,e,i){var s=!1;if(e===2){var r=this.currentScope();s=r.lexical.indexOf(t)>-1||r.functions.indexOf(t)>-1||r.var.indexOf(t)>-1,r.lexical.push(t),this.inModule&&1&r.flags&&delete this.undefinedExports[t]}else if(e===4)this.currentScope().lexical.push(t);else if(e===3){var a=this.currentScope();s=this.treatFunctionsAsVar?a.lexical.indexOf(t)>-1:a.lexical.indexOf(t)>-1||a.var.indexOf(t)>-1,a.functions.push(t)}else for(var o=this.scopeStack.length-1;o>=0;--o){var h=this.scopeStack[o];if(h.lexical.indexOf(t)>-1&&!(32&h.flags&&h.lexical[0]===t)||!this.treatFunctionsAsVarInScope(h)&&h.functions.indexOf(t)>-1){s=!0;break}if(h.var.push(t),this.inModule&&1&h.flags&&delete this.undefinedExports[t],h.flags&Pe)break}s&&this.raiseRecoverable(i,"Identifier '"+t+"' has already been declared")},et.checkLocalExport=function(t){this.scopeStack[0].lexical.indexOf(t.name)===-1&&this.scopeStack[0].var.indexOf(t.name)===-1&&(this.undefinedExports[t.name]=t)},et.currentScope=function(){return this.scopeStack[this.scopeStack.length-1]},et.currentVarScope=function(){for(var t=this.scopeStack.length-1;;t--){var e=this.scopeStack[t];if(771&e.flags)return e}},et.currentThisScope=function(){for(var t=this.scopeStack.length-1;;t--){var e=this.scopeStack[t];if(771&e.flags&&!(16&e.flags))return e}};var Dt=function(t,e,i){this.type="",this.start=e,this.end=0,t.options.locations&&(this.loc=new Pt(t,i)),t.options.directSourceFile&&(this.sourceFile=t.options.directSourceFile),t.options.ranges&&(this.range=[e,0])},It=N.prototype;function Le(t,e,i,s){return t.type=e,t.end=i,this.options.locations&&(t.loc.end=s),this.options.ranges&&(t.range[1]=i),t}It.startNode=function(){return new Dt(this,this.start,this.startLoc)},It.startNodeAt=function(t,e){return new Dt(this,t,e)},It.finishNode=function(t,e){return Le.call(this,t,e,this.lastTokEnd,this.lastTokEndLoc)},It.finishNodeAt=function(t,e,i,s){return Le.call(this,t,e,i,s)},It.copyNode=function(t){var e=new Dt(this,t.start,this.startLoc);for(var i in t)e[i]=t[i];return e};var Oe="ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS",ee=Oe+" Extended_Pictographic",ie=ee+" EBase EComp EMod EPres ExtPict",ns={9:Oe,10:ee,11:ee,12:ie,13:ie,14:ie},as={9:"",10:"",11:"",12:"",13:"",14:"Basic_Emoji Emoji_Keycap_Sequence RGI_Emoji_Modifier_Sequence RGI_Emoji_Flag_Sequence RGI_Emoji_Tag_Sequence RGI_Emoji_ZWJ_Sequence RGI_Emoji"},De="Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu",Ve="Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb",Ue=Ve+" Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd",Me=Ue+" Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho",je=Me+" Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi",Be=je+" Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith",os={9:Ve,10:Ue,11:Me,12:je,13:Be,14:Be+" Gara Garay Gukh Gurung_Khema Hrkt Katakana_Or_Hiragana Kawi Kirat_Rai Krai Nag_Mundari Nagm Ol_Onal Onao Sunu Sunuwar Todhri Todr Tulu_Tigalari Tutg Unknown Zzzz"},Fe={};function hs(t){var e=Fe[t]={binary:tt(ns[t]+" "+De),binaryOfStrings:tt(as[t]),nonBinary:{General_Category:tt(De),Script:tt(os[t])}};e.nonBinary.Script_Extensions=e.nonBinary.Script,e.nonBinary.gc=e.nonBinary.General_Category,e.nonBinary.sc=e.nonBinary.Script,e.nonBinary.scx=e.nonBinary.Script_Extensions}for(var se=0,$e=[9,10,11,12,13,14];se<$e.length;se+=1)hs($e[se]);var d=N.prototype,Vt=function(t,e){this.parent=t,this.base=e||this};Vt.prototype.separatedFrom=function(t){for(var e=this;e;e=e.parent)for(var i=t;i;i=i.parent)if(e.base===i.base&&e!==i)return!0;return!1},Vt.prototype.sibling=function(){return new Vt(this.parent,this.base)};var J=function(t){this.parser=t,this.validFlags="gim"+(t.options.ecmaVersion>=6?"uy":"")+(t.options.ecmaVersion>=9?"s":"")+(t.options.ecmaVersion>=13?"d":"")+(t.options.ecmaVersion>=15?"v":""),this.unicodeProperties=Fe[t.options.ecmaVersion>=14?14:t.options.ecmaVersion],this.source="",this.flags="",this.start=0,this.switchU=!1,this.switchV=!1,this.switchN=!1,this.pos=0,this.lastIntValue=0,this.lastStringValue="",this.lastAssertionIsQuantifiable=!1,this.numCapturingParens=0,this.maxBackReference=0,this.groupNames=Object.create(null),this.backReferenceNames=[],this.branchID=null};function cs(t){return t===105||t===109||t===115}function qe(t){return t===36||t>=40&&t<=43||t===46||t===63||t>=91&&t<=94||t>=123&&t<=125}function We(t){return t>=65&&t<=90||t>=97&&t<=122}J.prototype.reset=function(t,e,i){var s=i.indexOf("v")!==-1,r=i.indexOf("u")!==-1;this.start=0|t,this.source=e+"",this.flags=i,s&&this.parser.options.ecmaVersion>=15?(this.switchU=!0,this.switchV=!0,this.switchN=!0):(this.switchU=r&&this.parser.options.ecmaVersion>=6,this.switchV=!1,this.switchN=r&&this.parser.options.ecmaVersion>=9)},J.prototype.raise=function(t){this.parser.raiseRecoverable(this.start,"Invalid regular expression: /"+this.source+"/: "+t)},J.prototype.at=function(t,e){e===void 0&&(e=!1);var i=this.source,s=i.length;if(t>=s)return-1;var r=i.charCodeAt(t);if(!e&&!this.switchU||r<=55295||r>=57344||t+1>=s)return r;var a=i.charCodeAt(t+1);return a>=56320&&a<=57343?(r<<10)+a-56613888:r},J.prototype.nextIndex=function(t,e){e===void 0&&(e=!1);var i=this.source,s=i.length;if(t>=s)return s;var r,a=i.charCodeAt(t);return!e&&!this.switchU||a<=55295||a>=57344||t+1>=s||(r=i.charCodeAt(t+1))<56320||r>57343?t+1:t+2},J.prototype.current=function(t){return t===void 0&&(t=!1),this.at(this.pos,t)},J.prototype.lookahead=function(t){return t===void 0&&(t=!1),this.at(this.nextIndex(this.pos,t),t)},J.prototype.advance=function(t){t===void 0&&(t=!1),this.pos=this.nextIndex(this.pos,t)},J.prototype.eat=function(t,e){return e===void 0&&(e=!1),this.current(e)===t&&(this.advance(e),!0)},J.prototype.eatChars=function(t,e){e===void 0&&(e=!1);for(var i=this.pos,s=0,r=t;s<r.length;s+=1){var a=r[s],o=this.at(i,e);if(o===-1||o!==a)return!1;i=this.nextIndex(i,e)}return this.pos=i,!0},d.validateRegExpFlags=function(t){for(var e=t.validFlags,i=t.flags,s=!1,r=!1,a=0;a<i.length;a++){var o=i.charAt(a);e.indexOf(o)===-1&&this.raise(t.start,"Invalid regular expression flag"),i.indexOf(o,a+1)>-1&&this.raise(t.start,"Duplicate regular expression flag"),o==="u"&&(s=!0),o==="v"&&(r=!0)}this.options.ecmaVersion>=15&&s&&r&&this.raise(t.start,"Invalid regular expression flag")},d.validateRegExpPattern=function(t){this.regexp_pattern(t),!t.switchN&&this.options.ecmaVersion>=9&&(function(e){for(var i in e)return!0;return!1})(t.groupNames)&&(t.switchN=!0,this.regexp_pattern(t))},d.regexp_pattern=function(t){t.pos=0,t.lastIntValue=0,t.lastStringValue="",t.lastAssertionIsQuantifiable=!1,t.numCapturingParens=0,t.maxBackReference=0,t.groupNames=Object.create(null),t.backReferenceNames.length=0,t.branchID=null,this.regexp_disjunction(t),t.pos!==t.source.length&&(t.eat(41)&&t.raise("Unmatched ')'"),(t.eat(93)||t.eat(125))&&t.raise("Lone quantifier brackets")),t.maxBackReference>t.numCapturingParens&&t.raise("Invalid escape");for(var e=0,i=t.backReferenceNames;e<i.length;e+=1){var s=i[e];t.groupNames[s]||t.raise("Invalid named capture referenced")}},d.regexp_disjunction=function(t){var e=this.options.ecmaVersion>=16;for(e&&(t.branchID=new Vt(t.branchID,null)),this.regexp_alternative(t);t.eat(124);)e&&(t.branchID=t.branchID.sibling()),this.regexp_alternative(t);e&&(t.branchID=t.branchID.parent),this.regexp_eatQuantifier(t,!0)&&t.raise("Nothing to repeat"),t.eat(123)&&t.raise("Lone quantifier brackets")},d.regexp_alternative=function(t){for(;t.pos<t.source.length&&this.regexp_eatTerm(t););},d.regexp_eatTerm=function(t){return this.regexp_eatAssertion(t)?(t.lastAssertionIsQuantifiable&&this.regexp_eatQuantifier(t)&&t.switchU&&t.raise("Invalid quantifier"),!0):!!(t.switchU?this.regexp_eatAtom(t):this.regexp_eatExtendedAtom(t))&&(this.regexp_eatQuantifier(t),!0)},d.regexp_eatAssertion=function(t){var e=t.pos;if(t.lastAssertionIsQuantifiable=!1,t.eat(94)||t.eat(36))return!0;if(t.eat(92)){if(t.eat(66)||t.eat(98))return!0;t.pos=e}if(t.eat(40)&&t.eat(63)){var i=!1;if(this.options.ecmaVersion>=9&&(i=t.eat(60)),t.eat(61)||t.eat(33))return this.regexp_disjunction(t),t.eat(41)||t.raise("Unterminated group"),t.lastAssertionIsQuantifiable=!i,!0}return t.pos=e,!1},d.regexp_eatQuantifier=function(t,e){return e===void 0&&(e=!1),!!this.regexp_eatQuantifierPrefix(t,e)&&(t.eat(63),!0)},d.regexp_eatQuantifierPrefix=function(t,e){return t.eat(42)||t.eat(43)||t.eat(63)||this.regexp_eatBracedQuantifier(t,e)},d.regexp_eatBracedQuantifier=function(t,e){var i=t.pos;if(t.eat(123)){var s=0,r=-1;if(this.regexp_eatDecimalDigits(t)&&(s=t.lastIntValue,t.eat(44)&&this.regexp_eatDecimalDigits(t)&&(r=t.lastIntValue),t.eat(125)))return r!==-1&&r<s&&!e&&t.raise("numbers out of order in {} quantifier"),!0;t.switchU&&!e&&t.raise("Incomplete quantifier"),t.pos=i}return!1},d.regexp_eatAtom=function(t){return this.regexp_eatPatternCharacters(t)||t.eat(46)||this.regexp_eatReverseSolidusAtomEscape(t)||this.regexp_eatCharacterClass(t)||this.regexp_eatUncapturingGroup(t)||this.regexp_eatCapturingGroup(t)},d.regexp_eatReverseSolidusAtomEscape=function(t){var e=t.pos;if(t.eat(92)){if(this.regexp_eatAtomEscape(t))return!0;t.pos=e}return!1},d.regexp_eatUncapturingGroup=function(t){var e=t.pos;if(t.eat(40)){if(t.eat(63)){if(this.options.ecmaVersion>=16){var i=this.regexp_eatModifiers(t),s=t.eat(45);if(i||s){for(var r=0;r<i.length;r++){var a=i.charAt(r);i.indexOf(a,r+1)>-1&&t.raise("Duplicate regular expression modifiers")}if(s){var o=this.regexp_eatModifiers(t);i||o||t.current()!==58||t.raise("Invalid regular expression modifiers");for(var h=0;h<o.length;h++){var c=o.charAt(h);(o.indexOf(c,h+1)>-1||i.indexOf(c)>-1)&&t.raise("Duplicate regular expression modifiers")}}}}if(t.eat(58)){if(this.regexp_disjunction(t),t.eat(41))return!0;t.raise("Unterminated group")}}t.pos=e}return!1},d.regexp_eatCapturingGroup=function(t){if(t.eat(40)){if(this.options.ecmaVersion>=9?this.regexp_groupSpecifier(t):t.current()===63&&t.raise("Invalid group"),this.regexp_disjunction(t),t.eat(41))return t.numCapturingParens+=1,!0;t.raise("Unterminated group")}return!1},d.regexp_eatModifiers=function(t){for(var e="",i=0;(i=t.current())!==-1&&cs(i);)e+=Q(i),t.advance();return e},d.regexp_eatExtendedAtom=function(t){return t.eat(46)||this.regexp_eatReverseSolidusAtomEscape(t)||this.regexp_eatCharacterClass(t)||this.regexp_eatUncapturingGroup(t)||this.regexp_eatCapturingGroup(t)||this.regexp_eatInvalidBracedQuantifier(t)||this.regexp_eatExtendedPatternCharacter(t)},d.regexp_eatInvalidBracedQuantifier=function(t){return this.regexp_eatBracedQuantifier(t,!0)&&t.raise("Nothing to repeat"),!1},d.regexp_eatSyntaxCharacter=function(t){var e=t.current();return!!qe(e)&&(t.lastIntValue=e,t.advance(),!0)},d.regexp_eatPatternCharacters=function(t){for(var e=t.pos,i=0;(i=t.current())!==-1&&!qe(i);)t.advance();return t.pos!==e},d.regexp_eatExtendedPatternCharacter=function(t){var e=t.current();return!(e===-1||e===36||e>=40&&e<=43||e===46||e===63||e===91||e===94||e===124)&&(t.advance(),!0)},d.regexp_groupSpecifier=function(t){if(t.eat(63)){this.regexp_eatGroupName(t)||t.raise("Invalid group");var e=this.options.ecmaVersion>=16,i=t.groupNames[t.lastStringValue];if(i)if(e)for(var s=0,r=i;s<r.length;s+=1)r[s].separatedFrom(t.branchID)||t.raise("Duplicate capture group name");else t.raise("Duplicate capture group name");e?(i||(t.groupNames[t.lastStringValue]=[])).push(t.branchID):t.groupNames[t.lastStringValue]=!0}},d.regexp_eatGroupName=function(t){if(t.lastStringValue="",t.eat(60)){if(this.regexp_eatRegExpIdentifierName(t)&&t.eat(62))return!0;t.raise("Invalid capture group name")}return!1},d.regexp_eatRegExpIdentifierName=function(t){if(t.lastStringValue="",this.regexp_eatRegExpIdentifierStart(t)){for(t.lastStringValue+=Q(t.lastIntValue);this.regexp_eatRegExpIdentifierPart(t);)t.lastStringValue+=Q(t.lastIntValue);return!0}return!1},d.regexp_eatRegExpIdentifierStart=function(t){var e=t.pos,i=this.options.ecmaVersion>=11,s=t.current(i);return t.advance(i),s===92&&this.regexp_eatRegExpUnicodeEscapeSequence(t,i)&&(s=t.lastIntValue),(function(r){return K(r,!0)||r===36||r===95})(s)?(t.lastIntValue=s,!0):(t.pos=e,!1)},d.regexp_eatRegExpIdentifierPart=function(t){var e=t.pos,i=this.options.ecmaVersion>=11,s=t.current(i);return t.advance(i),s===92&&this.regexp_eatRegExpUnicodeEscapeSequence(t,i)&&(s=t.lastIntValue),(function(r){return X(r,!0)||r===36||r===95||r===8204||r===8205})(s)?(t.lastIntValue=s,!0):(t.pos=e,!1)},d.regexp_eatAtomEscape=function(t){return!!(this.regexp_eatBackReference(t)||this.regexp_eatCharacterClassEscape(t)||this.regexp_eatCharacterEscape(t)||t.switchN&&this.regexp_eatKGroupName(t))||(t.switchU&&(t.current()===99&&t.raise("Invalid unicode escape"),t.raise("Invalid escape")),!1)},d.regexp_eatBackReference=function(t){var e=t.pos;if(this.regexp_eatDecimalEscape(t)){var i=t.lastIntValue;if(t.switchU)return i>t.maxBackReference&&(t.maxBackReference=i),!0;if(i<=t.numCapturingParens)return!0;t.pos=e}return!1},d.regexp_eatKGroupName=function(t){if(t.eat(107)){if(this.regexp_eatGroupName(t))return t.backReferenceNames.push(t.lastStringValue),!0;t.raise("Invalid named reference")}return!1},d.regexp_eatCharacterEscape=function(t){return this.regexp_eatControlEscape(t)||this.regexp_eatCControlLetter(t)||this.regexp_eatZero(t)||this.regexp_eatHexEscapeSequence(t)||this.regexp_eatRegExpUnicodeEscapeSequence(t,!1)||!t.switchU&&this.regexp_eatLegacyOctalEscapeSequence(t)||this.regexp_eatIdentityEscape(t)},d.regexp_eatCControlLetter=function(t){var e=t.pos;if(t.eat(99)){if(this.regexp_eatControlLetter(t))return!0;t.pos=e}return!1},d.regexp_eatZero=function(t){return t.current()===48&&!Ut(t.lookahead())&&(t.lastIntValue=0,t.advance(),!0)},d.regexp_eatControlEscape=function(t){var e=t.current();return e===116?(t.lastIntValue=9,t.advance(),!0):e===110?(t.lastIntValue=10,t.advance(),!0):e===118?(t.lastIntValue=11,t.advance(),!0):e===102?(t.lastIntValue=12,t.advance(),!0):e===114&&(t.lastIntValue=13,t.advance(),!0)},d.regexp_eatControlLetter=function(t){var e=t.current();return!!We(e)&&(t.lastIntValue=e%32,t.advance(),!0)},d.regexp_eatRegExpUnicodeEscapeSequence=function(t,e){e===void 0&&(e=!1);var i,s=t.pos,r=e||t.switchU;if(t.eat(117)){if(this.regexp_eatFixedHexDigits(t,4)){var a=t.lastIntValue;if(r&&a>=55296&&a<=56319){var o=t.pos;if(t.eat(92)&&t.eat(117)&&this.regexp_eatFixedHexDigits(t,4)){var h=t.lastIntValue;if(h>=56320&&h<=57343)return t.lastIntValue=1024*(a-55296)+(h-56320)+65536,!0}t.pos=o,t.lastIntValue=a}return!0}if(r&&t.eat(123)&&this.regexp_eatHexDigits(t)&&t.eat(125)&&(i=t.lastIntValue)>=0&&i<=1114111)return!0;r&&t.raise("Invalid unicode escape"),t.pos=s}return!1},d.regexp_eatIdentityEscape=function(t){if(t.switchU)return!!this.regexp_eatSyntaxCharacter(t)||!!t.eat(47)&&(t.lastIntValue=47,!0);var e=t.current();return!(e===99||t.switchN&&e===107)&&(t.lastIntValue=e,t.advance(),!0)},d.regexp_eatDecimalEscape=function(t){t.lastIntValue=0;var e=t.current();if(e>=49&&e<=57){do t.lastIntValue=10*t.lastIntValue+(e-48),t.advance();while((e=t.current())>=48&&e<=57);return!0}return!1};function Ge(t){return We(t)||t===95}function ps(t){return Ge(t)||Ut(t)}function Ut(t){return t>=48&&t<=57}function He(t){return t>=48&&t<=57||t>=65&&t<=70||t>=97&&t<=102}function Ke(t){return t>=65&&t<=70?t-65+10:t>=97&&t<=102?t-97+10:t-48}function ze(t){return t>=48&&t<=55}d.regexp_eatCharacterClassEscape=function(t){var e=t.current();if((function(r){return r===100||r===68||r===115||r===83||r===119||r===87})(e))return t.lastIntValue=-1,t.advance(),1;var i=!1;if(t.switchU&&this.options.ecmaVersion>=9&&((i=e===80)||e===112)){var s;if(t.lastIntValue=-1,t.advance(),t.eat(123)&&(s=this.regexp_eatUnicodePropertyValueExpression(t))&&t.eat(125))return i&&s===2&&t.raise("Invalid property name"),s;t.raise("Invalid property name")}return 0},d.regexp_eatUnicodePropertyValueExpression=function(t){var e=t.pos;if(this.regexp_eatUnicodePropertyName(t)&&t.eat(61)){var i=t.lastStringValue;if(this.regexp_eatUnicodePropertyValue(t)){var s=t.lastStringValue;return this.regexp_validateUnicodePropertyNameAndValue(t,i,s),1}}if(t.pos=e,this.regexp_eatLoneUnicodePropertyNameOrValue(t)){var r=t.lastStringValue;return this.regexp_validateUnicodePropertyNameOrValue(t,r)}return 0},d.regexp_validateUnicodePropertyNameAndValue=function(t,e,i){ft(t.unicodeProperties.nonBinary,e)||t.raise("Invalid property name"),t.unicodeProperties.nonBinary[e].test(i)||t.raise("Invalid property value")},d.regexp_validateUnicodePropertyNameOrValue=function(t,e){return t.unicodeProperties.binary.test(e)?1:t.switchV&&t.unicodeProperties.binaryOfStrings.test(e)?2:void t.raise("Invalid property name")},d.regexp_eatUnicodePropertyName=function(t){var e=0;for(t.lastStringValue="";Ge(e=t.current());)t.lastStringValue+=Q(e),t.advance();return t.lastStringValue!==""},d.regexp_eatUnicodePropertyValue=function(t){var e=0;for(t.lastStringValue="";ps(e=t.current());)t.lastStringValue+=Q(e),t.advance();return t.lastStringValue!==""},d.regexp_eatLoneUnicodePropertyNameOrValue=function(t){return this.regexp_eatUnicodePropertyValue(t)},d.regexp_eatCharacterClass=function(t){if(t.eat(91)){var e=t.eat(94),i=this.regexp_classContents(t);return t.eat(93)||t.raise("Unterminated character class"),e&&i===2&&t.raise("Negated character class may contain strings"),!0}return!1},d.regexp_classContents=function(t){return t.current()===93?1:t.switchV?this.regexp_classSetExpression(t):(this.regexp_nonEmptyClassRanges(t),1)},d.regexp_nonEmptyClassRanges=function(t){for(;this.regexp_eatClassAtom(t);){var e=t.lastIntValue;if(t.eat(45)&&this.regexp_eatClassAtom(t)){var i=t.lastIntValue;!t.switchU||e!==-1&&i!==-1||t.raise("Invalid character class"),e!==-1&&i!==-1&&e>i&&t.raise("Range out of order in character class")}}},d.regexp_eatClassAtom=function(t){var e=t.pos;if(t.eat(92)){if(this.regexp_eatClassEscape(t))return!0;if(t.switchU){var i=t.current();(i===99||ze(i))&&t.raise("Invalid class escape"),t.raise("Invalid escape")}t.pos=e}var s=t.current();return s!==93&&(t.lastIntValue=s,t.advance(),!0)},d.regexp_eatClassEscape=function(t){var e=t.pos;if(t.eat(98))return t.lastIntValue=8,!0;if(t.switchU&&t.eat(45))return t.lastIntValue=45,!0;if(!t.switchU&&t.eat(99)){if(this.regexp_eatClassControlLetter(t))return!0;t.pos=e}return this.regexp_eatCharacterClassEscape(t)||this.regexp_eatCharacterEscape(t)},d.regexp_classSetExpression=function(t){var e,i=1;if(!this.regexp_eatClassSetRange(t))if(e=this.regexp_eatClassSetOperand(t)){e===2&&(i=2);for(var s=t.pos;t.eatChars([38,38]);)t.current()!==38&&(e=this.regexp_eatClassSetOperand(t))?e!==2&&(i=1):t.raise("Invalid character in character class");if(s!==t.pos)return i;for(;t.eatChars([45,45]);)this.regexp_eatClassSetOperand(t)||t.raise("Invalid character in character class");if(s!==t.pos)return i}else t.raise("Invalid character in character class");for(;;)if(!this.regexp_eatClassSetRange(t)){if(!(e=this.regexp_eatClassSetOperand(t)))return i;e===2&&(i=2)}},d.regexp_eatClassSetRange=function(t){var e=t.pos;if(this.regexp_eatClassSetCharacter(t)){var i=t.lastIntValue;if(t.eat(45)&&this.regexp_eatClassSetCharacter(t)){var s=t.lastIntValue;return i!==-1&&s!==-1&&i>s&&t.raise("Range out of order in character class"),!0}t.pos=e}return!1},d.regexp_eatClassSetOperand=function(t){return this.regexp_eatClassSetCharacter(t)?1:this.regexp_eatClassStringDisjunction(t)||this.regexp_eatNestedClass(t)},d.regexp_eatNestedClass=function(t){var e=t.pos;if(t.eat(91)){var i=t.eat(94),s=this.regexp_classContents(t);if(t.eat(93))return i&&s===2&&t.raise("Negated character class may contain strings"),s;t.pos=e}if(t.eat(92)){var r=this.regexp_eatCharacterClassEscape(t);if(r)return r;t.pos=e}return null},d.regexp_eatClassStringDisjunction=function(t){var e=t.pos;if(t.eatChars([92,113])){if(t.eat(123)){var i=this.regexp_classStringDisjunctionContents(t);if(t.eat(125))return i}else t.raise("Invalid escape");t.pos=e}return null},d.regexp_classStringDisjunctionContents=function(t){for(var e=this.regexp_classString(t);t.eat(124);)this.regexp_classString(t)===2&&(e=2);return e},d.regexp_classString=function(t){for(var e=0;this.regexp_eatClassSetCharacter(t);)e++;return e===1?1:2},d.regexp_eatClassSetCharacter=function(t){var e=t.pos;if(t.eat(92))return!(!this.regexp_eatCharacterEscape(t)&&!this.regexp_eatClassSetReservedPunctuator(t))||(t.eat(98)?(t.lastIntValue=8,!0):(t.pos=e,!1));var i=t.current();return!(i<0||i===t.lookahead()&&(function(s){return s===33||s>=35&&s<=38||s>=42&&s<=44||s===46||s>=58&&s<=64||s===94||s===96||s===126})(i))&&!(function(s){return s===40||s===41||s===45||s===47||s>=91&&s<=93||s>=123&&s<=125})(i)&&(t.advance(),t.lastIntValue=i,!0)},d.regexp_eatClassSetReservedPunctuator=function(t){var e=t.current();return!!(function(i){return i===33||i===35||i===37||i===38||i===44||i===45||i>=58&&i<=62||i===64||i===96||i===126})(e)&&(t.lastIntValue=e,t.advance(),!0)},d.regexp_eatClassControlLetter=function(t){var e=t.current();return!(!Ut(e)&&e!==95)&&(t.lastIntValue=e%32,t.advance(),!0)},d.regexp_eatHexEscapeSequence=function(t){var e=t.pos;if(t.eat(120)){if(this.regexp_eatFixedHexDigits(t,2))return!0;t.switchU&&t.raise("Invalid escape"),t.pos=e}return!1},d.regexp_eatDecimalDigits=function(t){var e=t.pos,i=0;for(t.lastIntValue=0;Ut(i=t.current());)t.lastIntValue=10*t.lastIntValue+(i-48),t.advance();return t.pos!==e},d.regexp_eatHexDigits=function(t){var e=t.pos,i=0;for(t.lastIntValue=0;He(i=t.current());)t.lastIntValue=16*t.lastIntValue+Ke(i),t.advance();return t.pos!==e},d.regexp_eatLegacyOctalEscapeSequence=function(t){if(this.regexp_eatOctalDigit(t)){var e=t.lastIntValue;if(this.regexp_eatOctalDigit(t)){var i=t.lastIntValue;e<=3&&this.regexp_eatOctalDigit(t)?t.lastIntValue=64*e+8*i+t.lastIntValue:t.lastIntValue=8*e+i}else t.lastIntValue=e;return!0}return!1},d.regexp_eatOctalDigit=function(t){var e=t.current();return ze(e)?(t.lastIntValue=e-48,t.advance(),!0):(t.lastIntValue=0,!1)},d.regexp_eatFixedHexDigits=function(t,e){var i=t.pos;t.lastIntValue=0;for(var s=0;s<e;++s){var r=t.current();if(!He(r))return t.pos=i,!1;t.lastIntValue=16*t.lastIntValue+Ke(r),t.advance()}return!0};var re=function(t){this.type=t.type,this.value=t.value,this.start=t.start,this.end=t.end,t.options.locations&&(this.loc=new Pt(t,t.startLoc,t.endLoc)),t.options.ranges&&(this.range=[t.start,t.end])},E=N.prototype;function Je(t){return typeof BigInt!="function"?null:BigInt(t.replace(/_/g,""))}E.next=function(t){!t&&this.type.keyword&&this.containsEsc&&this.raiseRecoverable(this.start,"Escape sequence in keyword "+this.type.keyword),this.options.onToken&&this.options.onToken(new re(this)),this.lastTokEnd=this.end,this.lastTokStart=this.start,this.lastTokEndLoc=this.endLoc,this.lastTokStartLoc=this.startLoc,this.nextToken()},E.getToken=function(){return this.next(),new re(this)},typeof Symbol<"u"&&(E[Symbol.iterator]=function(){var t=this;return{next:function(){var e=t.getToken();return{done:e.type===n.eof,value:e}}}}),E.nextToken=function(){var t=this.curContext();return t&&t.preserveSpace||this.skipSpace(),this.start=this.pos,this.options.locations&&(this.startLoc=this.curPosition()),this.pos>=this.input.length?this.finishToken(n.eof):t.override?t.override(this):void this.readToken(this.fullCharCodeAtPos())},E.readToken=function(t){return K(t,this.options.ecmaVersion>=6)||t===92?this.readWord():this.getTokenFromCode(t)},E.fullCharCodeAtPos=function(){var t=this.input.charCodeAt(this.pos);if(t<=55295||t>=56320)return t;var e=this.input.charCodeAt(this.pos+1);return e<=56319||e>=57344?t:(t<<10)+e-56613888},E.skipBlockComment=function(){var t=this.options.onComment&&this.curPosition(),e=this.pos,i=this.input.indexOf("*/",this.pos+=2);if(i===-1&&this.raise(this.pos-2,"Unterminated comment"),this.pos=i+2,this.options.locations)for(var s=void 0,r=e;(s=Ce(this.input,r,this.pos))>-1;)++this.curLine,r=this.lineStart=s;this.options.onComment&&this.options.onComment(!0,this.input.slice(e+2,i),e,this.pos,t,this.curPosition())},E.skipLineComment=function(t){for(var e=this.pos,i=this.options.onComment&&this.curPosition(),s=this.input.charCodeAt(this.pos+=t);this.pos<this.input.length&&!ut(s);)s=this.input.charCodeAt(++this.pos);this.options.onComment&&this.options.onComment(!1,this.input.slice(e+t,this.pos),e,this.pos,i,this.curPosition())},E.skipSpace=function(){t:for(;this.pos<this.input.length;){var t=this.input.charCodeAt(this.pos);switch(t){case 32:case 160:++this.pos;break;case 13:this.input.charCodeAt(this.pos+1)===10&&++this.pos;case 10:case 8232:case 8233:++this.pos,this.options.locations&&(++this.curLine,this.lineStart=this.pos);break;case 47:switch(this.input.charCodeAt(this.pos+1)){case 42:this.skipBlockComment();break;case 47:this.skipLineComment(2);break;default:break t}break;default:if(!(t>8&&t<14||t>=5760&&Ie.test(String.fromCharCode(t))))break t;++this.pos}}},E.finishToken=function(t,e){this.end=this.pos,this.options.locations&&(this.endLoc=this.curPosition());var i=this.type;this.type=t,this.value=e,this.updateContext(i)},E.readToken_dot=function(){var t=this.input.charCodeAt(this.pos+1);if(t>=48&&t<=57)return this.readNumber(!0);var e=this.input.charCodeAt(this.pos+2);return this.options.ecmaVersion>=6&&t===46&&e===46?(this.pos+=3,this.finishToken(n.ellipsis)):(++this.pos,this.finishToken(n.dot))},E.readToken_slash=function(){var t=this.input.charCodeAt(this.pos+1);return this.exprAllowed?(++this.pos,this.readRegexp()):t===61?this.finishOp(n.assign,2):this.finishOp(n.slash,1)},E.readToken_mult_modulo_exp=function(t){var e=this.input.charCodeAt(this.pos+1),i=1,s=t===42?n.star:n.modulo;return this.options.ecmaVersion>=7&&t===42&&e===42&&(++i,s=n.starstar,e=this.input.charCodeAt(this.pos+2)),e===61?this.finishOp(n.assign,i+1):this.finishOp(s,i)},E.readToken_pipe_amp=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?this.options.ecmaVersion>=12&&this.input.charCodeAt(this.pos+2)===61?this.finishOp(n.assign,3):this.finishOp(t===124?n.logicalOR:n.logicalAND,2):e===61?this.finishOp(n.assign,2):this.finishOp(t===124?n.bitwiseOR:n.bitwiseAND,1)},E.readToken_caret=function(){return this.input.charCodeAt(this.pos+1)===61?this.finishOp(n.assign,2):this.finishOp(n.bitwiseXOR,1)},E.readToken_plus_min=function(t){var e=this.input.charCodeAt(this.pos+1);return e===t?e!==45||this.inModule||this.input.charCodeAt(this.pos+2)!==62||this.lastTokEnd!==0&&!M.test(this.input.slice(this.lastTokEnd,this.pos))?this.finishOp(n.incDec,2):(this.skipLineComment(3),this.skipSpace(),this.nextToken()):e===61?this.finishOp(n.assign,2):this.finishOp(n.plusMin,1)},E.readToken_lt_gt=function(t){var e=this.input.charCodeAt(this.pos+1),i=1;return e===t?(i=t===62&&this.input.charCodeAt(this.pos+2)===62?3:2,this.input.charCodeAt(this.pos+i)===61?this.finishOp(n.assign,i+1):this.finishOp(n.bitShift,i)):e!==33||t!==60||this.inModule||this.input.charCodeAt(this.pos+2)!==45||this.input.charCodeAt(this.pos+3)!==45?(e===61&&(i=2),this.finishOp(n.relational,i)):(this.skipLineComment(4),this.skipSpace(),this.nextToken())},E.readToken_eq_excl=function(t){var e=this.input.charCodeAt(this.pos+1);return e===61?this.finishOp(n.equality,this.input.charCodeAt(this.pos+2)===61?3:2):t===61&&e===62&&this.options.ecmaVersion>=6?(this.pos+=2,this.finishToken(n.arrow)):this.finishOp(t===61?n.eq:n.prefix,1)},E.readToken_question=function(){var t=this.options.ecmaVersion;if(t>=11){var e=this.input.charCodeAt(this.pos+1);if(e===46){var i=this.input.charCodeAt(this.pos+2);if(i<48||i>57)return this.finishOp(n.questionDot,2)}if(e===63)return t>=12&&this.input.charCodeAt(this.pos+2)===61?this.finishOp(n.assign,3):this.finishOp(n.coalesce,2)}return this.finishOp(n.question,1)},E.readToken_numberSign=function(){var t=35;if(this.options.ecmaVersion>=13&&(++this.pos,K(t=this.fullCharCodeAtPos(),!0)||t===92))return this.finishToken(n.privateId,this.readWord1());this.raise(this.pos,"Unexpected character '"+Q(t)+"'")},E.getTokenFromCode=function(t){switch(t){case 46:return this.readToken_dot();case 40:return++this.pos,this.finishToken(n.parenL);case 41:return++this.pos,this.finishToken(n.parenR);case 59:return++this.pos,this.finishToken(n.semi);case 44:return++this.pos,this.finishToken(n.comma);case 91:return++this.pos,this.finishToken(n.bracketL);case 93:return++this.pos,this.finishToken(n.bracketR);case 123:return++this.pos,this.finishToken(n.braceL);case 125:return++this.pos,this.finishToken(n.braceR);case 58:return++this.pos,this.finishToken(n.colon);case 96:if(this.options.ecmaVersion<6)break;return++this.pos,this.finishToken(n.backQuote);case 48:var e=this.input.charCodeAt(this.pos+1);if(e===120||e===88)return this.readRadixNumber(16);if(this.options.ecmaVersion>=6){if(e===111||e===79)return this.readRadixNumber(8);if(e===98||e===66)return this.readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return this.readNumber(!1);case 34:case 39:return this.readString(t);case 47:return this.readToken_slash();case 37:case 42:return this.readToken_mult_modulo_exp(t);case 124:case 38:return this.readToken_pipe_amp(t);case 94:return this.readToken_caret();case 43:case 45:return this.readToken_plus_min(t);case 60:case 62:return this.readToken_lt_gt(t);case 61:case 33:return this.readToken_eq_excl(t);case 63:return this.readToken_question();case 126:return this.finishOp(n.prefix,1);case 35:return this.readToken_numberSign()}this.raise(this.pos,"Unexpected character '"+Q(t)+"'")},E.finishOp=function(t,e){var i=this.input.slice(this.pos,this.pos+e);return this.pos+=e,this.finishToken(t,i)},E.readRegexp=function(){for(var t,e,i=this.pos;;){this.pos>=this.input.length&&this.raise(i,"Unterminated regular expression");var s=this.input.charAt(this.pos);if(M.test(s)&&this.raise(i,"Unterminated regular expression"),t)t=!1;else{if(s==="[")e=!0;else if(s==="]"&&e)e=!1;else if(s==="/"&&!e)break;t=s==="\\"}++this.pos}var r=this.input.slice(i,this.pos);++this.pos;var a=this.pos,o=this.readWord1();this.containsEsc&&this.unexpected(a);var h=this.regexpState||(this.regexpState=new J(this));h.reset(i,r,o),this.validateRegExpFlags(h),this.validateRegExpPattern(h);var c=null;try{c=new RegExp(r,o)}catch{}return this.finishToken(n.regexp,{pattern:r,flags:o,value:c})},E.readInt=function(t,e,i){for(var s=this.options.ecmaVersion>=12&&e===void 0,r=i&&this.input.charCodeAt(this.pos)===48,a=this.pos,o=0,h=0,c=0,l=e??1/0;c<l;++c,++this.pos){var p=this.input.charCodeAt(this.pos),f=void 0;if(s&&p===95)r&&this.raiseRecoverable(this.pos,"Numeric separator is not allowed in legacy octal numeric literals"),h===95&&this.raiseRecoverable(this.pos,"Numeric separator must be exactly one underscore"),c===0&&this.raiseRecoverable(this.pos,"Numeric separator is not allowed at the first of digits"),h=p;else{if((f=p>=97?p-97+10:p>=65?p-65+10:p>=48&&p<=57?p-48:1/0)>=t)break;h=p,o=o*t+f}}return s&&h===95&&this.raiseRecoverable(this.pos-1,"Numeric separator is not allowed at the last of digits"),this.pos===a||e!=null&&this.pos-a!==e?null:o},E.readRadixNumber=function(t){var e=this.pos;this.pos+=2;var i=this.readInt(t);return i==null&&this.raise(this.start+2,"Expected number in radix "+t),this.options.ecmaVersion>=11&&this.input.charCodeAt(this.pos)===110?(i=Je(this.input.slice(e,this.pos)),++this.pos):K(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(n.num,i)},E.readNumber=function(t){var e=this.pos;t||this.readInt(10,void 0,!0)!==null||this.raise(e,"Invalid number");var i=this.pos-e>=2&&this.input.charCodeAt(e)===48;i&&this.strict&&this.raise(e,"Invalid number");var s=this.input.charCodeAt(this.pos);if(!i&&!t&&this.options.ecmaVersion>=11&&s===110){var r=Je(this.input.slice(e,this.pos));return++this.pos,K(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number"),this.finishToken(n.num,r)}i&&/[89]/.test(this.input.slice(e,this.pos))&&(i=!1),s!==46||i||(++this.pos,this.readInt(10),s=this.input.charCodeAt(this.pos)),s!==69&&s!==101||i||((s=this.input.charCodeAt(++this.pos))!==43&&s!==45||++this.pos,this.readInt(10)===null&&this.raise(e,"Invalid number")),K(this.fullCharCodeAtPos())&&this.raise(this.pos,"Identifier directly after number");var a,o=(a=this.input.slice(e,this.pos),i?parseInt(a,8):parseFloat(a.replace(/_/g,"")));return this.finishToken(n.num,o)},E.readCodePoint=function(){var t;if(this.input.charCodeAt(this.pos)===123){this.options.ecmaVersion<6&&this.unexpected();var e=++this.pos;t=this.readHexChar(this.input.indexOf("}",this.pos)-this.pos),++this.pos,t>1114111&&this.invalidStringToken(e,"Code point out of bounds")}else t=this.readHexChar(4);return t},E.readString=function(t){for(var e="",i=++this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated string constant");var s=this.input.charCodeAt(this.pos);if(s===t)break;s===92?(e+=this.input.slice(i,this.pos),e+=this.readEscapedChar(!1),i=this.pos):s===8232||s===8233?(this.options.ecmaVersion<10&&this.raise(this.start,"Unterminated string constant"),++this.pos,this.options.locations&&(this.curLine++,this.lineStart=this.pos)):(ut(s)&&this.raise(this.start,"Unterminated string constant"),++this.pos)}return e+=this.input.slice(i,this.pos++),this.finishToken(n.string,e)};var Ye={};E.tryReadTemplateToken=function(){this.inTemplateElement=!0;try{this.readTmplToken()}catch(t){if(t!==Ye)throw t;this.readInvalidTemplateToken()}this.inTemplateElement=!1},E.invalidStringToken=function(t,e){if(this.inTemplateElement&&this.options.ecmaVersion>=9)throw Ye;this.raise(t,e)},E.readTmplToken=function(){for(var t="",e=this.pos;;){this.pos>=this.input.length&&this.raise(this.start,"Unterminated template");var i=this.input.charCodeAt(this.pos);if(i===96||i===36&&this.input.charCodeAt(this.pos+1)===123)return this.pos!==this.start||this.type!==n.template&&this.type!==n.invalidTemplate?(t+=this.input.slice(e,this.pos),this.finishToken(n.template,t)):i===36?(this.pos+=2,this.finishToken(n.dollarBraceL)):(++this.pos,this.finishToken(n.backQuote));if(i===92)t+=this.input.slice(e,this.pos),t+=this.readEscapedChar(!0),e=this.pos;else if(ut(i)){switch(t+=this.input.slice(e,this.pos),++this.pos,i){case 13:this.input.charCodeAt(this.pos)===10&&++this.pos;case 10:t+=`
14
+ `;break;default:t+=String.fromCharCode(i)}this.options.locations&&(++this.curLine,this.lineStart=this.pos),e=this.pos}else++this.pos}},E.readInvalidTemplateToken=function(){for(;this.pos<this.input.length;this.pos++)switch(this.input[this.pos]){case"\\":++this.pos;break;case"$":if(this.input[this.pos+1]!=="{")break;case"`":return this.finishToken(n.invalidTemplate,this.input.slice(this.start,this.pos));case"\r":this.input[this.pos+1]===`
15
+ `&&++this.pos;case`
16
+ `:case"\u2028":case"\u2029":++this.curLine,this.lineStart=this.pos+1}this.raise(this.start,"Unterminated template")},E.readEscapedChar=function(t){var e=this.input.charCodeAt(++this.pos);switch(++this.pos,e){case 110:return`
17
+ `;case 114:return"\r";case 120:return String.fromCharCode(this.readHexChar(2));case 117:return Q(this.readCodePoint());case 116:return" ";case 98:return"\b";case 118:return"\v";case 102:return"\f";case 13:this.input.charCodeAt(this.pos)===10&&++this.pos;case 10:return this.options.locations&&(this.lineStart=this.pos,++this.curLine),"";case 56:case 57:if(this.strict&&this.invalidStringToken(this.pos-1,"Invalid escape sequence"),t){var i=this.pos-1;this.invalidStringToken(i,"Invalid escape sequence in template string")}default:if(e>=48&&e<=55){var s=this.input.substr(this.pos-1,3).match(/^[0-7]+/)[0],r=parseInt(s,8);return r>255&&(s=s.slice(0,-1),r=parseInt(s,8)),this.pos+=s.length-1,e=this.input.charCodeAt(this.pos),s==="0"&&e!==56&&e!==57||!this.strict&&!t||this.invalidStringToken(this.pos-1-s.length,t?"Octal literal in template string":"Octal literal in strict mode"),String.fromCharCode(r)}return ut(e)?(this.options.locations&&(this.lineStart=this.pos,++this.curLine),""):String.fromCharCode(e)}},E.readHexChar=function(t){var e=this.pos,i=this.readInt(16,t);return i===null&&this.invalidStringToken(e,"Bad character escape sequence"),i},E.readWord1=function(){this.containsEsc=!1;for(var t="",e=!0,i=this.pos,s=this.options.ecmaVersion>=6;this.pos<this.input.length;){var r=this.fullCharCodeAtPos();if(X(r,s))this.pos+=r<=65535?1:2;else{if(r!==92)break;this.containsEsc=!0,t+=this.input.slice(i,this.pos);var a=this.pos;this.input.charCodeAt(++this.pos)!==117&&this.invalidStringToken(this.pos,"Expecting Unicode escape sequence \\uXXXX"),++this.pos;var o=this.readCodePoint();(e?K:X)(o,s)||this.invalidStringToken(a,"Invalid Unicode escape"),t+=Q(o),i=this.pos}e=!1}return t+this.input.slice(i,this.pos)},E.readWord=function(){var t=this.readWord1(),e=n.name;return this.keywords.test(t)&&(e=Jt[t]),this.finishToken(e,t)},N.acorn={Parser:N,version:"8.15.0",defaultOptions:Yt,Position:St,SourceLocation:Pt,getLineInfo:Ae,Node:Dt,TokenType:S,tokTypes:n,keywordTypes:Jt,TokContext:G,tokContexts:R,isIdentifierChar:X,isIdentifierStart:K,Token:re,isNewLine:ut,lineBreak:M,lineBreakG:Ki,nonASCIIwhitespace:Ie};let mt=B("module"),D=B("fs");String.fromCharCode;let ls=/\/$|\/\?|\/#/,us=/^\.?\//;function fs(t="",e){return e?ls.test(t):t.endsWith("/")}function ds(t="",e){if(!e)return t.endsWith("/")?t:t+"/";if(fs(t,!0))return t||"/";let i=t,s="",r=t.indexOf("#");if(r!==-1&&(i=t.slice(0,r),s=t.slice(r),!i))return s;let[a,...o]=i.split("?");return a+"/"+(o.length>0?`?${o.join("?")}`:"")+s}function ms(t){return t&&t!=="/"}function Qe(t,...e){let i=t||"";for(let s of e.filter(r=>ms(r)))if(i){let r=s.replace(us,"");i=ds(i)+r}else i=s;return i}Symbol.for("ufo:protocolRelative");let gs=/^[A-Za-z]:\//;function gt(t=""){return t&&t.replace(/\\/g,"/").replace(gs,e=>e.toUpperCase())}let xs=/^[/\\]{2}/,vs=/^[/\\](?![/\\])|^[/\\]{2}(?!\.)|^[A-Za-z]:[/\\]/,Ze=/^[A-Za-z]:$/,ys=/.(\.[^./]+|\.)$/,_s=function(t){if(t.length===0)return".";let e=(t=gt(t)).match(xs),i=at(t),s=t[t.length-1]==="/";return(t=Xe(t,!i)).length===0?i?"/":s?"./":".":(s&&(t+="/"),Ze.test(t)&&(t+="/"),e?i?`//${t}`:`//./${t}`:i&&!at(t)?`/${t}`:t)},it=function(...t){let e="";for(let i of t)if(i)if(e.length>0){let s=e[e.length-1]==="/",r=i[0]==="/";e+=s&&r?i.slice(1):s||r?i:`/${i}`}else e+=i;return _s(e)};function Es(){return typeof process<"u"&&typeof process.cwd=="function"?process.cwd().replace(/\\/g,"/"):"/"}let bs=function(...t){let e="",i=!1;for(let s=(t=t.map(r=>gt(r))).length-1;s>=-1&&!i;s--){let r=s>=0?t[s]:Es();r&&r.length!==0&&(e=`${r}/${e}`,i=at(r))}return e=Xe(e,!i),i&&!at(e)?`/${e}`:e.length>0?e:"."};function Xe(t,e){let i="",s=0,r=-1,a=0,o=null;for(let h=0;h<=t.length;++h){if(h<t.length)o=t[h];else{if(o==="/")break;o="/"}if(o==="/"){if(!(r===h-1||a===1))if(a===2){if(i.length<2||s!==2||i[i.length-1]!=="."||i[i.length-2]!=="."){if(i.length>2){let c=i.lastIndexOf("/");c===-1?(i="",s=0):(i=i.slice(0,c),s=i.length-1-i.lastIndexOf("/")),r=h,a=0;continue}if(i.length>0){i="",s=0,r=h,a=0;continue}}e&&(i+=i.length>0?"/..":"..",s=2)}else i.length>0?i+=`/${t.slice(r+1,h)}`:i=t.slice(r+1,h),s=h-r-1;r=h,a=0}else o==="."&&a!==-1?++a:a=-1}return i}let at=function(t){return vs.test(t)},ti=function(t){if(t==="..")return"";let e=ys.exec(gt(t));return e&&e[1]||""},Mt=function(t){let e=gt(t).replace(/\/$/,"").split("/").slice(0,-1);return e.length===1&&Ze.test(e[0])&&(e[0]+="/"),e.join("/")||(at(t)?"/":".")},ei=function(t,e){let i=gt(t).split("/"),s="";for(let r=i.length-1;r>=0;r--){let a=i[r];if(a){s=a;break}}return e&&s.endsWith(e)?s.slice(0,-e.length):s},g=B("url"),st=B("assert"),ot=B("process"),ne=B("path"),Ss=B("v8"),jt=B("util"),ii=new Set(mt.builtinModules);function ae(t){return t.replace(/\\/g,"/")}let Cs={}.hasOwnProperty,Is=/^([A-Z][a-z\d]*)+$/,ks=new Set(["string","function","number","object","Function","Object","boolean","bigint","symbol"]),V={};function oe(t,e="and"){return t.length<3?t.join(` ${e} `):`${t.slice(0,-1).join(", ")}, ${e} ${t[t.length-1]}`}let si=new Map,ri;function W(t,e,i){return si.set(t,e),(function(s,r){return a;function a(...o){let h=Error.stackTraceLimit;he()&&(Error.stackTraceLimit=0);let c=new s;he()&&(Error.stackTraceLimit=h);let l=(function(p,f,u){let v=si.get(p);if(st(v!==void 0,"expected `message` to be found"),typeof v=="function")return st(v.length<=f.length,`Code: ${p}; The provided arguments length (${f.length}) does not match the required ones (${v.length}).`),Reflect.apply(v,u,f);let w=/%[dfijoOs]/g,y=0;for(;w.exec(v)!==null;)y++;return st(y===f.length,`Code: ${p}; The provided arguments length (${f.length}) does not match the required ones (${y}).`),f.length===0?v:(f.unshift(v),Reflect.apply(jt.format,null,f))})(r,o,c);return Object.defineProperties(c,{message:{value:l,enumerable:!1,writable:!0,configurable:!0},toString:{value(){return`${this.name} [${r}]: ${this.message}`},enumerable:!1,writable:!0,configurable:!0}}),ws(c),c.code=r,c}})(i,t)}function he(){try{if(Ss.startupSnapshot.isBuildingSnapshot())return!1}catch{}let t=Object.getOwnPropertyDescriptor(Error,"stackTraceLimit");return t===void 0?Object.isExtensible(Error):Cs.call(t,"writable")&&t.writable!==void 0?t.writable:t.set!==void 0}V.ERR_INVALID_ARG_TYPE=W("ERR_INVALID_ARG_TYPE",(t,e,i)=>{st(typeof t=="string","'name' must be a string"),Array.isArray(e)||(e=[e]);let s="The ";if(t.endsWith(" argument"))s+=`${t} `;else{let h=t.includes(".")?"property":"argument";s+=`"${t}" ${h} `}s+="must be ";let r=[],a=[],o=[];for(let h of e)st(typeof h=="string","All expected entries have to be of type string"),ks.has(h)?r.push(h.toLowerCase()):Is.exec(h)===null?(st(h!=="object",'The value "object" should be written as "Object"'),o.push(h)):a.push(h);if(a.length>0){let h=r.indexOf("object");h!==-1&&(r.slice(h,1),a.push("Object"))}return r.length>0&&(s+=`${r.length>1?"one of type":"of type"} ${oe(r,"or")}`,(a.length>0||o.length>0)&&(s+=" or ")),a.length>0&&(s+=`an instance of ${oe(a,"or")}`,o.length>0&&(s+=" or ")),o.length>0&&(o.length>1?s+=`one of ${oe(o,"or")}`:(o[0].toLowerCase()!==o[0]&&(s+="an "),s+=`${o[0]}`)),s+=`. Received ${(function(h){if(h==null)return String(h);if(typeof h=="function"&&h.name)return`function ${h.name}`;if(typeof h=="object")return h.constructor&&h.constructor.name?`an instance of ${h.constructor.name}`:`${(0,jt.inspect)(h,{depth:-1})}`;let c=(0,jt.inspect)(h,{colors:!1});return c.length>28&&(c=`${c.slice(0,25)}...`),`type ${typeof h} (${c})`})(i)}`,s},TypeError),V.ERR_INVALID_MODULE_SPECIFIER=W("ERR_INVALID_MODULE_SPECIFIER",(t,e,i=void 0)=>`Invalid module "${t}" ${e}${i?` imported from ${i}`:""}`,TypeError),V.ERR_INVALID_PACKAGE_CONFIG=W("ERR_INVALID_PACKAGE_CONFIG",(t,e,i)=>`Invalid package config ${t}${e?` while importing ${e}`:""}${i?`. ${i}`:""}`,Error),V.ERR_INVALID_PACKAGE_TARGET=W("ERR_INVALID_PACKAGE_TARGET",(t,e,i,s=!1,r=void 0)=>{let a=typeof i=="string"&&!s&&i.length>0&&!i.startsWith("./");return e==="."?(st(s===!1),`Invalid "exports" main target ${JSON.stringify(i)} defined in the package config ${t}package.json${r?` imported from ${r}`:""}${a?'; targets must start with "./"':""}`):`Invalid "${s?"imports":"exports"}" target ${JSON.stringify(i)} defined for '${e}' in the package config ${t}package.json${r?` imported from ${r}`:""}${a?'; targets must start with "./"':""}`},Error),V.ERR_MODULE_NOT_FOUND=W("ERR_MODULE_NOT_FOUND",(t,e,i=!1)=>`Cannot find ${i?"module":"package"} '${t}' imported from ${e}`,Error),V.ERR_NETWORK_IMPORT_DISALLOWED=W("ERR_NETWORK_IMPORT_DISALLOWED","import of '%s' by %s is not supported: %s",Error),V.ERR_PACKAGE_IMPORT_NOT_DEFINED=W("ERR_PACKAGE_IMPORT_NOT_DEFINED",(t,e,i)=>`Package import specifier "${t}" is not defined${e?` in package ${e}package.json`:""} imported from ${i}`,TypeError),V.ERR_PACKAGE_PATH_NOT_EXPORTED=W("ERR_PACKAGE_PATH_NOT_EXPORTED",(t,e,i=void 0)=>e==="."?`No "exports" main defined in ${t}package.json${i?` imported from ${i}`:""}`:`Package subpath '${e}' is not defined by "exports" in ${t}package.json${i?` imported from ${i}`:""}`,Error),V.ERR_UNSUPPORTED_DIR_IMPORT=W("ERR_UNSUPPORTED_DIR_IMPORT","Directory import '%s' is not supported resolving ES modules imported from %s",Error),V.ERR_UNSUPPORTED_RESOLVE_REQUEST=W("ERR_UNSUPPORTED_RESOLVE_REQUEST",'Failed to resolve module specifier "%s" from "%s": Invalid relative URL or base scheme is not hierarchical.',TypeError),V.ERR_UNKNOWN_FILE_EXTENSION=W("ERR_UNKNOWN_FILE_EXTENSION",(t,e)=>`Unknown file extension "${t}" for ${e}`,TypeError),V.ERR_INVALID_ARG_VALUE=W("ERR_INVALID_ARG_VALUE",(t,e,i="is invalid")=>{let s=(0,jt.inspect)(e);return s.length>128&&(s=`${s.slice(0,128)}...`),`The ${t.includes(".")?"property":"argument"} '${t}' ${i}. Received ${s}`},TypeError);let ws=(function(t){let e="__node_internal_"+t.name;return Object.defineProperty(t,"name",{value:e}),t})(function(t){let e=he();return e&&(ri=Error.stackTraceLimit,Error.stackTraceLimit=Number.POSITIVE_INFINITY),Error.captureStackTrace(t),e&&(Error.stackTraceLimit=ri),t}),kt={}.hasOwnProperty,{ERR_INVALID_PACKAGE_CONFIG:Rs}=V,ni=new Map;function ai(t,{base:e,specifier:i}){let s=ni.get(t);if(s)return s;let r;try{r=D.readFileSync(ne.toNamespacedPath(t),"utf8")}catch(o){let h=o;if(h.code!=="ENOENT")throw h}let a={exists:!1,pjsonPath:t,main:void 0,name:void 0,type:"none",exports:void 0,imports:void 0};if(r!==void 0){let o;try{o=JSON.parse(r)}catch(h){let c=h,l=new Rs(t,(e?`"${i}" from `:"")+(0,g.fileURLToPath)(e||i),c.message);throw l.cause=c,l}a.exists=!0,kt.call(o,"name")&&typeof o.name=="string"&&(a.name=o.name),kt.call(o,"main")&&typeof o.main=="string"&&(a.main=o.main),kt.call(o,"exports")&&(a.exports=o.exports),kt.call(o,"imports")&&(a.imports=o.imports),!kt.call(o,"type")||o.type!=="commonjs"&&o.type!=="module"||(a.type=o.type)}return ni.set(t,a),a}function ce(t){let e=new URL("package.json",t);for(;!e.pathname.endsWith("node_modules/package.json");){let i=ai((0,g.fileURLToPath)(e),{specifier:t});if(i.exists)return i;let s=e;if(e=new URL("../package.json",e),e.pathname===s.pathname)break}return{pjsonPath:(0,g.fileURLToPath)(e),exists:!1,type:"none"}}function oi(t){return ce(t).type}let{ERR_UNKNOWN_FILE_EXTENSION:As}=V,Ts={}.hasOwnProperty,Ps={__proto__:null,".cjs":"commonjs",".js":"module",".json":"json",".mjs":"module"},hi={__proto__:null,"data:":function(t){let{1:e}=/^([^/]+\/[^;,]+)[^,]*?(;base64)?,/.exec(t.pathname)||[null,null,null];return(function(i){return i&&/\s*(text|application)\/javascript\s*(;\s*charset=utf-?8\s*)?/i.test(i)?"module":i==="application/json"?"json":null})(e)},"file:":function(t,e,i){let s=(function(o){let h=o.pathname,c=h.length;for(;c--;){let l=h.codePointAt(c);if(l===47)return"";if(l===46)return h.codePointAt(c-1)===47?"":h.slice(c)}return""})(t);if(s===".js"){let o=oi(t);return o!=="none"?o:"commonjs"}if(s===""){let o=oi(t);return o==="none"||o==="commonjs"?"commonjs":"module"}let r=Ps[s];if(r)return r;if(i)return;let a=(0,g.fileURLToPath)(t);throw new As(s,a)},"http:":ci,"https:":ci,"node:":()=>"builtin"};function ci(){}let Bt=RegExp.prototype[Symbol.replace],{ERR_INVALID_MODULE_SPECIFIER:Ft,ERR_INVALID_PACKAGE_CONFIG:pi,ERR_INVALID_PACKAGE_TARGET:Ns,ERR_MODULE_NOT_FOUND:pe,ERR_PACKAGE_IMPORT_NOT_DEFINED:Ls,ERR_PACKAGE_PATH_NOT_EXPORTED:Os,ERR_UNSUPPORTED_DIR_IMPORT:Ds,ERR_UNSUPPORTED_RESOLVE_REQUEST:li}=V,ui={}.hasOwnProperty,fi=/(^|\\|\/)((\.|%2e)(\.|%2e)?|(n|%6e|%4e)(o|%6f|%4f)(d|%64|%44)(e|%65|%45)(_|%5f)(m|%6d|%4d)(o|%6f|%4f)(d|%64|%44)(u|%75|%55)(l|%6c|%4c)(e|%65|%45)(s|%73|%53))?(\\|\/|$)/i,di=/(^|\\|\/)((\.|%2e)(\.|%2e)?|(n|%6e|%4e)(o|%6f|%4f)(d|%64|%44)(e|%65|%45)(_|%5f)(m|%6d|%4d)(o|%6f|%4f)(d|%64|%44)(u|%75|%55)(l|%6c|%4c)(e|%65|%45)(s|%73|%53))(\\|\/|$)/i,Vs=/^\.|%|\\/,$t=/\*/g,Us=/%2f|%5c/i,mi=new Set,Ms=/[/\\]{2}/;function gi(t,e,i,s,r,a,o){if(ot.noDeprecation)return;let h=(0,g.fileURLToPath)(s),c=Ms.exec(o?t:e)!==null;ot.emitWarning(`Use of deprecated ${c?"double slash":"leading or trailing slash matching"} resolving "${t}" for module request "${e}" ${e===i?"":`matched to "${i}" `}in the "${r?"imports":"exports"}" field module resolution of the package at ${h}${a?` imported from ${(0,g.fileURLToPath)(a)}`:""}.`,"DeprecationWarning","DEP0166")}function xi(t,e,i,s){if(ot.noDeprecation||(function(c,l){let p=c.protocol;return Ts.call(hi,p)&&hi[p](c,l,!0)||null})(t,{parentURL:i.href})!=="module")return;let a=(0,g.fileURLToPath)(t.href),o=(0,g.fileURLToPath)(new g.URL(".",e)),h=(0,g.fileURLToPath)(i);s?ne.resolve(o,s)!==a&&ot.emitWarning(`Package ${o} has a "main" field set to "${s}", excluding the full filename and extension to the resolved file at "${a.slice(o.length)}", imported from ${h}.
18
+ Automatic extension resolution of the "main" field is deprecated for ES modules.`,"DeprecationWarning","DEP0151"):ot.emitWarning(`No "main" or "exports" field defined in the package.json for ${o} resolving the main entry point "${a.slice(o.length)}", imported from ${h}.
19
+ Default "index" lookups for the main are deprecated for ES modules.`,"DeprecationWarning","DEP0151")}function vi(t){try{return(0,D.statSync)(t)}catch{}}function le(t){let e=(0,D.statSync)(t,{throwIfNoEntry:!1}),i=e?e.isFile():void 0;return i!=null&&i}function js(t,e,i){let s;if(e.main!==void 0){if(s=new g.URL(e.main,t),le(s))return s;let o=[`./${e.main}.js`,`./${e.main}.json`,`./${e.main}.node`,`./${e.main}/index.js`,`./${e.main}/index.json`,`./${e.main}/index.node`],h=-1;for(;++h<o.length&&(s=new g.URL(o[h],t),!le(s));)s=void 0;if(s)return xi(s,t,i,e.main),s}let r=["./index.js","./index.json","./index.node"],a=-1;for(;++a<r.length&&(s=new g.URL(r[a],t),!le(s));)s=void 0;if(s)return xi(s,t,i,e.main),s;throw new pe((0,g.fileURLToPath)(new g.URL(".",t)),(0,g.fileURLToPath)(i))}function ue(t,e,i){return new Os((0,g.fileURLToPath)(new g.URL(".",e)),t,i&&(0,g.fileURLToPath)(i))}function wt(t,e,i,s,r){return e=typeof e=="object"&&e!==null?JSON.stringify(e,null,""):`${e}`,new Ns((0,g.fileURLToPath)(new g.URL(".",i)),t,e,s,r&&(0,g.fileURLToPath)(r))}function Bs(t,e,i,s,r,a,o,h,c){if(e!==""&&!a&&t[t.length-1]!=="/")throw wt(i,t,s,o,r);if(!t.startsWith("./")){if(o&&!t.startsWith("../")&&!t.startsWith("/")){let u=!1;try{new g.URL(t),u=!0}catch{}if(!u)return Ei(a?Bt.call($t,t,()=>e):t+e,s,c)}throw wt(i,t,s,o,r)}if(fi.exec(t.slice(2))!==null){if(di.exec(t.slice(2))!==null)throw wt(i,t,s,o,r);if(!h){let u=a?i.replace("*",()=>e):i+e;gi(a?Bt.call($t,t,()=>e):t,u,i,s,o,r,!0)}}let l=new g.URL(t,s),p=l.pathname,f=new g.URL(".",s).pathname;if(!p.startsWith(f))throw wt(i,t,s,o,r);if(e==="")return l;if(fi.exec(e)!==null){let u=a?i.replace("*",()=>e):i+e;di.exec(e)===null?h||gi(a?Bt.call($t,t,()=>e):t,u,i,s,o,r,!1):(function(v,w,y,I,C){let k=`request is not a valid match in pattern "${w}" for the "${I?"imports":"exports"}" resolution of ${(0,g.fileURLToPath)(y)}`;throw new Ft(v,k,C&&(0,g.fileURLToPath)(C))})(u,i,s,o,r)}return a?new g.URL(Bt.call($t,l.href,()=>e)):new g.URL(e,l)}function Fs(t){let e=Number(t);return`${e}`===t&&e>=0&&e<4294967295}function xt(t,e,i,s,r,a,o,h,c){if(typeof e=="string")return Bs(e,i,s,t,r,a,o,h,c);if(Array.isArray(e)){let l=e;if(l.length===0)return null;let p,f=-1;for(;++f<l.length;){let u=l[f],v;try{v=xt(t,u,i,s,r,a,o,h,c)}catch(w){if(p=w,w.code==="ERR_INVALID_PACKAGE_TARGET")continue;throw w}if(v!==void 0){if(v!==null)return v;p=null}}if(p==null)return null;throw p}if(typeof e=="object"&&e!==null){let l=Object.getOwnPropertyNames(e),p=-1;for(;++p<l.length;)if(Fs(l[p]))throw new pi((0,g.fileURLToPath)(t),r,'"exports" cannot contain numeric property keys.');for(p=-1;++p<l.length;){let f=l[p];if(f==="default"||c&&c.has(f)){let u=xt(t,e[f],i,s,r,a,o,h,c);if(u===void 0)continue;return u}}return null}if(e===null)return null;throw wt(s,e,t,o,r)}function $s(t,e,i){if(ot.noDeprecation)return;let s=(0,g.fileURLToPath)(e);mi.has(s+"|"+t)||(mi.add(s+"|"+t),ot.emitWarning(`Use of deprecated trailing slash pattern mapping "${t}" in the "exports" field module resolution of the package at ${s}${i?` imported from ${(0,g.fileURLToPath)(i)}`:""}. Mapping specifiers ending in "/" is no longer supported.`,"DeprecationWarning","DEP0155"))}function yi(t,e,i,s,r){let a=i.exports;if((function(p,f,u){if(typeof p=="string"||Array.isArray(p))return!0;if(typeof p!="object"||p===null)return!1;let v=Object.getOwnPropertyNames(p),w=!1,y=0,I=-1;for(;++I<v.length;){let C=v[I],k=C===""||C[0]!==".";if(y++===0)w=k;else if(w!==k)throw new pi((0,g.fileURLToPath)(f),u,`"exports" cannot contain some keys starting with '.' and some not. The exports object must either be an object of package subpath keys or an object of main entry condition name keys only.`)}return w})(a,t,s)&&(a={".":a}),ui.call(a,e)&&!e.includes("*")&&!e.endsWith("/")){let p=xt(t,a[e],"",e,s,!1,!1,!1,r);if(p==null)throw ue(e,t,s);return p}let o="",h="",c=Object.getOwnPropertyNames(a),l=-1;for(;++l<c.length;){let p=c[l],f=p.indexOf("*");if(f!==-1&&e.startsWith(p.slice(0,f))){e.endsWith("/")&&$s(e,t,s);let u=p.slice(f+1);e.length>=p.length&&e.endsWith(u)&&_i(o,p)===1&&p.lastIndexOf("*")===f&&(o=p,h=e.slice(f,e.length-u.length))}}if(o){let p=xt(t,a[o],h,o,s,!0,!1,e.endsWith("/"),r);if(p==null)throw ue(e,t,s);return p}throw ue(e,t,s)}function _i(t,e){let i=t.indexOf("*"),s=e.indexOf("*"),r=i===-1?t.length:i+1,a=s===-1?e.length:s+1;return r>a?-1:a>r||i===-1?1:s===-1||t.length>e.length?-1:e.length>t.length?1:0}function qs(t,e,i){if(t==="#"||t.startsWith("#/")||t.endsWith("/"))throw new Ft(t,"is not a valid internal imports specifier name",(0,g.fileURLToPath)(e));let s,r=ce(e);if(r.exists){s=(0,g.pathToFileURL)(r.pjsonPath);let a=r.imports;if(a)if(ui.call(a,t)&&!t.includes("*")){let o=xt(s,a[t],"",t,e,!1,!0,!1,i);if(o!=null)return o}else{let o="",h="",c=Object.getOwnPropertyNames(a),l=-1;for(;++l<c.length;){let p=c[l],f=p.indexOf("*");if(f!==-1&&t.startsWith(p.slice(0,-1))){let u=p.slice(f+1);t.length>=p.length&&t.endsWith(u)&&_i(o,p)===1&&p.lastIndexOf("*")===f&&(o=p,h=t.slice(f,t.length-u.length))}}if(o){let p=xt(s,a[o],h,o,e,!0,!0,!1,i);if(p!=null)return p}}}throw(function(a,o,h){return new Ls(a,o&&(0,g.fileURLToPath)(new g.URL(".",o)),(0,g.fileURLToPath)(h))})(t,s,e)}function Ei(t,e,i){if(mt.builtinModules.includes(t))return new g.URL("node:"+t);let{packageName:s,packageSubpath:r,isScoped:a}=(function(p,f){let u=p.indexOf("/"),v=!0,w=!1;p[0]==="@"&&(w=!0,u===-1||p.length===0?v=!1:u=p.indexOf("/",u+1));let y=u===-1?p:p.slice(0,u);if(Vs.exec(y)!==null&&(v=!1),!v)throw new Ft(p,"is not a valid package name",(0,g.fileURLToPath)(f));return{packageName:y,packageSubpath:"."+(u===-1?"":p.slice(u)),isScoped:w}})(t,e),o=ce(e);if(o.exists){let p=(0,g.pathToFileURL)(o.pjsonPath);if(o.name===s&&o.exports!==void 0&&o.exports!==null)return yi(p,r,o,e,i)}let h,c=new g.URL("./node_modules/"+s+"/package.json",e),l=(0,g.fileURLToPath)(c);do{let p=vi(l.slice(0,-13));if(!p||!p.isDirectory()){h=l,c=new g.URL((a?"../../../../node_modules/":"../../../node_modules/")+s+"/package.json",c),l=(0,g.fileURLToPath)(c);continue}let f=ai(l,{base:e,specifier:t});return f.exports!==void 0&&f.exports!==null?yi(c,r,f,e,i):r==="."?js(c,f,e):new g.URL(r,c)}while(l.length!==h.length);throw new pe(s,(0,g.fileURLToPath)(e),!1)}function Ws(t,e,i,s){let r=e.protocol,a=r==="data:"||r==="http:"||r==="https:",o;if((function(h){return h!==""&&(h[0]==="/"||(function(c){return c[0]==="."&&(c.length===1||c[1]==="/"||c[1]==="."&&(c.length===2||c[2]==="/"))})(h))})(t))try{o=new g.URL(t,e)}catch(h){let c=new li(t,e);throw c.cause=h,c}else if(r==="file:"&&t[0]==="#")o=qs(t,e,i);else try{o=new g.URL(t)}catch(h){if(a&&!mt.builtinModules.includes(t)){let c=new li(t,e);throw c.cause=h,c}o=Ei(t,e,i)}return st(o!==void 0,"expected to be defined"),o.protocol!=="file:"?o:(function(h,c){if(Us.exec(h.pathname)!==null)throw new Ft(h.pathname,'must not include encoded "/" or "\\" characters',(0,g.fileURLToPath)(c));let l;try{l=(0,g.fileURLToPath)(h)}catch(f){let u=f;throw Object.defineProperty(u,"input",{value:String(h)}),Object.defineProperty(u,"module",{value:String(c)}),u}let p=vi(l.endsWith("/")?l.slice(-1):l);if(p&&p.isDirectory()){let f=new Ds(l,(0,g.fileURLToPath)(c));throw f.url=String(h),f}if(!p||!p.isFile()){let f=new pe(l||h.pathname,c&&(0,g.fileURLToPath)(c),!0);throw f.url=String(h),f}{let f=(0,D.realpathSync)(l),{search:u,hash:v}=h;(h=(0,g.pathToFileURL)(f+(l.endsWith(ne.sep)?"/":""))).search=u,h.hash=v}return h})(o,e)}function Rt(t){return typeof t!="string"||t.startsWith("file://")?ae((0,g.fileURLToPath)(t)):ae(t)}function vt(t){return(0,g.pathToFileURL)(Rt(t)).toString()}let Gs=new Set(["node","import"]),Hs=[".mjs",".cjs",".js",".json"],Ks=new Set(["ERR_MODULE_NOT_FOUND","ERR_UNSUPPORTED_DIR_IMPORT","MODULE_NOT_FOUND","ERR_PACKAGE_PATH_NOT_EXPORTED"]);function bi(t,e,i){try{return Ws(t,e,i)}catch(s){if(!Ks.has(s?.code))throw s}}function zs(t,e={}){if(typeof t!="string"){if(!(t instanceof URL))throw new TypeError("input must be a `string` or `URL`");t=Rt(t)}if(/(?:node|data|http|https):/.test(t))return t;if(ii.has(t))return"node:"+t;if(t.startsWith("file://")&&(t=Rt(t)),at(t))try{if((0,D.statSync)(t).isFile())return vt(t)}catch(o){if(o?.code!=="ENOENT")throw o}let i=e.conditions?new Set(e.conditions):Gs,s=(Array.isArray(e.url)?e.url:[e.url]).filter(Boolean).map(o=>new URL((function(h){return typeof h!="string"&&(h=h.toString()),/(?:node|data|http|https|file):/.test(h)?h:ii.has(h)?"node:"+h:"file://"+encodeURI(ae(h))})(o.toString())));s.length===0&&s.push(new URL(vt(process.cwd())));let r=[...s];for(let o of s)o.protocol==="file:"&&r.push(new URL("./",o),new URL(Qe(o.pathname,"_index.js"),o),new URL("node_modules",o));let a;for(let o of r){if(a=bi(t,o,i),a)break;for(let h of["","/index"]){for(let c of e.extensions||Hs)if(a=bi(Qe(t,h)+c,o,i),a)break;if(a)break}if(a)break}if(!a){let o=new Error(`Cannot find module ${t} imported from ${r.join(", ")}`);throw o.code="ERR_MODULE_NOT_FOUND",o}return vt(a)}function Js(t,e){return zs(t,e)}function Ys(t,e){return Rt(Js(t,e))}let Qs=/(?:[\s;]|^)(?:import[\s\w*,{}]*from|import\s*["'*{]|export\b\s*(?:[*{]|default|class|type|function|const|var|let|async function)|import\.meta\b)/m,Zs=/\/\*.+?\*\/|\/\/.*(?=[nr])/g;function Xs(t,e={}){return e.stripComments&&(t=t.replace(Zs,"")),Qs.test(t)}function Si(t){if(typeof t!="string")throw new TypeError("Expected a string");return t.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}let tr=new Set(["/","\\",void 0]),Ci=Symbol.for("pathe:normalizedAlias"),er=/[/\\]/;function Ii(t){if(t[Ci])return t;let e=Object.fromEntries(Object.entries(t).sort(([i],[s])=>(function(r,a){return a.split("/").length-r.split("/").length})(i,s)));for(let i in e)for(let s in e)s===i||i.startsWith(s)||e[i]?.startsWith(s)&&tr.has(e[i][s.length])&&(e[i]=e[s]+e[i].slice(s.length));return Object.defineProperty(e,Ci,{value:!0,enumerable:!1}),e}function ki(t="/"){let e=t[t.length-1];return e==="/"||e==="\\"}var ir={rE:"2.6.1"};let sr=B("crypto");var fe=H.n(sr);let qt=Object.create(null),At=t=>globalThis.process?.env||globalThis.Deno?.env.toObject()||globalThis.__env__||(t?qt:globalThis),rt=new Proxy(qt,{get:(t,e)=>At()[e]??qt[e],has:(t,e)=>e in At()||e in qt,set:(t,e,i)=>(At(!0)[e]=i,!0),deleteProperty(t,e){return e?(delete At(!0)[e],!0):!1},ownKeys(){let t=At(!0);return Object.keys(t)}}),rr=typeof process<"u"&&process.env&&process.env.NODE_ENV||"",nr=[["APPVEYOR"],["AWS_AMPLIFY","AWS_APP_ID",{ci:!0}],["AZURE_PIPELINES","SYSTEM_TEAMFOUNDATIONCOLLECTIONURI"],["AZURE_STATIC","INPUT_AZURE_STATIC_WEB_APPS_API_TOKEN"],["APPCIRCLE","AC_APPCIRCLE"],["BAMBOO","bamboo_planKey"],["BITBUCKET","BITBUCKET_COMMIT"],["BITRISE","BITRISE_IO"],["BUDDY","BUDDY_WORKSPACE_ID"],["BUILDKITE"],["CIRCLE","CIRCLECI"],["CIRRUS","CIRRUS_CI"],["CLOUDFLARE_PAGES","CF_PAGES",{ci:!0}],["CLOUDFLARE_WORKERS","WORKERS_CI",{ci:!0}],["CODEBUILD","CODEBUILD_BUILD_ARN"],["CODEFRESH","CF_BUILD_ID"],["DRONE"],["DRONE","DRONE_BUILD_EVENT"],["DSARI"],["GITHUB_ACTIONS"],["GITLAB","GITLAB_CI"],["GITLAB","CI_MERGE_REQUEST_ID"],["GOCD","GO_PIPELINE_LABEL"],["LAYERCI"],["HUDSON","HUDSON_URL"],["JENKINS","JENKINS_URL"],["MAGNUM"],["NETLIFY"],["NETLIFY","NETLIFY_LOCAL",{ci:!1}],["NEVERCODE"],["RENDER"],["SAIL","SAILCI"],["SEMAPHORE"],["SCREWDRIVER"],["SHIPPABLE"],["SOLANO","TDDIUM"],["STRIDER"],["TEAMCITY","TEAMCITY_VERSION"],["TRAVIS"],["VERCEL","NOW_BUILDER"],["VERCEL","VERCEL",{ci:!1}],["VERCEL","VERCEL_ENV",{ci:!1}],["APPCENTER","APPCENTER_BUILD_ID"],["CODESANDBOX","CODESANDBOX_SSE",{ci:!1}],["CODESANDBOX","CODESANDBOX_HOST",{ci:!1}],["STACKBLITZ"],["STORMKIT"],["CLEAVR"],["ZEABUR"],["CODESPHERE","CODESPHERE_APP_ID",{ci:!0}],["RAILWAY","RAILWAY_PROJECT_ID"],["RAILWAY","RAILWAY_SERVICE_ID"],["DENO-DEPLOY","DENO_DEPLOYMENT_ID"],["FIREBASE_APP_HOSTING","FIREBASE_APP_HOSTING",{ci:!0}]],wi=(function(){if(globalThis.process?.env)for(let t of nr){let e=t[1]||t[0];if(globalThis.process?.env[e])return{name:t[0].toLowerCase(),...t[2]}}return globalThis.process?.env?.SHELL==="/bin/jsh"&&globalThis.process?.versions?.webcontainer?{name:"stackblitz",ci:!1}:{name:"",ci:!1}})();wi.name;function ht(t){return!!t&&t!=="false"}let de=globalThis.process?.platform||"",Nr=ht(rt.CI)||wi.ci!==!1,ar=ht(globalThis.process?.stdout&&globalThis.process?.stdout.isTTY),Lr=(ht(rt.DEBUG),rr==="test"||ht(rt.TEST)),Ri=(ht(rt.MINIMAL),/^win/i.test(de)),or=(/^linux/i.test(de),/^darwin/i.test(de),!ht(rt.NO_COLOR)&&(ht(rt.FORCE_COLOR)||(ar||Ri)&&rt.TERM),(globalThis.process?.versions?.node||"").replace(/^v/,"")||null),hr=(Number(or?.split(".")[0]),globalThis.process||Object.create(null)),Ai={versions:{}},cr=(new Proxy(hr,{get:(t,e)=>e==="env"?rt:e in t?t[e]:e in Ai?Ai[e]:void 0}),globalThis.process?.release?.name==="node"),pr=!!globalThis.Bun||!!globalThis.process?.versions?.bun,lr=!!globalThis.Deno,ur=!!globalThis.fastly,fr=[[!!globalThis.Netlify,"netlify"],[!!globalThis.EdgeRuntime,"edge-light"],[globalThis.navigator?.userAgent==="Cloudflare-Workers","workerd"],[ur,"fastly"],[lr,"deno"],[pr,"bun"],[cr,"node"]];(function(){let t=fr.find(e=>e[0]);t&&t[1]})();let dr=B("tty"),mr=dr?.WriteStream?.prototype?.hasColors?.()??!1,_=(t,e)=>{if(!mr)return r=>r;let i=`\x1B[${t}m`,s=`\x1B[${e}m`;return r=>{let a=r+"",o=a.indexOf(s);if(o===-1)return i+a+s;let h=i,c=0,l=(e===22?s:"")+i;for(;o!==-1;)h+=a.slice(c,o)+l,c=o+s.length,o=a.indexOf(s,c);return h+=a.slice(c)+s,h}},Ti=(_(0,0),_(1,22),_(2,22),_(3,23),_(4,24),_(53,55),_(7,27),_(8,28),_(9,29),_(30,39),_(31,39)),yt=_(32,39),Wt=_(33,39),Pi=_(34,39),gr=(_(35,39),_(36,39)),xr=(_(37,39),_(90,39));_(40,49),_(41,49),_(42,49),_(43,49),_(44,49),_(45,49),_(46,49),_(47,49),_(100,49),_(91,39),_(92,39),_(93,39),_(94,39),_(95,39),_(96,39),_(97,39),_(101,49),_(102,49),_(103,49),_(104,49),_(105,49),_(106,49),_(107,49);function Ni(t){if(typeof t!="string"||t.startsWith("file://"))return!1;try{return(0,D.lstatSync)(t).isDirectory()}catch{return!1}}function Li(t,e=8){return((function(){if(_t!==void 0)return _t;try{return _t=!!fe().getFips?.(),_t}catch{return _t=!1,_t}})()?fe().createHash("sha256"):fe().createHash("md5")).update(t).digest("hex").slice(0,e)}let Oi={true:yt("true"),false:Wt("false"),"[rebuild]":Wt("[rebuild]"),"[esm]":Pi("[esm]"),"[cjs]":yt("[cjs]"),"[import]":Pi("[import]"),"[require]":yt("[require]"),"[native]":gr("[native]"),"[transpile]":Wt("[transpile]"),"[fallback]":Ti("[fallback]"),"[unknown]":Ti("[unknown]"),"[hit]":yt("[hit]"),"[miss]":Wt("[miss]"),"[json]":yt("[json]"),"[data]":yt("[data]")};function P(t,...e){if(!t.opts.debug)return;let i=process.cwd();console.log(xr(["[jiti]",...e.map(s=>s in Oi?Oi[s]:typeof s!="string"?JSON.stringify(s):s.replace(i,"."))].join(" ")))}function ct(t,e){return t.opts.interopDefault?(function(i){let s=typeof i;if(i===null||s!=="object"&&s!=="function")return i;let r=i.default,a=typeof r,o=r==null,h=a==="object"||a==="function";return o&&i instanceof Promise?i:new Proxy(i,{get(c,l,p){if(l==="__esModule")return!0;if(l==="default")return o?i:typeof r?.default=="function"&&i.__esModule?r.default:r;if(Reflect.has(c,l))return Reflect.get(c,l,p);if(h&&!(r instanceof Promise)){let f=Reflect.get(r,l,p);return typeof f=="function"&&(f=f.bind(r)),f}},apply:(c,l,p)=>typeof c=="function"?Reflect.apply(c,l,p):a==="function"?Reflect.apply(r,l,p):void 0})})(e):e}let _t;function Z(t,e){return!!Et(t,e)}function Et(t,e){let i=process.env[t];if(!(t in process.env))return e;try{return JSON.parse(i)}catch{return e}}let Di=/\.(c|m)?j(sx?)$/,Vi=/\.(c|m)?t(sx?)$/;function Tt(t,e,i){let s,r;if(t.isNativeRe.test(e))return e;t.alias&&(e=(function(h,c){let l=gt(h);c=Ii(c);for(let[p,f]of Object.entries(c)){if(!l.startsWith(p))continue;let u=ki(p)?p.slice(0,-1):p;if(ki(l[u.length]))return it(f,l.slice(p.length))}return l})(e,t.alias));let a=i?.parentURL||t.url;Ni(a)&&(a=it(a,"_index.js"));let o=(i?.async?[i?.conditions,["node","import"],["node","require"]]:[i?.conditions,["node","require"],["node","import"]]).filter(Boolean);for(let h of o){try{s=Ys(e,{url:a,conditions:h,extensions:t.opts.extensions})}catch(c){r=c}if(s)return s}try{return t.nativeRequire.resolve(e,{paths:i.paths})}catch(h){r=h}for(let h of t.additionalExts)if(s=me(t,e+h,a,i)||me(t,e+"/index"+h,a,i),s||(Vi.test(t.filename)||Vi.test(t.parentModule?.filename||"")||Di.test(e))&&(s=me(t,e.replace(Di,".$1t$2"),a,i),s))return s;if(!i?.try)throw r}function me(t,e,i,s){try{return t.nativeRequire.resolve(e,{...s,paths:[Mt(Rt(i)),...s?.paths||[]]})}catch{}}let Ui=B("perf_hooks"),vr=B("vm");var yr=H.n(vr);function ge(t,e,i){let s=t.parentCache||{};if(e.startsWith("node:"))return pt(t,e,i.async);if(e.startsWith("file:"))e=(0,g.fileURLToPath)(e);else if(e.startsWith("data:")){if(!i.async)throw new Error("`data:` URLs are only supported in ESM context. Use `import` or `jiti.import` instead.");return P(t,"[native]","[data]","[import]",e),pt(t,e,!0)}if(mt.builtinModules.includes(e)||e===".pnp.js")return pt(t,e,i.async);if(t.opts.tryNative&&!t.opts.transformOptions)try{if(!(e=Tt(t,e,i))&&i.try)return;if(P(t,"[try-native]",i.async&&t.nativeImport?"[import]":"[require]",e),i.async&&t.nativeImport)return t.nativeImport(e).then(h=>(t.opts.moduleCache===!1&&delete t.nativeRequire.cache[e],ct(t,h)));{let h=t.nativeRequire(e);return t.opts.moduleCache===!1&&delete t.nativeRequire.cache[e],ct(t,h)}}catch(h){P(t,`[try-native] Using fallback for ${e} because of an error:`,h)}let r=Tt(t,e,i);if(!r&&i.try)return;let a=ti(r);if(a===".json"){P(t,"[json]",r);let h=t.nativeRequire(r);return h&&!("default"in h)&&Object.defineProperty(h,"default",{value:h,enumerable:!1}),h}if(a&&!t.opts.extensions.includes(a))return P(t,"[native]","[unknown]",i.async?"[import]":"[require]",r),pt(t,r,i.async);if(t.isNativeRe.test(r))return P(t,"[native]",i.async?"[import]":"[require]",r),pt(t,r,i.async);if(s[r])return ct(t,s[r]?.exports);if(t.opts.moduleCache){let h=t.nativeRequire.cache[r];if(h?.loaded)return ct(t,h.exports)}let o=(0,D.readFileSync)(r,"utf8");return ve(t,o,{id:e,filename:r,ext:a,cache:s,async:i.async})}function pt(t,e,i){return i&&t.nativeImport?t.nativeImport((function(s){return Ri&&at(s)?vt(s):s})(e)).then(s=>ct(t,s)):ct(t,t.nativeRequire(e))}let _r="9";function Er(t,e,i){if(!t.opts.fsCache||!e.filename)return i();let s=` /* v${_r}-${Li(e.source,16)} */
20
+ `,r=`${ei(Mt(e.filename))}-${(function(c){let l=c.split(er).pop();if(!l)return;let p=l.lastIndexOf(".");return p<=0?l:l.slice(0,p)})(e.filename)}`+(t.opts.sourceMaps?"+map":"")+(e.interopDefault?".i":"")+`.${Li(e.filename)}`+(e.async?".mjs":".cjs");e.jsx&&e.filename.endsWith("x")&&(r+="x");let a=t.opts.fsCache,o=it(a,r);if(!t.opts.rebuildFsCache&&(0,D.existsSync)(o)){let c=(0,D.readFileSync)(o,"utf8");if(c.endsWith(s))return P(t,"[cache]","[hit]",e.filename,"~>",o),c}P(t,"[cache]","[miss]",e.filename);let h=i();return h.includes("__JITI_ERROR__")||((0,D.writeFileSync)(o,h+s,"utf8"),P(t,"[cache]","[store]",e.filename,"~>",o)),h}function br(t){if(t.opts.fsCache===!0&&(t.opts.fsCache=(function(e){let i=e.filename&&bs(e.filename,"../node_modules");if(i&&(0,D.existsSync)(i))return it(i,".cache/jiti");let s=(0,T.tmpdir)();if(process.env.TMPDIR&&s===process.cwd()&&!process.env.JITI_RESPECT_TMPDIR_ENV){let r=process.env.TMPDIR;delete process.env.TMPDIR,s=(0,T.tmpdir)(),process.env.TMPDIR=r}return it(s,"jiti")})(t)),t.opts.fsCache)try{if((0,D.mkdirSync)(t.opts.fsCache,{recursive:!0}),!(function(e){try{return(0,D.accessSync)(e,D.constants.W_OK),!0}catch{return!1}})(t.opts.fsCache))throw new Error("directory is not writable!")}catch(e){P(t,"Error creating cache directory at ",t.opts.fsCache,e),t.opts.fsCache=!1}}function xe(t,e){let i=Er(t,e,()=>{let s=t.opts.transform({...t.opts.transformOptions,babel:{...t.opts.sourceMaps?{sourceFileName:e.filename,sourceMaps:"inline"}:{},...t.opts.transformOptions?.babel},interopDefault:t.opts.interopDefault,...e});return s.error&&t.opts.debug&&P(t,s.error),s.code});return i.startsWith("#!")&&(i="// "+i),i}function ve(t,e,i={}){let s=i.id||(i.filename?ei(i.filename):`_jitiEval.${i.ext||(i.async?"mjs":"js")}`),r=i.filename||Tt(t,s,{async:i.async}),a=i.ext||ti(r),o=i.cache||t.parentCache||{},h=/\.[cm]?tsx?$/.test(a),c=a===".mjs"||a===".js"&&(function(k){for(;k&&k!=="."&&k!=="/";){k=it(k,"..");try{let lt=(0,D.readFileSync)(it(k,"package.json"),"utf8");try{return JSON.parse(lt)}catch{}break}catch{}}})(r)?.type==="module",l=a===".cjs",p=i.forceTranspile??(!l&&!(c&&i.async)&&(h||c||t.isTransformRe.test(r)||Xs(e))),f=Ui.performance.now();if(p){e=xe(t,{filename:r,source:e,ts:h,async:i.async??!1,jsx:t.opts.jsx});let k=Math.round(1e3*(Ui.performance.now()-f))/1e3;P(t,"[transpile]",i.async?"[esm]":"[cjs]",r,`(${k}ms)`)}else{if(P(t,"[native]",i.async?"[import]":"[require]",r),i.async)return Promise.resolve(pt(t,r,i.async)).catch(k=>(P(t,"Native import error:",k),P(t,"[fallback]",r),ve(t,e,{...i,forceTranspile:!0})));try{return pt(t,r,i.async)}catch(k){P(t,"Native require error:",k),P(t,"[fallback]",r),e=xe(t,{filename:r,source:e,ts:h,async:i.async??!1,jsx:t.opts.jsx})}}let u=new mt.Module(r);u.filename=r,t.parentModule&&(u.parent=t.parentModule,Array.isArray(t.parentModule.children)&&!t.parentModule.children.includes(u)&&t.parentModule.children.push(u));let v=Mi(r,t.opts,{parentModule:u,parentCache:o,nativeImport:t.nativeImport,onError:t.onError,createRequire:t.createRequire},!0),w;u.require=v,u.path=Mt(r),u.paths=mt.Module._nodeModulePaths(u.path),o[r]=u,t.opts.moduleCache&&(t.nativeRequire.cache[r]=u);let y=(function(k,lt){return`(${lt?.async?"async ":""}function (exports, require, module, __filename, __dirname, jitiImport, jitiESMResolve) { ${k}
21
+ });`})(e,{async:i.async});try{w=yr().runInThisContext(y,{filename:r,lineOffset:0,displayErrors:!1})}catch(k){k.name==="SyntaxError"&&i.async&&t.nativeImport?(P(t,"[esm]","[import]","[fallback]",r),w=(function(lt,ye){let _e=`data:text/javascript;base64,${Buffer.from(`export default ${lt}`).toString("base64")}`;return(...Ee)=>ye(_e).then(Gt=>Gt.default(...Ee))})(y,t.nativeImport)):(t.opts.moduleCache&&delete t.nativeRequire.cache[r],t.onError(k))}let I;try{I=w(u.exports,u.require,u,u.filename,Mt(u.filename),v.import,v.esmResolve)}catch(k){t.opts.moduleCache&&delete t.nativeRequire.cache[r],t.onError(k)}function C(){if(u.exports&&u.exports.__JITI_ERROR__){let{filename:k,line:lt,column:ye,code:_e,message:Ee}=u.exports.__JITI_ERROR__,Gt=new Error(`${_e}: ${Ee}
22
+ ${`${k}:${lt}:${ye}`}`);Error.captureStackTrace(Gt,ge),t.onError(Gt)}return u.loaded=!0,ct(t,u.exports)}return i.async?Promise.resolve(I).then(C):C()}let Sr=(0,T.platform)()==="win32";function Mi(t,e={},i,s=!1){let r=s?e:(function(y){let I={fsCache:Z("JITI_FS_CACHE",Z("JITI_CACHE",!0)),rebuildFsCache:Z("JITI_REBUILD_FS_CACHE",!1),moduleCache:Z("JITI_MODULE_CACHE",Z("JITI_REQUIRE_CACHE",!0)),debug:Z("JITI_DEBUG",!1),sourceMaps:Z("JITI_SOURCE_MAPS",!1),interopDefault:Z("JITI_INTEROP_DEFAULT",!0),extensions:Et("JITI_EXTENSIONS",[".js",".mjs",".cjs",".ts",".tsx",".mts",".cts",".mtsx",".ctsx"]),alias:Et("JITI_ALIAS",{}),nativeModules:Et("JITI_NATIVE_MODULES",[]),transformModules:Et("JITI_TRANSFORM_MODULES",[]),tryNative:Et("JITI_TRY_NATIVE","Bun"in globalThis),jsx:Z("JITI_JSX",!1)};I.jsx&&I.extensions.push(".jsx",".tsx");let C={};return y.cache!==void 0&&(C.fsCache=y.cache),y.requireCache!==void 0&&(C.moduleCache=y.requireCache),{...I,...C,...y}})(e),a=r.alias&&Object.keys(r.alias).length>0?Ii(r.alias||{}):void 0,o=["typescript","jiti",...r.nativeModules||[]],h=new RegExp(`node_modules/(${o.map(y=>Si(y)).join("|")})/`),c=[...r.transformModules||[]],l=new RegExp(`node_modules/(${c.map(y=>Si(y)).join("|")})/`);t||(t=process.cwd()),!s&&Ni(t)&&(t=it(t,"_index.js"));let p=vt(t),f=[...r.extensions].filter(y=>y!==".js"),u=i.createRequire(Sr?t.replace(/\//g,"\\"):t),v={filename:t,url:p,opts:r,alias:a,nativeModules:o,transformModules:c,isNativeRe:h,isTransformRe:l,additionalExts:f,nativeRequire:u,onError:i.onError,parentModule:i.parentModule,parentCache:i.parentCache,nativeImport:i.nativeImport,createRequire:i.createRequire};return s||P(v,"[init]",...[["version:",ir.rE],["module-cache:",r.moduleCache],["fs-cache:",r.fsCache],["rebuild-fs-cache:",r.rebuildFsCache],["interop-defaults:",r.interopDefault]].flat()),s||br(v),Object.assign(function(y){return ge(v,y,{async:!1})},{cache:r.moduleCache?u.cache:Object.create(null),extensions:u.extensions,main:u.main,options:r,resolve:Object.assign(function(y){return Tt(v,y,{async:!1})},{paths:u.resolve.paths}),transform:y=>xe(v,y),evalModule:(y,I)=>ve(v,y,I),async import(y,I){let C=await ge(v,y,{...I,async:!0});return I?.default?C?.default??C:C},esmResolve(y,I){typeof I=="string"&&(I={parentURL:I});let C=Tt(v,y,{parentURL:p,...I,async:!0});return!C||typeof C!="string"||C.startsWith("file://")?C:vt(C)}})}})(),ji.exports=Se.default})()});import{createRequire as Fi}from"module";function wr(Y){throw Y}function Ar(...Y){return be||(be=Fi(import.meta.url)("../dist/babel.cjs")),be(...Y)}function Tr(Y,nt={}){return nt.transform||(nt={...nt,transform:Ar}),(0,$i.default)(Y,nt,{onError:wr,nativeImport:Rr,createRequire:Fi})}var $i,Rr,be,Vr,Pr=Cr(()=>{$i=kr(Bi(),1);Rr=Y=>import(Y);Vr=Tr});Pr();export{Tr as createJiti,Vr as default};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@batijs/core",
3
- "version": "0.0.544",
3
+ "version": "0.0.547",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "types": "./dist/index.d.ts",
@@ -38,7 +38,7 @@
38
38
  "vue-eslint-parser": "^10.2.0",
39
39
  "which": "^6.0.0",
40
40
  "yaml": "^2.8.2",
41
- "@batijs/features": "0.0.544"
41
+ "@batijs/features": "0.0.547"
42
42
  },
43
43
  "exports": {
44
44
  ".": "./dist/index.js",