@batijs/core 0.0.87 → 0.0.88
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 +15 -6
- package/dist/index.js +3 -3
- package/dist/rules.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -4,25 +4,32 @@ export { addVitePlugin } from 'magicast/helpers';
|
|
|
4
4
|
export { default as which } from 'which';
|
|
5
5
|
import { Color } from 'colorette';
|
|
6
6
|
|
|
7
|
-
declare const features: readonly ["framework:solid", "framework:react", "framework:vue", "db:edgedb", "db:prisma", "auth:authjs", "rpc:telefunc", "server:hattip", "server:express", "server:h3", "uikit:tailwindcss", "analytics:plausible.io", "hosting:vercel"];
|
|
8
|
-
declare const flags: Map<Flags, "framework:solid" | "framework:react" | "framework:vue" | "db:edgedb" | "db:prisma" | "auth:authjs" | "rpc:telefunc" | "server:hattip" | "server:express" | "server:h3" | "uikit:tailwindcss" | "analytics:plausible.io" | "hosting:vercel">;
|
|
7
|
+
declare const features: readonly ["framework:solid", "framework:react", "framework:vue", "db:edgedb", "db:prisma", "auth:authjs", "rpc:telefunc", "server:hattip", "server:express", "server:h3", "uikit:tailwindcss", "analytics:plausible.io", "hosting:vercel", "tool:eslint"];
|
|
8
|
+
declare const flags: Map<Flags, "framework:solid" | "framework:react" | "framework:vue" | "db:edgedb" | "db:prisma" | "auth:authjs" | "rpc:telefunc" | "server:hattip" | "server:express" | "server:h3" | "uikit:tailwindcss" | "analytics:plausible.io" | "hosting:vercel" | "tool:eslint">;
|
|
9
9
|
type BeforeColon<T extends string> = T extends `${infer A}:${string}` ? A : never;
|
|
10
10
|
type AfterColon<T extends string> = T extends `${string}:${infer B}` ? B : never;
|
|
11
11
|
type Flags = AfterColon<(typeof features)[number]>;
|
|
12
12
|
type Namespaces = BeforeColon<(typeof features)[number]>;
|
|
13
13
|
|
|
14
|
-
type
|
|
14
|
+
type ContentGetter = () => string | Promise<string>;
|
|
15
15
|
interface VikeMeta {
|
|
16
16
|
BATI_MODULES?: (typeof features)[number][];
|
|
17
17
|
}
|
|
18
|
+
type TransformerProps = {
|
|
19
|
+
readfile?: ContentGetter;
|
|
20
|
+
target: string;
|
|
21
|
+
source: string;
|
|
22
|
+
meta: VikeMeta;
|
|
23
|
+
};
|
|
24
|
+
type Transformer = (props: TransformerProps) => unknown;
|
|
18
25
|
|
|
19
26
|
declare function transformAstAndGenerate(tree: ASTNode, meta: VikeMeta, options?: {
|
|
20
27
|
filepath?: string;
|
|
21
28
|
}): Promise<string>;
|
|
22
29
|
declare function renderSquirrelly(template: string, meta: VikeMeta): string;
|
|
23
30
|
|
|
24
|
-
declare function loadAsJson(
|
|
25
|
-
declare function loadAsMagicast<Exports extends object>(
|
|
31
|
+
declare function loadAsJson({ readfile, source, target }: TransformerProps): Promise<any>;
|
|
32
|
+
declare function loadAsMagicast<Exports extends object>({ readfile, source, target, }: TransformerProps): Promise<ProxifiedModule<Exports>>;
|
|
26
33
|
declare function loadRelativeFileAsMagicast<Exports extends object>(relativePath: string, meta: Pick<ImportMeta, "url">): Promise<ProxifiedModule<Exports>>;
|
|
27
34
|
|
|
28
35
|
interface PackageJsonDeps {
|
|
@@ -34,6 +41,7 @@ interface PackageJsonScripts {
|
|
|
34
41
|
dev?: string;
|
|
35
42
|
build?: string;
|
|
36
43
|
preview?: string;
|
|
44
|
+
lint?: string;
|
|
37
45
|
};
|
|
38
46
|
}
|
|
39
47
|
interface PackageJsonScriptOption {
|
|
@@ -45,6 +53,7 @@ interface PackageJsonScriptOptions {
|
|
|
45
53
|
dev?: PackageJsonScriptOption;
|
|
46
54
|
build?: PackageJsonScriptOption;
|
|
47
55
|
preview?: PackageJsonScriptOption;
|
|
56
|
+
lint?: PackageJsonScriptOption;
|
|
48
57
|
}
|
|
49
58
|
declare function addDependency<T extends PackageJsonDeps, U extends PackageJsonDeps>(packageJson: T, scopedPackageJson: U, keys: {
|
|
50
59
|
devDependencies?: (keyof U["dependencies"] | keyof U["devDependencies"])[];
|
|
@@ -54,4 +63,4 @@ declare function setScripts<T extends PackageJsonScripts>(packageJson: T, script
|
|
|
54
63
|
|
|
55
64
|
declare function withIcon(icon: string, iconColor?: Color, indentLevel?: number): (str: string) => string;
|
|
56
65
|
|
|
57
|
-
export {
|
|
66
|
+
export { ContentGetter, Flags, Namespaces, PackageJsonDeps, PackageJsonScriptOption, PackageJsonScriptOptions, PackageJsonScripts, Transformer, TransformerProps, VikeMeta, addDependency, features, flags, loadAsJson, loadAsMagicast, loadRelativeFileAsMagicast, renderSquirrelly, setScripts, transformAstAndGenerate, withIcon };
|
package/dist/index.js
CHANGED
|
@@ -224,7 +224,7 @@ ${e}`;W2.exports.mergeShebang=(e,t)=>e?e+Att(t):t;W2.exports.cutShebang=e=>{if(e
|
|
|
224
224
|
|
|
225
225
|
"off" means rule is off
|
|
226
226
|
"on" means it is a on
|
|
227
|
-
`,enum:["on","off"]}],minItems:2,maxItems:2}},properties:{parser:{description:"Tell \u{1F40A}Putout which parser to use",type:"string"},printer:{description:"Tell \u{1F40A}Putout which printer to use",oneOf:[{type:"string"},{type:"array",minItems:2,maxItems:2,items:[{type:"string"},{type:"object"}]}]},formatter:{description:"Choose the way to show information about errors found",type:["string","array"]},processors:{description:"Tell \u{1F40A}Putout which processors to use to support file types other then JavaScript",type:"array",uniqueItems:!0,items:{oneOf:[{$ref:"#/definitions/processorToggle"},{type:"string"}]}},ignore:{description:"Tell \u{1F40A}Putout to ignore specific files and directories.",type:"array",uniqueItems:!0,items:{type:"string"}},match:{description:"Allows to match rules for files and folders, specified by glob patterns.",type:"object",patternProperties:{"^.*$":{$ref:"#/definitions/rules"}}},plugins:{description:"Tell \u{1F40A}Putout which plugins to load",type:"array",uniqueItems:!0},rules:{$ref:"#/definitions/rules"}}}});var mte=F((l2t,dte)=>{"use strict";var lpt=pte(),cpt=fte(),ppt=new lpt({strict:!0,allowUnionTypes:!0}),hte=ppt.compile(cpt);dte.exports.validateOptions=e=>{hte(e);let[t]=hte.errors||[];if(t)throw Error(`.putout.json: ${mpt(t)}${dpt(t)}${hpt(t)}${fpt(t)}`)};function fpt(e){let{allowedValues:t}=e.params;return t?` (${t.join("/")})`:""}function hpt(e){return e.message.replace(","," or ")}var dpt=e=>{let{additionalProperty:t}=e.params;return t?`${t}: `:""},mpt=e=>{let{instancePath:t}=e;return t?`${e.instancePath.slice(1)}: `:""}});var Ete=F((c2t,Ste)=>{"use strict";var ypt=It("process"),{homedir:gpt}=It("os"),{readdirSync:xpt}=It("fs"),{dirname:bpt,join:xS}=It("path"),gte=Fa(),g3=xp(),Spt=DI(),y3=MI(),yte=MQ(),gS=Rb(),Ept=KQ(),Tpt=XQ(),{validateOptions:vpt}=mte(),xte=gpt();Ste.exports=(e={})=>{let{rulesdir:t,name:r="",options:s={},readOptions:i=Cpt,readHomeOptions:n=Ppt,readCodeMods:a=wpt}=e,[o,u]=i(r),c=n(),p=y3(r,yte.match),g=gS(...[yte,c,p,u,s]),d=gS(g,y3(r,g.match),s),h=gS(u,s,y3(r,s.match)),b=gS(a(),bte("./",t),g,d,h);return vpt(b),{...b,dir:o}};var Apt=e=>(t,r)=>r.includes(e)&&e;function Cpt(e){let[t,r]=Ept(e,".putout.json"),[,s]=g3(Spt,e,Apt("package.json"));return s&&Tpt(It(s),r),t?[t,r]:s?[bpt(s),{...r,...It(s).putout}]:["",{}]}var Dpt=e=>e[0]!=="."&&!/(^not-rule-.*|^node_modules$)/.test(e);function bte(e,t){if(!t)return{};let r=xS(e,t);r.startsWith("/")||(r=xS(ypt.cwd(),t));let[s,i]=g3(xpt,r);if(s)return{};let n=[];for(let a of i.filter(Dpt)){let o=xS(r,a);n.push(`import:${o}`)}return{plugins:n}}var Ppt=gte(()=>{let e=xS(xte,".putout.json"),[,t={}]=g3(It,e);return t}),wpt=gte(()=>bte(xte,".putout"))});var Nte=F((y2t,Lu)=>{"use strict";var{isIdentifier:sc,isObjectExpression:Pte,isObjectPattern:_pt,isTemplateLiteral:Opt,isAssignmentPattern:Bpt}=Wi().types,wte=({use:e,declare:t})=>{let r=S3({use:e});return s=>{for(let i of s){if(i.isRestElement())continue;let{key:n,value:a}=i.node,o=i.get("value");switch(a.type){case"Identifier":t(i,a.name);break;case"AssignmentPattern":i.node.shorthand?t(i,n.name):t(i,o.node.left.name),r(o);break}}}};Lu.exports.traverseObjectPattern=wte;var Ite=({use:e,declare:t})=>r=>{for(let s of r){let{key:i,value:n,computed:a}=s.node;if(a&&sc(i)&&e(s,i.name),sc(n)){t(s,n.name);continue}if(_pt(n)){Ite({use:e,declare:t})(s.get("value.properties"));continue}if(Bpt(n)){S3({use:e})(s.get("value.right"));let u=s.get("value.left");switch(u.type){case"Identifier":t(s,u.node.name);continue}}}};Lu.exports.processObjectPattern=Ite;var b3=e=>{let t=kte(e);return r=>{for(let s of r){let{node:i}=s,{key:n,value:a,computed:o}=i;if(o&&sc(n)&&e(s,n.name),sc(a)){e(s,a.name);continue}if(Opt(a)){t(s,a.expressions);continue}if(Pte(a)){b3(e)(s.get("value.properties"));continue}}}};Lu.exports.traverseObjectExpression=b3;var Lpt=e=>{let t=b3(e);return r=>{for(let s of r){let{node:i}=s;Pte(i)&&t(s.get("properties"))}}};Lu.exports.traverseArrayExpression=Lpt;var Mpt=({use:e,declare:t})=>{let r=wte({use:e,declare:t});return s=>{let i=s.get("left"),n=s.get("right");if(i.isIdentifier()){let{parentPath:a}=i.parentPath,{name:o}=i.node;a.isObjectProperty()&&t(a,o),a.isFunction()&&t(i.parentPath,o)}n.isIdentifier()&&e(n,n.node.name),i.isObjectPattern()&&r(i.get("properties"))}};Lu.exports.traverseAssignmentExpression=Mpt;var kte=e=>(t,r)=>{for(let s of r)sc(s)&&e(t,s.name)};Lu.exports.traverseTemplateLiteral=kte;var S3=({use:e})=>t=>{let{node:r}=t,{right:s}=r;sc(r)&&e(t.parentPath,r.name),sc(s)&&e(t,s.name)};Lu.exports.traverseAssignmentPattern=S3});var _te=F((g2t,Fte)=>{"use strict";var{types:Rpt}=Wi(),{isIdentifier:jpt,isJSXIdentifier:$pt}=Rpt;Fte.exports=e=>({JSXOpeningElement(t){let{node:r}=t,{name:s}=r;/^[A-Z]/.test(s.name)&&e(t,s.name),e(t,"React")},JSXFragment(t){e(t,"React")},JSXSpreadAttribute(t){let r=t.get("argument");if(r.isIdentifier())return e(t,r.node.name)},JSXMemberExpression(t){let{node:r}=t,{object:s}=r;$pt(s)&&e(t,s.name)},JSXExpressionContainer(t){let{node:r}=t,{expression:s}=r;jpt(s)&&e(t,s.name)}})});var Bte=F((x2t,Ote)=>{"use strict";var{types:qpt}=Wi(),{isIdentifier:Upt}=qpt;Ote.exports=({use:e,declare:t})=>({GenericTypeAnnotation(r){let{node:s}=r,{id:i}=s;Upt(i)&&e(r,i.name)},QualifiedTypeIdentifier(r){let{qualification:s}=r.node,{type:i}=s;switch(i){case"Identifier":return e(r,s.name)}},InterfaceDeclaration(r){t(r,r.node.id.name)}})});var Mte=F((b2t,Lte)=>{"use strict";var{types:Vpt}=Wi(),{isIdentifier:Jpt,isTSModuleDeclaration:Kpt}=Vpt;Lte.exports=({use:e,declare:t})=>({TSExpressionWithTypeArguments(r){let{expression:s}=r.node,{type:i}=s;switch(i){case"Identifier":e(r,s.name)}},TSFunctionType(r){let{node:s}=r,{params:i}=s;for(let n of i){let{type:a}=n;switch(a){case"Identifier":t(r,n.name),e(r,n.name);break;case"RestElement":Jpt(n.argument)&&(t(r,n.argument.name),e(r,n.argument.name))}}},TSTypeReference(r){let{node:s}=r,{typeName:i}=s,{type:n}=i;switch(n){case"Identifier":e(r,i.name)}},TSTypeAliasDeclaration(r){let{node:s}=r,{id:i}=s,{type:n}=i;switch(n){case"Identifier":t(r,i.name)}},TSTypeQuery(r){let{node:s}=r,{exprName:i}=s,{type:n}=i;switch(n){case"Identifier":e(r,i.name)}},TSAsExpression(r){let{node:s}=r,{expression:i}=s,{type:n}=i;switch(n){case"Identifier":e(r,i.name)}},TSQualifiedName(r){let{node:s}=r,{left:i}=s,{type:n}=i;switch(n){case"Identifier":e(r,i.name)}},TSInterfaceDeclaration(r){t(r,r.node.id.name),r.findParent(Kpt)&&e(r,r.node.id.name)},TSMethodSignature(r){let s=r.get("params");for(let i of s){if(i.isIdentifier()){t(i,i.node.name),e(i,i.node.name);continue}let{type:n}=i;switch(n){case"RestElement":t(i,i.node.argument.name),e(i,i.node.argument.name);continue}}},TSDeclareFunction(r){if(!r.get("params").length)return;let[i]=r.get("params");i.isRestElement()&&e(i,i.node.argument.name)}})});var Vte=F((S2t,Ute)=>{"use strict";var{isAssignmentPattern:Rte,isClassDeclaration:Wpt,isIdentifier:Wt,isSpreadElement:Xpt,isObjectPattern:jte,isObjectExpression:zpt,isFunctionDeclaration:Hpt,isArrayExpression:Gpt,isVariableDeclaration:Ypt,isRestElement:Qpt}=Wi().types,{traverseObjectExpression:Zpt,processObjectPattern:eft,traverseArrayExpression:tft,traverseAssignmentExpression:rft,traverseTemplateLiteral:sft}=Nte(),ift=_te(),nft=Bte(),aft=Mte(),{assign:$te}=Object;Ute.exports=({use:e,declare:t,addParams:r})=>{let s=Zpt(e),i=eft({use:e,declare:t}),n=rft({use:e,declare:t}),a=sft(e),o=tft(e);return{"ObjectExpression|RecordExpression"(u){s(u.get("properties"))},SequenceExpression(u){for(let c of u.get("expressions"))c.isIdentifier()&&e(c,c.node.name)},"AwaitExpression|YieldExpression|SpreadElement"(u){let{argument:c}=u.node;Wt(c)&&e(u,c.name)},CatchClause(u){let c=u.get("param");if(!c.isIdentifier())return;let{name:p}=c.node;t(c,p),u.scope.getOwnBinding(p).referenced&&e(c,p)},Decorator(u){let c=u.get("expression");if(!c.isIdentifier())return;let{name:p}=c.node;e(c,p)},RestElement(u){let{argument:c}=u.node;Wt(c)&&t(u,c.name)},VariableDeclarator(u){let{node:c}=u,{init:p}=c,m=u.get("id"),g=u.parentPath.parentPath.isForInStatement();if(Wt(c.id))t(u,c.id.name),g&&e(u,c.id.name);else if(jte(c.id))m.traverse({ObjectProperty(h){if(Rte(h.node.value)&&n(h.get("value")),h.node.computed&&Wt(h.node.key)&&e(h.get("key"),h.node.key.name),!Wt(h.node.value))return;let{properties:b}=c.id,T=b.length===1?u:h,{name:C}=h.node.value;t(T,C),Qpt(h.parentPath.node.properties.at(-1))&&e(T,C)}});else if(m.isArrayPattern()){let h=m.get("elements");for(let b of h){if(b.isObjectPattern()){i(b.get("properties"));continue}if(b.isAssignmentPattern()){let S=b.get("left"),T=b.get("right");t(S,b.node.left.name),e(T,b.node.right.name),$te(S,{remove:qte(b)})}b.isIdentifier()&&($te(b,{remove:qte(b)}),t(b,b.node.name))}}let d=u.get("init");Wt(p)?e(u,p.name):Gpt(p)&&o(d.get("elements"))},ClassProperty(u){let c=u.get("value");c.isIdentifier()&&e(c,c.node.name)},"ClassDeclaration|ClassExpression"(u){let{node:c}=u,{id:p,superClass:m}=c;m&&e(u,m.name),p&&t(u,p.name),p&&u.isClassExpression()&&e(u,p.name)},AssignmentExpression(u){let c=u.get("left"),p=u.get("right");c.isIdentifier()&&e(c,c.node.name),p.isIdentifier()&&e(p,p.node.name)},"ArrayExpression|TupleExpression"(u){let{elements:c}=u.node;for(let p of c){if(Wt(p)){e(u,p.name);continue}if(Xpt(p)){e(u,p.argument.name);continue}}},ConditionalExpression(u){let{test:c,consequent:p,alternate:m}=u.node,g=u.get("alternate"),d=u.get("consequent");Wt(c)&&e(u,c.name),Wt(p)&&e(u,p.name),Wt(m)&&e(u,m.name),g.isFunction()&&m.id&&e(g,m.id.name),d.isFunction()&&p.id&&e(d,p.id.name)},DoWhileStatement(u){let c=u.get("test");c.isIdentifier()&&e(c,c.node.name)},TemplateLiteral(u){a(u,u.node.expressions)},LogicalExpression(u){let{left:c,right:p}=u.node;Wt(c)&&e(u,c.name),Wt(p)&&e(u,p.name)},MemberExpression(u){let{property:c,object:p,computed:m}=u.node;Wt(p)&&e(u,p.name),m&&Wt(c)&&e(u,c.name)},OptionalMemberExpression(u){let{object:c,property:p,computed:m}=u.node;Wt(c)&&e(u,c.name),m&&Wt(p)&&e(u,p.name)},NewExpression(u){let c=u.get("callee"),{node:p}=u;c.isIdentifier()?e(u,p.callee.name):c.isFunction()&&e(c,c.node.id.name);let m=u.get("arguments");for(let{node:g}of m)if(Wt(g)){e(u,g.name);continue}},TaggedTemplateExpression(u){let{tag:c}=u.node;Wt(c)&&e(u,c.name)},UnaryExpression(u){let{argument:c}=u.node;Wt(c)&&e(u,c.name)},UpdateExpression(u){let{argument:c}=u.node;Wt(c)&&e(u,c.name)},ThrowStatement(u){let{argument:c}=u.node;Wt(c)&&e(u,c.name)},IfStatement(u){let{node:c}=u,{test:p}=c;if(Wt(p))return e(u,p.name)},ForInStatement(u){let{node:c}=u,{left:p,right:m}=c;Wt(p)&&e(u,p.name),Wt(m)&&e(u,m.name)},ForOfStatement(u){let{node:c}=u,{left:p,right:m}=c;Wt(m)&&e(u,m.name),Wt(p)?e(u,p.name):u.get("left").traverse({Identifier(g){t(u,g.node.name)}}),u.get("left").traverse({Identifier(g){e(g,g.node.name)}})},ExpressionStatement(u){let{node:c}=u;Wt(c.expression)&&e(u,c.expression.name)},SwitchStatement(u){let{node:c}=u;Wt(c.discriminant)&&e(u,c.discriminant.name);for(let{test:p}of c.cases)Wt(p)&&e(u,p.name)},ReturnStatement(u){let{node:c}=u,{argument:p}=c,m=u.get("argument");if(m.isIdentifier())return e(u,p.name);if(m.isFunction()&&p.id)return e(m,p.id.name)},ObjectMethod(u){let{params:c}=u.node,p=u.get("params");for(let m of p){let{node:g}=m;if(Wt(g)){t(m,g.name);continue}}r({path:u,params:c})},"CallExpression|OptionalCallExpression"(u){let{node:c}=u,{callee:p}=c;Wt(p)&&e(u,c.callee.name),u.traverse({SpreadElement(m){let{argument:g}=m.node;Wt(g)&&e(m,g.name)},Identifier(m){c.arguments.includes(m.node)&&e(m,m.node.name)}})},BinaryExpression(u){let{left:c,right:p}=u.node;Wt(c)&&e(u,c.name),Wt(p)&&e(u,p.name)},ImportDeclaration(u){let c=u.get("specifiers");for(let p of c){let{local:m}=p.node;Wt(m)&&t(p,m.name)}},ExportDefaultDeclaration(u){let c=u.get("declaration"),{declaration:p}=u.node,{id:m}=p;m&&Hpt(p)?e(u,p.id.name):Wt(p)?e(u,p.name):m&&Wpt(p)?e(u,p.id.name):zpt(p)&&s(c.get("properties"))},ExportNamedDeclaration(u){let c=u.get("declaration"),{declaration:p,specifiers:m}=u.node;if(c.isFunctionDeclaration()||c.isClassDeclaration()||c.isTSInterfaceDeclaration()||c.isTSTypeAliasDeclaration()||c.isInterfaceDeclaration())return e(u,p.id.name);if(Ypt(p)){let{declarations:g}=p;for(let{id:d}of g)Wt(d)&&e(u,d.name);return}for(let{local:g}of m)Wt(g)&&e(u,g.name)},Function(u){let{node:c,parentPath:p}=u,{id:m,body:g,params:d}=c,h=u.get("params");m&&(t(u,c.id.name),!p.isBlock()&&!p.isProgram()&&e(u,c.id.name));for(let b of h){let{node:S}=b;if(Wt(S)){t(b,S.name);continue}if(Rte(S)){n(b);continue}if(jte(S)){i(b.get("properties"));continue}}Wt(g)&&e(u,g.name),r({path:u,params:d})},...ift(e),...nft({use:e,declare:t}),...aft({use:e,declare:t})}};var qte=e=>{let{remove:t}=e;return()=>{let r=e.node,{elements:s}=e.parentPath.node,i=s.length-1;if(s.indexOf(r)===i)return t.call(e)}}});var Wte=F((E2t,E3)=>{"use strict";var{types:oft}=Wi(),{isIdentifier:Jte,isObjectPattern:uft,isRestElement:lft}=oft;E3.exports.usePropertiesBeforeRest=({use:e})=>({path:t,params:r})=>{for(let s of r)uft(s)&&cft(e,t,s.properties)};function cft(e,t,r){let{length:s}=r,i=r.at(-1);if(lft(i))for(let n=0;n<s-1;n++){let{value:a}=r[n],{type:o}=a;switch(o){case"Identifier":e(t,a.name);continue}}}E3.exports.useParamsBeforeLastUsed=({use:e,isUsed:t})=>({path:r,params:s})=>{let i=s.length;for(;--i>0;){let n=s[i];if(pft(t,r,n))break}for(;--i>=0;)Jte(s[i])&&e(r,s[i].name);return{path:r,params:s}};var pft=(e,t,r)=>{let{type:s}=r;switch(s){case"Identifier":return e(t,r.name);case"ObjectPattern":return Kte(e,t,r);case"AssignmentPattern":return fft(e,t,r)}},fft=(e,t,r)=>{let{left:s}=r,{type:i}=s;switch(i){case"Identifier":return e(t,s.name);case"ObjectPattern":return Kte(e,t,s)}},Kte=(e,t,r)=>{for(let{value:s}of r.properties)if(Jte(s)){if(e(t,s.name))return!0;continue}return!1}});var zte=F((T2t,Xte)=>{"use strict";var{types:hft}=Wi(),dft=Vte(),{useParamsBeforeLastUsed:mft,usePropertiesBeforeRest:yft}=Wte(),{isClassDeclaration:gft,isFunctionDeclaration:xft}=hft;Xte.exports=(e,t)=>{let r={},s=[],{setPath:i,traverse:n}=t,a=vft({vars:r}),o=Tft({vars:r,setPath:i}),u=Sft({vars:r}),c=bft(s);return n(e,dft({use:a,declare:o,addParams:c})),s.map(mft({use:a,isUsed:u})).map(yft({use:a})),Object.values(r)};var bft=e=>({path:t,params:r})=>{e.push({path:t,params:r})};function T3({name:e,scope:t}){if(t.hasOwnBinding(e))return t.uid;for(;t.parent;)if(t=t.parent,t.hasOwnBinding(e))return t.uid;return t.uid}var Sft=({vars:e})=>(t,r)=>{let{scope:s}=t,i=T3({name:r,scope:s}),n=e[i],{used:a}=n[r];return a};function Eft(e){let{node:t,scope:r}=e;return xft(t)||gft(t)?e.parentPath.scope:r}var Tft=({vars:e,setPath:t})=>(r,s)=>{let i=Eft(r),n=T3({name:s,scope:i});e[n]||(e[n]={});let a=e[n];a[s]?a[s].declared=!0:a[s]={declared:!0,used:!1},t&&(a[s].path=r)},vft=({vars:e})=>(t,r)=>{let{scope:s}=t,i=T3({name:r,scope:s});e[i]||(e[i]={});let n=e[i];n[r]?n[r].used=!0:n[r]={declared:!1,used:!0}}});var Gte=F((v2t,Hte)=>{"use strict";Hte.exports=e=>{let t=[];for(let r of e){let s=Object.entries(r);for(let i of s)t.push(Aft(i))}return t};function Aft([e,t]){return{name:e,...t}}});var Qte=F((A2t,Yte)=>{"use strict";var Cft=({declared:e,used:t})=>e&&!t;Yte.exports=e=>e.filter(Cft)});var ere=F((C2t,bS)=>{"use strict";var{operator:Dft}=Wi(),Pft=zte(),wft=Gte(),Ift=Qte(),{replaceWith:kft,compare:Nft,remove:Zte}=Dft;bS.exports.report=({name:e})=>`'${e}' is defined but never used`;bS.exports.fix=({path:e})=>{if(Nft(e,"const __a = __b = __c"))return kft(e.parentPath,e.node.init);if(Fft(e))return Zte(e.parentPath);Zte(e)};bS.exports.find=(e,{traverse:t})=>{let r=Pft(e,{setPath:!0,traverse:t}),s=wft(r);return Ift(s)};function Fft({parentPath:e}){return e.isImportDeclaration()?e.node.specifiers.length===1:!1}});var kae=F(Mf=>{"use strict";Object.defineProperty(Mf,"__esModule",{value:!0});Mf.sync=Mf.isexe=void 0;var UEt=It("fs"),VEt=It("fs/promises"),JEt=async(e,t={})=>{let{ignoreErrors:r=!1}=t;try{return Iae(await(0,VEt.stat)(e),t)}catch(s){let i=s;if(r||i.code==="EACCES")return!1;throw i}};Mf.isexe=JEt;var KEt=(e,t={})=>{let{ignoreErrors:r=!1}=t;try{return Iae((0,UEt.statSync)(e),t)}catch(s){let i=s;if(r||i.code==="EACCES")return!1;throw i}};Mf.sync=KEt;var Iae=(e,t)=>e.isFile()&&WEt(e,t),WEt=(e,t)=>{let r=t.uid??process.getuid?.(),s=t.groups??process.getgroups?.()??[],i=t.gid??process.getgid?.()??s[0];if(r===void 0||i===void 0)throw new Error("cannot get uid or gid");let n=new Set([i,...s]),a=e.mode,o=e.uid,u=e.gid,c=parseInt("100",8),p=parseInt("010",8),m=parseInt("001",8),g=c|p;return!!(a&m||a&p&&n.has(u)||a&c&&o===r||a&g&&r===0)}});var Fae=F(Rf=>{"use strict";Object.defineProperty(Rf,"__esModule",{value:!0});Rf.sync=Rf.isexe=void 0;var XEt=It("fs"),zEt=It("fs/promises"),HEt=async(e,t={})=>{let{ignoreErrors:r=!1}=t;try{return Nae(await(0,zEt.stat)(e),e,t)}catch(s){let i=s;if(r||i.code==="EACCES")return!1;throw i}};Rf.isexe=HEt;var GEt=(e,t={})=>{let{ignoreErrors:r=!1}=t;try{return Nae((0,XEt.statSync)(e),e,t)}catch(s){let i=s;if(r||i.code==="EACCES")return!1;throw i}};Rf.sync=GEt;var YEt=(e,t)=>{let{pathExt:r=process.env.PATHEXT||""}=t,s=r.split(";");if(s.indexOf("")!==-1)return!0;for(let i=0;i<s.length;i++){let n=s[i].toLowerCase(),a=e.substring(e.length-n.length).toLowerCase();if(n&&a===n)return!0}return!1},Nae=(e,t,r)=>e.isFile()&&YEt(t,r)});var Oae=F(_ae=>{"use strict";Object.defineProperty(_ae,"__esModule",{value:!0})});var $ae=F(Ls=>{"use strict";var Bae=Ls&&Ls.__createBinding||(Object.create?function(e,t,r,s){s===void 0&&(s=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,s,i)}:function(e,t,r,s){s===void 0&&(s=r),e[s]=t[r]}),QEt=Ls&&Ls.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Lae=Ls&&Ls.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)r!=="default"&&Object.prototype.hasOwnProperty.call(e,r)&&Bae(t,e,r);return QEt(t,e),t},ZEt=Ls&&Ls.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&Bae(t,e,r)};Object.defineProperty(Ls,"__esModule",{value:!0});Ls.sync=Ls.isexe=Ls.posix=Ls.win32=void 0;var Mae=Lae(kae());Ls.posix=Mae;var Rae=Lae(Fae());Ls.win32=Rae;ZEt(Oae(),Ls);var e1t=process.env._ISEXE_TEST_PLATFORM_||process.platform,jae=e1t==="win32"?Rae:Mae;Ls.isexe=jae.isexe;Ls.sync=jae.sync});var Gae=F((Hkt,Hae)=>{"use strict";var{isexe:t1t,sync:r1t}=$ae(),{join:s1t,delimiter:i1t,sep:qae,posix:Uae}=It("path"),Vae=process.platform==="win32",Jae=new RegExp(`[${Uae.sep}${qae===Uae.sep?"":qae}]`.replace(/(\\)/g,"\\$1")),n1t=new RegExp(`^\\.${Jae.source}`),Kae=e=>Object.assign(new Error(`not found: ${e}`),{code:"ENOENT"}),Wae=(e,{path:t=process.env.PATH,pathExt:r=process.env.PATHEXT,delimiter:s=i1t})=>{let i=e.match(Jae)?[""]:[...Vae?[process.cwd()]:[],...(t||"").split(s)];if(Vae){let n=r||[".EXE",".CMD",".BAT",".COM"].join(s),a=n.split(s).flatMap(o=>[o,o.toLowerCase()]);return e.includes(".")&&a[0]!==""&&a.unshift(""),{pathEnv:i,pathExt:a,pathExtExe:n}}return{pathEnv:i,pathExt:[""]}},Xae=(e,t)=>{let r=/^".*"$/.test(e)?e.slice(1,-1):e;return(!r&&n1t.test(t)?t.slice(0,2):"")+s1t(r,t)},zae=async(e,t={})=>{let{pathEnv:r,pathExt:s,pathExtExe:i}=Wae(e,t),n=[];for(let a of r){let o=Xae(a,e);for(let u of s){let c=o+u;if(await t1t(c,{pathExt:i,ignoreErrors:!0})){if(!t.all)return c;n.push(c)}}}if(t.all&&n.length)return n;if(t.nothrow)return null;throw Kae(e)},a1t=(e,t={})=>{let{pathEnv:r,pathExt:s,pathExtExe:i}=Wae(e,t),n=[];for(let a of r){let o=Xae(a,e);for(let u of s){let c=o+u;if(r1t(c,{pathExt:i,ignoreErrors:!0})){if(!t.all)return c;n.push(c)}}}if(t.all&&n.length)return n;if(t.nothrow)return null;throw Kae(e)};Hae.exports=zae;zae.sync=a1t});var Foe=["framework:solid","framework:react","framework:vue","db:edgedb","db:prisma","auth:authjs","rpc:telefunc","server:hattip","server:express","server:h3","uikit:tailwindcss","analytics:plausible.io","hosting:vercel"],l1t=new Map(Foe.map(e=>[e.split(":").at(-1),e]));var Yo=Pn(C_(),1);import{promises as Jpe}from"fs";var C0=Pn(GE(),1),KO=Pn(F1(),1);function yn(e){var t=e.use(ds),r=t.Type,s=t.builtInTypes,i=s.number;function n(c){return r.from(p=>i.check(p)&&p>=c,i+" >= "+c)}let a={null:function(){return null},emptyArray:function(){return[]},false:function(){return!1},true:function(){return!0},undefined:function(){},"use strict":function(){return"use strict"}};var o=r.or(s.string,s.number,s.boolean,s.null,s.undefined);let u=r.from(c=>{if(c===null)return!0;var p=typeof c;return!(p==="object"||p==="function")},o.toString());return{geq:n,defaults:a,isPrimitive:u}}function Lr(e){try{var t=e(),r=t.exports,s=r.default}catch{return}s&&s!==r&&typeof r=="object"&&(Object.assign(s,r,{default:s}),r.__esModule&&Object.defineProperty(s,"__esModule",{value:!0}),t.exports=s)}var Kpe=Object.defineProperty,Wpe=(e,t,r)=>t in e?Kpe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,vi=(e,t,r)=>(Wpe(e,typeof t!="symbol"?t+"":t,r),r),WO=Object.prototype,x0=WO.toString,kn=WO.hasOwnProperty,fl=class{assert(t,r){if(!this.check(t,r)){var s=K1(t);throw new Error(s+" does not match type "+this)}return!0}arrayOf(){let t=this;return new gh(t)}},gh=class extends fl{constructor(t){super(),this.elemType=t,vi(this,"kind","ArrayType")}toString(){return"["+this.elemType+"]"}check(t,r){return Array.isArray(t)&&t.every(s=>this.elemType.check(s,r))}},b0=class extends fl{constructor(t){super(),this.value=t,vi(this,"kind","IdentityType")}toString(){return String(this.value)}check(t,r){let s=t===this.value;return!s&&typeof r=="function"&&r(this,t),s}},S0=class extends fl{constructor(t){super(),this.fields=t,vi(this,"kind","ObjectType")}toString(){return"{ "+this.fields.join(", ")+" }"}check(t,r){return x0.call(t)===x0.call({})&&this.fields.every(s=>s.type.check(t[s.name],r))}},E0=class extends fl{constructor(t){super(),this.types=t,vi(this,"kind","OrType")}toString(){return this.types.join(" | ")}check(t,r){return this.types.some(s=>s.check(t,!!r))?!0:(typeof r=="function"&&r(this,t),!1)}},pl=class extends fl{constructor(t,r){super(),this.name=t,this.predicate=r,vi(this,"kind","PredicateType")}toString(){return this.name}check(t,r){let s=this.predicate(t,r);return!s&&typeof r=="function"&&r(this,t),s}},mh=class e{constructor(t,r){this.type=t,this.typeName=r,vi(this,"baseNames",[]),vi(this,"ownFields",Object.create(null)),vi(this,"allSupertypes",Object.create(null)),vi(this,"supertypeList",[]),vi(this,"allFields",Object.create(null)),vi(this,"fieldNames",[]),vi(this,"finalized",!1),vi(this,"buildable",!1),vi(this,"buildParams",[])}isSupertypeOf(t){if(t instanceof e){if(this.finalized!==!0||t.finalized!==!0)throw new Error("");return kn.call(t.allSupertypes,this.typeName)}else throw new Error(t+" is not a Def")}checkAllFields(t,r){var s=this.allFields;if(this.finalized!==!0)throw new Error(""+this.typeName);function i(n){var a=s[n],o=a.type,u=a.getValue(t);return o.check(u,r)}return t!==null&&typeof t=="object"&&Object.keys(s).every(i)}bases(...t){var r=this.baseNames;if(this.finalized){if(t.length!==r.length)throw new Error("");for(var s=0;s<t.length;s++)if(t[s]!==r[s])throw new Error("");return this}return t.forEach(i=>{r.indexOf(i)<0&&r.push(i)}),this}},T0=class{constructor(t,r,s,i){this.name=t,this.type=r,this.defaultFn=s,vi(this,"hidden"),this.hidden=!!i}toString(){return JSON.stringify(this.name)+": "+this.type}getValue(t){var r=t[this.name];return typeof r<"u"||typeof this.defaultFn=="function"&&(r=this.defaultFn.call(t)),r}};function K1(e){return Array.isArray(e)?"["+e.map(K1).join(", ")+"]":e&&typeof e=="object"?"{ "+Object.keys(e).map(function(t){return t+": "+e[t]}).join(", ")+" }":JSON.stringify(e)}function ds(e){let t={or(...J){return new E0(J.map(q=>t.from(q)))},from(J,q){if(J instanceof gh||J instanceof b0||J instanceof S0||J instanceof E0||J instanceof pl)return J;if(J instanceof mh)return J.type;if(o.check(J)){if(J.length!==1)throw new Error("only one element type is permitted for typed arrays");return new gh(t.from(J[0]))}if(u.check(J))return new S0(Object.keys(J).map(de=>new T0(de,t.from(J[de],de))));if(typeof J=="function"){var Q=r.indexOf(J);if(Q>=0)return s[Q];if(typeof q!="string")throw new Error("missing name");return new pl(q,J)}return new b0(J)},def(J){return kn.call(T,J)?T[J]:T[J]=new A(J)},hasDef(J){return kn.call(T,J)}};var r=[],s=[];function i(J,q){let Q=x0.call(q),de=new pl(J,ve=>x0.call(ve)===Q);return q&&typeof q.constructor=="function"&&(r.push(q.constructor),s.push(de)),de}let n=i("string","truthy"),a=i("function",function(){}),o=i("array",[]),u=i("object",{}),c=i("RegExp",/./),p=i("Date",new Date),m=i("number",3),g=i("boolean",!0),d=i("null",null),h=i("undefined",void 0),b=typeof BigInt=="function"?i("BigInt",BigInt(1234)):new pl("BigInt",()=>!1),S={string:n,function:a,array:o,object:u,RegExp:c,Date:p,number:m,boolean:g,null:d,undefined:h,BigInt:b};var T=Object.create(null);function C(J){if(J&&typeof J=="object"){var q=J.type;if(typeof q=="string"&&kn.call(T,q)){var Q=T[q];if(Q.finalized)return Q}}return null}class A extends mh{constructor(q){super(new pl(q,(Q,de)=>this.check(Q,de)),q)}check(q,Q){if(this.finalized!==!0)throw new Error("prematurely checking unfinalized type "+this.typeName);if(q===null||typeof q!="object")return!1;var de=C(q);return de?Q&&de===this?this.checkAllFields(q,Q):this.isSupertypeOf(de)?Q?de.checkAllFields(q,Q)&&this.checkAllFields(q,!1):!0:!1:this.typeName==="SourceLocation"||this.typeName==="Position"?this.checkAllFields(q,Q):!1}build(...q){if(this.buildParams=q,this.buildable)return this;this.field("type",String,()=>this.typeName),this.buildable=!0;let Q=(ve,we,Se,fe)=>{if(!kn.call(ve,we)){var _e=this.allFields;if(!kn.call(_e,we))throw new Error(""+we);var re=_e[we],ie=re.type,se;if(fe)se=Se;else if(re.defaultFn)se=re.defaultFn.call(ve);else{var ye="no value or default function given for field "+JSON.stringify(we)+" of "+this.typeName+"("+this.buildParams.map(function($e){return _e[$e]}).join(", ")+")";throw new Error(ye)}if(!ie.check(se))throw new Error(K1(se)+" does not match field "+re+" of type "+this.typeName);ve[we]=se}},de=(...ve)=>{var we=ve.length;if(!this.finalized)throw new Error("attempting to instantiate unfinalized type "+this.typeName);var Se=Object.create(_);if(this.buildParams.forEach(function(fe,_e){_e<we?Q(Se,fe,ve[_e],!0):Q(Se,fe,null,!1)}),Object.keys(this.allFields).forEach(function(fe){Q(Se,fe,null,!1)}),Se.type!==this.typeName)throw new Error("");return Se};return de.from=ve=>{if(!this.finalized)throw new Error("attempting to instantiate unfinalized type "+this.typeName);var we=Object.create(_);if(Object.keys(this.allFields).forEach(function(Se){kn.call(ve,Se)?Q(we,Se,ve[Se],!0):Q(we,Se,null,!1)}),we.type!==this.typeName)throw new Error("");return we},Object.defineProperty(I,$(this.typeName),{enumerable:!0,value:de}),this}field(q,Q,de,ve){return this.finalized?(console.error("Ignoring attempt to redefine field "+JSON.stringify(q)+" of finalized type "+JSON.stringify(this.typeName)),this):(this.ownFields[q]=new T0(q,t.from(Q),de,ve),this)}finalize(){if(!this.finalized){var q=this.allFields,Q=this.allSupertypes;this.baseNames.forEach(ve=>{var we=T[ve];if(we instanceof mh)we.finalize(),Ie(q,we.allFields),Ie(Q,we.allSupertypes);else{var Se="unknown supertype name "+JSON.stringify(ve)+" for subtype "+JSON.stringify(this.typeName);throw new Error(Se)}}),Ie(q,this.ownFields),Q[this.typeName]=this,this.fieldNames.length=0;for(var de in q)kn.call(q,de)&&!q[de].hidden&&this.fieldNames.push(de);Object.defineProperty(M,this.typeName,{enumerable:!0,value:this.type}),this.finalized=!0,Be(this.typeName,this.supertypeList),this.buildable&&this.supertypeList.lastIndexOf("Expression")>=0&&ae(this.typeName)}}}function v(J){if(!kn.call(T,J))throw new Error("");var q=T[J];if(q.finalized!==!0)throw new Error("");return q.supertypeList.slice(1)}function w(J){for(var q={},Q=Object.keys(T),de=Q.length,ve=0;ve<de;++ve){var we=Q[ve],Se=T[we];if(Se.finalized!==!0)throw new Error(""+we);for(var fe=0;fe<Se.supertypeList.length;++fe){var _e=Se.supertypeList[fe];if(kn.call(J,_e)){q[we]=_e;break}}}return q}var I=Object.create(null),_={};function L(J,q){var Q=_[J];return h.check(q)?delete _[J]:(a.assert(q),Object.defineProperty(_,J,{enumerable:!0,configurable:!0,value:q})),Q}function $(J){return J.replace(/^[A-Z]+/,function(q){var Q=q.length;switch(Q){case 0:return"";case 1:return q.toLowerCase();default:return q.slice(0,Q-1).toLowerCase()+q.charAt(Q-1)}})}function G(J){return J=$(J),J.replace(/(Expression)?$/,"Statement")}var M={};function Ee(J){var q=C(J);if(q)return q.fieldNames.slice(0);if("type"in J)throw new Error("did not recognize object of type "+JSON.stringify(J.type));return Object.keys(J)}function Fe(J,q){var Q=C(J);if(Q){var de=Q.allFields[q];if(de)return de.getValue(J)}return J&&J[q]}function De(J,q,Q){Ee(J).forEach(function(de){q.call(this,de,Fe(J,de))},Q)}function ue(J,q,Q){return Ee(J).some(function(de){return q.call(this,de,Fe(J,de))},Q)}function ae(J){var q=G(J);if(I[q])return;var Q=I[$(J)];if(!Q)return;let de=function(...ve){return I.expressionStatement(Q.apply(I,ve))};de.from=function(...ve){return I.expressionStatement(Q.from.apply(I,ve))},I[q]=de}function Be(J,q){q.length=0,q.push(J);for(var Q=Object.create(null),de=0;de<q.length;++de){J=q[de];var ve=T[J];if(ve.finalized!==!0)throw new Error("");kn.call(Q,J)&&delete q[Q[J]],Q[J]=de,q.push.apply(q,ve.baseNames)}for(var we=0,Se=we,fe=q.length;Se<fe;++Se)kn.call(q,Se)&&(q[we++]=q[Se]);q.length=we}function Ie(J,q){return Object.keys(q).forEach(function(Q){J[Q]=q[Q]}),J}function me(){Object.keys(T).forEach(function(J){T[J].finalize()})}return{Type:t,builtInTypes:S,getSupertypeNames:v,computeSupertypeLookupTable:w,builders:I,defineMethod:L,getBuilderName:$,getStatementBuilderName:G,namedTypes:M,getFieldNames:Ee,getFieldValue:Fe,eachField:De,someField:ue,finalize:me}}Lr(()=>module);var Xpe=Object.prototype,l0=Xpe.hasOwnProperty;function XO(e){var t=e.use(ds),r=t.builtInTypes.array,s=t.builtInTypes.number;let i=function m(g,d,h){if(!(this instanceof m))throw new Error("Path constructor cannot be invoked without 'new'");if(d){if(!(d instanceof m))throw new Error("")}else d=null,h=null;this.value=g,this.parentPath=d,this.name=h,this.__childCache=null};var n=i.prototype;function a(m){return m.__childCache||(m.__childCache=Object.create(null))}function o(m,g){var d=a(m),h=m.getValueProperty(g),b=d[g];return(!l0.call(d,g)||b.value!==h)&&(b=d[g]=new m.constructor(h,m,g)),b}n.getValueProperty=function(g){return this.value[g]},n.get=function(...g){for(var d=this,h=g.length,b=0;b<h;++b)d=o(d,g[b]);return d},n.each=function(g,d){for(var h=[],b=this.value.length,S=0,S=0;S<b;++S)l0.call(this.value,S)&&(h[S]=this.get(S));for(d=d||this,S=0;S<b;++S)l0.call(h,S)&&g.call(d,h[S])},n.map=function(g,d){var h=[];return this.each(function(b){h.push(g.call(this,b))},d),h},n.filter=function(g,d){var h=[];return this.each(function(b){g.call(this,b)&&h.push(b)},d),h};function u(){}function c(m,g,d,h){if(r.assert(m.value),g===0)return u;var b=m.value.length;if(b<1)return u;var S=arguments.length;S===2?(d=0,h=b):S===3?(d=Math.max(d,0),h=b):(d=Math.max(d,0),h=Math.min(h,b)),s.assert(d),s.assert(h);for(var T=Object.create(null),C=a(m),A=d;A<h;++A)if(l0.call(m.value,A)){var v=m.get(A);if(v.name!==A)throw new Error("");var w=A+g;v.name=w,T[w]=v,delete C[A]}return delete C.length,function(){for(var I in T){var _=T[I];if(_.name!==+I)throw new Error("");C[I]=_,m.value[I]=_.value}}}n.shift=function(){var g=c(this,-1),d=this.value.shift();return g(),d},n.unshift=function(...g){var d=c(this,g.length),h=this.value.unshift.apply(this.value,g);return d(),h},n.push=function(...g){return r.assert(this.value),delete a(this).length,this.value.push.apply(this.value,g)},n.pop=function(){r.assert(this.value);var g=a(this);return delete g[this.value.length-1],delete g.length,this.value.pop()},n.insertAt=function(g){var d=arguments.length,h=c(this,d-1,g);if(h===u&&d<=1)return this;g=Math.max(g,0);for(var b=1;b<d;++b)this.value[g+b-1]=arguments[b];return h(),this},n.insertBefore=function(...g){for(var d=this.parentPath,h=g.length,b=[this.name],S=0;S<h;++S)b.push(g[S]);return d.insertAt.apply(d,b)},n.insertAfter=function(...g){for(var d=this.parentPath,h=g.length,b=[this.name+1],S=0;S<h;++S)b.push(g[S]);return d.insertAt.apply(d,b)};function p(m){if(!(m instanceof i))throw new Error("");var g=m.parentPath;if(!g)return m;var d=g.value,h=a(g);if(d[m.name]===m.value)h[m.name]=m;else if(r.check(d)){var b=d.indexOf(m.value);b>=0&&(h[m.name=b]=m)}else d[m.name]=m.value,h[m.name]=m;if(d[m.name]!==m.value)throw new Error("");if(m.parentPath.get(m.name)!==m)throw new Error("");return m}return n.replace=function(g){var d=[],h=this.parentPath.value,b=a(this.parentPath),S=arguments.length;if(p(this),r.check(h)){for(var T=h.length,C=c(this.parentPath,S-1,this.name+1),A=[this.name,1],v=0;v<S;++v)A.push(arguments[v]);var w=h.splice.apply(h,A);if(w[0]!==this.value)throw new Error("");if(h.length!==T-1+S)throw new Error("");if(C(),S===0)delete this.value,delete b[this.name],this.__childCache=null;else{if(h[this.name]!==g)throw new Error("");for(this.value!==g&&(this.value=g,this.__childCache=null),v=0;v<S;++v)d.push(this.parentPath.get(this.name+v));if(d[0]!==this)throw new Error("")}}else if(S===1)this.value!==g&&(this.__childCache=null),this.value=h[this.name]=g,d.push(this);else if(S===0)delete h[this.name],delete this.value,this.__childCache=null;else throw new Error("Could not replace path");return d},i}Lr(()=>module);var jc=Object.prototype.hasOwnProperty;function zpe(e){var t=e.use(ds),r=t.Type,s=t.namedTypes,i=s.Node,n=s.Expression,a=t.builtInTypes.array,o=t.builders;let u=function v(w,I){if(!(this instanceof v))throw new Error("Scope constructor cannot be invoked without 'new'");p.check(w.value)||c.assert(w.value);var _;if(I){if(!(I instanceof v))throw new Error("");_=I.depth+1}else I=null,_=0;Object.defineProperties(this,{path:{value:w},node:{value:w.value},isGlobal:{value:!I,enumerable:!0},depth:{value:_},parent:{value:I},bindings:{value:{}},types:{value:{}}})};var c=r.or(s.Program,s.Function,s.CatchClause),p=r.or(s.Function,s.ClassDeclaration,s.ClassExpression,s.InterfaceDeclaration,s.TSInterfaceDeclaration,s.TypeAlias,s.TSTypeAliasDeclaration),m=r.or(s.TypeParameter,s.TSTypeParameter);u.isEstablishedBy=function(v){return c.check(v)||p.check(v)};var g=u.prototype;g.didScan=!1,g.declares=function(v){return this.scan(),jc.call(this.bindings,v)},g.declaresType=function(v){return this.scan(),jc.call(this.types,v)},g.declareTemporary=function(v){if(v){if(!/^[a-z$_]/i.test(v))throw new Error("")}else v="t$";v+=this.depth.toString(36)+"$",this.scan();for(var w=0;this.declares(v+w);)++w;var I=v+w;return this.bindings[I]=t.builders.identifier(I)},g.injectTemporary=function(v,w){v||(v=this.declareTemporary());var I=this.path.get("body");return s.BlockStatement.check(I.value)&&(I=I.get("body")),I.unshift(o.variableDeclaration("var",[o.variableDeclarator(v,w||null)])),v},g.scan=function(v){if(v||!this.didScan){for(var w in this.bindings)delete this.bindings[w];for(var w in this.types)delete this.types[w];d(this.path,this.bindings,this.types),this.didScan=!0}},g.getBindings=function(){return this.scan(),this.bindings},g.getTypes=function(){return this.scan(),this.types};function d(v,w,I){var _=v.value;if(p.check(_)){let L=v.get("typeParameters","params");a.check(L.value)&&L.each($=>{A($,I)})}c.check(_)&&(s.CatchClause.check(_)?T(v.get("param"),w):h(v,w,I))}function h(v,w,I){var _=v.value;v.parent&&s.FunctionExpression.check(v.parent.node)&&v.parent.node.id&&T(v.parent.get("id"),w),_&&(a.check(_)?v.each(L=>{S(L,w,I)}):s.Function.check(_)?(v.get("params").each(L=>{T(L,w)}),S(v.get("body"),w,I),h(v.get("typeParameters"),w,I)):s.TypeAlias&&s.TypeAlias.check(_)||s.InterfaceDeclaration&&s.InterfaceDeclaration.check(_)||s.TSTypeAliasDeclaration&&s.TSTypeAliasDeclaration.check(_)||s.TSInterfaceDeclaration&&s.TSInterfaceDeclaration.check(_)?C(v.get("id"),I):s.VariableDeclarator.check(_)?(T(v.get("id"),w),S(v.get("init"),w,I)):_.type==="ImportSpecifier"||_.type==="ImportNamespaceSpecifier"||_.type==="ImportDefaultSpecifier"?T(v.get(_.local?"local":_.name?"name":"id"),w):i.check(_)&&!n.check(_)&&t.eachField(_,function(L,$){var G=v.get(L);if(!b(G,$))throw new Error("");S(G,w,I)}))}function b(v,w){return!!(v.value===w||Array.isArray(v.value)&&v.value.length===0&&Array.isArray(w)&&w.length===0)}function S(v,w,I){var _=v.value;if(!(!_||n.check(_)))if(s.FunctionDeclaration.check(_)&&_.id!==null)T(v.get("id"),w);else if(s.ClassDeclaration&&s.ClassDeclaration.check(_)&&_.id!==null)T(v.get("id"),w),h(v.get("typeParameters"),w,I);else if(s.InterfaceDeclaration&&s.InterfaceDeclaration.check(_)||s.TSInterfaceDeclaration&&s.TSInterfaceDeclaration.check(_))C(v.get("id"),I);else if(c.check(_)){if(s.CatchClause.check(_)&&s.Identifier.check(_.param)){var L=_.param.name,$=jc.call(w,L);h(v.get("body"),w,I),$||delete w[L]}}else h(v,w,I)}function T(v,w){var I=v.value;s.Pattern.assert(I),s.Identifier.check(I)?jc.call(w,I.name)?w[I.name].push(v):w[I.name]=[v]:s.AssignmentPattern&&s.AssignmentPattern.check(I)?T(v.get("left"),w):s.ObjectPattern&&s.ObjectPattern.check(I)?v.get("properties").each(function(_){var L=_.value;s.Pattern.check(L)?T(_,w):s.Property.check(L)||s.ObjectProperty&&s.ObjectProperty.check(L)?T(_.get("value"),w):s.SpreadProperty&&s.SpreadProperty.check(L)&&T(_.get("argument"),w)}):s.ArrayPattern&&s.ArrayPattern.check(I)?v.get("elements").each(function(_){var L=_.value;s.Pattern.check(L)?T(_,w):s.SpreadElement&&s.SpreadElement.check(L)&&T(_.get("argument"),w)}):s.PropertyPattern&&s.PropertyPattern.check(I)?T(v.get("pattern"),w):(s.SpreadElementPattern&&s.SpreadElementPattern.check(I)||s.RestElement&&s.RestElement.check(I)||s.SpreadPropertyPattern&&s.SpreadPropertyPattern.check(I))&&T(v.get("argument"),w)}function C(v,w){var I=v.value;s.Pattern.assert(I),s.Identifier.check(I)&&(jc.call(w,I.name)?w[I.name].push(v):w[I.name]=[v])}function A(v,w){var I=v.value;m.assert(I),jc.call(w,I.name)?w[I.name].push(v):w[I.name]=[v]}return g.lookup=function(v){for(var w=this;w&&!w.declares(v);w=w.parent);return w},g.lookupType=function(v){for(var w=this;w&&!w.declaresType(v);w=w.parent);return w},g.getGlobalScope=function(){for(var v=this;!v.isGlobal;)v=v.parent;return v},u}Lr(()=>module);function zO(e){var t=e.use(ds),r=t.namedTypes,s=t.builders,i=t.builtInTypes.number,n=t.builtInTypes.array,a=e.use(XO),o=e.use(zpe);let u=function S(T,C,A){if(!(this instanceof S))throw new Error("NodePath constructor cannot be invoked without 'new'");a.call(this,T,C,A)};var c=u.prototype=Object.create(a.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}});Object.defineProperties(c,{node:{get:function(){return Object.defineProperty(this,"node",{configurable:!0,value:this._computeNode()}),this.node}},parent:{get:function(){return Object.defineProperty(this,"parent",{configurable:!0,value:this._computeParent()}),this.parent}},scope:{get:function(){return Object.defineProperty(this,"scope",{configurable:!0,value:this._computeScope()}),this.scope}}}),c.replace=function(){return delete this.node,delete this.parent,delete this.scope,a.prototype.replace.apply(this,arguments)},c.prune=function(){var S=this.parent;return this.replace(),h(S)},c._computeNode=function(){var S=this.value;if(r.Node.check(S))return S;var T=this.parentPath;return T&&T.node||null},c._computeParent=function(){var S=this.value,T=this.parentPath;if(!r.Node.check(S)){for(;T&&!r.Node.check(T.value);)T=T.parentPath;T&&(T=T.parentPath)}for(;T&&!r.Node.check(T.value);)T=T.parentPath;return T||null},c._computeScope=function(){var S=this.value,T=this.parentPath,C=T&&T.scope;return r.Node.check(S)&&o.isEstablishedBy(S)&&(C=new o(this,C)),C||null},c.getValueProperty=function(S){return t.getFieldValue(this.value,S)},c.needsParens=function(S){var T=this.parentPath;if(!T)return!1;var C=this.value;if(!r.Expression.check(C)||C.type==="Identifier")return!1;for(;!r.Node.check(T.value);)if(T=T.parentPath,!T)return!1;var A=T.value;switch(C.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return A.type==="MemberExpression"&&this.name==="object"&&A.object===C;case"BinaryExpression":case"LogicalExpression":switch(A.type){case"CallExpression":return this.name==="callee"&&A.callee===C;case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return!0;case"MemberExpression":return this.name==="object"&&A.object===C;case"BinaryExpression":case"LogicalExpression":{let v=C,w=A.operator,I=m[w],_=v.operator,L=m[_];if(I>L)return!0;if(I===L&&this.name==="right"){if(A.right!==v)throw new Error("Nodes must be equal");return!0}}default:return!1}case"SequenceExpression":switch(A.type){case"ForStatement":return!1;case"ExpressionStatement":return this.name!=="expression";default:return!0}case"YieldExpression":switch(A.type){case"BinaryExpression":case"LogicalExpression":case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"CallExpression":case"MemberExpression":case"NewExpression":case"ConditionalExpression":case"YieldExpression":return!0;default:return!1}case"Literal":return A.type==="MemberExpression"&&i.check(C.value)&&this.name==="object"&&A.object===C;case"AssignmentExpression":case"ConditionalExpression":switch(A.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"BinaryExpression":case"LogicalExpression":return!0;case"CallExpression":return this.name==="callee"&&A.callee===C;case"ConditionalExpression":return this.name==="test"&&A.test===C;case"MemberExpression":return this.name==="object"&&A.object===C;default:return!1}default:if(A.type==="NewExpression"&&this.name==="callee"&&A.callee===C)return g(C)}return!!(S!==!0&&!this.canBeFirstInStatement()&&this.firstInStatement())};function p(S){return r.BinaryExpression.check(S)||r.LogicalExpression.check(S)}var m={};[["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"]].forEach(function(S,T){S.forEach(function(C){m[C]=T})});function g(S){return r.CallExpression.check(S)?!0:n.check(S)?S.some(g):r.Node.check(S)?t.someField(S,function(T,C){return g(C)}):!1}c.canBeFirstInStatement=function(){var S=this.node;return!r.FunctionExpression.check(S)&&!r.ObjectExpression.check(S)},c.firstInStatement=function(){return d(this)};function d(S){for(var T,C;S.parent;S=S.parent){if(T=S.node,C=S.parent.node,r.BlockStatement.check(C)&&S.parent.name==="body"&&S.name===0){if(C.body[0]!==T)throw new Error("Nodes must be equal");return!0}if(r.ExpressionStatement.check(C)&&S.name==="expression"){if(C.expression!==T)throw new Error("Nodes must be equal");return!0}if(r.SequenceExpression.check(C)&&S.parent.name==="expressions"&&S.name===0){if(C.expressions[0]!==T)throw new Error("Nodes must be equal");continue}if(r.CallExpression.check(C)&&S.name==="callee"){if(C.callee!==T)throw new Error("Nodes must be equal");continue}if(r.MemberExpression.check(C)&&S.name==="object"){if(C.object!==T)throw new Error("Nodes must be equal");continue}if(r.ConditionalExpression.check(C)&&S.name==="test"){if(C.test!==T)throw new Error("Nodes must be equal");continue}if(p(C)&&S.name==="left"){if(C.left!==T)throw new Error("Nodes must be equal");continue}if(r.UnaryExpression.check(C)&&!C.prefix&&S.name==="argument"){if(C.argument!==T)throw new Error("Nodes must be equal");continue}return!1}return!0}function h(S){if(r.VariableDeclaration.check(S.node)){var T=S.get("declarations").value;if(!T||T.length===0)return S.prune()}else if(r.ExpressionStatement.check(S.node)){if(!S.get("expression").value)return S.prune()}else r.IfStatement.check(S.node)&&b(S);return S}function b(S){var T=S.get("test").value,C=S.get("alternate").value,A=S.get("consequent").value;if(!A&&!C){var v=s.expressionStatement(T);S.replace(v)}else if(!A&&C){var w=s.unaryExpression("!",T,!0);r.UnaryExpression.check(T)&&T.operator==="!"&&(w=T.argument),S.get("test").replace(w),S.get("consequent").replace(C),S.get("alternate").replace()}}return u}Lr(()=>module);var c0=Object.prototype.hasOwnProperty;function Hpe(e){var t=e.use(ds),r=e.use(zO),s=t.builtInTypes.array,i=t.builtInTypes.object,n=t.builtInTypes.function,a;let o=function h(){if(!(this instanceof h))throw new Error("PathVisitor constructor cannot be invoked without 'new'");this._reusableContextStack=[],this._methodNameTable=u(this),this._shouldVisitComments=c0.call(this._methodNameTable,"Block")||c0.call(this._methodNameTable,"Line"),this.Context=g(this),this._visiting=!1,this._changeReported=!1};function u(h){var b=Object.create(null);for(var S in h)/^visit[A-Z]/.test(S)&&(b[S.slice(5)]=!0);for(var T=t.computeSupertypeLookupTable(b),C=Object.create(null),A=Object.keys(T),v=A.length,w=0;w<v;++w){var I=A[w];S="visit"+T[I],n.check(h[S])&&(C[I]=S)}return C}o.fromMethodsObject=function(b){if(b instanceof o)return b;if(!i.check(b))return new o;let S=function C(){if(!(this instanceof C))throw new Error("Visitor constructor cannot be invoked without 'new'");o.call(this)};var T=S.prototype=Object.create(p);return T.constructor=S,c(T,b),c(S,o),n.assert(S.fromMethodsObject),n.assert(S.visit),new S};function c(h,b){for(var S in b)c0.call(b,S)&&(h[S]=b[S]);return h}o.visit=function(b,S){return o.fromMethodsObject(S).visit(b)};var p=o.prototype;p.visit=function(){if(this._visiting)throw new Error("Recursively calling visitor.visit(path) resets visitor state. Try this.visit(path) or this.traverse(path) instead.");this._visiting=!0,this._changeReported=!1,this._abortRequested=!1;for(var h=arguments.length,b=new Array(h),S=0;S<h;++S)b[S]=arguments[S];b[0]instanceof r||(b[0]=new r({root:b[0]}).get("root")),this.reset.apply(this,b);var T;try{var C=this.visitWithoutReset(b[0]);T=!0}finally{if(this._visiting=!1,!T&&this._abortRequested)return b[0].value}return C},p.AbortRequest=function(){},p.abort=function(){var h=this;h._abortRequested=!0;var b=new h.AbortRequest;throw b.cancel=function(){h._abortRequested=!1},b},p.reset=function(h){},p.visitWithoutReset=function(h){if(this instanceof this.Context)return this.visitor.visitWithoutReset(h);if(!(h instanceof r))throw new Error("");var b=h.value,S=b&&typeof b=="object"&&typeof b.type=="string"&&this._methodNameTable[b.type];if(S){var T=this.acquireContext(h);try{return T.invokeVisitorMethod(S)}finally{this.releaseContext(T)}}else return m(h,this)};function m(h,b){if(!(h instanceof r))throw new Error("");if(!(b instanceof o))throw new Error("");var S=h.value;if(s.check(S))h.each(b.visitWithoutReset,b);else if(i.check(S)){var T=t.getFieldNames(S);b._shouldVisitComments&&S.comments&&T.indexOf("comments")<0&&T.push("comments");for(var C=T.length,A=[],v=0;v<C;++v){var w=T[v];c0.call(S,w)||(S[w]=t.getFieldValue(S,w)),A.push(h.get(w))}for(var v=0;v<C;++v)b.visitWithoutReset(A[v])}return h.value}p.acquireContext=function(h){return this._reusableContextStack.length===0?new this.Context(h):this._reusableContextStack.pop().reset(h)},p.releaseContext=function(h){if(!(h instanceof this.Context))throw new Error("");this._reusableContextStack.push(h),h.currentPath=null},p.reportChanged=function(){this._changeReported=!0},p.wasChangeReported=function(){return this._changeReported};function g(h){function b(T){if(!(this instanceof b))throw new Error("");if(!(this instanceof o))throw new Error("");if(!(T instanceof r))throw new Error("");Object.defineProperty(this,"visitor",{value:h,writable:!1,enumerable:!0,configurable:!1}),this.currentPath=T,this.needToCallTraverse=!0,Object.seal(this)}if(!(h instanceof o))throw new Error("");var S=b.prototype=Object.create(h);return S.constructor=b,c(S,d),b}var d=Object.create(null);return d.reset=function(b){if(!(this instanceof this.Context))throw new Error("");if(!(b instanceof r))throw new Error("");return this.currentPath=b,this.needToCallTraverse=!0,this},d.invokeVisitorMethod=function(b){if(!(this instanceof this.Context))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");var S=this.visitor[b].call(this,this.currentPath);if(S===!1?this.needToCallTraverse=!1:S!==a&&(this.currentPath=this.currentPath.replace(S)[0],this.needToCallTraverse&&this.traverse(this.currentPath)),this.needToCallTraverse!==!1)throw new Error("Must either call this.traverse or return false in "+b);var T=this.currentPath;return T&&T.value},d.traverse=function(b,S){if(!(this instanceof this.Context))throw new Error("");if(!(b instanceof r))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");return this.needToCallTraverse=!1,m(b,o.fromMethodsObject(S||this.visitor))},d.visit=function(b,S){if(!(this instanceof this.Context))throw new Error("");if(!(b instanceof r))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");return this.needToCallTraverse=!1,o.fromMethodsObject(S||this.visitor).visitWithoutReset(b)},d.reportChanged=function(){this.visitor.reportChanged()},d.abort=function(){this.needToCallTraverse=!1,this.visitor.abort()},o}Lr(()=>module);function Gpe(e){var t=e.use(ds),r=t.getFieldNames,s=t.getFieldValue,i=t.builtInTypes.array,n=t.builtInTypes.object,a=t.builtInTypes.Date,o=t.builtInTypes.RegExp,u=Object.prototype.hasOwnProperty;function c(h,b,S){return i.check(S)?S.length=0:S=null,m(h,b,S)}c.assert=function(h,b){var S=[];if(!c(h,b,S))if(S.length===0){if(h!==b)throw new Error("Nodes must be equal")}else throw new Error("Nodes differ in the following path: "+S.map(p).join(""))};function p(h){return/[_$a-z][_$a-z0-9]*/i.test(h)?"."+h:"["+JSON.stringify(h)+"]"}function m(h,b,S){return h===b?!0:i.check(h)?g(h,b,S):n.check(h)?d(h,b,S):a.check(h)?a.check(b)&&+h==+b:o.check(h)?o.check(b)&&h.source===b.source&&h.global===b.global&&h.multiline===b.multiline&&h.ignoreCase===b.ignoreCase:h==b}function g(h,b,S){i.assert(h);var T=h.length;if(!i.check(b)||b.length!==T)return S&&S.push("length"),!1;for(var C=0;C<T;++C){if(S&&S.push(C),C in h!=C in b||!m(h[C],b[C],S))return!1;if(S){var A=S.pop();if(A!==C)throw new Error(""+A)}}return!0}function d(h,b,S){if(n.assert(h),!n.check(b))return!1;if(h.type!==b.type)return S&&S.push("type"),!1;var T=r(h),C=T.length,A=r(b),v=A.length;if(C===v){for(var w=0;w<C;++w){var I=T[w],_=s(h,I),L=s(b,I);if(S&&S.push(I),!m(_,L,S))return!1;if(S){var $=S.pop();if($!==I)throw new Error(""+$)}}return!0}if(!S)return!1;var G=Object.create(null);for(w=0;w<C;++w)G[T[w]]=!0;for(w=0;w<v;++w){if(I=A[w],!u.call(G,I))return S.push(I),!1;delete G[I]}for(I in G){S.push(I);break}return!1}return c}Lr(()=>module);function Ype(e){let t=Qpe(),r=t.use(ds);e.forEach(t.use),r.finalize();let s=t.use(Hpe);return{Type:r.Type,builtInTypes:r.builtInTypes,namedTypes:r.namedTypes,builders:r.builders,defineMethod:r.defineMethod,getFieldNames:r.getFieldNames,getFieldValue:r.getFieldValue,eachField:r.eachField,someField:r.someField,getSupertypeNames:r.getSupertypeNames,getBuilderName:r.getBuilderName,astNodesAreEquivalent:t.use(Gpe),finalize:r.finalize,Path:t.use(XO),NodePath:t.use(zO),PathVisitor:s,use:t.use,visit:s.visit}}function Qpe(){let e=[],t=[];function r(i){var n=e.indexOf(i);return n===-1&&(n=e.length,e.push(i),t[n]=i(s)),t[n]}var s={use:r};return s}Lr(()=>module);function HO(){return{BinaryOperators:["==","!=","===","!==","<","<=",">",">=","<<",">>",">>>","+","-","*","/","%","&","|","^","in","instanceof"],AssignmentOperators:["=","+=","-=","*=","/=","%=","<<=",">>=",">>>=","|=","^=","&="],LogicalOperators:["||","&&"]}}Lr(()=>module);function GO(e){let t=e.use(HO);return t.BinaryOperators.indexOf("**")<0&&t.BinaryOperators.push("**"),t.AssignmentOperators.indexOf("**=")<0&&t.AssignmentOperators.push("**="),t}Lr(()=>module);function YO(e){let t=e.use(GO);return t.LogicalOperators.indexOf("??")<0&&t.LogicalOperators.push("??"),t}Lr(()=>module);function Zpe(e){let t=e.use(YO);return t.LogicalOperators.forEach(r=>{let s=r+"=";t.AssignmentOperators.indexOf(s)<0&&t.AssignmentOperators.push(s)}),t}Lr(()=>module);function efe(e){var t=e.use(ds),r=t.Type,s=r.def,i=r.or,n=e.use(yn),a=n.defaults,o=n.geq;let{BinaryOperators:u,AssignmentOperators:c,LogicalOperators:p}=e.use(HO);s("Printable").field("loc",i(s("SourceLocation"),null),a.null,!0),s("Node").bases("Printable").field("type",String).field("comments",i([s("Comment")],null),a.null,!0),s("SourceLocation").field("start",s("Position")).field("end",s("Position")).field("source",i(String,null),a.null),s("Position").field("line",o(1)).field("column",o(0)),s("File").bases("Node").build("program","name").field("program",s("Program")).field("name",i(String,null),a.null),s("Program").bases("Node").build("body").field("body",[s("Statement")]),s("Function").bases("Node").field("id",i(s("Identifier"),null),a.null).field("params",[s("Pattern")]).field("body",s("BlockStatement")).field("generator",Boolean,a.false).field("async",Boolean,a.false),s("Statement").bases("Node"),s("EmptyStatement").bases("Statement").build(),s("BlockStatement").bases("Statement").build("body").field("body",[s("Statement")]),s("ExpressionStatement").bases("Statement").build("expression").field("expression",s("Expression")),s("IfStatement").bases("Statement").build("test","consequent","alternate").field("test",s("Expression")).field("consequent",s("Statement")).field("alternate",i(s("Statement"),null),a.null),s("LabeledStatement").bases("Statement").build("label","body").field("label",s("Identifier")).field("body",s("Statement")),s("BreakStatement").bases("Statement").build("label").field("label",i(s("Identifier"),null),a.null),s("ContinueStatement").bases("Statement").build("label").field("label",i(s("Identifier"),null),a.null),s("WithStatement").bases("Statement").build("object","body").field("object",s("Expression")).field("body",s("Statement")),s("SwitchStatement").bases("Statement").build("discriminant","cases","lexical").field("discriminant",s("Expression")).field("cases",[s("SwitchCase")]).field("lexical",Boolean,a.false),s("ReturnStatement").bases("Statement").build("argument").field("argument",i(s("Expression"),null)),s("ThrowStatement").bases("Statement").build("argument").field("argument",s("Expression")),s("TryStatement").bases("Statement").build("block","handler","finalizer").field("block",s("BlockStatement")).field("handler",i(s("CatchClause"),null),function(){return this.handlers&&this.handlers[0]||null}).field("handlers",[s("CatchClause")],function(){return this.handler?[this.handler]:[]},!0).field("guardedHandlers",[s("CatchClause")],a.emptyArray).field("finalizer",i(s("BlockStatement"),null),a.null),s("CatchClause").bases("Node").build("param","guard","body").field("param",s("Pattern")).field("guard",i(s("Expression"),null),a.null).field("body",s("BlockStatement")),s("WhileStatement").bases("Statement").build("test","body").field("test",s("Expression")).field("body",s("Statement")),s("DoWhileStatement").bases("Statement").build("body","test").field("body",s("Statement")).field("test",s("Expression")),s("ForStatement").bases("Statement").build("init","test","update","body").field("init",i(s("VariableDeclaration"),s("Expression"),null)).field("test",i(s("Expression"),null)).field("update",i(s("Expression"),null)).field("body",s("Statement")),s("ForInStatement").bases("Statement").build("left","right","body").field("left",i(s("VariableDeclaration"),s("Expression"))).field("right",s("Expression")).field("body",s("Statement")),s("DebuggerStatement").bases("Statement").build(),s("Declaration").bases("Statement"),s("FunctionDeclaration").bases("Function","Declaration").build("id","params","body").field("id",s("Identifier")),s("FunctionExpression").bases("Function","Expression").build("id","params","body"),s("VariableDeclaration").bases("Declaration").build("kind","declarations").field("kind",i("var","let","const")).field("declarations",[s("VariableDeclarator")]),s("VariableDeclarator").bases("Node").build("id","init").field("id",s("Pattern")).field("init",i(s("Expression"),null),a.null),s("Expression").bases("Node"),s("ThisExpression").bases("Expression").build(),s("ArrayExpression").bases("Expression").build("elements").field("elements",[i(s("Expression"),null)]),s("ObjectExpression").bases("Expression").build("properties").field("properties",[s("Property")]),s("Property").bases("Node").build("kind","key","value").field("kind",i("init","get","set")).field("key",i(s("Literal"),s("Identifier"))).field("value",s("Expression")),s("SequenceExpression").bases("Expression").build("expressions").field("expressions",[s("Expression")]);var m=i("-","+","!","~","typeof","void","delete");s("UnaryExpression").bases("Expression").build("operator","argument","prefix").field("operator",m).field("argument",s("Expression")).field("prefix",Boolean,a.true);let g=i(...u);s("BinaryExpression").bases("Expression").build("operator","left","right").field("operator",g).field("left",s("Expression")).field("right",s("Expression"));let d=i(...c);s("AssignmentExpression").bases("Expression").build("operator","left","right").field("operator",d).field("left",i(s("Pattern"),s("MemberExpression"))).field("right",s("Expression"));var h=i("++","--");s("UpdateExpression").bases("Expression").build("operator","argument","prefix").field("operator",h).field("argument",s("Expression")).field("prefix",Boolean);var b=i(...p);s("LogicalExpression").bases("Expression").build("operator","left","right").field("operator",b).field("left",s("Expression")).field("right",s("Expression")),s("ConditionalExpression").bases("Expression").build("test","consequent","alternate").field("test",s("Expression")).field("consequent",s("Expression")).field("alternate",s("Expression")),s("NewExpression").bases("Expression").build("callee","arguments").field("callee",s("Expression")).field("arguments",[s("Expression")]),s("CallExpression").bases("Expression").build("callee","arguments").field("callee",s("Expression")).field("arguments",[s("Expression")]),s("MemberExpression").bases("Expression").build("object","property","computed").field("object",s("Expression")).field("property",i(s("Identifier"),s("Expression"))).field("computed",Boolean,function(){var S=this.property.type;return S==="Literal"||S==="MemberExpression"||S==="BinaryExpression"}),s("Pattern").bases("Node"),s("SwitchCase").bases("Node").build("test","consequent").field("test",i(s("Expression"),null)).field("consequent",[s("Statement")]),s("Identifier").bases("Expression","Pattern").build("name").field("name",String).field("optional",Boolean,a.false),s("Literal").bases("Expression").build("value").field("value",i(String,Boolean,null,Number,RegExp,BigInt)),s("Comment").bases("Printable").field("value",String).field("leading",Boolean,a.true).field("trailing",Boolean,a.false)}Lr(()=>module);function tfe(e){e.use(efe);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("Function").field("generator",Boolean,i.false).field("expression",Boolean,i.false).field("defaults",[s(r("Expression"),null)],i.emptyArray).field("rest",s(r("Identifier"),null),i.null),r("RestElement").bases("Pattern").build("argument").field("argument",r("Pattern")).field("typeAnnotation",s(r("TypeAnnotation"),r("TSTypeAnnotation"),null),i.null),r("SpreadElementPattern").bases("Pattern").build("argument").field("argument",r("Pattern")),r("FunctionDeclaration").build("id","params","body","generator","expression").field("id",s(r("Identifier"),null)),r("FunctionExpression").build("id","params","body","generator","expression"),r("ArrowFunctionExpression").bases("Function","Expression").build("params","body","expression").field("id",null,i.null).field("body",s(r("BlockStatement"),r("Expression"))).field("generator",!1,i.false),r("ForOfStatement").bases("Statement").build("left","right","body").field("left",s(r("VariableDeclaration"),r("Pattern"))).field("right",r("Expression")).field("body",r("Statement")),r("YieldExpression").bases("Expression").build("argument","delegate").field("argument",s(r("Expression"),null)).field("delegate",Boolean,i.false),r("GeneratorExpression").bases("Expression").build("body","blocks","filter").field("body",r("Expression")).field("blocks",[r("ComprehensionBlock")]).field("filter",s(r("Expression"),null)),r("ComprehensionExpression").bases("Expression").build("body","blocks","filter").field("body",r("Expression")).field("blocks",[r("ComprehensionBlock")]).field("filter",s(r("Expression"),null)),r("ComprehensionBlock").bases("Node").build("left","right","each").field("left",r("Pattern")).field("right",r("Expression")).field("each",Boolean),r("Property").field("key",s(r("Literal"),r("Identifier"),r("Expression"))).field("value",s(r("Expression"),r("Pattern"))).field("method",Boolean,i.false).field("shorthand",Boolean,i.false).field("computed",Boolean,i.false),r("ObjectProperty").field("shorthand",Boolean,i.false),r("PropertyPattern").bases("Pattern").build("key","pattern").field("key",s(r("Literal"),r("Identifier"),r("Expression"))).field("pattern",r("Pattern")).field("computed",Boolean,i.false),r("ObjectPattern").bases("Pattern").build("properties").field("properties",[s(r("PropertyPattern"),r("Property"))]),r("ArrayPattern").bases("Pattern").build("elements").field("elements",[s(r("Pattern"),null)]),r("SpreadElement").bases("Node").build("argument").field("argument",r("Expression")),r("ArrayExpression").field("elements",[s(r("Expression"),r("SpreadElement"),r("RestElement"),null)]),r("NewExpression").field("arguments",[s(r("Expression"),r("SpreadElement"))]),r("CallExpression").field("arguments",[s(r("Expression"),r("SpreadElement"))]),r("AssignmentPattern").bases("Pattern").build("left","right").field("left",r("Pattern")).field("right",r("Expression")),r("MethodDefinition").bases("Declaration").build("kind","key","value","static").field("kind",s("constructor","method","get","set")).field("key",r("Expression")).field("value",r("Function")).field("computed",Boolean,i.false).field("static",Boolean,i.false);let n=s(r("MethodDefinition"),r("VariableDeclarator"),r("ClassPropertyDefinition"),r("ClassProperty"),r("StaticBlock"));r("ClassProperty").bases("Declaration").build("key").field("key",s(r("Literal"),r("Identifier"),r("Expression"))).field("computed",Boolean,i.false),r("ClassPropertyDefinition").bases("Declaration").build("definition").field("definition",n),r("ClassBody").bases("Declaration").build("body").field("body",[n]),r("ClassDeclaration").bases("Declaration").build("id","body","superClass").field("id",s(r("Identifier"),null)).field("body",r("ClassBody")).field("superClass",s(r("Expression"),null),i.null),r("ClassExpression").bases("Expression").build("id","body","superClass").field("id",s(r("Identifier"),null),i.null).field("body",r("ClassBody")).field("superClass",s(r("Expression"),null),i.null),r("Super").bases("Expression").build(),r("Specifier").bases("Node"),r("ModuleSpecifier").bases("Specifier").field("local",s(r("Identifier"),null),i.null).field("id",s(r("Identifier"),null),i.null).field("name",s(r("Identifier"),null),i.null),r("ImportSpecifier").bases("ModuleSpecifier").build("imported","local").field("imported",r("Identifier")),r("ImportDefaultSpecifier").bases("ModuleSpecifier").build("local"),r("ImportNamespaceSpecifier").bases("ModuleSpecifier").build("local"),r("ImportDeclaration").bases("Declaration").build("specifiers","source","importKind").field("specifiers",[s(r("ImportSpecifier"),r("ImportNamespaceSpecifier"),r("ImportDefaultSpecifier"))],i.emptyArray).field("source",r("Literal")).field("importKind",s("value","type"),function(){return"value"}),r("ExportNamedDeclaration").bases("Declaration").build("declaration","specifiers","source").field("declaration",s(r("Declaration"),null)).field("specifiers",[r("ExportSpecifier")],i.emptyArray).field("source",s(r("Literal"),null),i.null),r("ExportSpecifier").bases("ModuleSpecifier").build("local","exported").field("exported",r("Identifier")),r("ExportDefaultDeclaration").bases("Declaration").build("declaration").field("declaration",s(r("Declaration"),r("Expression"))),r("ExportAllDeclaration").bases("Declaration").build("source").field("source",r("Literal")),r("TaggedTemplateExpression").bases("Expression").build("tag","quasi").field("tag",r("Expression")).field("quasi",r("TemplateLiteral")),r("TemplateLiteral").bases("Expression").build("quasis","expressions").field("quasis",[r("TemplateElement")]).field("expressions",[r("Expression")]),r("TemplateElement").bases("Node").build("value","tail").field("value",{cooked:String,raw:String}).field("tail",Boolean),r("MetaProperty").bases("Expression").build("meta","property").field("meta",r("Identifier")).field("property",r("Identifier"))}Lr(()=>module);function rfe(e){e.use(GO),e.use(tfe)}Lr(()=>module);function sfe(e){e.use(rfe);let r=e.use(ds).Type.def,s=e.use(yn).defaults;r("Function").field("async",Boolean,s.false),r("AwaitExpression").bases("Expression").build("argument").field("argument",r("Expression"))}Lr(()=>module);function ife(e){e.use(sfe);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("ForOfStatement").field("await",Boolean,i.false),r("SpreadProperty").bases("Node").build("argument").field("argument",r("Expression")),r("ObjectExpression").field("properties",[s(r("Property"),r("SpreadProperty"),r("SpreadElement"))]),r("TemplateElement").field("value",{cooked:s(String,null),raw:String}),r("SpreadPropertyPattern").bases("Pattern").build("argument").field("argument",r("Pattern")),r("ObjectPattern").field("properties",[s(r("PropertyPattern"),r("Property"),r("RestElement"),r("SpreadPropertyPattern"))])}Lr(()=>module);function nfe(e){e.use(ife);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("CatchClause").field("param",s(r("Pattern"),null),i.null)}Lr(()=>module);function afe(e){e.use(YO),e.use(nfe);let t=e.use(ds),r=t.Type.def,s=t.Type.or,n=e.use(yn).defaults;r("ImportExpression").bases("Expression").build("source").field("source",r("Expression")),r("ExportAllDeclaration").bases("Declaration").build("source","exported").field("source",r("Literal")).field("exported",s(r("Identifier"),null,void 0),n.null),r("ChainElement").bases("Node").field("optional",Boolean,n.false),r("CallExpression").bases("Expression","ChainElement"),r("MemberExpression").bases("Expression","ChainElement"),r("ChainExpression").bases("Expression").build("expression").field("expression",r("ChainElement")),r("OptionalCallExpression").bases("CallExpression").build("callee","arguments","optional").field("optional",Boolean,n.true),r("OptionalMemberExpression").bases("MemberExpression").build("object","property","computed","optional").field("optional",Boolean,n.true)}Lr(()=>module);function ofe(e){e.use(Zpe),e.use(afe)}Lr(()=>module);function ufe(e){e.use(ofe);let r=e.use(ds).Type.def;r("StaticBlock").bases("Declaration").build("body").field("body",[r("Statement")])}Lr(()=>module);function Eh(e){e.use(ufe);let t=e.use(ds),r=t.Type,s=t.Type.def,i=r.or,a=e.use(yn).defaults;s("AwaitExpression").build("argument","all").field("argument",i(s("Expression"),null)).field("all",Boolean,a.false),s("Decorator").bases("Node").build("expression").field("expression",s("Expression")),s("Property").field("decorators",i([s("Decorator")],null),a.null),s("MethodDefinition").field("decorators",i([s("Decorator")],null),a.null),s("PrivateName").bases("Expression","Pattern").build("id").field("id",s("Identifier")),s("ClassPrivateProperty").bases("ClassProperty").build("key","value").field("key",s("PrivateName")).field("value",i(s("Expression"),null),a.null),s("ImportAttribute").bases("Node").build("key","value").field("key",i(s("Identifier"),s("Literal"))).field("value",s("Expression")),["ImportDeclaration","ExportAllDeclaration","ExportNamedDeclaration"].forEach(o=>{s(o).field("assertions",[s("ImportAttribute")],a.emptyArray)}),s("RecordExpression").bases("Expression").build("properties").field("properties",[i(s("ObjectProperty"),s("ObjectMethod"),s("SpreadElement"))]),s("TupleExpression").bases("Expression").build("elements").field("elements",[i(s("Expression"),s("SpreadElement"),null)]),s("ModuleExpression").bases("Node").build("body").field("body",s("Program"))}Lr(()=>module);function lfe(e){e.use(Eh);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("JSXAttribute").bases("Node").build("name","value").field("name",s(r("JSXIdentifier"),r("JSXNamespacedName"))).field("value",s(r("Literal"),r("JSXExpressionContainer"),r("JSXElement"),r("JSXFragment"),null),i.null),r("JSXIdentifier").bases("Identifier").build("name").field("name",String),r("JSXNamespacedName").bases("Node").build("namespace","name").field("namespace",r("JSXIdentifier")).field("name",r("JSXIdentifier")),r("JSXMemberExpression").bases("MemberExpression").build("object","property").field("object",s(r("JSXIdentifier"),r("JSXMemberExpression"))).field("property",r("JSXIdentifier")).field("computed",Boolean,i.false);let n=s(r("JSXIdentifier"),r("JSXNamespacedName"),r("JSXMemberExpression"));r("JSXSpreadAttribute").bases("Node").build("argument").field("argument",r("Expression"));let a=[s(r("JSXAttribute"),r("JSXSpreadAttribute"))];r("JSXExpressionContainer").bases("Expression").build("expression").field("expression",s(r("Expression"),r("JSXEmptyExpression")));let o=[s(r("JSXText"),r("JSXExpressionContainer"),r("JSXSpreadChild"),r("JSXElement"),r("JSXFragment"),r("Literal"))];r("JSXElement").bases("Expression").build("openingElement","closingElement","children").field("openingElement",r("JSXOpeningElement")).field("closingElement",s(r("JSXClosingElement"),null),i.null).field("children",o,i.emptyArray).field("name",n,function(){return this.openingElement.name},!0).field("selfClosing",Boolean,function(){return this.openingElement.selfClosing},!0).field("attributes",a,function(){return this.openingElement.attributes},!0),r("JSXOpeningElement").bases("Node").build("name","attributes","selfClosing").field("name",n).field("attributes",a,i.emptyArray).field("selfClosing",Boolean,i.false),r("JSXClosingElement").bases("Node").build("name").field("name",n),r("JSXFragment").bases("Expression").build("openingFragment","closingFragment","children").field("openingFragment",r("JSXOpeningFragment")).field("closingFragment",r("JSXClosingFragment")).field("children",o,i.emptyArray),r("JSXOpeningFragment").bases("Node").build(),r("JSXClosingFragment").bases("Node").build(),r("JSXText").bases("Literal").build("value","raw").field("value",String).field("raw",String,function(){return this.value}),r("JSXEmptyExpression").bases("Node").build(),r("JSXSpreadChild").bases("Node").build("expression").field("expression",r("Expression"))}Lr(()=>module);function QO(e){var t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults,n=s(r("TypeAnnotation"),r("TSTypeAnnotation"),null),a=s(r("TypeParameterDeclaration"),r("TSTypeParameterDeclaration"),null);r("Identifier").field("typeAnnotation",n,i.null),r("ObjectPattern").field("typeAnnotation",n,i.null),r("Function").field("returnType",n,i.null).field("typeParameters",a,i.null),r("ClassProperty").build("key","value","typeAnnotation","static").field("value",s(r("Expression"),null)).field("static",Boolean,i.false).field("typeAnnotation",n,i.null),["ClassDeclaration","ClassExpression"].forEach(o=>{r(o).field("typeParameters",a,i.null).field("superTypeParameters",s(r("TypeParameterInstantiation"),r("TSTypeParameterInstantiation"),null),i.null).field("implements",s([r("ClassImplements")],[r("TSExpressionWithTypeArguments")]),i.emptyArray)})}Lr(()=>module);function ZO(e){e.use(Eh),e.use(QO);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("Flow").bases("Node"),r("FlowType").bases("Flow"),r("AnyTypeAnnotation").bases("FlowType").build(),r("EmptyTypeAnnotation").bases("FlowType").build(),r("MixedTypeAnnotation").bases("FlowType").build(),r("VoidTypeAnnotation").bases("FlowType").build(),r("SymbolTypeAnnotation").bases("FlowType").build(),r("NumberTypeAnnotation").bases("FlowType").build(),r("BigIntTypeAnnotation").bases("FlowType").build(),r("NumberLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),r("NumericLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),r("BigIntLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",null).field("raw",String),r("StringTypeAnnotation").bases("FlowType").build(),r("StringLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",String).field("raw",String),r("BooleanTypeAnnotation").bases("FlowType").build(),r("BooleanLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Boolean).field("raw",String),r("TypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",r("FlowType")),r("NullableTypeAnnotation").bases("FlowType").build("typeAnnotation").field("typeAnnotation",r("FlowType")),r("NullLiteralTypeAnnotation").bases("FlowType").build(),r("NullTypeAnnotation").bases("FlowType").build(),r("ThisTypeAnnotation").bases("FlowType").build(),r("ExistsTypeAnnotation").bases("FlowType").build(),r("ExistentialTypeParam").bases("FlowType").build(),r("FunctionTypeAnnotation").bases("FlowType").build("params","returnType","rest","typeParameters").field("params",[r("FunctionTypeParam")]).field("returnType",r("FlowType")).field("rest",s(r("FunctionTypeParam"),null)).field("typeParameters",s(r("TypeParameterDeclaration"),null)),r("FunctionTypeParam").bases("Node").build("name","typeAnnotation","optional").field("name",s(r("Identifier"),null)).field("typeAnnotation",r("FlowType")).field("optional",Boolean),r("ArrayTypeAnnotation").bases("FlowType").build("elementType").field("elementType",r("FlowType")),r("ObjectTypeAnnotation").bases("FlowType").build("properties","indexers","callProperties").field("properties",[s(r("ObjectTypeProperty"),r("ObjectTypeSpreadProperty"))]).field("indexers",[r("ObjectTypeIndexer")],i.emptyArray).field("callProperties",[r("ObjectTypeCallProperty")],i.emptyArray).field("inexact",s(Boolean,void 0),i.undefined).field("exact",Boolean,i.false).field("internalSlots",[r("ObjectTypeInternalSlot")],i.emptyArray),r("Variance").bases("Node").build("kind").field("kind",s("plus","minus"));let n=s(r("Variance"),"plus","minus",null);r("ObjectTypeProperty").bases("Node").build("key","value","optional").field("key",s(r("Literal"),r("Identifier"))).field("value",r("FlowType")).field("optional",Boolean).field("variance",n,i.null),r("ObjectTypeIndexer").bases("Node").build("id","key","value").field("id",r("Identifier")).field("key",r("FlowType")).field("value",r("FlowType")).field("variance",n,i.null).field("static",Boolean,i.false),r("ObjectTypeCallProperty").bases("Node").build("value").field("value",r("FunctionTypeAnnotation")).field("static",Boolean,i.false),r("QualifiedTypeIdentifier").bases("Node").build("qualification","id").field("qualification",s(r("Identifier"),r("QualifiedTypeIdentifier"))).field("id",r("Identifier")),r("GenericTypeAnnotation").bases("FlowType").build("id","typeParameters").field("id",s(r("Identifier"),r("QualifiedTypeIdentifier"))).field("typeParameters",s(r("TypeParameterInstantiation"),null)),r("MemberTypeAnnotation").bases("FlowType").build("object","property").field("object",r("Identifier")).field("property",s(r("MemberTypeAnnotation"),r("GenericTypeAnnotation"))),r("IndexedAccessType").bases("FlowType").build("objectType","indexType").field("objectType",r("FlowType")).field("indexType",r("FlowType")),r("OptionalIndexedAccessType").bases("FlowType").build("objectType","indexType","optional").field("objectType",r("FlowType")).field("indexType",r("FlowType")).field("optional",Boolean),r("UnionTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("IntersectionTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("TypeofTypeAnnotation").bases("FlowType").build("argument").field("argument",r("FlowType")),r("ObjectTypeSpreadProperty").bases("Node").build("argument").field("argument",r("FlowType")),r("ObjectTypeInternalSlot").bases("Node").build("id","value","optional","static","method").field("id",r("Identifier")).field("value",r("FlowType")).field("optional",Boolean).field("static",Boolean).field("method",Boolean),r("TypeParameterDeclaration").bases("Node").build("params").field("params",[r("TypeParameter")]),r("TypeParameterInstantiation").bases("Node").build("params").field("params",[r("FlowType")]),r("TypeParameter").bases("FlowType").build("name","variance","bound","default").field("name",String).field("variance",n,i.null).field("bound",s(r("TypeAnnotation"),null),i.null).field("default",s(r("FlowType"),null),i.null),r("ClassProperty").field("variance",n,i.null),r("ClassImplements").bases("Node").build("id").field("id",r("Identifier")).field("superClass",s(r("Expression"),null),i.null).field("typeParameters",s(r("TypeParameterInstantiation"),null),i.null),r("InterfaceTypeAnnotation").bases("FlowType").build("body","extends").field("body",r("ObjectTypeAnnotation")).field("extends",s([r("InterfaceExtends")],null),i.null),r("InterfaceDeclaration").bases("Declaration").build("id","body","extends").field("id",r("Identifier")).field("typeParameters",s(r("TypeParameterDeclaration"),null),i.null).field("body",r("ObjectTypeAnnotation")).field("extends",[r("InterfaceExtends")]),r("DeclareInterface").bases("InterfaceDeclaration").build("id","body","extends"),r("InterfaceExtends").bases("Node").build("id").field("id",r("Identifier")).field("typeParameters",s(r("TypeParameterInstantiation"),null),i.null),r("TypeAlias").bases("Declaration").build("id","typeParameters","right").field("id",r("Identifier")).field("typeParameters",s(r("TypeParameterDeclaration"),null)).field("right",r("FlowType")),r("DeclareTypeAlias").bases("TypeAlias").build("id","typeParameters","right"),r("OpaqueType").bases("Declaration").build("id","typeParameters","impltype","supertype").field("id",r("Identifier")).field("typeParameters",s(r("TypeParameterDeclaration"),null)).field("impltype",r("FlowType")).field("supertype",s(r("FlowType"),null)),r("DeclareOpaqueType").bases("OpaqueType").build("id","typeParameters","supertype").field("impltype",s(r("FlowType"),null)),r("TypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",r("Expression")).field("typeAnnotation",r("TypeAnnotation")),r("TupleTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("DeclareVariable").bases("Statement").build("id").field("id",r("Identifier")),r("DeclareFunction").bases("Statement").build("id").field("id",r("Identifier")).field("predicate",s(r("FlowPredicate"),null),i.null),r("DeclareClass").bases("InterfaceDeclaration").build("id"),r("DeclareModule").bases("Statement").build("id","body").field("id",s(r("Identifier"),r("Literal"))).field("body",r("BlockStatement")),r("DeclareModuleExports").bases("Statement").build("typeAnnotation").field("typeAnnotation",r("TypeAnnotation")),r("DeclareExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",s(r("DeclareVariable"),r("DeclareFunction"),r("DeclareClass"),r("FlowType"),r("TypeAlias"),r("DeclareOpaqueType"),r("InterfaceDeclaration"),null)).field("specifiers",[s(r("ExportSpecifier"),r("ExportBatchSpecifier"))],i.emptyArray).field("source",s(r("Literal"),null),i.null),r("DeclareExportAllDeclaration").bases("Declaration").build("source").field("source",s(r("Literal"),null),i.null),r("ImportDeclaration").field("importKind",s("value","type","typeof"),()=>"value"),r("FlowPredicate").bases("Flow"),r("InferredPredicate").bases("FlowPredicate").build(),r("DeclaredPredicate").bases("FlowPredicate").build("value").field("value",r("Expression")),r("Function").field("predicate",s(r("FlowPredicate"),null),i.null),r("CallExpression").field("typeArguments",s(null,r("TypeParameterInstantiation")),i.null),r("NewExpression").field("typeArguments",s(null,r("TypeParameterInstantiation")),i.null),r("EnumDeclaration").bases("Declaration").build("id","body").field("id",r("Identifier")).field("body",s(r("EnumBooleanBody"),r("EnumNumberBody"),r("EnumStringBody"),r("EnumSymbolBody"))),r("EnumBooleanBody").build("members","explicitType").field("members",[r("EnumBooleanMember")]).field("explicitType",Boolean),r("EnumNumberBody").build("members","explicitType").field("members",[r("EnumNumberMember")]).field("explicitType",Boolean),r("EnumStringBody").build("members","explicitType").field("members",s([r("EnumStringMember")],[r("EnumDefaultedMember")])).field("explicitType",Boolean),r("EnumSymbolBody").build("members").field("members",[r("EnumDefaultedMember")]),r("EnumBooleanMember").build("id","init").field("id",r("Identifier")).field("init",s(r("Literal"),Boolean)),r("EnumNumberMember").build("id","init").field("id",r("Identifier")).field("init",r("Literal")),r("EnumStringMember").build("id","init").field("id",r("Identifier")).field("init",r("Literal")),r("EnumDefaultedMember").build("id").field("id",r("Identifier"))}Lr(()=>module);function cfe(e){e.use(Eh);var t=e.use(ds),r=e.use(yn).defaults,s=t.Type.def,i=t.Type.or;s("VariableDeclaration").field("declarations",[i(s("VariableDeclarator"),s("Identifier"))]),s("Property").field("value",i(s("Expression"),s("Pattern"))),s("ArrayPattern").field("elements",[i(s("Pattern"),s("SpreadElement"),null)]),s("ObjectPattern").field("properties",[i(s("Property"),s("PropertyPattern"),s("SpreadPropertyPattern"),s("SpreadProperty"))]),s("ExportSpecifier").bases("ModuleSpecifier").build("id","name"),s("ExportBatchSpecifier").bases("Specifier").build(),s("ExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",i(s("Declaration"),s("Expression"),null)).field("specifiers",[i(s("ExportSpecifier"),s("ExportBatchSpecifier"))],r.emptyArray).field("source",i(s("Literal"),null),r.null),s("Block").bases("Comment").build("value","leading","trailing"),s("Line").bases("Comment").build("value","leading","trailing")}Lr(()=>module);function e4(e){e.use(Eh);let t=e.use(ds),r=e.use(yn).defaults,s=t.Type.def,i=t.Type.or,{undefined:n}=t.builtInTypes;s("Noop").bases("Statement").build(),s("DoExpression").bases("Expression").build("body").field("body",[s("Statement")]),s("BindExpression").bases("Expression").build("object","callee").field("object",i(s("Expression"),null)).field("callee",s("Expression")),s("ParenthesizedExpression").bases("Expression").build("expression").field("expression",s("Expression")),s("ExportNamespaceSpecifier").bases("Specifier").build("exported").field("exported",s("Identifier")),s("ExportDefaultSpecifier").bases("Specifier").build("exported").field("exported",s("Identifier")),s("CommentBlock").bases("Comment").build("value","leading","trailing"),s("CommentLine").bases("Comment").build("value","leading","trailing"),s("Directive").bases("Node").build("value").field("value",s("DirectiveLiteral")),s("DirectiveLiteral").bases("Node","Expression").build("value").field("value",String,r["use strict"]),s("InterpreterDirective").bases("Node").build("value").field("value",String),s("BlockStatement").bases("Statement").build("body").field("body",[s("Statement")]).field("directives",[s("Directive")],r.emptyArray),s("Program").bases("Node").build("body").field("body",[s("Statement")]).field("directives",[s("Directive")],r.emptyArray).field("interpreter",i(s("InterpreterDirective"),null),r.null);function a(p=String,m){return["extra",{rawValue:p,raw:String},function(){let d=t.getFieldValue(this,"value");return{rawValue:d,raw:m?m(d):String(d)}}]}s("StringLiteral").bases("Literal").build("value").field("value",String).field(...a(String,p=>JSON.stringify(p))),s("NumericLiteral").bases("Literal").build("value").field("value",Number).field("raw",i(String,null),r.null).field(...a(Number)),s("BigIntLiteral").bases("Literal").build("value").field("value",i(String,Number)).field(...a(String,p=>p+"n")),s("DecimalLiteral").bases("Literal").build("value").field("value",String).field(...a(String,p=>p+"m")),s("NullLiteral").bases("Literal").build().field("value",null,r.null),s("BooleanLiteral").bases("Literal").build("value").field("value",Boolean),s("RegExpLiteral").bases("Literal").build("pattern","flags").field("pattern",String).field("flags",String).field("value",RegExp,function(){return new RegExp(this.pattern,this.flags)}).field(...a(i(RegExp,n),p=>`/${p.pattern}/${p.flags||""}`)).field("regex",{pattern:String,flags:String},function(){return{pattern:this.pattern,flags:this.flags}});var o=i(s("Property"),s("ObjectMethod"),s("ObjectProperty"),s("SpreadProperty"),s("SpreadElement"));s("ObjectExpression").bases("Expression").build("properties").field("properties",[o]),s("ObjectMethod").bases("Node","Function").build("kind","key","params","body","computed").field("kind",i("method","get","set")).field("key",i(s("Literal"),s("Identifier"),s("Expression"))).field("params",[s("Pattern")]).field("body",s("BlockStatement")).field("computed",Boolean,r.false).field("generator",Boolean,r.false).field("async",Boolean,r.false).field("accessibility",i(s("Literal"),null),r.null).field("decorators",i([s("Decorator")],null),r.null),s("ObjectProperty").bases("Node").build("key","value").field("key",i(s("Literal"),s("Identifier"),s("Expression"))).field("value",i(s("Expression"),s("Pattern"))).field("accessibility",i(s("Literal"),null),r.null).field("computed",Boolean,r.false);var u=i(s("MethodDefinition"),s("VariableDeclarator"),s("ClassPropertyDefinition"),s("ClassProperty"),s("ClassPrivateProperty"),s("ClassMethod"),s("ClassPrivateMethod"),s("ClassAccessorProperty"),s("StaticBlock"));s("ClassBody").bases("Declaration").build("body").field("body",[u]),s("ClassMethod").bases("Declaration","Function").build("kind","key","params","body","computed","static").field("key",i(s("Literal"),s("Identifier"),s("Expression"))),s("ClassPrivateMethod").bases("Declaration","Function").build("key","params","body","kind","computed","static").field("key",s("PrivateName")),s("ClassAccessorProperty").bases("Declaration").build("key","value","decorators","computed","static").field("key",i(s("Literal"),s("Identifier"),s("PrivateName"),s("Expression"))).field("value",i(s("Expression"),null),r.null),["ClassMethod","ClassPrivateMethod"].forEach(p=>{s(p).field("kind",i("get","set","method","constructor"),()=>"method").field("body",s("BlockStatement")).field("access",i("public","private","protected",null),r.null)}),["ClassMethod","ClassPrivateMethod","ClassAccessorProperty"].forEach(p=>{s(p).field("computed",Boolean,r.false).field("static",Boolean,r.false).field("abstract",Boolean,r.false).field("accessibility",i("public","private","protected",null),r.null).field("decorators",i([s("Decorator")],null),r.null).field("definite",Boolean,r.false).field("optional",Boolean,r.false).field("override",Boolean,r.false).field("readonly",Boolean,r.false)});var c=i(s("Property"),s("PropertyPattern"),s("SpreadPropertyPattern"),s("SpreadProperty"),s("ObjectProperty"),s("RestProperty"),s("RestElement"));s("ObjectPattern").bases("Pattern").build("properties").field("properties",[c]).field("decorators",i([s("Decorator")],null),r.null),s("SpreadProperty").bases("Node").build("argument").field("argument",s("Expression")),s("RestProperty").bases("Node").build("argument").field("argument",s("Expression")),s("ForAwaitStatement").bases("Statement").build("left","right","body").field("left",i(s("VariableDeclaration"),s("Expression"))).field("right",s("Expression")).field("body",s("Statement")),s("Import").bases("Expression").build()}Lr(()=>module);function pfe(e){let r=e.use(ds).Type.def;e.use(e4),e.use(ZO),r("V8IntrinsicIdentifier").bases("Expression").build("name").field("name",String),r("TopicReference").bases("Expression").build()}Lr(()=>module);function ffe(e){e.use(e4),e.use(QO);var t=e.use(ds),r=t.namedTypes,s=t.Type.def,i=t.Type.or,n=e.use(yn).defaults,a=t.Type.from(function(p,m){return!!(r.StringLiteral&&r.StringLiteral.check(p,m)||r.Literal&&r.Literal.check(p,m)&&typeof p.value=="string")},"StringLiteral");s("TSType").bases("Node");var o=i(s("Identifier"),s("TSQualifiedName"));s("TSTypeReference").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("typeName","typeParameters").field("typeName",o),s("TSHasOptionalTypeParameterInstantiation").field("typeParameters",i(s("TSTypeParameterInstantiation"),null),n.null),s("TSHasOptionalTypeParameters").field("typeParameters",i(s("TSTypeParameterDeclaration"),null,void 0),n.null),s("TSHasOptionalTypeAnnotation").field("typeAnnotation",i(s("TSTypeAnnotation"),null),n.null),s("TSQualifiedName").bases("Node").build("left","right").field("left",o).field("right",o),s("TSAsExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",s("Expression")).field("typeAnnotation",s("TSType")).field("extra",i({parenthesized:Boolean},null),n.null),s("TSTypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",s("Expression")).field("typeAnnotation",s("TSType")),s("TSSatisfiesExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",s("Expression")).field("typeAnnotation",s("TSType")),s("TSNonNullExpression").bases("Expression","Pattern").build("expression").field("expression",s("Expression")),["TSAnyKeyword","TSBigIntKeyword","TSBooleanKeyword","TSNeverKeyword","TSNullKeyword","TSNumberKeyword","TSObjectKeyword","TSStringKeyword","TSSymbolKeyword","TSUndefinedKeyword","TSUnknownKeyword","TSVoidKeyword","TSIntrinsicKeyword","TSThisType"].forEach(p=>{s(p).bases("TSType").build()}),s("TSArrayType").bases("TSType").build("elementType").field("elementType",s("TSType")),s("TSLiteralType").bases("TSType").build("literal").field("literal",i(s("NumericLiteral"),s("StringLiteral"),s("BooleanLiteral"),s("TemplateLiteral"),s("UnaryExpression"),s("BigIntLiteral"))),s("TemplateLiteral").field("expressions",i([s("Expression")],[s("TSType")])),["TSUnionType","TSIntersectionType"].forEach(p=>{s(p).bases("TSType").build("types").field("types",[s("TSType")])}),s("TSConditionalType").bases("TSType").build("checkType","extendsType","trueType","falseType").field("checkType",s("TSType")).field("extendsType",s("TSType")).field("trueType",s("TSType")).field("falseType",s("TSType")),s("TSInferType").bases("TSType").build("typeParameter").field("typeParameter",s("TSTypeParameter")),s("TSParenthesizedType").bases("TSType").build("typeAnnotation").field("typeAnnotation",s("TSType"));var u=[i(s("Identifier"),s("RestElement"),s("ArrayPattern"),s("ObjectPattern"))];["TSFunctionType","TSConstructorType"].forEach(p=>{s(p).bases("TSType","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters").field("parameters",u)}),s("TSDeclareFunction").bases("Declaration","TSHasOptionalTypeParameters").build("id","params","returnType").field("declare",Boolean,n.false).field("async",Boolean,n.false).field("generator",Boolean,n.false).field("id",i(s("Identifier"),null),n.null).field("params",[s("Pattern")]).field("returnType",i(s("TSTypeAnnotation"),s("Noop"),null),n.null),s("TSDeclareMethod").bases("Declaration","TSHasOptionalTypeParameters").build("key","params","returnType").field("async",Boolean,n.false).field("generator",Boolean,n.false).field("params",[s("Pattern")]).field("abstract",Boolean,n.false).field("accessibility",i("public","private","protected",void 0),n.undefined).field("static",Boolean,n.false).field("computed",Boolean,n.false).field("optional",Boolean,n.false).field("key",i(s("Identifier"),s("StringLiteral"),s("NumericLiteral"),s("Expression"))).field("kind",i("get","set","method","constructor"),function(){return"method"}).field("access",i("public","private","protected",void 0),n.undefined).field("decorators",i([s("Decorator")],null),n.null).field("returnType",i(s("TSTypeAnnotation"),s("Noop"),null),n.null),s("TSMappedType").bases("TSType").build("typeParameter","typeAnnotation").field("readonly",i(Boolean,"+","-"),n.false).field("typeParameter",s("TSTypeParameter")).field("optional",i(Boolean,"+","-"),n.false).field("typeAnnotation",i(s("TSType"),null),n.null),s("TSTupleType").bases("TSType").build("elementTypes").field("elementTypes",[i(s("TSType"),s("TSNamedTupleMember"))]),s("TSNamedTupleMember").bases("TSType").build("label","elementType","optional").field("label",s("Identifier")).field("optional",Boolean,n.false).field("elementType",s("TSType")),s("TSRestType").bases("TSType").build("typeAnnotation").field("typeAnnotation",s("TSType")),s("TSOptionalType").bases("TSType").build("typeAnnotation").field("typeAnnotation",s("TSType")),s("TSIndexedAccessType").bases("TSType").build("objectType","indexType").field("objectType",s("TSType")).field("indexType",s("TSType")),s("TSTypeOperator").bases("TSType").build("operator").field("operator",String).field("typeAnnotation",s("TSType")),s("TSTypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",i(s("TSType"),s("TSTypeAnnotation"))),s("TSIndexSignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",[s("Identifier")]).field("readonly",Boolean,n.false),s("TSPropertySignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("key","typeAnnotation","optional").field("key",s("Expression")).field("computed",Boolean,n.false).field("readonly",Boolean,n.false).field("optional",Boolean,n.false).field("initializer",i(s("Expression"),null),n.null),s("TSMethodSignature").bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("key","parameters","typeAnnotation").field("key",s("Expression")).field("computed",Boolean,n.false).field("optional",Boolean,n.false).field("parameters",u),s("TSTypePredicate").bases("TSTypeAnnotation","TSType").build("parameterName","typeAnnotation","asserts").field("parameterName",i(s("Identifier"),s("TSThisType"))).field("typeAnnotation",i(s("TSTypeAnnotation"),null),n.null).field("asserts",Boolean,n.false),["TSCallSignatureDeclaration","TSConstructSignatureDeclaration"].forEach(p=>{s(p).bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",u)}),s("TSEnumMember").bases("Node").build("id","initializer").field("id",i(s("Identifier"),a)).field("initializer",i(s("Expression"),null),n.null),s("TSTypeQuery").bases("TSType").build("exprName").field("exprName",i(o,s("TSImportType")));var c=i(s("TSCallSignatureDeclaration"),s("TSConstructSignatureDeclaration"),s("TSIndexSignature"),s("TSMethodSignature"),s("TSPropertySignature"));s("TSTypeLiteral").bases("TSType").build("members").field("members",[c]),s("TSTypeParameter").bases("Identifier").build("name","constraint","default").field("name",i(s("Identifier"),String)).field("constraint",i(s("TSType"),void 0),n.undefined).field("default",i(s("TSType"),void 0),n.undefined),s("TSTypeAssertion").bases("Expression","Pattern").build("typeAnnotation","expression").field("typeAnnotation",s("TSType")).field("expression",s("Expression")).field("extra",i({parenthesized:Boolean},null),n.null),s("TSTypeParameterDeclaration").bases("Declaration").build("params").field("params",[s("TSTypeParameter")]),s("TSInstantiationExpression").bases("Expression","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",s("Expression")),s("TSTypeParameterInstantiation").bases("Node").build("params").field("params",[s("TSType")]),s("TSEnumDeclaration").bases("Declaration").build("id","members").field("id",s("Identifier")).field("const",Boolean,n.false).field("declare",Boolean,n.false).field("members",[s("TSEnumMember")]).field("initializer",i(s("Expression"),null),n.null),s("TSTypeAliasDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","typeAnnotation").field("id",s("Identifier")).field("declare",Boolean,n.false).field("typeAnnotation",s("TSType")),s("TSModuleBlock").bases("Node").build("body").field("body",[s("Statement")]),s("TSModuleDeclaration").bases("Declaration").build("id","body").field("id",i(a,o)).field("declare",Boolean,n.false).field("global",Boolean,n.false).field("body",i(s("TSModuleBlock"),s("TSModuleDeclaration"),null),n.null),s("TSImportType").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("argument","qualifier","typeParameters").field("argument",a).field("qualifier",i(o,void 0),n.undefined),s("TSImportEqualsDeclaration").bases("Declaration").build("id","moduleReference").field("id",s("Identifier")).field("isExport",Boolean,n.false).field("moduleReference",i(o,s("TSExternalModuleReference"))),s("TSExternalModuleReference").bases("Declaration").build("expression").field("expression",a),s("TSExportAssignment").bases("Statement").build("expression").field("expression",s("Expression")),s("TSNamespaceExportDeclaration").bases("Declaration").build("id").field("id",s("Identifier")),s("TSInterfaceBody").bases("Node").build("body").field("body",[c]),s("TSExpressionWithTypeArguments").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",o),s("TSInterfaceDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","body").field("id",o).field("declare",Boolean,n.false).field("extends",i([s("TSExpressionWithTypeArguments")],null),n.null).field("body",s("TSInterfaceBody")),s("TSParameterProperty").bases("Pattern").build("parameter").field("accessibility",i("public","private","protected",void 0),n.undefined).field("readonly",Boolean,n.false).field("parameter",i(s("Identifier"),s("AssignmentPattern"))),s("ClassProperty").field("access",i("public","private","protected",void 0),n.undefined),s("ClassAccessorProperty").bases("Declaration","TSHasOptionalTypeAnnotation"),s("ClassBody").field("body",[i(s("MethodDefinition"),s("VariableDeclarator"),s("ClassPropertyDefinition"),s("ClassProperty"),s("ClassPrivateProperty"),s("ClassAccessorProperty"),s("ClassMethod"),s("ClassPrivateMethod"),s("StaticBlock"),s("TSDeclareMethod"),c)])}Lr(()=>module);var ta;ta||(ta={});var{astNodesAreEquivalent:O1t,builders:Wc,builtInTypes:ra,defineMethod:B1t,eachField:L1t,finalize:M1t,getBuilderName:R1t,getFieldNames:hfe,getFieldValue:fo,getSupertypeNames:j1t,namedTypes:dfe,NodePath:mfe,Path:$1t,PathVisitor:q1t,someField:yfe,Type:U1t,use:V1t,visit:J1t}=Ype([Eh,lfe,ZO,cfe,pfe,ffe]);Object.assign(ta,dfe);var p0=ta,NO=C0.default.SourceMapConsumer,gfe=C0.default.SourceMapGenerator,t4=Object.prototype.hasOwnProperty;function xfe(){return`
|
|
227
|
+
`,enum:["on","off"]}],minItems:2,maxItems:2}},properties:{parser:{description:"Tell \u{1F40A}Putout which parser to use",type:"string"},printer:{description:"Tell \u{1F40A}Putout which printer to use",oneOf:[{type:"string"},{type:"array",minItems:2,maxItems:2,items:[{type:"string"},{type:"object"}]}]},formatter:{description:"Choose the way to show information about errors found",type:["string","array"]},processors:{description:"Tell \u{1F40A}Putout which processors to use to support file types other then JavaScript",type:"array",uniqueItems:!0,items:{oneOf:[{$ref:"#/definitions/processorToggle"},{type:"string"}]}},ignore:{description:"Tell \u{1F40A}Putout to ignore specific files and directories.",type:"array",uniqueItems:!0,items:{type:"string"}},match:{description:"Allows to match rules for files and folders, specified by glob patterns.",type:"object",patternProperties:{"^.*$":{$ref:"#/definitions/rules"}}},plugins:{description:"Tell \u{1F40A}Putout which plugins to load",type:"array",uniqueItems:!0},rules:{$ref:"#/definitions/rules"}}}});var mte=F((l2t,dte)=>{"use strict";var lpt=pte(),cpt=fte(),ppt=new lpt({strict:!0,allowUnionTypes:!0}),hte=ppt.compile(cpt);dte.exports.validateOptions=e=>{hte(e);let[t]=hte.errors||[];if(t)throw Error(`.putout.json: ${mpt(t)}${dpt(t)}${hpt(t)}${fpt(t)}`)};function fpt(e){let{allowedValues:t}=e.params;return t?` (${t.join("/")})`:""}function hpt(e){return e.message.replace(","," or ")}var dpt=e=>{let{additionalProperty:t}=e.params;return t?`${t}: `:""},mpt=e=>{let{instancePath:t}=e;return t?`${e.instancePath.slice(1)}: `:""}});var Ete=F((c2t,Ste)=>{"use strict";var ypt=It("process"),{homedir:gpt}=It("os"),{readdirSync:xpt}=It("fs"),{dirname:bpt,join:xS}=It("path"),gte=Fa(),g3=xp(),Spt=DI(),y3=MI(),yte=MQ(),gS=Rb(),Ept=KQ(),Tpt=XQ(),{validateOptions:vpt}=mte(),xte=gpt();Ste.exports=(e={})=>{let{rulesdir:t,name:r="",options:s={},readOptions:i=Cpt,readHomeOptions:n=Ppt,readCodeMods:a=wpt}=e,[o,u]=i(r),c=n(),p=y3(r,yte.match),g=gS(...[yte,c,p,u,s]),d=gS(g,y3(r,g.match),s),h=gS(u,s,y3(r,s.match)),b=gS(a(),bte("./",t),g,d,h);return vpt(b),{...b,dir:o}};var Apt=e=>(t,r)=>r.includes(e)&&e;function Cpt(e){let[t,r]=Ept(e,".putout.json"),[,s]=g3(Spt,e,Apt("package.json"));return s&&Tpt(It(s),r),t?[t,r]:s?[bpt(s),{...r,...It(s).putout}]:["",{}]}var Dpt=e=>e[0]!=="."&&!/(^not-rule-.*|^node_modules$)/.test(e);function bte(e,t){if(!t)return{};let r=xS(e,t);r.startsWith("/")||(r=xS(ypt.cwd(),t));let[s,i]=g3(xpt,r);if(s)return{};let n=[];for(let a of i.filter(Dpt)){let o=xS(r,a);n.push(`import:${o}`)}return{plugins:n}}var Ppt=gte(()=>{let e=xS(xte,".putout.json"),[,t={}]=g3(It,e);return t}),wpt=gte(()=>bte(xte,".putout"))});var Nte=F((y2t,Lu)=>{"use strict";var{isIdentifier:sc,isObjectExpression:Pte,isObjectPattern:_pt,isTemplateLiteral:Opt,isAssignmentPattern:Bpt}=Wi().types,wte=({use:e,declare:t})=>{let r=S3({use:e});return s=>{for(let i of s){if(i.isRestElement())continue;let{key:n,value:a}=i.node,o=i.get("value");switch(a.type){case"Identifier":t(i,a.name);break;case"AssignmentPattern":i.node.shorthand?t(i,n.name):t(i,o.node.left.name),r(o);break}}}};Lu.exports.traverseObjectPattern=wte;var Ite=({use:e,declare:t})=>r=>{for(let s of r){let{key:i,value:n,computed:a}=s.node;if(a&&sc(i)&&e(s,i.name),sc(n)){t(s,n.name);continue}if(_pt(n)){Ite({use:e,declare:t})(s.get("value.properties"));continue}if(Bpt(n)){S3({use:e})(s.get("value.right"));let u=s.get("value.left");switch(u.type){case"Identifier":t(s,u.node.name);continue}}}};Lu.exports.processObjectPattern=Ite;var b3=e=>{let t=kte(e);return r=>{for(let s of r){let{node:i}=s,{key:n,value:a,computed:o}=i;if(o&&sc(n)&&e(s,n.name),sc(a)){e(s,a.name);continue}if(Opt(a)){t(s,a.expressions);continue}if(Pte(a)){b3(e)(s.get("value.properties"));continue}}}};Lu.exports.traverseObjectExpression=b3;var Lpt=e=>{let t=b3(e);return r=>{for(let s of r){let{node:i}=s;Pte(i)&&t(s.get("properties"))}}};Lu.exports.traverseArrayExpression=Lpt;var Mpt=({use:e,declare:t})=>{let r=wte({use:e,declare:t});return s=>{let i=s.get("left"),n=s.get("right");if(i.isIdentifier()){let{parentPath:a}=i.parentPath,{name:o}=i.node;a.isObjectProperty()&&t(a,o),a.isFunction()&&t(i.parentPath,o)}n.isIdentifier()&&e(n,n.node.name),i.isObjectPattern()&&r(i.get("properties"))}};Lu.exports.traverseAssignmentExpression=Mpt;var kte=e=>(t,r)=>{for(let s of r)sc(s)&&e(t,s.name)};Lu.exports.traverseTemplateLiteral=kte;var S3=({use:e})=>t=>{let{node:r}=t,{right:s}=r;sc(r)&&e(t.parentPath,r.name),sc(s)&&e(t,s.name)};Lu.exports.traverseAssignmentPattern=S3});var _te=F((g2t,Fte)=>{"use strict";var{types:Rpt}=Wi(),{isIdentifier:jpt,isJSXIdentifier:$pt}=Rpt;Fte.exports=e=>({JSXOpeningElement(t){let{node:r}=t,{name:s}=r;/^[A-Z]/.test(s.name)&&e(t,s.name),e(t,"React")},JSXFragment(t){e(t,"React")},JSXSpreadAttribute(t){let r=t.get("argument");if(r.isIdentifier())return e(t,r.node.name)},JSXMemberExpression(t){let{node:r}=t,{object:s}=r;$pt(s)&&e(t,s.name)},JSXExpressionContainer(t){let{node:r}=t,{expression:s}=r;jpt(s)&&e(t,s.name)}})});var Bte=F((x2t,Ote)=>{"use strict";var{types:qpt}=Wi(),{isIdentifier:Upt}=qpt;Ote.exports=({use:e,declare:t})=>({GenericTypeAnnotation(r){let{node:s}=r,{id:i}=s;Upt(i)&&e(r,i.name)},QualifiedTypeIdentifier(r){let{qualification:s}=r.node,{type:i}=s;switch(i){case"Identifier":return e(r,s.name)}},InterfaceDeclaration(r){t(r,r.node.id.name)}})});var Mte=F((b2t,Lte)=>{"use strict";var{types:Vpt}=Wi(),{isIdentifier:Jpt,isTSModuleDeclaration:Kpt}=Vpt;Lte.exports=({use:e,declare:t})=>({TSExpressionWithTypeArguments(r){let{expression:s}=r.node,{type:i}=s;switch(i){case"Identifier":e(r,s.name)}},TSFunctionType(r){let{node:s}=r,{params:i}=s;for(let n of i){let{type:a}=n;switch(a){case"Identifier":t(r,n.name),e(r,n.name);break;case"RestElement":Jpt(n.argument)&&(t(r,n.argument.name),e(r,n.argument.name))}}},TSTypeReference(r){let{node:s}=r,{typeName:i}=s,{type:n}=i;switch(n){case"Identifier":e(r,i.name)}},TSTypeAliasDeclaration(r){let{node:s}=r,{id:i}=s,{type:n}=i;switch(n){case"Identifier":t(r,i.name)}},TSTypeQuery(r){let{node:s}=r,{exprName:i}=s,{type:n}=i;switch(n){case"Identifier":e(r,i.name)}},TSAsExpression(r){let{node:s}=r,{expression:i}=s,{type:n}=i;switch(n){case"Identifier":e(r,i.name)}},TSQualifiedName(r){let{node:s}=r,{left:i}=s,{type:n}=i;switch(n){case"Identifier":e(r,i.name)}},TSInterfaceDeclaration(r){t(r,r.node.id.name),r.findParent(Kpt)&&e(r,r.node.id.name)},TSMethodSignature(r){let s=r.get("params");for(let i of s){if(i.isIdentifier()){t(i,i.node.name),e(i,i.node.name);continue}let{type:n}=i;switch(n){case"RestElement":t(i,i.node.argument.name),e(i,i.node.argument.name);continue}}},TSDeclareFunction(r){if(!r.get("params").length)return;let[i]=r.get("params");i.isRestElement()&&e(i,i.node.argument.name)}})});var Vte=F((S2t,Ute)=>{"use strict";var{isAssignmentPattern:Rte,isClassDeclaration:Wpt,isIdentifier:Wt,isSpreadElement:Xpt,isObjectPattern:jte,isObjectExpression:zpt,isFunctionDeclaration:Hpt,isArrayExpression:Gpt,isVariableDeclaration:Ypt,isRestElement:Qpt}=Wi().types,{traverseObjectExpression:Zpt,processObjectPattern:eft,traverseArrayExpression:tft,traverseAssignmentExpression:rft,traverseTemplateLiteral:sft}=Nte(),ift=_te(),nft=Bte(),aft=Mte(),{assign:$te}=Object;Ute.exports=({use:e,declare:t,addParams:r})=>{let s=Zpt(e),i=eft({use:e,declare:t}),n=rft({use:e,declare:t}),a=sft(e),o=tft(e);return{"ObjectExpression|RecordExpression"(u){s(u.get("properties"))},SequenceExpression(u){for(let c of u.get("expressions"))c.isIdentifier()&&e(c,c.node.name)},"AwaitExpression|YieldExpression|SpreadElement"(u){let{argument:c}=u.node;Wt(c)&&e(u,c.name)},CatchClause(u){let c=u.get("param");if(!c.isIdentifier())return;let{name:p}=c.node;t(c,p),u.scope.getOwnBinding(p).referenced&&e(c,p)},Decorator(u){let c=u.get("expression");if(!c.isIdentifier())return;let{name:p}=c.node;e(c,p)},RestElement(u){let{argument:c}=u.node;Wt(c)&&t(u,c.name)},VariableDeclarator(u){let{node:c}=u,{init:p}=c,m=u.get("id"),g=u.parentPath.parentPath.isForInStatement();if(Wt(c.id))t(u,c.id.name),g&&e(u,c.id.name);else if(jte(c.id))m.traverse({ObjectProperty(h){if(Rte(h.node.value)&&n(h.get("value")),h.node.computed&&Wt(h.node.key)&&e(h.get("key"),h.node.key.name),!Wt(h.node.value))return;let{properties:b}=c.id,T=b.length===1?u:h,{name:C}=h.node.value;t(T,C),Qpt(h.parentPath.node.properties.at(-1))&&e(T,C)}});else if(m.isArrayPattern()){let h=m.get("elements");for(let b of h){if(b.isObjectPattern()){i(b.get("properties"));continue}if(b.isAssignmentPattern()){let S=b.get("left"),T=b.get("right");t(S,b.node.left.name),e(T,b.node.right.name),$te(S,{remove:qte(b)})}b.isIdentifier()&&($te(b,{remove:qte(b)}),t(b,b.node.name))}}let d=u.get("init");Wt(p)?e(u,p.name):Gpt(p)&&o(d.get("elements"))},ClassProperty(u){let c=u.get("value");c.isIdentifier()&&e(c,c.node.name)},"ClassDeclaration|ClassExpression"(u){let{node:c}=u,{id:p,superClass:m}=c;m&&e(u,m.name),p&&t(u,p.name),p&&u.isClassExpression()&&e(u,p.name)},AssignmentExpression(u){let c=u.get("left"),p=u.get("right");c.isIdentifier()&&e(c,c.node.name),p.isIdentifier()&&e(p,p.node.name)},"ArrayExpression|TupleExpression"(u){let{elements:c}=u.node;for(let p of c){if(Wt(p)){e(u,p.name);continue}if(Xpt(p)){e(u,p.argument.name);continue}}},ConditionalExpression(u){let{test:c,consequent:p,alternate:m}=u.node,g=u.get("alternate"),d=u.get("consequent");Wt(c)&&e(u,c.name),Wt(p)&&e(u,p.name),Wt(m)&&e(u,m.name),g.isFunction()&&m.id&&e(g,m.id.name),d.isFunction()&&p.id&&e(d,p.id.name)},DoWhileStatement(u){let c=u.get("test");c.isIdentifier()&&e(c,c.node.name)},TemplateLiteral(u){a(u,u.node.expressions)},LogicalExpression(u){let{left:c,right:p}=u.node;Wt(c)&&e(u,c.name),Wt(p)&&e(u,p.name)},MemberExpression(u){let{property:c,object:p,computed:m}=u.node;Wt(p)&&e(u,p.name),m&&Wt(c)&&e(u,c.name)},OptionalMemberExpression(u){let{object:c,property:p,computed:m}=u.node;Wt(c)&&e(u,c.name),m&&Wt(p)&&e(u,p.name)},NewExpression(u){let c=u.get("callee"),{node:p}=u;c.isIdentifier()?e(u,p.callee.name):c.isFunction()&&e(c,c.node.id.name);let m=u.get("arguments");for(let{node:g}of m)if(Wt(g)){e(u,g.name);continue}},TaggedTemplateExpression(u){let{tag:c}=u.node;Wt(c)&&e(u,c.name)},UnaryExpression(u){let{argument:c}=u.node;Wt(c)&&e(u,c.name)},UpdateExpression(u){let{argument:c}=u.node;Wt(c)&&e(u,c.name)},ThrowStatement(u){let{argument:c}=u.node;Wt(c)&&e(u,c.name)},IfStatement(u){let{node:c}=u,{test:p}=c;if(Wt(p))return e(u,p.name)},ForInStatement(u){let{node:c}=u,{left:p,right:m}=c;Wt(p)&&e(u,p.name),Wt(m)&&e(u,m.name)},ForOfStatement(u){let{node:c}=u,{left:p,right:m}=c;Wt(m)&&e(u,m.name),Wt(p)?e(u,p.name):u.get("left").traverse({Identifier(g){t(u,g.node.name)}}),u.get("left").traverse({Identifier(g){e(g,g.node.name)}})},ExpressionStatement(u){let{node:c}=u;Wt(c.expression)&&e(u,c.expression.name)},SwitchStatement(u){let{node:c}=u;Wt(c.discriminant)&&e(u,c.discriminant.name);for(let{test:p}of c.cases)Wt(p)&&e(u,p.name)},ReturnStatement(u){let{node:c}=u,{argument:p}=c,m=u.get("argument");if(m.isIdentifier())return e(u,p.name);if(m.isFunction()&&p.id)return e(m,p.id.name)},ObjectMethod(u){let{params:c}=u.node,p=u.get("params");for(let m of p){let{node:g}=m;if(Wt(g)){t(m,g.name);continue}}r({path:u,params:c})},"CallExpression|OptionalCallExpression"(u){let{node:c}=u,{callee:p}=c;Wt(p)&&e(u,c.callee.name),u.traverse({SpreadElement(m){let{argument:g}=m.node;Wt(g)&&e(m,g.name)},Identifier(m){c.arguments.includes(m.node)&&e(m,m.node.name)}})},BinaryExpression(u){let{left:c,right:p}=u.node;Wt(c)&&e(u,c.name),Wt(p)&&e(u,p.name)},ImportDeclaration(u){let c=u.get("specifiers");for(let p of c){let{local:m}=p.node;Wt(m)&&t(p,m.name)}},ExportDefaultDeclaration(u){let c=u.get("declaration"),{declaration:p}=u.node,{id:m}=p;m&&Hpt(p)?e(u,p.id.name):Wt(p)?e(u,p.name):m&&Wpt(p)?e(u,p.id.name):zpt(p)&&s(c.get("properties"))},ExportNamedDeclaration(u){let c=u.get("declaration"),{declaration:p,specifiers:m}=u.node;if(c.isFunctionDeclaration()||c.isClassDeclaration()||c.isTSInterfaceDeclaration()||c.isTSTypeAliasDeclaration()||c.isInterfaceDeclaration())return e(u,p.id.name);if(Ypt(p)){let{declarations:g}=p;for(let{id:d}of g)Wt(d)&&e(u,d.name);return}for(let{local:g}of m)Wt(g)&&e(u,g.name)},Function(u){let{node:c,parentPath:p}=u,{id:m,body:g,params:d}=c,h=u.get("params");m&&(t(u,c.id.name),!p.isBlock()&&!p.isProgram()&&e(u,c.id.name));for(let b of h){let{node:S}=b;if(Wt(S)){t(b,S.name);continue}if(Rte(S)){n(b);continue}if(jte(S)){i(b.get("properties"));continue}}Wt(g)&&e(u,g.name),r({path:u,params:d})},...ift(e),...nft({use:e,declare:t}),...aft({use:e,declare:t})}};var qte=e=>{let{remove:t}=e;return()=>{let r=e.node,{elements:s}=e.parentPath.node,i=s.length-1;if(s.indexOf(r)===i)return t.call(e)}}});var Wte=F((E2t,E3)=>{"use strict";var{types:oft}=Wi(),{isIdentifier:Jte,isObjectPattern:uft,isRestElement:lft}=oft;E3.exports.usePropertiesBeforeRest=({use:e})=>({path:t,params:r})=>{for(let s of r)uft(s)&&cft(e,t,s.properties)};function cft(e,t,r){let{length:s}=r,i=r.at(-1);if(lft(i))for(let n=0;n<s-1;n++){let{value:a}=r[n],{type:o}=a;switch(o){case"Identifier":e(t,a.name);continue}}}E3.exports.useParamsBeforeLastUsed=({use:e,isUsed:t})=>({path:r,params:s})=>{let i=s.length;for(;--i>0;){let n=s[i];if(pft(t,r,n))break}for(;--i>=0;)Jte(s[i])&&e(r,s[i].name);return{path:r,params:s}};var pft=(e,t,r)=>{let{type:s}=r;switch(s){case"Identifier":return e(t,r.name);case"ObjectPattern":return Kte(e,t,r);case"AssignmentPattern":return fft(e,t,r)}},fft=(e,t,r)=>{let{left:s}=r,{type:i}=s;switch(i){case"Identifier":return e(t,s.name);case"ObjectPattern":return Kte(e,t,s)}},Kte=(e,t,r)=>{for(let{value:s}of r.properties)if(Jte(s)){if(e(t,s.name))return!0;continue}return!1}});var zte=F((T2t,Xte)=>{"use strict";var{types:hft}=Wi(),dft=Vte(),{useParamsBeforeLastUsed:mft,usePropertiesBeforeRest:yft}=Wte(),{isClassDeclaration:gft,isFunctionDeclaration:xft}=hft;Xte.exports=(e,t)=>{let r={},s=[],{setPath:i,traverse:n}=t,a=vft({vars:r}),o=Tft({vars:r,setPath:i}),u=Sft({vars:r}),c=bft(s);return n(e,dft({use:a,declare:o,addParams:c})),s.map(mft({use:a,isUsed:u})).map(yft({use:a})),Object.values(r)};var bft=e=>({path:t,params:r})=>{e.push({path:t,params:r})};function T3({name:e,scope:t}){if(t.hasOwnBinding(e))return t.uid;for(;t.parent;)if(t=t.parent,t.hasOwnBinding(e))return t.uid;return t.uid}var Sft=({vars:e})=>(t,r)=>{let{scope:s}=t,i=T3({name:r,scope:s}),n=e[i],{used:a}=n[r];return a};function Eft(e){let{node:t,scope:r}=e;return xft(t)||gft(t)?e.parentPath.scope:r}var Tft=({vars:e,setPath:t})=>(r,s)=>{let i=Eft(r),n=T3({name:s,scope:i});e[n]||(e[n]={});let a=e[n];a[s]?a[s].declared=!0:a[s]={declared:!0,used:!1},t&&(a[s].path=r)},vft=({vars:e})=>(t,r)=>{let{scope:s}=t,i=T3({name:r,scope:s});e[i]||(e[i]={});let n=e[i];n[r]?n[r].used=!0:n[r]={declared:!1,used:!0}}});var Gte=F((v2t,Hte)=>{"use strict";Hte.exports=e=>{let t=[];for(let r of e){let s=Object.entries(r);for(let i of s)t.push(Aft(i))}return t};function Aft([e,t]){return{name:e,...t}}});var Qte=F((A2t,Yte)=>{"use strict";var Cft=({declared:e,used:t})=>e&&!t;Yte.exports=e=>e.filter(Cft)});var ere=F((C2t,bS)=>{"use strict";var{operator:Dft}=Wi(),Pft=zte(),wft=Gte(),Ift=Qte(),{replaceWith:kft,compare:Nft,remove:Zte}=Dft;bS.exports.report=({name:e})=>`'${e}' is defined but never used`;bS.exports.fix=({path:e})=>{if(Nft(e,"const __a = __b = __c"))return kft(e.parentPath,e.node.init);if(Fft(e))return Zte(e.parentPath);Zte(e)};bS.exports.find=(e,{traverse:t})=>{let r=Pft(e,{setPath:!0,traverse:t}),s=wft(r);return Ift(s)};function Fft({parentPath:e}){return e.isImportDeclaration()?e.node.specifiers.length===1:!1}});var kae=F(Mf=>{"use strict";Object.defineProperty(Mf,"__esModule",{value:!0});Mf.sync=Mf.isexe=void 0;var UEt=It("fs"),VEt=It("fs/promises"),JEt=async(e,t={})=>{let{ignoreErrors:r=!1}=t;try{return Iae(await(0,VEt.stat)(e),t)}catch(s){let i=s;if(r||i.code==="EACCES")return!1;throw i}};Mf.isexe=JEt;var KEt=(e,t={})=>{let{ignoreErrors:r=!1}=t;try{return Iae((0,UEt.statSync)(e),t)}catch(s){let i=s;if(r||i.code==="EACCES")return!1;throw i}};Mf.sync=KEt;var Iae=(e,t)=>e.isFile()&&WEt(e,t),WEt=(e,t)=>{let r=t.uid??process.getuid?.(),s=t.groups??process.getgroups?.()??[],i=t.gid??process.getgid?.()??s[0];if(r===void 0||i===void 0)throw new Error("cannot get uid or gid");let n=new Set([i,...s]),a=e.mode,o=e.uid,u=e.gid,c=parseInt("100",8),p=parseInt("010",8),m=parseInt("001",8),g=c|p;return!!(a&m||a&p&&n.has(u)||a&c&&o===r||a&g&&r===0)}});var Fae=F(Rf=>{"use strict";Object.defineProperty(Rf,"__esModule",{value:!0});Rf.sync=Rf.isexe=void 0;var XEt=It("fs"),zEt=It("fs/promises"),HEt=async(e,t={})=>{let{ignoreErrors:r=!1}=t;try{return Nae(await(0,zEt.stat)(e),e,t)}catch(s){let i=s;if(r||i.code==="EACCES")return!1;throw i}};Rf.isexe=HEt;var GEt=(e,t={})=>{let{ignoreErrors:r=!1}=t;try{return Nae((0,XEt.statSync)(e),e,t)}catch(s){let i=s;if(r||i.code==="EACCES")return!1;throw i}};Rf.sync=GEt;var YEt=(e,t)=>{let{pathExt:r=process.env.PATHEXT||""}=t,s=r.split(";");if(s.indexOf("")!==-1)return!0;for(let i=0;i<s.length;i++){let n=s[i].toLowerCase(),a=e.substring(e.length-n.length).toLowerCase();if(n&&a===n)return!0}return!1},Nae=(e,t,r)=>e.isFile()&&YEt(t,r)});var Oae=F(_ae=>{"use strict";Object.defineProperty(_ae,"__esModule",{value:!0})});var $ae=F(Ls=>{"use strict";var Bae=Ls&&Ls.__createBinding||(Object.create?function(e,t,r,s){s===void 0&&(s=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,s,i)}:function(e,t,r,s){s===void 0&&(s=r),e[s]=t[r]}),QEt=Ls&&Ls.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Lae=Ls&&Ls.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)r!=="default"&&Object.prototype.hasOwnProperty.call(e,r)&&Bae(t,e,r);return QEt(t,e),t},ZEt=Ls&&Ls.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&Bae(t,e,r)};Object.defineProperty(Ls,"__esModule",{value:!0});Ls.sync=Ls.isexe=Ls.posix=Ls.win32=void 0;var Mae=Lae(kae());Ls.posix=Mae;var Rae=Lae(Fae());Ls.win32=Rae;ZEt(Oae(),Ls);var e1t=process.env._ISEXE_TEST_PLATFORM_||process.platform,jae=e1t==="win32"?Rae:Mae;Ls.isexe=jae.isexe;Ls.sync=jae.sync});var Gae=F((Hkt,Hae)=>{"use strict";var{isexe:t1t,sync:r1t}=$ae(),{join:s1t,delimiter:i1t,sep:qae,posix:Uae}=It("path"),Vae=process.platform==="win32",Jae=new RegExp(`[${Uae.sep}${qae===Uae.sep?"":qae}]`.replace(/(\\)/g,"\\$1")),n1t=new RegExp(`^\\.${Jae.source}`),Kae=e=>Object.assign(new Error(`not found: ${e}`),{code:"ENOENT"}),Wae=(e,{path:t=process.env.PATH,pathExt:r=process.env.PATHEXT,delimiter:s=i1t})=>{let i=e.match(Jae)?[""]:[...Vae?[process.cwd()]:[],...(t||"").split(s)];if(Vae){let n=r||[".EXE",".CMD",".BAT",".COM"].join(s),a=n.split(s).flatMap(o=>[o,o.toLowerCase()]);return e.includes(".")&&a[0]!==""&&a.unshift(""),{pathEnv:i,pathExt:a,pathExtExe:n}}return{pathEnv:i,pathExt:[""]}},Xae=(e,t)=>{let r=/^".*"$/.test(e)?e.slice(1,-1):e;return(!r&&n1t.test(t)?t.slice(0,2):"")+s1t(r,t)},zae=async(e,t={})=>{let{pathEnv:r,pathExt:s,pathExtExe:i}=Wae(e,t),n=[];for(let a of r){let o=Xae(a,e);for(let u of s){let c=o+u;if(await t1t(c,{pathExt:i,ignoreErrors:!0})){if(!t.all)return c;n.push(c)}}}if(t.all&&n.length)return n;if(t.nothrow)return null;throw Kae(e)},a1t=(e,t={})=>{let{pathEnv:r,pathExt:s,pathExtExe:i}=Wae(e,t),n=[];for(let a of r){let o=Xae(a,e);for(let u of s){let c=o+u;if(r1t(c,{pathExt:i,ignoreErrors:!0})){if(!t.all)return c;n.push(c)}}}if(t.all&&n.length)return n;if(t.nothrow)return null;throw Kae(e)};Hae.exports=zae;zae.sync=a1t});var Foe=["framework:solid","framework:react","framework:vue","db:edgedb","db:prisma","auth:authjs","rpc:telefunc","server:hattip","server:express","server:h3","uikit:tailwindcss","analytics:plausible.io","hosting:vercel","tool:eslint"],l1t=new Map(Foe.map(e=>[e.split(":").at(-1),e]));var Yo=Pn(C_(),1);import{promises as Jpe}from"fs";var C0=Pn(GE(),1),KO=Pn(F1(),1);function yn(e){var t=e.use(ds),r=t.Type,s=t.builtInTypes,i=s.number;function n(c){return r.from(p=>i.check(p)&&p>=c,i+" >= "+c)}let a={null:function(){return null},emptyArray:function(){return[]},false:function(){return!1},true:function(){return!0},undefined:function(){},"use strict":function(){return"use strict"}};var o=r.or(s.string,s.number,s.boolean,s.null,s.undefined);let u=r.from(c=>{if(c===null)return!0;var p=typeof c;return!(p==="object"||p==="function")},o.toString());return{geq:n,defaults:a,isPrimitive:u}}function Lr(e){try{var t=e(),r=t.exports,s=r.default}catch{return}s&&s!==r&&typeof r=="object"&&(Object.assign(s,r,{default:s}),r.__esModule&&Object.defineProperty(s,"__esModule",{value:!0}),t.exports=s)}var Kpe=Object.defineProperty,Wpe=(e,t,r)=>t in e?Kpe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,vi=(e,t,r)=>(Wpe(e,typeof t!="symbol"?t+"":t,r),r),WO=Object.prototype,x0=WO.toString,kn=WO.hasOwnProperty,fl=class{assert(t,r){if(!this.check(t,r)){var s=K1(t);throw new Error(s+" does not match type "+this)}return!0}arrayOf(){let t=this;return new gh(t)}},gh=class extends fl{constructor(t){super(),this.elemType=t,vi(this,"kind","ArrayType")}toString(){return"["+this.elemType+"]"}check(t,r){return Array.isArray(t)&&t.every(s=>this.elemType.check(s,r))}},b0=class extends fl{constructor(t){super(),this.value=t,vi(this,"kind","IdentityType")}toString(){return String(this.value)}check(t,r){let s=t===this.value;return!s&&typeof r=="function"&&r(this,t),s}},S0=class extends fl{constructor(t){super(),this.fields=t,vi(this,"kind","ObjectType")}toString(){return"{ "+this.fields.join(", ")+" }"}check(t,r){return x0.call(t)===x0.call({})&&this.fields.every(s=>s.type.check(t[s.name],r))}},E0=class extends fl{constructor(t){super(),this.types=t,vi(this,"kind","OrType")}toString(){return this.types.join(" | ")}check(t,r){return this.types.some(s=>s.check(t,!!r))?!0:(typeof r=="function"&&r(this,t),!1)}},pl=class extends fl{constructor(t,r){super(),this.name=t,this.predicate=r,vi(this,"kind","PredicateType")}toString(){return this.name}check(t,r){let s=this.predicate(t,r);return!s&&typeof r=="function"&&r(this,t),s}},mh=class e{constructor(t,r){this.type=t,this.typeName=r,vi(this,"baseNames",[]),vi(this,"ownFields",Object.create(null)),vi(this,"allSupertypes",Object.create(null)),vi(this,"supertypeList",[]),vi(this,"allFields",Object.create(null)),vi(this,"fieldNames",[]),vi(this,"finalized",!1),vi(this,"buildable",!1),vi(this,"buildParams",[])}isSupertypeOf(t){if(t instanceof e){if(this.finalized!==!0||t.finalized!==!0)throw new Error("");return kn.call(t.allSupertypes,this.typeName)}else throw new Error(t+" is not a Def")}checkAllFields(t,r){var s=this.allFields;if(this.finalized!==!0)throw new Error(""+this.typeName);function i(n){var a=s[n],o=a.type,u=a.getValue(t);return o.check(u,r)}return t!==null&&typeof t=="object"&&Object.keys(s).every(i)}bases(...t){var r=this.baseNames;if(this.finalized){if(t.length!==r.length)throw new Error("");for(var s=0;s<t.length;s++)if(t[s]!==r[s])throw new Error("");return this}return t.forEach(i=>{r.indexOf(i)<0&&r.push(i)}),this}},T0=class{constructor(t,r,s,i){this.name=t,this.type=r,this.defaultFn=s,vi(this,"hidden"),this.hidden=!!i}toString(){return JSON.stringify(this.name)+": "+this.type}getValue(t){var r=t[this.name];return typeof r<"u"||typeof this.defaultFn=="function"&&(r=this.defaultFn.call(t)),r}};function K1(e){return Array.isArray(e)?"["+e.map(K1).join(", ")+"]":e&&typeof e=="object"?"{ "+Object.keys(e).map(function(t){return t+": "+e[t]}).join(", ")+" }":JSON.stringify(e)}function ds(e){let t={or(...J){return new E0(J.map(q=>t.from(q)))},from(J,q){if(J instanceof gh||J instanceof b0||J instanceof S0||J instanceof E0||J instanceof pl)return J;if(J instanceof mh)return J.type;if(o.check(J)){if(J.length!==1)throw new Error("only one element type is permitted for typed arrays");return new gh(t.from(J[0]))}if(u.check(J))return new S0(Object.keys(J).map(de=>new T0(de,t.from(J[de],de))));if(typeof J=="function"){var Q=r.indexOf(J);if(Q>=0)return s[Q];if(typeof q!="string")throw new Error("missing name");return new pl(q,J)}return new b0(J)},def(J){return kn.call(T,J)?T[J]:T[J]=new A(J)},hasDef(J){return kn.call(T,J)}};var r=[],s=[];function i(J,q){let Q=x0.call(q),de=new pl(J,ve=>x0.call(ve)===Q);return q&&typeof q.constructor=="function"&&(r.push(q.constructor),s.push(de)),de}let n=i("string","truthy"),a=i("function",function(){}),o=i("array",[]),u=i("object",{}),c=i("RegExp",/./),p=i("Date",new Date),m=i("number",3),g=i("boolean",!0),d=i("null",null),h=i("undefined",void 0),b=typeof BigInt=="function"?i("BigInt",BigInt(1234)):new pl("BigInt",()=>!1),S={string:n,function:a,array:o,object:u,RegExp:c,Date:p,number:m,boolean:g,null:d,undefined:h,BigInt:b};var T=Object.create(null);function C(J){if(J&&typeof J=="object"){var q=J.type;if(typeof q=="string"&&kn.call(T,q)){var Q=T[q];if(Q.finalized)return Q}}return null}class A extends mh{constructor(q){super(new pl(q,(Q,de)=>this.check(Q,de)),q)}check(q,Q){if(this.finalized!==!0)throw new Error("prematurely checking unfinalized type "+this.typeName);if(q===null||typeof q!="object")return!1;var de=C(q);return de?Q&&de===this?this.checkAllFields(q,Q):this.isSupertypeOf(de)?Q?de.checkAllFields(q,Q)&&this.checkAllFields(q,!1):!0:!1:this.typeName==="SourceLocation"||this.typeName==="Position"?this.checkAllFields(q,Q):!1}build(...q){if(this.buildParams=q,this.buildable)return this;this.field("type",String,()=>this.typeName),this.buildable=!0;let Q=(ve,we,Se,fe)=>{if(!kn.call(ve,we)){var _e=this.allFields;if(!kn.call(_e,we))throw new Error(""+we);var re=_e[we],ie=re.type,se;if(fe)se=Se;else if(re.defaultFn)se=re.defaultFn.call(ve);else{var ye="no value or default function given for field "+JSON.stringify(we)+" of "+this.typeName+"("+this.buildParams.map(function($e){return _e[$e]}).join(", ")+")";throw new Error(ye)}if(!ie.check(se))throw new Error(K1(se)+" does not match field "+re+" of type "+this.typeName);ve[we]=se}},de=(...ve)=>{var we=ve.length;if(!this.finalized)throw new Error("attempting to instantiate unfinalized type "+this.typeName);var Se=Object.create(_);if(this.buildParams.forEach(function(fe,_e){_e<we?Q(Se,fe,ve[_e],!0):Q(Se,fe,null,!1)}),Object.keys(this.allFields).forEach(function(fe){Q(Se,fe,null,!1)}),Se.type!==this.typeName)throw new Error("");return Se};return de.from=ve=>{if(!this.finalized)throw new Error("attempting to instantiate unfinalized type "+this.typeName);var we=Object.create(_);if(Object.keys(this.allFields).forEach(function(Se){kn.call(ve,Se)?Q(we,Se,ve[Se],!0):Q(we,Se,null,!1)}),we.type!==this.typeName)throw new Error("");return we},Object.defineProperty(I,$(this.typeName),{enumerable:!0,value:de}),this}field(q,Q,de,ve){return this.finalized?(console.error("Ignoring attempt to redefine field "+JSON.stringify(q)+" of finalized type "+JSON.stringify(this.typeName)),this):(this.ownFields[q]=new T0(q,t.from(Q),de,ve),this)}finalize(){if(!this.finalized){var q=this.allFields,Q=this.allSupertypes;this.baseNames.forEach(ve=>{var we=T[ve];if(we instanceof mh)we.finalize(),Ie(q,we.allFields),Ie(Q,we.allSupertypes);else{var Se="unknown supertype name "+JSON.stringify(ve)+" for subtype "+JSON.stringify(this.typeName);throw new Error(Se)}}),Ie(q,this.ownFields),Q[this.typeName]=this,this.fieldNames.length=0;for(var de in q)kn.call(q,de)&&!q[de].hidden&&this.fieldNames.push(de);Object.defineProperty(M,this.typeName,{enumerable:!0,value:this.type}),this.finalized=!0,Be(this.typeName,this.supertypeList),this.buildable&&this.supertypeList.lastIndexOf("Expression")>=0&&ae(this.typeName)}}}function v(J){if(!kn.call(T,J))throw new Error("");var q=T[J];if(q.finalized!==!0)throw new Error("");return q.supertypeList.slice(1)}function w(J){for(var q={},Q=Object.keys(T),de=Q.length,ve=0;ve<de;++ve){var we=Q[ve],Se=T[we];if(Se.finalized!==!0)throw new Error(""+we);for(var fe=0;fe<Se.supertypeList.length;++fe){var _e=Se.supertypeList[fe];if(kn.call(J,_e)){q[we]=_e;break}}}return q}var I=Object.create(null),_={};function L(J,q){var Q=_[J];return h.check(q)?delete _[J]:(a.assert(q),Object.defineProperty(_,J,{enumerable:!0,configurable:!0,value:q})),Q}function $(J){return J.replace(/^[A-Z]+/,function(q){var Q=q.length;switch(Q){case 0:return"";case 1:return q.toLowerCase();default:return q.slice(0,Q-1).toLowerCase()+q.charAt(Q-1)}})}function G(J){return J=$(J),J.replace(/(Expression)?$/,"Statement")}var M={};function Ee(J){var q=C(J);if(q)return q.fieldNames.slice(0);if("type"in J)throw new Error("did not recognize object of type "+JSON.stringify(J.type));return Object.keys(J)}function Fe(J,q){var Q=C(J);if(Q){var de=Q.allFields[q];if(de)return de.getValue(J)}return J&&J[q]}function De(J,q,Q){Ee(J).forEach(function(de){q.call(this,de,Fe(J,de))},Q)}function ue(J,q,Q){return Ee(J).some(function(de){return q.call(this,de,Fe(J,de))},Q)}function ae(J){var q=G(J);if(I[q])return;var Q=I[$(J)];if(!Q)return;let de=function(...ve){return I.expressionStatement(Q.apply(I,ve))};de.from=function(...ve){return I.expressionStatement(Q.from.apply(I,ve))},I[q]=de}function Be(J,q){q.length=0,q.push(J);for(var Q=Object.create(null),de=0;de<q.length;++de){J=q[de];var ve=T[J];if(ve.finalized!==!0)throw new Error("");kn.call(Q,J)&&delete q[Q[J]],Q[J]=de,q.push.apply(q,ve.baseNames)}for(var we=0,Se=we,fe=q.length;Se<fe;++Se)kn.call(q,Se)&&(q[we++]=q[Se]);q.length=we}function Ie(J,q){return Object.keys(q).forEach(function(Q){J[Q]=q[Q]}),J}function me(){Object.keys(T).forEach(function(J){T[J].finalize()})}return{Type:t,builtInTypes:S,getSupertypeNames:v,computeSupertypeLookupTable:w,builders:I,defineMethod:L,getBuilderName:$,getStatementBuilderName:G,namedTypes:M,getFieldNames:Ee,getFieldValue:Fe,eachField:De,someField:ue,finalize:me}}Lr(()=>module);var Xpe=Object.prototype,l0=Xpe.hasOwnProperty;function XO(e){var t=e.use(ds),r=t.builtInTypes.array,s=t.builtInTypes.number;let i=function m(g,d,h){if(!(this instanceof m))throw new Error("Path constructor cannot be invoked without 'new'");if(d){if(!(d instanceof m))throw new Error("")}else d=null,h=null;this.value=g,this.parentPath=d,this.name=h,this.__childCache=null};var n=i.prototype;function a(m){return m.__childCache||(m.__childCache=Object.create(null))}function o(m,g){var d=a(m),h=m.getValueProperty(g),b=d[g];return(!l0.call(d,g)||b.value!==h)&&(b=d[g]=new m.constructor(h,m,g)),b}n.getValueProperty=function(g){return this.value[g]},n.get=function(...g){for(var d=this,h=g.length,b=0;b<h;++b)d=o(d,g[b]);return d},n.each=function(g,d){for(var h=[],b=this.value.length,S=0,S=0;S<b;++S)l0.call(this.value,S)&&(h[S]=this.get(S));for(d=d||this,S=0;S<b;++S)l0.call(h,S)&&g.call(d,h[S])},n.map=function(g,d){var h=[];return this.each(function(b){h.push(g.call(this,b))},d),h},n.filter=function(g,d){var h=[];return this.each(function(b){g.call(this,b)&&h.push(b)},d),h};function u(){}function c(m,g,d,h){if(r.assert(m.value),g===0)return u;var b=m.value.length;if(b<1)return u;var S=arguments.length;S===2?(d=0,h=b):S===3?(d=Math.max(d,0),h=b):(d=Math.max(d,0),h=Math.min(h,b)),s.assert(d),s.assert(h);for(var T=Object.create(null),C=a(m),A=d;A<h;++A)if(l0.call(m.value,A)){var v=m.get(A);if(v.name!==A)throw new Error("");var w=A+g;v.name=w,T[w]=v,delete C[A]}return delete C.length,function(){for(var I in T){var _=T[I];if(_.name!==+I)throw new Error("");C[I]=_,m.value[I]=_.value}}}n.shift=function(){var g=c(this,-1),d=this.value.shift();return g(),d},n.unshift=function(...g){var d=c(this,g.length),h=this.value.unshift.apply(this.value,g);return d(),h},n.push=function(...g){return r.assert(this.value),delete a(this).length,this.value.push.apply(this.value,g)},n.pop=function(){r.assert(this.value);var g=a(this);return delete g[this.value.length-1],delete g.length,this.value.pop()},n.insertAt=function(g){var d=arguments.length,h=c(this,d-1,g);if(h===u&&d<=1)return this;g=Math.max(g,0);for(var b=1;b<d;++b)this.value[g+b-1]=arguments[b];return h(),this},n.insertBefore=function(...g){for(var d=this.parentPath,h=g.length,b=[this.name],S=0;S<h;++S)b.push(g[S]);return d.insertAt.apply(d,b)},n.insertAfter=function(...g){for(var d=this.parentPath,h=g.length,b=[this.name+1],S=0;S<h;++S)b.push(g[S]);return d.insertAt.apply(d,b)};function p(m){if(!(m instanceof i))throw new Error("");var g=m.parentPath;if(!g)return m;var d=g.value,h=a(g);if(d[m.name]===m.value)h[m.name]=m;else if(r.check(d)){var b=d.indexOf(m.value);b>=0&&(h[m.name=b]=m)}else d[m.name]=m.value,h[m.name]=m;if(d[m.name]!==m.value)throw new Error("");if(m.parentPath.get(m.name)!==m)throw new Error("");return m}return n.replace=function(g){var d=[],h=this.parentPath.value,b=a(this.parentPath),S=arguments.length;if(p(this),r.check(h)){for(var T=h.length,C=c(this.parentPath,S-1,this.name+1),A=[this.name,1],v=0;v<S;++v)A.push(arguments[v]);var w=h.splice.apply(h,A);if(w[0]!==this.value)throw new Error("");if(h.length!==T-1+S)throw new Error("");if(C(),S===0)delete this.value,delete b[this.name],this.__childCache=null;else{if(h[this.name]!==g)throw new Error("");for(this.value!==g&&(this.value=g,this.__childCache=null),v=0;v<S;++v)d.push(this.parentPath.get(this.name+v));if(d[0]!==this)throw new Error("")}}else if(S===1)this.value!==g&&(this.__childCache=null),this.value=h[this.name]=g,d.push(this);else if(S===0)delete h[this.name],delete this.value,this.__childCache=null;else throw new Error("Could not replace path");return d},i}Lr(()=>module);var jc=Object.prototype.hasOwnProperty;function zpe(e){var t=e.use(ds),r=t.Type,s=t.namedTypes,i=s.Node,n=s.Expression,a=t.builtInTypes.array,o=t.builders;let u=function v(w,I){if(!(this instanceof v))throw new Error("Scope constructor cannot be invoked without 'new'");p.check(w.value)||c.assert(w.value);var _;if(I){if(!(I instanceof v))throw new Error("");_=I.depth+1}else I=null,_=0;Object.defineProperties(this,{path:{value:w},node:{value:w.value},isGlobal:{value:!I,enumerable:!0},depth:{value:_},parent:{value:I},bindings:{value:{}},types:{value:{}}})};var c=r.or(s.Program,s.Function,s.CatchClause),p=r.or(s.Function,s.ClassDeclaration,s.ClassExpression,s.InterfaceDeclaration,s.TSInterfaceDeclaration,s.TypeAlias,s.TSTypeAliasDeclaration),m=r.or(s.TypeParameter,s.TSTypeParameter);u.isEstablishedBy=function(v){return c.check(v)||p.check(v)};var g=u.prototype;g.didScan=!1,g.declares=function(v){return this.scan(),jc.call(this.bindings,v)},g.declaresType=function(v){return this.scan(),jc.call(this.types,v)},g.declareTemporary=function(v){if(v){if(!/^[a-z$_]/i.test(v))throw new Error("")}else v="t$";v+=this.depth.toString(36)+"$",this.scan();for(var w=0;this.declares(v+w);)++w;var I=v+w;return this.bindings[I]=t.builders.identifier(I)},g.injectTemporary=function(v,w){v||(v=this.declareTemporary());var I=this.path.get("body");return s.BlockStatement.check(I.value)&&(I=I.get("body")),I.unshift(o.variableDeclaration("var",[o.variableDeclarator(v,w||null)])),v},g.scan=function(v){if(v||!this.didScan){for(var w in this.bindings)delete this.bindings[w];for(var w in this.types)delete this.types[w];d(this.path,this.bindings,this.types),this.didScan=!0}},g.getBindings=function(){return this.scan(),this.bindings},g.getTypes=function(){return this.scan(),this.types};function d(v,w,I){var _=v.value;if(p.check(_)){let L=v.get("typeParameters","params");a.check(L.value)&&L.each($=>{A($,I)})}c.check(_)&&(s.CatchClause.check(_)?T(v.get("param"),w):h(v,w,I))}function h(v,w,I){var _=v.value;v.parent&&s.FunctionExpression.check(v.parent.node)&&v.parent.node.id&&T(v.parent.get("id"),w),_&&(a.check(_)?v.each(L=>{S(L,w,I)}):s.Function.check(_)?(v.get("params").each(L=>{T(L,w)}),S(v.get("body"),w,I),h(v.get("typeParameters"),w,I)):s.TypeAlias&&s.TypeAlias.check(_)||s.InterfaceDeclaration&&s.InterfaceDeclaration.check(_)||s.TSTypeAliasDeclaration&&s.TSTypeAliasDeclaration.check(_)||s.TSInterfaceDeclaration&&s.TSInterfaceDeclaration.check(_)?C(v.get("id"),I):s.VariableDeclarator.check(_)?(T(v.get("id"),w),S(v.get("init"),w,I)):_.type==="ImportSpecifier"||_.type==="ImportNamespaceSpecifier"||_.type==="ImportDefaultSpecifier"?T(v.get(_.local?"local":_.name?"name":"id"),w):i.check(_)&&!n.check(_)&&t.eachField(_,function(L,$){var G=v.get(L);if(!b(G,$))throw new Error("");S(G,w,I)}))}function b(v,w){return!!(v.value===w||Array.isArray(v.value)&&v.value.length===0&&Array.isArray(w)&&w.length===0)}function S(v,w,I){var _=v.value;if(!(!_||n.check(_)))if(s.FunctionDeclaration.check(_)&&_.id!==null)T(v.get("id"),w);else if(s.ClassDeclaration&&s.ClassDeclaration.check(_)&&_.id!==null)T(v.get("id"),w),h(v.get("typeParameters"),w,I);else if(s.InterfaceDeclaration&&s.InterfaceDeclaration.check(_)||s.TSInterfaceDeclaration&&s.TSInterfaceDeclaration.check(_))C(v.get("id"),I);else if(c.check(_)){if(s.CatchClause.check(_)&&s.Identifier.check(_.param)){var L=_.param.name,$=jc.call(w,L);h(v.get("body"),w,I),$||delete w[L]}}else h(v,w,I)}function T(v,w){var I=v.value;s.Pattern.assert(I),s.Identifier.check(I)?jc.call(w,I.name)?w[I.name].push(v):w[I.name]=[v]:s.AssignmentPattern&&s.AssignmentPattern.check(I)?T(v.get("left"),w):s.ObjectPattern&&s.ObjectPattern.check(I)?v.get("properties").each(function(_){var L=_.value;s.Pattern.check(L)?T(_,w):s.Property.check(L)||s.ObjectProperty&&s.ObjectProperty.check(L)?T(_.get("value"),w):s.SpreadProperty&&s.SpreadProperty.check(L)&&T(_.get("argument"),w)}):s.ArrayPattern&&s.ArrayPattern.check(I)?v.get("elements").each(function(_){var L=_.value;s.Pattern.check(L)?T(_,w):s.SpreadElement&&s.SpreadElement.check(L)&&T(_.get("argument"),w)}):s.PropertyPattern&&s.PropertyPattern.check(I)?T(v.get("pattern"),w):(s.SpreadElementPattern&&s.SpreadElementPattern.check(I)||s.RestElement&&s.RestElement.check(I)||s.SpreadPropertyPattern&&s.SpreadPropertyPattern.check(I))&&T(v.get("argument"),w)}function C(v,w){var I=v.value;s.Pattern.assert(I),s.Identifier.check(I)&&(jc.call(w,I.name)?w[I.name].push(v):w[I.name]=[v])}function A(v,w){var I=v.value;m.assert(I),jc.call(w,I.name)?w[I.name].push(v):w[I.name]=[v]}return g.lookup=function(v){for(var w=this;w&&!w.declares(v);w=w.parent);return w},g.lookupType=function(v){for(var w=this;w&&!w.declaresType(v);w=w.parent);return w},g.getGlobalScope=function(){for(var v=this;!v.isGlobal;)v=v.parent;return v},u}Lr(()=>module);function zO(e){var t=e.use(ds),r=t.namedTypes,s=t.builders,i=t.builtInTypes.number,n=t.builtInTypes.array,a=e.use(XO),o=e.use(zpe);let u=function S(T,C,A){if(!(this instanceof S))throw new Error("NodePath constructor cannot be invoked without 'new'");a.call(this,T,C,A)};var c=u.prototype=Object.create(a.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}});Object.defineProperties(c,{node:{get:function(){return Object.defineProperty(this,"node",{configurable:!0,value:this._computeNode()}),this.node}},parent:{get:function(){return Object.defineProperty(this,"parent",{configurable:!0,value:this._computeParent()}),this.parent}},scope:{get:function(){return Object.defineProperty(this,"scope",{configurable:!0,value:this._computeScope()}),this.scope}}}),c.replace=function(){return delete this.node,delete this.parent,delete this.scope,a.prototype.replace.apply(this,arguments)},c.prune=function(){var S=this.parent;return this.replace(),h(S)},c._computeNode=function(){var S=this.value;if(r.Node.check(S))return S;var T=this.parentPath;return T&&T.node||null},c._computeParent=function(){var S=this.value,T=this.parentPath;if(!r.Node.check(S)){for(;T&&!r.Node.check(T.value);)T=T.parentPath;T&&(T=T.parentPath)}for(;T&&!r.Node.check(T.value);)T=T.parentPath;return T||null},c._computeScope=function(){var S=this.value,T=this.parentPath,C=T&&T.scope;return r.Node.check(S)&&o.isEstablishedBy(S)&&(C=new o(this,C)),C||null},c.getValueProperty=function(S){return t.getFieldValue(this.value,S)},c.needsParens=function(S){var T=this.parentPath;if(!T)return!1;var C=this.value;if(!r.Expression.check(C)||C.type==="Identifier")return!1;for(;!r.Node.check(T.value);)if(T=T.parentPath,!T)return!1;var A=T.value;switch(C.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return A.type==="MemberExpression"&&this.name==="object"&&A.object===C;case"BinaryExpression":case"LogicalExpression":switch(A.type){case"CallExpression":return this.name==="callee"&&A.callee===C;case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return!0;case"MemberExpression":return this.name==="object"&&A.object===C;case"BinaryExpression":case"LogicalExpression":{let v=C,w=A.operator,I=m[w],_=v.operator,L=m[_];if(I>L)return!0;if(I===L&&this.name==="right"){if(A.right!==v)throw new Error("Nodes must be equal");return!0}}default:return!1}case"SequenceExpression":switch(A.type){case"ForStatement":return!1;case"ExpressionStatement":return this.name!=="expression";default:return!0}case"YieldExpression":switch(A.type){case"BinaryExpression":case"LogicalExpression":case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"CallExpression":case"MemberExpression":case"NewExpression":case"ConditionalExpression":case"YieldExpression":return!0;default:return!1}case"Literal":return A.type==="MemberExpression"&&i.check(C.value)&&this.name==="object"&&A.object===C;case"AssignmentExpression":case"ConditionalExpression":switch(A.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"BinaryExpression":case"LogicalExpression":return!0;case"CallExpression":return this.name==="callee"&&A.callee===C;case"ConditionalExpression":return this.name==="test"&&A.test===C;case"MemberExpression":return this.name==="object"&&A.object===C;default:return!1}default:if(A.type==="NewExpression"&&this.name==="callee"&&A.callee===C)return g(C)}return!!(S!==!0&&!this.canBeFirstInStatement()&&this.firstInStatement())};function p(S){return r.BinaryExpression.check(S)||r.LogicalExpression.check(S)}var m={};[["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"]].forEach(function(S,T){S.forEach(function(C){m[C]=T})});function g(S){return r.CallExpression.check(S)?!0:n.check(S)?S.some(g):r.Node.check(S)?t.someField(S,function(T,C){return g(C)}):!1}c.canBeFirstInStatement=function(){var S=this.node;return!r.FunctionExpression.check(S)&&!r.ObjectExpression.check(S)},c.firstInStatement=function(){return d(this)};function d(S){for(var T,C;S.parent;S=S.parent){if(T=S.node,C=S.parent.node,r.BlockStatement.check(C)&&S.parent.name==="body"&&S.name===0){if(C.body[0]!==T)throw new Error("Nodes must be equal");return!0}if(r.ExpressionStatement.check(C)&&S.name==="expression"){if(C.expression!==T)throw new Error("Nodes must be equal");return!0}if(r.SequenceExpression.check(C)&&S.parent.name==="expressions"&&S.name===0){if(C.expressions[0]!==T)throw new Error("Nodes must be equal");continue}if(r.CallExpression.check(C)&&S.name==="callee"){if(C.callee!==T)throw new Error("Nodes must be equal");continue}if(r.MemberExpression.check(C)&&S.name==="object"){if(C.object!==T)throw new Error("Nodes must be equal");continue}if(r.ConditionalExpression.check(C)&&S.name==="test"){if(C.test!==T)throw new Error("Nodes must be equal");continue}if(p(C)&&S.name==="left"){if(C.left!==T)throw new Error("Nodes must be equal");continue}if(r.UnaryExpression.check(C)&&!C.prefix&&S.name==="argument"){if(C.argument!==T)throw new Error("Nodes must be equal");continue}return!1}return!0}function h(S){if(r.VariableDeclaration.check(S.node)){var T=S.get("declarations").value;if(!T||T.length===0)return S.prune()}else if(r.ExpressionStatement.check(S.node)){if(!S.get("expression").value)return S.prune()}else r.IfStatement.check(S.node)&&b(S);return S}function b(S){var T=S.get("test").value,C=S.get("alternate").value,A=S.get("consequent").value;if(!A&&!C){var v=s.expressionStatement(T);S.replace(v)}else if(!A&&C){var w=s.unaryExpression("!",T,!0);r.UnaryExpression.check(T)&&T.operator==="!"&&(w=T.argument),S.get("test").replace(w),S.get("consequent").replace(C),S.get("alternate").replace()}}return u}Lr(()=>module);var c0=Object.prototype.hasOwnProperty;function Hpe(e){var t=e.use(ds),r=e.use(zO),s=t.builtInTypes.array,i=t.builtInTypes.object,n=t.builtInTypes.function,a;let o=function h(){if(!(this instanceof h))throw new Error("PathVisitor constructor cannot be invoked without 'new'");this._reusableContextStack=[],this._methodNameTable=u(this),this._shouldVisitComments=c0.call(this._methodNameTable,"Block")||c0.call(this._methodNameTable,"Line"),this.Context=g(this),this._visiting=!1,this._changeReported=!1};function u(h){var b=Object.create(null);for(var S in h)/^visit[A-Z]/.test(S)&&(b[S.slice(5)]=!0);for(var T=t.computeSupertypeLookupTable(b),C=Object.create(null),A=Object.keys(T),v=A.length,w=0;w<v;++w){var I=A[w];S="visit"+T[I],n.check(h[S])&&(C[I]=S)}return C}o.fromMethodsObject=function(b){if(b instanceof o)return b;if(!i.check(b))return new o;let S=function C(){if(!(this instanceof C))throw new Error("Visitor constructor cannot be invoked without 'new'");o.call(this)};var T=S.prototype=Object.create(p);return T.constructor=S,c(T,b),c(S,o),n.assert(S.fromMethodsObject),n.assert(S.visit),new S};function c(h,b){for(var S in b)c0.call(b,S)&&(h[S]=b[S]);return h}o.visit=function(b,S){return o.fromMethodsObject(S).visit(b)};var p=o.prototype;p.visit=function(){if(this._visiting)throw new Error("Recursively calling visitor.visit(path) resets visitor state. Try this.visit(path) or this.traverse(path) instead.");this._visiting=!0,this._changeReported=!1,this._abortRequested=!1;for(var h=arguments.length,b=new Array(h),S=0;S<h;++S)b[S]=arguments[S];b[0]instanceof r||(b[0]=new r({root:b[0]}).get("root")),this.reset.apply(this,b);var T;try{var C=this.visitWithoutReset(b[0]);T=!0}finally{if(this._visiting=!1,!T&&this._abortRequested)return b[0].value}return C},p.AbortRequest=function(){},p.abort=function(){var h=this;h._abortRequested=!0;var b=new h.AbortRequest;throw b.cancel=function(){h._abortRequested=!1},b},p.reset=function(h){},p.visitWithoutReset=function(h){if(this instanceof this.Context)return this.visitor.visitWithoutReset(h);if(!(h instanceof r))throw new Error("");var b=h.value,S=b&&typeof b=="object"&&typeof b.type=="string"&&this._methodNameTable[b.type];if(S){var T=this.acquireContext(h);try{return T.invokeVisitorMethod(S)}finally{this.releaseContext(T)}}else return m(h,this)};function m(h,b){if(!(h instanceof r))throw new Error("");if(!(b instanceof o))throw new Error("");var S=h.value;if(s.check(S))h.each(b.visitWithoutReset,b);else if(i.check(S)){var T=t.getFieldNames(S);b._shouldVisitComments&&S.comments&&T.indexOf("comments")<0&&T.push("comments");for(var C=T.length,A=[],v=0;v<C;++v){var w=T[v];c0.call(S,w)||(S[w]=t.getFieldValue(S,w)),A.push(h.get(w))}for(var v=0;v<C;++v)b.visitWithoutReset(A[v])}return h.value}p.acquireContext=function(h){return this._reusableContextStack.length===0?new this.Context(h):this._reusableContextStack.pop().reset(h)},p.releaseContext=function(h){if(!(h instanceof this.Context))throw new Error("");this._reusableContextStack.push(h),h.currentPath=null},p.reportChanged=function(){this._changeReported=!0},p.wasChangeReported=function(){return this._changeReported};function g(h){function b(T){if(!(this instanceof b))throw new Error("");if(!(this instanceof o))throw new Error("");if(!(T instanceof r))throw new Error("");Object.defineProperty(this,"visitor",{value:h,writable:!1,enumerable:!0,configurable:!1}),this.currentPath=T,this.needToCallTraverse=!0,Object.seal(this)}if(!(h instanceof o))throw new Error("");var S=b.prototype=Object.create(h);return S.constructor=b,c(S,d),b}var d=Object.create(null);return d.reset=function(b){if(!(this instanceof this.Context))throw new Error("");if(!(b instanceof r))throw new Error("");return this.currentPath=b,this.needToCallTraverse=!0,this},d.invokeVisitorMethod=function(b){if(!(this instanceof this.Context))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");var S=this.visitor[b].call(this,this.currentPath);if(S===!1?this.needToCallTraverse=!1:S!==a&&(this.currentPath=this.currentPath.replace(S)[0],this.needToCallTraverse&&this.traverse(this.currentPath)),this.needToCallTraverse!==!1)throw new Error("Must either call this.traverse or return false in "+b);var T=this.currentPath;return T&&T.value},d.traverse=function(b,S){if(!(this instanceof this.Context))throw new Error("");if(!(b instanceof r))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");return this.needToCallTraverse=!1,m(b,o.fromMethodsObject(S||this.visitor))},d.visit=function(b,S){if(!(this instanceof this.Context))throw new Error("");if(!(b instanceof r))throw new Error("");if(!(this.currentPath instanceof r))throw new Error("");return this.needToCallTraverse=!1,o.fromMethodsObject(S||this.visitor).visitWithoutReset(b)},d.reportChanged=function(){this.visitor.reportChanged()},d.abort=function(){this.needToCallTraverse=!1,this.visitor.abort()},o}Lr(()=>module);function Gpe(e){var t=e.use(ds),r=t.getFieldNames,s=t.getFieldValue,i=t.builtInTypes.array,n=t.builtInTypes.object,a=t.builtInTypes.Date,o=t.builtInTypes.RegExp,u=Object.prototype.hasOwnProperty;function c(h,b,S){return i.check(S)?S.length=0:S=null,m(h,b,S)}c.assert=function(h,b){var S=[];if(!c(h,b,S))if(S.length===0){if(h!==b)throw new Error("Nodes must be equal")}else throw new Error("Nodes differ in the following path: "+S.map(p).join(""))};function p(h){return/[_$a-z][_$a-z0-9]*/i.test(h)?"."+h:"["+JSON.stringify(h)+"]"}function m(h,b,S){return h===b?!0:i.check(h)?g(h,b,S):n.check(h)?d(h,b,S):a.check(h)?a.check(b)&&+h==+b:o.check(h)?o.check(b)&&h.source===b.source&&h.global===b.global&&h.multiline===b.multiline&&h.ignoreCase===b.ignoreCase:h==b}function g(h,b,S){i.assert(h);var T=h.length;if(!i.check(b)||b.length!==T)return S&&S.push("length"),!1;for(var C=0;C<T;++C){if(S&&S.push(C),C in h!=C in b||!m(h[C],b[C],S))return!1;if(S){var A=S.pop();if(A!==C)throw new Error(""+A)}}return!0}function d(h,b,S){if(n.assert(h),!n.check(b))return!1;if(h.type!==b.type)return S&&S.push("type"),!1;var T=r(h),C=T.length,A=r(b),v=A.length;if(C===v){for(var w=0;w<C;++w){var I=T[w],_=s(h,I),L=s(b,I);if(S&&S.push(I),!m(_,L,S))return!1;if(S){var $=S.pop();if($!==I)throw new Error(""+$)}}return!0}if(!S)return!1;var G=Object.create(null);for(w=0;w<C;++w)G[T[w]]=!0;for(w=0;w<v;++w){if(I=A[w],!u.call(G,I))return S.push(I),!1;delete G[I]}for(I in G){S.push(I);break}return!1}return c}Lr(()=>module);function Ype(e){let t=Qpe(),r=t.use(ds);e.forEach(t.use),r.finalize();let s=t.use(Hpe);return{Type:r.Type,builtInTypes:r.builtInTypes,namedTypes:r.namedTypes,builders:r.builders,defineMethod:r.defineMethod,getFieldNames:r.getFieldNames,getFieldValue:r.getFieldValue,eachField:r.eachField,someField:r.someField,getSupertypeNames:r.getSupertypeNames,getBuilderName:r.getBuilderName,astNodesAreEquivalent:t.use(Gpe),finalize:r.finalize,Path:t.use(XO),NodePath:t.use(zO),PathVisitor:s,use:t.use,visit:s.visit}}function Qpe(){let e=[],t=[];function r(i){var n=e.indexOf(i);return n===-1&&(n=e.length,e.push(i),t[n]=i(s)),t[n]}var s={use:r};return s}Lr(()=>module);function HO(){return{BinaryOperators:["==","!=","===","!==","<","<=",">",">=","<<",">>",">>>","+","-","*","/","%","&","|","^","in","instanceof"],AssignmentOperators:["=","+=","-=","*=","/=","%=","<<=",">>=",">>>=","|=","^=","&="],LogicalOperators:["||","&&"]}}Lr(()=>module);function GO(e){let t=e.use(HO);return t.BinaryOperators.indexOf("**")<0&&t.BinaryOperators.push("**"),t.AssignmentOperators.indexOf("**=")<0&&t.AssignmentOperators.push("**="),t}Lr(()=>module);function YO(e){let t=e.use(GO);return t.LogicalOperators.indexOf("??")<0&&t.LogicalOperators.push("??"),t}Lr(()=>module);function Zpe(e){let t=e.use(YO);return t.LogicalOperators.forEach(r=>{let s=r+"=";t.AssignmentOperators.indexOf(s)<0&&t.AssignmentOperators.push(s)}),t}Lr(()=>module);function efe(e){var t=e.use(ds),r=t.Type,s=r.def,i=r.or,n=e.use(yn),a=n.defaults,o=n.geq;let{BinaryOperators:u,AssignmentOperators:c,LogicalOperators:p}=e.use(HO);s("Printable").field("loc",i(s("SourceLocation"),null),a.null,!0),s("Node").bases("Printable").field("type",String).field("comments",i([s("Comment")],null),a.null,!0),s("SourceLocation").field("start",s("Position")).field("end",s("Position")).field("source",i(String,null),a.null),s("Position").field("line",o(1)).field("column",o(0)),s("File").bases("Node").build("program","name").field("program",s("Program")).field("name",i(String,null),a.null),s("Program").bases("Node").build("body").field("body",[s("Statement")]),s("Function").bases("Node").field("id",i(s("Identifier"),null),a.null).field("params",[s("Pattern")]).field("body",s("BlockStatement")).field("generator",Boolean,a.false).field("async",Boolean,a.false),s("Statement").bases("Node"),s("EmptyStatement").bases("Statement").build(),s("BlockStatement").bases("Statement").build("body").field("body",[s("Statement")]),s("ExpressionStatement").bases("Statement").build("expression").field("expression",s("Expression")),s("IfStatement").bases("Statement").build("test","consequent","alternate").field("test",s("Expression")).field("consequent",s("Statement")).field("alternate",i(s("Statement"),null),a.null),s("LabeledStatement").bases("Statement").build("label","body").field("label",s("Identifier")).field("body",s("Statement")),s("BreakStatement").bases("Statement").build("label").field("label",i(s("Identifier"),null),a.null),s("ContinueStatement").bases("Statement").build("label").field("label",i(s("Identifier"),null),a.null),s("WithStatement").bases("Statement").build("object","body").field("object",s("Expression")).field("body",s("Statement")),s("SwitchStatement").bases("Statement").build("discriminant","cases","lexical").field("discriminant",s("Expression")).field("cases",[s("SwitchCase")]).field("lexical",Boolean,a.false),s("ReturnStatement").bases("Statement").build("argument").field("argument",i(s("Expression"),null)),s("ThrowStatement").bases("Statement").build("argument").field("argument",s("Expression")),s("TryStatement").bases("Statement").build("block","handler","finalizer").field("block",s("BlockStatement")).field("handler",i(s("CatchClause"),null),function(){return this.handlers&&this.handlers[0]||null}).field("handlers",[s("CatchClause")],function(){return this.handler?[this.handler]:[]},!0).field("guardedHandlers",[s("CatchClause")],a.emptyArray).field("finalizer",i(s("BlockStatement"),null),a.null),s("CatchClause").bases("Node").build("param","guard","body").field("param",s("Pattern")).field("guard",i(s("Expression"),null),a.null).field("body",s("BlockStatement")),s("WhileStatement").bases("Statement").build("test","body").field("test",s("Expression")).field("body",s("Statement")),s("DoWhileStatement").bases("Statement").build("body","test").field("body",s("Statement")).field("test",s("Expression")),s("ForStatement").bases("Statement").build("init","test","update","body").field("init",i(s("VariableDeclaration"),s("Expression"),null)).field("test",i(s("Expression"),null)).field("update",i(s("Expression"),null)).field("body",s("Statement")),s("ForInStatement").bases("Statement").build("left","right","body").field("left",i(s("VariableDeclaration"),s("Expression"))).field("right",s("Expression")).field("body",s("Statement")),s("DebuggerStatement").bases("Statement").build(),s("Declaration").bases("Statement"),s("FunctionDeclaration").bases("Function","Declaration").build("id","params","body").field("id",s("Identifier")),s("FunctionExpression").bases("Function","Expression").build("id","params","body"),s("VariableDeclaration").bases("Declaration").build("kind","declarations").field("kind",i("var","let","const")).field("declarations",[s("VariableDeclarator")]),s("VariableDeclarator").bases("Node").build("id","init").field("id",s("Pattern")).field("init",i(s("Expression"),null),a.null),s("Expression").bases("Node"),s("ThisExpression").bases("Expression").build(),s("ArrayExpression").bases("Expression").build("elements").field("elements",[i(s("Expression"),null)]),s("ObjectExpression").bases("Expression").build("properties").field("properties",[s("Property")]),s("Property").bases("Node").build("kind","key","value").field("kind",i("init","get","set")).field("key",i(s("Literal"),s("Identifier"))).field("value",s("Expression")),s("SequenceExpression").bases("Expression").build("expressions").field("expressions",[s("Expression")]);var m=i("-","+","!","~","typeof","void","delete");s("UnaryExpression").bases("Expression").build("operator","argument","prefix").field("operator",m).field("argument",s("Expression")).field("prefix",Boolean,a.true);let g=i(...u);s("BinaryExpression").bases("Expression").build("operator","left","right").field("operator",g).field("left",s("Expression")).field("right",s("Expression"));let d=i(...c);s("AssignmentExpression").bases("Expression").build("operator","left","right").field("operator",d).field("left",i(s("Pattern"),s("MemberExpression"))).field("right",s("Expression"));var h=i("++","--");s("UpdateExpression").bases("Expression").build("operator","argument","prefix").field("operator",h).field("argument",s("Expression")).field("prefix",Boolean);var b=i(...p);s("LogicalExpression").bases("Expression").build("operator","left","right").field("operator",b).field("left",s("Expression")).field("right",s("Expression")),s("ConditionalExpression").bases("Expression").build("test","consequent","alternate").field("test",s("Expression")).field("consequent",s("Expression")).field("alternate",s("Expression")),s("NewExpression").bases("Expression").build("callee","arguments").field("callee",s("Expression")).field("arguments",[s("Expression")]),s("CallExpression").bases("Expression").build("callee","arguments").field("callee",s("Expression")).field("arguments",[s("Expression")]),s("MemberExpression").bases("Expression").build("object","property","computed").field("object",s("Expression")).field("property",i(s("Identifier"),s("Expression"))).field("computed",Boolean,function(){var S=this.property.type;return S==="Literal"||S==="MemberExpression"||S==="BinaryExpression"}),s("Pattern").bases("Node"),s("SwitchCase").bases("Node").build("test","consequent").field("test",i(s("Expression"),null)).field("consequent",[s("Statement")]),s("Identifier").bases("Expression","Pattern").build("name").field("name",String).field("optional",Boolean,a.false),s("Literal").bases("Expression").build("value").field("value",i(String,Boolean,null,Number,RegExp,BigInt)),s("Comment").bases("Printable").field("value",String).field("leading",Boolean,a.true).field("trailing",Boolean,a.false)}Lr(()=>module);function tfe(e){e.use(efe);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("Function").field("generator",Boolean,i.false).field("expression",Boolean,i.false).field("defaults",[s(r("Expression"),null)],i.emptyArray).field("rest",s(r("Identifier"),null),i.null),r("RestElement").bases("Pattern").build("argument").field("argument",r("Pattern")).field("typeAnnotation",s(r("TypeAnnotation"),r("TSTypeAnnotation"),null),i.null),r("SpreadElementPattern").bases("Pattern").build("argument").field("argument",r("Pattern")),r("FunctionDeclaration").build("id","params","body","generator","expression").field("id",s(r("Identifier"),null)),r("FunctionExpression").build("id","params","body","generator","expression"),r("ArrowFunctionExpression").bases("Function","Expression").build("params","body","expression").field("id",null,i.null).field("body",s(r("BlockStatement"),r("Expression"))).field("generator",!1,i.false),r("ForOfStatement").bases("Statement").build("left","right","body").field("left",s(r("VariableDeclaration"),r("Pattern"))).field("right",r("Expression")).field("body",r("Statement")),r("YieldExpression").bases("Expression").build("argument","delegate").field("argument",s(r("Expression"),null)).field("delegate",Boolean,i.false),r("GeneratorExpression").bases("Expression").build("body","blocks","filter").field("body",r("Expression")).field("blocks",[r("ComprehensionBlock")]).field("filter",s(r("Expression"),null)),r("ComprehensionExpression").bases("Expression").build("body","blocks","filter").field("body",r("Expression")).field("blocks",[r("ComprehensionBlock")]).field("filter",s(r("Expression"),null)),r("ComprehensionBlock").bases("Node").build("left","right","each").field("left",r("Pattern")).field("right",r("Expression")).field("each",Boolean),r("Property").field("key",s(r("Literal"),r("Identifier"),r("Expression"))).field("value",s(r("Expression"),r("Pattern"))).field("method",Boolean,i.false).field("shorthand",Boolean,i.false).field("computed",Boolean,i.false),r("ObjectProperty").field("shorthand",Boolean,i.false),r("PropertyPattern").bases("Pattern").build("key","pattern").field("key",s(r("Literal"),r("Identifier"),r("Expression"))).field("pattern",r("Pattern")).field("computed",Boolean,i.false),r("ObjectPattern").bases("Pattern").build("properties").field("properties",[s(r("PropertyPattern"),r("Property"))]),r("ArrayPattern").bases("Pattern").build("elements").field("elements",[s(r("Pattern"),null)]),r("SpreadElement").bases("Node").build("argument").field("argument",r("Expression")),r("ArrayExpression").field("elements",[s(r("Expression"),r("SpreadElement"),r("RestElement"),null)]),r("NewExpression").field("arguments",[s(r("Expression"),r("SpreadElement"))]),r("CallExpression").field("arguments",[s(r("Expression"),r("SpreadElement"))]),r("AssignmentPattern").bases("Pattern").build("left","right").field("left",r("Pattern")).field("right",r("Expression")),r("MethodDefinition").bases("Declaration").build("kind","key","value","static").field("kind",s("constructor","method","get","set")).field("key",r("Expression")).field("value",r("Function")).field("computed",Boolean,i.false).field("static",Boolean,i.false);let n=s(r("MethodDefinition"),r("VariableDeclarator"),r("ClassPropertyDefinition"),r("ClassProperty"),r("StaticBlock"));r("ClassProperty").bases("Declaration").build("key").field("key",s(r("Literal"),r("Identifier"),r("Expression"))).field("computed",Boolean,i.false),r("ClassPropertyDefinition").bases("Declaration").build("definition").field("definition",n),r("ClassBody").bases("Declaration").build("body").field("body",[n]),r("ClassDeclaration").bases("Declaration").build("id","body","superClass").field("id",s(r("Identifier"),null)).field("body",r("ClassBody")).field("superClass",s(r("Expression"),null),i.null),r("ClassExpression").bases("Expression").build("id","body","superClass").field("id",s(r("Identifier"),null),i.null).field("body",r("ClassBody")).field("superClass",s(r("Expression"),null),i.null),r("Super").bases("Expression").build(),r("Specifier").bases("Node"),r("ModuleSpecifier").bases("Specifier").field("local",s(r("Identifier"),null),i.null).field("id",s(r("Identifier"),null),i.null).field("name",s(r("Identifier"),null),i.null),r("ImportSpecifier").bases("ModuleSpecifier").build("imported","local").field("imported",r("Identifier")),r("ImportDefaultSpecifier").bases("ModuleSpecifier").build("local"),r("ImportNamespaceSpecifier").bases("ModuleSpecifier").build("local"),r("ImportDeclaration").bases("Declaration").build("specifiers","source","importKind").field("specifiers",[s(r("ImportSpecifier"),r("ImportNamespaceSpecifier"),r("ImportDefaultSpecifier"))],i.emptyArray).field("source",r("Literal")).field("importKind",s("value","type"),function(){return"value"}),r("ExportNamedDeclaration").bases("Declaration").build("declaration","specifiers","source").field("declaration",s(r("Declaration"),null)).field("specifiers",[r("ExportSpecifier")],i.emptyArray).field("source",s(r("Literal"),null),i.null),r("ExportSpecifier").bases("ModuleSpecifier").build("local","exported").field("exported",r("Identifier")),r("ExportDefaultDeclaration").bases("Declaration").build("declaration").field("declaration",s(r("Declaration"),r("Expression"))),r("ExportAllDeclaration").bases("Declaration").build("source").field("source",r("Literal")),r("TaggedTemplateExpression").bases("Expression").build("tag","quasi").field("tag",r("Expression")).field("quasi",r("TemplateLiteral")),r("TemplateLiteral").bases("Expression").build("quasis","expressions").field("quasis",[r("TemplateElement")]).field("expressions",[r("Expression")]),r("TemplateElement").bases("Node").build("value","tail").field("value",{cooked:String,raw:String}).field("tail",Boolean),r("MetaProperty").bases("Expression").build("meta","property").field("meta",r("Identifier")).field("property",r("Identifier"))}Lr(()=>module);function rfe(e){e.use(GO),e.use(tfe)}Lr(()=>module);function sfe(e){e.use(rfe);let r=e.use(ds).Type.def,s=e.use(yn).defaults;r("Function").field("async",Boolean,s.false),r("AwaitExpression").bases("Expression").build("argument").field("argument",r("Expression"))}Lr(()=>module);function ife(e){e.use(sfe);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("ForOfStatement").field("await",Boolean,i.false),r("SpreadProperty").bases("Node").build("argument").field("argument",r("Expression")),r("ObjectExpression").field("properties",[s(r("Property"),r("SpreadProperty"),r("SpreadElement"))]),r("TemplateElement").field("value",{cooked:s(String,null),raw:String}),r("SpreadPropertyPattern").bases("Pattern").build("argument").field("argument",r("Pattern")),r("ObjectPattern").field("properties",[s(r("PropertyPattern"),r("Property"),r("RestElement"),r("SpreadPropertyPattern"))])}Lr(()=>module);function nfe(e){e.use(ife);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("CatchClause").field("param",s(r("Pattern"),null),i.null)}Lr(()=>module);function afe(e){e.use(YO),e.use(nfe);let t=e.use(ds),r=t.Type.def,s=t.Type.or,n=e.use(yn).defaults;r("ImportExpression").bases("Expression").build("source").field("source",r("Expression")),r("ExportAllDeclaration").bases("Declaration").build("source","exported").field("source",r("Literal")).field("exported",s(r("Identifier"),null,void 0),n.null),r("ChainElement").bases("Node").field("optional",Boolean,n.false),r("CallExpression").bases("Expression","ChainElement"),r("MemberExpression").bases("Expression","ChainElement"),r("ChainExpression").bases("Expression").build("expression").field("expression",r("ChainElement")),r("OptionalCallExpression").bases("CallExpression").build("callee","arguments","optional").field("optional",Boolean,n.true),r("OptionalMemberExpression").bases("MemberExpression").build("object","property","computed","optional").field("optional",Boolean,n.true)}Lr(()=>module);function ofe(e){e.use(Zpe),e.use(afe)}Lr(()=>module);function ufe(e){e.use(ofe);let r=e.use(ds).Type.def;r("StaticBlock").bases("Declaration").build("body").field("body",[r("Statement")])}Lr(()=>module);function Eh(e){e.use(ufe);let t=e.use(ds),r=t.Type,s=t.Type.def,i=r.or,a=e.use(yn).defaults;s("AwaitExpression").build("argument","all").field("argument",i(s("Expression"),null)).field("all",Boolean,a.false),s("Decorator").bases("Node").build("expression").field("expression",s("Expression")),s("Property").field("decorators",i([s("Decorator")],null),a.null),s("MethodDefinition").field("decorators",i([s("Decorator")],null),a.null),s("PrivateName").bases("Expression","Pattern").build("id").field("id",s("Identifier")),s("ClassPrivateProperty").bases("ClassProperty").build("key","value").field("key",s("PrivateName")).field("value",i(s("Expression"),null),a.null),s("ImportAttribute").bases("Node").build("key","value").field("key",i(s("Identifier"),s("Literal"))).field("value",s("Expression")),["ImportDeclaration","ExportAllDeclaration","ExportNamedDeclaration"].forEach(o=>{s(o).field("assertions",[s("ImportAttribute")],a.emptyArray)}),s("RecordExpression").bases("Expression").build("properties").field("properties",[i(s("ObjectProperty"),s("ObjectMethod"),s("SpreadElement"))]),s("TupleExpression").bases("Expression").build("elements").field("elements",[i(s("Expression"),s("SpreadElement"),null)]),s("ModuleExpression").bases("Node").build("body").field("body",s("Program"))}Lr(()=>module);function lfe(e){e.use(Eh);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("JSXAttribute").bases("Node").build("name","value").field("name",s(r("JSXIdentifier"),r("JSXNamespacedName"))).field("value",s(r("Literal"),r("JSXExpressionContainer"),r("JSXElement"),r("JSXFragment"),null),i.null),r("JSXIdentifier").bases("Identifier").build("name").field("name",String),r("JSXNamespacedName").bases("Node").build("namespace","name").field("namespace",r("JSXIdentifier")).field("name",r("JSXIdentifier")),r("JSXMemberExpression").bases("MemberExpression").build("object","property").field("object",s(r("JSXIdentifier"),r("JSXMemberExpression"))).field("property",r("JSXIdentifier")).field("computed",Boolean,i.false);let n=s(r("JSXIdentifier"),r("JSXNamespacedName"),r("JSXMemberExpression"));r("JSXSpreadAttribute").bases("Node").build("argument").field("argument",r("Expression"));let a=[s(r("JSXAttribute"),r("JSXSpreadAttribute"))];r("JSXExpressionContainer").bases("Expression").build("expression").field("expression",s(r("Expression"),r("JSXEmptyExpression")));let o=[s(r("JSXText"),r("JSXExpressionContainer"),r("JSXSpreadChild"),r("JSXElement"),r("JSXFragment"),r("Literal"))];r("JSXElement").bases("Expression").build("openingElement","closingElement","children").field("openingElement",r("JSXOpeningElement")).field("closingElement",s(r("JSXClosingElement"),null),i.null).field("children",o,i.emptyArray).field("name",n,function(){return this.openingElement.name},!0).field("selfClosing",Boolean,function(){return this.openingElement.selfClosing},!0).field("attributes",a,function(){return this.openingElement.attributes},!0),r("JSXOpeningElement").bases("Node").build("name","attributes","selfClosing").field("name",n).field("attributes",a,i.emptyArray).field("selfClosing",Boolean,i.false),r("JSXClosingElement").bases("Node").build("name").field("name",n),r("JSXFragment").bases("Expression").build("openingFragment","closingFragment","children").field("openingFragment",r("JSXOpeningFragment")).field("closingFragment",r("JSXClosingFragment")).field("children",o,i.emptyArray),r("JSXOpeningFragment").bases("Node").build(),r("JSXClosingFragment").bases("Node").build(),r("JSXText").bases("Literal").build("value","raw").field("value",String).field("raw",String,function(){return this.value}),r("JSXEmptyExpression").bases("Node").build(),r("JSXSpreadChild").bases("Node").build("expression").field("expression",r("Expression"))}Lr(()=>module);function QO(e){var t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults,n=s(r("TypeAnnotation"),r("TSTypeAnnotation"),null),a=s(r("TypeParameterDeclaration"),r("TSTypeParameterDeclaration"),null);r("Identifier").field("typeAnnotation",n,i.null),r("ObjectPattern").field("typeAnnotation",n,i.null),r("Function").field("returnType",n,i.null).field("typeParameters",a,i.null),r("ClassProperty").build("key","value","typeAnnotation","static").field("value",s(r("Expression"),null)).field("static",Boolean,i.false).field("typeAnnotation",n,i.null),["ClassDeclaration","ClassExpression"].forEach(o=>{r(o).field("typeParameters",a,i.null).field("superTypeParameters",s(r("TypeParameterInstantiation"),r("TSTypeParameterInstantiation"),null),i.null).field("implements",s([r("ClassImplements")],[r("TSExpressionWithTypeArguments")]),i.emptyArray)})}Lr(()=>module);function ZO(e){e.use(Eh),e.use(QO);let t=e.use(ds),r=t.Type.def,s=t.Type.or,i=e.use(yn).defaults;r("Flow").bases("Node"),r("FlowType").bases("Flow"),r("AnyTypeAnnotation").bases("FlowType").build(),r("EmptyTypeAnnotation").bases("FlowType").build(),r("MixedTypeAnnotation").bases("FlowType").build(),r("VoidTypeAnnotation").bases("FlowType").build(),r("SymbolTypeAnnotation").bases("FlowType").build(),r("NumberTypeAnnotation").bases("FlowType").build(),r("BigIntTypeAnnotation").bases("FlowType").build(),r("NumberLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),r("NumericLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Number).field("raw",String),r("BigIntLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",null).field("raw",String),r("StringTypeAnnotation").bases("FlowType").build(),r("StringLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",String).field("raw",String),r("BooleanTypeAnnotation").bases("FlowType").build(),r("BooleanLiteralTypeAnnotation").bases("FlowType").build("value","raw").field("value",Boolean).field("raw",String),r("TypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",r("FlowType")),r("NullableTypeAnnotation").bases("FlowType").build("typeAnnotation").field("typeAnnotation",r("FlowType")),r("NullLiteralTypeAnnotation").bases("FlowType").build(),r("NullTypeAnnotation").bases("FlowType").build(),r("ThisTypeAnnotation").bases("FlowType").build(),r("ExistsTypeAnnotation").bases("FlowType").build(),r("ExistentialTypeParam").bases("FlowType").build(),r("FunctionTypeAnnotation").bases("FlowType").build("params","returnType","rest","typeParameters").field("params",[r("FunctionTypeParam")]).field("returnType",r("FlowType")).field("rest",s(r("FunctionTypeParam"),null)).field("typeParameters",s(r("TypeParameterDeclaration"),null)),r("FunctionTypeParam").bases("Node").build("name","typeAnnotation","optional").field("name",s(r("Identifier"),null)).field("typeAnnotation",r("FlowType")).field("optional",Boolean),r("ArrayTypeAnnotation").bases("FlowType").build("elementType").field("elementType",r("FlowType")),r("ObjectTypeAnnotation").bases("FlowType").build("properties","indexers","callProperties").field("properties",[s(r("ObjectTypeProperty"),r("ObjectTypeSpreadProperty"))]).field("indexers",[r("ObjectTypeIndexer")],i.emptyArray).field("callProperties",[r("ObjectTypeCallProperty")],i.emptyArray).field("inexact",s(Boolean,void 0),i.undefined).field("exact",Boolean,i.false).field("internalSlots",[r("ObjectTypeInternalSlot")],i.emptyArray),r("Variance").bases("Node").build("kind").field("kind",s("plus","minus"));let n=s(r("Variance"),"plus","minus",null);r("ObjectTypeProperty").bases("Node").build("key","value","optional").field("key",s(r("Literal"),r("Identifier"))).field("value",r("FlowType")).field("optional",Boolean).field("variance",n,i.null),r("ObjectTypeIndexer").bases("Node").build("id","key","value").field("id",r("Identifier")).field("key",r("FlowType")).field("value",r("FlowType")).field("variance",n,i.null).field("static",Boolean,i.false),r("ObjectTypeCallProperty").bases("Node").build("value").field("value",r("FunctionTypeAnnotation")).field("static",Boolean,i.false),r("QualifiedTypeIdentifier").bases("Node").build("qualification","id").field("qualification",s(r("Identifier"),r("QualifiedTypeIdentifier"))).field("id",r("Identifier")),r("GenericTypeAnnotation").bases("FlowType").build("id","typeParameters").field("id",s(r("Identifier"),r("QualifiedTypeIdentifier"))).field("typeParameters",s(r("TypeParameterInstantiation"),null)),r("MemberTypeAnnotation").bases("FlowType").build("object","property").field("object",r("Identifier")).field("property",s(r("MemberTypeAnnotation"),r("GenericTypeAnnotation"))),r("IndexedAccessType").bases("FlowType").build("objectType","indexType").field("objectType",r("FlowType")).field("indexType",r("FlowType")),r("OptionalIndexedAccessType").bases("FlowType").build("objectType","indexType","optional").field("objectType",r("FlowType")).field("indexType",r("FlowType")).field("optional",Boolean),r("UnionTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("IntersectionTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("TypeofTypeAnnotation").bases("FlowType").build("argument").field("argument",r("FlowType")),r("ObjectTypeSpreadProperty").bases("Node").build("argument").field("argument",r("FlowType")),r("ObjectTypeInternalSlot").bases("Node").build("id","value","optional","static","method").field("id",r("Identifier")).field("value",r("FlowType")).field("optional",Boolean).field("static",Boolean).field("method",Boolean),r("TypeParameterDeclaration").bases("Node").build("params").field("params",[r("TypeParameter")]),r("TypeParameterInstantiation").bases("Node").build("params").field("params",[r("FlowType")]),r("TypeParameter").bases("FlowType").build("name","variance","bound","default").field("name",String).field("variance",n,i.null).field("bound",s(r("TypeAnnotation"),null),i.null).field("default",s(r("FlowType"),null),i.null),r("ClassProperty").field("variance",n,i.null),r("ClassImplements").bases("Node").build("id").field("id",r("Identifier")).field("superClass",s(r("Expression"),null),i.null).field("typeParameters",s(r("TypeParameterInstantiation"),null),i.null),r("InterfaceTypeAnnotation").bases("FlowType").build("body","extends").field("body",r("ObjectTypeAnnotation")).field("extends",s([r("InterfaceExtends")],null),i.null),r("InterfaceDeclaration").bases("Declaration").build("id","body","extends").field("id",r("Identifier")).field("typeParameters",s(r("TypeParameterDeclaration"),null),i.null).field("body",r("ObjectTypeAnnotation")).field("extends",[r("InterfaceExtends")]),r("DeclareInterface").bases("InterfaceDeclaration").build("id","body","extends"),r("InterfaceExtends").bases("Node").build("id").field("id",r("Identifier")).field("typeParameters",s(r("TypeParameterInstantiation"),null),i.null),r("TypeAlias").bases("Declaration").build("id","typeParameters","right").field("id",r("Identifier")).field("typeParameters",s(r("TypeParameterDeclaration"),null)).field("right",r("FlowType")),r("DeclareTypeAlias").bases("TypeAlias").build("id","typeParameters","right"),r("OpaqueType").bases("Declaration").build("id","typeParameters","impltype","supertype").field("id",r("Identifier")).field("typeParameters",s(r("TypeParameterDeclaration"),null)).field("impltype",r("FlowType")).field("supertype",s(r("FlowType"),null)),r("DeclareOpaqueType").bases("OpaqueType").build("id","typeParameters","supertype").field("impltype",s(r("FlowType"),null)),r("TypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",r("Expression")).field("typeAnnotation",r("TypeAnnotation")),r("TupleTypeAnnotation").bases("FlowType").build("types").field("types",[r("FlowType")]),r("DeclareVariable").bases("Statement").build("id").field("id",r("Identifier")),r("DeclareFunction").bases("Statement").build("id").field("id",r("Identifier")).field("predicate",s(r("FlowPredicate"),null),i.null),r("DeclareClass").bases("InterfaceDeclaration").build("id"),r("DeclareModule").bases("Statement").build("id","body").field("id",s(r("Identifier"),r("Literal"))).field("body",r("BlockStatement")),r("DeclareModuleExports").bases("Statement").build("typeAnnotation").field("typeAnnotation",r("TypeAnnotation")),r("DeclareExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",s(r("DeclareVariable"),r("DeclareFunction"),r("DeclareClass"),r("FlowType"),r("TypeAlias"),r("DeclareOpaqueType"),r("InterfaceDeclaration"),null)).field("specifiers",[s(r("ExportSpecifier"),r("ExportBatchSpecifier"))],i.emptyArray).field("source",s(r("Literal"),null),i.null),r("DeclareExportAllDeclaration").bases("Declaration").build("source").field("source",s(r("Literal"),null),i.null),r("ImportDeclaration").field("importKind",s("value","type","typeof"),()=>"value"),r("FlowPredicate").bases("Flow"),r("InferredPredicate").bases("FlowPredicate").build(),r("DeclaredPredicate").bases("FlowPredicate").build("value").field("value",r("Expression")),r("Function").field("predicate",s(r("FlowPredicate"),null),i.null),r("CallExpression").field("typeArguments",s(null,r("TypeParameterInstantiation")),i.null),r("NewExpression").field("typeArguments",s(null,r("TypeParameterInstantiation")),i.null),r("EnumDeclaration").bases("Declaration").build("id","body").field("id",r("Identifier")).field("body",s(r("EnumBooleanBody"),r("EnumNumberBody"),r("EnumStringBody"),r("EnumSymbolBody"))),r("EnumBooleanBody").build("members","explicitType").field("members",[r("EnumBooleanMember")]).field("explicitType",Boolean),r("EnumNumberBody").build("members","explicitType").field("members",[r("EnumNumberMember")]).field("explicitType",Boolean),r("EnumStringBody").build("members","explicitType").field("members",s([r("EnumStringMember")],[r("EnumDefaultedMember")])).field("explicitType",Boolean),r("EnumSymbolBody").build("members").field("members",[r("EnumDefaultedMember")]),r("EnumBooleanMember").build("id","init").field("id",r("Identifier")).field("init",s(r("Literal"),Boolean)),r("EnumNumberMember").build("id","init").field("id",r("Identifier")).field("init",r("Literal")),r("EnumStringMember").build("id","init").field("id",r("Identifier")).field("init",r("Literal")),r("EnumDefaultedMember").build("id").field("id",r("Identifier"))}Lr(()=>module);function cfe(e){e.use(Eh);var t=e.use(ds),r=e.use(yn).defaults,s=t.Type.def,i=t.Type.or;s("VariableDeclaration").field("declarations",[i(s("VariableDeclarator"),s("Identifier"))]),s("Property").field("value",i(s("Expression"),s("Pattern"))),s("ArrayPattern").field("elements",[i(s("Pattern"),s("SpreadElement"),null)]),s("ObjectPattern").field("properties",[i(s("Property"),s("PropertyPattern"),s("SpreadPropertyPattern"),s("SpreadProperty"))]),s("ExportSpecifier").bases("ModuleSpecifier").build("id","name"),s("ExportBatchSpecifier").bases("Specifier").build(),s("ExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",Boolean).field("declaration",i(s("Declaration"),s("Expression"),null)).field("specifiers",[i(s("ExportSpecifier"),s("ExportBatchSpecifier"))],r.emptyArray).field("source",i(s("Literal"),null),r.null),s("Block").bases("Comment").build("value","leading","trailing"),s("Line").bases("Comment").build("value","leading","trailing")}Lr(()=>module);function e4(e){e.use(Eh);let t=e.use(ds),r=e.use(yn).defaults,s=t.Type.def,i=t.Type.or,{undefined:n}=t.builtInTypes;s("Noop").bases("Statement").build(),s("DoExpression").bases("Expression").build("body").field("body",[s("Statement")]),s("BindExpression").bases("Expression").build("object","callee").field("object",i(s("Expression"),null)).field("callee",s("Expression")),s("ParenthesizedExpression").bases("Expression").build("expression").field("expression",s("Expression")),s("ExportNamespaceSpecifier").bases("Specifier").build("exported").field("exported",s("Identifier")),s("ExportDefaultSpecifier").bases("Specifier").build("exported").field("exported",s("Identifier")),s("CommentBlock").bases("Comment").build("value","leading","trailing"),s("CommentLine").bases("Comment").build("value","leading","trailing"),s("Directive").bases("Node").build("value").field("value",s("DirectiveLiteral")),s("DirectiveLiteral").bases("Node","Expression").build("value").field("value",String,r["use strict"]),s("InterpreterDirective").bases("Node").build("value").field("value",String),s("BlockStatement").bases("Statement").build("body").field("body",[s("Statement")]).field("directives",[s("Directive")],r.emptyArray),s("Program").bases("Node").build("body").field("body",[s("Statement")]).field("directives",[s("Directive")],r.emptyArray).field("interpreter",i(s("InterpreterDirective"),null),r.null);function a(p=String,m){return["extra",{rawValue:p,raw:String},function(){let d=t.getFieldValue(this,"value");return{rawValue:d,raw:m?m(d):String(d)}}]}s("StringLiteral").bases("Literal").build("value").field("value",String).field(...a(String,p=>JSON.stringify(p))),s("NumericLiteral").bases("Literal").build("value").field("value",Number).field("raw",i(String,null),r.null).field(...a(Number)),s("BigIntLiteral").bases("Literal").build("value").field("value",i(String,Number)).field(...a(String,p=>p+"n")),s("DecimalLiteral").bases("Literal").build("value").field("value",String).field(...a(String,p=>p+"m")),s("NullLiteral").bases("Literal").build().field("value",null,r.null),s("BooleanLiteral").bases("Literal").build("value").field("value",Boolean),s("RegExpLiteral").bases("Literal").build("pattern","flags").field("pattern",String).field("flags",String).field("value",RegExp,function(){return new RegExp(this.pattern,this.flags)}).field(...a(i(RegExp,n),p=>`/${p.pattern}/${p.flags||""}`)).field("regex",{pattern:String,flags:String},function(){return{pattern:this.pattern,flags:this.flags}});var o=i(s("Property"),s("ObjectMethod"),s("ObjectProperty"),s("SpreadProperty"),s("SpreadElement"));s("ObjectExpression").bases("Expression").build("properties").field("properties",[o]),s("ObjectMethod").bases("Node","Function").build("kind","key","params","body","computed").field("kind",i("method","get","set")).field("key",i(s("Literal"),s("Identifier"),s("Expression"))).field("params",[s("Pattern")]).field("body",s("BlockStatement")).field("computed",Boolean,r.false).field("generator",Boolean,r.false).field("async",Boolean,r.false).field("accessibility",i(s("Literal"),null),r.null).field("decorators",i([s("Decorator")],null),r.null),s("ObjectProperty").bases("Node").build("key","value").field("key",i(s("Literal"),s("Identifier"),s("Expression"))).field("value",i(s("Expression"),s("Pattern"))).field("accessibility",i(s("Literal"),null),r.null).field("computed",Boolean,r.false);var u=i(s("MethodDefinition"),s("VariableDeclarator"),s("ClassPropertyDefinition"),s("ClassProperty"),s("ClassPrivateProperty"),s("ClassMethod"),s("ClassPrivateMethod"),s("ClassAccessorProperty"),s("StaticBlock"));s("ClassBody").bases("Declaration").build("body").field("body",[u]),s("ClassMethod").bases("Declaration","Function").build("kind","key","params","body","computed","static").field("key",i(s("Literal"),s("Identifier"),s("Expression"))),s("ClassPrivateMethod").bases("Declaration","Function").build("key","params","body","kind","computed","static").field("key",s("PrivateName")),s("ClassAccessorProperty").bases("Declaration").build("key","value","decorators","computed","static").field("key",i(s("Literal"),s("Identifier"),s("PrivateName"),s("Expression"))).field("value",i(s("Expression"),null),r.null),["ClassMethod","ClassPrivateMethod"].forEach(p=>{s(p).field("kind",i("get","set","method","constructor"),()=>"method").field("body",s("BlockStatement")).field("access",i("public","private","protected",null),r.null)}),["ClassMethod","ClassPrivateMethod","ClassAccessorProperty"].forEach(p=>{s(p).field("computed",Boolean,r.false).field("static",Boolean,r.false).field("abstract",Boolean,r.false).field("accessibility",i("public","private","protected",null),r.null).field("decorators",i([s("Decorator")],null),r.null).field("definite",Boolean,r.false).field("optional",Boolean,r.false).field("override",Boolean,r.false).field("readonly",Boolean,r.false)});var c=i(s("Property"),s("PropertyPattern"),s("SpreadPropertyPattern"),s("SpreadProperty"),s("ObjectProperty"),s("RestProperty"),s("RestElement"));s("ObjectPattern").bases("Pattern").build("properties").field("properties",[c]).field("decorators",i([s("Decorator")],null),r.null),s("SpreadProperty").bases("Node").build("argument").field("argument",s("Expression")),s("RestProperty").bases("Node").build("argument").field("argument",s("Expression")),s("ForAwaitStatement").bases("Statement").build("left","right","body").field("left",i(s("VariableDeclaration"),s("Expression"))).field("right",s("Expression")).field("body",s("Statement")),s("Import").bases("Expression").build()}Lr(()=>module);function pfe(e){let r=e.use(ds).Type.def;e.use(e4),e.use(ZO),r("V8IntrinsicIdentifier").bases("Expression").build("name").field("name",String),r("TopicReference").bases("Expression").build()}Lr(()=>module);function ffe(e){e.use(e4),e.use(QO);var t=e.use(ds),r=t.namedTypes,s=t.Type.def,i=t.Type.or,n=e.use(yn).defaults,a=t.Type.from(function(p,m){return!!(r.StringLiteral&&r.StringLiteral.check(p,m)||r.Literal&&r.Literal.check(p,m)&&typeof p.value=="string")},"StringLiteral");s("TSType").bases("Node");var o=i(s("Identifier"),s("TSQualifiedName"));s("TSTypeReference").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("typeName","typeParameters").field("typeName",o),s("TSHasOptionalTypeParameterInstantiation").field("typeParameters",i(s("TSTypeParameterInstantiation"),null),n.null),s("TSHasOptionalTypeParameters").field("typeParameters",i(s("TSTypeParameterDeclaration"),null,void 0),n.null),s("TSHasOptionalTypeAnnotation").field("typeAnnotation",i(s("TSTypeAnnotation"),null),n.null),s("TSQualifiedName").bases("Node").build("left","right").field("left",o).field("right",o),s("TSAsExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",s("Expression")).field("typeAnnotation",s("TSType")).field("extra",i({parenthesized:Boolean},null),n.null),s("TSTypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",s("Expression")).field("typeAnnotation",s("TSType")),s("TSSatisfiesExpression").bases("Expression","Pattern").build("expression","typeAnnotation").field("expression",s("Expression")).field("typeAnnotation",s("TSType")),s("TSNonNullExpression").bases("Expression","Pattern").build("expression").field("expression",s("Expression")),["TSAnyKeyword","TSBigIntKeyword","TSBooleanKeyword","TSNeverKeyword","TSNullKeyword","TSNumberKeyword","TSObjectKeyword","TSStringKeyword","TSSymbolKeyword","TSUndefinedKeyword","TSUnknownKeyword","TSVoidKeyword","TSIntrinsicKeyword","TSThisType"].forEach(p=>{s(p).bases("TSType").build()}),s("TSArrayType").bases("TSType").build("elementType").field("elementType",s("TSType")),s("TSLiteralType").bases("TSType").build("literal").field("literal",i(s("NumericLiteral"),s("StringLiteral"),s("BooleanLiteral"),s("TemplateLiteral"),s("UnaryExpression"),s("BigIntLiteral"))),s("TemplateLiteral").field("expressions",i([s("Expression")],[s("TSType")])),["TSUnionType","TSIntersectionType"].forEach(p=>{s(p).bases("TSType").build("types").field("types",[s("TSType")])}),s("TSConditionalType").bases("TSType").build("checkType","extendsType","trueType","falseType").field("checkType",s("TSType")).field("extendsType",s("TSType")).field("trueType",s("TSType")).field("falseType",s("TSType")),s("TSInferType").bases("TSType").build("typeParameter").field("typeParameter",s("TSTypeParameter")),s("TSParenthesizedType").bases("TSType").build("typeAnnotation").field("typeAnnotation",s("TSType"));var u=[i(s("Identifier"),s("RestElement"),s("ArrayPattern"),s("ObjectPattern"))];["TSFunctionType","TSConstructorType"].forEach(p=>{s(p).bases("TSType","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters").field("parameters",u)}),s("TSDeclareFunction").bases("Declaration","TSHasOptionalTypeParameters").build("id","params","returnType").field("declare",Boolean,n.false).field("async",Boolean,n.false).field("generator",Boolean,n.false).field("id",i(s("Identifier"),null),n.null).field("params",[s("Pattern")]).field("returnType",i(s("TSTypeAnnotation"),s("Noop"),null),n.null),s("TSDeclareMethod").bases("Declaration","TSHasOptionalTypeParameters").build("key","params","returnType").field("async",Boolean,n.false).field("generator",Boolean,n.false).field("params",[s("Pattern")]).field("abstract",Boolean,n.false).field("accessibility",i("public","private","protected",void 0),n.undefined).field("static",Boolean,n.false).field("computed",Boolean,n.false).field("optional",Boolean,n.false).field("key",i(s("Identifier"),s("StringLiteral"),s("NumericLiteral"),s("Expression"))).field("kind",i("get","set","method","constructor"),function(){return"method"}).field("access",i("public","private","protected",void 0),n.undefined).field("decorators",i([s("Decorator")],null),n.null).field("returnType",i(s("TSTypeAnnotation"),s("Noop"),null),n.null),s("TSMappedType").bases("TSType").build("typeParameter","typeAnnotation").field("readonly",i(Boolean,"+","-"),n.false).field("typeParameter",s("TSTypeParameter")).field("optional",i(Boolean,"+","-"),n.false).field("typeAnnotation",i(s("TSType"),null),n.null),s("TSTupleType").bases("TSType").build("elementTypes").field("elementTypes",[i(s("TSType"),s("TSNamedTupleMember"))]),s("TSNamedTupleMember").bases("TSType").build("label","elementType","optional").field("label",s("Identifier")).field("optional",Boolean,n.false).field("elementType",s("TSType")),s("TSRestType").bases("TSType").build("typeAnnotation").field("typeAnnotation",s("TSType")),s("TSOptionalType").bases("TSType").build("typeAnnotation").field("typeAnnotation",s("TSType")),s("TSIndexedAccessType").bases("TSType").build("objectType","indexType").field("objectType",s("TSType")).field("indexType",s("TSType")),s("TSTypeOperator").bases("TSType").build("operator").field("operator",String).field("typeAnnotation",s("TSType")),s("TSTypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",i(s("TSType"),s("TSTypeAnnotation"))),s("TSIndexSignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",[s("Identifier")]).field("readonly",Boolean,n.false),s("TSPropertySignature").bases("Declaration","TSHasOptionalTypeAnnotation").build("key","typeAnnotation","optional").field("key",s("Expression")).field("computed",Boolean,n.false).field("readonly",Boolean,n.false).field("optional",Boolean,n.false).field("initializer",i(s("Expression"),null),n.null),s("TSMethodSignature").bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("key","parameters","typeAnnotation").field("key",s("Expression")).field("computed",Boolean,n.false).field("optional",Boolean,n.false).field("parameters",u),s("TSTypePredicate").bases("TSTypeAnnotation","TSType").build("parameterName","typeAnnotation","asserts").field("parameterName",i(s("Identifier"),s("TSThisType"))).field("typeAnnotation",i(s("TSTypeAnnotation"),null),n.null).field("asserts",Boolean,n.false),["TSCallSignatureDeclaration","TSConstructSignatureDeclaration"].forEach(p=>{s(p).bases("Declaration","TSHasOptionalTypeParameters","TSHasOptionalTypeAnnotation").build("parameters","typeAnnotation").field("parameters",u)}),s("TSEnumMember").bases("Node").build("id","initializer").field("id",i(s("Identifier"),a)).field("initializer",i(s("Expression"),null),n.null),s("TSTypeQuery").bases("TSType").build("exprName").field("exprName",i(o,s("TSImportType")));var c=i(s("TSCallSignatureDeclaration"),s("TSConstructSignatureDeclaration"),s("TSIndexSignature"),s("TSMethodSignature"),s("TSPropertySignature"));s("TSTypeLiteral").bases("TSType").build("members").field("members",[c]),s("TSTypeParameter").bases("Identifier").build("name","constraint","default").field("name",i(s("Identifier"),String)).field("constraint",i(s("TSType"),void 0),n.undefined).field("default",i(s("TSType"),void 0),n.undefined),s("TSTypeAssertion").bases("Expression","Pattern").build("typeAnnotation","expression").field("typeAnnotation",s("TSType")).field("expression",s("Expression")).field("extra",i({parenthesized:Boolean},null),n.null),s("TSTypeParameterDeclaration").bases("Declaration").build("params").field("params",[s("TSTypeParameter")]),s("TSInstantiationExpression").bases("Expression","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",s("Expression")),s("TSTypeParameterInstantiation").bases("Node").build("params").field("params",[s("TSType")]),s("TSEnumDeclaration").bases("Declaration").build("id","members").field("id",s("Identifier")).field("const",Boolean,n.false).field("declare",Boolean,n.false).field("members",[s("TSEnumMember")]).field("initializer",i(s("Expression"),null),n.null),s("TSTypeAliasDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","typeAnnotation").field("id",s("Identifier")).field("declare",Boolean,n.false).field("typeAnnotation",s("TSType")),s("TSModuleBlock").bases("Node").build("body").field("body",[s("Statement")]),s("TSModuleDeclaration").bases("Declaration").build("id","body").field("id",i(a,o)).field("declare",Boolean,n.false).field("global",Boolean,n.false).field("body",i(s("TSModuleBlock"),s("TSModuleDeclaration"),null),n.null),s("TSImportType").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("argument","qualifier","typeParameters").field("argument",a).field("qualifier",i(o,void 0),n.undefined),s("TSImportEqualsDeclaration").bases("Declaration").build("id","moduleReference").field("id",s("Identifier")).field("isExport",Boolean,n.false).field("moduleReference",i(o,s("TSExternalModuleReference"))),s("TSExternalModuleReference").bases("Declaration").build("expression").field("expression",a),s("TSExportAssignment").bases("Statement").build("expression").field("expression",s("Expression")),s("TSNamespaceExportDeclaration").bases("Declaration").build("id").field("id",s("Identifier")),s("TSInterfaceBody").bases("Node").build("body").field("body",[c]),s("TSExpressionWithTypeArguments").bases("TSType","TSHasOptionalTypeParameterInstantiation").build("expression","typeParameters").field("expression",o),s("TSInterfaceDeclaration").bases("Declaration","TSHasOptionalTypeParameters").build("id","body").field("id",o).field("declare",Boolean,n.false).field("extends",i([s("TSExpressionWithTypeArguments")],null),n.null).field("body",s("TSInterfaceBody")),s("TSParameterProperty").bases("Pattern").build("parameter").field("accessibility",i("public","private","protected",void 0),n.undefined).field("readonly",Boolean,n.false).field("parameter",i(s("Identifier"),s("AssignmentPattern"))),s("ClassProperty").field("access",i("public","private","protected",void 0),n.undefined),s("ClassAccessorProperty").bases("Declaration","TSHasOptionalTypeAnnotation"),s("ClassBody").field("body",[i(s("MethodDefinition"),s("VariableDeclarator"),s("ClassPropertyDefinition"),s("ClassProperty"),s("ClassPrivateProperty"),s("ClassAccessorProperty"),s("ClassMethod"),s("ClassPrivateMethod"),s("StaticBlock"),s("TSDeclareMethod"),c)])}Lr(()=>module);var ta;ta||(ta={});var{astNodesAreEquivalent:O1t,builders:Wc,builtInTypes:ra,defineMethod:B1t,eachField:L1t,finalize:M1t,getBuilderName:R1t,getFieldNames:hfe,getFieldValue:fo,getSupertypeNames:j1t,namedTypes:dfe,NodePath:mfe,Path:$1t,PathVisitor:q1t,someField:yfe,Type:U1t,use:V1t,visit:J1t}=Ype([Eh,lfe,ZO,cfe,pfe,ffe]);Object.assign(ta,dfe);var p0=ta,NO=C0.default.SourceMapConsumer,gfe=C0.default.SourceMapGenerator,t4=Object.prototype.hasOwnProperty;function xfe(){return`
|
|
228
228
|
`}function FO(e,t,r){return e&&t4.call(e,t)?e[t]:r}function bfe(...e){let t={},r=e.length;for(let s=0;s<r;++s){let i=Object.keys(e[s]),n=i.length;for(let a=0;a<n;++a)t[i[a]]=!0}return t}function Ar(e,t){return e.line-t.line||e.column-t.column}function lu(e){return{line:e.line,column:e.column}}function Sfe(e,t){if(e){if(!t)return e}else return t||null;let r=new NO(e),s=new NO(t),i=new gfe({file:t.file,sourceRoot:t.sourceRoot}),n={};return s.eachMapping(function(a){let o=r.originalPositionFor({line:a.originalLine,column:a.originalColumn}),u=o.source;if(u===null)return;i.addMapping({source:u,original:lu(o),generated:{line:a.generatedLine,column:a.generatedColumn},name:a.name});let c=r.sourceContentFor(u);c&&!t4.call(n,u)&&(n[u]=c,i.setSourceContent(u,c))}),i.toJSON()}function r4(e,t){if(!e.loc)return null;let r={start:e.loc.start,end:e.loc.end};function s(i){L1(r,i.loc)}return e.declaration&&e.declaration.decorators&&D0(e)&&e.declaration.decorators.forEach(s),Ar(r.start,r.end)<0&&(r.start=lu(r.start),t.skipSpaces(r.start,!1,!0),Ar(r.start,r.end)<0&&(r.end=lu(r.end),t.skipSpaces(r.end,!0,!0))),e.comments&&e.comments.forEach(s),r}function L1(e,t){e&&t&&(Ar(t.start,e.start)<0&&(e.start=t.start),Ar(e.end,t.end)<0&&(e.end=t.end))}function W1(e,t){let r=e.loc;if(r&&(r.start.line<1&&(r.start.line=1),r.end.line<1&&(r.end.line=1)),e.type==="File"&&(r.start=t.firstPos(),r.end=t.lastPos()),Efe(e,t),Tfe(e,t),r&&e.decorators)e.decorators.forEach(function(s){L1(r,s.loc)});else if(e.declaration&&D0(e)){e.declaration.loc=null;let s=e.declaration.decorators;s&&s.forEach(function(i){L1(r,i.loc)})}else if(p0.MethodDefinition&&p0.MethodDefinition.check(e)||p0.Property.check(e)&&(e.method||e.shorthand))e.value.loc=null,p0.FunctionExpression.check(e.value)&&(e.value.id=null);else if(e.type==="ObjectTypeProperty"){let s=e.loc,i=s&&s.end;i&&(i=lu(i),t.prevPos(i)&&t.charAt(i)===","&&(i=t.skipSpaces(i,!0,!0))&&(s.end=i))}}function Efe(e,t){if(e.type!=="ForStatement")return;function r(s){let i=s&&s.loc,n=i&&i.start,a=i&&lu(i.end);for(;n&&a&&Ar(n,a)<0&&(t.prevPos(a),t.charAt(a)===";");)i.end.line=a.line,i.end.column=a.column}r(e.init),r(e.test),r(e.update)}function Tfe(e,t){if(e.type==="TemplateLiteral"&&e.quasis.length!==0){if(e.loc){let r=lu(e.loc.start),s=e.quasis[0];Ar(s.loc.start,r)<0&&(s.loc.start=r);let i=lu(e.loc.end),n=e.quasis[e.quasis.length-1];Ar(i,n.loc.end)<0&&(n.loc.end=i)}e.expressions.forEach(function(r,s){let i=t.skipSpaces(r.loc.start,!0,!1);if(t.prevPos(i)&&t.charAt(i)==="{"&&t.prevPos(i)&&t.charAt(i)==="$"){let a=e.quasis[s];Ar(i,a.loc.end)<0&&(a.loc.end=i)}let n=t.skipSpaces(r.loc.end,!1,!1);if(t.charAt(n)==="}"){let a=e.quasis[s+1];Ar(a.loc.start,n)<0&&(a.loc.start=n)}})}}function D0(e){if(e)switch(e.type){case"ExportDeclaration":case"ExportDefaultDeclaration":case"ExportDefaultSpecifier":case"DeclareExportDeclaration":case"ExportNamedDeclaration":case"ExportAllDeclaration":return!0}return!1}function s4(e){let t=e.getParentNode();return e.getName()==="declaration"&&D0(t)?t:null}function yh(e,t){let r=e.trailingComma;return typeof r=="object"?!!r[t]:!!r}var M1={tabWidth:4,useTabs:!1,reuseWhitespace:!0,lineTerminator:xfe(),wrapColumn:74,sourceFileName:null,sourceMapName:null,sourceRoot:null,inputSourceMap:null,range:!1,tolerant:!0,quote:null,trailingComma:!1,arrayBracketSpacing:!1,objectCurlySpacing:!0,arrowParensAlways:!1,flowObjectCommas:!0,tokens:!0},vfe=M1.hasOwnProperty;function P0(e){let t=e||M1;function r(s){return vfe.call(t,s)?t[s]:M1[s]}return{tabWidth:+r("tabWidth"),useTabs:!!r("useTabs"),reuseWhitespace:!!r("reuseWhitespace"),lineTerminator:r("lineTerminator"),wrapColumn:Math.max(r("wrapColumn"),0),sourceFileName:r("sourceFileName"),sourceMapName:r("sourceMapName"),sourceRoot:r("sourceRoot"),inputSourceMap:r("inputSourceMap"),parser:r("esprima")||r("parser"),range:r("range"),tolerant:r("tolerant"),quote:r("quote"),trailingComma:r("trailingComma"),arrayBracketSpacing:r("arrayBracketSpacing"),objectCurlySpacing:r("objectCurlySpacing"),arrowParensAlways:r("arrowParensAlways"),flowObjectCommas:r("flowObjectCommas"),tokens:!!r("tokens")}}var R1=class e{constructor(t,r,s=r){this.sourceLines=t,this.sourceLoc=r,this.targetLoc=s}slice(t,r,s=t.lastPos()){let i=this.sourceLines,n=this.sourceLoc,a=this.targetLoc;function o(u){let c=n[u],p=a[u],m=r;return u==="end"&&(m=s),Afe(i,c,t,p,m)}if(Ar(r,a.start)<=0)if(Ar(a.end,s)<=0)a={start:uu(a.start,r.line,r.column),end:uu(a.end,r.line,r.column)};else{if(Ar(s,a.start)<=0)return null;n={start:n.start,end:o("end")},a={start:uu(a.start,r.line,r.column),end:uu(s,r.line,r.column)}}else{if(Ar(a.end,r)<=0)return null;Ar(a.end,s)<=0?(n={start:o("start"),end:n.end},a={start:{line:1,column:0},end:uu(a.end,r.line,r.column)}):(n={start:o("start"),end:o("end")},a={start:{line:1,column:0},end:uu(s,r.line,r.column)})}return new e(this.sourceLines,n,a)}add(t,r){return new e(this.sourceLines,this.sourceLoc,{start:_O(this.targetLoc.start,t,r),end:_O(this.targetLoc.end,t,r)})}subtract(t,r){return new e(this.sourceLines,this.sourceLoc,{start:uu(this.targetLoc.start,t,r),end:uu(this.targetLoc.end,t,r)})}indent(t,r=!1,s=!1){if(t===0)return this;let i=this.targetLoc,n=i.start.line,a=i.end.line;if(r&&n===1&&a===1)return this;if(i={start:i.start,end:i.end},!r||n>1){let o=i.start.column+t;i.start={line:n,column:s?Math.max(0,o):o}}if(!r||a>1){let o=i.end.column+t;i.end={line:a,column:s?Math.max(0,o):o}}return new e(this.sourceLines,this.sourceLoc,i)}};function _O(e,t,r){return{line:e.line+t-1,column:e.line===1?e.column+r:e.column}}function uu(e,t,r){return{line:e.line-t+1,column:e.line===t?e.column-r:e.column}}function Afe(e,t,r,s,i){let n=Ar(s,i);if(n===0)return t;let a,o;if(n<0){a=e.skipSpaces(t)||e.lastPos(),o=r.skipSpaces(s)||r.lastPos();let u=i.line-o.line;for(a.line+=u,o.line+=u,u>0&&(a.column=0,o.column=0);Ar(o,i)<0&&r.nextPos(o,!0););}else{a=e.skipSpaces(t,!0)||e.firstPos(),o=r.skipSpaces(s,!0)||r.firstPos();let u=i.line-o.line;for(a.line+=u,o.line+=u,u<0&&(a.column=e.getLineLength(a.line),o.column=r.getLineLength(o.line));Ar(i,o)<0&&r.prevPos(o,!0););}return a}var Cfe=Object.defineProperty,Dfe=(e,t,r)=>t in e?Cfe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,lh=(e,t,r)=>(Dfe(e,typeof t!="symbol"?t+"":t,r),r),Jc=class e{constructor(t,r=null){this.infos=t,lh(this,"length"),lh(this,"name"),lh(this,"mappings",[]),lh(this,"cachedSourceMap",null),lh(this,"cachedTabWidth"),this.length=t.length,this.name=r||null,this.name&&this.mappings.push(new R1(this,{start:this.firstPos(),end:this.lastPos()}))}toString(t){return this.sliceString(this.firstPos(),this.lastPos(),t)}getSourceMap(t,r){if(!t)return null;let s=this;function i(o){return o=o||{},o.file=t,r&&(o.sourceRoot=r),o}if(s.cachedSourceMap)return i(s.cachedSourceMap.toJSON());let n=new C0.default.SourceMapGenerator(i()),a={};return s.mappings.forEach(function(o){let u=o.sourceLines.skipSpaces(o.sourceLoc.start)||o.sourceLines.lastPos(),c=s.skipSpaces(o.targetLoc.start)||s.lastPos();for(;Ar(u,o.sourceLoc.end)<0&&Ar(c,o.targetLoc.end)<0;){o.sourceLines.charAt(u),s.charAt(c);let p=o.sourceLines.name;if(n.addMapping({source:p,original:{line:u.line,column:u.column},generated:{line:c.line,column:c.column}}),!j1.call(a,p)){let m=o.sourceLines.toString();n.setSourceContent(p,m),a[p]=m}s.nextPos(c,!0),o.sourceLines.nextPos(u,!0)}}),s.cachedSourceMap=n,n.toJSON()}bootstrapCharAt(t){let r=t.line,s=t.column,i=this.toString().split($1),n=i[r-1];return typeof n>"u"?"":s===n.length&&r<i.length?`
|
|
229
229
|
`:s>=n.length?"":n.charAt(s)}charAt(t){let r=t.line,s=t.column,i=this,n=i.infos,a=n[r-1],o=s;if(typeof a>"u"||o<0)return"";let u=this.getIndentAt(r);return o<u?" ":(o+=a.sliceStart-u,o===a.sliceEnd&&r<this.length?`
|
|
230
230
|
`:o>=a.sliceEnd?"":a.line.charAt(o))}stripMargin(t,r){if(t===0)return this;if(r&&this.length===1)return this;let s=new e(this.infos.map(function(i,n){return i.line&&(n>0||!r)&&(i={...i,indent:Math.max(0,i.indent-t)}),i}));if(this.mappings.length>0){let i=s.mappings;this.mappings.forEach(function(n){i.push(n.indent(t,r,!0))})}return s}indent(t){if(t===0)return this;let r=new e(this.infos.map(function(s){return s.line&&!s.locked&&(s={...s,indent:s.indent+t}),s}));if(this.mappings.length>0){let s=r.mappings;this.mappings.forEach(function(i){s.push(i.indent(t))})}return r}indentTail(t){if(t===0)return this;if(this.length<2)return this;let r=new e(this.infos.map(function(s,i){return i>0&&s.line&&!s.locked&&(s={...s,indent:s.indent+t}),s}));if(this.mappings.length>0){let s=r.mappings;this.mappings.forEach(function(i){s.push(i.indent(t,!0))})}return r}lockIndentTail(){return this.length<2?this:new e(this.infos.map((t,r)=>({...t,locked:r>0})))}getIndentAt(t){return Math.max(this.infos[t-1].indent,0)}guessTabWidth(){if(typeof this.cachedTabWidth=="number")return this.cachedTabWidth;let t=[],r=0;for(let n=1,a=this.length;n<=a;++n){let o=this.infos[n-1],u=o.line.slice(o.sliceStart,o.sliceEnd);if($c(u))continue;let c=Math.abs(o.indent-r);t[c]=~~t[c]+1,r=o.indent}let s=-1,i=2;for(let n=1;n<t.length;n+=1)j1.call(t,n)&&t[n]>s&&(s=t[n],i=n);return this.cachedTabWidth=i}startsWithComment(){if(this.infos.length===0)return!1;let t=this.infos[0],r=t.sliceStart,s=t.sliceEnd,i=t.line.slice(r,s).trim();return i.length===0||i.slice(0,2)==="//"||i.slice(0,2)==="/*"}isOnlyWhitespace(){return $c(this.toString())}isPrecededOnlyByWhitespace(t){let r=this.infos[t.line-1],s=Math.max(r.indent,0),i=t.column-s;if(i<=0)return!0;let n=r.sliceStart,a=Math.min(n+i,r.sliceEnd),o=r.line.slice(n,a);return $c(o)}getLineLength(t){let r=this.infos[t-1];return this.getIndentAt(t)+r.sliceEnd-r.sliceStart}nextPos(t,r=!1){let s=Math.max(t.line,0);return Math.max(t.column,0)<this.getLineLength(s)?(t.column+=1,r?!!this.skipSpaces(t,!1,!0):!0):s<this.length?(t.line+=1,t.column=0,r?!!this.skipSpaces(t,!1,!0):!0):!1}prevPos(t,r=!1){let s=t.line,i=t.column;if(i<1){if(s-=1,s<1)return!1;i=this.getLineLength(s)}else i=Math.min(i-1,this.getLineLength(s));return t.line=s,t.column=i,r?!!this.skipSpaces(t,!0,!0):!0}firstPos(){return{line:1,column:0}}lastPos(){return{line:this.length,column:this.getLineLength(this.length)}}skipSpaces(t,r=!1,s=!1){if(t?t=s?t:{line:t.line,column:t.column}:r?t=this.lastPos():t=this.firstPos(),r){for(;this.prevPos(t);)if(!$c(this.charAt(t))&&this.nextPos(t))return t;return null}else{for(;$c(this.charAt(t));)if(!this.nextPos(t))return null;return t}}trimLeft(){let t=this.skipSpaces(this.firstPos(),!1,!0);return t?this.slice(t):cl}trimRight(){let t=this.skipSpaces(this.lastPos(),!0,!0);return t?this.slice(this.firstPos(),t):cl}trim(){let t=this.skipSpaces(this.firstPos(),!1,!0);if(t===null)return cl;let r=this.skipSpaces(this.lastPos(),!0,!0);return r===null?cl:this.slice(t,r)}eachPos(t,r=this.firstPos(),s=!1){let i=this.firstPos();if(r&&(i.line=r.line,i.column=r.column),!(s&&!this.skipSpaces(i,!1,!0)))do t.call(this,i);while(this.nextPos(i,s))}bootstrapSlice(t,r){let s=this.toString().split($1).slice(t.line-1,r.line);return s.length>0&&(s.push(s.pop().slice(0,r.column)),s[0]=s[0].slice(t.column)),Pe(s.join(`
|
|
@@ -414,11 +414,11 @@ Expected it to be ${s}.`}var o0t=class extends Error{constructor(t){super(a0t(t)
|
|
|
414
414
|
`)?`
|
|
415
415
|
`:`
|
|
416
416
|
|
|
417
|
-
`)+n}var cEt={avoidAstMutation:!0},pEt=[{linguistLanguageId:183,name:"JavaScript",type:"programming",tmScope:"source.js",aceMode:"javascript",codemirrorMode:"javascript",codemirrorMimeType:"text/javascript",color:"#f1e05a",aliases:["js","node"],extensions:[".js","._js",".bones",".cjs",".es",".es6",".frag",".gs",".jake",".javascript",".jsb",".jscad",".jsfl",".jslib",".jsm",".jspre",".jss",".mjs",".njs",".pac",".sjs",".ssjs",".xsjs",".xsjslib",".wxs"],filenames:["Jakefile"],interpreters:["chakra","d8","gjs","js","node","nodejs","qjs","rhino","v8","v8-shell","zx"],parsers:["babel","acorn","espree","meriyah","babel-flow","babel-ts","flow","typescript"],vscodeLanguageIds:["javascript","mongo"]},{linguistLanguageId:183,name:"Flow",type:"programming",tmScope:"source.js",aceMode:"javascript",codemirrorMode:"javascript",codemirrorMimeType:"text/javascript",color:"#f1e05a",aliases:[],extensions:[".js.flow"],filenames:[],interpreters:["chakra","d8","gjs","js","node","nodejs","qjs","rhino","v8","v8-shell"],parsers:["flow","babel-flow"],vscodeLanguageIds:["javascript"]},{linguistLanguageId:183,name:"JSX",type:"programming",tmScope:"source.js.jsx",aceMode:"javascript",codemirrorMode:"jsx",codemirrorMimeType:"text/jsx",color:void 0,aliases:void 0,extensions:[".jsx"],filenames:void 0,interpreters:void 0,parsers:["babel","babel-flow","babel-ts","flow","typescript","espree","meriyah"],vscodeLanguageIds:["javascriptreact"],group:"JavaScript"},{linguistLanguageId:378,name:"TypeScript",type:"programming",color:"#3178c6",aliases:["ts"],interpreters:["deno","ts-node"],extensions:[".ts",".cts",".mts"],tmScope:"source.ts",aceMode:"typescript",codemirrorMode:"javascript",codemirrorMimeType:"application/typescript",parsers:["typescript","babel-ts"],vscodeLanguageIds:["typescript"]},{linguistLanguageId:94901924,name:"TSX",type:"programming",color:"#3178c6",group:"TypeScript",extensions:[".tsx"],tmScope:"source.tsx",aceMode:"javascript",codemirrorMode:"jsx",codemirrorMimeType:"text/jsx",parsers:["typescript","babel-ts"],vscodeLanguageIds:["typescriptreact"]}],pae={};ZS(pae,{getVisitorKeys:()=>mEt,massageAstNode:()=>fae,print:()=>yEt});var fEt={JsonRoot:["node"],ArrayExpression:["elements"],ObjectExpression:["properties"],ObjectProperty:["key","value"],UnaryExpression:["argument"],NullLiteral:[],BooleanLiteral:[],StringLiteral:[],NumericLiteral:[],Identifier:[],TemplateLiteral:["quasis"],TemplateElement:[]},hEt=fEt,dEt=mie(hEt),mEt=dEt;function yEt(e,t,r){let{node:s}=e;switch(s.type){case"JsonRoot":return[r("node"),Me];case"ArrayExpression":{if(s.elements.length===0)return"[]";let i=e.map(()=>e.node===null?"null":r(),"elements");return["[",Ue([Me,hr([",",Me],i)]),Me,"]"]}case"ObjectExpression":return s.properties.length===0?"{}":["{",Ue([Me,hr([",",Me],e.map(r,"properties"))]),Me,"}"];case"ObjectProperty":return[r("key"),": ",r("value")];case"UnaryExpression":return[s.operator==="+"?"":s.operator,r("argument")];case"NullLiteral":return"null";case"BooleanLiteral":return s.value?"true":"false";case"StringLiteral":return JSON.stringify(s.value);case"NumericLiteral":return iie(e)?JSON.stringify(String(s.value)):JSON.stringify(s.value);case"Identifier":return iie(e)?JSON.stringify(s.name):s.name;case"TemplateLiteral":return r(["quasis",0]);case"TemplateElement":return JSON.stringify(s.value.cooked);default:throw new Lf(s,"JSON")}}function iie(e){return e.key==="key"&&e.parent.type==="ObjectProperty"}var gEt=new Set(["start","end","extra","loc","comments","leadingComments","trailingComments","innerComments","errors","range","tokens"]);function fae(e,t){let{type:r}=e;if(r==="ObjectProperty"){let{key:s}=e;s.type==="Identifier"?t.key={type:"StringLiteral",value:s.name}:s.type==="NumericLiteral"&&(t.key={type:"StringLiteral",value:String(s.value)});return}if(r==="UnaryExpression"&&e.operator==="+")return t.argument;if(r==="ArrayExpression"){for(let[s,i]of e.elements.entries())i===null&&t.elements.splice(s,0,{type:"NullLiteral"});return}if(r==="TemplateLiteral")return{type:"StringLiteral",value:e.quasis[0].value.cooked}}fae.ignoredProperties=gEt;var xEt=[{linguistLanguageId:174,name:"JSON.stringify",type:"data",color:"#292929",tmScope:"source.json",aceMode:"json",codemirrorMode:"javascript",codemirrorMimeType:"application/json",aliases:["geojson","jsonl","topojson"],extensions:[".importmap"],filenames:["package.json","package-lock.json","composer.json"],parsers:["json-stringify"],vscodeLanguageIds:["json"]},{linguistLanguageId:174,name:"JSON",type:"data",color:"#292929",tmScope:"source.json",aceMode:"json",codemirrorMode:"javascript",codemirrorMimeType:"application/json",aliases:["geojson","jsonl","topojson"],extensions:[".json",".4DForm",".4DProject",".avsc",".geojson",".gltf",".har",".ice",".JSON-tmLanguage",".mcmeta",".tfstate",".tfstate.backup",".topojson",".webapp",".webmanifest",".yy",".yyp"],filenames:[".all-contributorsrc",".arcconfig",".auto-changelog",".c8rc",".htmlhintrc",".imgbotconfig",".nycrc",".tern-config",".tern-project",".watchmanconfig","Pipfile.lock","composer.lock","flake.lock","mcmod.info"],parsers:["json"],vscodeLanguageIds:["json"]},{linguistLanguageId:423,name:"JSON with Comments",type:"data",color:"#292929",group:"JSON",tmScope:"source.js",aceMode:"javascript",codemirrorMode:"javascript",codemirrorMimeType:"text/javascript",aliases:["jsonc"],extensions:[".jsonc",".code-snippets",".sublime-build",".sublime-commands",".sublime-completions",".sublime-keymap",".sublime-macro",".sublime-menu",".sublime-mousemap",".sublime-project",".sublime-settings",".sublime-theme",".sublime-workspace",".sublime_metrics",".sublime_session"],filenames:[".babelrc",".devcontainer.json",".eslintrc.json",".jscsrc",".jshintrc",".jslintrc",".swcrc","api-extractor.json","devcontainer.json","jsconfig.json","language-configuration.json","tsconfig.json","tslint.json",".eslintrc"],parsers:["json"],vscodeLanguageIds:["jsonc"]},{linguistLanguageId:175,name:"JSON5",type:"data",color:"#267CB9",extensions:[".json5"],tmScope:"source.js",aceMode:"javascript",codemirrorMode:"javascript",codemirrorMimeType:"application/json",parsers:["json5"],vscodeLanguageIds:["json5"]}],JS={bracketSpacing:{category:"Common",type:"boolean",default:!0,description:"Print spaces between brackets.",oppositeDescription:"Do not print spaces between brackets."},singleQuote:{category:"Common",type:"boolean",default:!1,description:"Use single quotes instead of double quotes."},proseWrap:{category:"Common",type:"choice",default:"preserve",description:"How to wrap prose.",choices:[{value:"always",description:"Wrap prose if it exceeds the print width."},{value:"never",description:"Do not wrap prose."},{value:"preserve",description:"Wrap prose as-is."}]},bracketSameLine:{category:"Common",type:"boolean",default:!1,description:"Put > of opening tags on the last line instead of on a new line."},singleAttributePerLine:{category:"Common",type:"boolean",default:!1,description:"Enforce single attribute per line in HTML, Vue and JSX."}},Af="JavaScript",bEt={arrowParens:{category:Af,type:"choice",default:"always",description:"Include parentheses around a sole arrow function parameter.",choices:[{value:"always",description:"Always include parens. Example: `(x) => x`"},{value:"avoid",description:"Omit parens when possible. Example: `x => x`"}]},bracketSameLine:JS.bracketSameLine,bracketSpacing:JS.bracketSpacing,jsxBracketSameLine:{category:Af,type:"boolean",description:"Put > on the last line instead of at a new line.",deprecated:"2.4.0"},semi:{category:Af,type:"boolean",default:!0,description:"Print semicolons.",oppositeDescription:"Do not print semicolons, except at the beginning of lines which may need them."},singleQuote:JS.singleQuote,jsxSingleQuote:{category:Af,type:"boolean",default:!1,description:"Use single quotes in JSX."},quoteProps:{category:Af,type:"choice",default:"as-needed",description:"Change when properties in objects are quoted.",choices:[{value:"as-needed",description:"Only add quotes around object properties where required."},{value:"consistent",description:"If at least one property in an object requires quotes, quote all properties."},{value:"preserve",description:"Respect the input use of quotes in object properties."}]},trailingComma:{category:Af,type:"choice",default:"all",description:"Print trailing commas wherever possible when multi-line.",choices:[{value:"all",description:"Trailing commas wherever possible (including function arguments)."},{value:"es5",description:"Trailing commas where valid in ES5 (objects, arrays, etc.)"},{value:"none",description:"No trailing commas."}]},singleAttributePerLine:JS.singleAttributePerLine},hae=bEt,dae={estree:oie,"estree-json":pae},mae=[...pEt,...xEt],SEt=aie;function gae(e,t={}){let r=!!t.filepath?.match(/\.[jt]sx$/),s=x3(e,{isJSX:r,isTS:!0,printer:"recast",plugins:[["remove-unused-variables",yae.default]]});return BS(s.code,{parser:"babel-ts",plugins:[iN,QN]})}function ZN(e,t={}){return e=e.replaceAll("import.meta","BATI_META"),e=`var BATI_META = ${JSON.stringify(t)};(${e})`,(0,eval)(e)}function EEt(e,t){return(0,Yo.visit)(e,{visitJSXAttribute(r){let s=r.value.comments?.[0];s&&s.value.includes("import.meta.BATI_")&&(ZN(s.value.replace("# ",""),t)?r.get("comments").prune():r.prune()),this.traverse(r)},visitImportDeclaration(r){if(Yo.namedTypes.ImportDeclaration.check(r.value)&&r.value.comments&&r.value.comments.some(s=>s.value.includes("import.meta.BATI_"))){let s=r.value.comments.find(i=>i.value.includes("import.meta.BATI_")).value;ZN(s.replace("# ",""),t)?r.value.comments=[]:r.prune()}this.traverse(r)},visitIdentifier(r){if(r.value.name==="BATI_REMOVE"){if(!r.parent)throw new Error("BATI_REMOVE cannot appear at top level");if(!Yo.namedTypes.ArrayExpression.check(r.parent?.parent?.value))throw new Error("BATI_REMOVE can only be an array element for now");r.parent.prune(),this.traverse(r);return}this.traverse(r)},visitConditionalExpression(r){this.visitIfStatement(r)},visitIfStatement(r){let s=!1;if(this.traverse(r.get("test"),{visitMemberExpression(i){Nn(i.value).code.startsWith("import.meta.BATI_")&&(s=!0),this.traverse(i)}}),this.traverse(r),!!s)if(!ZN(Nn(r.value.test).code,t))r.value.alternate?Yo.namedTypes.BlockStatement.check(r.value.alternate)?r.replace(...r.value.alternate.body):r.replace(r.value.alternate):r.prune();else{let i=r;Yo.namedTypes.ConditionalExpression.check(r.value)&&Yo.namedTypes.JSXExpressionContainer.check(r.parent.value)&&(i=r.parent),Yo.namedTypes.BlockStatement.check(r.value.consequent)?i.replace(...r.value.consequent.body):i.replace(r.value.consequent)}}}),e}function TEt(e,t,r={}){let s=EEt(e,t),i=Nn(s).code;return gae(i,r)}function vEt(e,t){let r="";try{r=B4(e,{import:{meta:t}},{tags:["{{{","}}}"]})}catch(s){throw console.error("SquirrellyJS rendering error:",s.message),s}return r}import{fileURLToPath as AEt}from"url";import{dirname as CEt,join as DEt}from"path";function eF(e,t){if(!e)throw new Error(t)}async function UIt(e){let t=await e?.();return eF(typeof t=="string","Unable to load previous JSON module"),JSON.parse(t)}async function VIt(e){let t=await e?.();return eF(typeof t=="string","Unable to load previous module"),w0(t)}async function JIt(e,t){let r=AEt(t.url),s=CEt(r);return Q1(DEt(s,e))}var XIt=Pn(GE(),1),zIt=Pn(F1(),1);function PEt(e){return xae(e.exports.default)}function wEt(e){if(e.exports.default.$type!=="identifier")throw new Ci(`Not supported: Cannot modify this kind of default export (${e.exports.default.$type})`);let t=e.exports.default.$name;for(let r of e.$ast.body)if(r.type==="VariableDeclaration"){for(let s of r.declarations)if(s.id.type==="Identifier"&&s.id.name===t&&s.init){let i=s.init.type==="TSSatisfiesExpression"?s.init.expression:s.init,n=Nn(i).code,a=Y1(n);return{declaration:s,config:xae(a)}}}throw new Ci("Couldn't find config declaration")}function xae(e){return e.$type==="function-call"?e.$args[0]:e}function IEt(e,t){let r=PEt(e);return r.$type==="identifier"?kEt(e,t):bae(t,r),e.imports.$add({from:t.from,local:t.constructor,imported:t.imported||"default"}),!0}function kEt(e,t){let{config:r,declaration:s}=wEt(e);bae(t,r),s.init&&(s.init.type==="ObjectExpression"?s.init=Nn(r).code:s.init.type==="CallExpression"&&s.init.callee.type==="Identifier"?s.init=Nn(Th.functionCall(s.init.callee.name,r)).code:s.init.type==="TSSatisfiesExpression"&&(s.init.expression.type==="ObjectExpression"&&(s.init.expression=Nn(r).code),s.init.expression.type==="CallExpression"&&s.init.expression.callee.type==="Identifier"&&(s.init.expression=Nn(Th.functionCall(s.init.expression.callee.name,r)).code)))}function bae(e,t){let r=e.index??t.plugins?.length??0;t.plugins||(t.plugins=[]),t.plugins.splice(r,0,e.options?Th.functionCall(e.constructor,e.options):Th.functionCall(e.constructor))}import*as oE from"tty";var{env:el={},argv:Eae=[],platform:NEt=""}=typeof process>"u"?{}:process,FEt="NO_COLOR"in el||Eae.includes("--no-color"),_Et="FORCE_COLOR"in el||Eae.includes("--color"),OEt=NEt==="win32",Tae=el.TERM==="dumb",BEt=oE&&oE.isatty&&oE.isatty(1)&&el.TERM&&!Tae,LEt="CI"in el&&("GITHUB_ACTIONS"in el||"GITLAB_CI"in el||"CIRCLECI"in el),MEt=!FEt&&(_Et||OEt&&!Tae||BEt||LEt),vae=(e,t,r,s,i=t.substring(0,e)+s,n=t.substring(e+r.length),a=n.indexOf(r))=>i+(a<0?n:vae(a,n,r,s)),REt=(e,t,r,s,i)=>e<0?r+t+s:r+vae(e,t,s,i)+s,jEt=(e,t,r=e,s=e.length+1)=>i=>i||!(i===""||i===void 0)?REt((""+i).indexOf(t,s),i,e,t,r):"",Vt=(e,t,r)=>jEt(`\x1B[${e}m`,`\x1B[${t}m`,r),Sae={reset:Vt(0,0),bold:Vt(1,22,"\x1B[22m\x1B[1m"),dim:Vt(2,22,"\x1B[22m\x1B[2m"),italic:Vt(3,23),underline:Vt(4,24),inverse:Vt(7,27),hidden:Vt(8,28),strikethrough:Vt(9,29),black:Vt(30,39),red:Vt(31,39),green:Vt(32,39),yellow:Vt(33,39),blue:Vt(34,39),magenta:Vt(35,39),cyan:Vt(36,39),white:Vt(37,39),gray:Vt(90,39),bgBlack:Vt(40,49),bgRed:Vt(41,49),bgGreen:Vt(42,49),bgYellow:Vt(43,49),bgBlue:Vt(44,49),bgMagenta:Vt(45,49),bgCyan:Vt(46,49),bgWhite:Vt(47,49),blackBright:Vt(90,39),redBright:Vt(91,39),greenBright:Vt(92,39),yellowBright:Vt(93,39),blueBright:Vt(94,39),magentaBright:Vt(95,39),cyanBright:Vt(96,39),whiteBright:Vt(97,39),bgBlackBright:Vt(100,49),bgRedBright:Vt(101,49),bgGreenBright:Vt(102,49),bgYellowBright:Vt(103,49),bgBlueBright:Vt(104,49),bgMagentaBright:Vt(105,49),bgCyanBright:Vt(106,49),bgWhiteBright:Vt(107,49)},$Et=({useColor:e=MEt}={})=>e?Sae:Object.keys(Sae).reduce((t,r)=>({...t,[r]:String}),{}),{reset:ZIt,bold:ekt,dim:tF,italic:tkt,underline:rkt,inverse:skt,hidden:ikt,strikethrough:nkt,black:akt,red:okt,green:ukt,yellow:Aae,blue:lkt,magenta:ckt,cyan:pkt,white:fkt,gray:hkt,bgBlack:dkt,bgRed:mkt,bgGreen:ykt,bgYellow:gkt,bgBlue:xkt,bgMagenta:bkt,bgCyan:Skt,bgWhite:Ekt,blackBright:Tkt,redBright:vkt,greenBright:Akt,yellowBright:Ckt,blueBright:Dkt,magentaBright:Pkt,cyanBright:wkt,whiteBright:Ikt,bgBlackBright:kkt,bgRedBright:Nkt,bgGreenBright:Fkt,bgYellowBright:_kt,bgBlueBright:Okt,bgMagentaBright:Bkt,bgCyanBright:Lkt,bgWhiteBright:Mkt}=$Et();function Cae(e,t,r=0){let s=`${" ".repeat(r*2)}${t?t(e):e}`;return i=>`${s} ${i}`}function*qEt(e){if(e.devDependencies)for(let t in e.devDependencies)yield[t,e.devDependencies[t]];if(e.dependencies)for(let t in e.dependencies)yield[t,e.dependencies[t]]}function*Dae(e,t){for(let r of t){let s=e.get(r);if(!s)throw new Error(`key '${s}' not found in package.json`);yield[r,s]}}function Ukt(e,t,r){e.devDependencies??(e.devDependencies={}),e.dependencies??(e.dependencies={});let s=new Map(qEt(t));for(let[i,n]of Dae(s,r.devDependencies??[]))i in e.dependencies||(e.devDependencies[i]=n);for(let[i,n]of Dae(s,r.dependencies??[]))i in e.devDependencies&&delete e.devDependencies[i],e.dependencies[i]=n;return e}var Pae={dev:{precedence:-1/0},build:{precedence:-1/0},preview:{precedence:-1/0}};function wae(e,t,r){console.warn(Cae("\u26A0",Aae)(`Possible conflict between flags for "package.json":
|
|
417
|
+
`)+n}var cEt={avoidAstMutation:!0},pEt=[{linguistLanguageId:183,name:"JavaScript",type:"programming",tmScope:"source.js",aceMode:"javascript",codemirrorMode:"javascript",codemirrorMimeType:"text/javascript",color:"#f1e05a",aliases:["js","node"],extensions:[".js","._js",".bones",".cjs",".es",".es6",".frag",".gs",".jake",".javascript",".jsb",".jscad",".jsfl",".jslib",".jsm",".jspre",".jss",".mjs",".njs",".pac",".sjs",".ssjs",".xsjs",".xsjslib",".wxs"],filenames:["Jakefile"],interpreters:["chakra","d8","gjs","js","node","nodejs","qjs","rhino","v8","v8-shell","zx"],parsers:["babel","acorn","espree","meriyah","babel-flow","babel-ts","flow","typescript"],vscodeLanguageIds:["javascript","mongo"]},{linguistLanguageId:183,name:"Flow",type:"programming",tmScope:"source.js",aceMode:"javascript",codemirrorMode:"javascript",codemirrorMimeType:"text/javascript",color:"#f1e05a",aliases:[],extensions:[".js.flow"],filenames:[],interpreters:["chakra","d8","gjs","js","node","nodejs","qjs","rhino","v8","v8-shell"],parsers:["flow","babel-flow"],vscodeLanguageIds:["javascript"]},{linguistLanguageId:183,name:"JSX",type:"programming",tmScope:"source.js.jsx",aceMode:"javascript",codemirrorMode:"jsx",codemirrorMimeType:"text/jsx",color:void 0,aliases:void 0,extensions:[".jsx"],filenames:void 0,interpreters:void 0,parsers:["babel","babel-flow","babel-ts","flow","typescript","espree","meriyah"],vscodeLanguageIds:["javascriptreact"],group:"JavaScript"},{linguistLanguageId:378,name:"TypeScript",type:"programming",color:"#3178c6",aliases:["ts"],interpreters:["deno","ts-node"],extensions:[".ts",".cts",".mts"],tmScope:"source.ts",aceMode:"typescript",codemirrorMode:"javascript",codemirrorMimeType:"application/typescript",parsers:["typescript","babel-ts"],vscodeLanguageIds:["typescript"]},{linguistLanguageId:94901924,name:"TSX",type:"programming",color:"#3178c6",group:"TypeScript",extensions:[".tsx"],tmScope:"source.tsx",aceMode:"javascript",codemirrorMode:"jsx",codemirrorMimeType:"text/jsx",parsers:["typescript","babel-ts"],vscodeLanguageIds:["typescriptreact"]}],pae={};ZS(pae,{getVisitorKeys:()=>mEt,massageAstNode:()=>fae,print:()=>yEt});var fEt={JsonRoot:["node"],ArrayExpression:["elements"],ObjectExpression:["properties"],ObjectProperty:["key","value"],UnaryExpression:["argument"],NullLiteral:[],BooleanLiteral:[],StringLiteral:[],NumericLiteral:[],Identifier:[],TemplateLiteral:["quasis"],TemplateElement:[]},hEt=fEt,dEt=mie(hEt),mEt=dEt;function yEt(e,t,r){let{node:s}=e;switch(s.type){case"JsonRoot":return[r("node"),Me];case"ArrayExpression":{if(s.elements.length===0)return"[]";let i=e.map(()=>e.node===null?"null":r(),"elements");return["[",Ue([Me,hr([",",Me],i)]),Me,"]"]}case"ObjectExpression":return s.properties.length===0?"{}":["{",Ue([Me,hr([",",Me],e.map(r,"properties"))]),Me,"}"];case"ObjectProperty":return[r("key"),": ",r("value")];case"UnaryExpression":return[s.operator==="+"?"":s.operator,r("argument")];case"NullLiteral":return"null";case"BooleanLiteral":return s.value?"true":"false";case"StringLiteral":return JSON.stringify(s.value);case"NumericLiteral":return iie(e)?JSON.stringify(String(s.value)):JSON.stringify(s.value);case"Identifier":return iie(e)?JSON.stringify(s.name):s.name;case"TemplateLiteral":return r(["quasis",0]);case"TemplateElement":return JSON.stringify(s.value.cooked);default:throw new Lf(s,"JSON")}}function iie(e){return e.key==="key"&&e.parent.type==="ObjectProperty"}var gEt=new Set(["start","end","extra","loc","comments","leadingComments","trailingComments","innerComments","errors","range","tokens"]);function fae(e,t){let{type:r}=e;if(r==="ObjectProperty"){let{key:s}=e;s.type==="Identifier"?t.key={type:"StringLiteral",value:s.name}:s.type==="NumericLiteral"&&(t.key={type:"StringLiteral",value:String(s.value)});return}if(r==="UnaryExpression"&&e.operator==="+")return t.argument;if(r==="ArrayExpression"){for(let[s,i]of e.elements.entries())i===null&&t.elements.splice(s,0,{type:"NullLiteral"});return}if(r==="TemplateLiteral")return{type:"StringLiteral",value:e.quasis[0].value.cooked}}fae.ignoredProperties=gEt;var xEt=[{linguistLanguageId:174,name:"JSON.stringify",type:"data",color:"#292929",tmScope:"source.json",aceMode:"json",codemirrorMode:"javascript",codemirrorMimeType:"application/json",aliases:["geojson","jsonl","topojson"],extensions:[".importmap"],filenames:["package.json","package-lock.json","composer.json"],parsers:["json-stringify"],vscodeLanguageIds:["json"]},{linguistLanguageId:174,name:"JSON",type:"data",color:"#292929",tmScope:"source.json",aceMode:"json",codemirrorMode:"javascript",codemirrorMimeType:"application/json",aliases:["geojson","jsonl","topojson"],extensions:[".json",".4DForm",".4DProject",".avsc",".geojson",".gltf",".har",".ice",".JSON-tmLanguage",".mcmeta",".tfstate",".tfstate.backup",".topojson",".webapp",".webmanifest",".yy",".yyp"],filenames:[".all-contributorsrc",".arcconfig",".auto-changelog",".c8rc",".htmlhintrc",".imgbotconfig",".nycrc",".tern-config",".tern-project",".watchmanconfig","Pipfile.lock","composer.lock","flake.lock","mcmod.info"],parsers:["json"],vscodeLanguageIds:["json"]},{linguistLanguageId:423,name:"JSON with Comments",type:"data",color:"#292929",group:"JSON",tmScope:"source.js",aceMode:"javascript",codemirrorMode:"javascript",codemirrorMimeType:"text/javascript",aliases:["jsonc"],extensions:[".jsonc",".code-snippets",".sublime-build",".sublime-commands",".sublime-completions",".sublime-keymap",".sublime-macro",".sublime-menu",".sublime-mousemap",".sublime-project",".sublime-settings",".sublime-theme",".sublime-workspace",".sublime_metrics",".sublime_session"],filenames:[".babelrc",".devcontainer.json",".eslintrc.json",".jscsrc",".jshintrc",".jslintrc",".swcrc","api-extractor.json","devcontainer.json","jsconfig.json","language-configuration.json","tsconfig.json","tslint.json",".eslintrc"],parsers:["json"],vscodeLanguageIds:["jsonc"]},{linguistLanguageId:175,name:"JSON5",type:"data",color:"#267CB9",extensions:[".json5"],tmScope:"source.js",aceMode:"javascript",codemirrorMode:"javascript",codemirrorMimeType:"application/json",parsers:["json5"],vscodeLanguageIds:["json5"]}],JS={bracketSpacing:{category:"Common",type:"boolean",default:!0,description:"Print spaces between brackets.",oppositeDescription:"Do not print spaces between brackets."},singleQuote:{category:"Common",type:"boolean",default:!1,description:"Use single quotes instead of double quotes."},proseWrap:{category:"Common",type:"choice",default:"preserve",description:"How to wrap prose.",choices:[{value:"always",description:"Wrap prose if it exceeds the print width."},{value:"never",description:"Do not wrap prose."},{value:"preserve",description:"Wrap prose as-is."}]},bracketSameLine:{category:"Common",type:"boolean",default:!1,description:"Put > of opening tags on the last line instead of on a new line."},singleAttributePerLine:{category:"Common",type:"boolean",default:!1,description:"Enforce single attribute per line in HTML, Vue and JSX."}},Af="JavaScript",bEt={arrowParens:{category:Af,type:"choice",default:"always",description:"Include parentheses around a sole arrow function parameter.",choices:[{value:"always",description:"Always include parens. Example: `(x) => x`"},{value:"avoid",description:"Omit parens when possible. Example: `x => x`"}]},bracketSameLine:JS.bracketSameLine,bracketSpacing:JS.bracketSpacing,jsxBracketSameLine:{category:Af,type:"boolean",description:"Put > on the last line instead of at a new line.",deprecated:"2.4.0"},semi:{category:Af,type:"boolean",default:!0,description:"Print semicolons.",oppositeDescription:"Do not print semicolons, except at the beginning of lines which may need them."},singleQuote:JS.singleQuote,jsxSingleQuote:{category:Af,type:"boolean",default:!1,description:"Use single quotes in JSX."},quoteProps:{category:Af,type:"choice",default:"as-needed",description:"Change when properties in objects are quoted.",choices:[{value:"as-needed",description:"Only add quotes around object properties where required."},{value:"consistent",description:"If at least one property in an object requires quotes, quote all properties."},{value:"preserve",description:"Respect the input use of quotes in object properties."}]},trailingComma:{category:Af,type:"choice",default:"all",description:"Print trailing commas wherever possible when multi-line.",choices:[{value:"all",description:"Trailing commas wherever possible (including function arguments)."},{value:"es5",description:"Trailing commas where valid in ES5 (objects, arrays, etc.)"},{value:"none",description:"No trailing commas."}]},singleAttributePerLine:JS.singleAttributePerLine},hae=bEt,dae={estree:oie,"estree-json":pae},mae=[...pEt,...xEt],SEt=aie;function gae(e,t={}){let r=!!t.filepath?.match(/\.[jt]sx$/),s=x3(e,{isJSX:r,isTS:!0,printer:"recast",plugins:[["remove-unused-variables",yae.default]]});return BS(s.code,{parser:"babel-ts",plugins:[iN,QN]})}function ZN(e,t={}){return e=e.replaceAll("import.meta","BATI_META"),e=`var BATI_META = ${JSON.stringify(t)};(${e})`,(0,eval)(e)}function EEt(e,t){return(0,Yo.visit)(e,{visitJSXAttribute(r){let s=r.value.comments?.[0];s&&s.value.includes("import.meta.BATI_")&&(ZN(s.value.replace("# ",""),t)?r.get("comments").prune():r.prune()),this.traverse(r)},visitImportDeclaration(r){if(Yo.namedTypes.ImportDeclaration.check(r.value)&&r.value.comments&&r.value.comments.some(s=>s.value.includes("import.meta.BATI_"))){let s=r.value.comments.find(i=>i.value.includes("import.meta.BATI_")).value;ZN(s.replace("# ",""),t)?r.value.comments=[]:r.prune()}this.traverse(r)},visitIdentifier(r){if(r.value.name==="BATI_REMOVE"){if(!r.parent)throw new Error("BATI_REMOVE cannot appear at top level");if(!Yo.namedTypes.ArrayExpression.check(r.parent?.parent?.value))throw new Error("BATI_REMOVE can only be an array element for now");r.parent.prune(),this.traverse(r);return}this.traverse(r)},visitConditionalExpression(r){this.visitIfStatement(r)},visitIfStatement(r){let s=!1;if(this.traverse(r.get("test"),{visitMemberExpression(i){Nn(i.value).code.startsWith("import.meta.BATI_")&&(s=!0),this.traverse(i)}}),this.traverse(r),!!s)if(!ZN(Nn(r.value.test).code,t))r.value.alternate?Yo.namedTypes.BlockStatement.check(r.value.alternate)?r.replace(...r.value.alternate.body):r.replace(r.value.alternate):r.prune();else{let i=r;Yo.namedTypes.ConditionalExpression.check(r.value)&&Yo.namedTypes.JSXExpressionContainer.check(r.parent.value)&&(i=r.parent),Yo.namedTypes.BlockStatement.check(r.value.consequent)?i.replace(...r.value.consequent.body):i.replace(r.value.consequent)}}}),e}function TEt(e,t,r={}){let s=EEt(e,t),i=Nn(s).code;return gae(i,r)}function vEt(e,t){let r="";try{r=B4(e,{import:{meta:t}},{tags:["{{{","}}}"]})}catch(s){throw console.error("SquirrellyJS rendering error:",s.message),s}return r}import{dirname as AEt,join as CEt}from"path";import{fileURLToPath as DEt}from"url";function eF(e,t){if(!e)throw new Error(t)}async function UIt({readfile:e,source:t,target:r}){let s=await e?.();return eF(typeof s=="string",`Unable to load previous JSON module ("${t}" -> "${r}")`),JSON.parse(s)}async function VIt({readfile:e,source:t,target:r}){let s=await e?.();return eF(typeof s=="string",`Unable to load previous module ("${t}" -> "${r}")`),w0(s)}async function JIt(e,t){let r=DEt(t.url),s=AEt(r);return Q1(CEt(s,e))}var XIt=Pn(GE(),1),zIt=Pn(F1(),1);function PEt(e){return xae(e.exports.default)}function wEt(e){if(e.exports.default.$type!=="identifier")throw new Ci(`Not supported: Cannot modify this kind of default export (${e.exports.default.$type})`);let t=e.exports.default.$name;for(let r of e.$ast.body)if(r.type==="VariableDeclaration"){for(let s of r.declarations)if(s.id.type==="Identifier"&&s.id.name===t&&s.init){let i=s.init.type==="TSSatisfiesExpression"?s.init.expression:s.init,n=Nn(i).code,a=Y1(n);return{declaration:s,config:xae(a)}}}throw new Ci("Couldn't find config declaration")}function xae(e){return e.$type==="function-call"?e.$args[0]:e}function IEt(e,t){let r=PEt(e);return r.$type==="identifier"?kEt(e,t):bae(t,r),e.imports.$add({from:t.from,local:t.constructor,imported:t.imported||"default"}),!0}function kEt(e,t){let{config:r,declaration:s}=wEt(e);bae(t,r),s.init&&(s.init.type==="ObjectExpression"?s.init=Nn(r).code:s.init.type==="CallExpression"&&s.init.callee.type==="Identifier"?s.init=Nn(Th.functionCall(s.init.callee.name,r)).code:s.init.type==="TSSatisfiesExpression"&&(s.init.expression.type==="ObjectExpression"&&(s.init.expression=Nn(r).code),s.init.expression.type==="CallExpression"&&s.init.expression.callee.type==="Identifier"&&(s.init.expression=Nn(Th.functionCall(s.init.expression.callee.name,r)).code)))}function bae(e,t){let r=e.index??t.plugins?.length??0;t.plugins||(t.plugins=[]),t.plugins.splice(r,0,e.options?Th.functionCall(e.constructor,e.options):Th.functionCall(e.constructor))}import*as oE from"tty";var{env:el={},argv:Eae=[],platform:NEt=""}=typeof process>"u"?{}:process,FEt="NO_COLOR"in el||Eae.includes("--no-color"),_Et="FORCE_COLOR"in el||Eae.includes("--color"),OEt=NEt==="win32",Tae=el.TERM==="dumb",BEt=oE&&oE.isatty&&oE.isatty(1)&&el.TERM&&!Tae,LEt="CI"in el&&("GITHUB_ACTIONS"in el||"GITLAB_CI"in el||"CIRCLECI"in el),MEt=!FEt&&(_Et||OEt&&!Tae||BEt||LEt),vae=(e,t,r,s,i=t.substring(0,e)+s,n=t.substring(e+r.length),a=n.indexOf(r))=>i+(a<0?n:vae(a,n,r,s)),REt=(e,t,r,s,i)=>e<0?r+t+s:r+vae(e,t,s,i)+s,jEt=(e,t,r=e,s=e.length+1)=>i=>i||!(i===""||i===void 0)?REt((""+i).indexOf(t,s),i,e,t,r):"",Vt=(e,t,r)=>jEt(`\x1B[${e}m`,`\x1B[${t}m`,r),Sae={reset:Vt(0,0),bold:Vt(1,22,"\x1B[22m\x1B[1m"),dim:Vt(2,22,"\x1B[22m\x1B[2m"),italic:Vt(3,23),underline:Vt(4,24),inverse:Vt(7,27),hidden:Vt(8,28),strikethrough:Vt(9,29),black:Vt(30,39),red:Vt(31,39),green:Vt(32,39),yellow:Vt(33,39),blue:Vt(34,39),magenta:Vt(35,39),cyan:Vt(36,39),white:Vt(37,39),gray:Vt(90,39),bgBlack:Vt(40,49),bgRed:Vt(41,49),bgGreen:Vt(42,49),bgYellow:Vt(43,49),bgBlue:Vt(44,49),bgMagenta:Vt(45,49),bgCyan:Vt(46,49),bgWhite:Vt(47,49),blackBright:Vt(90,39),redBright:Vt(91,39),greenBright:Vt(92,39),yellowBright:Vt(93,39),blueBright:Vt(94,39),magentaBright:Vt(95,39),cyanBright:Vt(96,39),whiteBright:Vt(97,39),bgBlackBright:Vt(100,49),bgRedBright:Vt(101,49),bgGreenBright:Vt(102,49),bgYellowBright:Vt(103,49),bgBlueBright:Vt(104,49),bgMagentaBright:Vt(105,49),bgCyanBright:Vt(106,49),bgWhiteBright:Vt(107,49)},$Et=({useColor:e=MEt}={})=>e?Sae:Object.keys(Sae).reduce((t,r)=>({...t,[r]:String}),{}),{reset:ZIt,bold:ekt,dim:tF,italic:tkt,underline:rkt,inverse:skt,hidden:ikt,strikethrough:nkt,black:akt,red:okt,green:ukt,yellow:Aae,blue:lkt,magenta:ckt,cyan:pkt,white:fkt,gray:hkt,bgBlack:dkt,bgRed:mkt,bgGreen:ykt,bgYellow:gkt,bgBlue:xkt,bgMagenta:bkt,bgCyan:Skt,bgWhite:Ekt,blackBright:Tkt,redBright:vkt,greenBright:Akt,yellowBright:Ckt,blueBright:Dkt,magentaBright:Pkt,cyanBright:wkt,whiteBright:Ikt,bgBlackBright:kkt,bgRedBright:Nkt,bgGreenBright:Fkt,bgYellowBright:_kt,bgBlueBright:Okt,bgMagentaBright:Bkt,bgCyanBright:Lkt,bgWhiteBright:Mkt}=$Et();function Cae(e,t,r=0){let s=`${" ".repeat(r*2)}${t?t(e):e}`;return i=>`${s} ${i}`}function*qEt(e){if(e.devDependencies)for(let t in e.devDependencies)yield[t,e.devDependencies[t]];if(e.dependencies)for(let t in e.dependencies)yield[t,e.dependencies[t]]}function*Dae(e,t){for(let r of t){let s=e.get(r);if(!s)throw new Error(`key '${s}' not found in package.json`);yield[r,s]}}function Ukt(e,t,r){e.devDependencies??(e.devDependencies={}),e.dependencies??(e.dependencies={});let s=new Map(qEt(t));for(let[i,n]of Dae(s,r.devDependencies??[]))i in e.dependencies||(e.devDependencies[i]=n);for(let[i,n]of Dae(s,r.dependencies??[]))i in e.devDependencies&&delete e.devDependencies[i],e.dependencies[i]=n;return e}var Pae={dev:{precedence:-1/0},build:{precedence:-1/0},preview:{precedence:-1/0},lint:{precedence:-1/0}};function wae(e,t,r){console.warn(Cae("\u26A0",Aae)(`Possible conflict between flags for "package.json":
|
|
418
418
|
Old \`scripts.${e}\`: ${tF(t)}
|
|
419
419
|
New \`scripts.${e}\`: ${tF(r)}
|
|
420
420
|
You can check https://batijs.github.io for more details.
|
|
421
|
-
`))}function Vkt(e,t){let r=["dev","build","preview"];for(let s of r){let i=Pae[s],n=t[s];n&&(n.precedence>i.precedence?(i.warnIfReplaced&&wae(s,i.value,n.value),e.scripts[s]=n.value,Pae[s]=n):n.warnIfReplaced&&wae(s,n.value,i.value))}return e}var o1t=Pn(Gae(),1);var export_which=o1t.default;export{Ukt as addDependency,IEt as addVitePlugin,Foe as features,l1t as flags,Nn as generateCode,UIt as loadAsJson,VIt as loadAsMagicast,Q1 as loadFile,JIt as loadRelativeFileAsMagicast,w0 as parseModule,vEt as renderSquirrelly,Vkt as setScripts,TEt as transformAstAndGenerate,export_which as which,Cae as withIcon};
|
|
421
|
+
`))}function Vkt(e,t){let r=["dev","build","preview","lint"];for(let s of r){let i=Pae[s],n=t[s];n&&(n.precedence>i.precedence?(i.warnIfReplaced&&wae(s,i.value,n.value),e.scripts[s]=n.value,Pae[s]=n):n.warnIfReplaced&&wae(s,n.value,i.value))}return e}var o1t=Pn(Gae(),1);var export_which=o1t.default;export{Ukt as addDependency,IEt as addVitePlugin,Foe as features,l1t as flags,Nn as generateCode,UIt as loadAsJson,VIt as loadAsMagicast,Q1 as loadFile,JIt as loadRelativeFileAsMagicast,w0 as parseModule,vEt as renderSquirrelly,Vkt as setScripts,TEt as transformAstAndGenerate,export_which as which,Cae as withIcon};
|
|
422
422
|
/*! Bundled license information:
|
|
423
423
|
|
|
424
424
|
uri-js/dist/es5/uri.all.js:
|
package/dist/rules.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ declare enum RulesMessage {
|
|
|
3
3
|
INFO_HATTIP = 1
|
|
4
4
|
}
|
|
5
5
|
|
|
6
|
-
declare const features: readonly ["framework:solid", "framework:react", "framework:vue", "db:edgedb", "db:prisma", "auth:authjs", "rpc:telefunc", "server:hattip", "server:express", "server:h3", "uikit:tailwindcss", "analytics:plausible.io", "hosting:vercel"];
|
|
6
|
+
declare const features: readonly ["framework:solid", "framework:react", "framework:vue", "db:edgedb", "db:prisma", "auth:authjs", "rpc:telefunc", "server:hattip", "server:express", "server:h3", "uikit:tailwindcss", "analytics:plausible.io", "hosting:vercel", "tool:eslint"];
|
|
7
7
|
type BeforeColon<T extends string> = T extends `${infer A}:${string}` ? A : never;
|
|
8
8
|
type Namespaces = BeforeColon<(typeof features)[number]>;
|
|
9
9
|
|