@unocss/inspector 0.45.30 → 0.46.0
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/client/assets/_id_.bebfe424.js +1 -0
- package/dist/client/assets/{index.0273a1ac.js → index.5bce7f8c.js} +1 -1
- package/dist/client/assets/{repl.62435d96.js → repl.aa376791.js} +1 -1
- package/dist/client/index.html +1 -1
- package/package.json +1 -1
- package/dist/client/assets/_id_.226316e8.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{s as k,t as I,d as M,x as O,y as W,r as C,u as D,z as U,A as Z,B as j,i as u,c as R,e as g,w as A,g as f,C as w,_ as q,o as E,k as S,D as V,E as N,n as P,h as G,v as H,F as K,G as J,m as L,l as Q,q as X,H as Y}from"./index.5bce7f8c.js";const tt=t=>[...new Set(t.split(/\\?[\s'"`;={}]+/g))].filter(k),et={name:"split",order:0,extract({code:t}){return tt(t)}},B=/^(?!.*\[(?:[^:]+):(?:.+)\]$)((?:.+:)?!?)?(.*)$/,st=(t={})=>{var i,h,d;const a=(i=t.prefix)!=null?i:"un-",c=(h=t.prefixedOnly)!=null?h:!1,_=(d=t.trueToNonValued)!=null?d:!1;return{name:"attributify",match(r){const o=I(r);if(!o)return;let e=o[1];if(e.startsWith(a))e=e.slice(a.length);else if(c)return;const p=o[2],[,l="",s=p]=p.match(B)||[];return s==="~"||_&&s==="true"||!s?`${l}${e}`:`${l}${e}-${s}`}}},lt=/(<\w[\w:\.$-]*\s)((?:'[^>]*?'|"[^>]*?"|`[^>]*?`|\{[^>]*?\}|[^>]*?)*)/g,rt=/([?]|(?!\d|-{2}|-\d)[a-zA-Z0-9\u00A0-\uFFFF-_:%-]+)(?:=("[^"]*|'[^']*))?/g,z=/[\s'"`;>]+/,nt={name:"attributify",extract:({content:t,cursor:a})=>{const c=t.matchAll(lt);let _,i=0;for(const n of c){const[,x,y]=n,b=n.index+x.length;if(a>b&&a<=b+y.length){i=b,_=y;break}}if(!_)return null;const h=_.matchAll(rt);let d=0,r,o;for(const n of h){const[x,y,b]=n,$=i+n.index;if(a>$&&a<=$+x.length){d=$,r=y,o=b==null?void 0:b.slice(1);break}}if(!r||r==="class"||r==="className"||r===":class")return null;if(o===void 0)return{extracted:r,resolveReplacement(n){return{start:d,end:d+r.length,replacement:n}}};const e=d+r.length+2;let p=z.exec(o),l=0,s;for(;p;){const[n]=p;if(a>e+l&&a<=e+l+p.index){s=o.slice(l,l+p.index);break}l+=p.index+n.length,p=z.exec(o.slice(l))}s===void 0&&(s=o.slice(l));const[,m="",v]=s.match(B)||[];return{extracted:`${m}${r}-${v}`,transformSuggestions(n){return n.filter(x=>x.startsWith(`${m}${r}-`)).map(x=>m+x.slice(m.length+r.length+1))},resolveReplacement(n){return{start:l+e,end:l+e+s.length,replacement:m+n.slice(m.length+r.length+1)}}}}},at=["v-bind:",":"],F=/[\s'"`;]+/g,ct=/<\w(?=.*>)[\w:\.$-]*\s((?:['"`\{].*?['"`\}]|.*?)*?)>/gs,ot=/([?]|(?!\d|-{2}|-\d)[a-zA-Z0-9\u00A0-\uFFFF-_:!%-]+)(?:={?(["'])([^\2]*?)\2}?)?/g,T=["placeholder"],it=t=>{var i,h,d;const a=(i=t==null?void 0:t.ignoreAttributes)!=null?i:T,c=(h=t==null?void 0:t.nonValuedAttribute)!=null?h:!0,_=(d=t==null?void 0:t.trueToNonValued)!=null?d:!1;return{name:"attributify",extract({code:r}){const o=Array.from(r.matchAll(ct)).flatMap(e=>Array.from((e[1]||"").matchAll(ot))).flatMap(([,e,p,l])=>{if(a.includes(e))return[];for(const s of at)if(e.startsWith(s)){e=e.slice(s.length);break}if(!l){if(k(e)&&c!==!1){const s=[`[${e}=""]`];return _&&s.push(`[${e}="true"]`),s}return[]}return["class","className"].includes(e)?l.split(F).filter(k):l.split(F).filter(Boolean).map(s=>`[${e}~="${s}"]`)});return new Set(o)}}},ut=(t={})=>{var i,h,d,r,o;t.strict=(i=t.strict)!=null?i:!1,t.prefix=(h=t.prefix)!=null?h:"un-",t.prefixedOnly=(d=t.prefixedOnly)!=null?d:!1,t.nonValuedAttribute=(r=t.nonValuedAttribute)!=null?r:!0,t.ignoreAttributes=(o=t.ignoreAttributes)!=null?o:T;const a=[st(t)],c=[it(t)],_=[nt];return t.strict||c.unshift(et),{name:"@unocss/preset-attributify",variants:a,extractors:c,options:t,autocomplete:{extractors:_}}},dt={key:0,"h-full":"","of-hidden":""},ft=f("div",{op50:""}," Module ",-1),mt=f("div",{"i-carbon-launch":""},null,-1),ht=f("div",{op50:""}," Matched Rules ",-1),_t=f("div",{op50:""}," CSS Size ",-1),pt=f("span",{op50:""},"gzipped",-1),xt={key:0,"row-span-3":""},yt=f("div",{op50:""}," Potentially Unmatched ",-1),vt={"h-full":"","of-hidden":""},gt=M({__name:"ModuleInfo",props:{id:null},setup(t){const a=t,{data:c}=O(W(a,"id")),_=a.id.split(/\./g).pop(),i=C(null),h=D(i,"module-scrolls");function d(){fetch(`/__open-in-editor?file=${encodeURIComponent(a.id)}`)}const{extractors:r}=ut({strict:!0}),o=U(async()=>{var s;const l=new Set;if(r){const m={code:((s=c.value)==null?void 0:s.code)||""};for(const v of r){const n=await v.extract(m);n==null||n.forEach(x=>l.add(x))}}return Array.from(l).filter(m=>!m.startsWith("[")).filter(m=>{var v;return!((v=c.value)!=null&&v.matched.includes(m))})}),e=C(!1),p=Z(j(()=>{var l;return(l=c.value)==null?void 0:l.css}),e);return(l,s)=>{const m=J,v=q,n=L,x=Q;return u(c)?(E(),R("div",dt,[g(v,{ref_key:"status",ref:i,grid:"~ cols-3 gap-4"},{default:A(()=>{var y;return[f("div",null,[ft,f("a",{"cursor-pointer":"",op80:"","hover:op100":"",onClick:d},[g(m,{id:u(c).id,"mr-1":""},null,8,["id"]),mt])]),f("div",null,[ht,S(" "+V(u(c).matched.length),1)]),f("div",null,[_t,S(" "+V(((((y=u(c))==null?void 0:y.gzipSize)||0)/1024).toFixed(2))+" KiB ",1),pt]),u(o).length?(E(),R("div",xt,[yt,f("code",null,V(u(o).join(", ")),1)])):w("",!0)]}),_:1},512),f("div",vt,[g(u(K),null,{default:A(()=>[g(u(N),{size:"50"},{default:A(()=>[g(n,{"h-full":"","model-value":u(c).code,"read-only":!0,mode:u(_),matched:u(c).matched,class:"scrolls module-scrolls",style:P(u(h))},null,8,["model-value","mode","matched","style"])]),_:1}),g(u(N),{size:"50"},{default:A(()=>[f("div",null,[g(x,{border:"l b gray-400/20",title:"Output CSS"},{default:A(()=>[f("label",null,[G(f("input",{"onUpdate:modelValue":s[0]||(s[0]=y=>e.value=y),type:"checkbox"},null,512),[[H,e.value]]),S(" Prettify ")])]),_:1}),g(n,{"h-full":"",b:"l main","model-value":u(p),"read-only":!0,mode:"css",class:"scrolls module-scrolls",style:P(u(h))},null,8,["model-value","style"])])]),_:1})]),_:1})])])):w("",!0)}}}),At=M({__name:"[id]",setup(t){const a=Y();return(c,_)=>{const i=gt;return E(),X(i,{id:u(a).params.id},null,8,["id"])}}});export{At as default};
|
|
@@ -275,7 +275,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
275
275
|
`),cooked:y===null?null:y.slice(1,At)},he.tail=Ye,this.next(),this.finishNode(he,"TemplateElement"),this.resetEndLocation(he,pn(this.state.lastTokEndLoc,At)),he}parseTemplate(i){let t=this.startNode();t.expressions=[];let o=this.parseTemplateElement(i);for(t.quasis=[o];!o.tail;)t.expressions.push(this.parseTemplateSubstitution()),this.readTemplateContinuation(),t.quasis.push(o=this.parseTemplateElement(i));return this.finishNode(t,"TemplateLiteral")}parseTemplateSubstitution(){return this.parseExpression()}parseObjectLike(i,t,o,p){o&&this.expectPlugin("recordAndTuple");let y=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!1;let $=Object.create(null),he=!0,Ye=this.startNode();for(Ye.properties=[],this.next();!this.match(i);){if(he)he=!1;else if(this.expect(12),this.match(i)){this.addTrailingCommaExtraToNode(Ye);break}let ar;t?ar=this.parseBindingProperty():(ar=this.parsePropertyDefinition(p),this.checkProto(ar,o,$,p)),o&&!this.isObjectProperty(ar)&&ar.type!=="SpreadElement"&&this.raise(dt.InvalidRecordProperty,{at:ar}),ar.shorthand&&this.addExtra(ar,"shorthand",!0),Ye.properties.push(ar)}this.next(),this.state.inFSharpPipelineDirectBody=y;let At="ObjectExpression";return t?At="ObjectPattern":o&&(At="RecordExpression"),this.finishNode(Ye,At)}addTrailingCommaExtraToNode(i){this.addExtra(i,"trailingComma",this.state.lastTokStart),this.addExtra(i,"trailingCommaLoc",this.state.lastTokStartLoc,!1)}maybeAsyncOrAccessorProp(i){return!i.computed&&i.key.type==="Identifier"&&(this.isLiteralPropertyName()||this.match(0)||this.match(55))}parsePropertyDefinition(i){let t=[];if(this.match(26))for(this.hasPlugin("decorators")&&this.raise(dt.UnsupportedPropertyDecorator,{at:this.state.startLoc});this.match(26);)t.push(this.parseDecorator());let o=this.startNode(),p=!1,y=!1,$,he;if(this.match(21))return t.length&&this.unexpected(),this.parseSpread();t.length&&(o.decorators=t,t=[]),o.method=!1,i&&($=this.state.start,he=this.state.startLoc);let Ye=this.eat(55);this.parsePropertyNamePrefixOperator(o);let At=this.state.containsEsc,ar=this.parsePropertyName(o,i);if(!Ye&&!At&&this.maybeAsyncOrAccessorProp(o)){let d=ar.name;d==="async"&&!this.hasPrecedingLineBreak()&&(p=!0,this.resetPreviousNodeTrailingComments(ar),Ye=this.eat(55),this.parsePropertyName(o)),(d==="get"||d==="set")&&(y=!0,this.resetPreviousNodeTrailingComments(ar),o.kind=d,this.match(55)&&(Ye=!0,this.raise(dt.AccessorIsGenerator,{at:this.state.curPosition(),kind:d}),this.next()),this.parsePropertyName(o))}return this.parseObjPropValue(o,$,he,Ye,p,!1,y,i),o}getGetterSetterExpectedParamCount(i){return i.kind==="get"?0:1}getObjectOrClassMethodParams(i){return i.params}checkGetterSetterParams(i){var t;let o=this.getGetterSetterExpectedParamCount(i),p=this.getObjectOrClassMethodParams(i);p.length!==o&&this.raise(i.kind==="get"?dt.BadGetterArity:dt.BadSetterArity,{at:i}),i.kind==="set"&&((t=p[p.length-1])==null?void 0:t.type)==="RestElement"&&this.raise(dt.BadSetterRestParameter,{at:i})}parseObjectMethod(i,t,o,p,y){if(y)return this.parseMethod(i,t,!1,!1,!1,"ObjectMethod"),this.checkGetterSetterParams(i),i;if(o||t||this.match(10))return p&&this.unexpected(),i.kind="method",i.method=!0,this.parseMethod(i,t,o,!1,!1,"ObjectMethod")}parseObjectProperty(i,t,o,p,y){if(i.shorthand=!1,this.eat(14))return i.value=p?this.parseMaybeDefault(this.state.start,this.state.startLoc):this.parseMaybeAssignAllowIn(y),this.finishNode(i,"ObjectProperty");if(!i.computed&&i.key.type==="Identifier"){if(this.checkReservedWord(i.key.name,i.key.loc.start,!0,!1),p)i.value=this.parseMaybeDefault(t,o,K(i.key));else if(this.match(29)){let $=this.state.startLoc;y!=null?y.shorthandAssignLoc===null&&(y.shorthandAssignLoc=$):this.raise(dt.InvalidCoverInitializedName,{at:$}),i.value=this.parseMaybeDefault(t,o,K(i.key))}else i.value=K(i.key);return i.shorthand=!0,this.finishNode(i,"ObjectProperty")}}parseObjPropValue(i,t,o,p,y,$,he,Ye){let At=this.parseObjectMethod(i,p,y,$,he)||this.parseObjectProperty(i,t,o,$,Ye);return At||this.unexpected(),At}parsePropertyName(i,t){if(this.eat(0))i.computed=!0,i.key=this.parseMaybeAssignAllowIn(),this.expect(3);else{let{type:o,value:p}=this.state,y;if(ds(o))y=this.parseIdentifier(!0);else switch(o){case 130:y=this.parseNumericLiteral(p);break;case 129:y=this.parseStringLiteral(p);break;case 131:y=this.parseBigIntLiteral(p);break;case 132:y=this.parseDecimalLiteral(p);break;case 134:{let $=this.state.startLoc;t!=null?t.privateKeyLoc===null&&(t.privateKeyLoc=$):this.raise(dt.UnexpectedPrivateField,{at:$}),y=this.parsePrivateName();break}default:throw this.unexpected()}i.key=y,o!==134&&(i.computed=!1)}return i.key}initFunction(i,t){i.id=null,i.generator=!1,i.async=!!t}parseMethod(i,t,o,p,y,$){let he=arguments.length>6&&arguments[6]!==void 0?arguments[6]:!1;this.initFunction(i,o),i.generator=!!t;let Ye=p;return this.scope.enter(Xa|po|(he?so:0)|(y?Ou:0)),this.prodParam.enter(lu(o,i.generator)),this.parseFunctionParams(i,Ye),this.parseFunctionBodyAndFinish(i,$,!0),this.prodParam.exit(),this.scope.exit(),i}parseArrayLike(i,t,o,p){o&&this.expectPlugin("recordAndTuple");let y=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!1;let $=this.startNode();return this.next(),$.elements=this.parseExprList(i,!o,p,$),this.state.inFSharpPipelineDirectBody=y,this.finishNode($,o?"TupleExpression":"ArrayExpression")}parseArrowExpression(i,t,o,p){this.scope.enter(Xa|xu);let y=lu(o,!1);!this.match(5)&&this.prodParam.hasIn&&(y|=Ra),this.prodParam.enter(y),this.initFunction(i,o);let $=this.state.maybeInArrowParameters;return t&&(this.state.maybeInArrowParameters=!0,this.setArrowFunctionParameters(i,t,p)),this.state.maybeInArrowParameters=!1,this.parseFunctionBody(i,!0),this.prodParam.exit(),this.scope.exit(),this.state.maybeInArrowParameters=$,this.finishNode(i,"ArrowFunctionExpression")}setArrowFunctionParameters(i,t,o){this.toAssignableList(t,o,!1),i.params=t}parseFunctionBodyAndFinish(i,t){let o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;this.parseFunctionBody(i,!1,o),this.finishNode(i,t)}parseFunctionBody(i,t){let o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,p=t&&!this.match(5);if(this.expressionScope.enter(Ko()),p)i.body=this.parseMaybeAssign(),this.checkParams(i,!1,t,!1);else{let y=this.state.strict,$=this.state.labels;this.state.labels=[],this.prodParam.enter(this.prodParam.currentFlags()|Vu),i.body=this.parseBlock(!0,!1,he=>{let Ye=!this.isSimpleParamList(i.params);he&&Ye&&this.raise(dt.IllegalLanguageModeDirective,{at:(i.kind==="method"||i.kind==="constructor")&&!!i.key?i.key.loc.end:i});let At=!y&&this.state.strict;this.checkParams(i,!this.state.strict&&!t&&!o&&!Ye,t,At),this.state.strict&&i.id&&this.checkIdentifier(i.id,su,At)}),this.prodParam.exit(),this.state.labels=$}this.expressionScope.exit()}isSimpleParameter(i){return i.type==="Identifier"}isSimpleParamList(i){for(let t=0,o=i.length;t<o;t++)if(!this.isSimpleParameter(i[t]))return!1;return!0}checkParams(i,t,o){let p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,y=!t&&new Set,$={type:"FormalParameters"};for(let he of i.params)this.checkLVal(he,{in:$,binding:Za,checkClashes:y,strictModeChanged:p})}parseExprList(i,t,o,p){let y=[],$=!0;for(;!this.eat(i);){if($)$=!1;else if(this.expect(12),this.match(i)){p&&this.addTrailingCommaExtraToNode(p),this.next();break}y.push(this.parseExprListItem(t,o))}return y}parseExprListItem(i,t,o){let p;if(this.match(12))i||this.raise(dt.UnexpectedToken,{at:this.state.curPosition(),unexpected:","}),p=null;else if(this.match(21)){let y=this.state.start,$=this.state.startLoc;p=this.parseParenItem(this.parseSpread(t),y,$)}else if(this.match(17)){this.expectPlugin("partialApplication"),o||this.raise(dt.UnexpectedArgumentPlaceholder,{at:this.state.startLoc});let y=this.startNode();this.next(),p=this.finishNode(y,"ArgumentPlaceholder")}else p=this.parseMaybeAssignAllowIn(t,this.parseParenItem);return p}parseIdentifier(i){let t=this.startNode(),o=this.parseIdentifierName(t.start,i);return this.createIdentifier(t,o)}createIdentifier(i,t){return i.name=t,i.loc.identifierName=t,this.finishNode(i,"Identifier")}parseIdentifierName(i,t){let o,{startLoc:p,type:y}=this.state;if(ds(y))o=this.state.value;else throw this.unexpected();let $=Ri(y);return t?$&&this.replaceToken(128):this.checkReservedWord(o,p,$,!1),this.next(),o}checkReservedWord(i,t,o,p){if(!(i.length>10||!ua(i))){if(i==="yield"){if(this.prodParam.hasYield){this.raise(dt.YieldBindingIdentifier,{at:t});return}}else if(i==="await"){if(this.prodParam.hasAwait){this.raise(dt.AwaitBindingIdentifier,{at:t});return}if(this.scope.inStaticBlock){this.raise(dt.AwaitBindingIdentifierInStaticBlock,{at:t});return}this.expressionScope.recordAsyncArrowParametersError({at:t})}else if(i==="arguments"&&this.scope.inClassAndNotInNonArrowFunction){this.raise(dt.ArgumentsInClass,{at:t});return}if(o&&Ma(i)){this.raise(dt.UnexpectedKeyword,{at:t,keyword:i});return}(this.state.strict?p?Va:Uo:co)(i,this.inModule)&&this.raise(dt.UnexpectedReservedWord,{at:t,reservedWord:i})}}isAwaitAllowed(){return!!(this.prodParam.hasAwait||this.options.allowAwaitOutsideFunction&&!this.scope.inFunction)}parseAwait(i,t){let o=this.startNodeAt(i,t);return this.expressionScope.recordParameterInitializerError(dt.AwaitExpressionFormalParameter,{at:o}),this.eat(55)&&this.raise(dt.ObsoleteAwaitStar,{at:o}),!this.scope.inFunction&&!this.options.allowAwaitOutsideFunction&&(this.isAmbiguousAwait()?this.ambiguousScriptDifferentAst=!0:this.sawUnambiguousESM=!0),this.state.soloAwait||(o.argument=this.parseMaybeUnary(null,!0)),this.finishNode(o,"AwaitExpression")}isAmbiguousAwait(){if(this.hasPrecedingLineBreak())return!0;let{type:i}=this.state;return i===53||i===10||i===0||Ps(i)||i===133||i===56||this.hasPlugin("v8intrinsic")&&i===54}parseYield(){let i=this.startNode();this.expressionScope.recordParameterInitializerError(dt.YieldInParameter,{at:i}),this.next();let t=!1,o=null;if(!this.hasPrecedingLineBreak())switch(t=this.eat(55),this.state.type){case 13:case 135:case 8:case 11:case 3:case 9:case 14:case 12:if(!t)break;default:o=this.parseMaybeAssign()}return i.delegate=t,i.argument=o,this.finishNode(i,"YieldExpression")}checkPipelineAtInfixOperator(i,t){this.hasPlugin(["pipelineOperator",{proposal:"smart"}])&&i.type==="SequenceExpression"&&this.raise(dt.PipelineHeadSequenceExpression,{at:t})}parseSmartPipelineBodyInStyle(i,t,o){let p=this.startNodeAt(t,o);return this.isSimpleReference(i)?(p.callee=i,this.finishNode(p,"PipelineBareFunction")):(this.checkSmartPipeTopicBodyEarlyErrors(o),p.expression=i,this.finishNode(p,"PipelineTopicExpression"))}isSimpleReference(i){switch(i.type){case"MemberExpression":return!i.computed&&this.isSimpleReference(i.object);case"Identifier":return!0;default:return!1}}checkSmartPipeTopicBodyEarlyErrors(i){if(this.match(19))throw this.raise(dt.PipelineBodyNoArrow,{at:this.state.startLoc});this.topicReferenceWasUsedInCurrentContext()||this.raise(dt.PipelineTopicUnused,{at:i})}withTopicBindingContext(i){let t=this.state.topicContext;this.state.topicContext={maxNumOfResolvableTopics:1,maxTopicIndex:null};try{return i()}finally{this.state.topicContext=t}}withSmartMixTopicForbiddingContext(i){if(this.hasPlugin(["pipelineOperator",{proposal:"smart"}])){let t=this.state.topicContext;this.state.topicContext={maxNumOfResolvableTopics:0,maxTopicIndex:null};try{return i()}finally{this.state.topicContext=t}}else return i()}withSoloAwaitPermittingContext(i){let t=this.state.soloAwait;this.state.soloAwait=!0;try{return i()}finally{this.state.soloAwait=t}}allowInAnd(i){let t=this.prodParam.currentFlags();if(Ra&~t){this.prodParam.enter(t|Ra);try{return i()}finally{this.prodParam.exit()}}return i()}disallowInAnd(i){let t=this.prodParam.currentFlags();if(Ra&t){this.prodParam.enter(t&~Ra);try{return i()}finally{this.prodParam.exit()}}return i()}registerTopicReference(){this.state.topicContext.maxTopicIndex=0}topicReferenceIsAllowedInCurrentContext(){return this.state.topicContext.maxNumOfResolvableTopics>=1}topicReferenceWasUsedInCurrentContext(){return this.state.topicContext.maxTopicIndex!=null&&this.state.topicContext.maxTopicIndex>=0}parseFSharpPipelineBody(i){let t=this.state.start,o=this.state.startLoc;this.state.potentialArrowAt=this.state.start;let p=this.state.inFSharpPipelineDirectBody;this.state.inFSharpPipelineDirectBody=!0;let y=this.parseExprOp(this.parseMaybeUnaryOrPrivate(),t,o,i);return this.state.inFSharpPipelineDirectBody=p,y}parseModuleExpression(){this.expectPlugin("moduleBlocks");let i=this.startNode();this.next(),this.eat(5);let t=this.initializeScopes(!0);this.enterInitialScopes();let o=this.startNode();try{i.body=this.parseProgram(o,8,"module")}finally{t()}return this.eat(8),this.finishNode(i,"ModuleExpression")}parsePropertyNamePrefixOperator(i){}},ta={kind:"loop"},ia={kind:"switch"},ka=0,Pa=1,Ls=2,Qs=4,Ua=/[\uD800-\uDFFF]/u,la=/in(?:stanceof)?/y;function sa(i,t){for(let o=0;o<i.length;o++){let p=i[o],{type:y}=p;if(typeof y=="number"){{if(y===134){let{loc:$,start:he,value:Ye,end:At}=p,ar=he+1,d=pn($.start,1);i.splice(o,1,new To({type:Ws(27),value:"#",start:he,end:ar,startLoc:$.start,endLoc:d}),new To({type:Ws(128),value:Ye,start:ar,end:At,startLoc:d,endLoc:$.end})),o++;continue}if(Ps(y)){let{loc:$,start:he,value:Ye,end:At}=p,ar=he+1,d=pn($.start,1),A;t.charCodeAt(he)===96?A=new To({type:Ws(22),value:"`",start:he,end:ar,startLoc:$.start,endLoc:d}):A=new To({type:Ws(8),value:"}",start:he,end:ar,startLoc:$.start,endLoc:d});let m,b,E,g;y===24?(b=At-1,E=pn($.end,-1),m=Ye===null?null:Ye.slice(1,-1),g=new To({type:Ws(22),value:"`",start:b,end:At,startLoc:E,endLoc:$.end})):(b=At-2,E=pn($.end,-2),m=Ye===null?null:Ye.slice(1,-2),g=new To({type:Ws(23),value:"${",start:b,end:At,startLoc:E,endLoc:$.end})),i.splice(o,1,A,new To({type:Ws(20),value:m,start:ar,end:b,startLoc:d,endLoc:E}),g),o+=2;continue}}p.type=Ws(y)}}return i}var aa=class extends ei{parseTopLevel(i,t){return i.program=this.parseProgram(t),i.comments=this.state.comments,this.options.tokens&&(i.tokens=sa(this.tokens,this.input)),this.finishNode(i,"File")}parseProgram(i){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:135,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:this.options.sourceType;if(i.sourceType=o,i.interpreter=this.parseInterpreterDirective(),this.parseBlockBody(i,!0,!0,t),this.inModule&&!this.options.allowUndeclaredExports&&this.scope.undefinedExports.size>0)for(let[p,y]of Array.from(this.scope.undefinedExports))this.raise(dt.ModuleExportUndefined,{at:y,localName:p});return this.finishNode(i,"Program")}stmtToDirective(i){let t=i;t.type="Directive",t.value=t.expression,delete t.expression;let o=t.value,p=o.value,y=this.input.slice(o.start,o.end),$=o.value=y.slice(1,-1);return this.addExtra(o,"raw",y),this.addExtra(o,"rawValue",$),this.addExtra(o,"expressionValue",p),o.type="DirectiveLiteral",t}parseInterpreterDirective(){if(!this.match(28))return null;let i=this.startNode();return i.value=this.state.value,this.next(),this.finishNode(i,"InterpreterDirective")}isLet(i){return this.isContextual(99)?this.isLetKeyword(i):!1}isLetKeyword(i){let t=this.nextTokenStart(),o=this.codePointAtPos(t);if(o===92||o===91)return!0;if(i)return!1;if(o===123)return!0;if(Ts(o)){if(la.lastIndex=t,la.test(this.input)){let p=this.codePointAtPos(la.lastIndex);if(!ea(p)&&p!==92)return!1}return!0}return!1}parseStatement(i,t){return this.match(26)&&this.parseDecorators(!0),this.parseStatementContent(i,t)}parseStatementContent(i,t){let o=this.state.type,p=this.startNode(),y;switch(this.isLet(i)&&(o=74,y="let"),o){case 60:return this.parseBreakContinueStatement(p,!0);case 63:return this.parseBreakContinueStatement(p,!1);case 64:return this.parseDebuggerStatement(p);case 90:return this.parseDoStatement(p);case 91:return this.parseForStatement(p);case 68:if(this.lookaheadCharCode()===46)break;return i&&(this.state.strict?this.raise(dt.StrictFunction,{at:this.state.startLoc}):i!=="if"&&i!=="label"&&this.raise(dt.SloppyFunction,{at:this.state.startLoc})),this.parseFunctionStatement(p,!1,!i);case 80:return i&&this.unexpected(),this.parseClass(p,!0);case 69:return this.parseIfStatement(p);case 70:return this.parseReturnStatement(p);case 71:return this.parseSwitchStatement(p);case 72:return this.parseThrowStatement(p);case 73:return this.parseTryStatement(p);case 75:case 74:return y=y||this.state.value,i&&y!=="var"&&this.raise(dt.UnexpectedLexicalDeclaration,{at:this.state.startLoc}),this.parseVarStatement(p,y);case 92:return this.parseWhileStatement(p);case 76:return this.parseWithStatement(p);case 5:return this.parseBlock();case 13:return this.parseEmptyStatement(p);case 83:{let Ye=this.lookaheadCharCode();if(Ye===40||Ye===46)break}case 82:{!this.options.allowImportExportEverywhere&&!t&&this.raise(dt.UnexpectedImportExport,{at:this.state.startLoc}),this.next();let Ye;return o===83?(Ye=this.parseImport(p),Ye.type==="ImportDeclaration"&&(!Ye.importKind||Ye.importKind==="value")&&(this.sawUnambiguousESM=!0)):(Ye=this.parseExport(p),(Ye.type==="ExportNamedDeclaration"&&(!Ye.exportKind||Ye.exportKind==="value")||Ye.type==="ExportAllDeclaration"&&(!Ye.exportKind||Ye.exportKind==="value")||Ye.type==="ExportDefaultDeclaration")&&(this.sawUnambiguousESM=!0)),this.assertModuleNodeAllowed(p),Ye}default:if(this.isAsyncFunction())return i&&this.raise(dt.AsyncFunctionInSingleStatementContext,{at:this.state.startLoc}),this.next(),this.parseFunctionStatement(p,!0,!i)}let $=this.state.value,he=this.parseExpression();return jn(o)&&he.type==="Identifier"&&this.eat(14)?this.parseLabeledStatement(p,$,he,i):this.parseExpressionStatement(p,he)}assertModuleNodeAllowed(i){!this.options.allowImportExportEverywhere&&!this.inModule&&this.raise(dt.ImportOutsideModule,{at:i})}takeDecorators(i){let t=this.state.decoratorStack[this.state.decoratorStack.length-1];t.length&&(i.decorators=t,this.resetStartLocationFromNode(i,t[0]),this.state.decoratorStack[this.state.decoratorStack.length-1]=[])}canHaveLeadingDecorator(){return this.match(80)}parseDecorators(i){let t=this.state.decoratorStack[this.state.decoratorStack.length-1];for(;this.match(26);){let o=this.parseDecorator();t.push(o)}if(this.match(82))i||this.unexpected(),this.hasPlugin("decorators")&&!this.getPluginOption("decorators","decoratorsBeforeExport")&&this.raise(dt.DecoratorExportClass,{at:this.state.startLoc});else if(!this.canHaveLeadingDecorator())throw this.raise(dt.UnexpectedLeadingDecorator,{at:this.state.startLoc})}parseDecorator(){this.expectOnePlugin(["decorators-legacy","decorators"]);let i=this.startNode();if(this.next(),this.hasPlugin("decorators")){this.state.decoratorStack.push([]);let t=this.state.start,o=this.state.startLoc,p;if(this.match(10)){let y=this.state.start,$=this.state.startLoc;this.next(),p=this.parseExpression(),this.expect(11),p=this.wrapParenthesis(y,$,p)}else for(p=this.parseIdentifier(!1);this.eat(16);){let y=this.startNodeAt(t,o);y.object=p,y.property=this.parseIdentifier(!0),y.computed=!1,p=this.finishNode(y,"MemberExpression")}i.expression=this.parseMaybeDecoratorArguments(p),this.state.decoratorStack.pop()}else i.expression=this.parseExprSubscripts();return this.finishNode(i,"Decorator")}parseMaybeDecoratorArguments(i){if(this.eat(10)){let t=this.startNodeAtNode(i);return t.callee=i,t.arguments=this.parseCallExpressionArguments(11,!1),this.toReferencedList(t.arguments),this.finishNode(t,"CallExpression")}return i}parseBreakContinueStatement(i,t){return this.next(),this.isLineTerminator()?i.label=null:(i.label=this.parseIdentifier(),this.semicolon()),this.verifyBreakContinue(i,t),this.finishNode(i,t?"BreakStatement":"ContinueStatement")}verifyBreakContinue(i,t){let o;for(o=0;o<this.state.labels.length;++o){let p=this.state.labels[o];if((i.label==null||p.name===i.label.name)&&(p.kind!=null&&(t||p.kind==="loop")||i.label&&t))break}if(o===this.state.labels.length){let p=t?"BreakStatement":"ContinueStatement";this.raise(dt.IllegalBreakContinue,{at:i,type:p})}}parseDebuggerStatement(i){return this.next(),this.semicolon(),this.finishNode(i,"DebuggerStatement")}parseHeaderExpression(){this.expect(10);let i=this.parseExpression();return this.expect(11),i}parseDoStatement(i){return this.next(),this.state.labels.push(ta),i.body=this.withSmartMixTopicForbiddingContext(()=>this.parseStatement("do")),this.state.labels.pop(),this.expect(92),i.test=this.parseHeaderExpression(),this.eat(13),this.finishNode(i,"DoWhileStatement")}parseForStatement(i){this.next(),this.state.labels.push(ta);let t=null;if(this.isAwaitAllowed()&&this.eatContextual(96)&&(t=this.state.lastTokStartLoc),this.scope.enter(Wa),this.expect(10),this.match(13))return t!==null&&this.unexpected(t),this.parseFor(i,null);let o=this.isContextual(99),p=o&&this.isLetKeyword();if(this.match(74)||this.match(75)||p){let At=this.startNode(),ar=p?"let":this.state.value;return this.next(),this.parseVar(At,!0,ar),this.finishNode(At,"VariableDeclaration"),(this.match(58)||this.isContextual(101))&&At.declarations.length===1?this.parseForIn(i,At,t):(t!==null&&this.unexpected(t),this.parseFor(i,At))}let y=this.isContextual(95),$=new So,he=this.parseExpression(!0,$),Ye=this.isContextual(101);if(Ye&&(o&&this.raise(dt.ForOfLet,{at:he}),t===null&&y&&he.type==="Identifier"&&this.raise(dt.ForOfAsync,{at:he})),Ye||this.match(58)){this.checkDestructuringPrivate($),this.toAssignable(he,!0);let At=Ye?"ForOfStatement":"ForInStatement";return this.checkLVal(he,{in:{type:At}}),this.parseForIn(i,he,t)}else this.checkExpressionErrors($,!0);return t!==null&&this.unexpected(t),this.parseFor(i,he)}parseFunctionStatement(i,t,o){return this.next(),this.parseFunction(i,Pa|(o?0:Ls),t)}parseIfStatement(i){return this.next(),i.test=this.parseHeaderExpression(),i.consequent=this.parseStatement("if"),i.alternate=this.eat(66)?this.parseStatement("if"):null,this.finishNode(i,"IfStatement")}parseReturnStatement(i){return!this.prodParam.hasReturn&&!this.options.allowReturnOutsideFunction&&this.raise(dt.IllegalReturn,{at:this.state.startLoc}),this.next(),this.isLineTerminator()?i.argument=null:(i.argument=this.parseExpression(),this.semicolon()),this.finishNode(i,"ReturnStatement")}parseSwitchStatement(i){this.next(),i.discriminant=this.parseHeaderExpression();let t=i.cases=[];this.expect(5),this.state.labels.push(ia),this.scope.enter(Wa);let o;for(let p;!this.match(8);)if(this.match(61)||this.match(65)){let y=this.match(61);o&&this.finishNode(o,"SwitchCase"),t.push(o=this.startNode()),o.consequent=[],this.next(),y?o.test=this.parseExpression():(p&&this.raise(dt.MultipleDefaultsInSwitch,{at:this.state.lastTokStartLoc}),p=!0,o.test=null),this.expect(14)}else o?o.consequent.push(this.parseStatement(null)):this.unexpected();return this.scope.exit(),o&&this.finishNode(o,"SwitchCase"),this.next(),this.state.labels.pop(),this.finishNode(i,"SwitchStatement")}parseThrowStatement(i){return this.next(),this.hasPrecedingLineBreak()&&this.raise(dt.NewlineAfterThrow,{at:this.state.lastTokEndLoc}),i.argument=this.parseExpression(),this.semicolon(),this.finishNode(i,"ThrowStatement")}parseCatchClauseParam(){let i=this.parseBindingAtom(),t=i.type==="Identifier";return this.scope.enter(t?Iu:0),this.checkLVal(i,{in:{type:"CatchClause"},binding:Aa,allowingSloppyLetBinding:!0}),i}parseTryStatement(i){if(this.next(),i.block=this.parseBlock(),i.handler=null,this.match(62)){let t=this.startNode();this.next(),this.match(10)?(this.expect(10),t.param=this.parseCatchClauseParam(),this.expect(11)):(t.param=null,this.scope.enter(Wa)),t.body=this.withSmartMixTopicForbiddingContext(()=>this.parseBlock(!1,!1)),this.scope.exit(),i.handler=this.finishNode(t,"CatchClause")}return i.finalizer=this.eat(67)?this.parseBlock():null,!i.handler&&!i.finalizer&&this.raise(dt.NoCatchOrFinally,{at:i}),this.finishNode(i,"TryStatement")}parseVarStatement(i,t){let o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return this.next(),this.parseVar(i,!1,t,o),this.semicolon(),this.finishNode(i,"VariableDeclaration")}parseWhileStatement(i){return this.next(),i.test=this.parseHeaderExpression(),this.state.labels.push(ta),i.body=this.withSmartMixTopicForbiddingContext(()=>this.parseStatement("while")),this.state.labels.pop(),this.finishNode(i,"WhileStatement")}parseWithStatement(i){return this.state.strict&&this.raise(dt.StrictWith,{at:this.state.startLoc}),this.next(),i.object=this.parseHeaderExpression(),i.body=this.withSmartMixTopicForbiddingContext(()=>this.parseStatement("with")),this.finishNode(i,"WithStatement")}parseEmptyStatement(i){return this.next(),this.finishNode(i,"EmptyStatement")}parseLabeledStatement(i,t,o,p){for(let $ of this.state.labels)$.name===t&&this.raise(dt.LabelRedeclaration,{at:o,labelName:t});let y=We(this.state.type)?"loop":this.match(71)?"switch":null;for(let $=this.state.labels.length-1;$>=0;$--){let he=this.state.labels[$];if(he.statementStart===i.start)he.statementStart=this.state.start,he.kind=y;else break}return this.state.labels.push({name:t,kind:y,statementStart:this.state.start}),i.body=this.parseStatement(p?p.indexOf("label")===-1?p+"label":p:"label"),this.state.labels.pop(),i.label=o,this.finishNode(i,"LabeledStatement")}parseExpressionStatement(i,t){return i.expression=t,this.semicolon(),this.finishNode(i,"ExpressionStatement")}parseBlock(){let i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,o=arguments.length>2?arguments[2]:void 0,p=this.startNode();return i&&this.state.strictErrors.clear(),this.expect(5),t&&this.scope.enter(Wa),this.parseBlockBody(p,i,!1,8,o),t&&this.scope.exit(),this.finishNode(p,"BlockStatement")}isValidDirective(i){return i.type==="ExpressionStatement"&&i.expression.type==="StringLiteral"&&!i.expression.extra.parenthesized}parseBlockBody(i,t,o,p,y){let $=i.body=[],he=i.directives=[];this.parseBlockOrModuleBlockBody($,t?he:void 0,o,p,y)}parseBlockOrModuleBlockBody(i,t,o,p,y){let $=this.state.strict,he=!1,Ye=!1;for(;!this.match(p);){let At=this.parseStatement(null,o);if(t&&!Ye){if(this.isValidDirective(At)){let ar=this.stmtToDirective(At);t.push(ar),!he&&ar.value.value==="use strict"&&(he=!0,this.setStrict(!0));continue}Ye=!0,this.state.strictErrors.clear()}i.push(At)}y&&y.call(this,he),$||this.setStrict(!1),this.next()}parseFor(i,t){return i.init=t,this.semicolon(!1),i.test=this.match(13)?null:this.parseExpression(),this.semicolon(!1),i.update=this.match(11)?null:this.parseExpression(),this.expect(11),i.body=this.withSmartMixTopicForbiddingContext(()=>this.parseStatement("for")),this.scope.exit(),this.state.labels.pop(),this.finishNode(i,"ForStatement")}parseForIn(i,t,o){let p=this.match(58);return this.next(),p?o!==null&&this.unexpected(o):i.await=o!==null,t.type==="VariableDeclaration"&&t.declarations[0].init!=null&&(!p||this.state.strict||t.kind!=="var"||t.declarations[0].id.type!=="Identifier")&&this.raise(dt.ForInOfLoopInitializer,{at:t,type:p?"ForInStatement":"ForOfStatement"}),t.type==="AssignmentPattern"&&this.raise(dt.InvalidLhs,{at:t,ancestor:{type:"ForStatement"}}),i.left=t,i.right=p?this.parseExpression():this.parseMaybeAssignAllowIn(),this.expect(11),i.body=this.withSmartMixTopicForbiddingContext(()=>this.parseStatement("for")),this.scope.exit(),this.state.labels.pop(),this.finishNode(i,p?"ForInStatement":"ForOfStatement")}parseVar(i,t,o){let p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,y=i.declarations=[];for(i.kind=o;;){let $=this.startNode();if(this.parseVarId($,o),$.init=this.eat(29)?t?this.parseMaybeAssignDisallowIn():this.parseMaybeAssignAllowIn():null,$.init===null&&!p&&($.id.type!=="Identifier"&&!(t&&(this.match(58)||this.isContextual(101)))?this.raise(dt.DeclarationMissingInitializer,{at:this.state.lastTokEndLoc,kind:"destructuring"}):o==="const"&&!(this.match(58)||this.isContextual(101))&&this.raise(dt.DeclarationMissingInitializer,{at:this.state.lastTokEndLoc,kind:"const"})),y.push(this.finishNode($,"VariableDeclarator")),!this.eat(12))break}return i}parseVarId(i,t){i.id=this.parseBindingAtom(),this.checkLVal(i.id,{in:{type:"VariableDeclarator"},binding:t==="var"?Za:Aa})}parseFunction(i){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ka,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,p=t&Pa,y=t&Ls,$=!!p&&!(t&Qs);this.initFunction(i,o),this.match(55)&&y&&this.raise(dt.GeneratorInSingleStatementContext,{at:this.state.startLoc}),i.generator=this.eat(55),p&&(i.id=this.parseFunctionId($));let he=this.state.maybeInArrowParameters;return this.state.maybeInArrowParameters=!1,this.scope.enter(Xa),this.prodParam.enter(lu(o,i.generator)),p||(i.id=this.parseFunctionId()),this.parseFunctionParams(i,!1),this.withSmartMixTopicForbiddingContext(()=>{this.parseFunctionBodyAndFinish(i,p?"FunctionDeclaration":"FunctionExpression")}),this.prodParam.exit(),this.scope.exit(),p&&!y&&this.registerFunctionStatementId(i),this.state.maybeInArrowParameters=he,i}parseFunctionId(i){return i||jn(this.state.type)?this.parseIdentifier():null}parseFunctionParams(i,t){this.expect(10),this.expressionScope.enter(Bl()),i.params=this.parseBindingList(11,41,!1,t),this.expressionScope.exit()}registerFunctionStatementId(i){!i.id||this.scope.declareName(i.id.name,this.state.strict||i.generator||i.async?this.scope.treatFunctionsAsVar?Za:Aa:ju,i.id.loc.start)}parseClass(i,t,o){this.next(),this.takeDecorators(i);let p=this.state.strict;return this.state.strict=!0,this.parseClassId(i,t,o),this.parseClassSuper(i),i.body=this.parseClassBody(!!i.superClass,p),this.finishNode(i,t?"ClassDeclaration":"ClassExpression")}isClassProperty(){return this.match(29)||this.match(13)||this.match(8)}isClassMethod(){return this.match(10)}isNonstaticConstructor(i){return!i.computed&&!i.static&&(i.key.name==="constructor"||i.key.value==="constructor")}parseClassBody(i,t){this.classScope.enter();let o={hadConstructor:!1,hadSuperClass:i},p=[],y=this.startNode();if(y.body=[],this.expect(5),this.withSmartMixTopicForbiddingContext(()=>{for(;!this.match(8);){if(this.eat(13)){if(p.length>0)throw this.raise(dt.DecoratorSemicolon,{at:this.state.lastTokEndLoc});continue}if(this.match(26)){p.push(this.parseDecorator());continue}let $=this.startNode();p.length&&($.decorators=p,this.resetStartLocationFromNode($,p[0]),p=[]),this.parseClassMember(y,$,o),$.kind==="constructor"&&$.decorators&&$.decorators.length>0&&this.raise(dt.DecoratorConstructor,{at:$})}}),this.state.strict=t,this.next(),p.length)throw this.raise(dt.TrailingDecorator,{at:this.state.startLoc});return this.classScope.exit(),this.finishNode(y,"ClassBody")}parseClassMemberFromModifier(i,t){let o=this.parseIdentifier(!0);if(this.isClassMethod()){let p=t;return p.kind="method",p.computed=!1,p.key=o,p.static=!1,this.pushClassMethod(i,p,!1,!1,!1,!1),!0}else if(this.isClassProperty()){let p=t;return p.computed=!1,p.key=o,p.static=!1,i.body.push(this.parseClassProperty(p)),!0}return this.resetPreviousNodeTrailingComments(o),!1}parseClassMember(i,t,o){let p=this.isContextual(104);if(p){if(this.parseClassMemberFromModifier(i,t))return;if(this.eat(5)){this.parseClassStaticBlock(i,t);return}}this.parseClassMemberWithIsStatic(i,t,o,p)}parseClassMemberWithIsStatic(i,t,o,p){let y=t,$=t,he=t,Ye=t,At=t,ar=y,d=y;if(t.static=p,this.parsePropertyNamePrefixOperator(t),this.eat(55)){ar.kind="method";let g=this.match(134);if(this.parseClassElementName(ar),g){this.pushClassPrivateMethod(i,$,!0,!1);return}this.isNonstaticConstructor(y)&&this.raise(dt.ConstructorIsGenerator,{at:y.key}),this.pushClassMethod(i,y,!0,!1,!1,!1);return}let A=jn(this.state.type)&&!this.state.containsEsc,m=this.match(134),b=this.parseClassElementName(t),E=this.state.startLoc;if(this.parsePostMemberNameModifiers(d),this.isClassMethod()){if(ar.kind="method",m){this.pushClassPrivateMethod(i,$,!1,!1);return}let g=this.isNonstaticConstructor(y),v=!1;g&&(y.kind="constructor",o.hadConstructor&&!this.hasPlugin("typescript")&&this.raise(dt.DuplicateConstructor,{at:b}),g&&this.hasPlugin("typescript")&&t.override&&this.raise(dt.OverrideOnConstructor,{at:b}),o.hadConstructor=!0,v=o.hadSuperClass),this.pushClassMethod(i,y,!1,!1,g,v)}else if(this.isClassProperty())m?this.pushClassPrivateProperty(i,Ye):this.pushClassProperty(i,he);else if(A&&b.name==="async"&&!this.isLineTerminator()){this.resetPreviousNodeTrailingComments(b);let g=this.eat(55);d.optional&&this.unexpected(E),ar.kind="method";let v=this.match(134);this.parseClassElementName(ar),this.parsePostMemberNameModifiers(d),v?this.pushClassPrivateMethod(i,$,g,!0):(this.isNonstaticConstructor(y)&&this.raise(dt.ConstructorIsAsync,{at:y.key}),this.pushClassMethod(i,y,g,!0,!1,!1))}else if(A&&(b.name==="get"||b.name==="set")&&!(this.match(55)&&this.isLineTerminator())){this.resetPreviousNodeTrailingComments(b),ar.kind=b.name;let g=this.match(134);this.parseClassElementName(y),g?this.pushClassPrivateMethod(i,$,!1,!1):(this.isNonstaticConstructor(y)&&this.raise(dt.ConstructorIsAccessor,{at:y.key}),this.pushClassMethod(i,y,!1,!1,!1,!1)),this.checkGetterSetterParams(y)}else if(A&&b.name==="accessor"&&!this.isLineTerminator()){this.expectPlugin("decoratorAutoAccessors"),this.resetPreviousNodeTrailingComments(b);let g=this.match(134);this.parseClassElementName(he),this.pushClassAccessorProperty(i,At,g)}else this.isLineTerminator()?m?this.pushClassPrivateProperty(i,Ye):this.pushClassProperty(i,he):this.unexpected()}parseClassElementName(i){let{type:t,value:o}=this.state;if((t===128||t===129)&&i.static&&o==="prototype"&&this.raise(dt.StaticPrototype,{at:this.state.startLoc}),t===134){o==="constructor"&&this.raise(dt.ConstructorClassPrivateField,{at:this.state.startLoc});let p=this.parsePrivateName();return i.key=p,p}return this.parsePropertyName(i)}parseClassStaticBlock(i,t){var o;this.scope.enter(so|Ho|po);let p=this.state.labels;this.state.labels=[],this.prodParam.enter(Qo);let y=t.body=[];this.parseBlockOrModuleBlockBody(y,void 0,!1,8),this.prodParam.exit(),this.scope.exit(),this.state.labels=p,i.body.push(this.finishNode(t,"StaticBlock")),(o=t.decorators)!=null&&o.length&&this.raise(dt.DecoratorStaticBlock,{at:t})}pushClassProperty(i,t){!t.computed&&(t.key.name==="constructor"||t.key.value==="constructor")&&this.raise(dt.ConstructorClassField,{at:t.key}),i.body.push(this.parseClassProperty(t))}pushClassPrivateProperty(i,t){let o=this.parseClassPrivateProperty(t);i.body.push(o),this.classScope.declarePrivateName(this.getPrivateNameSV(o.key),Eu,o.key.loc.start)}pushClassAccessorProperty(i,t,o){if(!o&&!t.computed){let y=t.key;(y.name==="constructor"||y.value==="constructor")&&this.raise(dt.ConstructorClassField,{at:y})}let p=this.parseClassAccessorProperty(t);i.body.push(p),o&&this.classScope.declarePrivateName(this.getPrivateNameSV(p.key),Eu,p.key.loc.start)}pushClassMethod(i,t,o,p,y,$){i.body.push(this.parseMethod(t,o,p,y,$,"ClassMethod",!0))}pushClassPrivateMethod(i,t,o,p){let y=this.parseMethod(t,o,p,!1,!1,"ClassPrivateMethod",!0);i.body.push(y);let $=y.kind==="get"?y.static?ao:Vl:y.kind==="set"?y.static?wo:rc:Eu;this.declareClassPrivateMethodInScope(y,$)}declareClassPrivateMethodInScope(i,t){this.classScope.declarePrivateName(this.getPrivateNameSV(i.key),t,i.key.loc.start)}parsePostMemberNameModifiers(i){}parseClassPrivateProperty(i){return this.parseInitializer(i),this.semicolon(),this.finishNode(i,"ClassPrivateProperty")}parseClassProperty(i){return this.parseInitializer(i),this.semicolon(),this.finishNode(i,"ClassProperty")}parseClassAccessorProperty(i){return this.parseInitializer(i),this.semicolon(),this.finishNode(i,"ClassAccessorProperty")}parseInitializer(i){this.scope.enter(so|po),this.expressionScope.enter(Ko()),this.prodParam.enter(Qo),i.value=this.eat(29)?this.parseMaybeAssignAllowIn():null,this.expressionScope.exit(),this.prodParam.exit(),this.scope.exit()}parseClassId(i,t,o){let p=arguments.length>3&&arguments[3]!==void 0?arguments[3]:iu;if(jn(this.state.type))i.id=this.parseIdentifier(),t&&this.declareNameFromIdentifier(i.id,p);else if(o||!t)i.id=null;else throw this.raise(dt.MissingClassName,{at:this.state.startLoc})}parseClassSuper(i){i.superClass=this.eat(81)?this.parseExprSubscripts():null}parseExport(i){let t=this.maybeParseExportDefaultSpecifier(i),o=!t||this.eat(12),p=o&&this.eatExportStar(i),y=p&&this.maybeParseExportNamespaceSpecifier(i),$=o&&(!y||this.eat(12)),he=t||p;if(p&&!y)return t&&this.unexpected(),this.parseExportFrom(i,!0),this.finishNode(i,"ExportAllDeclaration");let Ye=this.maybeParseExportNamedSpecifiers(i);if(t&&o&&!p&&!Ye||y&&$&&!Ye)throw this.unexpected(null,5);let At;if(he||Ye?(At=!1,this.parseExportFrom(i,he)):At=this.maybeParseExportDeclaration(i),he||Ye||At)return this.checkExport(i,!0,!1,!!i.source),this.finishNode(i,"ExportNamedDeclaration");if(this.eat(65))return i.declaration=this.parseExportDefaultExpression(),this.checkExport(i,!0,!0),this.finishNode(i,"ExportDefaultDeclaration");throw this.unexpected(null,5)}eatExportStar(i){return this.eat(55)}maybeParseExportDefaultSpecifier(i){if(this.isExportDefaultSpecifier()){this.expectPlugin("exportDefaultFrom");let t=this.startNode();return t.exported=this.parseIdentifier(!0),i.specifiers=[this.finishNode(t,"ExportDefaultSpecifier")],!0}return!1}maybeParseExportNamespaceSpecifier(i){if(this.isContextual(93)){i.specifiers||(i.specifiers=[]);let t=this.startNodeAt(this.state.lastTokStart,this.state.lastTokStartLoc);return this.next(),t.exported=this.parseModuleExportName(),i.specifiers.push(this.finishNode(t,"ExportNamespaceSpecifier")),!0}return!1}maybeParseExportNamedSpecifiers(i){if(this.match(5)){i.specifiers||(i.specifiers=[]);let t=i.exportKind==="type";return i.specifiers.push(...this.parseExportSpecifiers(t)),i.source=null,i.declaration=null,this.hasPlugin("importAssertions")&&(i.assertions=[]),!0}return!1}maybeParseExportDeclaration(i){return this.shouldParseExportDeclaration()?(i.specifiers=[],i.source=null,this.hasPlugin("importAssertions")&&(i.assertions=[]),i.declaration=this.parseExportDeclaration(i),!0):!1}isAsyncFunction(){if(!this.isContextual(95))return!1;let i=this.nextTokenStart();return!Js.test(this.input.slice(this.state.pos,i))&&this.isUnparsedContextual(i,"function")}parseExportDefaultExpression(){let i=this.startNode(),t=this.isAsyncFunction();if(this.match(68)||t)return this.next(),t&&this.next(),this.parseFunction(i,Pa|Qs,t);if(this.match(80))return this.parseClass(i,!0,!0);if(this.match(26))return this.hasPlugin("decorators")&&this.getPluginOption("decorators","decoratorsBeforeExport")&&this.raise(dt.DecoratorBeforeExport,{at:this.state.startLoc}),this.parseDecorators(!1),this.parseClass(i,!0,!0);if(this.match(75)||this.match(74)||this.isLet())throw this.raise(dt.UnsupportedDefaultExport,{at:this.state.startLoc});let o=this.parseMaybeAssignAllowIn();return this.semicolon(),o}parseExportDeclaration(i){return this.parseStatement(null)}isExportDefaultSpecifier(){let{type:i}=this.state;if(jn(i)){if(i===95&&!this.state.containsEsc||i===99)return!1;if((i===126||i===125)&&!this.state.containsEsc){let{type:p}=this.lookahead();if(jn(p)&&p!==97||p===5)return this.expectOnePlugin(["flow","typescript"]),!1}}else if(!this.match(65))return!1;let t=this.nextTokenStart(),o=this.isUnparsedContextual(t,"from");if(this.input.charCodeAt(t)===44||jn(this.state.type)&&o)return!0;if(this.match(65)&&o){let p=this.input.charCodeAt(this.nextTokenStartSince(t+4));return p===34||p===39}return!1}parseExportFrom(i,t){if(this.eatContextual(97)){i.source=this.parseImportSource(),this.checkExport(i);let o=this.maybeParseImportAssertions();o&&(i.assertions=o)}else t&&this.unexpected();this.semicolon()}shouldParseExportDeclaration(){let{type:i}=this.state;if(i===26&&(this.expectOnePlugin(["decorators","decorators-legacy"]),this.hasPlugin("decorators"))){if(this.getPluginOption("decorators","decoratorsBeforeExport"))throw this.raise(dt.DecoratorBeforeExport,{at:this.state.startLoc});return!0}return i===74||i===75||i===68||i===80||this.isLet()||this.isAsyncFunction()}checkExport(i,t,o,p){if(t){if(o){if(this.checkDuplicateExports(i,"default"),this.hasPlugin("exportDefaultFrom")){var y;let $=i.declaration;$.type==="Identifier"&&$.name==="from"&&$.end-$.start===4&&!((y=$.extra)!=null&&y.parenthesized)&&this.raise(dt.ExportDefaultFromAsIdentifier,{at:$})}}else if(i.specifiers&&i.specifiers.length)for(let $ of i.specifiers){let{exported:he}=$,Ye=he.type==="Identifier"?he.name:he.value;if(this.checkDuplicateExports($,Ye),!p&&$.local){let{local:At}=$;At.type!=="Identifier"?this.raise(dt.ExportBindingIsString,{at:$,localName:At.value,exportName:Ye}):(this.checkReservedWord(At.name,At.loc.start,!0,!1),this.scope.checkLocalExport(At))}}else if(i.declaration){if(i.declaration.type==="FunctionDeclaration"||i.declaration.type==="ClassDeclaration"){let $=i.declaration.id;if(!$)throw new Error("Assertion failure");this.checkDuplicateExports(i,$.name)}else if(i.declaration.type==="VariableDeclaration")for(let $ of i.declaration.declarations)this.checkDeclaration($.id)}}if(this.state.decoratorStack[this.state.decoratorStack.length-1].length)throw this.raise(dt.UnsupportedDecoratorExport,{at:i})}checkDeclaration(i){if(i.type==="Identifier")this.checkDuplicateExports(i,i.name);else if(i.type==="ObjectPattern")for(let t of i.properties)this.checkDeclaration(t);else if(i.type==="ArrayPattern")for(let t of i.elements)t&&this.checkDeclaration(t);else i.type==="ObjectProperty"?this.checkDeclaration(i.value):i.type==="RestElement"?this.checkDeclaration(i.argument):i.type==="AssignmentPattern"&&this.checkDeclaration(i.left)}checkDuplicateExports(i,t){this.exportedIdentifiers.has(t)&&(t==="default"?this.raise(dt.DuplicateDefaultExport,{at:i}):this.raise(dt.DuplicateExport,{at:i,exportName:t})),this.exportedIdentifiers.add(t)}parseExportSpecifiers(i){let t=[],o=!0;for(this.expect(5);!this.eat(8);){if(o)o=!1;else if(this.expect(12),this.eat(8))break;let p=this.isContextual(126),y=this.match(129),$=this.startNode();$.local=this.parseModuleExportName(),t.push(this.parseExportSpecifier($,y,i,p))}return t}parseExportSpecifier(i,t,o,p){return this.eatContextual(93)?i.exported=this.parseModuleExportName():t?i.exported=oe(i.local):i.exported||(i.exported=K(i.local)),this.finishNode(i,"ExportSpecifier")}parseModuleExportName(){if(this.match(129)){let i=this.parseStringLiteral(this.state.value),t=i.value.match(Ua);return t&&this.raise(dt.ModuleExportNameHasLoneSurrogate,{at:i,surrogateCharCode:t[0].charCodeAt(0)}),i}return this.parseIdentifier(!0)}parseImport(i){if(i.specifiers=[],!this.match(129)){let o=!this.maybeParseDefaultImportSpecifier(i)||this.eat(12),p=o&&this.maybeParseStarImportSpecifier(i);o&&!p&&this.parseNamedImportSpecifiers(i),this.expectContextual(97)}i.source=this.parseImportSource();let t=this.maybeParseImportAssertions();if(t)i.assertions=t;else{let o=this.maybeParseModuleAttributes();o&&(i.attributes=o)}return this.semicolon(),this.finishNode(i,"ImportDeclaration")}parseImportSource(){return this.match(129)||this.unexpected(),this.parseExprAtom()}shouldParseDefaultImport(i){return jn(this.state.type)}parseImportSpecifierLocal(i,t,o){t.local=this.parseIdentifier(),i.specifiers.push(this.finishImportSpecifier(t,o))}finishImportSpecifier(i,t){return this.checkLVal(i.local,{in:i,binding:Aa}),this.finishNode(i,t)}parseAssertEntries(){let i=[],t=new Set;do{if(this.match(8))break;let o=this.startNode(),p=this.state.value;if(t.has(p)&&this.raise(dt.ModuleAttributesWithDuplicateKeys,{at:this.state.startLoc,key:p}),t.add(p),this.match(129)?o.key=this.parseStringLiteral(p):o.key=this.parseIdentifier(!0),this.expect(14),!this.match(129))throw this.raise(dt.ModuleAttributeInvalidValue,{at:this.state.startLoc});o.value=this.parseStringLiteral(this.state.value),this.finishNode(o,"ImportAttribute"),i.push(o)}while(this.eat(12));return i}maybeParseModuleAttributes(){if(this.match(76)&&!this.hasPrecedingLineBreak())this.expectPlugin("moduleAttributes"),this.next();else return this.hasPlugin("moduleAttributes")?[]:null;let i=[],t=new Set;do{let o=this.startNode();if(o.key=this.parseIdentifier(!0),o.key.name!=="type"&&this.raise(dt.ModuleAttributeDifferentFromType,{at:o.key}),t.has(o.key.name)&&this.raise(dt.ModuleAttributesWithDuplicateKeys,{at:o.key,key:o.key.name}),t.add(o.key.name),this.expect(14),!this.match(129))throw this.raise(dt.ModuleAttributeInvalidValue,{at:this.state.startLoc});o.value=this.parseStringLiteral(this.state.value),this.finishNode(o,"ImportAttribute"),i.push(o)}while(this.eat(12));return i}maybeParseImportAssertions(){if(this.isContextual(94)&&!this.hasPrecedingLineBreak())this.expectPlugin("importAssertions"),this.next();else return this.hasPlugin("importAssertions")?[]:null;this.eat(5);let i=this.parseAssertEntries();return this.eat(8),i}maybeParseDefaultImportSpecifier(i){return this.shouldParseDefaultImport(i)?(this.parseImportSpecifierLocal(i,this.startNode(),"ImportDefaultSpecifier"),!0):!1}maybeParseStarImportSpecifier(i){if(this.match(55)){let t=this.startNode();return this.next(),this.expectContextual(93),this.parseImportSpecifierLocal(i,t,"ImportNamespaceSpecifier"),!0}return!1}parseNamedImportSpecifiers(i){let t=!0;for(this.expect(5);!this.eat(8);){if(t)t=!1;else{if(this.eat(14))throw this.raise(dt.DestructureNamedImport,{at:this.state.startLoc});if(this.expect(12),this.eat(8))break}let o=this.startNode(),p=this.match(129),y=this.isContextual(126);o.imported=this.parseModuleExportName();let $=this.parseImportSpecifier(o,p,i.importKind==="type"||i.importKind==="typeof",y);i.specifiers.push($)}}parseImportSpecifier(i,t,o,p){if(this.eatContextual(93))i.local=this.parseIdentifier();else{let{imported:y}=i;if(t)throw this.raise(dt.ImportBindingIsString,{at:i,importName:y.value});this.checkReservedWord(y.name,i.loc.start,!0,!0),i.local||(i.local=K(y))}return this.finishImportSpecifier(i,"ImportSpecifier")}isThisParam(i){return i.type==="Identifier"&&i.name==="this"}},fl=class extends aa{constructor(i,t){i=Lr(i),super(i,t),this.options=i,this.initializeScopes(),this.plugins=wu(this.options.plugins),this.filename=i.sourceFilename}getScopeHandler(){return uu}parse(){this.enterInitialScopes();let i=this.startNode(),t=this.startNode();return this.nextToken(),i.errors=null,this.parseTopLevel(i,t),i.errors=this.state.errors,i}};function wu(i){let t=new Map;for(let o of i){let[p,y]=Array.isArray(o)?o:[o,{}];t.has(p)||t.set(p,y||{})}return t}function _c(i,t){var o;if(((o=t)==null?void 0:o.sourceType)==="unambiguous"){t=Object.assign({},t);try{t.sourceType="module";let p=cu(t,i),y=p.parse();if(p.sawUnambiguousESM)return y;if(p.ambiguousScriptDifferentAst)try{return t.sourceType="script",cu(t,i).parse()}catch{}else y.program.sourceType="script";return y}catch(p){try{return t.sourceType="script",cu(t,i).parse()}catch{}throw p}}else return cu(t,i).parse()}function Ic(i,t){let o=cu(t,i);return o.options.strictMode&&(o.state.strict=!0),o.getExpression()}function Oc(i){let t={};for(let o of Object.keys(i))t[o]=Ws(i[o]);return t}var Tu=Oc(Bn);function cu(i,t){let o=fl;return i!=null&&i.plugins&&(xi(i.plugins),o=Ol(i.plugins)),new o(i,t)}var Il={};function Ol(i){let t=Vt.filter(y=>rs(i,y)),o=t.join("/"),p=Il[o];if(!p){p=fl;for(let y of t)p=Ci[y](p);Il[o]=p}return p}Qn.parse=_c,Qn.parseExpression=Ic,Qn.tokTypes=Tu}}),Nu=Ee({"src/language-js/parse/json.js"(Qn,An){xt();var yn=Bo(),ln=vo(),pn=tu(),Zn=lo();function ai(){let ti=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},{allowComments:Pi=!0}=ti;return function(ls){let{parseExpression:Mi}=tl(),ks;try{ks=Mi(ls,{tokens:!0,ranges:!0})}catch(da){throw Zn(da)}if(!Pi&&yn(ks.comments))throw ni(ks.comments[0],"Comment");return wi(ks),ks}}function ni(ti,Pi){let[ls,Mi]=[ti.loc.start,ti.loc.end].map(ks=>{let{line:da,column:is}=ks;return{line:da,column:is+1}});return ln("".concat(Pi," is not allowed in JSON."),{start:ls,end:Mi})}function wi(ti){switch(ti.type){case"ArrayExpression":for(let Pi of ti.elements)Pi!==null&&wi(Pi);return;case"ObjectExpression":for(let Pi of ti.properties)wi(Pi);return;case"ObjectProperty":if(ti.computed)throw ni(ti.key,"Computed key");if(ti.shorthand)throw ni(ti.key,"Shorthand property");ti.key.type!=="Identifier"&&wi(ti.key),wi(ti.value);return;case"UnaryExpression":{let{operator:Pi,argument:ls}=ti;if(Pi!=="+"&&Pi!=="-")throw ni(ti,"Operator '".concat(ti.operator,"'"));if(ls.type==="NumericLiteral"||ls.type==="Identifier"&&(ls.name==="Infinity"||ls.name==="NaN"))return;throw ni(ls,"Operator '".concat(Pi,"' before '").concat(ls.type,"'"))}case"Identifier":if(ti.name!=="Infinity"&&ti.name!=="NaN"&&ti.name!=="undefined")throw ni(ti,"Identifier '".concat(ti.name,"'"));return;case"TemplateLiteral":if(yn(ti.expressions))throw ni(ti.expressions[0],"'TemplateLiteral' with expression");for(let Pi of ti.quasis)wi(Pi);return;case"NullLiteral":case"BooleanLiteral":case"NumericLiteral":case"StringLiteral":case"TemplateElement":return;default:throw ni(ti,"'".concat(ti.type,"'"))}}var Wi=ai(),Qi={json:pn({parse:Wi,hasPragma(){return!0}}),json5:pn(Wi),"json-stringify":pn({parse:ai({allowComments:!1}),astFormat:"estree-json"})};An.exports=Qi}});xt();var za=Kt(),xl=or(),rl=Pr(),ma=tu(),Io=lo(),Bu=el(),nl=Nu(),Cl={sourceType:"module",allowImportExportEverywhere:!0,allowReturnOutsideFunction:!0,allowSuperOutsideMethod:!0,allowUndeclaredExports:!0,errorRecovery:!0,createParenthesizedExpressions:!0,plugins:["doExpressions","exportDefaultFrom","functionBind","functionSent","throwExpressions","partialApplication",["decorators",{decoratorsBeforeExport:!1}],"importAssertions","decimal","moduleBlocks","asyncDoExpressions","regexpUnicodeSets","destructuringPrivate","decoratorAutoAccessors"],tokens:!0,ranges:!0},El=["recordAndTuple",{syntaxType:"hash"}],Oo="v8intrinsic",Ia=[["pipelineOperator",{proposal:"hack",topicToken:"%"}],["pipelineOperator",{proposal:"minimal"}],["pipelineOperator",{proposal:"fsharp"}]],Xs=function(Qn){let An=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Cl;return Object.assign(Object.assign({},An),{},{plugins:[...An.plugins,...Qn]})},Da=/@(?:no)?flow\b/;function Ha(Qn,An){if(An.filepath&&An.filepath.endsWith(".js.flow"))return!0;let yn=xl(Qn);yn&&(Qn=Qn.slice(yn.length));let ln=rl(Qn,0);return ln!==!1&&(Qn=Qn.slice(0,ln)),Da.test(Qn)}function $a(Qn,An,yn){let ln=tl()[Qn](An,yn),pn=ln.errors.find(Zn=>!xa.has(Zn.reasonCode));if(pn)throw pn;return ln}function va(Qn){for(var An=arguments.length,yn=new Array(An>1?An-1:0),ln=1;ln<An;ln++)yn[ln-1]=arguments[ln];return function(pn,Zn){let ai=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if((ai.parser==="babel"||ai.parser==="__babel_estree")&&Ha(pn,ai))return ai.parser="babel-flow",Du(pn,Zn,ai);let ni=yn;ai.__babelSourceType==="script"&&(ni=ni.map(ti=>Object.assign(Object.assign({},ti),{},{sourceType:"script"}))),/#[[{]/.test(pn)&&(ni=ni.map(ti=>Xs([El],ti)));let wi=/%[A-Z]/.test(pn);pn.includes("|>")?ni=(wi?[...Ia,Oo]:Ia).flatMap(ti=>ni.map(Pi=>Xs([ti],Pi))):wi&&(ni=ni.map(ti=>Xs([Oo],ti)));let{result:Wi,error:Qi}=za(...ni.map(ti=>()=>$a(Qn,pn,ti)));if(!Wi)throw Io(Qi);return ai.originalText=pn,Bu(Wi,ai)}}var Lo=va("parse",Xs(["jsx","flow"])),Du=va("parse",Xs(["jsx",["flow",{all:!0,enums:!0}]])),Ki=va("parse",Xs(["jsx","typescript"]),Xs(["typescript"])),Mo=va("parse",Xs(["jsx","flow","estree"])),_u=va("parseExpression",Xs(["jsx"])),jo=va("parseExpression",Xs(["typescript"])),xa=new Set(["StrictNumericEscape","StrictWith","StrictOctalLiteral","StrictDelete","StrictEvalArguments","StrictEvalArgumentsBinding","StrictFunction","EmptyTypeArguments","EmptyTypeParameters","ConstructorHasTypeParameters","UnsupportedParameterPropertyKind","UnexpectedParameterModifier","MixedLabeledAndUnlabeledElements","InvalidTupleMemberLabel","NonClassMethodPropertyHasAbstractModifer","ReadonlyForMethodSignature","ClassMethodHasDeclare","ClassMethodHasReadonly","InvalidModifierOnTypeMember","DuplicateAccessibilityModifier","IndexSignatureHasDeclare","DecoratorExportClass","ParamDupe","InvalidDecimal","RestTrailingComma","UnsupportedParameterDecorator","UnterminatedJsxContent","UnexpectedReservedWord","ModuleAttributesWithDuplicateKeys","LineTerminatorBeforeArrow","InvalidEscapeSequenceTemplate","NonAbstractClassHasAbstractMethod","UnsupportedPropertyDecorator","OptionalTypeBeforeRequired","PatternIsOptional","OptionalBindingPattern","DeclareClassFieldHasInitializer","TypeImportCannotSpecifyDefaultAndNamed","DeclareFunctionHasImplementation","ConstructorClassField","VarRedeclaration","InvalidPrivateFieldResolution","DuplicateExport"]),ru=ma(Lo),vu=ma(Ki),Ro=ma(_u),xo=ma(jo);It.exports={parsers:Object.assign(Object.assign({babel:ru,"babel-flow":ma(Du),"babel-ts":vu},nl),{},{__js_expression:Ro,__vue_expression:Ro,__vue_ts_expression:xo,__vue_event_binding:ru,__vue_ts_event_binding:vu,__babel_estree:ma(Mo)})}});return On()})})(Sm);const JD=zp(Sm.exports);function KD(s,c,l){const f={css:GD,html:XD,babel:JD};return Zs(()=>{if(!bs(c))return bs(s)||"/* empty */";try{return WD.format(bs(s)||"",{parser:l,plugins:[f[l]],singleQuote:!0,semi:!1})}catch(D){return console.error(D),`/* Error on prettifying: ${D.message} */
|
|
276
276
|
${bs(s)||""}`}})}function QD(s,c=!0){return KD(s,c,"css")}const YD={"h-full":""},ZD={p:"x4 y2",grid:"~ cols-4 gap-4"},ev=Gi("div",{op80:""}," Presets ",-1),tv={op50:"","ws-pre":""},rv={overflow:"auto"},nv=Gi("div",{op80:""}," Rules ",-1),iv=Gi("span",{op50:""},"dynamic",-1),sv=Gi("br",null,null,-1),av=Gi("span",{op50:""},"static",-1),ov=Gi("div",{op80:""}," Variants ",-1),uv=Gi("div",{op80:""}," Shortcuts ",-1),lv={key:0},cv=Gi("div",{op80:""}," Config File ",-1),pv=Gi("div",{op80:""}," Version ",-1),hv={op50:"","ws-pre":""},fv={b:"t main",p:"x4 y2",grid:"~ cols-4 gap-4"},dv=Gi("div",{op80:""}," Included Files ",-1),mv=Gi("div",{op80:""}," CSS Size ",-1),gv=Gi("span",{op50:""},"gzipped",-1),yv=Gi("div",{op80:""}," Matched Rules ",-1),Dv=Gi("div",{op80:""}," Layers ",-1),vv={op50:"","ws-pre":""},xv=Zu({__name:"Overview",setup(s){const c=Ba(null),l=VD(c,"overview-scrolls");Uh.execute();const f=Ba(!1),D=QD(Zs(()=>{var N;return(N=up.value)==null?void 0:N.css}),f);return(N,Y)=>{const le=qD,ye=jD,Me=ID,Oe=PD;return ya(),uo("div",YD,[ra(Me,{ref_key:"status",ref:c,p0:""},{default:jl(()=>{var st,mt,St,Wt,Zt,Jr,bt,Ot,$t,Ar,un,Kn,bn,oi,fi,Wn,Un,gi;return[Gi("div",ZD,[Gi("div",null,[ev,Gi("div",tv,ko((St=(mt=(st=bs(ro))==null?void 0:st.config)==null?void 0:mt.presets)==null?void 0:St.map(vr=>vr.name).join(`
|
|
277
277
|
`)),1)]),Gi("div",rv,[nv,Gu(" "+ko((Jr=(Zt=(Wt=bs(ro))==null?void 0:Wt.config)==null?void 0:Zt.rulesDynamic)==null?void 0:Jr.length)+" ",1),iv,sv,Gu(" "+ko(Object.keys(((Ot=(bt=bs(ro))==null?void 0:bt.config)==null?void 0:Ot.rulesStaticMap)||{}).length)+" ",1),av]),Gi("div",null,[ov,Gu(" "+ko((un=(Ar=($t=bs(ro))==null?void 0:$t.config)==null?void 0:Ar.variants)==null?void 0:un.length),1)]),Gi("div",null,[uv,Gu(" "+ko((Kn=bs(ro))==null?void 0:Kn.config.shortcuts.length),1)]),(bn=bs(ro))!=null&&bn.configPath?(ya(),uo("div",lv,[cv,ra(le,{id:bs(ro).configPath},null,8,["id"])])):Ap("",!0),Gi("div",null,[pv,Gi("div",hv,ko((oi=bs(ro))==null?void 0:oi.version),1)])]),Gi("div",fv,[Gi("div",null,[dv,Gu(" "+ko((fi=bs(ro))==null?void 0:fi.modules.length),1)]),Gi("div",null,[mv,Gu(" "+ko(((((Wn=bs(up))==null?void 0:Wn.gzipSize)||0)/1024).toFixed(2))+" KiB ",1),gv]),Gi("div",null,[yv,Gu(" "+ko((Un=bs(up))==null?void 0:Un.matched.length),1)]),Gi("div",null,[Dv,Gi("div",vv,ko((gi=bs(up))==null?void 0:gi.layers.join(`
|
|
278
|
-
`)),1)])]),ra(ye,{border:"t gray-400/20",title:"Output CSS"},{default:jl(()=>[Gi("label",null,[c0(Gi("input",{"onUpdate:modelValue":Y[0]||(Y[0]=vr=>f.value=vr),type:"checkbox"},null,512),[[uy,f.value]]),Gu(" Prettify ")])]),_:1})]}),_:1},512),ra(Oe,{"model-value":bs(D),"read-only":!0,mode:"css",class:"scrolls overview-scrolls",style:tp(bs(l))},null,8,["model-value","style"])])}}}),Cv={};function Ev(s,c){const l=xv;return ya(),bc(l)}const bv=vm(Cv,[["render",Ev]]),Av=()=>yh(()=>import("./repl.
|
|
278
|
+
`)),1)])]),ra(ye,{border:"t gray-400/20",title:"Output CSS"},{default:jl(()=>[Gi("label",null,[c0(Gi("input",{"onUpdate:modelValue":Y[0]||(Y[0]=vr=>f.value=vr),type:"checkbox"},null,512),[[uy,f.value]]),Gu(" Prettify ")])]),_:1})]}),_:1},512),ra(Oe,{"model-value":bs(D),"read-only":!0,mode:"css",class:"scrolls overview-scrolls",style:tp(bs(l))},null,8,["model-value","style"])])}}}),Cv={};function Ev(s,c){const l=xv;return ya(),bc(l)}const bv=vm(Cv,[["render",Ev]]),Av=()=>yh(()=>import("./repl.aa376791.js"),[]),wv=()=>yh(()=>import("./_id_.bebfe424.js"),[]),Tv=[{name:"repl",path:"/repl",component:Av,props:!0},{name:"index",path:"/",component:bv,props:!0},{name:"module-id",path:"/module/:id",component:wv,props:!0}];/*!
|
|
279
279
|
* vue-router v4.1.5
|
|
280
280
|
* (c) 2022 Eduardo San Martin Morote
|
|
281
281
|
* @license MIT
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{d as x,r as b,u as S,a as k,b as V,f as B,o as h,c as w,e as a,w as m,g as s,h as C,v as R,i as e,j as p,k as P,n as f,_ as E,l as N,m as U,p as $,q as I}from"./index.
|
|
1
|
+
import{d as x,r as b,u as S,a as k,b as V,f as B,o as h,c as w,e as a,w as m,g as s,h as C,v as R,i as e,j as p,k as P,n as f,_ as E,l as N,m as U,p as $,q as I}from"./index.5bce7f8c.js";const L={"h-full":"",grid:"~ rows-[max-content_1fr]","of-hidden":""},M=s("div",null," REPL Playground ",-1),T=s("div",{op60:""}," Edit your code below to test and play UnoCSS's matching and generating. ",-1),j={"h-full":"","of-hidden":"",grid:"","grid-cols-2":""},q=x({__name:"ReplPlayground",setup(y){const r=b(null),l=S(r,"rpel-scrolls"),t=k("unocss:inspector:repl",`<div class="text-sm hover:text-red">
|
|
2
2
|
Hello World
|
|
3
3
|
</div>`),o=V("unocss-inspector-safelist",!1),{data:d}=B(t,o);return(H,n)=>{var i,_;const g=E,v=N,u=U;return h(),w("div",L,[a(g,{ref_key:"status",ref:r},{default:m(()=>[M,T]),_:1},512),a(v,{border:"b gray-400/20",title:""},{default:m(()=>[s("label",null,[C(s("input",{"onUpdate:modelValue":n[0]||(n[0]=c=>p(o)?o.value=c:null),type:"checkbox"},null,512),[[R,e(o)]]),P(" Include safelist ")])]),_:1}),s("div",j,[a(u,{modelValue:e(t),"onUpdate:modelValue":n[1]||(n[1]=c=>p(t)?t.value=c:null),mode:"html",matched:((i=e(d))==null?void 0:i.matched)||[],class:"scrolls rpel-scrolls",style:f(e(l))},null,8,["modelValue","matched","style"]),a(u,{"b-l":"","b-main":"","model-value":((_=e(d))==null?void 0:_.css)||"/* empty */","read-only":!0,mode:"css",class:"scrolls rpel-scrolls",style:f(e(l))},null,8,["model-value","style"])])])}}}),z={};function D(y,r){const l=q;return h(),I(l)}const A=$(z,[["render",D]]);export{A as default};
|
package/dist/client/index.html
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
|
9
9
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
|
10
10
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@100;200;400&family=Fira+Code&display=swap" rel="stylesheet" />
|
|
11
|
-
<script type="module" crossorigin src="/__unocss/assets/index.
|
|
11
|
+
<script type="module" crossorigin src="/__unocss/assets/index.5bce7f8c.js"></script>
|
|
12
12
|
<link rel="stylesheet" href="/__unocss/assets/index.b630285a.css">
|
|
13
13
|
</head>
|
|
14
14
|
<body>
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s as k,t as I,d as M,x as O,y as W,r as C,u as D,z as U,A as Z,B as j,i as u,c as R,e as g,w as A,g as f,C as w,_ as q,o as E,k as S,D as V,E as N,n as P,h as G,v as H,F as K,G as J,m as L,l as Q,q as X,H as Y}from"./index.0273a1ac.js";const tt=t=>[...new Set(t.split(/\\?[\s'"`;={}]+/g))].filter(k),et={name:"split",order:0,extract({code:t}){return tt(t)}},B=/^(?!\[(?:[^:]+):(?:.+)\]$)((?:.+:)?!?)?(.*)$/,st=(t={})=>{var i,h,d;const a=(i=t.prefix)!=null?i:"un-",c=(h=t.prefixedOnly)!=null?h:!1,_=(d=t.trueToNonValued)!=null?d:!1;return{name:"attributify",match(r){const o=I(r);if(!o)return;let e=o[1];if(e.startsWith(a))e=e.slice(a.length);else if(c)return;const p=o[2],[,l="",s=p]=p.match(B)||[];return s==="~"||_&&s==="true"||!s?`${l}${e}`:`${l}${e}-${s}`}}},lt=/(<\w[\w:\.$-]*\s)((?:'[^>]*?'|"[^>]*?"|`[^>]*?`|\{[^>]*?\}|[^>]*?)*)/g,rt=/([?]|(?!\d|-{2}|-\d)[a-zA-Z0-9\u00A0-\uFFFF-_:%-]+)(?:=("[^"]*|'[^']*))?/g,z=/[\s'"`;>]+/,nt={name:"attributify",extract:({content:t,cursor:a})=>{const c=t.matchAll(lt);let _,i=0;for(const n of c){const[,x,y]=n,b=n.index+x.length;if(a>b&&a<=b+y.length){i=b,_=y;break}}if(!_)return null;const h=_.matchAll(rt);let d=0,r,o;for(const n of h){const[x,y,b]=n,$=i+n.index;if(a>$&&a<=$+x.length){d=$,r=y,o=b==null?void 0:b.slice(1);break}}if(!r||r==="class"||r==="className"||r===":class")return null;if(o===void 0)return{extracted:r,resolveReplacement(n){return{start:d,end:d+r.length,replacement:n}}};const e=d+r.length+2;let p=z.exec(o),l=0,s;for(;p;){const[n]=p;if(a>e+l&&a<=e+l+p.index){s=o.slice(l,l+p.index);break}l+=p.index+n.length,p=z.exec(o.slice(l))}s===void 0&&(s=o.slice(l));const[,m="",v]=s.match(B)||[];return{extracted:`${m}${r}-${v}`,transformSuggestions(n){return n.filter(x=>x.startsWith(`${m}${r}-`)).map(x=>m+x.slice(m.length+r.length+1))},resolveReplacement(n){return{start:l+e,end:l+e+s.length,replacement:m+n.slice(m.length+r.length+1)}}}}},at=["v-bind:",":"],F=/[\s'"`;]+/g,ct=/<\w(?=.*>)[\w:\.$-]*\s((?:['"`\{].*?['"`\}]|.*?)*?)>/gs,ot=/([?]|(?!\d|-{2}|-\d)[a-zA-Z0-9\u00A0-\uFFFF-_:!%-]+)(?:={?(["'])([^\2]*?)\2}?)?/g,T=["placeholder"],it=t=>{var i,h,d;const a=(i=t==null?void 0:t.ignoreAttributes)!=null?i:T,c=(h=t==null?void 0:t.nonValuedAttribute)!=null?h:!0,_=(d=t==null?void 0:t.trueToNonValued)!=null?d:!1;return{name:"attributify",extract({code:r}){const o=Array.from(r.matchAll(ct)).flatMap(e=>Array.from((e[1]||"").matchAll(ot))).flatMap(([,e,p,l])=>{if(a.includes(e))return[];for(const s of at)if(e.startsWith(s)){e=e.slice(s.length);break}if(!l){if(k(e)&&c!==!1){const s=[`[${e}=""]`];return _&&s.push(`[${e}="true"]`),s}return[]}return["class","className"].includes(e)?l.split(F).filter(k):l.split(F).filter(Boolean).map(s=>`[${e}~="${s}"]`)});return new Set(o)}}},ut=(t={})=>{var i,h,d,r,o;t.strict=(i=t.strict)!=null?i:!1,t.prefix=(h=t.prefix)!=null?h:"un-",t.prefixedOnly=(d=t.prefixedOnly)!=null?d:!1,t.nonValuedAttribute=(r=t.nonValuedAttribute)!=null?r:!0,t.ignoreAttributes=(o=t.ignoreAttributes)!=null?o:T;const a=[st(t)],c=[it(t)],_=[nt];return t.strict||c.unshift(et),{name:"@unocss/preset-attributify",variants:a,extractors:c,options:t,autocomplete:{extractors:_}}},dt={key:0,"h-full":"","of-hidden":""},ft=f("div",{op50:""}," Module ",-1),mt=f("div",{"i-carbon-launch":""},null,-1),ht=f("div",{op50:""}," Matched Rules ",-1),_t=f("div",{op50:""}," CSS Size ",-1),pt=f("span",{op50:""},"gzipped",-1),xt={key:0,"row-span-3":""},yt=f("div",{op50:""}," Potentially Unmatched ",-1),vt={"h-full":"","of-hidden":""},gt=M({__name:"ModuleInfo",props:{id:null},setup(t){const a=t,{data:c}=O(W(a,"id")),_=a.id.split(/\./g).pop(),i=C(null),h=D(i,"module-scrolls");function d(){fetch(`/__open-in-editor?file=${encodeURIComponent(a.id)}`)}const{extractors:r}=ut({strict:!0}),o=U(async()=>{var s;const l=new Set;if(r){const m={code:((s=c.value)==null?void 0:s.code)||""};for(const v of r){const n=await v.extract(m);n==null||n.forEach(x=>l.add(x))}}return Array.from(l).filter(m=>!m.startsWith("[")).filter(m=>{var v;return!((v=c.value)!=null&&v.matched.includes(m))})}),e=C(!1),p=Z(j(()=>{var l;return(l=c.value)==null?void 0:l.css}),e);return(l,s)=>{const m=J,v=q,n=L,x=Q;return u(c)?(E(),R("div",dt,[g(v,{ref_key:"status",ref:i,grid:"~ cols-3 gap-4"},{default:A(()=>{var y;return[f("div",null,[ft,f("a",{"cursor-pointer":"",op80:"","hover:op100":"",onClick:d},[g(m,{id:u(c).id,"mr-1":""},null,8,["id"]),mt])]),f("div",null,[ht,S(" "+V(u(c).matched.length),1)]),f("div",null,[_t,S(" "+V(((((y=u(c))==null?void 0:y.gzipSize)||0)/1024).toFixed(2))+" KiB ",1),pt]),u(o).length?(E(),R("div",xt,[yt,f("code",null,V(u(o).join(", ")),1)])):w("",!0)]}),_:1},512),f("div",vt,[g(u(K),null,{default:A(()=>[g(u(N),{size:"50"},{default:A(()=>[g(n,{"h-full":"","model-value":u(c).code,"read-only":!0,mode:u(_),matched:u(c).matched,class:"scrolls module-scrolls",style:P(u(h))},null,8,["model-value","mode","matched","style"])]),_:1}),g(u(N),{size:"50"},{default:A(()=>[f("div",null,[g(x,{border:"l b gray-400/20",title:"Output CSS"},{default:A(()=>[f("label",null,[G(f("input",{"onUpdate:modelValue":s[0]||(s[0]=y=>e.value=y),type:"checkbox"},null,512),[[H,e.value]]),S(" Prettify ")])]),_:1}),g(n,{"h-full":"",b:"l main","model-value":u(p),"read-only":!0,mode:"css",class:"scrolls module-scrolls",style:P(u(h))},null,8,["model-value","style"])])]),_:1})]),_:1})])])):w("",!0)}}}),At=M({__name:"[id]",setup(t){const a=Y();return(c,_)=>{const i=gt;return E(),X(i,{id:u(a).params.id},null,8,["id"])}}});export{At as default};
|