@shopify/create-hydrogen 5.0.28 → 5.0.30
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/acorn-CAM24XUM.js +17 -0
- package/dist/angular-DNP7YRKH.js +5 -0
- package/dist/assets/hydrogen/starter/CHANGELOG.md +47 -0
- package/dist/assets/hydrogen/starter/app/components/Aside.tsx +4 -2
- package/dist/assets/hydrogen/starter/app/components/CartMain.tsx +6 -3
- package/dist/assets/hydrogen/starter/app/components/CartSummary.tsx +117 -23
- package/dist/assets/hydrogen/starter/app/components/Header.tsx +3 -3
- package/dist/assets/hydrogen/starter/app/components/MockShopNotice.tsx +20 -0
- package/dist/assets/hydrogen/starter/app/entry.client.tsx +2 -3
- package/dist/assets/hydrogen/starter/app/routes/[robots.txt].tsx +14 -53
- package/dist/assets/hydrogen/starter/app/routes/_index.tsx +15 -9
- package/dist/assets/hydrogen/starter/app/routes/account.$.tsx +1 -1
- package/dist/assets/hydrogen/starter/app/routes/account.addresses.tsx +13 -13
- package/dist/assets/hydrogen/starter/app/routes/account.profile.tsx +1 -1
- package/dist/assets/hydrogen/starter/app/routes/account.tsx +4 -7
- package/dist/assets/hydrogen/starter/app/routes/blogs.$blogHandle._index.tsx +2 -9
- package/dist/assets/hydrogen/starter/app/routes/blogs._index.tsx +1 -4
- package/dist/assets/hydrogen/starter/app/routes/cart.tsx +1 -5
- package/dist/assets/hydrogen/starter/app/routes/collections.all.tsx +1 -3
- package/dist/assets/hydrogen/starter/app/routes/pages.$handle.tsx +2 -8
- package/dist/assets/hydrogen/starter/app/routes/policies.$handle.tsx +1 -4
- package/dist/assets/hydrogen/starter/app/routes/policies._index.tsx +1 -1
- package/dist/assets/hydrogen/starter/app/routes/products.$handle.tsx +2 -9
- package/dist/assets/hydrogen/starter/app/routes/search.tsx +18 -12
- package/dist/assets/hydrogen/starter/app/styles/app.css +51 -0
- package/dist/assets/hydrogen/starter/guides/predictiveSearch/predictiveSearch.md +3 -3
- package/dist/assets/hydrogen/starter/guides/search/search.md +1 -1
- package/dist/assets/hydrogen/starter/package.json +10 -10
- package/dist/assets/hydrogen/starter/vite.config.ts +1 -1
- package/dist/assets/hydrogen/vite/vite.config.js +1 -1
- package/dist/babel-Q7WGFTYC.js +16 -0
- package/dist/chunk-6JMCCVMB.js +1178 -0
- package/dist/chunk-AMAQOLRU.js +51 -0
- package/dist/{chunk-RUCJI22O.js → chunk-FOFKID43.js} +1 -1
- package/dist/{chunk-6YUUFKYO.js → chunk-KP5HTXEK.js} +1 -1
- package/dist/{chunk-Y5VZE2FH.js → chunk-MLIZM3D3.js} +1 -1
- package/dist/{chunk-VXJIQGAB.js → chunk-SOYTF5NM.js} +1 -1
- package/dist/chunk-SSCFXJTG.js +2 -0
- package/dist/chunk-TDF32DPQ.js +5 -0
- package/dist/create-app.js +185 -934
- package/dist/{del-VDYQZFAQ.js → del-SDQ4S47S.js} +1 -1
- package/dist/devtools-RYOXA5H7.js +8 -0
- package/dist/error-handler-SA6VDSNI.js +2 -0
- package/dist/estree-V6MYQTSR.js +45 -0
- package/dist/flow-6QBD7VFZ.js +21 -0
- package/dist/glimmer-F25SYUSG.js +38 -0
- package/dist/graphql-DIAYZHIY.js +29 -0
- package/dist/html-AE7KHAJ7.js +26 -0
- package/dist/{is-wsl-52AELLDM.js → is-wsl-7NORHMI2.js} +1 -1
- package/dist/markdown-W7E2MOQ2.js +63 -0
- package/dist/meriyah-37WUJX22.js +6 -0
- package/dist/{morph-S2LU6PQ4.js → morph-IIMCOPW3.js} +114 -114
- package/dist/{multipart-parser-MX4R5XJM.js → multipart-parser-JT5WYXDW.js} +1 -1
- package/dist/open-VLBBYVPL.js +2 -0
- package/dist/{out-U7AI7XUQ.js → out-YA75DDJD.js} +1 -1
- package/dist/postcss-7X2D3S46.js +62 -0
- package/dist/typescript-AXPPFPUX.js +22 -0
- package/dist/yaml-U74YVCK4.js +160 -0
- package/package.json +10 -9
- package/dist/chunk-AUULK6IN.js +0 -5
- package/dist/chunk-CJKPLQJ7.js +0 -51
- package/dist/chunk-YKN6SEJT.js +0 -1189
- package/dist/chunk-ZLNTSIDN.js +0 -2
- package/dist/devtools-3BYEW2L2.js +0 -8
- package/dist/error-handler-2JZDGPAN.js +0 -2
- package/dist/open-PMJ32HTM.js +0 -2
- /package/dist/{chunk-LBUW5UHX.js → chunk-Y52UPHAG.js} +0 -0
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from 'module';globalThis.require = __createRequire(import.meta.url);
|
|
2
|
+
import{i as Pt}from"./chunk-Y52UPHAG.js";Pt();var nr=Object.create,St=Object.defineProperty,rr=Object.getOwnPropertyDescriptor,ir=Object.getOwnPropertyNames,sr=Object.getPrototypeOf,or=Object.prototype.hasOwnProperty,Me=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Vt=(t,e)=>{for(var r in e)St(t,r,{get:e[r],enumerable:!0})},ar=(t,e,r,u)=>{if(e&&typeof e=="object"||typeof e=="function")for(let g of ir(e))!or.call(t,g)&&g!==r&&St(t,g,{get:()=>e[g],enumerable:!(u=rr(e,g))||u.enumerable});return t},bt=(t,e,r)=>(r=t!=null?nr(sr(t)):{},ar(e||!t||!t.__esModule?St(r,"default",{value:t,enumerable:!0}):r,t)),Pe=Me(t=>{"use strict";var e={ANCHOR:"&",COMMENT:"#",TAG:"!",DIRECTIVES_END:"-",DOCUMENT_END:"."},r={ALIAS:"ALIAS",BLANK_LINE:"BLANK_LINE",BLOCK_FOLDED:"BLOCK_FOLDED",BLOCK_LITERAL:"BLOCK_LITERAL",COMMENT:"COMMENT",DIRECTIVE:"DIRECTIVE",DOCUMENT:"DOCUMENT",FLOW_MAP:"FLOW_MAP",FLOW_SEQ:"FLOW_SEQ",MAP:"MAP",MAP_KEY:"MAP_KEY",MAP_VALUE:"MAP_VALUE",PLAIN:"PLAIN",QUOTE_DOUBLE:"QUOTE_DOUBLE",QUOTE_SINGLE:"QUOTE_SINGLE",SEQ:"SEQ",SEQ_ITEM:"SEQ_ITEM"},u="tag:yaml.org,2002:",g={MAP:"tag:yaml.org,2002:map",SEQ:"tag:yaml.org,2002:seq",STR:"tag:yaml.org,2002:str"};function y(l){let i=[0],n=l.indexOf(`
|
|
3
|
+
`);for(;n!==-1;)n+=1,i.push(n),n=l.indexOf(`
|
|
4
|
+
`,n);return i}function b(l){let i,n;return typeof l=="string"?(i=y(l),n=l):(Array.isArray(l)&&(l=l[0]),l&&l.context&&(l.lineStarts||(l.lineStarts=y(l.context.src)),i=l.lineStarts,n=l.context.src)),{lineStarts:i,src:n}}function A(l,i){if(typeof l!="number"||l<0)return null;let{lineStarts:n,src:s}=b(i);if(!n||!s||l>s.length)return null;for(let p=0;p<n.length;++p){let c=n[p];if(l<c)return{line:p,col:l-n[p-1]+1};if(l===c)return{line:p+1,col:1}}let o=n.length;return{line:o,col:l-n[o-1]+1}}function k(l,i){let{lineStarts:n,src:s}=b(i);if(!n||!(l>=1)||l>n.length)return null;let o=n[l-1],p=n[l];for(;p&&p>o&&s[p-1]===`
|
|
5
|
+
`;)--p;return s.slice(o,p)}function C({start:l,end:i},n,s=80){let o=k(l.line,n);if(!o)return null;let{col:p}=l;if(o.length>s)if(p<=s-10)o=o.substr(0,s-1)+"\u2026";else{let x=Math.round(s/2);o.length>p+x&&(o=o.substr(0,p+x-1)+"\u2026"),p-=o.length-s,o="\u2026"+o.substr(1-s)}let c=1,h="";i&&(i.line===l.line&&p+(i.col-l.col)<=s+1?c=i.col-l.col:(c=Math.min(o.length+1,s)-p,h="\u2026"));let E=p>1?" ".repeat(p-1):"",O="^".repeat(c);return`${o}
|
|
6
|
+
${E}${O}${h}`}var P=class Qt{static copy(i){return new Qt(i.start,i.end)}constructor(i,n){this.start=i,this.end=n||i}isEmpty(){return typeof this.start!="number"||!this.end||this.end<=this.start}setOrigRange(i,n){let{start:s,end:o}=this;if(i.length===0||o<=i[0])return this.origStart=s,this.origEnd=o,n;let p=n;for(;p<i.length&&!(i[p]>s);)++p;this.origStart=s+p;let c=p;for(;p<i.length&&!(i[p]>=o);)++p;return this.origEnd=o+p,c}},F=class Ae{static addStringTerminator(i,n,s){if(s[s.length-1]===`
|
|
7
|
+
`)return s;let o=Ae.endOfWhiteSpace(i,n);return o>=i.length||i[o]===`
|
|
8
|
+
`?s+`
|
|
9
|
+
`:s}static atDocumentBoundary(i,n,s){let o=i[n];if(!o)return!0;let p=i[n-1];if(p&&p!==`
|
|
10
|
+
`)return!1;if(s){if(o!==s)return!1}else if(o!==e.DIRECTIVES_END&&o!==e.DOCUMENT_END)return!1;let c=i[n+1],h=i[n+2];if(c!==o||h!==o)return!1;let E=i[n+3];return!E||E===`
|
|
11
|
+
`||E===" "||E===" "}static endOfIdentifier(i,n){let s=i[n],o=s==="<",p=o?[`
|
|
12
|
+
`," "," ",">"]:[`
|
|
13
|
+
`," "," ","[","]","{","}",","];for(;s&&p.indexOf(s)===-1;)s=i[n+=1];return o&&s===">"&&(n+=1),n}static endOfIndent(i,n){let s=i[n];for(;s===" ";)s=i[n+=1];return n}static endOfLine(i,n){let s=i[n];for(;s&&s!==`
|
|
14
|
+
`;)s=i[n+=1];return n}static endOfWhiteSpace(i,n){let s=i[n];for(;s===" "||s===" ";)s=i[n+=1];return n}static startOfLine(i,n){let s=i[n-1];if(s===`
|
|
15
|
+
`)return n;for(;s&&s!==`
|
|
16
|
+
`;)s=i[n-=1];return n+1}static endOfBlockIndent(i,n,s){let o=Ae.endOfIndent(i,s);if(o>s+n)return o;{let p=Ae.endOfWhiteSpace(i,o),c=i[p];if(!c||c===`
|
|
17
|
+
`)return p}return null}static atBlank(i,n,s){let o=i[n];return o===`
|
|
18
|
+
`||o===" "||o===" "||s&&!o}static nextNodeIsIndented(i,n,s){return!i||n<0?!1:n>0?!0:s&&i==="-"}static normalizeOffset(i,n){let s=i[n];return s?s!==`
|
|
19
|
+
`&&i[n-1]===`
|
|
20
|
+
`?n-1:Ae.endOfWhiteSpace(i,n):n}static foldNewline(i,n,s){let o=0,p=!1,c="",h=i[n+1];for(;h===" "||h===" "||h===`
|
|
21
|
+
`;){switch(h){case`
|
|
22
|
+
`:o=0,n+=1,c+=`
|
|
23
|
+
`;break;case" ":o<=s&&(p=!0),n=Ae.endOfWhiteSpace(i,n+2)-1;break;case" ":o+=1,n+=1;break}h=i[n+1]}return c||(c=" "),h&&o<=s&&(p=!0),{fold:c,offset:n,error:p}}constructor(i,n,s){Object.defineProperty(this,"context",{value:s||null,writable:!0}),this.error=null,this.range=null,this.valueRange=null,this.props=n||[],this.type=i,this.value=null}getPropValue(i,n,s){if(!this.context)return null;let{src:o}=this.context,p=this.props[i];return p&&o[p.start]===n?o.slice(p.start+(s?1:0),p.end):null}get anchor(){for(let i=0;i<this.props.length;++i){let n=this.getPropValue(i,e.ANCHOR,!0);if(n!=null)return n}return null}get comment(){let i=[];for(let n=0;n<this.props.length;++n){let s=this.getPropValue(n,e.COMMENT,!0);s!=null&&i.push(s)}return i.length>0?i.join(`
|
|
24
|
+
`):null}commentHasRequiredWhitespace(i){let{src:n}=this.context;if(this.header&&i===this.header.end||!this.valueRange)return!1;let{end:s}=this.valueRange;return i!==s||Ae.atBlank(n,s-1)}get hasComment(){if(this.context){let{src:i}=this.context;for(let n=0;n<this.props.length;++n)if(i[this.props[n].start]===e.COMMENT)return!0}return!1}get hasProps(){if(this.context){let{src:i}=this.context;for(let n=0;n<this.props.length;++n)if(i[this.props[n].start]!==e.COMMENT)return!0}return!1}get includesTrailingLines(){return!1}get jsonLike(){return[r.FLOW_MAP,r.FLOW_SEQ,r.QUOTE_DOUBLE,r.QUOTE_SINGLE].indexOf(this.type)!==-1}get rangeAsLinePos(){if(!this.range||!this.context)return;let i=A(this.range.start,this.context.root);if(!i)return;let n=A(this.range.end,this.context.root);return{start:i,end:n}}get rawValue(){if(!this.valueRange||!this.context)return null;let{start:i,end:n}=this.valueRange;return this.context.src.slice(i,n)}get tag(){for(let i=0;i<this.props.length;++i){let n=this.getPropValue(i,e.TAG,!1);if(n!=null){if(n[1]==="<")return{verbatim:n.slice(2,-1)};{let[s,o,p]=n.match(/^(.*!)([^!]*)$/);return{handle:o,suffix:p}}}}return null}get valueRangeContainsNewline(){if(!this.valueRange||!this.context)return!1;let{start:i,end:n}=this.valueRange,{src:s}=this.context;for(let o=i;o<n;++o)if(s[o]===`
|
|
25
|
+
`)return!0;return!1}parseComment(i){let{src:n}=this.context;if(n[i]===e.COMMENT){let s=Ae.endOfLine(n,i+1),o=new P(i,s);return this.props.push(o),s}return i}setOrigRanges(i,n){return this.range&&(n=this.range.setOrigRange(i,n)),this.valueRange&&this.valueRange.setOrigRange(i,n),this.props.forEach(s=>s.setOrigRange(i,n)),n}toString(){let{context:{src:i},range:n,value:s}=this;if(s!=null)return s;let o=i.slice(n.start,n.end);return Ae.addStringTerminator(i,n.end,o)}},ie=class extends Error{constructor(l,i,n){if(!n||!(i instanceof F))throw new Error(`Invalid arguments for new ${l}`);super(),this.name=l,this.message=n,this.source=i}makePretty(){if(!this.source)return;this.nodeType=this.source.type;let l=this.source.context&&this.source.context.root;if(typeof this.offset=="number"){this.range=new P(this.offset,this.offset+1);let i=l&&A(this.offset,l);if(i){let n={line:i.line,col:i.col+1};this.linePos={start:i,end:n}}delete this.offset}else this.range=this.source.range,this.linePos=this.source.rangeAsLinePos;if(this.linePos){let{line:i,col:n}=this.linePos.start;this.message+=` at line ${i}, column ${n}`;let s=l&&C(this.linePos,l);s&&(this.message+=`:
|
|
26
|
+
|
|
27
|
+
${s}
|
|
28
|
+
`)}delete this.source}},q=class extends ie{constructor(l,i){super("YAMLReferenceError",l,i)}},z=class extends ie{constructor(l,i){super("YAMLSemanticError",l,i)}},K=class extends ie{constructor(l,i){super("YAMLSyntaxError",l,i)}},ee=class extends ie{constructor(l,i){super("YAMLWarning",l,i)}};function ce(l,i,n){return i in l?Object.defineProperty(l,i,{value:n,enumerable:!0,configurable:!0,writable:!0}):l[i]=n,l}var M=class ft extends F{static endOfLine(i,n,s){let o=i[n],p=n;for(;o&&o!==`
|
|
29
|
+
`&&!(s&&(o==="["||o==="]"||o==="{"||o==="}"||o===","));){let c=i[p+1];if(o===":"&&(!c||c===`
|
|
30
|
+
`||c===" "||c===" "||s&&c===",")||(o===" "||o===" ")&&c==="#")break;p+=1,o=c}return p}get strValue(){if(!this.valueRange||!this.context)return null;let{start:i,end:n}=this.valueRange,{src:s}=this.context,o=s[n-1];for(;i<n&&(o===`
|
|
31
|
+
`||o===" "||o===" ");)o=s[--n-1];let p="";for(let h=i;h<n;++h){let E=s[h];if(E===`
|
|
32
|
+
`){let{fold:O,offset:x}=F.foldNewline(s,h,-1);p+=O,h=x}else if(E===" "||E===" "){let O=h,x=s[h+1];for(;h<n&&(x===" "||x===" ");)h+=1,x=s[h+1];x!==`
|
|
33
|
+
`&&(p+=h>O?s.slice(O,h+1):E)}else p+=E}let c=s[i];switch(c){case" ":{let h="Plain value cannot start with a tab character";return{errors:[new z(this,h)],str:p}}case"@":case"`":{let h=`Plain value cannot start with reserved character ${c}`;return{errors:[new z(this,h)],str:p}}default:return p}}parseBlockValue(i){let{indent:n,inFlow:s,src:o}=this.context,p=i,c=i;for(let h=o[p];h===`
|
|
34
|
+
`&&!F.atDocumentBoundary(o,p+1);h=o[p]){let E=F.endOfBlockIndent(o,n,p+1);if(E===null||o[E]==="#")break;o[E]===`
|
|
35
|
+
`?p=E:(c=ft.endOfLine(o,E,s),p=c)}return this.valueRange.isEmpty()&&(this.valueRange.start=i),this.valueRange.end=c,c}parse(i,n){this.context=i;let{inFlow:s,src:o}=i,p=n,c=o[p];return c&&c!=="#"&&c!==`
|
|
36
|
+
`&&(p=ft.endOfLine(o,n,s)),this.valueRange=new P(n,p),p=F.endOfWhiteSpace(o,p),p=this.parseComment(p),(!this.hasComment||this.valueRange.isEmpty())&&(p=this.parseBlockValue(p)),p}};t.Char=e,t.Node=F,t.PlainValue=M,t.Range=P,t.Type=r,t.YAMLError=ie,t.YAMLReferenceError=q,t.YAMLSemanticError=z,t.YAMLSyntaxError=K,t.YAMLWarning=ee,t._defineProperty=ce,t.defaultTagPrefix=u,t.defaultTags=g}),lr=Me(t=>{"use strict";var e=Pe(),r=class extends e.Node{constructor(){super(e.Type.BLANK_LINE)}get includesTrailingLines(){return!0}parse(M,l){return this.context=M,this.range=new e.Range(l,l+1),l+1}},u=class extends e.Node{constructor(M,l){super(M,l),this.node=null}get includesTrailingLines(){return!!this.node&&this.node.includesTrailingLines}parse(M,l){this.context=M;let{parseNode:i,src:n}=M,{atLineStart:s,lineStart:o}=M;!s&&this.type===e.Type.SEQ_ITEM&&(this.error=new e.YAMLSemanticError(this,"Sequence items must not have preceding content on the same line"));let p=s?l-o:M.indent,c=e.Node.endOfWhiteSpace(n,l+1),h=n[c],E=h==="#",O=[],x=null;for(;h===`
|
|
37
|
+
`||h==="#";){if(h==="#"){let W=e.Node.endOfLine(n,c+1);O.push(new e.Range(c,W)),c=W}else{s=!0,o=c+1;let W=e.Node.endOfWhiteSpace(n,o);n[W]===`
|
|
38
|
+
`&&O.length===0&&(x=new r,o=x.parse({src:n},o)),c=e.Node.endOfIndent(n,o)}h=n[c]}if(e.Node.nextNodeIsIndented(h,c-(o+p),this.type!==e.Type.SEQ_ITEM)?this.node=i({atLineStart:s,inCollection:!1,indent:p,lineStart:o,parent:this},c):h&&o>l+1&&(c=o-1),this.node){if(x){let W=M.parent.items||M.parent.contents;W&&W.push(x)}O.length&&Array.prototype.push.apply(this.props,O),c=this.node.range.end}else if(E){let W=O[0];this.props.push(W),c=W.end}else c=e.Node.endOfLine(n,l+1);let _=this.node?this.node.valueRange.end:c;return this.valueRange=new e.Range(l,_),c}setOrigRanges(M,l){return l=super.setOrigRanges(M,l),this.node?this.node.setOrigRanges(M,l):l}toString(){let{context:{src:M},node:l,range:i,value:n}=this;if(n!=null)return n;let s=l?M.slice(i.start,l.range.start)+String(l):M.slice(i.start,i.end);return e.Node.addStringTerminator(M,i.end,s)}},g=class extends e.Node{constructor(){super(e.Type.COMMENT)}parse(M,l){this.context=M;let i=this.parseComment(l);return this.range=new e.Range(l,i),i}};function y(M){let l=M;for(;l instanceof u;)l=l.node;if(!(l instanceof b))return null;let i=l.items.length,n=-1;for(let p=i-1;p>=0;--p){let c=l.items[p];if(c.type===e.Type.COMMENT){let{indent:h,lineStart:E}=c.context;if(h>0&&c.range.start>=E+h)break;n=p}else if(c.type===e.Type.BLANK_LINE)n=p;else break}if(n===-1)return null;let s=l.items.splice(n,i-n),o=s[0].range.start;for(;l.range.end=o,l.valueRange&&l.valueRange.end>o&&(l.valueRange.end=o),l!==M;)l=l.context.parent;return s}var b=class pt extends e.Node{static nextContentHasIndent(l,i,n){let s=e.Node.endOfLine(l,i)+1;i=e.Node.endOfWhiteSpace(l,s);let o=l[i];return o?i>=s+n?!0:o!=="#"&&o!==`
|
|
39
|
+
`?!1:pt.nextContentHasIndent(l,i,n):!1}constructor(l){super(l.type===e.Type.SEQ_ITEM?e.Type.SEQ:e.Type.MAP);for(let n=l.props.length-1;n>=0;--n)if(l.props[n].start<l.context.lineStart){this.props=l.props.slice(0,n+1),l.props=l.props.slice(n+1);let s=l.props[0]||l.valueRange;l.range.start=s.start;break}this.items=[l];let i=y(l);i&&Array.prototype.push.apply(this.items,i)}get includesTrailingLines(){return this.items.length>0}parse(l,i){this.context=l;let{parseNode:n,src:s}=l,o=e.Node.startOfLine(s,i),p=this.items[0];p.context.parent=this,this.valueRange=e.Range.copy(p.valueRange);let c=p.range.start-p.context.lineStart,h=i;h=e.Node.normalizeOffset(s,h);let E=s[h],O=e.Node.endOfWhiteSpace(s,o)===h,x=!1;for(;E;){for(;E===`
|
|
40
|
+
`||E==="#";){if(O&&E===`
|
|
41
|
+
`&&!x){let B=new r;if(h=B.parse({src:s},h),this.valueRange.end=h,h>=s.length){E=null;break}this.items.push(B),h-=1}else if(E==="#"){if(h<o+c&&!pt.nextContentHasIndent(s,h,c))return h;let B=new g;if(h=B.parse({indent:c,lineStart:o,src:s},h),this.items.push(B),this.valueRange.end=h,h>=s.length){E=null;break}}if(o=h+1,h=e.Node.endOfIndent(s,o),e.Node.atBlank(s,h)){let B=e.Node.endOfWhiteSpace(s,h),U=s[B];(!U||U===`
|
|
42
|
+
`||U==="#")&&(h=B)}E=s[h],O=!0}if(!E)break;if(h!==o+c&&(O||E!==":")){if(h<o+c){o>i&&(h=o);break}else if(!this.error){let B="All collection items must start at the same column";this.error=new e.YAMLSyntaxError(this,B)}}if(p.type===e.Type.SEQ_ITEM){if(E!=="-"){o>i&&(h=o);break}}else if(E==="-"&&!this.error){let B=s[h+1];if(!B||B===`
|
|
43
|
+
`||B===" "||B===" "){let U="A collection cannot be both a mapping and a sequence";this.error=new e.YAMLSyntaxError(this,U)}}let _=n({atLineStart:O,inCollection:!0,indent:c,lineStart:o,parent:this},h);if(!_)return h;if(this.items.push(_),this.valueRange.end=_.valueRange.end,h=e.Node.normalizeOffset(s,_.range.end),E=s[h],O=!1,x=_.includesTrailingLines,E){let B=h-1,U=s[B];for(;U===" "||U===" ";)U=s[--B];U===`
|
|
44
|
+
`&&(o=B+1,O=!0)}let W=y(_);W&&Array.prototype.push.apply(this.items,W)}return h}setOrigRanges(l,i){return i=super.setOrigRanges(l,i),this.items.forEach(n=>{i=n.setOrigRanges(l,i)}),i}toString(){let{context:{src:l},items:i,range:n,value:s}=this;if(s!=null)return s;let o=l.slice(n.start,i[0].range.start)+String(i[0]);for(let p=1;p<i.length;++p){let c=i[p],{atLineStart:h,indent:E}=c.context;if(h)for(let O=0;O<E;++O)o+=" ";o+=String(c)}return e.Node.addStringTerminator(l,n.end,o)}},A=class extends e.Node{constructor(){super(e.Type.DIRECTIVE),this.name=null}get parameters(){let M=this.rawValue;return M?M.trim().split(/[ \t]+/):[]}parseName(M){let{src:l}=this.context,i=M,n=l[i];for(;n&&n!==`
|
|
45
|
+
`&&n!==" "&&n!==" ";)n=l[i+=1];return this.name=l.slice(M,i),i}parseParameters(M){let{src:l}=this.context,i=M,n=l[i];for(;n&&n!==`
|
|
46
|
+
`&&n!=="#";)n=l[i+=1];return this.valueRange=new e.Range(M,i),i}parse(M,l){this.context=M;let i=this.parseName(l+1);return i=this.parseParameters(i),i=this.parseComment(i),this.range=new e.Range(l,i),i}},k=class dt extends e.Node{static startCommentOrEndBlankLine(l,i){let n=e.Node.endOfWhiteSpace(l,i),s=l[n];return s==="#"||s===`
|
|
47
|
+
`?n:i}constructor(){super(e.Type.DOCUMENT),this.directives=null,this.contents=null,this.directivesEndMarker=null,this.documentEndMarker=null}parseDirectives(l){let{src:i}=this.context;this.directives=[];let n=!0,s=!1,o=l;for(;!e.Node.atDocumentBoundary(i,o,e.Char.DIRECTIVES_END);)switch(o=dt.startCommentOrEndBlankLine(i,o),i[o]){case`
|
|
48
|
+
`:if(n){let p=new r;o=p.parse({src:i},o),o<i.length&&this.directives.push(p)}else o+=1,n=!0;break;case"#":{let p=new g;o=p.parse({src:i},o),this.directives.push(p),n=!1}break;case"%":{let p=new A;o=p.parse({parent:this,src:i},o),this.directives.push(p),s=!0,n=!1}break;default:return s?this.error=new e.YAMLSemanticError(this,"Missing directives-end indicator line"):this.directives.length>0&&(this.contents=this.directives,this.directives=[]),o}return i[o]?(this.directivesEndMarker=new e.Range(o,o+3),o+3):(s?this.error=new e.YAMLSemanticError(this,"Missing directives-end indicator line"):this.directives.length>0&&(this.contents=this.directives,this.directives=[]),o)}parseContents(l){let{parseNode:i,src:n}=this.context;this.contents||(this.contents=[]);let s=l;for(;n[s-1]==="-";)s-=1;let o=e.Node.endOfWhiteSpace(n,l),p=s===l;for(this.valueRange=new e.Range(o);!e.Node.atDocumentBoundary(n,o,e.Char.DOCUMENT_END);){switch(n[o]){case`
|
|
49
|
+
`:if(p){let c=new r;o=c.parse({src:n},o),o<n.length&&this.contents.push(c)}else o+=1,p=!0;s=o;break;case"#":{let c=new g;o=c.parse({src:n},o),this.contents.push(c),p=!1}break;default:{let c=e.Node.endOfIndent(n,o),h=i({atLineStart:p,indent:-1,inFlow:!1,inCollection:!1,lineStart:s,parent:this},c);if(!h)return this.valueRange.end=c;this.contents.push(h),o=h.range.end,p=!1;let E=y(h);E&&Array.prototype.push.apply(this.contents,E)}}o=dt.startCommentOrEndBlankLine(n,o)}if(this.valueRange.end=o,n[o]&&(this.documentEndMarker=new e.Range(o,o+3),o+=3,n[o])){if(o=e.Node.endOfWhiteSpace(n,o),n[o]==="#"){let c=new g;o=c.parse({src:n},o),this.contents.push(c)}switch(n[o]){case`
|
|
50
|
+
`:o+=1;break;case void 0:break;default:this.error=new e.YAMLSyntaxError(this,"Document end marker line cannot have a non-comment suffix")}}return o}parse(l,i){l.root=this,this.context=l;let{src:n}=l,s=n.charCodeAt(i)===65279?i+1:i;return s=this.parseDirectives(s),s=this.parseContents(s),s}setOrigRanges(l,i){return i=super.setOrigRanges(l,i),this.directives.forEach(n=>{i=n.setOrigRanges(l,i)}),this.directivesEndMarker&&(i=this.directivesEndMarker.setOrigRange(l,i)),this.contents.forEach(n=>{i=n.setOrigRanges(l,i)}),this.documentEndMarker&&(i=this.documentEndMarker.setOrigRange(l,i)),i}toString(){let{contents:l,directives:i,value:n}=this;if(n!=null)return n;let s=i.join("");return l.length>0&&((i.length>0||l[0].type===e.Type.COMMENT)&&(s+=`---
|
|
51
|
+
`),s+=l.join("")),s[s.length-1]!==`
|
|
52
|
+
`&&(s+=`
|
|
53
|
+
`),s}},C=class extends e.Node{parse(M,l){this.context=M;let{src:i}=M,n=e.Node.endOfIdentifier(i,l+1);return this.valueRange=new e.Range(l+1,n),n=e.Node.endOfWhiteSpace(i,n),n=this.parseComment(n),n}},P={CLIP:"CLIP",KEEP:"KEEP",STRIP:"STRIP"},F=class extends e.Node{constructor(M,l){super(M,l),this.blockIndent=null,this.chomping=P.CLIP,this.header=null}get includesTrailingLines(){return this.chomping===P.KEEP}get strValue(){if(!this.valueRange||!this.context)return null;let{start:M,end:l}=this.valueRange,{indent:i,src:n}=this.context;if(this.valueRange.isEmpty())return"";let s=null,o=n[l-1];for(;o===`
|
|
54
|
+
`||o===" "||o===" ";){if(l-=1,l<=M){if(this.chomping===P.KEEP)break;return""}o===`
|
|
55
|
+
`&&(s=l),o=n[l-1]}let p=l+1;s&&(this.chomping===P.KEEP?(p=s,l=this.valueRange.end):l=s);let c=i+this.blockIndent,h=this.type===e.Type.BLOCK_FOLDED,E=!0,O="",x="",_=!1;for(let W=M;W<l;++W){for(let U=0;U<c&&n[W]===" ";++U)W+=1;let B=n[W];if(B===`
|
|
56
|
+
`)x===`
|
|
57
|
+
`?O+=`
|
|
58
|
+
`:x=`
|
|
59
|
+
`;else{let U=e.Node.endOfLine(n,W),oe=n.slice(W,U);W=U,h&&(B===" "||B===" ")&&W<p?(x===" "?x=`
|
|
60
|
+
`:!_&&!E&&x===`
|
|
61
|
+
`&&(x=`
|
|
62
|
+
|
|
63
|
+
`),O+=x+oe,x=U<l&&n[U]||"",_=!0):(O+=x+oe,x=h&&W<p?" ":`
|
|
64
|
+
`,_=!1),E&&oe!==""&&(E=!1)}}return this.chomping===P.STRIP?O:O+`
|
|
65
|
+
`}parseBlockHeader(M){let{src:l}=this.context,i=M+1,n="";for(;;){let s=l[i];switch(s){case"-":this.chomping=P.STRIP;break;case"+":this.chomping=P.KEEP;break;case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":n+=s;break;default:return this.blockIndent=Number(n)||null,this.header=new e.Range(M,i),i}i+=1}}parseBlockValue(M){let{indent:l,src:i}=this.context,n=!!this.blockIndent,s=M,o=M,p=1;for(let c=i[s];c===`
|
|
66
|
+
`&&(s+=1,!e.Node.atDocumentBoundary(i,s));c=i[s]){let h=e.Node.endOfBlockIndent(i,l,s);if(h===null)break;let E=i[h],O=h-(s+l);if(this.blockIndent){if(E&&E!==`
|
|
67
|
+
`&&O<this.blockIndent){if(i[h]==="#")break;if(!this.error){let x=`Block scalars must not be less indented than their ${n?"explicit indentation indicator":"first line"}`;this.error=new e.YAMLSemanticError(this,x)}}}else if(i[h]!==`
|
|
68
|
+
`){if(O<p){let x="Block scalars with more-indented leading empty lines must use an explicit indentation indicator";this.error=new e.YAMLSemanticError(this,x)}this.blockIndent=O}else O>p&&(p=O);i[h]===`
|
|
69
|
+
`?s=h:s=o=e.Node.endOfLine(i,h)}return this.chomping!==P.KEEP&&(s=i[o]?o+1:o),this.valueRange=new e.Range(M+1,s),s}parse(M,l){this.context=M;let{src:i}=M,n=this.parseBlockHeader(l);return n=e.Node.endOfWhiteSpace(i,n),n=this.parseComment(n),n=this.parseBlockValue(n),n}setOrigRanges(M,l){return l=super.setOrigRanges(M,l),this.header?this.header.setOrigRange(M,l):l}},ie=class extends e.Node{constructor(M,l){super(M,l),this.items=null}prevNodeIsJsonLike(M=this.items.length){let l=this.items[M-1];return!!l&&(l.jsonLike||l.type===e.Type.COMMENT&&this.prevNodeIsJsonLike(M-1))}parse(M,l){this.context=M;let{parseNode:i,src:n}=M,{indent:s,lineStart:o}=M,p=n[l];this.items=[{char:p,offset:l}];let c=e.Node.endOfWhiteSpace(n,l+1);for(p=n[c];p&&p!=="]"&&p!=="}";){switch(p){case`
|
|
70
|
+
`:{o=c+1;let h=e.Node.endOfWhiteSpace(n,o);if(n[h]===`
|
|
71
|
+
`){let E=new r;o=E.parse({src:n},o),this.items.push(E)}if(c=e.Node.endOfIndent(n,o),c<=o+s&&(p=n[c],c<o+s||p!=="]"&&p!=="}")){let E="Insufficient indentation in flow collection";this.error=new e.YAMLSemanticError(this,E)}}break;case",":this.items.push({char:p,offset:c}),c+=1;break;case"#":{let h=new g;c=h.parse({src:n},c),this.items.push(h)}break;case"?":case":":{let h=n[c+1];if(h===`
|
|
72
|
+
`||h===" "||h===" "||h===","||p===":"&&this.prevNodeIsJsonLike()){this.items.push({char:p,offset:c}),c+=1;break}}default:{let h=i({atLineStart:!1,inCollection:!1,inFlow:!0,indent:-1,lineStart:o,parent:this},c);if(!h)return this.valueRange=new e.Range(l,c),c;this.items.push(h),c=e.Node.normalizeOffset(n,h.range.end)}}c=e.Node.endOfWhiteSpace(n,c),p=n[c]}return this.valueRange=new e.Range(l,c+1),p&&(this.items.push({char:p,offset:c}),c=e.Node.endOfWhiteSpace(n,c+1),c=this.parseComment(c)),c}setOrigRanges(M,l){return l=super.setOrigRanges(M,l),this.items.forEach(i=>{if(i instanceof e.Node)l=i.setOrigRanges(M,l);else if(M.length===0)i.origOffset=i.offset;else{let n=l;for(;n<M.length&&!(M[n]>i.offset);)++n;i.origOffset=i.offset+n,l=n}}),l}toString(){let{context:{src:M},items:l,range:i,value:n}=this;if(n!=null)return n;let s=l.filter(c=>c instanceof e.Node),o="",p=i.start;return s.forEach(c=>{let h=M.slice(p,c.range.start);p=c.range.end,o+=h+String(c),o[o.length-1]===`
|
|
73
|
+
`&&M[p-1]!==`
|
|
74
|
+
`&&M[p]===`
|
|
75
|
+
`&&(p+=1)}),o+=M.slice(p,i.end),e.Node.addStringTerminator(M,i.end,o)}},q=class Jt extends e.Node{static endOfQuote(l,i){let n=l[i];for(;n&&n!=='"';)i+=n==="\\"?2:1,n=l[i];return i+1}get strValue(){if(!this.valueRange||!this.context)return null;let l=[],{start:i,end:n}=this.valueRange,{indent:s,src:o}=this.context;o[n-1]!=='"'&&l.push(new e.YAMLSyntaxError(this,'Missing closing "quote'));let p="";for(let c=i+1;c<n-1;++c){let h=o[c];if(h===`
|
|
76
|
+
`){e.Node.atDocumentBoundary(o,c+1)&&l.push(new e.YAMLSemanticError(this,"Document boundary indicators are not allowed within string values"));let{fold:E,offset:O,error:x}=e.Node.foldNewline(o,c,s);p+=E,c=O,x&&l.push(new e.YAMLSemanticError(this,"Multi-line double-quoted string needs to be sufficiently indented"))}else if(h==="\\")switch(c+=1,o[c]){case"0":p+="\0";break;case"a":p+="\x07";break;case"b":p+="\b";break;case"e":p+="\x1B";break;case"f":p+="\f";break;case"n":p+=`
|
|
77
|
+
`;break;case"r":p+="\r";break;case"t":p+=" ";break;case"v":p+="\v";break;case"N":p+="\x85";break;case"_":p+="\xA0";break;case"L":p+="\u2028";break;case"P":p+="\u2029";break;case" ":p+=" ";break;case'"':p+='"';break;case"/":p+="/";break;case"\\":p+="\\";break;case" ":p+=" ";break;case"x":p+=this.parseCharCode(c+1,2,l),c+=2;break;case"u":p+=this.parseCharCode(c+1,4,l),c+=4;break;case"U":p+=this.parseCharCode(c+1,8,l),c+=8;break;case`
|
|
78
|
+
`:for(;o[c+1]===" "||o[c+1]===" ";)c+=1;break;default:l.push(new e.YAMLSyntaxError(this,`Invalid escape sequence ${o.substr(c-1,2)}`)),p+="\\"+o[c]}else if(h===" "||h===" "){let E=c,O=o[c+1];for(;O===" "||O===" ";)c+=1,O=o[c+1];O!==`
|
|
79
|
+
`&&(p+=c>E?o.slice(E,c+1):h)}else p+=h}return l.length>0?{errors:l,str:p}:p}parseCharCode(l,i,n){let{src:s}=this.context,o=s.substr(l,i),p=o.length===i&&/^[0-9a-fA-F]+$/.test(o)?parseInt(o,16):NaN;return isNaN(p)?(n.push(new e.YAMLSyntaxError(this,`Invalid escape sequence ${s.substr(l-2,i+2)}`)),s.substr(l-2,i+2)):String.fromCodePoint(p)}parse(l,i){this.context=l;let{src:n}=l,s=Jt.endOfQuote(n,i+1);return this.valueRange=new e.Range(i,s),s=e.Node.endOfWhiteSpace(n,s),s=this.parseComment(s),s}},z=class Gt extends e.Node{static endOfQuote(l,i){let n=l[i];for(;n;)if(n==="'"){if(l[i+1]!=="'")break;n=l[i+=2]}else n=l[i+=1];return i+1}get strValue(){if(!this.valueRange||!this.context)return null;let l=[],{start:i,end:n}=this.valueRange,{indent:s,src:o}=this.context;o[n-1]!=="'"&&l.push(new e.YAMLSyntaxError(this,"Missing closing 'quote"));let p="";for(let c=i+1;c<n-1;++c){let h=o[c];if(h===`
|
|
80
|
+
`){e.Node.atDocumentBoundary(o,c+1)&&l.push(new e.YAMLSemanticError(this,"Document boundary indicators are not allowed within string values"));let{fold:E,offset:O,error:x}=e.Node.foldNewline(o,c,s);p+=E,c=O,x&&l.push(new e.YAMLSemanticError(this,"Multi-line single-quoted string needs to be sufficiently indented"))}else if(h==="'")p+=h,c+=1,o[c]!=="'"&&l.push(new e.YAMLSyntaxError(this,"Unescaped single quote? This should not happen."));else if(h===" "||h===" "){let E=c,O=o[c+1];for(;O===" "||O===" ";)c+=1,O=o[c+1];O!==`
|
|
81
|
+
`&&(p+=c>E?o.slice(E,c+1):h)}else p+=h}return l.length>0?{errors:l,str:p}:p}parse(l,i){this.context=l;let{src:n}=l,s=Gt.endOfQuote(n,i+1);return this.valueRange=new e.Range(i,s),s=e.Node.endOfWhiteSpace(n,s),s=this.parseComment(s),s}};function K(M,l){switch(M){case e.Type.ALIAS:return new C(M,l);case e.Type.BLOCK_FOLDED:case e.Type.BLOCK_LITERAL:return new F(M,l);case e.Type.FLOW_MAP:case e.Type.FLOW_SEQ:return new ie(M,l);case e.Type.MAP_KEY:case e.Type.MAP_VALUE:case e.Type.SEQ_ITEM:return new u(M,l);case e.Type.COMMENT:case e.Type.PLAIN:return new e.PlainValue(M,l);case e.Type.QUOTE_DOUBLE:return new q(M,l);case e.Type.QUOTE_SINGLE:return new z(M,l);default:return null}}var ee=class He{static parseType(l,i,n){switch(l[i]){case"*":return e.Type.ALIAS;case">":return e.Type.BLOCK_FOLDED;case"|":return e.Type.BLOCK_LITERAL;case"{":return e.Type.FLOW_MAP;case"[":return e.Type.FLOW_SEQ;case"?":return!n&&e.Node.atBlank(l,i+1,!0)?e.Type.MAP_KEY:e.Type.PLAIN;case":":return!n&&e.Node.atBlank(l,i+1,!0)?e.Type.MAP_VALUE:e.Type.PLAIN;case"-":return!n&&e.Node.atBlank(l,i+1,!0)?e.Type.SEQ_ITEM:e.Type.PLAIN;case'"':return e.Type.QUOTE_DOUBLE;case"'":return e.Type.QUOTE_SINGLE;default:return e.Type.PLAIN}}constructor(l={},{atLineStart:i,inCollection:n,inFlow:s,indent:o,lineStart:p,parent:c}={}){e._defineProperty(this,"parseNode",(h,E)=>{if(e.Node.atDocumentBoundary(this.src,E))return null;let O=new He(this,h),{props:x,type:_,valueStart:W}=O.parseProps(E),B=K(_,x),U=B.parse(O,W);if(B.range=new e.Range(E,U),U<=E&&(B.error=new Error("Node#parse consumed no characters"),B.error.parseEnd=U,B.error.source=B,B.range.end=E+1),O.nodeStartsCollection(B)){!B.error&&!O.atLineStart&&O.parent.type===e.Type.DOCUMENT&&(B.error=new e.YAMLSyntaxError(B,"Block collection must not have preceding content here (e.g. directives-end indicator)"));let oe=new b(B);return U=oe.parse(new He(O),U),oe.range=new e.Range(E,U),oe}return B}),this.atLineStart=i??(l.atLineStart||!1),this.inCollection=n??(l.inCollection||!1),this.inFlow=s??(l.inFlow||!1),this.indent=o??l.indent,this.lineStart=p??l.lineStart,this.parent=c??(l.parent||{}),this.root=l.root,this.src=l.src}nodeStartsCollection(l){let{inCollection:i,inFlow:n,src:s}=this;if(i||n)return!1;if(l instanceof u)return!0;let o=l.range.end;return s[o]===`
|
|
82
|
+
`||s[o-1]===`
|
|
83
|
+
`?!1:(o=e.Node.endOfWhiteSpace(s,o),s[o]===":")}parseProps(l){let{inFlow:i,parent:n,src:s}=this,o=[],p=!1;l=this.atLineStart?e.Node.endOfIndent(s,l):e.Node.endOfWhiteSpace(s,l);let c=s[l];for(;c===e.Char.ANCHOR||c===e.Char.COMMENT||c===e.Char.TAG||c===`
|
|
84
|
+
`;){if(c===`
|
|
85
|
+
`){let E=l,O;do O=E+1,E=e.Node.endOfIndent(s,O);while(s[E]===`
|
|
86
|
+
`);let x=E-(O+this.indent),_=n.type===e.Type.SEQ_ITEM&&n.context.atLineStart;if(s[E]!=="#"&&!e.Node.nextNodeIsIndented(s[E],x,!_))break;this.atLineStart=!0,this.lineStart=O,p=!1,l=E}else if(c===e.Char.COMMENT){let E=e.Node.endOfLine(s,l+1);o.push(new e.Range(l,E)),l=E}else{let E=e.Node.endOfIdentifier(s,l+1);c===e.Char.TAG&&s[E]===","&&/^[a-zA-Z0-9-]+\.[a-zA-Z0-9-]+,\d\d\d\d(-\d\d){0,2}\/\S/.test(s.slice(l+1,E+13))&&(E=e.Node.endOfIdentifier(s,E+5)),o.push(new e.Range(l,E)),p=!0,l=e.Node.endOfWhiteSpace(s,E)}c=s[l]}p&&c===":"&&e.Node.atBlank(s,l+1,!0)&&(l-=1);let h=He.parseType(s,l,i);return{props:o,type:h,valueStart:l}}};function ce(M){let l=[];M.indexOf("\r")!==-1&&(M=M.replace(/\r\n?/g,(s,o)=>(s.length>1&&l.push(o),`
|
|
87
|
+
`)));let i=[],n=0;do{let s=new k,o=new ee({src:M});n=s.parse(o,n),i.push(s)}while(n<M.length);return i.setOrigRanges=()=>{if(l.length===0)return!1;for(let o=1;o<l.length;++o)l[o]-=o;let s=0;for(let o=0;o<i.length;++o)s=i[o].setOrigRanges(l,s);return l.splice(0,l.length),!0},i.toString=()=>i.join(`...
|
|
88
|
+
`),i}t.parse=ce}),Ve=Me(t=>{"use strict";var e=Pe();function r(f,a,d){return d?`#${d.replace(/[\s\S]^/gm,`$&${a}#`)}
|
|
89
|
+
${a}${f}`:f}function u(f,a,d){return d?d.indexOf(`
|
|
90
|
+
`)===-1?`${f} #${d}`:`${f}
|
|
91
|
+
`+d.replace(/^/gm,`${a||""}#`):f}var g=class{};function y(f,a,d){if(Array.isArray(f))return f.map((m,v)=>y(m,String(v),d));if(f&&typeof f.toJSON=="function"){let m=d&&d.anchors&&d.anchors.get(f);m&&(d.onCreate=S=>{m.res=S,delete d.onCreate});let v=f.toJSON(a,d);return m&&d.onCreate&&d.onCreate(v),v}return(!d||!d.keep)&&typeof f=="bigint"?Number(f):f}var b=class extends g{constructor(f){super(),this.value=f}toJSON(f,a){return a&&a.keep?this.value:y(this.value,f,a)}toString(){return String(this.value)}};function A(f,a,d){let m=d;for(let v=a.length-1;v>=0;--v){let S=a[v];if(Number.isInteger(S)&&S>=0){let N=[];N[S]=m,m=N}else{let N={};Object.defineProperty(N,S,{value:m,writable:!0,enumerable:!0,configurable:!0}),m=N}}return f.createNode(m,!1)}var k=f=>f==null||typeof f=="object"&&f[Symbol.iterator]().next().done,C=class Ce extends g{constructor(a){super(),e._defineProperty(this,"items",[]),this.schema=a}addIn(a,d){if(k(a))this.add(d);else{let[m,...v]=a,S=this.get(m,!0);if(S instanceof Ce)S.addIn(v,d);else if(S===void 0&&this.schema)this.set(m,A(this.schema,v,d));else throw new Error(`Expected YAML collection at ${m}. Remaining path: ${v}`)}}deleteIn([a,...d]){if(d.length===0)return this.delete(a);let m=this.get(a,!0);if(m instanceof Ce)return m.deleteIn(d);throw new Error(`Expected YAML collection at ${a}. Remaining path: ${d}`)}getIn([a,...d],m){let v=this.get(a,!0);return d.length===0?!m&&v instanceof b?v.value:v:v instanceof Ce?v.getIn(d,m):void 0}hasAllNullValues(){return this.items.every(a=>{if(!a||a.type!=="PAIR")return!1;let d=a.value;return d==null||d instanceof b&&d.value==null&&!d.commentBefore&&!d.comment&&!d.tag})}hasIn([a,...d]){if(d.length===0)return this.has(a);let m=this.get(a,!0);return m instanceof Ce?m.hasIn(d):!1}setIn([a,...d],m){if(d.length===0)this.set(a,m);else{let v=this.get(a,!0);if(v instanceof Ce)v.setIn(d,m);else if(v===void 0&&this.schema)this.set(a,A(this.schema,d,m));else throw new Error(`Expected YAML collection at ${a}. Remaining path: ${d}`)}}toJSON(){return null}toString(a,{blockItem:d,flowChars:m,isMap:v,itemIndent:S},N,L){let{indent:T,indentStep:I,stringify:R}=a,j=this.type===e.Type.FLOW_MAP||this.type===e.Type.FLOW_SEQ||a.inFlow;j&&(S+=I);let ne=v&&this.hasAllNullValues();a=Object.assign({},a,{allNullValues:ne,indent:S,inFlow:j,type:null});let Q=!1,re=!1,J=this.items.reduce((ue,X,se)=>{let Z;X&&(!Q&&X.spaceBefore&&ue.push({type:"comment",str:""}),X.commentBefore&&X.commentBefore.match(/^.*$/gm).forEach(tr=>{ue.push({type:"comment",str:`#${tr}`})}),X.comment&&(Z=X.comment),j&&(!Q&&X.spaceBefore||X.commentBefore||X.comment||X.key&&(X.key.commentBefore||X.key.comment)||X.value&&(X.value.commentBefore||X.value.comment))&&(re=!0)),Q=!1;let fe=R(X,a,()=>Z=null,()=>Q=!0);return j&&!re&&fe.includes(`
|
|
92
|
+
`)&&(re=!0),j&&se<this.items.length-1&&(fe+=","),fe=u(fe,S,Z),Q&&(Z||j)&&(Q=!1),ue.push({type:"item",str:fe}),ue},[]),te;if(J.length===0)te=m.start+m.end;else if(j){let{start:ue,end:X}=m,se=J.map(Z=>Z.str);if(re||se.reduce((Z,fe)=>Z+fe.length+2,2)>Ce.maxFlowStringSingleLineLength){te=ue;for(let Z of se)te+=Z?`
|
|
93
|
+
${I}${T}${Z}`:`
|
|
94
|
+
`;te+=`
|
|
95
|
+
${T}${X}`}else te=`${ue} ${se.join(" ")} ${X}`}else{let ue=J.map(d);te=ue.shift();for(let X of ue)te+=X?`
|
|
96
|
+
${T}${X}`:`
|
|
97
|
+
`}return this.comment?(te+=`
|
|
98
|
+
`+this.comment.replace(/^/gm,`${T}#`),N&&N()):Q&&L&&L(),te}};e._defineProperty(C,"maxFlowStringSingleLineLength",60);function P(f){let a=f instanceof b?f.value:f;return a&&typeof a=="string"&&(a=Number(a)),Number.isInteger(a)&&a>=0?a:null}var F=class extends C{add(f){this.items.push(f)}delete(f){let a=P(f);return typeof a!="number"?!1:this.items.splice(a,1).length>0}get(f,a){let d=P(f);if(typeof d!="number")return;let m=this.items[d];return!a&&m instanceof b?m.value:m}has(f){let a=P(f);return typeof a=="number"&&a<this.items.length}set(f,a){let d=P(f);if(typeof d!="number")throw new Error(`Expected a valid index, not ${f}.`);this.items[d]=a}toJSON(f,a){let d=[];a&&a.onCreate&&a.onCreate(d);let m=0;for(let v of this.items)d.push(y(v,String(m++),a));return d}toString(f,a,d){return f?super.toString(f,{blockItem:m=>m.type==="comment"?m.str:`- ${m.str}`,flowChars:{start:"[",end:"]"},isMap:!1,itemIndent:(f.indent||"")+" "},a,d):JSON.stringify(this)}},ie=(f,a,d)=>a===null?"":typeof a!="object"?String(a):f instanceof g&&d&&d.doc?f.toString({anchors:Object.create(null),doc:d.doc,indent:"",indentStep:d.indentStep,inFlow:!0,inStringifyKey:!0,stringify:d.stringify}):JSON.stringify(a),q=class Ht extends g{constructor(a,d=null){super(),this.key=a,this.value=d,this.type=Ht.Type.PAIR}get commentBefore(){return this.key instanceof g?this.key.commentBefore:void 0}set commentBefore(a){if(this.key==null&&(this.key=new b(null)),this.key instanceof g)this.key.commentBefore=a;else{let d="Pair.commentBefore is an alias for Pair.key.commentBefore. To set it, the key must be a Node.";throw new Error(d)}}addToJSMap(a,d){let m=y(this.key,"",a);if(d instanceof Map){let v=y(this.value,m,a);d.set(m,v)}else if(d instanceof Set)d.add(m);else{let v=ie(this.key,m,a),S=y(this.value,v,a);v in d?Object.defineProperty(d,v,{value:S,writable:!0,enumerable:!0,configurable:!0}):d[v]=S}return d}toJSON(a,d){let m=d&&d.mapAsMap?new Map:{};return this.addToJSMap(d,m)}toString(a,d,m){if(!a||!a.doc)return JSON.stringify(this);let{indent:v,indentSeq:S,simpleKeys:N}=a.doc.options,{key:L,value:T}=this,I=L instanceof g&&L.comment;if(N){if(I)throw new Error("With simple keys, key nodes cannot have comments");if(L instanceof C){let fe="With simple keys, collection cannot be used as a key value";throw new Error(fe)}}let R=!N&&(!L||I||(L instanceof g?L instanceof C||L.type===e.Type.BLOCK_FOLDED||L.type===e.Type.BLOCK_LITERAL:typeof L=="object")),{doc:j,indent:ne,indentStep:Q,stringify:re}=a;a=Object.assign({},a,{implicitKey:!R,indent:ne+Q});let J=!1,te=re(L,a,()=>I=null,()=>J=!0);if(te=u(te,a.indent,I),!R&&te.length>1024){if(N)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");R=!0}if(a.allNullValues&&!N)return this.comment?(te=u(te,a.indent,this.comment),d&&d()):J&&!I&&m&&m(),a.inFlow&&!R?te:`? ${te}`;te=R?`? ${te}
|
|
99
|
+
${ne}:`:`${te}:`,this.comment&&(te=u(te,a.indent,this.comment),d&&d());let ue="",X=null;if(T instanceof g){if(T.spaceBefore&&(ue=`
|
|
100
|
+
`),T.commentBefore){let fe=T.commentBefore.replace(/^/gm,`${a.indent}#`);ue+=`
|
|
101
|
+
${fe}`}X=T.comment}else T&&typeof T=="object"&&(T=j.schema.createNode(T,!0));a.implicitKey=!1,!R&&!this.comment&&T instanceof b&&(a.indentAtStart=te.length+1),J=!1,!S&&v>=2&&!a.inFlow&&!R&&T instanceof F&&T.type!==e.Type.FLOW_SEQ&&!T.tag&&!j.anchors.getName(T)&&(a.indent=a.indent.substr(2));let se=re(T,a,()=>X=null,()=>J=!0),Z=" ";return ue||this.comment?Z=`${ue}
|
|
102
|
+
${a.indent}`:!R&&T instanceof C?(!(se[0]==="["||se[0]==="{")||se.includes(`
|
|
103
|
+
`))&&(Z=`
|
|
104
|
+
${a.indent}`):se[0]===`
|
|
105
|
+
`&&(Z=""),J&&!X&&m&&m(),u(te+Z+se,a.indent,X)}};e._defineProperty(q,"Type",{PAIR:"PAIR",MERGE_PAIR:"MERGE_PAIR"});var z=(f,a)=>{if(f instanceof K){let d=a.get(f.source);return d.count*d.aliasCount}else if(f instanceof C){let d=0;for(let m of f.items){let v=z(m,a);v>d&&(d=v)}return d}else if(f instanceof q){let d=z(f.key,a),m=z(f.value,a);return Math.max(d,m)}return 1},K=class zt extends g{static stringify({range:a,source:d},{anchors:m,doc:v,implicitKey:S,inStringifyKey:N}){let L=Object.keys(m).find(I=>m[I]===d);if(!L&&N&&(L=v.anchors.getName(d)||v.anchors.newName()),L)return`*${L}${S?" ":""}`;let T=v.anchors.getName(d)?"Alias node must be after source node":"Source node not found for alias node";throw new Error(`${T} [${a}]`)}constructor(a){super(),this.source=a,this.type=e.Type.ALIAS}set tag(a){throw new Error("Alias nodes cannot have tags")}toJSON(a,d){if(!d)return y(this.source,a,d);let{anchors:m,maxAliasCount:v}=d,S=m.get(this.source);if(!S||S.res===void 0){let N="This should not happen: Alias anchor was not resolved?";throw this.cstNode?new e.YAMLReferenceError(this.cstNode,N):new ReferenceError(N)}if(v>=0&&(S.count+=1,S.aliasCount===0&&(S.aliasCount=z(this.source,m)),S.count*S.aliasCount>v)){let N="Excessive alias count indicates a resource exhaustion attack";throw this.cstNode?new e.YAMLReferenceError(this.cstNode,N):new ReferenceError(N)}return S.res}toString(a){return zt.stringify(this,a)}};e._defineProperty(K,"default",!0);function ee(f,a){let d=a instanceof b?a.value:a;for(let m of f)if(m instanceof q&&(m.key===a||m.key===d||m.key&&m.key.value===d))return m}var ce=class extends C{add(f,a){f?f instanceof q||(f=new q(f.key||f,f.value)):f=new q(f);let d=ee(this.items,f.key),m=this.schema&&this.schema.sortMapEntries;if(d)if(a)d.value=f.value;else throw new Error(`Key ${f.key} already set`);else if(m){let v=this.items.findIndex(S=>m(f,S)<0);v===-1?this.items.push(f):this.items.splice(v,0,f)}else this.items.push(f)}delete(f){let a=ee(this.items,f);return a?this.items.splice(this.items.indexOf(a),1).length>0:!1}get(f,a){let d=ee(this.items,f),m=d&&d.value;return!a&&m instanceof b?m.value:m}has(f){return!!ee(this.items,f)}set(f,a){this.add(new q(f,a),!0)}toJSON(f,a,d){let m=d?new d:a&&a.mapAsMap?new Map:{};a&&a.onCreate&&a.onCreate(m);for(let v of this.items)v.addToJSMap(a,m);return m}toString(f,a,d){if(!f)return JSON.stringify(this);for(let m of this.items)if(!(m instanceof q))throw new Error(`Map items must all be pairs; found ${JSON.stringify(m)} instead`);return super.toString(f,{blockItem:m=>m.str,flowChars:{start:"{",end:"}"},isMap:!0,itemIndent:f.indent||""},a,d)}},M="<<",l=class extends q{constructor(f){if(f instanceof q){let a=f.value;a instanceof F||(a=new F,a.items.push(f.value),a.range=f.value.range),super(f.key,a),this.range=f.range}else super(new b(M),new F);this.type=q.Type.MERGE_PAIR}addToJSMap(f,a){for(let{source:d}of this.value.items){if(!(d instanceof ce))throw new Error("Merge sources must be maps");let m=d.toJSON(null,f,Map);for(let[v,S]of m)a instanceof Map?a.has(v)||a.set(v,S):a instanceof Set?a.add(v):Object.prototype.hasOwnProperty.call(a,v)||Object.defineProperty(a,v,{value:S,writable:!0,enumerable:!0,configurable:!0})}return a}toString(f,a){let d=this.value;if(d.items.length>1)return super.toString(f,a);this.value=d.items[0];let m=super.toString(f,a);return this.value=d,m}},i={defaultType:e.Type.BLOCK_LITERAL,lineWidth:76},n={trueStr:"true",falseStr:"false"},s={asBigInt:!1},o={nullStr:"null"},p={defaultType:e.Type.PLAIN,doubleQuoted:{jsonEncoding:!1,minMultiLineLength:40},fold:{lineWidth:80,minContentWidth:20}};function c(f,a,d){for(let{format:m,test:v,resolve:S}of a)if(v){let N=f.match(v);if(N){let L=S.apply(null,N);return L instanceof b||(L=new b(L)),m&&(L.format=m),L}}return d&&(f=d(f)),new b(f)}var h="flow",E="block",O="quoted",x=(f,a)=>{let d=f[a+1];for(;d===" "||d===" ";){do d=f[a+=1];while(d&&d!==`
|
|
106
|
+
`);d=f[a+1]}return a};function _(f,a,d,{indentAtStart:m,lineWidth:v=80,minContentWidth:S=20,onFold:N,onOverflow:L}){if(!v||v<0)return f;let T=Math.max(1+S,1+v-a.length);if(f.length<=T)return f;let I=[],R={},j=v-a.length;typeof m=="number"&&(m>v-Math.max(2,S)?I.push(0):j=v-m);let ne,Q,re=!1,J=-1,te=-1,ue=-1;d===E&&(J=x(f,J),J!==-1&&(j=J+T));for(let se;se=f[J+=1];){if(d===O&&se==="\\"){switch(te=J,f[J+1]){case"x":J+=3;break;case"u":J+=5;break;case"U":J+=9;break;default:J+=1}ue=J}if(se===`
|
|
107
|
+
`)d===E&&(J=x(f,J)),j=J+T,ne=void 0;else{if(se===" "&&Q&&Q!==" "&&Q!==`
|
|
108
|
+
`&&Q!==" "){let Z=f[J+1];Z&&Z!==" "&&Z!==`
|
|
109
|
+
`&&Z!==" "&&(ne=J)}if(J>=j)if(ne)I.push(ne),j=ne+T,ne=void 0;else if(d===O){for(;Q===" "||Q===" ";)Q=se,se=f[J+=1],re=!0;let Z=J>ue+1?J-2:te-1;if(R[Z])return f;I.push(Z),R[Z]=!0,j=Z+T,ne=void 0}else re=!0}Q=se}if(re&&L&&L(),I.length===0)return f;N&&N();let X=f.slice(0,I[0]);for(let se=0;se<I.length;++se){let Z=I[se],fe=I[se+1]||f.length;Z===0?X=`
|
|
110
|
+
${a}${f.slice(0,fe)}`:(d===O&&R[Z]&&(X+=`${f[Z]}\\`),X+=`
|
|
111
|
+
${a}${f.slice(Z+1,fe)}`)}return X}var W=({indentAtStart:f})=>f?Object.assign({indentAtStart:f},p.fold):p.fold,B=f=>/^(%|---|\.\.\.)/m.test(f);function U(f,a,d){if(!a||a<0)return!1;let m=a-d,v=f.length;if(v<=m)return!1;for(let S=0,N=0;S<v;++S)if(f[S]===`
|
|
112
|
+
`){if(S-N>m)return!0;if(N=S+1,v-N<=m)return!1}return!0}function oe(f,a){let{implicitKey:d}=a,{jsonEncoding:m,minMultiLineLength:v}=p.doubleQuoted,S=JSON.stringify(f);if(m)return S;let N=a.indent||(B(f)?" ":""),L="",T=0;for(let I=0,R=S[I];R;R=S[++I])if(R===" "&&S[I+1]==="\\"&&S[I+2]==="n"&&(L+=S.slice(T,I)+"\\ ",I+=1,T=I,R="\\"),R==="\\")switch(S[I+1]){case"u":{L+=S.slice(T,I);let j=S.substr(I+2,4);switch(j){case"0000":L+="\\0";break;case"0007":L+="\\a";break;case"000b":L+="\\v";break;case"001b":L+="\\e";break;case"0085":L+="\\N";break;case"00a0":L+="\\_";break;case"2028":L+="\\L";break;case"2029":L+="\\P";break;default:j.substr(0,2)==="00"?L+="\\x"+j.substr(2):L+=S.substr(I,6)}I+=5,T=I+1}break;case"n":if(d||S[I+2]==='"'||S.length<v)I+=1;else{for(L+=S.slice(T,I)+`
|
|
113
|
+
|
|
114
|
+
`;S[I+2]==="\\"&&S[I+3]==="n"&&S[I+4]!=='"';)L+=`
|
|
115
|
+
`,I+=2;L+=N,S[I+2]===" "&&(L+="\\"),I+=1,T=I+1}break;default:I+=1}return L=T?L+S.slice(T):S,d?L:_(L,N,O,W(a))}function he(f,a){if(a.implicitKey){if(/\n/.test(f))return oe(f,a)}else if(/[ \t]\n|\n[ \t]/.test(f))return oe(f,a);let d=a.indent||(B(f)?" ":""),m="'"+f.replace(/'/g,"''").replace(/\n+/g,`$&
|
|
116
|
+
${d}`)+"'";return a.implicitKey?m:_(m,d,h,W(a))}function Se({comment:f,type:a,value:d},m,v,S){if(/\n[\t ]+$/.test(d)||/^\s*$/.test(d))return oe(d,m);let N=m.indent||(m.forceBlockIndent||B(d)?" ":""),L=N?"2":"1",T=a===e.Type.BLOCK_FOLDED?!1:a===e.Type.BLOCK_LITERAL?!0:!U(d,p.fold.lineWidth,N.length),I=T?"|":">";if(!d)return I+`
|
|
117
|
+
`;let R="",j="";if(d=d.replace(/[\n\t ]*$/,Q=>{let re=Q.indexOf(`
|
|
118
|
+
`);return re===-1?I+="-":(d===Q||re!==Q.length-1)&&(I+="+",S&&S()),j=Q.replace(/\n$/,""),""}).replace(/^[\n ]*/,Q=>{Q.indexOf(" ")!==-1&&(I+=L);let re=Q.match(/ +$/);return re?(R=Q.slice(0,-re[0].length),re[0]):(R=Q,"")}),j&&(j=j.replace(/\n+(?!\n|$)/g,`$&${N}`)),R&&(R=R.replace(/\n+/g,`$&${N}`)),f&&(I+=" #"+f.replace(/ ?[\r\n]+/g," "),v&&v()),!d)return`${I}${L}
|
|
119
|
+
${N}${j}`;if(T)return d=d.replace(/\n+/g,`$&${N}`),`${I}
|
|
120
|
+
${N}${R}${d}${j}`;d=d.replace(/\n+/g,`
|
|
121
|
+
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${N}`);let ne=_(`${R}${d}${j}`,N,E,p.fold);return`${I}
|
|
122
|
+
${N}${ne}`}function w(f,a,d,m){let{comment:v,type:S,value:N}=f,{actualString:L,implicitKey:T,indent:I,inFlow:R}=a;if(T&&/[\n[\]{},]/.test(N)||R&&/[[\]{},]/.test(N))return oe(N,a);if(!N||/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(N))return T||R||N.indexOf(`
|
|
123
|
+
`)===-1?N.indexOf('"')!==-1&&N.indexOf("'")===-1?he(N,a):oe(N,a):Se(f,a,d,m);if(!T&&!R&&S!==e.Type.PLAIN&&N.indexOf(`
|
|
124
|
+
`)!==-1)return Se(f,a,d,m);if(I===""&&B(N))return a.forceBlockIndent=!0,Se(f,a,d,m);let j=N.replace(/\n+/g,`$&
|
|
125
|
+
${I}`);if(L){let{tags:Q}=a.doc.schema;if(typeof c(j,Q,Q.scalarFallback).value!="string")return oe(N,a)}let ne=T?j:_(j,I,h,W(a));return v&&!R&&(ne.indexOf(`
|
|
126
|
+
`)!==-1||v.indexOf(`
|
|
127
|
+
`)!==-1)?(d&&d(),r(ne,I,v)):ne}function $(f,a,d,m){let{defaultType:v}=p,{implicitKey:S,inFlow:N}=a,{type:L,value:T}=f;typeof T!="string"&&(T=String(T),f=Object.assign({},f,{value:T}));let I=j=>{switch(j){case e.Type.BLOCK_FOLDED:case e.Type.BLOCK_LITERAL:return Se(f,a,d,m);case e.Type.QUOTE_DOUBLE:return oe(T,a);case e.Type.QUOTE_SINGLE:return he(T,a);case e.Type.PLAIN:return w(f,a,d,m);default:return null}};(L!==e.Type.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f]/.test(T)||(S||N)&&(L===e.Type.BLOCK_FOLDED||L===e.Type.BLOCK_LITERAL))&&(L=e.Type.QUOTE_DOUBLE);let R=I(L);if(R===null&&(R=I(v),R===null))throw new Error(`Unsupported default string type ${v}`);return R}function D({format:f,minFractionDigits:a,tag:d,value:m}){if(typeof m=="bigint")return String(m);if(!isFinite(m))return isNaN(m)?".nan":m<0?"-.inf":".inf";let v=JSON.stringify(m);if(!f&&a&&(!d||d==="tag:yaml.org,2002:float")&&/^\d/.test(v)){let S=v.indexOf(".");S<0&&(S=v.length,v+=".");let N=a-(v.length-S-1);for(;N-- >0;)v+="0"}return v}function Y(f,a){let d,m;switch(a.type){case e.Type.FLOW_MAP:d="}",m="flow map";break;case e.Type.FLOW_SEQ:d="]",m="flow sequence";break;default:f.push(new e.YAMLSemanticError(a,"Not a flow collection!?"));return}let v;for(let S=a.items.length-1;S>=0;--S){let N=a.items[S];if(!N||N.type!==e.Type.COMMENT){v=N;break}}if(v&&v.char!==d){let S=`Expected ${m} to end with ${d}`,N;typeof v.offset=="number"?(N=new e.YAMLSemanticError(a,S),N.offset=v.offset+1):(N=new e.YAMLSemanticError(v,S),v.range&&v.range.end&&(N.offset=v.range.end-v.range.start)),f.push(N)}}function V(f,a){let d=a.context.src[a.range.start-1];if(d!==`
|
|
128
|
+
`&&d!==" "&&d!==" "){let m="Comments must be separated from other tokens by white space characters";f.push(new e.YAMLSemanticError(a,m))}}function G(f,a){let d=String(a),m=d.substr(0,8)+"..."+d.substr(-8);return new e.YAMLSemanticError(f,`The "${m}" key is too long`)}function me(f,a){for(let{afterKey:d,before:m,comment:v}of a){let S=f.items[m];S?(d&&S.value&&(S=S.value),v===void 0?(d||!S.commentBefore)&&(S.spaceBefore=!0):S.commentBefore?S.commentBefore+=`
|
|
129
|
+
`+v:S.commentBefore=v):v!==void 0&&(f.comment?f.comment+=`
|
|
130
|
+
`+v:f.comment=v)}}function Ne(f,a){let d=a.strValue;return d?typeof d=="string"?d:(d.errors.forEach(m=>{m.source||(m.source=a),f.errors.push(m)}),d.str):""}function Le(f,a){let{handle:d,suffix:m}=a.tag,v=f.tagPrefixes.find(S=>S.handle===d);if(!v){let S=f.getDefaults().tagPrefixes;if(S&&(v=S.find(N=>N.handle===d)),!v)throw new e.YAMLSemanticError(a,`The ${d} tag handle is non-default and was not declared.`)}if(!m)throw new e.YAMLSemanticError(a,`The ${d} tag has no suffix.`);if(d==="!"&&(f.version||f.options.version)==="1.0"){if(m[0]==="^")return f.warnings.push(new e.YAMLWarning(a,"YAML 1.0 ^ tag expansion is not supported")),m;if(/[:/]/.test(m)){let S=m.match(/^([a-z0-9-]+)\/(.*)/i);return S?`tag:${S[1]}.yaml.org,2002:${S[2]}`:`tag:${m}`}}return v.prefix+decodeURIComponent(m)}function we(f,a){let{tag:d,type:m}=a,v=!1;if(d){let{handle:S,suffix:N,verbatim:L}=d;if(L){if(L!=="!"&&L!=="!!")return L;let T=`Verbatim tags aren't resolved, so ${L} is invalid.`;f.errors.push(new e.YAMLSemanticError(a,T))}else if(S==="!"&&!N)v=!0;else try{return Le(f,a)}catch(T){f.errors.push(T)}}switch(m){case e.Type.BLOCK_FOLDED:case e.Type.BLOCK_LITERAL:case e.Type.QUOTE_DOUBLE:case e.Type.QUOTE_SINGLE:return e.defaultTags.STR;case e.Type.FLOW_MAP:case e.Type.MAP:return e.defaultTags.MAP;case e.Type.FLOW_SEQ:case e.Type.SEQ:return e.defaultTags.SEQ;case e.Type.PLAIN:return v?e.defaultTags.STR:null;default:return null}}function je(f,a,d){let{tags:m}=f.schema,v=[];for(let N of m)if(N.tag===d)if(N.test)v.push(N);else{let L=N.resolve(f,a);return L instanceof C?L:new b(L)}let S=Ne(f,a);return typeof S=="string"&&v.length>0?c(S,v,m.scalarFallback):null}function Ge({type:f}){switch(f){case e.Type.FLOW_MAP:case e.Type.MAP:return e.defaultTags.MAP;case e.Type.FLOW_SEQ:case e.Type.SEQ:return e.defaultTags.SEQ;default:return e.defaultTags.STR}}function qn(f,a,d){try{let m=je(f,a,d);if(m)return d&&a.tag&&(m.tag=d),m}catch(m){return m.source||(m.source=a),f.errors.push(m),null}try{let m=Ge(a);if(!m)throw new Error(`The tag ${d} is unavailable`);let v=`The tag ${d} is unavailable, falling back to ${m}`;f.warnings.push(new e.YAMLWarning(a,v));let S=je(f,a,m);return S.tag=d,S}catch(m){let v=new e.YAMLReferenceError(a,m.message);return v.stack=m.stack,f.errors.push(v),null}}var Kn=f=>{if(!f)return!1;let{type:a}=f;return a===e.Type.MAP_KEY||a===e.Type.MAP_VALUE||a===e.Type.SEQ_ITEM};function Un(f,a){let d={before:[],after:[]},m=!1,v=!1,S=Kn(a.context.parent)?a.context.parent.props.concat(a.props):a.props;for(let{start:N,end:L}of S)switch(a.context.src[N]){case e.Char.COMMENT:{if(!a.commentHasRequiredWhitespace(N)){let R="Comments must be separated from other tokens by white space characters";f.push(new e.YAMLSemanticError(a,R))}let{header:T,valueRange:I}=a;(I&&(N>I.start||T&&N>T.start)?d.after:d.before).push(a.context.src.slice(N+1,L));break}case e.Char.ANCHOR:if(m){let T="A node can have at most one anchor";f.push(new e.YAMLSemanticError(a,T))}m=!0;break;case e.Char.TAG:if(v){let T="A node can have at most one tag";f.push(new e.YAMLSemanticError(a,T))}v=!0;break}return{comments:d,hasAnchor:m,hasTag:v}}function Vn(f,a){let{anchors:d,errors:m,schema:v}=f;if(a.type===e.Type.ALIAS){let N=a.rawValue,L=d.getNode(N);if(!L){let I=`Aliased anchor not found: ${N}`;return m.push(new e.YAMLReferenceError(a,I)),null}let T=new K(L);return d._cstAliases.push(T),T}let S=we(f,a);if(S)return qn(f,a,S);if(a.type!==e.Type.PLAIN){let N=`Failed to resolve ${a.type} node here`;return m.push(new e.YAMLSyntaxError(a,N)),null}try{let N=Ne(f,a);return c(N,v.tags,v.tags.scalarFallback)}catch(N){return N.source||(N.source=a),m.push(N),null}}function Te(f,a){if(!a)return null;a.error&&f.errors.push(a.error);let{comments:d,hasAnchor:m,hasTag:v}=Un(f.errors,a);if(m){let{anchors:N}=f,L=a.anchor,T=N.getNode(L);T&&(N.map[N.newName(L)]=T),N.map[L]=a}if(a.type===e.Type.ALIAS&&(m||v)){let N="An alias node must not specify any properties";f.errors.push(new e.YAMLSemanticError(a,N))}let S=Vn(f,a);if(S){S.range=[a.range.start,a.range.end],f.options.keepCstNodes&&(S.cstNode=a),f.options.keepNodeTypes&&(S.type=a.type);let N=d.before.join(`
|
|
131
|
+
`);N&&(S.commentBefore=S.commentBefore?`${S.commentBefore}
|
|
132
|
+
${N}`:N);let L=d.after.join(`
|
|
133
|
+
`);L&&(S.comment=S.comment?`${S.comment}
|
|
134
|
+
${L}`:L)}return a.resolved=S}function Qn(f,a){if(a.type!==e.Type.MAP&&a.type!==e.Type.FLOW_MAP){let N=`A ${a.type} node cannot be resolved as a mapping`;return f.errors.push(new e.YAMLSyntaxError(a,N)),null}let{comments:d,items:m}=a.type===e.Type.FLOW_MAP?zn(f,a):Hn(f,a),v=new ce;v.items=m,me(v,d);let S=!1;for(let N=0;N<m.length;++N){let{key:L}=m[N];if(L instanceof C&&(S=!0),f.schema.merge&&L&&L.value===M){m[N]=new l(m[N]);let T=m[N].value.items,I=null;T.some(R=>{if(R instanceof K){let{type:j}=R.source;return j===e.Type.MAP||j===e.Type.FLOW_MAP?!1:I="Merge nodes aliases can only point to maps"}return I="Merge nodes can only have Alias nodes as values"}),I&&f.errors.push(new e.YAMLSemanticError(a,I))}else for(let T=N+1;T<m.length;++T){let{key:I}=m[T];if(L===I||L&&I&&Object.prototype.hasOwnProperty.call(L,"value")&&L.value===I.value){let R=`Map keys must be unique; "${L}" is repeated`;f.errors.push(new e.YAMLSemanticError(a,R));break}}}if(S&&!f.options.mapAsMap){let N="Keys with collection values will be stringified as YAML due to JS Object restrictions. Use mapAsMap: true to avoid this.";f.warnings.push(new e.YAMLWarning(a,N))}return a.resolved=v,v}var Jn=({context:{lineStart:f,node:a,src:d},props:m})=>{if(m.length===0)return!1;let{start:v}=m[0];if(a&&v>a.valueRange.start||d[v]!==e.Char.COMMENT)return!1;for(let S=f;S<v;++S)if(d[S]===`
|
|
135
|
+
`)return!1;return!0};function Gn(f,a){if(!Jn(f))return;let d=f.getPropValue(0,e.Char.COMMENT,!0),m=!1,v=a.value.commentBefore;if(v&&v.startsWith(d))a.value.commentBefore=v.substr(d.length+1),m=!0;else{let S=a.value.comment;!f.node&&S&&S.startsWith(d)&&(a.value.comment=S.substr(d.length+1),m=!0)}m&&(a.comment=d)}function Hn(f,a){let d=[],m=[],v,S=null;for(let N=0;N<a.items.length;++N){let L=a.items[N];switch(L.type){case e.Type.BLANK_LINE:d.push({afterKey:!!v,before:m.length});break;case e.Type.COMMENT:d.push({afterKey:!!v,before:m.length,comment:L.comment});break;case e.Type.MAP_KEY:v!==void 0&&m.push(new q(v)),L.error&&f.errors.push(L.error),v=Te(f,L.node),S=null;break;case e.Type.MAP_VALUE:{if(v===void 0&&(v=null),L.error&&f.errors.push(L.error),!L.context.atLineStart&&L.node&&L.node.type===e.Type.MAP&&!L.node.context.atLineStart){let R="Nested mappings are not allowed in compact mappings";f.errors.push(new e.YAMLSemanticError(L.node,R))}let T=L.node;if(!T&&L.props.length>0){T=new e.PlainValue(e.Type.PLAIN,[]),T.context={parent:L,src:L.context.src};let R=L.range.start+1;if(T.range={start:R,end:R},T.valueRange={start:R,end:R},typeof L.range.origStart=="number"){let j=L.range.origStart+1;T.range.origStart=T.range.origEnd=j,T.valueRange.origStart=T.valueRange.origEnd=j}}let I=new q(v,Te(f,T));Gn(L,I),m.push(I),v&&typeof S=="number"&&L.range.start>S+1024&&f.errors.push(G(a,v)),v=void 0,S=null}break;default:v!==void 0&&m.push(new q(v)),v=Te(f,L),S=L.range.start,L.error&&f.errors.push(L.error);e:for(let T=N+1;;++T){let I=a.items[T];switch(I&&I.type){case e.Type.BLANK_LINE:case e.Type.COMMENT:continue e;case e.Type.MAP_VALUE:break e;default:{let R="Implicit map keys need to be followed by map values";f.errors.push(new e.YAMLSemanticError(L,R));break e}}}if(L.valueRangeContainsNewline){let T="Implicit map keys need to be on a single line";f.errors.push(new e.YAMLSemanticError(L,T))}}}return v!==void 0&&m.push(new q(v)),{comments:d,items:m}}function zn(f,a){let d=[],m=[],v,S=!1,N="{";for(let L=0;L<a.items.length;++L){let T=a.items[L];if(typeof T.char=="string"){let{char:I,offset:R}=T;if(I==="?"&&v===void 0&&!S){S=!0,N=":";continue}if(I===":"){if(v===void 0&&(v=null),N===":"){N=",";continue}}else if(S&&(v===void 0&&I!==","&&(v=null),S=!1),v!==void 0&&(m.push(new q(v)),v=void 0,I===",")){N=":";continue}if(I==="}"){if(L===a.items.length-1)continue}else if(I===N){N=":";continue}let j=`Flow map contains an unexpected ${I}`,ne=new e.YAMLSyntaxError(a,j);ne.offset=R,f.errors.push(ne)}else T.type===e.Type.BLANK_LINE?d.push({afterKey:!!v,before:m.length}):T.type===e.Type.COMMENT?(V(f.errors,T),d.push({afterKey:!!v,before:m.length,comment:T.comment})):v===void 0?(N===","&&f.errors.push(new e.YAMLSemanticError(T,"Separator , missing in flow map")),v=Te(f,T)):(N!==","&&f.errors.push(new e.YAMLSemanticError(T,"Indicator : missing in flow map entry")),m.push(new q(v,Te(f,T))),v=void 0,S=!1)}return Y(f.errors,a),v!==void 0&&m.push(new q(v)),{comments:d,items:m}}function Xn(f,a){if(a.type!==e.Type.SEQ&&a.type!==e.Type.FLOW_SEQ){let S=`A ${a.type} node cannot be resolved as a sequence`;return f.errors.push(new e.YAMLSyntaxError(a,S)),null}let{comments:d,items:m}=a.type===e.Type.FLOW_SEQ?er(f,a):Zn(f,a),v=new F;if(v.items=m,me(v,d),!f.options.mapAsMap&&m.some(S=>S instanceof q&&S.key instanceof C)){let S="Keys with collection values will be stringified as YAML due to JS Object restrictions. Use mapAsMap: true to avoid this.";f.warnings.push(new e.YAMLWarning(a,S))}return a.resolved=v,v}function Zn(f,a){let d=[],m=[];for(let v=0;v<a.items.length;++v){let S=a.items[v];switch(S.type){case e.Type.BLANK_LINE:d.push({before:m.length});break;case e.Type.COMMENT:d.push({comment:S.comment,before:m.length});break;case e.Type.SEQ_ITEM:if(S.error&&f.errors.push(S.error),m.push(Te(f,S.node)),S.hasProps){let N="Sequence items cannot have tags or anchors before the - indicator";f.errors.push(new e.YAMLSemanticError(S,N))}break;default:S.error&&f.errors.push(S.error),f.errors.push(new e.YAMLSyntaxError(S,`Unexpected ${S.type} node in sequence`))}}return{comments:d,items:m}}function er(f,a){let d=[],m=[],v=!1,S,N=null,L="[",T=null;for(let I=0;I<a.items.length;++I){let R=a.items[I];if(typeof R.char=="string"){let{char:j,offset:ne}=R;if(j!==":"&&(v||S!==void 0)&&(v&&S===void 0&&(S=L?m.pop():null),m.push(new q(S)),v=!1,S=void 0,N=null),j===L)L=null;else if(!L&&j==="?")v=!0;else if(L!=="["&&j===":"&&S===void 0){if(L===","){if(S=m.pop(),S instanceof q){let Q="Chaining flow sequence pairs is invalid",re=new e.YAMLSemanticError(a,Q);re.offset=ne,f.errors.push(re)}if(!v&&typeof N=="number"){let Q=R.range?R.range.start:R.offset;Q>N+1024&&f.errors.push(G(a,S));let{src:re}=T.context;for(let J=N;J<Q;++J)if(re[J]===`
|
|
136
|
+
`){let te="Implicit keys of flow sequence pairs need to be on a single line";f.errors.push(new e.YAMLSemanticError(T,te));break}}}else S=null;N=null,v=!1,L=null}else if(L==="["||j!=="]"||I<a.items.length-1){let Q=`Flow sequence contains an unexpected ${j}`,re=new e.YAMLSyntaxError(a,Q);re.offset=ne,f.errors.push(re)}}else if(R.type===e.Type.BLANK_LINE)d.push({before:m.length});else if(R.type===e.Type.COMMENT)V(f.errors,R),d.push({comment:R.comment,before:m.length});else{if(L){let ne=`Expected a ${L} in flow sequence`;f.errors.push(new e.YAMLSemanticError(R,ne))}let j=Te(f,R);S===void 0?(m.push(j),T=R):(m.push(new q(S,j)),S=void 0),N=R.range.start,L=","}}return Y(f.errors,a),S!==void 0&&m.push(new q(S)),{comments:d,items:m}}t.Alias=K,t.Collection=C,t.Merge=l,t.Node=g,t.Pair=q,t.Scalar=b,t.YAMLMap=ce,t.YAMLSeq=F,t.addComment=u,t.binaryOptions=i,t.boolOptions=n,t.findPair=ee,t.intOptions=s,t.isEmptyPath=k,t.nullOptions=o,t.resolveMap=Qn,t.resolveNode=Te,t.resolveSeq=Xn,t.resolveString=Ne,t.strOptions=p,t.stringifyNumber=D,t.stringifyString=$,t.toJSON=y}),Xt=Me(t=>{"use strict";var e=Pe(),r=Ve(),u={identify:c=>c instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve:(c,h)=>{let E=r.resolveString(c,h);if(typeof Buffer=="function")return Buffer.from(E,"base64");if(typeof atob=="function"){let O=atob(E.replace(/[\n\r]/g,"")),x=new Uint8Array(O.length);for(let _=0;_<O.length;++_)x[_]=O.charCodeAt(_);return x}else{let O="This environment does not support reading binary tags; either Buffer or atob is required";return c.errors.push(new e.YAMLReferenceError(h,O)),null}},options:r.binaryOptions,stringify:({comment:c,type:h,value:E},O,x,_)=>{let W;if(typeof Buffer=="function")W=E instanceof Buffer?E.toString("base64"):Buffer.from(E.buffer).toString("base64");else if(typeof btoa=="function"){let B="";for(let U=0;U<E.length;++U)B+=String.fromCharCode(E[U]);W=btoa(B)}else throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(h||(h=r.binaryOptions.defaultType),h===e.Type.QUOTE_DOUBLE)E=W;else{let{lineWidth:B}=r.binaryOptions,U=Math.ceil(W.length/B),oe=new Array(U);for(let he=0,Se=0;he<U;++he,Se+=B)oe[he]=W.substr(Se,B);E=oe.join(h===e.Type.BLOCK_LITERAL?`
|
|
137
|
+
`:" ")}return r.stringifyString({comment:c,type:h,value:E},O,x,_)}};function g(c,h){let E=r.resolveSeq(c,h);for(let O=0;O<E.items.length;++O){let x=E.items[O];if(!(x instanceof r.Pair)){if(x instanceof r.YAMLMap){if(x.items.length>1){let W="Each pair must have its own sequence indicator";throw new e.YAMLSemanticError(h,W)}let _=x.items[0]||new r.Pair;x.commentBefore&&(_.commentBefore=_.commentBefore?`${x.commentBefore}
|
|
138
|
+
${_.commentBefore}`:x.commentBefore),x.comment&&(_.comment=_.comment?`${x.comment}
|
|
139
|
+
${_.comment}`:x.comment),x=_}E.items[O]=x instanceof r.Pair?x:new r.Pair(x)}}return E}function y(c,h,E){let O=new r.YAMLSeq(c);O.tag="tag:yaml.org,2002:pairs";for(let x of h){let _,W;if(Array.isArray(x))if(x.length===2)_=x[0],W=x[1];else throw new TypeError(`Expected [key, value] tuple: ${x}`);else if(x&&x instanceof Object){let U=Object.keys(x);if(U.length===1)_=U[0],W=x[_];else throw new TypeError(`Expected { key: value } tuple: ${x}`)}else _=x;let B=c.createPair(_,W,E);O.items.push(B)}return O}var b={default:!1,tag:"tag:yaml.org,2002:pairs",resolve:g,createNode:y},A=class Zt extends r.YAMLSeq{constructor(){super(),e._defineProperty(this,"add",r.YAMLMap.prototype.add.bind(this)),e._defineProperty(this,"delete",r.YAMLMap.prototype.delete.bind(this)),e._defineProperty(this,"get",r.YAMLMap.prototype.get.bind(this)),e._defineProperty(this,"has",r.YAMLMap.prototype.has.bind(this)),e._defineProperty(this,"set",r.YAMLMap.prototype.set.bind(this)),this.tag=Zt.tag}toJSON(h,E){let O=new Map;E&&E.onCreate&&E.onCreate(O);for(let x of this.items){let _,W;if(x instanceof r.Pair?(_=r.toJSON(x.key,"",E),W=r.toJSON(x.value,_,E)):_=r.toJSON(x,"",E),O.has(_))throw new Error("Ordered maps must not include duplicate keys");O.set(_,W)}return O}};e._defineProperty(A,"tag","tag:yaml.org,2002:omap");function k(c,h){let E=g(c,h),O=[];for(let{key:x}of E.items)if(x instanceof r.Scalar)if(O.includes(x.value)){let _="Ordered maps must not include duplicate keys";throw new e.YAMLSemanticError(h,_)}else O.push(x.value);return Object.assign(new A,E)}function C(c,h,E){let O=y(c,h,E),x=new A;return x.items=O.items,x}var P={identify:c=>c instanceof Map,nodeClass:A,default:!1,tag:"tag:yaml.org,2002:omap",resolve:k,createNode:C},F=class en extends r.YAMLMap{constructor(){super(),this.tag=en.tag}add(h){let E=h instanceof r.Pair?h:new r.Pair(h);r.findPair(this.items,E.key)||this.items.push(E)}get(h,E){let O=r.findPair(this.items,h);return!E&&O instanceof r.Pair?O.key instanceof r.Scalar?O.key.value:O.key:O}set(h,E){if(typeof E!="boolean")throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof E}`);let O=r.findPair(this.items,h);O&&!E?this.items.splice(this.items.indexOf(O),1):!O&&E&&this.items.push(new r.Pair(h))}toJSON(h,E){return super.toJSON(h,E,Set)}toString(h,E,O){if(!h)return JSON.stringify(this);if(this.hasAllNullValues())return super.toString(h,E,O);throw new Error("Set items must all have null values")}};e._defineProperty(F,"tag","tag:yaml.org,2002:set");function ie(c,h){let E=r.resolveMap(c,h);if(!E.hasAllNullValues())throw new e.YAMLSemanticError(h,"Set items must all have null values");return Object.assign(new F,E)}function q(c,h,E){let O=new F;for(let x of h)O.items.push(c.createPair(x,null,E));return O}var z={identify:c=>c instanceof Set,nodeClass:F,default:!1,tag:"tag:yaml.org,2002:set",resolve:ie,createNode:q},K=(c,h)=>{let E=h.split(":").reduce((O,x)=>O*60+Number(x),0);return c==="-"?-E:E},ee=({value:c})=>{if(isNaN(c)||!isFinite(c))return r.stringifyNumber(c);let h="";c<0&&(h="-",c=Math.abs(c));let E=[c%60];return c<60?E.unshift(0):(c=Math.round((c-E[0])/60),E.unshift(c%60),c>=60&&(c=Math.round((c-E[0])/60),E.unshift(c))),h+E.map(O=>O<10?"0"+String(O):String(O)).join(":").replace(/000000\d*$/,"")},ce={identify:c=>typeof c=="number",default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^([-+]?)([0-9][0-9_]*(?::[0-5]?[0-9])+)$/,resolve:(c,h,E)=>K(h,E.replace(/_/g,"")),stringify:ee},M={identify:c=>typeof c=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^([-+]?)([0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*)$/,resolve:(c,h,E)=>K(h,E.replace(/_/g,"")),stringify:ee},l={identify:c=>c instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^(?:([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?)$"),resolve:(c,h,E,O,x,_,W,B,U)=>{B&&(B=(B+"00").substr(1,3));let oe=Date.UTC(h,E-1,O,x||0,_||0,W||0,B||0);if(U&&U!=="Z"){let he=K(U[0],U.slice(1));Math.abs(he)<30&&(he*=60),oe-=6e4*he}return new Date(oe)},stringify:({value:c})=>c.toISOString().replace(/((T00:00)?:00)?\.000Z$/,"")};function i(c){let h={};return c?typeof YAML_SILENCE_DEPRECATION_WARNINGS<"u"?!YAML_SILENCE_DEPRECATION_WARNINGS:!h.YAML_SILENCE_DEPRECATION_WARNINGS:typeof YAML_SILENCE_WARNINGS<"u"?!YAML_SILENCE_WARNINGS:!h.YAML_SILENCE_WARNINGS}function n(c,h){i(!1)&&console.warn(h?`${h}: ${c}`:c)}function s(c){if(i(!0)){let h=c.replace(/.*yaml[/\\]/i,"").replace(/\.js$/,"").replace(/\\/g,"/");n(`The endpoint 'yaml/${h}' will be removed in a future release.`,"DeprecationWarning")}}var o={};function p(c,h){if(!o[c]&&i(!0)){o[c]=!0;let E=`The option '${c}' will be removed in a future release`;E+=h?`, use '${h}' instead.`:".",n(E,"DeprecationWarning")}}t.binary=u,t.floatTime=M,t.intTime=ce,t.omap=P,t.pairs=b,t.set=z,t.timestamp=l,t.warn=n,t.warnFileDeprecation=s,t.warnOptionDeprecation=p}),tn=Me(t=>{"use strict";var e=Pe(),r=Ve(),u=Xt();function g(w,$,D){let Y=new r.YAMLMap(w);if($ instanceof Map)for(let[V,G]of $)Y.items.push(w.createPair(V,G,D));else if($&&typeof $=="object")for(let V of Object.keys($))Y.items.push(w.createPair(V,$[V],D));return typeof w.sortMapEntries=="function"&&Y.items.sort(w.sortMapEntries),Y}var y={createNode:g,default:!0,nodeClass:r.YAMLMap,tag:"tag:yaml.org,2002:map",resolve:r.resolveMap};function b(w,$,D){let Y=new r.YAMLSeq(w);if($&&$[Symbol.iterator])for(let V of $){let G=w.createNode(V,D.wrapScalars,null,D);Y.items.push(G)}return Y}var A={createNode:b,default:!0,nodeClass:r.YAMLSeq,tag:"tag:yaml.org,2002:seq",resolve:r.resolveSeq},k={identify:w=>typeof w=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:r.resolveString,stringify(w,$,D,Y){return $=Object.assign({actualString:!0},$),r.stringifyString(w,$,D,Y)},options:r.strOptions},C=[y,A,k],P=w=>typeof w=="bigint"||Number.isInteger(w),F=(w,$,D)=>r.intOptions.asBigInt?BigInt(w):parseInt($,D);function ie(w,$,D){let{value:Y}=w;return P(Y)&&Y>=0?D+Y.toString($):r.stringifyNumber(w)}var q={identify:w=>w==null,createNode:(w,$,D)=>D.wrapScalars?new r.Scalar(null):null,default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>null,options:r.nullOptions,stringify:()=>r.nullOptions.nullStr},z={identify:w=>typeof w=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:w=>w[0]==="t"||w[0]==="T",options:r.boolOptions,stringify:({value:w})=>w?r.boolOptions.trueStr:r.boolOptions.falseStr},K={identify:w=>P(w)&&w>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o([0-7]+)$/,resolve:(w,$)=>F(w,$,8),options:r.intOptions,stringify:w=>ie(w,8,"0o")},ee={identify:P,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:w=>F(w,w,10),options:r.intOptions,stringify:r.stringifyNumber},ce={identify:w=>P(w)&&w>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x([0-9a-fA-F]+)$/,resolve:(w,$)=>F(w,$,16),options:r.intOptions,stringify:w=>ie(w,16,"0x")},M={identify:w=>typeof w=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.inf|(\.nan))$/i,resolve:(w,$)=>$?NaN:w[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:r.stringifyNumber},l={identify:w=>typeof w=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:w=>parseFloat(w),stringify:({value:w})=>Number(w).toExponential()},i={identify:w=>typeof w=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.([0-9]+)|[0-9]+\.([0-9]*))$/,resolve(w,$,D){let Y=$||D,V=new r.Scalar(parseFloat(w));return Y&&Y[Y.length-1]==="0"&&(V.minFractionDigits=Y.length),V},stringify:r.stringifyNumber},n=C.concat([q,z,K,ee,ce,M,l,i]),s=w=>typeof w=="bigint"||Number.isInteger(w),o=({value:w})=>JSON.stringify(w),p=[y,A,{identify:w=>typeof w=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:r.resolveString,stringify:o},{identify:w=>w==null,createNode:(w,$,D)=>D.wrapScalars?new r.Scalar(null):null,default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:o},{identify:w=>typeof w=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true|false$/,resolve:w=>w==="true",stringify:o},{identify:s,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:w=>r.intOptions.asBigInt?BigInt(w):parseInt(w,10),stringify:({value:w})=>s(w)?w.toString():JSON.stringify(w)},{identify:w=>typeof w=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:w=>parseFloat(w),stringify:o}];p.scalarFallback=w=>{throw new SyntaxError(`Unresolved plain scalar ${JSON.stringify(w)}`)};var c=({value:w})=>w?r.boolOptions.trueStr:r.boolOptions.falseStr,h=w=>typeof w=="bigint"||Number.isInteger(w);function E(w,$,D){let Y=$.replace(/_/g,"");if(r.intOptions.asBigInt){switch(D){case 2:Y=`0b${Y}`;break;case 8:Y=`0o${Y}`;break;case 16:Y=`0x${Y}`;break}let G=BigInt(Y);return w==="-"?BigInt(-1)*G:G}let V=parseInt(Y,D);return w==="-"?-1*V:V}function O(w,$,D){let{value:Y}=w;if(h(Y)){let V=Y.toString($);return Y<0?"-"+D+V.substr(1):D+V}return r.stringifyNumber(w)}var x=C.concat([{identify:w=>w==null,createNode:(w,$,D)=>D.wrapScalars?new r.Scalar(null):null,default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>null,options:r.nullOptions,stringify:()=>r.nullOptions.nullStr},{identify:w=>typeof w=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>!0,options:r.boolOptions,stringify:c},{identify:w=>typeof w=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/i,resolve:()=>!1,options:r.boolOptions,stringify:c},{identify:h,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^([-+]?)0b([0-1_]+)$/,resolve:(w,$,D)=>E($,D,2),stringify:w=>O(w,2,"0b")},{identify:h,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^([-+]?)0([0-7_]+)$/,resolve:(w,$,D)=>E($,D,8),stringify:w=>O(w,8,"0")},{identify:h,default:!0,tag:"tag:yaml.org,2002:int",test:/^([-+]?)([0-9][0-9_]*)$/,resolve:(w,$,D)=>E($,D,10),stringify:r.stringifyNumber},{identify:h,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^([-+]?)0x([0-9a-fA-F_]+)$/,resolve:(w,$,D)=>E($,D,16),stringify:w=>O(w,16,"0x")},{identify:w=>typeof w=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.inf|(\.nan))$/i,resolve:(w,$)=>$?NaN:w[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:r.stringifyNumber},{identify:w=>typeof w=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?([0-9][0-9_]*)?(\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:w=>parseFloat(w.replace(/_/g,"")),stringify:({value:w})=>Number(w).toExponential()},{identify:w=>typeof w=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.([0-9_]*)$/,resolve(w,$){let D=new r.Scalar(parseFloat(w.replace(/_/g,"")));if($){let Y=$.replace(/_/g,"");Y[Y.length-1]==="0"&&(D.minFractionDigits=Y.length)}return D},stringify:r.stringifyNumber}],u.binary,u.omap,u.pairs,u.set,u.intTime,u.floatTime,u.timestamp),_={core:n,failsafe:C,json:p,yaml11:x},W={binary:u.binary,bool:z,float:i,floatExp:l,floatNaN:M,floatTime:u.floatTime,int:ee,intHex:ce,intOct:K,intTime:u.intTime,map:y,null:q,omap:u.omap,pairs:u.pairs,seq:A,set:u.set,timestamp:u.timestamp};function B(w,$,D){if($){let Y=D.filter(G=>G.tag===$),V=Y.find(G=>!G.format)||Y[0];if(!V)throw new Error(`Tag ${$} not found`);return V}return D.find(Y=>(Y.identify&&Y.identify(w)||Y.class&&w instanceof Y.class)&&!Y.format)}function U(w,$,D){if(w instanceof r.Node)return w;let{defaultPrefix:Y,onTagObj:V,prevObjects:G,schema:me,wrapScalars:Ne}=D;$&&$.startsWith("!!")&&($=Y+$.slice(2));let Le=B(w,$,me.tags);if(!Le){if(typeof w.toJSON=="function"&&(w=w.toJSON()),!w||typeof w!="object")return Ne?new r.Scalar(w):w;Le=w instanceof Map?y:w[Symbol.iterator]?A:y}V&&(V(Le),delete D.onTagObj);let we={value:void 0,node:void 0};if(w&&typeof w=="object"&&G){let je=G.get(w);if(je){let Ge=new r.Alias(je);return D.aliasNodes.push(Ge),Ge}we.value=w,G.set(w,we)}return we.node=Le.createNode?Le.createNode(D.schema,w,D):Ne?new r.Scalar(w):w,$&&we.node instanceof r.Node&&(we.node.tag=$),we.node}function oe(w,$,D,Y){let V=w[Y.replace(/\W/g,"")];if(!V){let G=Object.keys(w).map(me=>JSON.stringify(me)).join(", ");throw new Error(`Unknown schema "${Y}"; use one of ${G}`)}if(Array.isArray(D))for(let G of D)V=V.concat(G);else typeof D=="function"&&(V=D(V.slice()));for(let G=0;G<V.length;++G){let me=V[G];if(typeof me=="string"){let Ne=$[me];if(!Ne){let Le=Object.keys($).map(we=>JSON.stringify(we)).join(", ");throw new Error(`Unknown custom tag "${me}"; use one of ${Le}`)}V[G]=Ne}}return V}var he=(w,$)=>w.key<$.key?-1:w.key>$.key?1:0,Se=class nn{constructor({customTags:$,merge:D,schema:Y,sortMapEntries:V,tags:G}){this.merge=!!D,this.name=Y,this.sortMapEntries=V===!0?he:V||null,!$&&G&&u.warnOptionDeprecation("tags","customTags"),this.tags=oe(_,W,$||G,Y)}createNode($,D,Y,V){let G={defaultPrefix:nn.defaultPrefix,schema:this,wrapScalars:D},me=V?Object.assign(V,G):G;return U($,Y,me)}createPair($,D,Y){Y||(Y={wrapScalars:!0});let V=this.createNode($,Y.wrapScalars,null,Y),G=this.createNode(D,Y.wrapScalars,null,Y);return new r.Pair(V,G)}};e._defineProperty(Se,"defaultPrefix",e.defaultTagPrefix),e._defineProperty(Se,"defaultTags",e.defaultTags),t.Schema=Se}),cr=Me(t=>{"use strict";var e=Pe(),r=Ve(),u=tn(),g={anchorPrefix:"a",customTags:null,indent:2,indentSeq:!0,keepCstNodes:!1,keepNodeTypes:!0,keepBlobsInJSON:!0,mapAsMap:!1,maxAliasCount:100,prettyErrors:!1,simpleKeys:!1,version:"1.2"},y={get binary(){return r.binaryOptions},set binary(i){Object.assign(r.binaryOptions,i)},get bool(){return r.boolOptions},set bool(i){Object.assign(r.boolOptions,i)},get int(){return r.intOptions},set int(i){Object.assign(r.intOptions,i)},get null(){return r.nullOptions},set null(i){Object.assign(r.nullOptions,i)},get str(){return r.strOptions},set str(i){Object.assign(r.strOptions,i)}},b={"1.0":{schema:"yaml-1.1",merge:!0,tagPrefixes:[{handle:"!",prefix:e.defaultTagPrefix},{handle:"!!",prefix:"tag:private.yaml.org,2002:"}]},1.1:{schema:"yaml-1.1",merge:!0,tagPrefixes:[{handle:"!",prefix:"!"},{handle:"!!",prefix:e.defaultTagPrefix}]},1.2:{schema:"core",merge:!1,tagPrefixes:[{handle:"!",prefix:"!"},{handle:"!!",prefix:e.defaultTagPrefix}]}};function A(i,n){if((i.version||i.options.version)==="1.0"){let p=n.match(/^tag:private\.yaml\.org,2002:([^:/]+)$/);if(p)return"!"+p[1];let c=n.match(/^tag:([a-zA-Z0-9-]+)\.yaml\.org,2002:(.*)/);return c?`!${c[1]}/${c[2]}`:`!${n.replace(/^tag:/,"")}`}let s=i.tagPrefixes.find(p=>n.indexOf(p.prefix)===0);if(!s){let p=i.getDefaults().tagPrefixes;s=p&&p.find(c=>n.indexOf(c.prefix)===0)}if(!s)return n[0]==="!"?n:`!<${n}>`;let o=n.substr(s.prefix.length).replace(/[!,[\]{}]/g,p=>({"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"})[p]);return s.handle+o}function k(i,n){if(n instanceof r.Alias)return r.Alias;if(n.tag){let p=i.filter(c=>c.tag===n.tag);if(p.length>0)return p.find(c=>c.format===n.format)||p[0]}let s,o;if(n instanceof r.Scalar){o=n.value;let p=i.filter(c=>c.identify&&c.identify(o)||c.class&&o instanceof c.class);s=p.find(c=>c.format===n.format)||p.find(c=>!c.format)}else o=n,s=i.find(p=>p.nodeClass&&o instanceof p.nodeClass);if(!s){let p=o&&o.constructor?o.constructor.name:typeof o;throw new Error(`Tag not resolved for ${p} value`)}return s}function C(i,n,{anchors:s,doc:o}){let p=[],c=o.anchors.getName(i);return c&&(s[c]=i,p.push(`&${c}`)),i.tag?p.push(A(o,i.tag)):n.default||p.push(A(o,n.tag)),p.join(" ")}function P(i,n,s,o){let{anchors:p,schema:c}=n.doc,h;if(!(i instanceof r.Node)){let x={aliasNodes:[],onTagObj:_=>h=_,prevObjects:new Map};i=c.createNode(i,!0,null,x);for(let _ of x.aliasNodes){_.source=_.source.node;let W=p.getName(_.source);W||(W=p.newName(),p.map[W]=_.source)}}if(i instanceof r.Pair)return i.toString(n,s,o);h||(h=k(c.tags,i));let E=C(i,h,n);E.length>0&&(n.indentAtStart=(n.indentAtStart||0)+E.length+1);let O=typeof h.stringify=="function"?h.stringify(i,n,s,o):i instanceof r.Scalar?r.stringifyString(i,n,s,o):i.toString(n,s,o);return E?i instanceof r.Scalar||O[0]==="{"||O[0]==="["?`${E} ${O}`:`${E}
|
|
140
|
+
${n.indent}${O}`:O}var F=class rn{static validAnchorNode(n){return n instanceof r.Scalar||n instanceof r.YAMLSeq||n instanceof r.YAMLMap}constructor(n){e._defineProperty(this,"map",Object.create(null)),this.prefix=n}createAlias(n,s){return this.setAnchor(n,s),new r.Alias(n)}createMergePair(...n){let s=new r.Merge;return s.value.items=n.map(o=>{if(o instanceof r.Alias){if(o.source instanceof r.YAMLMap)return o}else if(o instanceof r.YAMLMap)return this.createAlias(o);throw new Error("Merge sources must be Map nodes or their Aliases")}),s}getName(n){let{map:s}=this;return Object.keys(s).find(o=>s[o]===n)}getNames(){return Object.keys(this.map)}getNode(n){return this.map[n]}newName(n){n||(n=this.prefix);let s=Object.keys(this.map);for(let o=1;;++o){let p=`${n}${o}`;if(!s.includes(p))return p}}resolveNodes(){let{map:n,_cstAliases:s}=this;Object.keys(n).forEach(o=>{n[o]=n[o].resolved}),s.forEach(o=>{o.source=o.source.resolved}),delete this._cstAliases}setAnchor(n,s){if(n!=null&&!rn.validAnchorNode(n))throw new Error("Anchors may only be set for Scalar, Seq and Map nodes");if(s&&/[\x00-\x19\s,[\]{}]/.test(s))throw new Error("Anchor names must not contain whitespace or control characters");let{map:o}=this,p=n&&Object.keys(o).find(c=>o[c]===n);if(p)if(s)p!==s&&(delete o[p],o[s]=n);else return p;else{if(!s){if(!n)return null;s=this.newName()}o[s]=n}return s}},ie=(i,n)=>{if(i&&typeof i=="object"){let{tag:s}=i;i instanceof r.Collection?(s&&(n[s]=!0),i.items.forEach(o=>ie(o,n))):i instanceof r.Pair?(ie(i.key,n),ie(i.value,n)):i instanceof r.Scalar&&s&&(n[s]=!0)}return n},q=i=>Object.keys(ie(i,{}));function z(i,n){let s={before:[],after:[]},o,p=!1;for(let c of n)if(c.valueRange){if(o!==void 0){let E="Document contains trailing content not separated by a ... or --- line";i.errors.push(new e.YAMLSyntaxError(c,E));break}let h=r.resolveNode(i,c);p&&(h.spaceBefore=!0,p=!1),o=h}else c.comment!==null?(o===void 0?s.before:s.after).push(c.comment):c.type===e.Type.BLANK_LINE&&(p=!0,o===void 0&&s.before.length>0&&!i.commentBefore&&(i.commentBefore=s.before.join(`
|
|
141
|
+
`),s.before=[]));if(i.contents=o||null,!o)i.comment=s.before.concat(s.after).join(`
|
|
142
|
+
`)||null;else{let c=s.before.join(`
|
|
143
|
+
`);if(c){let h=o instanceof r.Collection&&o.items[0]?o.items[0]:o;h.commentBefore=h.commentBefore?`${c}
|
|
144
|
+
${h.commentBefore}`:c}i.comment=s.after.join(`
|
|
145
|
+
`)||null}}function K({tagPrefixes:i},n){let[s,o]=n.parameters;if(!s||!o){let p="Insufficient parameters given for %TAG directive";throw new e.YAMLSemanticError(n,p)}if(i.some(p=>p.handle===s)){let p="The %TAG directive must only be given at most once per handle in the same document.";throw new e.YAMLSemanticError(n,p)}return{handle:s,prefix:o}}function ee(i,n){let[s]=n.parameters;if(n.name==="YAML:1.0"&&(s="1.0"),!s){let o="Insufficient parameters given for %YAML directive";throw new e.YAMLSemanticError(n,o)}if(!b[s]){let o=`Document will be parsed as YAML ${i.version||i.options.version} rather than YAML ${s}`;i.warnings.push(new e.YAMLWarning(n,o))}return s}function ce(i,n,s){let o=[],p=!1;for(let c of n){let{comment:h,name:E}=c;switch(E){case"TAG":try{i.tagPrefixes.push(K(i,c))}catch(O){i.errors.push(O)}p=!0;break;case"YAML":case"YAML:1.0":if(i.version){let O="The %YAML directive must only be given at most once per document.";i.errors.push(new e.YAMLSemanticError(c,O))}try{i.version=ee(i,c)}catch(O){i.errors.push(O)}p=!0;break;default:if(E){let O=`YAML only supports %TAG and %YAML directives, and not %${E}`;i.warnings.push(new e.YAMLWarning(c,O))}}h&&o.push(h)}if(s&&!p&&(i.version||s.version||i.options.version)==="1.1"){let c=({handle:h,prefix:E})=>({handle:h,prefix:E});i.tagPrefixes=s.tagPrefixes.map(c),i.version=s.version}i.commentBefore=o.join(`
|
|
146
|
+
`)||null}function M(i){if(i instanceof r.Collection)return!0;throw new Error("Expected a YAML collection as document contents")}var l=class ht{constructor(n){this.anchors=new F(n.anchorPrefix),this.commentBefore=null,this.comment=null,this.contents=null,this.directivesEndMarker=null,this.errors=[],this.options=n,this.schema=null,this.tagPrefixes=[],this.version=null,this.warnings=[]}add(n){return M(this.contents),this.contents.add(n)}addIn(n,s){M(this.contents),this.contents.addIn(n,s)}delete(n){return M(this.contents),this.contents.delete(n)}deleteIn(n){return r.isEmptyPath(n)?this.contents==null?!1:(this.contents=null,!0):(M(this.contents),this.contents.deleteIn(n))}getDefaults(){return ht.defaults[this.version]||ht.defaults[this.options.version]||{}}get(n,s){return this.contents instanceof r.Collection?this.contents.get(n,s):void 0}getIn(n,s){return r.isEmptyPath(n)?!s&&this.contents instanceof r.Scalar?this.contents.value:this.contents:this.contents instanceof r.Collection?this.contents.getIn(n,s):void 0}has(n){return this.contents instanceof r.Collection?this.contents.has(n):!1}hasIn(n){return r.isEmptyPath(n)?this.contents!==void 0:this.contents instanceof r.Collection?this.contents.hasIn(n):!1}set(n,s){M(this.contents),this.contents.set(n,s)}setIn(n,s){r.isEmptyPath(n)?this.contents=s:(M(this.contents),this.contents.setIn(n,s))}setSchema(n,s){if(!n&&!s&&this.schema)return;typeof n=="number"&&(n=n.toFixed(1)),n==="1.0"||n==="1.1"||n==="1.2"?(this.version?this.version=n:this.options.version=n,delete this.options.schema):n&&typeof n=="string"&&(this.options.schema=n),Array.isArray(s)&&(this.options.customTags=s);let o=Object.assign({},this.getDefaults(),this.options);this.schema=new u.Schema(o)}parse(n,s){this.options.keepCstNodes&&(this.cstNode=n),this.options.keepNodeTypes&&(this.type="DOCUMENT");let{directives:o=[],contents:p=[],directivesEndMarker:c,error:h,valueRange:E}=n;if(h&&(h.source||(h.source=this),this.errors.push(h)),ce(this,o,s),c&&(this.directivesEndMarker=!0),this.range=E?[E.start,E.end]:null,this.setSchema(),this.anchors._cstAliases=[],z(this,p),this.anchors.resolveNodes(),this.options.prettyErrors){for(let O of this.errors)O instanceof e.YAMLError&&O.makePretty();for(let O of this.warnings)O instanceof e.YAMLError&&O.makePretty()}return this}listNonDefaultTags(){return q(this.contents).filter(n=>n.indexOf(u.Schema.defaultPrefix)!==0)}setTagPrefix(n,s){if(n[0]!=="!"||n[n.length-1]!=="!")throw new Error("Handle must start and end with !");if(s){let o=this.tagPrefixes.find(p=>p.handle===n);o?o.prefix=s:this.tagPrefixes.push({handle:n,prefix:s})}else this.tagPrefixes=this.tagPrefixes.filter(o=>o.handle!==n)}toJSON(n,s){let{keepBlobsInJSON:o,mapAsMap:p,maxAliasCount:c}=this.options,h=o&&(typeof n!="string"||!(this.contents instanceof r.Scalar)),E={doc:this,indentStep:" ",keep:h,mapAsMap:h&&!!p,maxAliasCount:c,stringify:P},O=Object.keys(this.anchors.map);O.length>0&&(E.anchors=new Map(O.map(_=>[this.anchors.map[_],{alias:[],aliasCount:0,count:1}])));let x=r.toJSON(this.contents,n,E);if(typeof s=="function"&&E.anchors)for(let{count:_,res:W}of E.anchors.values())s(W,_);return x}toString(){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");let n=this.options.indent;if(!Number.isInteger(n)||n<=0){let O=JSON.stringify(n);throw new Error(`"indent" option must be a positive integer, not ${O}`)}this.setSchema();let s=[],o=!1;if(this.version){let O="%YAML 1.2";this.schema.name==="yaml-1.1"&&(this.version==="1.0"?O="%YAML:1.0":this.version==="1.1"&&(O="%YAML 1.1")),s.push(O),o=!0}let p=this.listNonDefaultTags();this.tagPrefixes.forEach(({handle:O,prefix:x})=>{p.some(_=>_.indexOf(x)===0)&&(s.push(`%TAG ${O} ${x}`),o=!0)}),(o||this.directivesEndMarker)&&s.push("---"),this.commentBefore&&((o||!this.directivesEndMarker)&&s.unshift(""),s.unshift(this.commentBefore.replace(/^/gm,"#")));let c={anchors:Object.create(null),doc:this,indent:"",indentStep:" ".repeat(n),stringify:P},h=!1,E=null;if(this.contents){this.contents instanceof r.Node&&(this.contents.spaceBefore&&(o||this.directivesEndMarker)&&s.push(""),this.contents.commentBefore&&s.push(this.contents.commentBefore.replace(/^/gm,"#")),c.forceBlockIndent=!!this.comment,E=this.contents.comment);let O=E?null:()=>h=!0,x=P(this.contents,c,()=>E=null,O);s.push(r.addComment(x,"",E))}else this.contents!==void 0&&s.push(P(this.contents,c));return this.comment&&((!h||E)&&s[s.length-1]!==""&&s.push(""),s.push(this.comment.replace(/^/gm,"#"))),s.join(`
|
|
147
|
+
`)+`
|
|
148
|
+
`}};e._defineProperty(l,"defaults",b),t.Document=l,t.defaultOptions=g,t.scalarOptions=y}),ur=Me(t=>{"use strict";var e=lr(),r=cr(),u=tn(),g=Pe(),y=Xt();Ve();function b(q,z=!0,K){K===void 0&&typeof z=="string"&&(K=z,z=!0);let ee=Object.assign({},r.Document.defaults[r.defaultOptions.version],r.defaultOptions);return new u.Schema(ee).createNode(q,z,K)}var A=class extends r.Document{constructor(q){super(Object.assign({},r.defaultOptions,q))}};function k(q,z){let K=[],ee;for(let ce of e.parse(q)){let M=new A(z);M.parse(ce,ee),K.push(M),ee=M}return K}function C(q,z){let K=e.parse(q),ee=new A(z).parse(K[0]);if(K.length>1){let ce="Source contains multiple documents; please use YAML.parseAllDocuments()";ee.errors.unshift(new g.YAMLSemanticError(K[1],ce))}return ee}function P(q,z){let K=C(q,z);if(K.warnings.forEach(ee=>y.warn(ee)),K.errors.length>0)throw K.errors[0];return K.toJSON()}function F(q,z){let K=new A(z);return K.contents=q,String(K)}var ie={createNode:b,defaultOptions:r.defaultOptions,Document:A,parse:P,parseAllDocuments:k,parseCST:e.parse,parseDocument:C,scalarOptions:r.scalarOptions,stringify:F};t.YAML=ie}),sn=Me((t,e)=>{e.exports=ur().YAML}),fr=Me(t=>{"use strict";var e=Ve(),r=Pe();t.findPair=e.findPair,t.parseMap=e.resolveMap,t.parseSeq=e.resolveSeq,t.stringifyNumber=e.stringifyNumber,t.stringifyString=e.stringifyString,t.toJSON=e.toJSON,t.Type=r.Type,t.YAMLError=r.YAMLError,t.YAMLReferenceError=r.YAMLReferenceError,t.YAMLSemanticError=r.YAMLSemanticError,t.YAMLSyntaxError=r.YAMLSyntaxError,t.YAMLWarning=r.YAMLWarning}),pr={};Vt(pr,{__parsePrettierYamlConfig:()=>Ds,languages:()=>Oi,options:()=>Li,parsers:()=>xn,printers:()=>Ys});var on=(t,e)=>(r,u,...g)=>r|1&&u==null?void 0:(e.call(u)??u[t]).apply(u,g);function dr(t){return this[t<0?this.length+t:t]}var hr=on("at",function(){if(Array.isArray(this)||typeof this=="string")return dr}),ve=hr,mr=String.prototype.replaceAll??function(t,e){return t.global?this.replace(t,e):this.split(t).join(e)},gr=on("replaceAll",function(){if(typeof this=="string")return mr}),ot=gr,yr=()=>{},tt=yr,an="string",ln="array",cn="cursor",un="indent",wt="align",fn="trim",Ot="group",Nt="fill",Lt="if-break",pn="indent-if-break",At="line-suffix",dn="line-suffix-boundary",De="line",hn="label",Mt="break-parent",mn=new Set([cn,un,wt,fn,Ot,Nt,Lt,pn,At,dn,De,hn,Mt]);function vr(t){if(typeof t=="string")return an;if(Array.isArray(t))return ln;if(!t)return;let{type:e}=t;if(mn.has(e))return e}var gn=vr,Er=t=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(t);function Sr(t){let e=t===null?"null":typeof t;if(e!=="string"&&e!=="object")return`Unexpected doc '${e}',
|
|
149
|
+
Expected it to be 'string' or 'object'.`;if(gn(t))throw new Error("doc is valid.");let r=Object.prototype.toString.call(t);if(r!=="[object Object]")return`Unexpected doc '${r}'.`;let u=Er([...mn].map(g=>`'${g}'`));return`Unexpected doc.type '${t.type}'.
|
|
150
|
+
Expected it to be ${u}.`}var br=class extends Error{name="InvalidDocError";constructor(t){super(Sr(t)),this.doc=t}},wr=br;function Or(t,e){if(typeof t=="string")return e(t);let r=new Map;return u(t);function u(y){if(r.has(y))return r.get(y);let b=g(y);return r.set(y,b),b}function g(y){switch(gn(y)){case ln:return e(y.map(u));case Nt:return e({...y,parts:y.parts.map(u)});case Lt:return e({...y,breakContents:u(y.breakContents),flatContents:u(y.flatContents)});case Ot:{let{expandedStates:b,contents:A}=y;return b?(b=b.map(u),A=b[0]):A=u(A),e({...y,contents:A,expandedStates:b})}case wt:case un:case pn:case hn:case At:return e({...y,contents:u(y.contents)});case an:case cn:case fn:case dn:case De:case Mt:return e(y);default:throw new wr(y)}}}function Nr(t,e=gt){return Or(t,r=>typeof r=="string"?pe(e,r.split(`
|
|
151
|
+
`)):r)}var Be=tt,yn=tt,Lr=tt,Ar=tt;function nt(t,e){return Ar(t),Be(e),{type:wt,contents:e,n:t}}function $t(t){return nt(Number.NEGATIVE_INFINITY,t)}function Mr(t){return nt({type:"root"},t)}function Tr(t){return nt(-1,t)}var Tt={type:Mt};function vn(t){return Lr(t),{type:Nt,parts:t}}function Xe(t,e={}){return Be(t),yn(e.expandedStates,!0),{type:Ot,id:e.id,contents:t,break:!!e.shouldBreak,expandedStates:e.expandedStates}}function Rt(t,e){return Xe(t[0],{...e,expandedStates:t})}function mt(t,e="",r={}){return Be(t),e!==""&&Be(e),{type:Lt,breakContents:t,flatContents:e,groupId:r.groupId}}function pe(t,e){Be(t),yn(e);let r=[];for(let u=0;u<e.length;u++)u!==0&&r.push(t),r.push(e[u]);return r}var Qe={type:De},En={type:De,soft:!0},xr={type:De,hard:!0},H=[xr,Tt],kr={type:De,hard:!0,literal:!0},gt=[kr,Tt];function Cr(t){return Be(t),{type:At,contents:t}}function rt(t){return(e,r,u)=>{let g=!!u?.backwards;if(r===!1)return!1;let{length:y}=e,b=r;for(;b>=0&&b<y;){let A=e.charAt(b);if(t instanceof RegExp){if(!t.test(A))return b}else if(!t.includes(A))return b;g?b--:b++}return b===-1||b===y?b:!1}}var Ws=rt(/\s/u),_t=rt(" "),js=rt(",; "),Fs=rt(/[^\n\r]/u),Yt=t=>t===`
|
|
152
|
+
`||t==="\r"||t==="\u2028"||t==="\u2029";function Ir(t,e,r){let u=!!r?.backwards;if(e===!1)return!1;let g=t.charAt(e);if(u){if(t.charAt(e-1)==="\r"&&g===`
|
|
153
|
+
`)return e-2;if(Yt(g))return e-1}else{if(g==="\r"&&t.charAt(e+1)===`
|
|
154
|
+
`)return e+2;if(Yt(g))return e+1}return e}var Bt=Ir;function Pr(t,e){let r=e-1;r=_t(t,r,{backwards:!0}),r=Bt(t,r,{backwards:!0}),r=_t(t,r,{backwards:!0});let u=Bt(t,r,{backwards:!0});return r!==u}var Sn=Pr,$r=class extends Error{name="UnexpectedNodeError";constructor(t,e,r="type"){super(`Unexpected ${e} node ${r}: ${JSON.stringify(t[r])}.`),this.node=t}},Rr=$r,_r="format",Yr=/^\s*#[^\S\n]*@(?:noformat|noprettier)\s*?(?:\n|$)/u,Br=/^\s*#[^\S\n]*@(?:format|prettier)\s*?(?:\n|$)/u,Dr=/^\s*@(?:format|prettier)\s*$/u,Wr=t=>Dr.test(t),jr=t=>Br.test(t),Fr=t=>Yr.test(t),qr=t=>`# @${_r}
|
|
155
|
+
|
|
156
|
+
${t}`;function bn(t,e){switch(t.type){case"comment":if(Wr(t.value))return null;break;case"quoteDouble":case"quoteSingle":e.type="quote";break;case"document":e.directivesEndMarker||delete e.directivesEndMarker,e.documentEndMarker||delete e.documentEndMarker;break}}bn.ignoredProperties=new Set(["position"]);var Kr=bn;function wn(t,e){let{node:r}=t;if(r.type==="root"&&e.filepath&&/(?:[/\\]|^)\.(?:prettier|stylelint|lintstaged)rc$/u.test(e.filepath))return async u=>{let g=await u(e.originalText,{parser:"json"});return g?[g,H]:void 0}}wn.getVisitorKeys=()=>[];var Ur=wn,Fe=null;function Ue(t){if(Fe!==null&&typeof Fe.property){let e=Fe;return Fe=Ue.prototype=null,e}return Fe=Ue.prototype=t??Object.create(null),new Ue}var Vr=10;for(let t=0;t<=Vr;t++)Ue();function Qr(t){return Ue(t)}function Jr(t,e="type"){Qr(t);function r(u){let g=u[e],y=t[g];if(!Array.isArray(y))throw Object.assign(new Error(`Missing visitor keys for '${g}'.`),{node:u});return y}return r}var Gr=Jr,ae=[["children","anchor","tag","indicatorComment","leadingComments","middleComments","trailingComment","endComments"],["anchor","tag","indicatorComment","leadingComments","middleComments","trailingComment","endComments"],["key","value","children","anchor","tag","indicatorComment","leadingComments","middleComments","trailingComment","endComments"],["content","children","anchor","tag","indicatorComment","leadingComments","middleComments","trailingComment","endComments"],["indicatorComment","leadingComments","middleComments","trailingComment","endComments"]],Hr={root:ae[0],document:["head","body","children","anchor","tag","indicatorComment","leadingComments","middleComments","trailingComment","endComments"],documentHead:ae[0],documentBody:ae[0],directive:ae[1],alias:ae[1],blockLiteral:ae[1],blockFolded:ae[0],plain:ae[0],quoteSingle:ae[1],quoteDouble:ae[1],mapping:ae[0],mappingItem:ae[2],mappingKey:ae[3],mappingValue:ae[3],sequence:ae[0],sequenceItem:ae[3],flowMapping:ae[0],flowMappingItem:ae[2],flowSequence:ae[0],flowSequenceItem:ae[3],comment:ae[1],tag:ae[4],anchor:ae[4]},zr=Gr(Hr),Xr=zr,xt=t=>t.position.start.offset,Zr=t=>t.position.end.offset;function ei(t){return Array.isArray(t)&&t.length>0}var Je=ei;function Oe(t,e){return typeof t?.type=="string"&&e.includes(t.type)}function On(t,e,r){return e("children"in t?{...t,children:t.children.map(u=>On(u,e,t))}:t,r)}function qe(t,e,r){Object.defineProperty(t,e,{get:r,enumerable:!1})}function ti(t,e){let r=0,u=e.length;for(let g=t.position.end.offset-1;g<u;g++){let y=e[g];if(y===`
|
|
157
|
+
`&&r++,r===1&&/\S/u.test(y))return!1;if(r===2)return!0}return!1}function Nn(t){let{node:e}=t;switch(e.type){case"tag":case"anchor":case"comment":return!1}let r=t.stack.length;for(let u=1;u<r;u++){let g=t.stack[u],y=t.stack[u-1];if(Array.isArray(y)&&typeof g=="number"&&g!==y.length-1)return!1}return!0}function yt(t){return Je(t.children)?yt(ve(0,t.children,-1)):t}function Dt(t){return t.value.trim()==="prettier-ignore"}function ni(t){let{node:e}=t;if(e.type==="documentBody"){let r=t.parent.head;return ye(r)&&Dt(ve(0,r.endComments,-1))}return xe(e)&&Dt(ve(0,e.leadingComments,-1))}function Ze(t){return!Je(t.children)&&!ri(t)}function ri(t){return xe(t)||_e(t)||Ln(t)||be(t)||ye(t)}function xe(t){return Je(t?.leadingComments)}function _e(t){return Je(t?.middleComments)}function Ln(t){return t?.indicatorComment}function be(t){return t?.trailingComment}function ye(t){return Je(t?.endComments)}function An(t){return t?t.split(/(?<!^| ) (?! |$)/u):[]}function ii(t,e,r){let u=e.split(`
|
|
158
|
+
`).map((y,b,A)=>b===0&&b===A.length-1?y:b!==0&&b!==A.length-1?y.trim():b===0?y.trimEnd():y.trimStart());if(r.proseWrap==="preserve")return u.map(y=>y?[y]:[]);let g=[];for(let[y,b]of u.entries()){let A=An(b);y>0&&u[y-1].length>0&&A.length>0&&!(t==="quoteDouble"&&ve(0,ve(0,g,-1),-1).endsWith("\\"))?g[g.length-1]=[...ve(0,g,-1),...A]:g.push(A)}return r.proseWrap==="never"?g.map(y=>[y.join(" ")]):g}function si(t,{parentIndent:e,isLastDescendant:r,options:u}){let g=t.position.start.line===t.position.end.line?"":u.originalText.slice(t.position.start.offset,t.position.end.offset).match(/^[^\n]*\n(.*)$/su)[1],y;if(t.indent===null){let C=g.match(/^(?<leadingSpace> *)[^\n\r ]/mu);y=C?C.groups.leadingSpace.length:Number.POSITIVE_INFINITY}else y=t.indent-1+e;let b=g.split(`
|
|
159
|
+
`).map(C=>C.slice(y));if(u.proseWrap==="preserve"||t.type==="blockLiteral")return k(b.map(C=>C?[C]:[]));let A=[];for(let[C,P]of b.entries()){let F=An(P);C>0&&F.length>0&&b[C-1].length>0&&!/^\s/u.test(F[0])&&!/^\s|\s$/u.test(ve(0,A,-1))?A[A.length-1]=[...ve(0,A,-1),...F]:A.push(F)}return A=A.map(C=>{let P=[];for(let F of C)P.length>0&&/\s$/u.test(ve(0,P,-1))?P[P.length-1]+=" "+F:P.push(F);return P}),u.proseWrap==="never"&&(A=A.map(C=>[C.join(" ")])),k(A);function k(C){if(t.chomping==="keep")return ve(0,C,-1).length===0?C.slice(0,-1):C;let P=0;for(let F=C.length-1;F>=0&&C[F].length===0;F--)P++;return P===0?C:P>=2&&!r?C.slice(0,-(P-1)):C.slice(0,-P)}}function vt(t){if(!t)return!0;switch(t.type){case"plain":case"quoteDouble":case"quoteSingle":case"alias":case"flowMapping":case"flowSequence":return!0;default:return!1}}var at=new WeakMap;function Mn(t,e){let{node:r,root:u}=t,g;return at.has(u)?g=at.get(u):(g=new Set,at.set(u,g)),!g.has(r.position.end.line)&&(g.add(r.position.end.line),ti(r,e)&&!Tn(t.parent))?En:""}function Tn(t){return ye(t)&&!Oe(t,["documentHead","documentBody","flowMapping","flowSequence"])}function ge(t,e){return nt(" ".repeat(t),e)}function oi(t,e,r){let{node:u}=t,g=t.ancestors.filter(C=>C.type==="sequence"||C.type==="mapping").length,y=Nn(t),b=[u.type==="blockFolded"?">":"|"];u.indent!==null&&b.push(u.indent.toString()),u.chomping!=="clip"&&b.push(u.chomping==="keep"?"+":"-"),Ln(u)&&b.push(" ",r("indicatorComment"));let A=si(u,{parentIndent:g,isLastDescendant:y,options:e}),k=[];for(let[C,P]of A.entries())C===0&&k.push(H),k.push(vn(pe(Qe,P))),C!==A.length-1?k.push(P.length===0?H:Mr(gt)):u.chomping==="keep"&&y&&k.push($t(P.length===0?H:gt));return u.indent===null?b.push(Tr(ge(e.tabWidth,k))):b.push($t(ge(u.indent-1+g,k))),b}var ai=oi;function Wt(t,e,r){let{node:u}=t,g=u.type==="flowMapping",y=g?"{":"[",b=g?"}":"]",A=En;g&&u.children.length>0&&e.bracketSpacing&&(A=Qe);let k=ve(0,u.children,-1),C=k?.type==="flowMappingItem"&&Ze(k.key)&&Ze(k.value);return[y,ge(e.tabWidth,[A,li(t,e,r),e.trailingComma==="none"?"":mt(","),ye(u)?[H,pe(H,t.map(r,"endComments"))]:""]),C?"":A,b]}function li(t,e,r){return t.map(({isLast:u,node:g,next:y})=>[r(),u?"":[",",Qe,g.position.start.line!==y.position.start.line?Mn(t,e.originalText):""]],"children")}function ci(t,e,r){let{node:u,parent:g}=t,{key:y,value:b}=u,A=Ze(y),k=Ze(b);if(A&&k)return": ";let C=r("key"),P=ui(u)?" ":"";if(k)return u.type==="flowMappingItem"&&g.type==="flowMapping"?C:u.type==="mappingItem"&<(y.content,e)&&!be(y.content)&&g.tag?.value!=="tag:yaml.org,2002:set"?[C,P,":"]:["? ",ge(2,C)];let F=r("value");if(A)return[": ",ge(2,F)];if(xe(b)||!vt(y.content))return["? ",ge(2,C),H,...t.map(()=>[r(),H],"value","leadingComments"),": ",ge(2,F)];if(fi(y.content)&&!xe(y.content)&&!_e(y.content)&&!be(y.content)&&!ye(y)&&!xe(b.content)&&!_e(b.content)&&!ye(b)&<(b.content,e))return[C,P,": ",F];let ie=Symbol("mappingKey"),q=Xe([mt("? "),Xe(ge(2,C),{id:ie})]),z=[H,": ",ge(2,F)],K=[P,":"];ye(b)&&b.content&&Oe(b.content,["flowMapping","flowSequence"])&&b.content.children.length===0?K.push(" "):xe(b.content)||ye(b)&&b.content&&!Oe(b.content,["mapping","sequence"])||g.type==="mapping"&&be(y.content)&&vt(b.content)||Oe(b.content,["mapping","sequence"])&&b.content.tag===null&&b.content.anchor===null?K.push(H):b.content?K.push(Qe):be(b)&&K.push(" "),K.push(F);let ee=ge(e.tabWidth,K);return lt(y.content,e)&&!xe(y.content)&&!_e(y.content)&&!be(y.content)&&!ye(y)?Rt([[C,ee]]):Rt([[q,mt(z,ee,{groupId:ie})]])}function lt(t,e){if(!t)return!0;switch(t.type){case"plain":case"quoteSingle":case"quoteDouble":break;case"alias":return!0;default:return!1}if(e.proseWrap==="preserve")return t.position.start.line===t.position.end.line;if(/\\$/mu.test(e.originalText.slice(t.position.start.offset,t.position.end.offset)))return!1;switch(e.proseWrap){case"never":return!t.value.includes(`
|
|
160
|
+
`);case"always":return!/[\n ]/u.test(t.value);default:return!1}}function ui(t){return t.key.content?.type==="alias"}function fi(t){if(!t)return!0;switch(t.type){case"plain":case"quoteDouble":case"quoteSingle":return t.position.start.line===t.position.end.line;case"alias":return!0;default:return!1}}var pi=ci;function di(t){return On(t,hi)}function hi(t){switch(t.type){case"document":qe(t,"head",()=>t.children[0]),qe(t,"body",()=>t.children[1]);break;case"documentBody":case"sequenceItem":case"flowSequenceItem":case"mappingKey":case"mappingValue":qe(t,"content",()=>t.children[0]);break;case"mappingItem":case"flowMappingItem":qe(t,"key",()=>t.children[0]),qe(t,"value",()=>t.children[1]);break}return t}var mi=di;function gi(t,e,r){let{node:u}=t,g=[];u.type!=="mappingValue"&&xe(u)&&g.push([pe(H,t.map(r,"leadingComments")),H]);let{tag:y,anchor:b}=u;y&&g.push(r("tag")),y&&b&&g.push(" "),b&&g.push(r("anchor"));let A="";return Oe(u,["mapping","sequence","comment","directive","mappingItem","sequenceItem"])&&!Nn(t)&&(A=Mn(t,e.originalText)),(y||b)&&(Oe(u,["sequence","mapping"])&&!_e(u)?g.push(H):g.push(" ")),_e(u)&&g.push([u.middleComments.length===1?"":H,pe(H,t.map(r,"middleComments")),H]),ni(t)?g.push(Nr(e.originalText.slice(u.position.start.offset,u.position.end.offset).trimEnd())):g.push(Xe(yi(t,e,r))),be(u)&&!Oe(u,["document","documentHead"])&&g.push(Cr([u.type==="mappingValue"&&!u.content?"":" ",t.parent.type==="mappingKey"&&t.getParentNode(2).type==="mapping"&&vt(u)?"":Tt,r("trailingComment")])),Tn(u)&&g.push(ge(u.type==="sequenceItem"?2:0,[H,pe(H,t.map(({node:k})=>[Sn(e.originalText,xt(k))?H:"",r()],"endComments"))])),g.push(A),g}function yi(t,e,r){let{node:u}=t;switch(u.type){case"root":{let g=yt(u),y=!(Oe(g,["blockLiteral","blockFolded"])&&g.chomping==="keep"),b=[];return t.each(({node:A,isFirst:k})=>{k||b.push(H),b.push(r()),Ei(t)&&(y&&b.push(H),b.push("..."),be(A)&&b.push(" ",r("trailingComment")))},"children"),y&&b.push(H),b}case"document":{let g=[];return Si(t)&&((u.head.children.length>0||u.head.endComments.length>0)&&g.push(r("head")),be(u.head)?g.push(["---"," ",r(["head","trailingComment"])]):g.push("---")),vi(u)&&g.push(r("body")),pe(H,g)}case"documentHead":return pe(H,[...t.map(r,"children"),...t.map(r,"endComments")]);case"documentBody":{let{children:g,endComments:y}=u,b="";if(g.length>0&&y.length>0){let A=yt(u);if(Oe(A,["blockFolded","blockLiteral"]))A.chomping!=="keep"&&(b=[H,H]);else{let k=ve(0,g,-1);b=Oe(k,["mapping"])&&Sn(e.originalText,xt(y[0]))?[H,H]:H}}return[pe(H,t.map(r,"children")),b,pe(H,t.map(r,"endComments"))]}case"directive":return["%",pe(" ",[u.name,...u.parameters])];case"comment":return["#",u.value];case"alias":return["*",u.value];case"tag":return e.originalText.slice(u.position.start.offset,u.position.end.offset);case"anchor":return["&",u.value];case"plain":return Ke(u.type,e.originalText.slice(u.position.start.offset,u.position.end.offset),e);case"quoteDouble":case"quoteSingle":{let g=e.originalText.slice(u.position.start.offset+1,u.position.end.offset-1);if(u.type==="quoteSingle"&&g.includes("\\")||u.type==="quoteDouble"&&/\\[^"]/u.test(g)){let b=u.type==="quoteDouble"?'"':"'";return[b,Ke(u.type,g,e),b]}if(g.includes('"'))return["'",Ke(u.type,u.type==="quoteDouble"?ot(0,ot(0,g,'\\"','"'),"'","'".repeat(2)):g,e),"'"];if(g.includes("'"))return['"',Ke(u.type,u.type==="quoteSingle"?ot(0,g,"''","'"):g,e),'"'];let y=e.singleQuote?"'":'"';return[y,Ke(u.type,g,e),y]}case"blockFolded":case"blockLiteral":return ai(t,e,r);case"mapping":case"sequence":return pe(H,t.map(r,"children"));case"sequenceItem":return["- ",ge(2,u.content?r("content"):"")];case"mappingKey":case"mappingValue":return u.content?r("content"):"";case"mappingItem":case"flowMappingItem":return pi(t,e,r);case"flowMapping":return Wt(t,e,r);case"flowSequence":return Wt(t,e,r);case"flowSequenceItem":return r("content");default:throw new Rr(u,"YAML")}}function vi(t){return t.body.children.length>0||ye(t.body)}function Ei(t){let e=t.node;if(e.documentEndMarker||be(e))return!0;if(t.isLast)return!1;let r=t.next;return r.head.children.length>0||ye(r.head)}function Si(t){let e=t.node;return e.directivesEndMarker||e.head.children.length>0||ye(e.head)||be(e.head)}function Ke(t,e,r){let u=ii(t,e,r);return pe(H,u.map(g=>vn(pe(Qe,g))))}var bi={preprocess:mi,embed:Ur,print:gi,massageAstNode:Kr,insertPragma:qr,getVisitorKeys:Xr},wi=bi,Oi=[{name:"YAML",type:"data",aceMode:"yaml",extensions:[".yml",".mir",".reek",".rviz",".sublime-syntax",".syntax",".yaml",".yaml-tmlanguage",".yaml.sed",".yml.mysql"],filenames:[".clang-format",".clang-tidy",".clangd",".gemrc","CITATION.cff","glide.lock","pixi.lock",".prettierrc",".stylelintrc",".lintstagedrc"],tmScope:"source.yaml",aliases:["yml"],codemirrorMode:"yaml",codemirrorMimeType:"text/x-yaml",parsers:["yaml"],vscodeLanguageIds:["yaml","ansible","dockercompose","github-actions-workflow","home-assistant"],linguistLanguageId:407}],ct={bracketSpacing:{category:"Common",type:"boolean",default:!0,description:"Print spaces between brackets.",oppositeDescription:"Do not print spaces between brackets."},objectWrap:{category:"Common",type:"choice",default:"preserve",description:"How to wrap object literals.",choices:[{value:"preserve",description:"Keep as multi-line, if there is a newline between the opening brace and first property."},{value:"collapse",description:"Fit to a single line when possible."}]},singleQuote:{category:"Common",type:"boolean",default:!1,description:"Use single quotes instead of double quotes."},proseWrap:{category:"Common",type:"choice",default:"preserve",description:"How to wrap prose.",choices:[{value:"always",description:"Wrap prose if it exceeds the print width."},{value:"never",description:"Do not wrap prose."},{value:"preserve",description:"Wrap prose as-is."}]},bracketSameLine:{category:"Common",type:"boolean",default:!1,description:"Put > of opening tags on the last line instead of on a new line."},singleAttributePerLine:{category:"Common",type:"boolean",default:!1,description:"Enforce single attribute per line in HTML, Vue and JSX."}},Ni={bracketSpacing:ct.bracketSpacing,singleQuote:ct.singleQuote,proseWrap:ct.proseWrap},Li=Ni,xn={};Vt(xn,{yaml:()=>_s});var jt=bt(sn(),1),Ee=bt(fr(),1),qs=Ee.default.findPair,Ks=Ee.default.toJSON,Us=Ee.default.parseMap,Vs=Ee.default.parseSeq,Qs=Ee.default.stringifyNumber,Js=Ee.default.stringifyString,Gs=Ee.default.Type,Hs=Ee.default.YAMLError,zs=Ee.default.YAMLReferenceError,Ai=Ee.default.YAMLSemanticError,Xs=Ee.default.YAMLSyntaxError,Zs=Ee.default.YAMLWarning;function de(t,e=null){"children"in t&&t.children.forEach(r=>de(r,t)),"anchor"in t&&t.anchor&&de(t.anchor,t),"tag"in t&&t.tag&&de(t.tag,t),"leadingComments"in t&&t.leadingComments.forEach(r=>de(r,t)),"middleComments"in t&&t.middleComments.forEach(r=>de(r,t)),"indicatorComment"in t&&t.indicatorComment&&de(t.indicatorComment,t),"trailingComment"in t&&t.trailingComment&&de(t.trailingComment,t),"endComments"in t&&t.endComments.forEach(r=>de(r,t)),Object.defineProperty(t,"_parent",{value:e,enumerable:!1})}function et(t){return`${t.line}:${t.column}`}function Mi(t){de(t);let e=Ti(t),r=t.children.slice();t.comments.sort((u,g)=>u.position.start.offset-g.position.end.offset).filter(u=>!u._parent).forEach(u=>{for(;r.length>1&&u.position.start.line>r[0].position.end.line;)r.shift();xi(u,e,r[0])})}function Ti(t){let e=Array.from(new Array(t.position.end.line),()=>({}));for(let r of t.comments)e[r.position.start.line-1].comment=r;return kn(e,t),e}function kn(t,e){if(e.position.start.offset!==e.position.end.offset){if("leadingComments"in e){let{start:r}=e.position,{leadingAttachableNode:u}=t[r.line-1];(!u||r.column<u.position.start.column)&&(t[r.line-1].leadingAttachableNode=e)}if("trailingComment"in e&&e.position.end.column>1&&e.type!=="document"&&e.type!=="documentHead"){let{end:r}=e.position,{trailingAttachableNode:u}=t[r.line-1];(!u||r.column>=u.position.end.column)&&(t[r.line-1].trailingAttachableNode=e)}if(e.type!=="root"&&e.type!=="document"&&e.type!=="documentHead"&&e.type!=="documentBody"){let{start:r,end:u}=e.position,g=[u.line].concat(r.line===u.line?[]:r.line);for(let y of g){let b=t[y-1].trailingNode;(!b||u.column>=b.position.end.column)&&(t[y-1].trailingNode=e)}}"children"in e&&e.children.forEach(r=>{kn(t,r)})}}function xi(t,e,r){let u=t.position.start.line,{trailingAttachableNode:g}=e[u-1];if(g){if(g.trailingComment)throw new Error(`Unexpected multiple trailing comment at ${et(t.position.start)}`);de(t,g),g.trailingComment=t;return}for(let b=u;b>=r.position.start.line;b--){let{trailingNode:A}=e[b-1],k;if(A)k=A;else if(b!==u&&e[b-1].comment)k=e[b-1].comment._parent;else continue;if((k.type==="sequence"||k.type==="mapping")&&(k=k.children[0]),k.type==="mappingItem"){let[C,P]=k.children;k=Cn(C)?C:P}for(;;){if(ki(k,t)){de(t,k),k.endComments.push(t);return}if(!k._parent)break;k=k._parent}break}for(let b=u+1;b<=r.position.end.line;b++){let{leadingAttachableNode:A}=e[b-1];if(A){de(t,A),A.leadingComments.push(t);return}}let y=r.children[1];de(t,y),y.endComments.push(t)}function ki(t,e){if(t.position.start.offset<e.position.start.offset&&t.position.end.offset>e.position.end.offset)switch(t.type){case"flowMapping":case"flowSequence":return t.children.length===0||e.position.start.line>t.children[t.children.length-1].position.end.line}if(e.position.end.offset<t.position.end.offset)return!1;switch(t.type){case"sequenceItem":return e.position.start.column>t.position.start.column;case"mappingKey":case"mappingValue":return e.position.start.column>t._parent.position.start.column&&(t.children.length===0||t.children.length===1&&t.children[0].type!=="blockFolded"&&t.children[0].type!=="blockLiteral")&&(t.type==="mappingValue"||Cn(t));default:return!1}}function Cn(t){return t.position.start!==t.position.end&&(t.children.length===0||t.position.start.offset!==t.children[0].position.start.offset)}function le(t,e){return{type:t,position:e}}function Ci(t,e,r){return{...le("root",t),children:e,comments:r}}function ze(t){switch(t.type){case"DOCUMENT":for(let e=t.contents.length-1;e>=0;e--)t.contents[e].type==="BLANK_LINE"?t.contents.splice(e,1):ze(t.contents[e]);for(let e=t.directives.length-1;e>=0;e--)t.directives[e].type==="BLANK_LINE"&&t.directives.splice(e,1);break;case"FLOW_MAP":case"FLOW_SEQ":case"MAP":case"SEQ":for(let e=t.items.length-1;e>=0;e--){let r=t.items[e];"char"in r||(r.type==="BLANK_LINE"?t.items.splice(e,1):ze(r))}break;case"MAP_KEY":case"MAP_VALUE":case"SEQ_ITEM":t.node&&ze(t.node);break;case"ALIAS":case"BLANK_LINE":case"BLOCK_FOLDED":case"BLOCK_LITERAL":case"COMMENT":case"DIRECTIVE":case"PLAIN":case"QUOTE_DOUBLE":case"QUOTE_SINGLE":break;default:throw new Error(`Unexpected node type ${JSON.stringify(t.type)}`)}}function Ie(t,e){return{start:t,end:e}}function Ft(t){return{start:t,end:t}}var Ye;(function(t){t.Tag="!",t.Anchor="&",t.Comment="#"})(Ye||(Ye={}));function Ii(t,e){return{...le("anchor",t),value:e}}function kt(t,e){return{...le("comment",t),value:e}}function Pi(t,e,r){return{anchor:e,tag:t,middleComments:r}}function $i(t,e){return{...le("tag",t),value:e}}function In(t,e,r=()=>!1){let u=t.cstNode,g=[],y=null,b=null,A=null;for(let k of u.props){let C=e.text[k.origStart];switch(C){case Ye.Tag:y=y||k,b=$i(e.transformRange(k),t.tag);break;case Ye.Anchor:y=y||k,A=Ii(e.transformRange(k),u.anchor);break;case Ye.Comment:{let P=kt(e.transformRange(k),e.text.slice(k.origStart+1,k.origEnd));e.comments.push(P),!r(P)&&y&&y.origEnd<=k.origStart&&k.origEnd<=u.valueRange.origStart&&g.push(P);break}default:throw new Error(`Unexpected leading character ${JSON.stringify(C)}`)}}return Pi(b,A,g)}function We(){return{leadingComments:[]}}function it(t=null){return{trailingComment:t}}function $e(){return{...We(),...it()}}function Ri(t,e,r){return{...le("alias",t),...$e(),...e,value:r}}function _i(t,e){let r=t.cstNode;return Ri(e.transformRange({origStart:r.valueRange.origStart-1,origEnd:r.valueRange.origEnd}),e.transformContent(t),r.rawValue)}function Yi(t){return{...t,type:"blockFolded"}}function Bi(t,e,r,u,g,y){return{...le("blockValue",t),...We(),...e,chomping:r,indent:u,value:g,indicatorComment:y}}var Et;(function(t){t.CLIP="clip",t.STRIP="strip",t.KEEP="keep"})(Et||(Et={}));function Pn(t,e){let r=t.cstNode,u=1,g=r.chomping==="CLIP"?0:1,y=r.header.origEnd-r.header.origStart-u-g!==0,b=e.transformRange({origStart:r.header.origStart,origEnd:r.valueRange.origEnd}),A=null,k=In(t,e,C=>{if(!(b.start.offset<C.position.start.offset&&C.position.end.offset<b.end.offset))return!1;if(A)throw new Error(`Unexpected multiple indicator comments at ${et(C.position.start)}`);return A=C,!0});return Bi(b,k,Et[r.chomping],y?r.blockIndent:null,r.strValue,A)}function Di(t,e){return Yi(Pn(t,e))}function Wi(t){return{...t,type:"blockLiteral"}}function ji(t,e){return Wi(Pn(t,e))}function Fi(t,e){return kt(e.transformRange(t.range),t.comment)}function qi(t,e,r){return{...le("directive",t),...$e(),name:e,parameters:r}}function Ct(t,e){for(let r of t.props){let u=e.text[r.origStart];if(u===Ye.Comment)e.comments.push(kt(e.transformRange(r),e.text.slice(r.origStart+1,r.origEnd)));else throw new Error(`Unexpected leading character ${JSON.stringify(u)}`)}}function Ki(t,e){return Ct(t,e),qi(e.transformRange(t.range),t.name,t.parameters)}function Ui(t,e,r,u,g,y){return{...le("document",t),...it(y),directivesEndMarker:e,documentEndMarker:r,children:[u,g]}}function Re(t=[]){return{endComments:t}}function Vi(t,e,r){return{...le("documentBody",t),...Re(r),children:e?[e]:[]}}function ke(t){return t[t.length-1]}function $n(t,e){let r=t.match(e);return r?r.index:-1}function Qi(t,e,r){let u=t.cstNode,{comments:g,endComments:y,documentTrailingComment:b,documentHeadTrailingComment:A}=Ji(u,e,r),k=e.transformNode(t.contents),{position:C,documentEndPoint:P}=Gi(u,k,e);return e.comments.push(...g,...y),{documentBody:Vi(C,k,y),documentEndPoint:P,documentTrailingComment:b,documentHeadTrailingComment:A}}function Ji(t,e,r){let u=[],g=[],y=[],b=[],A=!1;for(let k=t.contents.length-1;k>=0;k--){let C=t.contents[k];if(C.type==="COMMENT"){let P=e.transformNode(C);r&&r.line===P.position.start.line?b.unshift(P):A?u.unshift(P):P.position.start.offset>=t.valueRange.origEnd?y.unshift(P):u.unshift(P)}else A=!0}if(y.length>1)throw new Error(`Unexpected multiple document trailing comments at ${et(y[1].position.start)}`);if(b.length>1)throw new Error(`Unexpected multiple documentHead trailing comments at ${et(b[1].position.start)}`);return{comments:u,endComments:g,documentTrailingComment:ke(y)||null,documentHeadTrailingComment:ke(b)||null}}function Gi(t,e,r){let u=$n(r.text.slice(t.valueRange.origEnd),/^\.\.\./),g=u===-1?t.valueRange.origEnd:Math.max(0,t.valueRange.origEnd-1);r.text[g-1]==="\r"&&g--;let y=r.transformRange({origStart:e!==null?e.position.start.offset:g,origEnd:g}),b=u===-1?y.end:r.transformOffset(t.valueRange.origEnd+3);return{position:y,documentEndPoint:b}}function Hi(t,e,r,u){return{...le("documentHead",t),...Re(r),...it(u),children:e}}function zi(t,e){let r=t.cstNode,{directives:u,comments:g,endComments:y}=Xi(r,e),{position:b,documentEndMarkererPoint:A}=Zi(r,u,e);return e.comments.push(...g,...y),{createDocumentHeadWithTrailingComment:k=>(k&&e.comments.push(k),Hi(b,u,y,k)),documentHeadEndMarkerPoint:A}}function Xi(t,e){let r=[],u=[],g=[],y=!1;for(let b=t.directives.length-1;b>=0;b--){let A=e.transformNode(t.directives[b]);A.type==="comment"?y?u.unshift(A):g.unshift(A):(y=!0,r.unshift(A))}return{directives:r,comments:u,endComments:g}}function Zi(t,e,r){let u=$n(r.text.slice(0,t.valueRange.origStart),/---\s*$/);u>0&&!/[\r\n]/.test(r.text[u-1])&&(u=-1);let g=u===-1?{origStart:t.valueRange.origStart,origEnd:t.valueRange.origStart}:{origStart:u,origEnd:u+3};return e.length!==0&&(g.origStart=e[0].position.start.offset),{position:r.transformRange(g),documentEndMarkererPoint:u===-1?null:r.transformOffset(u)}}function es(t,e){let{createDocumentHeadWithTrailingComment:r,documentHeadEndMarkerPoint:u}=zi(t,e),{documentBody:g,documentEndPoint:y,documentTrailingComment:b,documentHeadTrailingComment:A}=Qi(t,e,u),k=r(A);b&&e.comments.push(b);let C=t.cstNode;return Ui(Ie(k.position.start,y),!!C.directivesEndMarker,!!C.documentEndMarker,k,g,b)}function Rn(t,e,r){return{...le("flowCollection",t),...$e(),...Re(),...e,children:r}}function ts(t,e,r){return{...Rn(t,e,r),type:"flowMapping"}}function _n(t,e,r){return{...le("flowMappingItem",t),...We(),children:[e,r]}}function st(t,e){let r=[];for(let u of t)u&&"type"in u&&u.type==="COMMENT"?e.comments.push(e.transformNode(u)):r.push(u);return r}function Yn(t){let[e,r]=["?",":"].map(u=>{let g=t.find(y=>"char"in y&&y.char===u);return g?{origStart:g.origOffset,origEnd:g.origOffset+1}:null});return{additionalKeyRange:e,additionalValueRange:r}}function Bn(t,e){let r=e;return u=>t.slice(r,r=u)}function Dn(t){let e=[],r=Bn(t,1),u=!1;for(let g=1;g<t.length-1;g++){let y=t[g];if("char"in y&&y.char===","){e.push(r(g)),r(g+1),u=!1;continue}u=!0}return u&&e.push(r(t.length-1)),e}function qt(t,e){return{...le("mappingKey",t),...it(),...Re(),children:e?[e]:[]}}function Kt(t,e){return{...le("mappingValue",t),...$e(),...Re(),children:e?[e]:[]}}function It(t,e,r,u,g){let y=e.transformNode(t.key),b=e.transformNode(t.value),A=y||u?qt(e.transformRange({origStart:u?u.origStart:y.position.start.offset,origEnd:y?y.position.end.offset:u.origStart+1}),y):null,k=b||g?Kt(e.transformRange({origStart:g?g.origStart:b.position.start.offset,origEnd:b?b.position.end.offset:g.origStart+1}),b):null;return r(Ie(A?A.position.start:k.position.start,k?k.position.end:A.position.end),A||qt(Ft(k.position.start),null),k||Kt(Ft(A.position.end),null))}function ns(t,e){let r=st(t.cstNode.items,e),u=Dn(r),g=t.items.map((A,k)=>{let C=u[k],{additionalKeyRange:P,additionalValueRange:F}=Yn(C);return It(A,e,_n,P,F)}),y=r[0],b=ke(r);return ts(e.transformRange({origStart:y.origOffset,origEnd:b.origOffset+1}),e.transformContent(t),g)}function rs(t,e,r){return{...Rn(t,e,r),type:"flowSequence"}}function is(t,e){return{...le("flowSequenceItem",t),children:[e]}}function ss(t,e){let r=st(t.cstNode.items,e),u=Dn(r),g=t.items.map((A,k)=>{if(A.type!=="PAIR"){let C=e.transformNode(A);return is(Ie(C.position.start,C.position.end),C)}else{let C=u[k],{additionalKeyRange:P,additionalValueRange:F}=Yn(C);return It(A,e,_n,P,F)}}),y=r[0],b=ke(r);return rs(e.transformRange({origStart:y.origOffset,origEnd:b.origOffset+1}),e.transformContent(t),g)}function os(t,e,r){return{...le("mapping",t),...We(),...e,children:r}}function as(t,e,r){return{...le("mappingItem",t),...We(),children:[e,r]}}function ls(t,e){let r=t.cstNode;r.items.filter(b=>b.type==="MAP_KEY"||b.type==="MAP_VALUE").forEach(b=>Ct(b,e));let u=st(r.items,e),g=cs(u),y=t.items.map((b,A)=>{let k=g[A],[C,P]=k[0].type==="MAP_VALUE"?[null,k[0].range]:[k[0].range,k.length===1?null:k[1].range];return It(b,e,as,C,P)});return os(Ie(y[0].position.start,ke(y).position.end),e.transformContent(t),y)}function cs(t){let e=[],r=Bn(t,0),u=!1;for(let g=0;g<t.length;g++){if(t[g].type==="MAP_VALUE"){e.push(r(g+1)),u=!1;continue}u&&e.push(r(g)),u=!0}return u&&e.push(r(1/0)),e}function us(t,e,r){return{...le("plain",t),...$e(),...e,value:r}}function fs(t,e,r){for(let u=e;u>=0;u--)if(r.test(t[u]))return u;return-1}function ps(t,e){let r=t.cstNode;return us(e.transformRange({origStart:r.valueRange.origStart,origEnd:fs(e.text,r.valueRange.origEnd-1,/\S/)+1}),e.transformContent(t),r.strValue)}function ds(t){return{...t,type:"quoteDouble"}}function hs(t,e,r){return{...le("quoteValue",t),...e,...$e(),value:r}}function Wn(t,e){let r=t.cstNode;return hs(e.transformRange(r.valueRange),e.transformContent(t),r.strValue)}function ms(t,e){return ds(Wn(t,e))}function gs(t){return{...t,type:"quoteSingle"}}function ys(t,e){return gs(Wn(t,e))}function vs(t,e,r){return{...le("sequence",t),...We(),...Re(),...e,children:r}}function Es(t,e){return{...le("sequenceItem",t),...$e(),...Re(),children:e?[e]:[]}}function Ss(t,e){let r=st(t.cstNode.items,e).map((u,g)=>{Ct(u,e);let y=e.transformNode(t.items[g]);return Es(Ie(e.transformOffset(u.valueRange.origStart),y===null?e.transformOffset(u.valueRange.origStart+1):y.position.end),y)});return vs(Ie(r[0].position.start,ke(r).position.end),e.transformContent(t),r)}function bs(t,e){if(t===null||t.type===void 0&&t.value===null)return null;switch(t.type){case"ALIAS":return _i(t,e);case"BLOCK_FOLDED":return Di(t,e);case"BLOCK_LITERAL":return ji(t,e);case"COMMENT":return Fi(t,e);case"DIRECTIVE":return Ki(t,e);case"DOCUMENT":return es(t,e);case"FLOW_MAP":return ns(t,e);case"FLOW_SEQ":return ss(t,e);case"MAP":return ls(t,e);case"PLAIN":return ps(t,e);case"QUOTE_DOUBLE":return ms(t,e);case"QUOTE_SINGLE":return ys(t,e);case"SEQ":return Ss(t,e);default:throw new Error(`Unexpected node type ${t.type}`)}}var ut,ws=class{text;comments=[];#e;#t;constructor(t,e){this.text=e,this.#e=t}setOrigRanges(){if(!this.#e.setOrigRanges())for(let t of this.#e)t.setOrigRanges([],0)}#n(t){if(!ut){let[y]=this.#e,b=Object.getPrototypeOf(Object.getPrototypeOf(y));ut=Object.getOwnPropertyDescriptor(b,"rangeAsLinePos").get}if(this.#t??(this.#t={root:{context:{src:this.text}}}),this.text===""&&t.origStart===0&&t.origEnd===0)return{start:{offset:0,line:1,column:1},end:{offset:0,line:1,column:1}};let{start:{line:e,col:r},end:{line:u,col:g}}=ut.call({range:{start:this.#r(t.origStart),end:this.#r(t.origEnd)},context:this.#t});return{start:{offset:t.origStart,line:e,column:r},end:{offset:t.origEnd,line:u,column:g}}}#r(t){return t<0?0:t>this.text.length?this.text.length:t}transformOffset(t){return this.#n({origStart:t,origEnd:t}).start}transformRange(t){let{start:e,end:r}=this.#n(t);return Ie(e,r)}transformNode(t){return bs(t,this)}transformContent(t){return In(t,this)}},Os=ws;function Ns(t,e,r){let u=new SyntaxError(t);return u.name="YAMLSyntaxError",u.source=e,u.position=r,u}function Ls(t,e){let r=t.source.range||t.source.valueRange;return Ns(t.message,e.text,e.transformRange(r))}function jn(t){if("children"in t){if(t.children.length===1){let e=t.children[0];if(e.type==="plain"&&e.tag===null&&e.anchor===null&&e.value==="")return t.children.splice(0,1),t}t.children.forEach(jn)}return t}function Ut(t,e,r,u){let g=e(t);return y=>{u(g,y)&&r(t,g=y)}}function Fn(t){if(t===null||!("children"in t))return;let e=t.children;if(e.forEach(Fn),t.type==="document"){let[y,b]=t.children;y.position.start.offset===y.position.end.offset?y.position.start=y.position.end=b.position.start:b.position.start.offset===b.position.end.offset&&(b.position.start=b.position.end=y.position.end)}let r=Ut(t.position,As,Ms,ks),u=Ut(t.position,Ts,xs,Cs);"endComments"in t&&t.endComments.length!==0&&(r(t.endComments[0].position.start),u(ke(t.endComments).position.end));let g=e.filter(y=>y!==null);if(g.length!==0){let y=g[0],b=ke(g);r(y.position.start),u(b.position.end),"leadingComments"in y&&y.leadingComments.length!==0&&r(y.leadingComments[0].position.start),"tag"in y&&y.tag&&r(y.tag.position.start),"anchor"in y&&y.anchor&&r(y.anchor.position.start),"trailingComment"in b&&b.trailingComment&&u(b.trailingComment.position.end)}}function As(t){return t.start}function Ms(t,e){t.start=e}function Ts(t){return t.end}function xs(t,e){t.end=e}function ks(t,e){return e.offset<t.offset}function Cs(t,e){return e.offset>t.offset}function Is(t){let e=jt.default.parseCST(t),r=new Os(e,t);r.setOrigRanges();let u=e.map(y=>new jt.default.Document({merge:!1,keepCstNodes:!0}).parse(y));for(let y of u)for(let b of y.errors)if(!(b instanceof Ai&&b.message==='Map keys must be unique; "<<" is repeated'))throw Ls(b,r);u.forEach(y=>ze(y.cstNode));let g=Ci(r.transformRange({origStart:0,origEnd:t.length}),u.map(y=>r.transformNode(y)),r.comments);return Mi(g),Fn(g),jn(g),g}function Ps(t,e){let r=new SyntaxError(t+" ("+e.loc.start.line+":"+e.loc.start.column+")");return Object.assign(r,e)}var $s=Ps;function Rs(t){try{let e=Is(t);return delete e.comments,e}catch(e){throw e?.position?$s(e.message,{loc:e.position,cause:e}):e}}var _s={astFormat:"yaml",parse:Rs,hasPragma:jr,hasIgnorePragma:Fr,locStart:xt,locEnd:Zr},Ys={yaml:wi},Bs=bt(sn(),1),Ds=Bs.default.parse;export{Ds as __parsePrettierYamlConfig,pr as default,Oi as languages,Li as options,xn as parsers,Ys as printers};
|
package/package.json
CHANGED
|
@@ -5,23 +5,18 @@
|
|
|
5
5
|
"@shopify:registry": "https://registry.npmjs.org"
|
|
6
6
|
},
|
|
7
7
|
"license": "MIT",
|
|
8
|
-
"version": "5.0.
|
|
8
|
+
"version": "5.0.30",
|
|
9
9
|
"type": "module",
|
|
10
10
|
"repository": {
|
|
11
11
|
"type": "git",
|
|
12
12
|
"url": "git+https://github.com/Shopify/hydrogen.git",
|
|
13
13
|
"directory": "packages/create-hydrogen"
|
|
14
14
|
},
|
|
15
|
-
"scripts": {
|
|
16
|
-
"build": "tsup --clean",
|
|
17
|
-
"dev": "tsup --watch src --watch ../cli/src",
|
|
18
|
-
"test": "vitest run --test-timeout=60000",
|
|
19
|
-
"typecheck": "tsc --noEmit"
|
|
20
|
-
},
|
|
21
15
|
"dependencies": {
|
|
22
16
|
"@ast-grep/napi": "0.34.1"
|
|
23
17
|
},
|
|
24
18
|
"devDependencies": {
|
|
19
|
+
"@types/node": "^22",
|
|
25
20
|
"execa": "^8.0.1",
|
|
26
21
|
"tempy": "3.1.0",
|
|
27
22
|
"vitest": "^3.2.4"
|
|
@@ -29,5 +24,11 @@
|
|
|
29
24
|
"bin": "dist/create-app.js",
|
|
30
25
|
"files": [
|
|
31
26
|
"dist"
|
|
32
|
-
]
|
|
33
|
-
|
|
27
|
+
],
|
|
28
|
+
"scripts": {
|
|
29
|
+
"build": "tsup --clean",
|
|
30
|
+
"dev": "tsup --watch src --watch ../cli/src",
|
|
31
|
+
"test": "vitest run --test-timeout=60000",
|
|
32
|
+
"typecheck": "tsc --noEmit"
|
|
33
|
+
}
|
|
34
|
+
}
|
package/dist/chunk-AUULK6IN.js
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { createRequire as __createRequire } from 'module';globalThis.require = __createRequire(import.meta.url);
|
|
2
|
-
import{a as we,c as w,i as d}from"./chunk-LBUW5UHX.js";var Le=w(H=>{"use strict";d();var Me="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");H.encode=function(r){if(0<=r&&r<Me.length)return Me[r];throw new TypeError("Must be between 0 and 63: "+r)};H.decode=function(r){var e=65,n=90,t=97,o=122,i=48,u=57,l=43,s=47,a=26,c=52;return e<=r&&r<=n?r-e:t<=r&&r<=o?r-t+a:i<=r&&r<=u?r-i+c:r==l?62:r==s?63:-1}});var ne=w(re=>{"use strict";d();var Ee=Le(),ee=5,Ae=1<<ee,Oe=Ae-1,be=Ae;function nr(r){return r<0?(-r<<1)+1:(r<<1)+0}function tr(r){var e=(r&1)===1,n=r>>1;return e?-n:n}re.encode=function(e){var n="",t,o=nr(e);do t=o&Oe,o>>>=ee,o>0&&(t|=be),n+=Ee.encode(t);while(o>0);return n};re.decode=function(e,n,t){var o=e.length,i=0,u=0,l,s;do{if(n>=o)throw new Error("Expected more digits in base 64 VLQ value.");if(s=Ee.decode(e.charCodeAt(n++)),s===-1)throw new Error("Invalid base64 digit: "+e.charAt(n-1));l=!!(s&be),s&=Oe,i=i+(s<<u),u+=ee}while(l);t.value=tr(i),t.rest=n}});var F=w(y=>{"use strict";d();function or(r,e,n){if(e in r)return r[e];if(arguments.length===3)return n;throw new Error('"'+e+'" is a required argument.')}y.getArg=or;var Re=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,ir=/^data:.+\,.+$/;function U(r){var e=r.match(Re);return e?{scheme:e[1],auth:e[2],host:e[3],port:e[4],path:e[5]}:null}y.urlParse=U;function B(r){var e="";return r.scheme&&(e+=r.scheme+":"),e+="//",r.auth&&(e+=r.auth+"@"),r.host&&(e+=r.host),r.port&&(e+=":"+r.port),r.path&&(e+=r.path),e}y.urlGenerate=B;function te(r){var e=r,n=U(r);if(n){if(!n.path)return r;e=n.path}for(var t=y.isAbsolute(e),o=e.split(/\/+/),i,u=0,l=o.length-1;l>=0;l--)i=o[l],i==="."?o.splice(l,1):i===".."?u++:u>0&&(i===""?(o.splice(l+1,u),u=0):(o.splice(l,2),u--));return e=o.join("/"),e===""&&(e=t?"/":"."),n?(n.path=e,B(n)):e}y.normalize=te;function Ne(r,e){r===""&&(r="."),e===""&&(e=".");var n=U(e),t=U(r);if(t&&(r=t.path||"/"),n&&!n.scheme)return t&&(n.scheme=t.scheme),B(n);if(n||e.match(ir))return e;if(t&&!t.host&&!t.path)return t.host=e,B(t);var o=e.charAt(0)==="/"?e:te(r.replace(/\/+$/,"")+"/"+e);return t?(t.path=o,B(t)):o}y.join=Ne;y.isAbsolute=function(r){return r.charAt(0)==="/"||Re.test(r)};function ur(r,e){r===""&&(r="."),r=r.replace(/\/$/,"");for(var n=0;e.indexOf(r+"/")!==0;){var t=r.lastIndexOf("/");if(t<0||(r=r.slice(0,t),r.match(/^([^\/]+:\/)?\/*$/)))return e;++n}return Array(n+1).join("../")+e.substr(r.length+1)}y.relative=ur;var xe=(function(){var r=Object.create(null);return!("__proto__"in r)})();function Ge(r){return r}function sr(r){return Ie(r)?"$"+r:r}y.toSetString=xe?Ge:sr;function lr(r){return Ie(r)?r.slice(1):r}y.fromSetString=xe?Ge:lr;function Ie(r){if(!r)return!1;var e=r.length;if(e<9||r.charCodeAt(e-1)!==95||r.charCodeAt(e-2)!==95||r.charCodeAt(e-3)!==111||r.charCodeAt(e-4)!==116||r.charCodeAt(e-5)!==111||r.charCodeAt(e-6)!==114||r.charCodeAt(e-7)!==112||r.charCodeAt(e-8)!==95||r.charCodeAt(e-9)!==95)return!1;for(var n=e-10;n>=0;n--)if(r.charCodeAt(n)!==36)return!1;return!0}function ar(r,e,n){var t=q(r.source,e.source);return t!==0||(t=r.originalLine-e.originalLine,t!==0)||(t=r.originalColumn-e.originalColumn,t!==0||n)||(t=r.generatedColumn-e.generatedColumn,t!==0)||(t=r.generatedLine-e.generatedLine,t!==0)?t:q(r.name,e.name)}y.compareByOriginalPositions=ar;function cr(r,e,n){var t=r.generatedLine-e.generatedLine;return t!==0||(t=r.generatedColumn-e.generatedColumn,t!==0||n)||(t=q(r.source,e.source),t!==0)||(t=r.originalLine-e.originalLine,t!==0)||(t=r.originalColumn-e.originalColumn,t!==0)?t:q(r.name,e.name)}y.compareByGeneratedPositionsDeflated=cr;function q(r,e){return r===e?0:r===null?1:e===null?-1:r>e?1:-1}function fr(r,e){var n=r.generatedLine-e.generatedLine;return n!==0||(n=r.generatedColumn-e.generatedColumn,n!==0)||(n=q(r.source,e.source),n!==0)||(n=r.originalLine-e.originalLine,n!==0)||(n=r.originalColumn-e.originalColumn,n!==0)?n:q(r.name,e.name)}y.compareByGeneratedPositionsInflated=fr;function hr(r){return JSON.parse(r.replace(/^\)]}'[^\n]*\n/,""))}y.parseSourceMapInput=hr;function gr(r,e,n){if(e=e||"",r&&(r[r.length-1]!=="/"&&e[0]!=="/"&&(r+="/"),e=r+e),n){var t=U(n);if(!t)throw new Error("sourceMapURL could not be parsed");if(t.path){var o=t.path.lastIndexOf("/");o>=0&&(t.path=t.path.substring(0,o+1))}e=Ne(B(t),e)}return te(e)}y.computeSourceURL=gr});var ue=w(Te=>{"use strict";d();var oe=F(),ie=Object.prototype.hasOwnProperty,x=typeof Map<"u";function b(){this._array=[],this._set=x?new Map:Object.create(null)}b.fromArray=function(e,n){for(var t=new b,o=0,i=e.length;o<i;o++)t.add(e[o],n);return t};b.prototype.size=function(){return x?this._set.size:Object.getOwnPropertyNames(this._set).length};b.prototype.add=function(e,n){var t=x?e:oe.toSetString(e),o=x?this.has(e):ie.call(this._set,t),i=this._array.length;(!o||n)&&this._array.push(e),o||(x?this._set.set(e,i):this._set[t]=i)};b.prototype.has=function(e){if(x)return this._set.has(e);var n=oe.toSetString(e);return ie.call(this._set,n)};b.prototype.indexOf=function(e){if(x){var n=this._set.get(e);if(n>=0)return n}else{var t=oe.toSetString(e);if(ie.call(this._set,t))return this._set[t]}throw new Error('"'+e+'" is not in the set.')};b.prototype.at=function(e){if(e>=0&&e<this._array.length)return this._array[e];throw new Error("No element indexed by "+e)};b.prototype.toArray=function(){return this._array.slice()};Te.ArraySet=b});var qe=w(Be=>{"use strict";d();var Pe=F();function dr(r,e){var n=r.generatedLine,t=e.generatedLine,o=r.generatedColumn,i=e.generatedColumn;return t>n||t==n&&i>=o||Pe.compareByGeneratedPositionsInflated(r,e)<=0}function W(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}W.prototype.unsortedForEach=function(e,n){this._array.forEach(e,n)};W.prototype.add=function(e){dr(this._last,e)?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))};W.prototype.toArray=function(){return this._sorted||(this._array.sort(Pe.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};Be.MappingList=W});var se=w(Fe=>{"use strict";d();var $=ne(),_=F(),J=ue().ArraySet,vr=qe().MappingList;function E(r){r||(r={}),this._file=_.getArg(r,"file",null),this._sourceRoot=_.getArg(r,"sourceRoot",null),this._skipValidation=_.getArg(r,"skipValidation",!1),this._sources=new J,this._names=new J,this._mappings=new vr,this._sourcesContents=null}E.prototype._version=3;E.fromSourceMap=function(e){var n=e.sourceRoot,t=new E({file:e.file,sourceRoot:n});return e.eachMapping(function(o){var i={generated:{line:o.generatedLine,column:o.generatedColumn}};o.source!=null&&(i.source=o.source,n!=null&&(i.source=_.relative(n,i.source)),i.original={line:o.originalLine,column:o.originalColumn},o.name!=null&&(i.name=o.name)),t.addMapping(i)}),e.sources.forEach(function(o){var i=o;n!==null&&(i=_.relative(n,o)),t._sources.has(i)||t._sources.add(i);var u=e.sourceContentFor(o);u!=null&&t.setSourceContent(o,u)}),t};E.prototype.addMapping=function(e){var n=_.getArg(e,"generated"),t=_.getArg(e,"original",null),o=_.getArg(e,"source",null),i=_.getArg(e,"name",null);this._skipValidation||this._validateMapping(n,t,o,i),o!=null&&(o=String(o),this._sources.has(o)||this._sources.add(o)),i!=null&&(i=String(i),this._names.has(i)||this._names.add(i)),this._mappings.add({generatedLine:n.line,generatedColumn:n.column,originalLine:t!=null&&t.line,originalColumn:t!=null&&t.column,source:o,name:i})};E.prototype.setSourceContent=function(e,n){var t=e;this._sourceRoot!=null&&(t=_.relative(this._sourceRoot,t)),n!=null?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[_.toSetString(t)]=n):this._sourcesContents&&(delete this._sourcesContents[_.toSetString(t)],Object.keys(this._sourcesContents).length===0&&(this._sourcesContents=null))};E.prototype.applySourceMap=function(e,n,t){var o=n;if(n==null){if(e.file==null)throw new Error(`SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map's "file" property. Both were omitted.`);o=e.file}var i=this._sourceRoot;i!=null&&(o=_.relative(i,o));var u=new J,l=new J;this._mappings.unsortedForEach(function(s){if(s.source===o&&s.originalLine!=null){var a=e.originalPositionFor({line:s.originalLine,column:s.originalColumn});a.source!=null&&(s.source=a.source,t!=null&&(s.source=_.join(t,s.source)),i!=null&&(s.source=_.relative(i,s.source)),s.originalLine=a.line,s.originalColumn=a.column,a.name!=null&&(s.name=a.name))}var c=s.source;c!=null&&!u.has(c)&&u.add(c);var g=s.name;g!=null&&!l.has(g)&&l.add(g)},this),this._sources=u,this._names=l,e.sources.forEach(function(s){var a=e.sourceContentFor(s);a!=null&&(t!=null&&(s=_.join(t,s)),i!=null&&(s=_.relative(i,s)),this.setSourceContent(s,a))},this)};E.prototype._validateMapping=function(e,n,t,o){if(n&&typeof n.line!="number"&&typeof n.column!="number")throw new Error("original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.");if(!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0&&!n&&!t&&!o)){if(e&&"line"in e&&"column"in e&&n&&"line"in n&&"column"in n&&e.line>0&&e.column>=0&&n.line>0&&n.column>=0&&t)return;throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:t,original:n,name:o}))}};E.prototype._serializeMappings=function(){for(var e=0,n=1,t=0,o=0,i=0,u=0,l="",s,a,c,g,h=this._mappings.toArray(),v=0,L=h.length;v<L;v++){if(a=h[v],s="",a.generatedLine!==n)for(e=0;a.generatedLine!==n;)s+=";",n++;else if(v>0){if(!_.compareByGeneratedPositionsInflated(a,h[v-1]))continue;s+=","}s+=$.encode(a.generatedColumn-e),e=a.generatedColumn,a.source!=null&&(g=this._sources.indexOf(a.source),s+=$.encode(g-u),u=g,s+=$.encode(a.originalLine-1-o),o=a.originalLine-1,s+=$.encode(a.originalColumn-t),t=a.originalColumn,a.name!=null&&(c=this._names.indexOf(a.name),s+=$.encode(c-i),i=c)),l+=s}return l};E.prototype._generateSourcesContent=function(e,n){return e.map(function(t){if(!this._sourcesContents)return null;n!=null&&(t=_.relative(n,t));var o=_.toSetString(t);return Object.prototype.hasOwnProperty.call(this._sourcesContents,o)?this._sourcesContents[o]:null},this)};E.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(e.file=this._file),this._sourceRoot!=null&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e};E.prototype.toString=function(){return JSON.stringify(this.toJSON())};Fe.SourceMapGenerator=E});var je=w(G=>{"use strict";d();G.GREATEST_LOWER_BOUND=1;G.LEAST_UPPER_BOUND=2;function le(r,e,n,t,o,i){var u=Math.floor((e-r)/2)+r,l=o(n,t[u],!0);return l===0?u:l>0?e-u>1?le(u,e,n,t,o,i):i==G.LEAST_UPPER_BOUND?e<t.length?e:-1:u:u-r>1?le(r,u,n,t,o,i):i==G.LEAST_UPPER_BOUND?u:r<0?-1:r}G.search=function(e,n,t,o){if(n.length===0)return-1;var i=le(-1,n.length,e,n,t,o||G.GREATEST_LOWER_BOUND);if(i<0)return-1;for(;i-1>=0&&t(n[i],n[i-1],!0)===0;)--i;return i}});var Ue=w(De=>{"use strict";d();function ae(r,e,n){var t=r[e];r[e]=r[n],r[n]=t}function pr(r,e){return Math.round(r+Math.random()*(e-r))}function ce(r,e,n,t){if(n<t){var o=pr(n,t),i=n-1;ae(r,o,t);for(var u=r[t],l=n;l<t;l++)e(r[l],u)<=0&&(i+=1,ae(r,i,l));ae(r,i+1,l);var s=i+1;ce(r,e,n,s-1),ce(r,e,s+1,t)}}De.quickSort=function(r,e){ce(r,e,0,r.length-1)}});var ke=w(X=>{"use strict";d();var f=F(),fe=je(),j=ue().ArraySet,_r=ne(),k=Ue().quickSort;function p(r,e){var n=r;return typeof r=="string"&&(n=f.parseSourceMapInput(r)),n.sections!=null?new A(n,e):new m(n,e)}p.fromSourceMap=function(r,e){return m.fromSourceMap(r,e)};p.prototype._version=3;p.prototype.__generatedMappings=null;Object.defineProperty(p.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}});p.prototype.__originalMappings=null;Object.defineProperty(p.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}});p.prototype._charIsMappingSeparator=function(e,n){var t=e.charAt(n);return t===";"||t===","};p.prototype._parseMappings=function(e,n){throw new Error("Subclasses must implement _parseMappings")};p.GENERATED_ORDER=1;p.ORIGINAL_ORDER=2;p.GREATEST_LOWER_BOUND=1;p.LEAST_UPPER_BOUND=2;p.prototype.eachMapping=function(e,n,t){var o=n||null,i=t||p.GENERATED_ORDER,u;switch(i){case p.GENERATED_ORDER:u=this._generatedMappings;break;case p.ORIGINAL_ORDER:u=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}var l=this.sourceRoot;u.map(function(s){var a=s.source===null?null:this._sources.at(s.source);return a=f.computeSourceURL(l,a,this._sourceMapURL),{source:a,generatedLine:s.generatedLine,generatedColumn:s.generatedColumn,originalLine:s.originalLine,originalColumn:s.originalColumn,name:s.name===null?null:this._names.at(s.name)}},this).forEach(e,o)};p.prototype.allGeneratedPositionsFor=function(e){var n=f.getArg(e,"line"),t={source:f.getArg(e,"source"),originalLine:n,originalColumn:f.getArg(e,"column",0)};if(t.source=this._findSourceIndex(t.source),t.source<0)return[];var o=[],i=this._findMapping(t,this._originalMappings,"originalLine","originalColumn",f.compareByOriginalPositions,fe.LEAST_UPPER_BOUND);if(i>=0){var u=this._originalMappings[i];if(e.column===void 0)for(var l=u.originalLine;u&&u.originalLine===l;)o.push({line:f.getArg(u,"generatedLine",null),column:f.getArg(u,"generatedColumn",null),lastColumn:f.getArg(u,"lastGeneratedColumn",null)}),u=this._originalMappings[++i];else for(var s=u.originalColumn;u&&u.originalLine===n&&u.originalColumn==s;)o.push({line:f.getArg(u,"generatedLine",null),column:f.getArg(u,"generatedColumn",null),lastColumn:f.getArg(u,"lastGeneratedColumn",null)}),u=this._originalMappings[++i]}return o};X.SourceMapConsumer=p;function m(r,e){var n=r;typeof r=="string"&&(n=f.parseSourceMapInput(r));var t=f.getArg(n,"version"),o=f.getArg(n,"sources"),i=f.getArg(n,"names",[]),u=f.getArg(n,"sourceRoot",null),l=f.getArg(n,"sourcesContent",null),s=f.getArg(n,"mappings"),a=f.getArg(n,"file",null);if(t!=this._version)throw new Error("Unsupported version: "+t);u&&(u=f.normalize(u)),o=o.map(String).map(f.normalize).map(function(c){return u&&f.isAbsolute(u)&&f.isAbsolute(c)?f.relative(u,c):c}),this._names=j.fromArray(i.map(String),!0),this._sources=j.fromArray(o,!0),this._absoluteSources=this._sources.toArray().map(function(c){return f.computeSourceURL(u,c,e)}),this.sourceRoot=u,this.sourcesContent=l,this._mappings=s,this._sourceMapURL=e,this.file=a}m.prototype=Object.create(p.prototype);m.prototype.consumer=p;m.prototype._findSourceIndex=function(r){var e=r;if(this.sourceRoot!=null&&(e=f.relative(this.sourceRoot,e)),this._sources.has(e))return this._sources.indexOf(e);var n;for(n=0;n<this._absoluteSources.length;++n)if(this._absoluteSources[n]==r)return n;return-1};m.fromSourceMap=function(e,n){var t=Object.create(m.prototype),o=t._names=j.fromArray(e._names.toArray(),!0),i=t._sources=j.fromArray(e._sources.toArray(),!0);t.sourceRoot=e._sourceRoot,t.sourcesContent=e._generateSourcesContent(t._sources.toArray(),t.sourceRoot),t.file=e._file,t._sourceMapURL=n,t._absoluteSources=t._sources.toArray().map(function(v){return f.computeSourceURL(t.sourceRoot,v,n)});for(var u=e._mappings.toArray().slice(),l=t.__generatedMappings=[],s=t.__originalMappings=[],a=0,c=u.length;a<c;a++){var g=u[a],h=new $e;h.generatedLine=g.generatedLine,h.generatedColumn=g.generatedColumn,g.source&&(h.source=i.indexOf(g.source),h.originalLine=g.originalLine,h.originalColumn=g.originalColumn,g.name&&(h.name=o.indexOf(g.name)),s.push(h)),l.push(h)}return k(t.__originalMappings,f.compareByOriginalPositions),t};m.prototype._version=3;Object.defineProperty(m.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});function $e(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}m.prototype._parseMappings=function(e,n){for(var t=1,o=0,i=0,u=0,l=0,s=0,a=e.length,c=0,g={},h={},v=[],L=[],C,V,S,P,Ce;c<a;)if(e.charAt(c)===";")t++,c++,o=0;else if(e.charAt(c)===",")c++;else{for(C=new $e,C.generatedLine=t,P=c;P<a&&!this._charIsMappingSeparator(e,P);P++);if(V=e.slice(c,P),S=g[V],S)c+=V.length;else{for(S=[];c<P;)_r.decode(e,c,h),Ce=h.value,c=h.rest,S.push(Ce);if(S.length===2)throw new Error("Found a source, but no line and column");if(S.length===3)throw new Error("Found a source and line, but no column");g[V]=S}C.generatedColumn=o+S[0],o=C.generatedColumn,S.length>1&&(C.source=l+S[1],l+=S[1],C.originalLine=i+S[2],i=C.originalLine,C.originalLine+=1,C.originalColumn=u+S[3],u=C.originalColumn,S.length>4&&(C.name=s+S[4],s+=S[4])),L.push(C),typeof C.originalLine=="number"&&v.push(C)}k(L,f.compareByGeneratedPositionsDeflated),this.__generatedMappings=L,k(v,f.compareByOriginalPositions),this.__originalMappings=v};m.prototype._findMapping=function(e,n,t,o,i,u){if(e[t]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[t]);if(e[o]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[o]);return fe.search(e,n,i,u)};m.prototype.computeColumnSpans=function(){for(var e=0;e<this._generatedMappings.length;++e){var n=this._generatedMappings[e];if(e+1<this._generatedMappings.length){var t=this._generatedMappings[e+1];if(n.generatedLine===t.generatedLine){n.lastGeneratedColumn=t.generatedColumn-1;continue}}n.lastGeneratedColumn=1/0}};m.prototype.originalPositionFor=function(e){var n={generatedLine:f.getArg(e,"line"),generatedColumn:f.getArg(e,"column")},t=this._findMapping(n,this._generatedMappings,"generatedLine","generatedColumn",f.compareByGeneratedPositionsDeflated,f.getArg(e,"bias",p.GREATEST_LOWER_BOUND));if(t>=0){var o=this._generatedMappings[t];if(o.generatedLine===n.generatedLine){var i=f.getArg(o,"source",null);i!==null&&(i=this._sources.at(i),i=f.computeSourceURL(this.sourceRoot,i,this._sourceMapURL));var u=f.getArg(o,"name",null);return u!==null&&(u=this._names.at(u)),{source:i,line:f.getArg(o,"originalLine",null),column:f.getArg(o,"originalColumn",null),name:u}}}return{source:null,line:null,column:null,name:null}};m.prototype.hasContentsOfAllSources=function(){return this.sourcesContent?this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(e){return e==null}):!1};m.prototype.sourceContentFor=function(e,n){if(!this.sourcesContent)return null;var t=this._findSourceIndex(e);if(t>=0)return this.sourcesContent[t];var o=e;this.sourceRoot!=null&&(o=f.relative(this.sourceRoot,o));var i;if(this.sourceRoot!=null&&(i=f.urlParse(this.sourceRoot))){var u=o.replace(/^file:\/\//,"");if(i.scheme=="file"&&this._sources.has(u))return this.sourcesContent[this._sources.indexOf(u)];if((!i.path||i.path=="/")&&this._sources.has("/"+o))return this.sourcesContent[this._sources.indexOf("/"+o)]}if(n)return null;throw new Error('"'+o+'" is not in the SourceMap.')};m.prototype.generatedPositionFor=function(e){var n=f.getArg(e,"source");if(n=this._findSourceIndex(n),n<0)return{line:null,column:null,lastColumn:null};var t={source:n,originalLine:f.getArg(e,"line"),originalColumn:f.getArg(e,"column")},o=this._findMapping(t,this._originalMappings,"originalLine","originalColumn",f.compareByOriginalPositions,f.getArg(e,"bias",p.GREATEST_LOWER_BOUND));if(o>=0){var i=this._originalMappings[o];if(i.source===t.source)return{line:f.getArg(i,"generatedLine",null),column:f.getArg(i,"generatedColumn",null),lastColumn:f.getArg(i,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}};X.BasicSourceMapConsumer=m;function A(r,e){var n=r;typeof r=="string"&&(n=f.parseSourceMapInput(r));var t=f.getArg(n,"version"),o=f.getArg(n,"sections");if(t!=this._version)throw new Error("Unsupported version: "+t);this._sources=new j,this._names=new j;var i={line:-1,column:0};this._sections=o.map(function(u){if(u.url)throw new Error("Support for url field in sections not implemented.");var l=f.getArg(u,"offset"),s=f.getArg(l,"line"),a=f.getArg(l,"column");if(s<i.line||s===i.line&&a<i.column)throw new Error("Section offsets must be ordered and non-overlapping.");return i=l,{generatedOffset:{generatedLine:s+1,generatedColumn:a+1},consumer:new p(f.getArg(u,"map"),e)}})}A.prototype=Object.create(p.prototype);A.prototype.constructor=p;A.prototype._version=3;Object.defineProperty(A.prototype,"sources",{get:function(){for(var r=[],e=0;e<this._sections.length;e++)for(var n=0;n<this._sections[e].consumer.sources.length;n++)r.push(this._sections[e].consumer.sources[n]);return r}});A.prototype.originalPositionFor=function(e){var n={generatedLine:f.getArg(e,"line"),generatedColumn:f.getArg(e,"column")},t=fe.search(n,this._sections,function(i,u){var l=i.generatedLine-u.generatedOffset.generatedLine;return l||i.generatedColumn-u.generatedOffset.generatedColumn}),o=this._sections[t];return o?o.consumer.originalPositionFor({line:n.generatedLine-(o.generatedOffset.generatedLine-1),column:n.generatedColumn-(o.generatedOffset.generatedLine===n.generatedLine?o.generatedOffset.generatedColumn-1:0),bias:e.bias}):{source:null,line:null,column:null,name:null}};A.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(e){return e.consumer.hasContentsOfAllSources()})};A.prototype.sourceContentFor=function(e,n){for(var t=0;t<this._sections.length;t++){var o=this._sections[t],i=o.consumer.sourceContentFor(e,!0);if(i)return i}if(n)return null;throw new Error('"'+e+'" is not in the SourceMap.')};A.prototype.generatedPositionFor=function(e){for(var n=0;n<this._sections.length;n++){var t=this._sections[n];if(t.consumer._findSourceIndex(f.getArg(e,"source"))!==-1){var o=t.consumer.generatedPositionFor(e);if(o){var i={line:o.line+(t.generatedOffset.generatedLine-1),column:o.column+(t.generatedOffset.generatedLine===o.line?t.generatedOffset.generatedColumn-1:0)};return i}}}return{line:null,column:null}};A.prototype._parseMappings=function(e,n){this.__generatedMappings=[],this.__originalMappings=[];for(var t=0;t<this._sections.length;t++)for(var o=this._sections[t],i=o.consumer._generatedMappings,u=0;u<i.length;u++){var l=i[u],s=o.consumer._sources.at(l.source);s=f.computeSourceURL(o.consumer.sourceRoot,s,this._sourceMapURL),this._sources.add(s),s=this._sources.indexOf(s);var a=null;l.name&&(a=o.consumer._names.at(l.name),this._names.add(a),a=this._names.indexOf(a));var c={source:s,generatedLine:l.generatedLine+(o.generatedOffset.generatedLine-1),generatedColumn:l.generatedColumn+(o.generatedOffset.generatedLine===l.generatedLine?o.generatedOffset.generatedColumn-1:0),originalLine:l.originalLine,originalColumn:l.originalColumn,name:a};this.__generatedMappings.push(c),typeof c.originalLine=="number"&&this.__originalMappings.push(c)}k(this.__generatedMappings,f.compareByGeneratedPositionsDeflated),k(this.__originalMappings,f.compareByOriginalPositions)};X.IndexedSourceMapConsumer=A});var Qe=w(ze=>{"use strict";d();var mr=se().SourceMapGenerator,Z=F(),Sr=/(\r?\n)/,yr=10,D="$$$isSourceNode$$$";function M(r,e,n,t,o){this.children=[],this.sourceContents={},this.line=r??null,this.column=e??null,this.source=n??null,this.name=o??null,this[D]=!0,t!=null&&this.add(t)}M.fromStringWithSourceMap=function(e,n,t){var o=new M,i=e.split(Sr),u=0,l=function(){var h=L(),v=L()||"";return h+v;function L(){return u<i.length?i[u++]:void 0}},s=1,a=0,c=null;return n.eachMapping(function(h){if(c!==null)if(s<h.generatedLine)g(c,l()),s++,a=0;else{var v=i[u]||"",L=v.substr(0,h.generatedColumn-a);i[u]=v.substr(h.generatedColumn-a),a=h.generatedColumn,g(c,L),c=h;return}for(;s<h.generatedLine;)o.add(l()),s++;if(a<h.generatedColumn){var v=i[u]||"";o.add(v.substr(0,h.generatedColumn)),i[u]=v.substr(h.generatedColumn),a=h.generatedColumn}c=h},this),u<i.length&&(c&&g(c,l()),o.add(i.splice(u).join(""))),n.sources.forEach(function(h){var v=n.sourceContentFor(h);v!=null&&(t!=null&&(h=Z.join(t,h)),o.setSourceContent(h,v))}),o;function g(h,v){if(h===null||h.source===void 0)o.add(v);else{var L=t?Z.join(t,h.source):h.source;o.add(new M(h.originalLine,h.originalColumn,L,v,h.name))}}};M.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(n){this.add(n)},this);else if(e[D]||typeof e=="string")e&&this.children.push(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};M.prototype.prepend=function(e){if(Array.isArray(e))for(var n=e.length-1;n>=0;n--)this.prepend(e[n]);else if(e[D]||typeof e=="string")this.children.unshift(e);else throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);return this};M.prototype.walk=function(e){for(var n,t=0,o=this.children.length;t<o;t++)n=this.children[t],n[D]?n.walk(e):n!==""&&e(n,{source:this.source,line:this.line,column:this.column,name:this.name})};M.prototype.join=function(e){var n,t,o=this.children.length;if(o>0){for(n=[],t=0;t<o-1;t++)n.push(this.children[t]),n.push(e);n.push(this.children[t]),this.children=n}return this};M.prototype.replaceRight=function(e,n){var t=this.children[this.children.length-1];return t[D]?t.replaceRight(e,n):typeof t=="string"?this.children[this.children.length-1]=t.replace(e,n):this.children.push("".replace(e,n)),this};M.prototype.setSourceContent=function(e,n){this.sourceContents[Z.toSetString(e)]=n};M.prototype.walkSourceContents=function(e){for(var n=0,t=this.children.length;n<t;n++)this.children[n][D]&&this.children[n].walkSourceContents(e);for(var o=Object.keys(this.sourceContents),n=0,t=o.length;n<t;n++)e(Z.fromSetString(o[n]),this.sourceContents[o[n]])};M.prototype.toString=function(){var e="";return this.walk(function(n){e+=n}),e};M.prototype.toStringWithSourceMap=function(e){var n={code:"",line:1,column:0},t=new mr(e),o=!1,i=null,u=null,l=null,s=null;return this.walk(function(a,c){n.code+=a,c.source!==null&&c.line!==null&&c.column!==null?((i!==c.source||u!==c.line||l!==c.column||s!==c.name)&&t.addMapping({source:c.source,original:{line:c.line,column:c.column},generated:{line:n.line,column:n.column},name:c.name}),i=c.source,u=c.line,l=c.column,s=c.name,o=!0):o&&(t.addMapping({generated:{line:n.line,column:n.column}}),i=null,o=!1);for(var g=0,h=a.length;g<h;g++)a.charCodeAt(g)===yr?(n.line++,n.column=0,g+1===h?(i=null,o=!1):o&&t.addMapping({source:c.source,original:{line:c.line,column:c.column},generated:{line:n.line,column:n.column},name:c.name})):n.column++}),this.walkSourceContents(function(a,c){t.setSourceContent(a,c)}),{code:n.code,map:t}};ze.SourceNode=M});var Ve=w(K=>{"use strict";d();K.SourceMapGenerator=se().SourceMapGenerator;K.SourceMapConsumer=ke().SourceMapConsumer;K.SourceNode=Qe().SourceNode});var Je=w((cn,We)=>{"use strict";d();var Cr=Object.prototype.toString,he=typeof Buffer<"u"&&typeof Buffer.alloc=="function"&&typeof Buffer.allocUnsafe=="function"&&typeof Buffer.from=="function";function wr(r){return Cr.call(r).slice(8,-1)==="ArrayBuffer"}function Mr(r,e,n){e>>>=0;var t=r.byteLength-e;if(t<0)throw new RangeError("'offset' is out of bounds");if(n===void 0)n=t;else if(n>>>=0,n>t)throw new RangeError("'length' is out of bounds");return he?Buffer.from(r.slice(e,e+n)):new Buffer(new Uint8Array(r.slice(e,e+n)))}function Lr(r,e){if((typeof e!="string"||e==="")&&(e="utf8"),!Buffer.isEncoding(e))throw new TypeError('"encoding" must be a valid string encoding');return he?Buffer.from(r,e):new Buffer(r,e)}function Er(r,e,n){if(typeof r=="number")throw new TypeError('"value" argument must not be a number');return wr(r)?Mr(r,e,n):typeof r=="string"?Lr(r,e):he?Buffer.from(r):new Buffer(r)}We.exports=Er});var Dr=w((T,pe)=>{"use strict";d();var Ar=Ve().SourceMapConsumer,ge=we("path"),O;try{O=we("fs"),(!O.existsSync||!O.readFileSync)&&(O=null)}catch{}var Or=Je();function Xe(r,e){return r.require(e)}var Ze=!1,Ke=!1,de=!1,z="auto",I={},Q={},br=/^data:application\/json[^,]+base64,/,R=[],N=[];function _e(){return z==="browser"?!0:z==="node"?!1:typeof window<"u"&&typeof XMLHttpRequest=="function"&&!(window.require&&window.module&&window.process&&window.process.type==="renderer")}function Rr(){return typeof process=="object"&&process!==null&&typeof process.on=="function"}function Nr(){return typeof process=="object"&&process!==null?process.version:""}function xr(){if(typeof process=="object"&&process!==null)return process.stderr}function Gr(r){if(typeof process=="object"&&process!==null&&typeof process.exit=="function")return process.exit(r)}function Y(r){return function(e){for(var n=0;n<r.length;n++){var t=r[n](e);if(t)return t}return null}}var me=Y(R);R.push(function(r){if(r=r.trim(),/^file:/.test(r)&&(r=r.replace(/file:\/\/\/(\w:)?/,function(t,o){return o?"":"/"})),r in I)return I[r];var e="";try{if(O)O.existsSync(r)&&(e=O.readFileSync(r,"utf8"));else{var n=new XMLHttpRequest;n.open("GET",r,!1),n.send(null),n.readyState===4&&n.status===200&&(e=n.responseText)}}catch{}return I[r]=e});function ve(r,e){if(!r)return e;var n=ge.dirname(r),t=/^\w+:\/\/[^\/]*/.exec(n),o=t?t[0]:"",i=n.slice(o.length);return o&&/^\/\w\:/.test(i)?(o+="/",o+ge.resolve(n.slice(o.length),e).replace(/\\/g,"/")):o+ge.resolve(n.slice(o.length),e)}function Ir(r){var e;if(_e())try{var n=new XMLHttpRequest;n.open("GET",r,!1),n.send(null),e=n.readyState===4?n.responseText:null;var t=n.getResponseHeader("SourceMap")||n.getResponseHeader("X-SourceMap");if(t)return t}catch{}e=me(r);for(var o=/(?:\/\/[@#][\s]*sourceMappingURL=([^\s'"]+)[\s]*$)|(?:\/\*[@#][\s]*sourceMappingURL=([^\s*'"]+)[\s]*(?:\*\/)[\s]*$)/mg,i,u;u=o.exec(e);)i=u;return i?i[1]:null}var Se=Y(N);N.push(function(r){var e=Ir(r);if(!e)return null;var n;if(br.test(e)){var t=e.slice(e.indexOf(",")+1);n=Or(t,"base64").toString(),e=r}else e=ve(r,e),n=me(e);return n?{url:e,map:n}:null});function ye(r){var e=Q[r.source];if(!e){var n=Se(r.source);n?(e=Q[r.source]={url:n.url,map:new Ar(n.map)},e.map.sourcesContent&&e.map.sources.forEach(function(o,i){var u=e.map.sourcesContent[i];if(u){var l=ve(e.url,o);I[l]=u}})):e=Q[r.source]={url:null,map:null}}if(e&&e.map&&typeof e.map.originalPositionFor=="function"){var t=e.map.originalPositionFor(r);if(t.source!==null)return t.source=ve(e.url,t.source),t}return r}function He(r){var e=/^eval at ([^(]+) \((.+):(\d+):(\d+)\)$/.exec(r);if(e){var n=ye({source:e[2],line:+e[3],column:e[4]-1});return"eval at "+e[1]+" ("+n.source+":"+n.line+":"+(n.column+1)+")"}return e=/^eval at ([^(]+) \((.+)\)$/.exec(r),e?"eval at "+e[1]+" ("+He(e[2])+")":r}function Tr(){var r,e="";if(this.isNative())e="native";else{r=this.getScriptNameOrSourceURL(),!r&&this.isEval()&&(e=this.getEvalOrigin(),e+=", "),r?e+=r:e+="<anonymous>";var n=this.getLineNumber();if(n!=null){e+=":"+n;var t=this.getColumnNumber();t&&(e+=":"+t)}}var o="",i=this.getFunctionName(),u=!0,l=this.isConstructor(),s=!(this.isToplevel()||l);if(s){var a=this.getTypeName();a==="[object Object]"&&(a="null");var c=this.getMethodName();i?(a&&i.indexOf(a)!=0&&(o+=a+"."),o+=i,c&&i.indexOf("."+c)!=i.length-c.length-1&&(o+=" [as "+c+"]")):o+=a+"."+(c||"<anonymous>")}else l?o+="new "+(i||"<anonymous>"):i?o+=i:(o+=e,u=!1);return u&&(o+=" ("+e+")"),o}function Ye(r){var e={};return Object.getOwnPropertyNames(Object.getPrototypeOf(r)).forEach(function(n){e[n]=/^(?:is|get)/.test(n)?function(){return r[n].call(r)}:r[n]}),e.toString=Tr,e}function er(r,e){if(e===void 0&&(e={nextPosition:null,curPosition:null}),r.isNative())return e.curPosition=null,r;var n=r.getFileName()||r.getScriptNameOrSourceURL();if(n){var t=r.getLineNumber(),o=r.getColumnNumber()-1,i=/^v(10\.1[6-9]|10\.[2-9][0-9]|10\.[0-9]{3,}|1[2-9]\d*|[2-9]\d|\d{3,}|11\.11)/,u=i.test(Nr())?0:62;t===1&&o>u&&!_e()&&!r.isEval()&&(o-=u);var l=ye({source:n,line:t,column:o});e.curPosition=l,r=Ye(r);var s=r.getFunctionName;return r.getFunctionName=function(){return e.nextPosition==null?s():e.nextPosition.name||s()},r.getFileName=function(){return l.source},r.getLineNumber=function(){return l.line},r.getColumnNumber=function(){return l.column+1},r.getScriptNameOrSourceURL=function(){return l.source},r}var a=r.isEval()&&r.getEvalOrigin();return a&&(a=He(a),r=Ye(r),r.getEvalOrigin=function(){return a}),r}function Pr(r,e){de&&(I={},Q={});for(var n=r.name||"Error",t=r.message||"",o=n+": "+t,i={nextPosition:null,curPosition:null},u=[],l=e.length-1;l>=0;l--)u.push(`
|
|
3
|
-
at `+er(e[l],i)),i.nextPosition=i.curPosition;return i.curPosition=i.nextPosition=null,o+u.reverse().join("")}function rr(r){var e=/\n at [^(]+ \((.*):(\d+):(\d+)\)/.exec(r.stack);if(e){var n=e[1],t=+e[2],o=+e[3],i=I[n];if(!i&&O&&O.existsSync(n))try{i=O.readFileSync(n,"utf8")}catch{i=""}if(i){var u=i.split(/(?:\r\n|\r|\n)/)[t-1];if(u)return n+":"+t+`
|
|
4
|
-
`+u+`
|
|
5
|
-
`+new Array(o).join(" ")+"^"}}return null}function Br(r){var e=rr(r),n=xr();n&&n._handle&&n._handle.setBlocking&&n._handle.setBlocking(!0),e&&(console.error(),console.error(e)),console.error(r.stack),Gr(1)}function qr(){var r=process.emit;process.emit=function(e){if(e==="uncaughtException"){var n=arguments[1]&&arguments[1].stack,t=this.listeners(e).length>0;if(n&&!t)return Br(arguments[1])}return r.apply(this,arguments)}}var Fr=R.slice(0),jr=N.slice(0);T.wrapCallSite=er;T.getErrorSource=rr;T.mapSourcePosition=ye;T.retrieveSourceMap=Se;T.install=function(r){if(r=r||{},r.environment&&(z=r.environment,["node","browser","auto"].indexOf(z)===-1))throw new Error("environment "+z+" was unknown. Available options are {auto, browser, node}");if(r.retrieveFile&&(r.overrideRetrieveFile&&(R.length=0),R.unshift(r.retrieveFile)),r.retrieveSourceMap&&(r.overrideRetrieveSourceMap&&(N.length=0),N.unshift(r.retrieveSourceMap)),r.hookRequire&&!_e()){var e=Xe(pe,"module"),n=e.prototype._compile;n.__sourceMapSupport||(e.prototype._compile=function(i,u){return I[u]=i,Q[u]=void 0,n.call(this,i,u)},e.prototype._compile.__sourceMapSupport=!0)}if(de||(de="emptyCacheBetweenOperations"in r?r.emptyCacheBetweenOperations:!1),Ze||(Ze=!0,Error.prepareStackTrace=Pr),!Ke){var t="handleUncaughtExceptions"in r?r.handleUncaughtExceptions:!0;try{var o=Xe(pe,"worker_threads");o.isMainThread===!1&&(t=!1)}catch{}t&&Rr()&&(Ke=!0,qr())}};T.resetRetrieveHandlers=function(){R.length=0,N.length=0,R=Fr.slice(0),N=jr.slice(0),Se=Y(N),me=Y(R)}});export{Je as a,Dr as b};
|