diff --git a/asset-manifest.json b/asset-manifest.json
index dc27405b7..4b6a66c48 100644
--- a/asset-manifest.json
+++ b/asset-manifest.json
@@ -1,22 +1,22 @@
{
"files": {
"main.css": "/apidom/static/css/main.e6c13ad2.css",
- "main.js": "/apidom/static/js/main.1ad75d22.js",
- "static/js/144.eb8e1e5a.chunk.js": "/apidom/static/js/144.eb8e1e5a.chunk.js",
- "static/js/18.64e3be8e.chunk.js": "/apidom/static/js/18.64e3be8e.chunk.js",
- "static/js/884.470e9edd.chunk.js": "/apidom/static/js/884.470e9edd.chunk.js",
+ "main.js": "/apidom/static/js/main.1d65a9d1.js",
+ "static/js/938.6fccb2f7.chunk.js": "/apidom/static/js/938.6fccb2f7.chunk.js",
+ "static/js/878.846c200a.chunk.js": "/apidom/static/js/878.846c200a.chunk.js",
+ "static/js/838.d0ddd180.chunk.js": "/apidom/static/js/838.d0ddd180.chunk.js",
"static/media/tree-sitter-yaml.wasm": "/apidom/static/media/tree-sitter-yaml.d396281e11774e0afa7a.wasm",
"static/media/tree-sitter.wasm": "/apidom/static/media/tree-sitter.23aac571c96605dc2521.wasm",
"static/media/tree-sitter-json.wasm": "/apidom/static/media/tree-sitter-json.64a30dfa8a51b6a090eb.wasm",
"index.html": "/apidom/index.html",
"main.e6c13ad2.css.map": "/apidom/static/css/main.e6c13ad2.css.map",
- "main.1ad75d22.js.map": "/apidom/static/js/main.1ad75d22.js.map",
- "144.eb8e1e5a.chunk.js.map": "/apidom/static/js/144.eb8e1e5a.chunk.js.map",
- "18.64e3be8e.chunk.js.map": "/apidom/static/js/18.64e3be8e.chunk.js.map",
- "884.470e9edd.chunk.js.map": "/apidom/static/js/884.470e9edd.chunk.js.map"
+ "main.1d65a9d1.js.map": "/apidom/static/js/main.1d65a9d1.js.map",
+ "938.6fccb2f7.chunk.js.map": "/apidom/static/js/938.6fccb2f7.chunk.js.map",
+ "878.846c200a.chunk.js.map": "/apidom/static/js/878.846c200a.chunk.js.map",
+ "838.d0ddd180.chunk.js.map": "/apidom/static/js/838.d0ddd180.chunk.js.map"
},
"entrypoints": [
"static/css/main.e6c13ad2.css",
- "static/js/main.1ad75d22.js"
+ "static/js/main.1d65a9d1.js"
]
}
\ No newline at end of file
diff --git a/index.html b/index.html
index 1423c83ca..c1ac411d5 100644
--- a/index.html
+++ b/index.html
@@ -1 +1 @@
-
ApiDOM playground
\ No newline at end of file
+ApiDOM playground
\ No newline at end of file
diff --git a/static/js/144.eb8e1e5a.chunk.js b/static/js/144.eb8e1e5a.chunk.js
deleted file mode 100644
index eb676b423..000000000
--- a/static/js/144.eb8e1e5a.chunk.js
+++ /dev/null
@@ -1,2 +0,0 @@
-(()=>{var e={47988:(e,t,s)=>{"use strict";var n={};s.r(n),s.d(n,{hasElementSourceMap:()=>Me,includesClasses:()=>Te,includesSymbols:()=>Re,isAnnotationElement:()=>Pe,isArrayElement:()=>Ee,isBooleanElement:()=>ye,isCommentElement:()=>$e,isElement:()=>ge,isLinkElement:()=>je,isMemberElement:()=>we,isNullElement:()=>be,isNumberElement:()=>ve,isObjectElement:()=>xe,isParseResultElement:()=>Oe,isPrimitiveElement:()=>Be,isRefElement:()=>Se,isSourceMapElement:()=>qe,isStringElement:()=>fe});var i={};s.r(i),s.d(i,{detect:()=>Ns,detectionRegExp:()=>Is,lexicalAnalysis:()=>vt,mediaTypes:()=>Ds,namespace:()=>Cs,parse:()=>Vs,syntacticAnalysis:()=>kt,syntacticAnalysisDirect:()=>kt,syntacticAnalysisIndirect:()=>ks});var r={};s.r(r),s.d(r,{detect:()=>Vi,lexicalAnalysis:()=>Hs,mediaTypes:()=>Ni,namespace:()=>Di,parse:()=>Wi,syntacticAnalysis:()=>Ii});var o={};s.r(o),s.d(o,{isJSONReferenceElement:()=>qo,isJSONSchemaElement:()=>Oo,isLinkDescriptionElement:()=>Mo,isMediaElement:()=>Bo});var c={};s.r(c),s.d(c,{isReferenceLikeElement:()=>yc,isSwaggerExtension:()=>bc});var a={};s.r(a),s.d(a,{isContactElement:()=>sa,isDefinitionsElement:()=>xa,isExampleElement:()=>ha,isExternalDocumentationElement:()=>oa,isHeaderElement:()=>da,isHeadersElement:()=>ua,isInfoElement:()=>ea,isItemsElement:()=>aa,isLicenseElement:()=>ta,isOperationElement:()=>ra,isParameterElement:()=>ca,isParametersDefinitionsElement:()=>Ea,isPathItemElement:()=>ia,isPathsElement:()=>na,isReferenceElement:()=>ga,isResponseElement:()=>pa,isResponsesDefinitionsElement:()=>ba,isResponsesElement:()=>la,isSchemaElement:()=>fa,isScopesElement:()=>ja,isSecurityDefinitionsElement:()=>ya,isSecurityRequirementElement:()=>Sa,isSecuritySchemeElement:()=>wa,isSwaggerElement:()=>Yc,isSwaggerVersionElement:()=>Zc,isTagElement:()=>ma,isXmlElement:()=>va});var l={};s.r(l),s.d(l,{detect:()=>bp,detectionRegExp:()=>vp,mediaTypes:()=>fp,namespace:()=>xp,parse:()=>yp});var p={};s.r(p),s.d(p,{detect:()=>jp,detectionRegExp:()=>wp,mediaTypes:()=>Ep,namespace:()=>Pp,parse:()=>Sp});var u={};s.r(u),s.d(u,{isBooleanJsonSchemaElement:()=>Hh,isCallbackElement:()=>Ph,isComponentsElement:()=>$h,isContactElement:()=>Oh,isExampleElement:()=>qh,isExternalDocumentationElement:()=>Bh,isHeaderElement:()=>Mh,isInfoElement:()=>Rh,isLicenseElement:()=>Th,isLinkElement:()=>Ah,isMediaTypeElement:()=>Xh,isOpenApi3_0Element:()=>kh,isOpenapiElement:()=>Fh,isOperationElement:()=>Ch,isParameterElement:()=>Ih,isPathItemElement:()=>Dh,isPathsElement:()=>Nh,isReferenceElement:()=>Vh,isRequestBodyElement:()=>Wh,isResponseElement:()=>Lh,isResponsesElement:()=>Uh,isSchemaElement:()=>Jh,isSecurityRequirementElement:()=>_h,isSecuritySchemeElement:()=>Gh,isServerElement:()=>Qh,isServerVariableElement:()=>Kh,isServersElement:()=>zh});var h={};s.r(h),s.d(h,{detect:()=>Nf,detectionRegExp:()=>Df,mediaTypes:()=>If,namespace:()=>Wf,parse:()=>Vf});var d={};s.r(d),s.d(d,{detect:()=>Jf,detectionRegExp:()=>Uf,mediaTypes:()=>Lf,namespace:()=>_f,parse:()=>Hf});var m={};s.r(m),s.d(m,{isBooleanJsonSchemaElement:()=>Bb,isCallbackElement:()=>ob,isComponentsElement:()=>cb,isContactElement:()=>ab,isExampleElement:()=>lb,isExternalDocumentationElement:()=>pb,isHeaderElement:()=>ub,isInfoElement:()=>hb,isJsonSchemaDialectElement:()=>db,isLicenseElement:()=>mb,isLinkElement:()=>gb,isMediaTypeElement:()=>Fb,isOpenApi3_1Element:()=>vb,isOpenapiElement:()=>fb,isOperationElement:()=>bb,isParameterElement:()=>yb,isPathItemElement:()=>xb,isPathItemElementExternal:()=>Eb,isPathsElement:()=>wb,isReferenceElement:()=>jb,isReferenceElementExternal:()=>Sb,isRequestBodyElement:()=>Pb,isResponseElement:()=>$b,isResponsesElement:()=>Ob,isSchemaElement:()=>qb,isSecurityRequirementElement:()=>Mb,isSecuritySchemeElement:()=>Rb,isServerElement:()=>Tb,isServerVariableElement:()=>Ab});var g={};s.r(g),s.d(g,{detect:()=>nx,detectionRegExp:()=>sx,mediaTypes:()=>tx,namespace:()=>rx,parse:()=>ix});var f={};s.r(f),s.d(f,{detect:()=>ax,detectionRegExp:()=>cx,mediaTypes:()=>ox,namespace:()=>px,parse:()=>lx});var v={};s.r(v),s.d(v,{isJSONReferenceElement:()=>qo,isJSONSchemaElement:()=>Px,isLinkDescriptionElement:()=>$x,isMediaElement:()=>Bo});var b={};s.r(b),s.d(b,{isJSONReferenceElement:()=>qo,isJSONSchemaElement:()=>dw,isLinkDescriptionElement:()=>mw});var y={};s.r(y),s.d(y,{isAsyncApi2Element:()=>qw,isAsyncApiVersionElement:()=>Bw,isBooleanJsonSchemaElement:()=>Uw,isChannelBindingsElement:()=>Mw,isChannelItemElement:()=>Rw,isChannelsElement:()=>Tw,isComponentsElement:()=>Aw,isContactElement:()=>Fw,isIdentifierElement:()=>kw,isInfoElement:()=>Cw,isLicenseElement:()=>Iw,isOperationElement:()=>Dw,isParameterElement:()=>Nw,isParametersElement:()=>Vw,isReferenceElement:()=>Ww,isSchemaElement:()=>Lw,isSecurityRequirementElement:()=>Jw,isServerBindingsElement:()=>_w,isServerElement:()=>Hw,isServerVariableElement:()=>Qw,isServersElement:()=>Gw});var x={};s.r(x),s.d(x,{detect:()=>IT,detectionRegExp:()=>CT,mediaTypes:()=>kT,namespace:()=>NT,parse:()=>DT});var E={};s.r(E),s.d(E,{detect:()=>LT,detectionRegExp:()=>WT,mediaTypes:()=>VT,namespace:()=>JT,parse:()=>UT});var w={};s.r(w),s.d(w,{isReferenceLikeElement:()=>xA,isWorkflowsSpecificationExtension:()=>yA});var j={};s.r(j),s.d(j,{isComponentsElement:()=>TF,isCriterionElement:()=>AF,isFailureActionCriteriaElement:()=>IF,isFailureActionElement:()=>CF,isInfoElement:()=>fF,isJSONSchemaElement:()=>DF,isParameterElement:()=>MF,isReferenceElement:()=>FF,isSourceDescriptionElement:()=>vF,isSourceDescriptionsElement:()=>bF,isStepDependsOnElement:()=>qF,isStepElement:()=>$F,isStepOnFailureElement:()=>SF,isStepOnSuccessElement:()=>jF,isStepOutputsElement:()=>PF,isStepParametersElement:()=>OF,isStepSuccessCriteriaElement:()=>BF,isSuccessActionCriteriaElement:()=>kF,isSuccessActionElement:()=>RF,isWorkflowElement:()=>wF,isWorkflowOutputsElement:()=>EF,isWorkflowStepsElement:()=>xF,isWorkflowsElement:()=>yF,isWorkflowsSpecElement:()=>mF,isWorkflowsSpecification1Element:()=>gF});var S={};s.r(S),s.d(S,{detect:()=>Nk,detectionRegExp:()=>Dk,mediaTypes:()=>Ik,namespace:()=>Wk,parse:()=>Vk});var P={};s.r(P),s.d(P,{detect:()=>Jk,detectionRegExp:()=>Uk,mediaTypes:()=>Lk,namespace:()=>_k,parse:()=>Hk});var $={};s.r($),s.d($,{isInfoElement:()=>MD,isMainElement:()=>BD,isPrincipleElement:()=>RD,isRequirementElement:()=>TD,isRequirementLevelElement:()=>AD,isScenarioElement:()=>FD,isStandardElement:()=>kD,isStandardIdentifierElement:()=>CD});var O=s(22764),q=s(64508),B=s(34968);class M extends q.M${constructor(e,t,s){super(e,t,s),this.element="annotation"}get code(){return this.attributes.get("code")}set code(e){this.attributes.set("code",e)}}const R=M;class T extends q.M${constructor(e,t,s){super(e,t,s),this.element="comment"}}const A=T;var F=s(89600);class k extends q.uQ{constructor(e,t,s){super(e,t,s),this.element="parseResult"}get api(){return this.children.filter((e=>e.classes.contains("api"))).first}get results(){return this.children.filter((e=>e.classes.contains("result")))}get result(){return this.results.first}get annotations(){return this.children.filter((e=>"annotation"===e.element))}get warnings(){return this.children.filter((e=>"annotation"===e.element&&e.classes.contains("warning")))}get errors(){return this.children.filter((e=>"annotation"===e.element&&e.classes.contains("error")))}get isEmpty(){return this.children.reject((e=>"annotation"===e.element)).isEmpty}replaceResult(e){const{result:t}=this;if((0,F.c)(t))return!1;const s=this.content.findIndex((e=>e===t));return-1!==s&&(this.content[s]=e,!0)}}const C=k;class I extends q.uQ{constructor(e,t,s){super(e,t,s),this.element="sourceMap"}get positionStart(){return this.children.filter((e=>e.classes.contains("position"))).get(0)}get positionEnd(){return this.children.filter((e=>e.classes.contains("position"))).get(1)}set position(e){if("undefined"===typeof e)return;const t=new q.uQ([e.start.row,e.start.column,e.start.char]),s=new q.uQ([e.end.row,e.end.column,e.end.char]);t.classes.push("position"),s.classes.push("position"),this.push(t).push(s)}}const D=I;class N extends q.MH{constructor(){super(),this.register("annotation",R),this.register("comment",A),this.register("parseResult",C),this.register("sourceMap",D)}}const V=new N,W=e=>{const t=new N;return(0,B.c)(e)&&t.use(e),t},L=V,U=function(e){return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:L).toRefract(e)};var J=s(49320),H=s(25868);const _=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:L;if((0,H.c)(e))try{return t.fromRefract(JSON.parse(e))}catch{}return(0,B.c)(e)&&(0,J.c)("element",e)?t.fromRefract(e):t.toElement(e)};var G=s(69952),Q=s(41008),K=s(42636),X=s(11204);const z=class extends X{constructor(e,t,s){if(super(e,t,s),this.name=this.constructor.name,"string"===typeof t&&(this.message=t),"function"===typeof Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error(t).stack,null!=s&&"object"===typeof s&&Object.hasOwn(s,"cause")&&!("cause"in this)){const{cause:e}=s;this.cause=e,e instanceof Error&&"stack"in e&&(this.stack="".concat(this.stack,"\nCAUSE: ").concat(e.stack))}}};class Y extends Error{static[Symbol.hasInstance](e){return super[Symbol.hasInstance](e)||Function.prototype[Symbol.hasInstance].call(z,e)}constructor(e,t){if(super(e,t),this.name=this.constructor.name,"string"===typeof e&&(this.message=e),"function"===typeof Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error(e).stack,null!=t&&"object"===typeof t&&Object.hasOwn(t,"cause")&&!("cause"in this)){const{cause:e}=t;this.cause=e,e instanceof Error&&"stack"in e&&(this.stack="".concat(this.stack,"\nCAUSE: ").concat(e.stack))}}}const Z=Y;const ee=class extends Z{constructor(e,t){if(super(e,t),null!=t&&"object"===typeof t){const{cause:e,...s}=t;Object.assign(this,s)}}},te=(e,t,s)=>{const n=e[t];if(null!=n){if(!s&&"function"===typeof n)return n;const e=s?n.leave:n.enter;if("function"===typeof e)return e}else{const n=s?e.leave:e.enter;if(null!=n){if("function"===typeof n)return n;const e=n[t];if("function"===typeof e)return e}}return null},se={},ne=e=>null===e||void 0===e?void 0:e.type,ie=e=>"string"===typeof ne(e),re=e=>Object.create(Object.getPrototypeOf(e),Object.getOwnPropertyDescriptors(e)),oe=function(e,t){let{keyMap:s=null,state:n={},breakSymbol:i=se,deleteNodeSymbol:r=null,skipVisitingNodeSymbol:o=!1,visitFnGetter:c=te,nodeTypeGetter:a=ne,nodePredicate:l=ie,nodeCloneFn:p=re,detectCycles:u=!0}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const h=s||{};let d,m,g=Array.isArray(e),f=[e],v=-1,b=[],y=e;const x=[],E=[];do{v+=1;const e=v===f.length;let s;const j=e&&0!==b.length;if(e){if(s=0===E.length?void 0:x.pop(),y=m,m=E.pop(),j)if(g){y=y.slice();let e=0;for(const[t,s]of b){const n=t-e;s===r?(y.splice(n,1),e+=1):y[n]=s}}else{y=p(y);for(const[e,t]of b)y[e]=t}v=d.index,f=d.keys,b=d.edits,g=d.inArray,d=d.prev}else if(m!==r&&void 0!==m){if(s=g?v:f[v],y=m[s],y===r||void 0===y)continue;x.push(s)}let S;if(!Array.isArray(y)){if(!l(y))throw new ee("Invalid AST Node: ".concat(String(y)),{node:y});if(u&&E.includes(y)){x.pop();continue}const r=c(t,a(y),e);if(r){for(const[e,s]of Object.entries(n))t[e]=s;S=r.call(t,y,s,m,x,E)}if(S===i)break;if(S===o){if(!e){x.pop();continue}}else if(void 0!==S&&(b.push([s,S]),!e)){if(!l(S)){x.pop();continue}y=S}}var w;if(void 0===S&&j&&b.push([s,y]),!e)d={inArray:g,index:v,keys:f,edits:b,prev:d},g=Array.isArray(y),f=g?y:null!==(w=h[a(y)])&&void 0!==w?w:[],v=-1,b=[],m!==r&&void 0!==m&&E.push(m),m=y}while(void 0!==d);return 0!==b.length?b[b.length-1][1]:e};oe[Symbol.for("nodejs.util.promisify.custom")]=async function(e,t){let{keyMap:s=null,state:n={},breakSymbol:i=se,deleteNodeSymbol:r=null,skipVisitingNodeSymbol:o=!1,visitFnGetter:c=te,nodeTypeGetter:a=ne,nodePredicate:l=ie,nodeCloneFn:p=re,detectCycles:u=!0}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const h=s||{};let d,m,g=Array.isArray(e),f=[e],v=-1,b=[],y=e;const x=[],E=[];do{v+=1;const e=v===f.length;let s;const j=e&&0!==b.length;if(e){if(s=0===E.length?void 0:x.pop(),y=m,m=E.pop(),j)if(g){y=y.slice();let e=0;for(const[t,s]of b){const n=t-e;s===r?(y.splice(n,1),e+=1):y[n]=s}}else{y=p(y);for(const[e,t]of b)y[e]=t}v=d.index,f=d.keys,b=d.edits,g=d.inArray,d=d.prev}else if(m!==r&&void 0!==m){if(s=g?v:f[v],y=m[s],y===r||void 0===y)continue;x.push(s)}let S;if(!Array.isArray(y)){if(!l(y))throw new ee("Invalid AST Node: ".concat(String(y)),{node:y});if(u&&E.includes(y)){x.pop();continue}const r=c(t,a(y),e);if(r){for(const[e,s]of Object.entries(n))t[e]=s;S=await r.call(t,y,s,m,x,E)}if(S===i)break;if(S===o){if(!e){x.pop();continue}}else if(void 0!==S&&(b.push([s,S]),!e)){if(!l(S)){x.pop();continue}y=S}}var w;if(void 0===S&&j&&b.push([s,y]),!e)d={inArray:g,index:v,keys:f,edits:b,prev:d},g=Array.isArray(y),f=g?y:null!==(w=h[a(y)])&&void 0!==w?w:[],v=-1,b=[],m!==r&&void 0!==m&&E.push(m),m=y}while(void 0!==d);return 0!==b.length?b[b.length-1][1]:e};var ce=s(88796),ae=s(87152);const le=(e,t)=>"object"===typeof t&&null!==t&&e in t&&"function"===typeof t[e],pe=e=>"object"===typeof e&&null!=e&&"_storedElement"in e&&"string"===typeof e._storedElement&&"_content"in e,ue=(e,t)=>"object"===typeof t&&null!==t&&"primitive"in t&&("function"===typeof t.primitive&&t.primitive()===e),he=(e,t)=>"object"===typeof t&&null!==t&&"classes"in t&&(Array.isArray(t.classes)||t.classes instanceof q.uQ)&&t.classes.includes(e),de=(e,t)=>"object"===typeof t&&null!==t&&"element"in t&&t.element===e,me=e=>e({hasMethod:le,hasBasicElementProps:pe,primitiveEq:ue,isElementType:de,hasClass:he}),ge=me((e=>{let{hasBasicElementProps:t,primitiveEq:s}=e;return e=>e instanceof q.gr||t(e)&&s(void 0,e)})),fe=me((e=>{let{hasBasicElementProps:t,primitiveEq:s}=e;return e=>e instanceof q.M$||t(e)&&s("string",e)})),ve=me((e=>{let{hasBasicElementProps:t,primitiveEq:s}=e;return e=>e instanceof q.wH||t(e)&&s("number",e)})),be=me((e=>{let{hasBasicElementProps:t,primitiveEq:s}=e;return e=>e instanceof q.WM||t(e)&&s("null",e)})),ye=me((e=>{let{hasBasicElementProps:t,primitiveEq:s}=e;return e=>e instanceof q.Ar||t(e)&&s("boolean",e)})),xe=me((e=>{let{hasBasicElementProps:t,primitiveEq:s,hasMethod:n}=e;return e=>e instanceof q.We||t(e)&&s("object",e)&&n("keys",e)&&n("values",e)&&n("items",e)})),Ee=me((e=>{let{hasBasicElementProps:t,primitiveEq:s,hasMethod:n}=e;return e=>e instanceof q.uQ&&!(e instanceof q.We)||t(e)&&s("array",e)&&n("push",e)&&n("unshift",e)&&n("map",e)&&n("reduce",e)})),we=me((e=>{let{hasBasicElementProps:t,isElementType:s,primitiveEq:n}=e;return e=>e instanceof q.u6||t(e)&&s("member",e)&&n(void 0,e)})),je=me((e=>{let{hasBasicElementProps:t,isElementType:s,primitiveEq:n}=e;return e=>e instanceof q.UH||t(e)&&s("link",e)&&n(void 0,e)})),Se=me((e=>{let{hasBasicElementProps:t,isElementType:s,primitiveEq:n}=e;return e=>e instanceof q.eE||t(e)&&s("ref",e)&&n(void 0,e)})),Pe=me((e=>{let{hasBasicElementProps:t,isElementType:s,primitiveEq:n}=e;return e=>e instanceof R||t(e)&&s("annotation",e)&&n("array",e)})),$e=me((e=>{let{hasBasicElementProps:t,isElementType:s,primitiveEq:n}=e;return e=>e instanceof A||t(e)&&s("comment",e)&&n("string",e)})),Oe=me((e=>{let{hasBasicElementProps:t,isElementType:s,primitiveEq:n}=e;return e=>e instanceof C||t(e)&&s("parseResult",e)&&n("array",e)})),qe=me((e=>{let{hasBasicElementProps:t,isElementType:s,primitiveEq:n}=e;return e=>e instanceof D||t(e)&&s("sourceMap",e)&&n("array",e)})),Be=e=>de("object",e)||de("array",e)||de("boolean",e)||de("number",e)||de("string",e)||de("null",e)||de("member",e),Me=e=>qe(e.meta.get("sourceMap")),Re=(e,t)=>{if(0===e.length)return!0;const s=t.attributes.get("symbols");return!!Ee(s)&&(0,ce.c)((0,ae.c)(s.toValue()),e)},Te=(e,t)=>0===e.length||(0,ce.c)((0,ae.c)(t.classes.toValue()),e);const Ae=class extends ee{constructor(e,t){super(e,t),(0,G.c)(this,"value",void 0),"undefined"!==typeof t&&(this.value=t.value)}};const Fe=class extends Ae{};const ke=class extends Ae{},Ce=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{visited:s=new WeakMap}=t,n={...t,visited:s};if(s.has(e))return s.get(e);if(e instanceof q.KeyValuePair){const{key:t,value:i}=e,r=ge(t)?Ce(t,n):t,o=ge(i)?Ce(i,n):i,c=new q.KeyValuePair(r,o);return s.set(e,c),c}if(e instanceof q.wL){const t=e=>Ce(e,n),i=[...e].map(t),r=new q.wL(i);return s.set(e,r),r}if(e instanceof q.eW){const t=e=>Ce(e,n),i=[...e].map(t),r=new q.eW(i);return s.set(e,r),r}if(ge(e)){const t=Ne(e);if(s.set(e,t),e.content)if(ge(e.content))t.content=Ce(e.content,n);else if(e.content instanceof q.KeyValuePair)t.content=Ce(e.content,n);else if(Array.isArray(e.content)){const s=e=>Ce(e,n);t.content=e.content.map(s)}else t.content=e.content;else t.content=e.content;return t}throw new Fe("Value provided to cloneDeep function couldn't be cloned",{value:e})};Ce.safe=e=>{try{return Ce(e)}catch{return e}};const Ie=e=>{const{key:t,value:s}=e;return new q.KeyValuePair(t,s)},De=e=>{const t=new e.constructor;if(t.element=e.element,e.meta.length>0&&(t._meta=Ce(e.meta)),e.attributes.length>0&&(t._attributes=Ce(e.attributes)),ge(e.content)){const s=e.content;t.content=De(s)}else Array.isArray(e.content)?t.content=[...e.content]:e.content instanceof q.KeyValuePair?t.content=Ie(e.content):t.content=e.content;return t},Ne=e=>{if(e instanceof q.KeyValuePair)return Ie(e);if(e instanceof q.wL)return(e=>{const t=[...e];return new q.wL(t)})(e);if(e instanceof q.eW)return(e=>{const t=[...e];return new q.eW(t)})(e);if(ge(e))return De(e);throw new ke("Value provided to cloneShallow function couldn't be cloned",{value:e})};Ne.safe=e=>{try{return Ne(e)}catch{return e}};const Ve=e=>xe(e)?"ObjectElement":Ee(e)?"ArrayElement":we(e)?"MemberElement":fe(e)?"StringElement":ye(e)?"BooleanElement":ve(e)?"NumberElement":be(e)?"NullElement":je(e)?"LinkElement":Se(e)?"RefElement":void 0,We=e=>ge(e)?Ne(e):re(e),Le=(0,Q.c)(Ve,H.c),Ue={ObjectElement:["content"],ArrayElement:["content"],MemberElement:["key","value"],StringElement:[],BooleanElement:[],NumberElement:[],NullElement:[],RefElement:[],LinkElement:[],Annotation:[],Comment:[],ParseResultElement:["content"],SourceMap:["content"]};class Je{constructor(){let{predicate:e=K.c,returnOnTrue:t,returnOnFalse:s}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};(0,G.c)(this,"result",void 0),(0,G.c)(this,"predicate",void 0),(0,G.c)(this,"returnOnTrue",void 0),(0,G.c)(this,"returnOnFalse",void 0),this.result=[],this.predicate=e,this.returnOnTrue=t,this.returnOnFalse=s}enter(e){return this.predicate(e)?(this.result.push(e),this.returnOnTrue):this.returnOnFalse}}const He=function(e,t){let{keyMap:s=Ue,...n}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return oe(e,t,{keyMap:s,nodeTypeGetter:Ve,nodePredicate:Le,nodeCloneFn:We,...n})};He[Symbol.for("nodejs.util.promisify.custom")]=async function(e,t){let{keyMap:s=Ue,...n}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return oe[Symbol.for("nodejs.util.promisify.custom")](e,t,{keyMap:s,nodeTypeGetter:Ve,nodePredicate:Le,nodeCloneFn:We,...n})};class _e{constructor(){(0,G.c)(this,"result",""),(0,G.c)(this,"nestingLevel",0)}enter(e){const{element:t}=e,s=t.charAt(0).toUpperCase()+t.slice(1),n=" ".repeat(this.nestingLevel);this.result+=this.nestingLevel>0?"\n":"",this.result+="".concat(n,"(").concat(s,"Element"),this.nestingLevel+=1}leave(){this.nestingLevel-=1,this.result+=")"}}const Ge=e=>{const t=new _e;return He(e,t),t.result};var Qe=s(30600);const Ke=e=>"string"===typeof(null===e||void 0===e?void 0:e.type)?e.type:Ve(e),Xe={EphemeralObject:["content"],EphemeralArray:["content"],...Ue},ze=function(e,t){let{keyMap:s=Xe,...n}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return He(e,t,{keyMap:s,nodeTypeGetter:Ke,nodePredicate:Qe.c,detectCycles:!1,deleteNodeSymbol:Symbol.for("delete-node"),skipVisitingNodeSymbol:Symbol.for("skip-visiting-node"),...n})};ze[Symbol.for("nodejs.util.promisify.custom")]=async function(e){let{keyMap:t=Xe,...s}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return He[Symbol.for("nodejs.util.promisify.custom")](e,visitor,{keyMap:t,nodeTypeGetter:Ke,nodePredicate:Qe.c,detectCycles:!1,deleteNodeSymbol:Symbol.for("delete-node"),skipVisitingNodeSymbol:Symbol.for("skip-visiting-node"),...s})};const Ye=class{constructor(e){(0,G.c)(this,"type","EphemeralArray"),(0,G.c)(this,"content",[]),(0,G.c)(this,"reference",void 0),this.content=e,this.reference=[]}toReference(){return this.reference}toArray(){return this.reference.push(...this.content),this.reference}};const Ze=class{constructor(e){(0,G.c)(this,"type","EphemeralObject"),(0,G.c)(this,"content",[]),(0,G.c)(this,"reference",void 0),this.content=e,this.reference={}}toReference(){return this.reference}toObject(){return Object.assign(this.reference,Object.fromEntries(this.content))}};class et{constructor(){(0,G.c)(this,"ObjectElement",{enter:e=>{if(this.references.has(e))return this.references.get(e).toReference();const t=new Ze(e.content);return this.references.set(e,t),t}}),(0,G.c)(this,"EphemeralObject",{leave:e=>e.toObject()}),(0,G.c)(this,"MemberElement",{enter:e=>[e.key,e.value]}),(0,G.c)(this,"ArrayElement",{enter:e=>{if(this.references.has(e))return this.references.get(e).toReference();const t=new Ye(e.content);return this.references.set(e,t),t}}),(0,G.c)(this,"EphemeralArray",{leave:e=>e.toArray()}),(0,G.c)(this,"references",new WeakMap)}BooleanElement(e){return e.toValue()}NumberElement(e){return e.toValue()}StringElement(e){return e.toValue()}NullElement(){return null}}const tt=e=>ge(e)?fe(e)||ve(e)||ye(e)||be(e)?e.toValue():ze(e,new et):e;var st=s(13652),nt=s(11792),it=s(74884);const rt=class extends Z{};const ot=class extends rt{};const ct=class extends Array{constructor(){super(...arguments),(0,G.c)(this,"unknownMediaType","application/octet-stream")}filterByFormat(){throw new ot("filterByFormat method in MediaTypes class is not yet implemented.")}findBy(){throw new ot("findBy method in MediaTypes class is not yet implemented.")}latest(){throw new ot("latest method in MediaTypes class is not yet implemented.")}};const at=class extends ee{constructor(e,t){super(e,t),(0,G.c)(this,"source",void 0),(0,G.c)(this,"parserOptions",void 0),"undefined"!==typeof t&&(this.source=t.source,this.parserOptions=t.parserOptions)}};const lt=class{constructor(){(0,G.c)(this,"adapters",[])}async detectAdapterCandidates(e){const t=[];for(const s of this.adapters)(0,nt.c)(s.detect)&&await s.detect(e)&&t.push(s);return t}async findAdapter(e,t){if((0,H.c)(t))return this.adapters.find((e=>!!(0,it.c)(e.mediaTypes)&&e.mediaTypes.includes(t)));const s=await this.detectAdapterCandidates(e);return(0,st.c)(s)}use(e){return this.adapters.push(e),this}async findNamespace(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const s=await this.findAdapter(e,t.mediaType);return null===s||void 0===s?void 0:s.namespace}async findMediaType(e){const t=await this.findAdapter(e,void 0);if("undefined"===typeof t)return(new ct).unknownMediaType;if("undefined"===typeof t.mediaTypes)return(new ct).unknownMediaType;if("undefined"===typeof t.detectionRegExp)return t.mediaTypes.latest();const{detectionRegExp:s}=t,n=e.match(s);if(null===n)return(new ct).unknownMediaType;const{groups:i}=n,r=(null===i||void 0===i?void 0:i.version)||(null===i||void 0===i?void 0:i.version_json)||(null===i||void 0===i?void 0:i.version_yaml),o=null!==i&&void 0!==i&&i.version_json?"json":null!==i&&void 0!==i&&i.version_yaml?"yaml":"generic";return"undefined"===typeof r?t.mediaTypes.latest():t.mediaTypes.findBy(r,o)}async parse(e){let t,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};try{t=await this.findAdapter(e,s.mediaType)}catch(n){throw new at("Encountered an unexpected error while matching parser adapters against the source.",{source:e,parserOptions:s,cause:n})}if((0,F.c)(t))throw new at("Source did not match any registered parsers",{source:e,parserOptions:s});try{return t.parse(e,s)}catch(n){throw new at("Parsing encountered an unexpected error.",{source:e,parserOptions:s,cause:n})}}};var pt=s(26536),ut=s(72764);const ht=globalThis.fetch;(0,nt.c)(ht)&&(globalThis.fetch=function(){for(var e=arguments.length,t=new Array(e),s=0;s{if(null===gt&&null===ft)ft=dt.init().then((()=>dt.Language.load(mt))).then((e=>{const t=new dt;return t.setLanguage(e),t})).finally((()=>{ft=null})),gt=await ft;else if(null===gt&&null!==ft)gt=await ft;else if(null===gt)throw new Z("Error while initializing web-tree-sitter and loading tree-sitter-json grammar.");return gt.parse(e)};var bt=s(44552),yt=s(70664),xt=s(7282);const Et=()=>({predicates:{...n},namespace:L}),wt={toolboxCreator:Et,visitorOptions:{nodeTypeGetter:Ve,exposeEdits:!0}},jt=function(e,t){let s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(0===t.length)return e;const n=(0,bt.c)(wt,s),{toolboxCreator:i,visitorOptions:r}=n,o=i(),c=t.map((e=>e(o))),a=function(e){let{visitFnGetter:t=te,nodeTypeGetter:s=ne,breakSymbol:n=se,deleteNodeSymbol:i=null,skipVisitingNodeSymbol:r=!1,exposeEdits:o=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const c=Symbol("skip"),a=new Array(e.length).fill(c);return{enter(l){let p=l,u=!1;for(var h=arguments.length,d=new Array(h>1?h-1:0),m=1;m1?o-1:0),p=1;p{let{Type:s,plugins:n=[]}=t;const i=new s(e);return jt(i,n,{toolboxCreator:Et,visitorOptions:{nodeTypeGetter:Ve}})},Pt=e=>function(t){return St(t,{...arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},Type:e})};q.We.refract=Pt(q.We),q.uQ.refract=Pt(q.uQ),q.M$.refract=Pt(q.M$),q.Ar.refract=Pt(q.Ar),q.WM.refract=Pt(q.WM),q.wH.refract=Pt(q.wH),q.UH.refract=Pt(q.UH),q.eE.refract=Pt(q.eE),R.refract=Pt(R),A.refract=Pt(A),C.refract=Pt(C),D.refract=Pt(D);const $t=class{constructor(e){(0,G.c)(this,"type",void 0),(0,G.c)(this,"startPosition",void 0),(0,G.c)(this,"endPosition",void 0),(0,G.c)(this,"startIndex",void 0),(0,G.c)(this,"endIndex",void 0),(0,G.c)(this,"text",void 0),(0,G.c)(this,"isNamed",void 0),(0,G.c)(this,"isMissing",void 0),(0,G.c)(this,"fieldName",void 0),(0,G.c)(this,"hasError",!1),(0,G.c)(this,"children",[]),this.type=e.nodeType,this.startPosition=e.startPosition,this.endPosition=e.endPosition,this.startIndex=e.startIndex,this.endIndex=e.endIndex,this.text=e.nodeText,this.isNamed=e.nodeIsNamed,this.isMissing=e.nodeIsMissing}get keyNode(){if("pair"===this.type)return this.children.find((e=>"key"===e.fieldName))}get valueNode(){if("pair"===this.type)return this.children.find((e=>"value"===e.fieldName))}setFieldName(e){return"function"===typeof e.currentFieldName?this.fieldName=e.currentFieldName():this.fieldName=e.currentFieldName,this}setHasError(e){return"function"===typeof e.currentNode?this.hasError=e.currentNode().hasError():this.hasError=e.currentNode.hasError(),this}pushChildren(){this.children.push(...arguments)}};class Ot{static toPosition(e){const t=new q.uQ([e.startPosition.row,e.startPosition.column,e.startIndex]),s=new q.uQ([e.endPosition.row,e.endPosition.column,e.endIndex]);return t.classes.push("position"),s.classes.push("position"),[t,s]}constructor(){(0,G.c)(this,"sourceMap",!1),(0,G.c)(this,"annotations",void 0),(0,G.c)(this,"ParseResultElement",{leave:e=>{const t=e.findElements(Be);if(t.length>0){t[0].classes.push("result")}this.annotations.forEach((t=>{e.push(t)})),this.annotations=[]}}),this.annotations=[]}enter(e){if(e instanceof $t&&!e.isNamed&&e.isMissing){const t=e.type||e.text,s="(Missing ".concat(t,")"),n=new R(s);n.classes.push("warning"),this.maybeAddSourceMap(e,n),this.annotations.push(n)}return null}document(e){const t=new C;return t._content=e.children,this.maybeAddSourceMap(e,t),t}object(e){const t=new q.We;return t._content=e.children,this.maybeAddSourceMap(e,t),t}array(e){const t=new q.uQ;return t._content=e.children,this.maybeAddSourceMap(e,t),t}pair(e){const t=new q.u6;return t.content.key=e.keyNode,t.content.value=e.valueNode,this.maybeAddSourceMap(e,t),e.children.length>3&&e.children.filter((e=>"ERROR"===e.type)).forEach((t=>{this.ERROR(t,e,[],[e])})),t}string(e){const t=new q.M$(JSON.parse(e.text));return this.maybeAddSourceMap(e,t),t}number(e){const t=new q.wH(Number(e.text));return this.maybeAddSourceMap(e,t),t}null(e){const t=new q.WM;return this.maybeAddSourceMap(e,t),t}true(e){const t=new q.Ar(!0);return this.maybeAddSourceMap(e,t),t}false(e){const t=new q.Ar(!1);return this.maybeAddSourceMap(e,t),t}ERROR(e,t,s,n){const i=!e.hasError,r=e.text,o=i?"(Unexpected ".concat(r,")"):"(Error ".concat(r,")"),c=new R(o);if(c.classes.push("error"),this.maybeAddSourceMap(e,c),0===n.length){const e=new C;return e.push(c),e}return this.annotations.push(c),null}maybeAddSourceMap(e,t){if(!this.sourceMap)return;const s=new D,n=Ot.toPosition(e);if(null!==n){const[e,t]=n;s.push(e),s.push(t)}s.astNode=e,t.meta.set("sourceMap",s)}}const qt=Ot;let Bt;Bt=Symbol.iterator;class Mt{constructor(e){(0,G.c)(this,"cursor",void 0),this.cursor=e}document(){return new $t(this.cursor)}object(){return new $t(this.cursor).setFieldName(this.cursor)}array(){return new $t(this.cursor).setFieldName(this.cursor)}pair(){return new $t(this.cursor)}string(){return new $t(this.cursor).setFieldName(this.cursor)}number(){return new $t(this.cursor).setFieldName(this.cursor)}null(){return new $t(this.cursor).setFieldName(this.cursor)}true(){return new $t(this.cursor).setFieldName(this.cursor)}false(){return new $t(this.cursor).setFieldName(this.cursor)}ERROR(){return new $t(this.cursor).setHasError(this.cursor)}*[Bt](){let e;if(e=this.cursor.nodeType in this?this[this.cursor.nodeType]():new $t(this.cursor),this.cursor.gotoFirstChild()){const[t]=new Mt(this.cursor);for(e.pushChildren(t);this.cursor.gotoNextSibling();){const t=new Mt(this.cursor);e.pushChildren(...t)}this.cursor.gotoParent()}yield e}}const Rt=Mt,Tt={document:["children"],object:["children"],array:["children"],string:["children"],property:["children"],key:["children"],error:["children"],...Ue},At=e=>Oe(e)?"ParseResultElement":ge(e)?Ve(e):ne(e),Ft=e=>ge(e)||ie(e),kt=function(e){let{sourceMap:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const s=new qt,n=e.walk(),i=new Rt(n),[r]=Array.from(i);return oe(r,s,{keyMap:Tt,nodeTypeGetter:At,nodePredicate:Ft,state:{sourceMap:t}})};class Ct{constructor(){let{children:e=[],position:t,isMissing:s=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};(0,G.c)(this,"type","node"),(0,G.c)(this,"isMissing",void 0),(0,G.c)(this,"children",void 0),(0,G.c)(this,"position",void 0),this.type=this.constructor.type,this.isMissing=s,this.children=e,this.position=t}clone(){const e=Object.create(Object.getPrototypeOf(this));return Object.getOwnPropertyNames(this).forEach((t=>{const s=Object.getOwnPropertyDescriptor(this,t);Object.defineProperty(e,t,s)})),e}}(0,G.c)(Ct,"type","node");const It=Ct;const Dt=class extends It{};class Nt extends Dt{get child(){return(0,st.c)(this.children)}}(0,G.c)(Nt,"type","document");const Vt=Nt;class Wt extends It{get rootNode(){return(0,st.c)(this.children)}}(0,G.c)(Wt,"type","parseResult");const Lt=Wt;class Ut{constructor(e){let{row:t,column:s,char:n}=e;(0,G.c)(this,"type",Ut.type),(0,G.c)(this,"row",void 0),(0,G.c)(this,"column",void 0),(0,G.c)(this,"char",void 0),this.row=t,this.column=s,this.char=n}}(0,G.c)(Ut,"type","point");class Jt{constructor(e){let{start:t,end:s}=e;(0,G.c)(this,"type",Jt.type),(0,G.c)(this,"start",void 0),(0,G.c)(this,"end",void 0),this.start=t,this.end=s}}(0,G.c)(Jt,"type","position");const Ht=Jt;class _t extends It{constructor(){let{value:e,...t}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};super({...t}),(0,G.c)(this,"value",void 0),this.value=e}}(0,G.c)(_t,"type","literal");const Gt=_t,Qt=(e,t)=>null!=t&&"object"===typeof t&&"type"in t&&t.type===e,Kt=e=>Qt("string",e),Xt=e=>Qt("false",e),zt=e=>Qt("true",e),Yt=e=>Qt("null",e),Zt=e=>Qt("number",e),es=e=>Qt("array",e),ts=e=>Qt("object",e),ss=e=>Qt("property",e),ns=e=>Qt("key",e);class is extends Dt{get properties(){return this.children.filter(ss)}}(0,G.c)(is,"type","object");const rs=is;class os extends Dt{get value(){if(1===this.children.length){return this.children[0].value}return this.children.filter((e=>(e=>Qt("stringContent",e))(e)||(e=>Qt("escapeSequence",e))(e))).reduce(((e,t)=>e+t.value),"")}}(0,G.c)(os,"type","string");const cs=os;class as extends cs{}(0,G.c)(as,"type","key");const ls=as;class ps extends Dt{get key(){return this.children.find(ns)}get value(){return this.children.find((e=>Xt(e)||zt(e)||Yt(e)||Zt(e)||Kt(e)||es(e)||ts(e)))}}(0,G.c)(ps,"type","property");const us=ps;class hs extends Dt{get items(){return this.children.filter((e=>Xt(e)||zt(e)||Yt(e)||Zt(e)||Kt(e)||es(e)||ts))}}(0,G.c)(hs,"type","array");const ds=hs;class ms extends Dt{constructor(e){let{value:t,...s}=e;super({...s}),(0,G.c)(this,"value",void 0),this.value=t}}(0,G.c)(ms,"type","value");const gs=ms;class fs extends gs{}(0,G.c)(fs,"type","stringContent");const vs=fs;class bs extends gs{}(0,G.c)(bs,"type","number");const ys=bs;class xs extends gs{}(0,G.c)(xs,"type","null");const Es=xs;class ws extends gs{}(0,G.c)(ws,"type","true");const js=ws;class Ss extends gs{}(0,G.c)(Ss,"type","false");const Ps=Ss;class $s extends It{constructor(){let{value:e,isUnexpected:t=!1,...s}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};super({...s}),(0,G.c)(this,"value",void 0),(0,G.c)(this,"isUnexpected",void 0),this.value=e,this.isUnexpected=t}}(0,G.c)($s,"type","error");const Os=$s,qs={document:["children"],object:["children"],array:["children"],string:["children"],property:["children"],key:["children"],error:["children"]};class Bs{constructor(){(0,G.c)(this,"document",{enter:e=>{const t=Bs.toPosition(e);return new Vt({children:e.children,position:t,isMissing:e.isMissing})},leave:e=>new Lt({children:[e]})})}static toPosition(e){const t=new Ut({row:e.startPosition.row,column:e.startPosition.column,char:e.startIndex}),s=new Ut({row:e.endPosition.row,column:e.endPosition.column,char:e.endIndex});return new Ht({start:t,end:s})}enter(e){if(e instanceof $t&&!e.isNamed){const t=Bs.toPosition(e),s=e.type||e.text,{isMissing:n}=e;return new Gt({value:s,position:t,isMissing:n})}}object(e){const t=Bs.toPosition(e);return new rs({children:e.children,position:t,isMissing:e.isMissing})}pair(e){const t=Bs.toPosition(e),s=e.children.slice(1),{keyNode:n}=e,i=new ls({children:(null===n||void 0===n?void 0:n.children)||[],position:null!=n?Bs.toPosition(n):void 0,isMissing:null!=n&&n.isMissing});return new us({children:[i,...s],position:t,isMissing:e.isMissing})}array(e){const t=Bs.toPosition(e);return new ds({children:e.children,position:t,isMissing:e.isMissing})}string(e){const t=Bs.toPosition(e),s=new vs({value:JSON.parse(e.text)});return new cs({children:[s],position:t,isMissing:e.isMissing})}number(e){const t=Bs.toPosition(e),s=e.text;return new ys({value:s,position:t,isMissing:e.isMissing})}null(e){const t=Bs.toPosition(e),s=e.text;return new Es({value:s,position:t,isMissing:e.isMissing})}true(e){const t=Bs.toPosition(e),s=e.text;return new js({value:s,position:t,isMissing:e.isMissing})}false(e){const t=Bs.toPosition(e),s=e.text;return new Ps({value:s,position:t,isMissing:e.isMissing})}ERROR(e,t,s,n){const i=Bs.toPosition(e),r=new Os({children:e.children,position:i,isUnexpected:!e.hasError,isMissing:e.isMissing,value:e.text});return 0===n.length?new Lt({children:[r]}):r}}const Ms=Bs,Rs={[Lt.type]:["children"],[Vt.type]:["children"],[rs.type]:["children"],[us.type]:["children"],[ds.type]:["children"],[Os.type]:["children"],...Ue},Ts=e=>Oe(e)?"ParseResultElement":ge(e)?Ve(e):ne(e),As=e=>ge(e)||ie(e);const Fs=class{constructor(){(0,G.c)(this,"sourceMap",!1),(0,G.c)(this,"annotations",void 0),(0,G.c)(this,"ParseResultElement",{leave:e=>{const t=e.findElements(Be);if(t.length>0){t[0].classes.push("result")}this.annotations.forEach((t=>{e.push(t)})),this.annotations=[]}}),this.annotations=[]}document(e){const t=new C;return t._content=e.children,t}object(e){const t=new q.We;return t._content=e.children,this.maybeAddSourceMap(e,t),t}property(e){const t=new q.u6;return t.content.key=e.key,t.content.value=e.value,this.maybeAddSourceMap(e,t),e.children.length>3&&e.children.filter((e=>"error"===e.type)).forEach((t=>{this.error(t,e,[],[e])})),t}key(e){const t=new q.M$(e.value);return this.maybeAddSourceMap(e,t),t}array(e){const t=new q.uQ;return t._content=e.children,this.maybeAddSourceMap(e,t),t}string(e){const t=new q.M$(e.value);return this.maybeAddSourceMap(e,t),t}number(e){const t=new q.wH(Number(e.value));return this.maybeAddSourceMap(e,t),t}null(e){const t=new q.WM;return this.maybeAddSourceMap(e,t),t}true(e){const t=new q.Ar(!0);return this.maybeAddSourceMap(e,t),t}false(e){const t=new q.Ar(!1);return this.maybeAddSourceMap(e,t),t}literal(e){if(e.isMissing){const t="(Missing ".concat(e.value,")"),s=new R(t);s.classes.push("warning"),this.maybeAddSourceMap(e,s),this.annotations.push(s)}return null}error(e,t,s,n){const i=e.isUnexpected?"(Unexpected ".concat(e.value,")"):"(Error ".concat(e.value,")"),r=new R(i);if(r.classes.push("error"),this.maybeAddSourceMap(e,r),0===n.length){const e=new C;return e.push(r),e}return this.annotations.push(r),null}maybeAddSourceMap(e,t){if(!this.sourceMap)return;const s=new D;s.position=e.position,s.astNode=e,t.meta.set("sourceMap",s)}},ks=function(e){let{sourceMap:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const s=e.walk(),n=new Rt(s),[i]=Array.from(n),r=new Ms,o=new Fs,c=oe(i,r,{keyMap:qs,state:{sourceMap:t}});return oe(c.rootNode,o,{keyMap:Rs,nodeTypeGetter:Ts,nodePredicate:As,state:{sourceMap:t}})},Cs=W(),Is=/(?^\s*true\s*$)|(?^\s*false\s*$)|(?^\s*null\s*$)|(?^\s*\d+\s*$)|(?