@techdocs/cli 1.4.1-next.3 → 1.4.2-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +23 -0
- package/dist/embedded-app/.config-schema.json +52 -0
- package/dist/embedded-app/index.html +1 -1
- package/dist/embedded-app/static/{1032.94c986d1.chunk.js → 1032.8b636047.chunk.js} +2 -2
- package/dist/embedded-app/static/{1032.94c986d1.chunk.js.map → 1032.8b636047.chunk.js.map} +1 -1
- package/dist/embedded-app/static/1049.dd1f0d99.chunk.js +7 -0
- package/dist/embedded-app/static/1049.dd1f0d99.chunk.js.map +1 -0
- package/dist/embedded-app/static/{1105.facb65a8.chunk.js → 1105.82a0fd7f.chunk.js} +2 -2
- package/dist/embedded-app/static/{1105.facb65a8.chunk.js.map → 1105.82a0fd7f.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{184.c1c44877.chunk.js → 184.44692312.chunk.js} +2 -2
- package/dist/embedded-app/static/{184.c1c44877.chunk.js.map → 184.44692312.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{2440.e147b5dc.chunk.js → 2440.5e8d7e92.chunk.js} +2 -2
- package/dist/embedded-app/static/{2440.e147b5dc.chunk.js.map → 2440.5e8d7e92.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{5458.742cd271.chunk.js → 5458.b84b2f47.chunk.js} +2 -2
- package/dist/embedded-app/static/{5458.742cd271.chunk.js.map → 5458.b84b2f47.chunk.js.map} +1 -1
- package/dist/embedded-app/static/6051.56a76749.chunk.js +4 -0
- package/dist/embedded-app/static/6051.56a76749.chunk.js.map +1 -0
- package/dist/embedded-app/static/{732.b2dac5c3.chunk.js → 732.1e19510d.chunk.js} +2 -2
- package/dist/embedded-app/static/{732.b2dac5c3.chunk.js.map → 732.1e19510d.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{7560.4cfb6ad7.chunk.js → 7560.785ca5bd.chunk.js} +2 -2
- package/dist/embedded-app/static/{7560.4cfb6ad7.chunk.js.map → 7560.785ca5bd.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{7670.d2126c9e.chunk.js → 7670.ae73207b.chunk.js} +2 -2
- package/dist/embedded-app/static/{7670.d2126c9e.chunk.js.map → 7670.ae73207b.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{7750.7cd64666.chunk.js → 7750.7eb92a3e.chunk.js} +2 -2
- package/dist/embedded-app/static/{7750.7cd64666.chunk.js.map → 7750.7eb92a3e.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{8951.dd51135b.chunk.js → 8951.ad64462a.chunk.js} +2 -2
- package/dist/embedded-app/static/{8951.dd51135b.chunk.js.map → 8951.ad64462a.chunk.js.map} +1 -1
- package/dist/embedded-app/static/9323.b8f35b31.chunk.js +3 -0
- package/dist/embedded-app/static/9323.b8f35b31.chunk.js.map +1 -0
- package/dist/embedded-app/static/{9545.fab4c42c.chunk.js → 9545.262ef793.chunk.js} +2 -2
- package/dist/embedded-app/static/{9545.fab4c42c.chunk.js.map → 9545.262ef793.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{9770.b5b411d2.chunk.js → 9770.86ef0a38.chunk.js} +2 -2
- package/dist/embedded-app/static/{9770.b5b411d2.chunk.js.map → 9770.86ef0a38.chunk.js.map} +1 -1
- package/dist/embedded-app/static/main.8fd0fc33.js +508 -0
- package/dist/embedded-app/static/main.8fd0fc33.js.map +1 -0
- package/dist/embedded-app/static/module-luxon.ee277e4b.js +3 -0
- package/dist/embedded-app/static/module-luxon.ee277e4b.js.map +1 -0
- package/dist/embedded-app/static/{module-material-ui.1f3c23cb.js → module-material-ui.821488a0.js} +1 -1
- package/dist/embedded-app/static/{module-material-ui.1f3c23cb.js.map → module-material-ui.821488a0.js.map} +1 -1
- package/dist/embedded-app/static/{module-yaml.feabae04.js → module-yaml.639cc746.js} +8 -8
- package/dist/embedded-app/static/module-yaml.639cc746.js.map +1 -0
- package/dist/embedded-app/static/{runtime.0f1c16cc.js → runtime.8fd0fc33.js} +2 -2
- package/dist/embedded-app/static/{runtime.0f1c16cc.js.map → runtime.8fd0fc33.js.map} +1 -1
- package/dist/embedded-app/static/{vendor.0f1c16cc.js → vendor.8fd0fc33.js} +44 -44
- package/dist/embedded-app/static/vendor.8fd0fc33.js.map +1 -0
- package/dist/index.cjs.js +1 -1
- package/package.json +5 -5
- package/dist/embedded-app/static/6051.bd9f4d48.chunk.js +0 -4
- package/dist/embedded-app/static/6051.bd9f4d48.chunk.js.map +0 -1
- package/dist/embedded-app/static/6174.55ddb654.chunk.js +0 -3
- package/dist/embedded-app/static/6174.55ddb654.chunk.js.map +0 -1
- package/dist/embedded-app/static/9323.0aa3540d.chunk.js +0 -3
- package/dist/embedded-app/static/9323.0aa3540d.chunk.js.map +0 -1
- package/dist/embedded-app/static/main.0f1c16cc.js +0 -508
- package/dist/embedded-app/static/main.0f1c16cc.js.map +0 -1
- package/dist/embedded-app/static/module-luxon.f096b58d.js +0 -3
- package/dist/embedded-app/static/module-luxon.f096b58d.js.map +0 -1
- package/dist/embedded-app/static/module-yaml.feabae04.js.map +0 -1
- package/dist/embedded-app/static/vendor.0f1c16cc.js.map +0 -1
|
@@ -8,13 +8,13 @@
|
|
|
8
8
|
`&&N!==" "&&(h=d)}if(d>=f)if(h)c.push(h),f=h+a,h=void 0;else if(t===Be){for(;p===" "||p===" ";)p=S,S=s[d+=1],g=!0;const N=d>w+1?d-2:m-1;if(u[N])return s;c.push(N),u[N]=!0,f=N+a,h=void 0}else g=!0}p=S}if(g&&l&&l(),c.length===0)return s;o&&o();let y=s.slice(0,c[0]);for(let S=0;S<c.length;++S){const N=c[S],k=c[S+1]||s.length;N===0?y=`
|
|
9
9
|
${e}${s.slice(0,k)}`:(t===Be&&u[N]&&(y+=`${s[N]}\\`),y+=`
|
|
10
10
|
${e}${s.slice(N+1,k)}`)}return y}function Ft(s,e){let t=s[e+1];for(;t===" "||t===" ";){do t=s[e+=1];while(t&&t!==`
|
|
11
|
-
`);t=s[e+1]}return e}const Pe=s=>({indentAtStart:s.indentAtStart,lineWidth:s.options.lineWidth,minContentWidth:s.options.minContentWidth}),je=s=>/^(%|---|\.\.\.)/m.test(s);function Us(s,e,t){if(!e||e<0)return!1;const n=e-t,i=s.length;if(i<=n)return!1;for(let r=0,o=0;r<i;++r)if(s[r]===`
|
|
11
|
+
`);t=s[e+1]}return e}const Pe=(s,e)=>({indentAtStart:e?s.indent.length:s.indentAtStart,lineWidth:s.options.lineWidth,minContentWidth:s.options.minContentWidth}),je=s=>/^(%|---|\.\.\.)/m.test(s);function Us(s,e,t){if(!e||e<0)return!1;const n=e-t,i=s.length;if(i<=n)return!1;for(let r=0,o=0;r<i;++r)if(s[r]===`
|
|
12
12
|
`){if(r-o>n)return!0;if(o=r+1,i-o<=n)return!1}return!0}function we(s,e){const t=JSON.stringify(s);if(e.options.doubleQuotedAsJSON)return t;const{implicitKey:n}=e,i=e.options.doubleQuotedMinMultiLineLength,r=e.indent||(je(s)?" ":"");let o="",l=0;for(let a=0,c=t[a];c;c=t[++a])if(c===" "&&t[a+1]==="\\"&&t[a+2]==="n"&&(o+=t.slice(l,a)+"\\ ",a+=1,l=a,c="\\"),c==="\\")switch(t[a+1]){case"u":{o+=t.slice(l,a);const u=t.substr(a+2,4);switch(u){case"0000":o+="\\0";break;case"0007":o+="\\a";break;case"000b":o+="\\v";break;case"001b":o+="\\e";break;case"0085":o+="\\N";break;case"00a0":o+="\\_";break;case"2028":o+="\\L";break;case"2029":o+="\\P";break;default:u.substr(0,2)==="00"?o+="\\x"+u.substr(2):o+=t.substr(a,6)}a+=5,l=a+1}break;case"n":if(n||t[a+2]==='"'||t.length<i)a+=1;else{for(o+=t.slice(l,a)+`
|
|
13
13
|
|
|
14
14
|
`;t[a+2]==="\\"&&t[a+3]==="n"&&t[a+4]!=='"';)o+=`
|
|
15
|
-
`,a+=2;o+=r,t[a+2]===" "&&(o+="\\"),a+=1,l=a+1}break;default:a+=1}return o=l?o+t.slice(l):t,n?o:Me(o,r,Be,Pe(e))}function ot(s,e){if(e.options.singleQuote===!1||e.implicitKey&&s.includes(`
|
|
15
|
+
`,a+=2;o+=r,t[a+2]===" "&&(o+="\\"),a+=1,l=a+1}break;default:a+=1}return o=l?o+t.slice(l):t,n?o:Me(o,r,Be,Pe(e,!1))}function ot(s,e){if(e.options.singleQuote===!1||e.implicitKey&&s.includes(`
|
|
16
16
|
`)||/[ \t]\n|\n[ \t]/.test(s))return we(s,e);const t=e.indent||(je(s)?" ":""),n="'"+s.replace(/'/g,"''").replace(/\n+/g,`$&
|
|
17
|
-
${t}`)+"'";return e.implicitKey?n:Me(n,t,qt,Pe(e))}function le(s,e){const{singleQuote:t}=e.options;let n;if(t===!1)n=we;else{const i=s.includes('"'),r=s.includes("'");i&&!r?n=ot:r&&!i?n=we:n=t?ot:we}return n(s,e)}function De({comment:s,type:e,value:t},n,i,r){const{blockQuote:o,commentString:l,lineWidth:a}=n.options;if(!o||/\n[\t ]+$/.test(t)||/^\s*$/.test(t))return le(t,n);const c=n.indent||(n.forceBlockIndent||je(t)?" ":""),u=o==="literal"?!0:o==="folded"||e===O.BLOCK_FOLDED?!1:e===O.BLOCK_LITERAL?!0:!Us(t,a,c.length);if(!t)return u?`|
|
|
17
|
+
${t}`)+"'";return e.implicitKey?n:Me(n,t,qt,Pe(e,!1))}function le(s,e){const{singleQuote:t}=e.options;let n;if(t===!1)n=we;else{const i=s.includes('"'),r=s.includes("'");i&&!r?n=ot:r&&!i?n=we:n=t?ot:we}return n(s,e)}function De({comment:s,type:e,value:t},n,i,r){const{blockQuote:o,commentString:l,lineWidth:a}=n.options;if(!o||/\n[\t ]+$/.test(t)||/^\s*$/.test(t))return le(t,n);const c=n.indent||(n.forceBlockIndent||je(t)?" ":""),u=o==="literal"?!0:o==="folded"||e===O.BLOCK_FOLDED?!1:e===O.BLOCK_LITERAL?!0:!Us(t,a,c.length);if(!t)return u?`|
|
|
18
18
|
`:`>
|
|
19
19
|
`;let f,h;for(h=t.length;h>0;--h){const b=t[h-1];if(b!==`
|
|
20
20
|
`&&b!==" "&&b!==" ")break}let p=t.substring(h);const g=p.indexOf(`
|
|
@@ -22,11 +22,11 @@ ${t}`)+"'";return e.implicitKey?n:Me(n,t,qt,Pe(e))}function le(s,e){const{single
|
|
|
22
22
|
`&&(p=p.slice(0,-1)),p=p.replace(/\n+(?!\n|$)/g,`$&${c}`));let d=!1,m,w=-1;for(m=0;m<t.length;++m){const b=t[m];if(b===" ")d=!0;else if(b===`
|
|
23
23
|
`)w=m;else break}let y=t.substring(0,w<m?w+1:m);y&&(t=t.substring(y.length),y=y.replace(/\n+/g,`$&${c}`));let N=(u?"|":">")+(d?c?"2":"1":"")+f;if(s&&(N+=" "+l(s.replace(/ ?[\r\n]+/g," ")),i&&i()),u)return t=t.replace(/\n+/g,`$&${c}`),`${N}
|
|
24
24
|
${c}${y}${t}${p}`;t=t.replace(/\n+/g,`
|
|
25
|
-
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${c}`);const k=Me(`${y}${t}${p}`,c,rt,Pe(n));return`${N}
|
|
25
|
+
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${c}`);const k=Me(`${y}${t}${p}`,c,rt,Pe(n,!0));return`${N}
|
|
26
26
|
${c}${k}`}function Rs(s,e,t,n){const{type:i,value:r}=s,{actualString:o,implicitKey:l,indent:a,indentStep:c,inFlow:u}=e;if(l&&/[\n[\]{},]/.test(r)||u&&/[[\]{},]/.test(r))return le(r,e);if(!r||/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(r))return l||u||!r.includes(`
|
|
27
27
|
`)?le(r,e):De(s,e,t,n);if(!l&&!u&&i!==O.PLAIN&&r.includes(`
|
|
28
28
|
`))return De(s,e,t,n);if(je(r)){if(a==="")return e.forceBlockIndent=!0,De(s,e,t,n);if(l&&a===c)return le(r,e)}const f=r.replace(/\n+/g,`$&
|
|
29
|
-
${a}`);if(o){const h=d=>{var m;return d.default&&d.tag!=="tag:yaml.org,2002:str"&&((m=d.test)==null?void 0:m.test(f))},{compat:p,tags:g}=e.doc.schema;if(g.some(h)||p!=null&&p.some(h))return le(r,e)}return l?f:Me(f,a,qt,Pe(e))}function Se(s,e,t,n){const{implicitKey:i,inFlow:r}=e,o=typeof s.value=="string"?s:Object.assign({},s,{value:String(s.value)});let{type:l}=s;l!==O.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(l=O.QUOTE_DOUBLE);const a=u=>{switch(u){case O.BLOCK_FOLDED:case O.BLOCK_LITERAL:return i||r?le(o.value,e):De(o,e,t,n);case O.QUOTE_DOUBLE:return we(o.value,e);case O.QUOTE_SINGLE:return ot(o.value,e);case O.PLAIN:return Rs(o,e,t,n);default:return null}};let c=a(l);if(c===null){const{defaultKeyType:u,defaultStringType:f}=e.options,h=i&&u||f;if(c=a(h),c===null)throw new Error(`Unsupported default string type ${h}`)}return c}function Ut(s,e){const t=Object.assign({blockQuote:!0,commentString:Fs,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trueStr:"true",verifyAliasOrder:!0},s.schema.toStringOptions,e);let n;switch(t.collectionStyle){case"block":n=!1;break;case"flow":n=!0;break;default:n=null}return{anchors:new Set,doc:s,flowCollectionPadding:t.flowCollectionPadding?" ":"",indent:"",indentStep:typeof t.indent=="number"?" ".repeat(t.indent):" ",inFlow:n,options:t}}function Vs(s,e){var i,r,o,l;if(e.tag){const a=s.filter(c=>c.tag===e.tag);if(a.length>0)return(i=a.find(c=>c.format===e.format))!=null?i:a[0]}let t,n;if(A(e)){n=e.value;const a=s.filter(c=>{var u;return(u=c.identify)==null?void 0:u.call(c,n)});t=(r=a.find(c=>c.format===e.format))!=null?r:a.find(c=>!c.format)}else n=e,t=s.find(a=>a.nodeClass&&n instanceof a.nodeClass);if(!t){const a=(l=(o=n==null?void 0:n.constructor)==null?void 0:o.name)!=null?l:typeof n;throw new Error(`Tag not resolved for ${a} value`)}return t}function Ys(s,e,{anchors:t,doc:n}){if(!n.directives)return"";const i=[],r=(A(s)||I(s))&&s.anchor;r&&Pt(r)&&(t.add(r),i.push(`&${r}`));const o=s.tag?s.tag:e.default?null:e.tag;return o&&i.push(n.directives.tagString(o)),i.join(" ")}function X(s,e,t,n){var a,c;if(E(s))return s.toString(e,t,n);if(W(s)){if(e.doc.directives)return s.toString(e);if((a=e.resolvedAliases)!=null&&a.has(s))throw new TypeError("Cannot stringify circular structure without alias nodes");e.resolvedAliases?e.resolvedAliases.add(s):e.resolvedAliases=new Set([s]),s=s.resolve(e.doc)}let i;const r=T(s)?s:e.doc.createNode(s,{onTagObj:u=>i=u});i||(i=Vs(e.doc.schema.tags,r));const o=Ys(r,i,e);o.length>0&&(e.indentAtStart=((c=e.indentAtStart)!=null?c:0)+o.length+1);const l=typeof i.stringify=="function"?i.stringify(r,e,t,n):A(r)?Se(r,e,t,n):r.toString(e,t,n);return o?A(r)||l[0]==="{"||l[0]==="["?`${o} ${l}`:`${o}
|
|
29
|
+
${a}`);if(o){const h=d=>{var m;return d.default&&d.tag!=="tag:yaml.org,2002:str"&&((m=d.test)==null?void 0:m.test(f))},{compat:p,tags:g}=e.doc.schema;if(g.some(h)||p!=null&&p.some(h))return le(r,e)}return l?f:Me(f,a,qt,Pe(e,!1))}function Se(s,e,t,n){const{implicitKey:i,inFlow:r}=e,o=typeof s.value=="string"?s:Object.assign({},s,{value:String(s.value)});let{type:l}=s;l!==O.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(l=O.QUOTE_DOUBLE);const a=u=>{switch(u){case O.BLOCK_FOLDED:case O.BLOCK_LITERAL:return i||r?le(o.value,e):De(o,e,t,n);case O.QUOTE_DOUBLE:return we(o.value,e);case O.QUOTE_SINGLE:return ot(o.value,e);case O.PLAIN:return Rs(o,e,t,n);default:return null}};let c=a(l);if(c===null){const{defaultKeyType:u,defaultStringType:f}=e.options,h=i&&u||f;if(c=a(h),c===null)throw new Error(`Unsupported default string type ${h}`)}return c}function Ut(s,e){const t=Object.assign({blockQuote:!0,commentString:Fs,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trueStr:"true",verifyAliasOrder:!0},s.schema.toStringOptions,e);let n;switch(t.collectionStyle){case"block":n=!1;break;case"flow":n=!0;break;default:n=null}return{anchors:new Set,doc:s,flowCollectionPadding:t.flowCollectionPadding?" ":"",indent:"",indentStep:typeof t.indent=="number"?" ".repeat(t.indent):" ",inFlow:n,options:t}}function Vs(s,e){var i,r,o,l;if(e.tag){const a=s.filter(c=>c.tag===e.tag);if(a.length>0)return(i=a.find(c=>c.format===e.format))!=null?i:a[0]}let t,n;if(A(e)){n=e.value;const a=s.filter(c=>{var u;return(u=c.identify)==null?void 0:u.call(c,n)});t=(r=a.find(c=>c.format===e.format))!=null?r:a.find(c=>!c.format)}else n=e,t=s.find(a=>a.nodeClass&&n instanceof a.nodeClass);if(!t){const a=(l=(o=n==null?void 0:n.constructor)==null?void 0:o.name)!=null?l:typeof n;throw new Error(`Tag not resolved for ${a} value`)}return t}function Ys(s,e,{anchors:t,doc:n}){if(!n.directives)return"";const i=[],r=(A(s)||I(s))&&s.anchor;r&&Pt(r)&&(t.add(r),i.push(`&${r}`));const o=s.tag?s.tag:e.default?null:e.tag;return o&&i.push(n.directives.tagString(o)),i.join(" ")}function X(s,e,t,n){var a,c;if(E(s))return s.toString(e,t,n);if(W(s)){if(e.doc.directives)return s.toString(e);if((a=e.resolvedAliases)!=null&&a.has(s))throw new TypeError("Cannot stringify circular structure without alias nodes");e.resolvedAliases?e.resolvedAliases.add(s):e.resolvedAliases=new Set([s]),s=s.resolve(e.doc)}let i;const r=T(s)?s:e.doc.createNode(s,{onTagObj:u=>i=u});i||(i=Vs(e.doc.schema.tags,r));const o=Ys(r,i,e);o.length>0&&(e.indentAtStart=((c=e.indentAtStart)!=null?c:0)+o.length+1);const l=typeof i.stringify=="function"?i.stringify(r,e,t,n):A(r)?Se(r,e,t,n):r.toString(e,t,n);return o?A(r)||l[0]==="{"||l[0]==="["?`${o} ${l}`:`${o}
|
|
30
30
|
${e.indent}${l}`:l}function Js({key:s,value:e},t,n,i){var L,$;const{allNullValues:r,doc:o,indent:l,indentStep:a,options:{commentString:c,indentSeq:u,simpleKeys:f}}=t;let h=T(s)&&s.comment||null;if(f){if(h)throw new Error("With simple keys, key nodes cannot have comments");if(I(s)){const B="With simple keys, collection cannot be used as a key value";throw new Error(B)}}let p=!f&&(!s||h&&e==null&&!t.inFlow||I(s)||(A(s)?s.type===O.BLOCK_FOLDED||s.type===O.BLOCK_LITERAL:typeof s=="object"));t=Object.assign({},t,{allNullValues:!1,implicitKey:!p&&(f||!r),indent:l+a});let g=!1,d=!1,m=X(s,t,()=>g=!0,()=>d=!0);if(!p&&!t.inFlow&&m.length>1024){if(f)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");p=!0}if(t.inFlow){if(r||e==null)return g&&n&&n(),m===""?"?":p?`? ${m}`:m}else if(r&&!f||e==null&&p)return m=`? ${m}`,h&&!g?m+=G(m,t.indent,c(h)):d&&i&&i(),m;g&&(h=null),p?(h&&(m+=G(m,t.indent,c(h))),m=`? ${m}
|
|
31
31
|
${l}:`):(m=`${m}:`,h&&(m+=G(m,t.indent,c(h))));let w,y,S;T(e)?(w=!!e.spaceBefore,y=e.commentBefore,S=e.comment):(w=!1,y=null,S=null,e&&typeof e=="object"&&(e=o.createNode(e))),t.implicitKey=!1,!p&&!h&&A(e)&&(t.indentAtStart=m.length+1),d=!1,!u&&a.length>=2&&!t.inFlow&&!p&&ie(e)&&!e.flow&&!e.tag&&!e.anchor&&(t.indent=t.indent.substring(2));let N=!1;const k=X(e,t,()=>N=!0,()=>d=!0);let b=" ";if(h||w||y){if(b=w?`
|
|
32
32
|
`:"",y){const B=c(y);b+=`
|
|
@@ -44,14 +44,14 @@ ${a}${d}`:`
|
|
|
44
44
|
`))&&(f=!0),p.push(N),h=p.length}let g;const{start:d,end:m}=n;if(p.length===0)g=d+m;else if(f||(f=p.reduce((y,S)=>y+S.length+2,2)>ve.maxFlowStringSingleLineLength),f){g=d;for(const w of p)g+=w?`
|
|
45
45
|
${l}${o}${w}`:`
|
|
46
46
|
`;g+=`
|
|
47
|
-
${o}${m}`}else g=`${d}${a}${p.join(" ")}${a}${m}`;return s&&(g+=G(g,c(s)
|
|
47
|
+
${o}${m}`}else g=`${d}${a}${p.join(" ")}${a}${m}`;return s&&(g+=G(g,o,c(s)),r&&r()),g}function Ke({indent:s,options:{commentString:e}},t,n,i){if(n&&i&&(n=n.replace(/^\n+/,"")),n){const r=V(e(n),s);t.push(r.trimStart())}}function z(s,e){const t=A(e)?e.value:e;for(const n of s)if(E(n)&&(n.key===e||n.key===t||A(n.key)&&n.key.value===t))return n}class j extends ve{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(Y,e),this.items=[]}add(e,t){var o;let n;E(e)?n=e:!e||typeof e!="object"||!("key"in e)?n=new _(e,e==null?void 0:e.value):n=new _(e.key,e.value);const i=z(this.items,n.key),r=(o=this.schema)==null?void 0:o.sortMapEntries;if(i){if(!t)throw new Error(`Key ${n.key} already set`);A(i.value)&&Kt(n.value)?i.value.value=n.value:i.value=n.value}else if(r){const l=this.items.findIndex(a=>r(n,a)<0);l===-1?this.items.push(n):this.items.splice(l,0,n)}else this.items.push(n)}delete(e){const t=z(this.items,e);return t?this.items.splice(this.items.indexOf(t),1).length>0:!1}get(e,t){var r;const n=z(this.items,e),i=n==null?void 0:n.value;return(r=!t&&A(i)?i.value:i)!=null?r:void 0}has(e){return!!z(this.items,e)}set(e,t){this.add(new _(e,t),!0)}toJSON(e,t,n){const i=n?new n:t!=null&&t.mapAsMap?new Map:{};t!=null&&t.onCreate&&t.onCreate(i);for(const r of this.items)Yt(t,i,r);return i}toString(e,t,n){if(!e)return JSON.stringify(this);for(const i of this.items)if(!E(i))throw new Error(`Map items must all be pairs; found ${JSON.stringify(i)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),Jt(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:n,onComment:t})}}function Xs(s,e,t){const{keepUndefined:n,replacer:i}=t,r=new j(s),o=(l,a)=>{if(typeof i=="function")a=i.call(e,l,a);else if(Array.isArray(i)&&!i.includes(l))return;(a!==void 0||n)&&r.items.push(ct(l,a,t))};if(e instanceof Map)for(const[l,a]of e)o(l,a);else if(e&&typeof e=="object")for(const l of Object.keys(e))o(l,e[l]);return typeof s.sortMapEntries=="function"&&r.items.sort(s.sortMapEntries),r}const ae={collection:"map",createNode:Xs,default:!0,nodeClass:j,tag:"tag:yaml.org,2002:map",resolve(s,e){return H(s)||e("Expected a mapping for this tag"),s}};class Z extends ve{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(ne,e),this.items=[]}add(e){this.items.push(e)}delete(e){const t=qe(e);return typeof t!="number"?!1:this.items.splice(t,1).length>0}get(e,t){const n=qe(e);if(typeof n!="number")return;const i=this.items[n];return!t&&A(i)?i.value:i}has(e){const t=qe(e);return typeof t=="number"&&t<this.items.length}set(e,t){const n=qe(e);if(typeof n!="number")throw new Error(`Expected a valid index, not ${e}.`);const i=this.items[n];A(i)&&Kt(t)?i.value=t:this.items[n]=t}toJSON(e,t){const n=[];t!=null&&t.onCreate&&t.onCreate(n);let i=0;for(const r of this.items)n.push(U(r,String(i++),t));return n}toString(e,t,n){return e?Jt(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+" ",onChompKeep:n,onComment:t}):JSON.stringify(this)}}function qe(s){let e=A(s)?s.value:s;return e&&typeof e=="string"&&(e=Number(e)),typeof e=="number"&&Number.isInteger(e)&&e>=0?e:null}function zs(s,e,t){const{replacer:n}=t,i=new Z(s);if(e&&Symbol.iterator in Object(e)){let r=0;for(let o of e){if(typeof n=="function"){const l=e instanceof Set?o:String(r++);o=n.call(e,l,o)}i.items.push(ge(o,void 0,t))}}return i}const ce={collection:"seq",createNode:zs,default:!0,nodeClass:Z,tag:"tag:yaml.org,2002:seq",resolve(s,e){return ie(s)||e("Expected a sequence for this tag"),s}},Fe={identify:s=>typeof s=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:s=>s,stringify(s,e,t,n){return e=Object.assign({actualString:!0},e),Se(s,e,t,n)}},Ue={identify:s=>s==null,createNode:()=>new O(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new O(null),stringify:({source:s},e)=>typeof s=="string"&&Ue.test.test(s)?s:e.options.nullStr},ft={identify:s=>typeof s=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:s=>new O(s[0]==="t"||s[0]==="T"),stringify({source:s,value:e},t){if(s&&ft.test.test(s)){const n=s[0]==="t"||s[0]==="T";if(e===n)return s}return e?t.options.trueStr:t.options.falseStr}};function K({format:s,minFractionDigits:e,tag:t,value:n}){if(typeof n=="bigint")return String(n);const i=typeof n=="number"?n:Number(n);if(!isFinite(i))return isNaN(i)?".nan":i<0?"-.inf":".inf";let r=JSON.stringify(n);if(!s&&e&&(!t||t==="tag:yaml.org,2002:float")&&/^\d/.test(r)){let o=r.indexOf(".");o<0&&(o=r.length,r+=".");let l=e-(r.length-o-1);for(;l-- >0;)r+="0"}return r}const Gt={identify:s=>typeof s=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF|nan|NaN|NAN))$/,resolve:s=>s.slice(-3).toLowerCase()==="nan"?NaN:s[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:K},Qt={identify:s=>typeof s=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:s=>parseFloat(s),stringify(s){const e=Number(s.value);return isFinite(e)?e.toExponential():K(s)}},Wt={identify:s=>typeof s=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(s){const e=new O(parseFloat(s)),t=s.indexOf(".");return t!==-1&&s[s.length-1]==="0"&&(e.minFractionDigits=s.length-t-1),e},stringify:K},Re=s=>typeof s=="bigint"||Number.isInteger(s),ut=(s,e,t,{intAsBigInt:n})=>n?BigInt(s):parseInt(s.substring(e),t);function Ht(s,e,t){const{value:n}=s;return Re(n)&&n>=0?t+n.toString(e):K(s)}const Xt={identify:s=>Re(s)&&s>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(s,e,t)=>ut(s,2,8,t),stringify:s=>Ht(s,8,"0o")},zt={identify:Re,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(s,e,t)=>ut(s,0,10,t),stringify:K},Zt={identify:s=>Re(s)&&s>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(s,e,t)=>ut(s,2,16,t),stringify:s=>Ht(s,16,"0x")},Zs=[ae,ce,Fe,Ue,ft,Xt,zt,Zt,Gt,Qt,Wt];function xt(s){return typeof s=="bigint"||Number.isInteger(s)}const Ve=({value:s})=>JSON.stringify(s),xs=[{identify:s=>typeof s=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:s=>s,stringify:Ve},{identify:s=>s==null,createNode:()=>new O(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:Ve},{identify:s=>typeof s=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true|false$/,resolve:s=>s==="true",stringify:Ve},{identify:xt,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(s,e,{intAsBigInt:t})=>t?BigInt(s):parseInt(s,10),stringify:({value:s})=>xt(s)?s.toString():JSON.stringify(s)},{identify:s=>typeof s=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:s=>parseFloat(s),stringify:Ve}],en={default:!0,tag:"",test:/^/,resolve(s,e){return e(`Unresolved plain scalar ${JSON.stringify(s)}`),s}},tn=[ae,ce].concat(xs,en);var ke=Q(48834).lW;const ht={identify:s=>s instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(s,e){if(typeof ke=="function")return ke.from(s,"base64");if(typeof atob=="function"){const t=atob(s.replace(/[\n\r]/g,"")),n=new Uint8Array(t.length);for(let i=0;i<t.length;++i)n[i]=t.charCodeAt(i);return n}else return e("This environment does not support reading binary tags; either Buffer or atob is required"),s},stringify({comment:s,type:e,value:t},n,i,r){const o=t;let l;if(typeof ke=="function")l=o instanceof ke?o.toString("base64"):ke.from(o.buffer).toString("base64");else if(typeof btoa=="function"){let a="";for(let c=0;c<o.length;++c)a+=String.fromCharCode(o[c]);l=btoa(a)}else throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(e||(e=O.BLOCK_LITERAL),e!==O.QUOTE_DOUBLE){const a=Math.max(n.options.lineWidth-n.indent.length,n.options.minContentWidth),c=Math.ceil(l.length/a),u=new Array(c);for(let f=0,h=0;f<c;++f,h+=a)u[f]=l.substr(h,a);l=u.join(e===O.BLOCK_LITERAL?`
|
|
48
48
|
`:" ")}return Se({comment:s,type:e,value:l},n,i,r)}};function es(s,e){var t;if(ie(s))for(let n=0;n<s.items.length;++n){let i=s.items[n];if(!E(i)){if(H(i)){i.items.length>1&&e("Each pair must have its own sequence indicator");const r=i.items[0]||new _(new O(null));if(i.commentBefore&&(r.key.commentBefore=r.key.commentBefore?`${i.commentBefore}
|
|
49
49
|
${r.key.commentBefore}`:i.commentBefore),i.comment){const o=(t=r.value)!=null?t:r.key;o.comment=o.comment?`${i.comment}
|
|
50
50
|
${o.comment}`:i.comment}i=r}s.items[n]=E(i)?i:new _(i)}}else e("Expected a sequence for this tag");return s}function ts(s,e,t){const{replacer:n}=t,i=new Z(s);i.tag="tag:yaml.org,2002:pairs";let r=0;if(e&&Symbol.iterator in Object(e))for(let o of e){typeof n=="function"&&(o=n.call(e,String(r++),o));let l,a;if(Array.isArray(o))if(o.length===2)l=o[0],a=o[1];else throw new TypeError(`Expected [key, value] tuple: ${o}`);else if(o&&o instanceof Object){const c=Object.keys(o);if(c.length===1)l=c[0],a=o[l];else throw new TypeError(`Expected { key: value } tuple: ${o}`)}else l=o;i.items.push(ct(l,a,t))}return i}const dt={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:es,createNode:ts};class fe extends Z{constructor(){super(),this.add=j.prototype.add.bind(this),this.delete=j.prototype.delete.bind(this),this.get=j.prototype.get.bind(this),this.has=j.prototype.has.bind(this),this.set=j.prototype.set.bind(this),this.tag=fe.tag}toJSON(e,t){if(!t)return super.toJSON(e);const n=new Map;t!=null&&t.onCreate&&t.onCreate(n);for(const i of this.items){let r,o;if(E(i)?(r=U(i.key,"",t),o=U(i.value,r,t)):r=U(i,"",t),n.has(r))throw new Error("Ordered maps must not include duplicate keys");n.set(r,o)}return n}}fe.tag="tag:yaml.org,2002:omap";const pt={collection:"seq",identify:s=>s instanceof Map,nodeClass:fe,default:!1,tag:"tag:yaml.org,2002:omap",resolve(s,e){const t=es(s,e),n=[];for(const{key:i}of t.items)A(i)&&(n.includes(i.value)?e(`Ordered maps must not include duplicate keys: ${i.value}`):n.push(i.value));return Object.assign(new fe,t)},createNode(s,e,t){const n=ts(s,e,t),i=new fe;return i.items=n.items,i}};function ss({value:s,source:e},t){return e&&(s?ns:is).test.test(e)?e:s?t.options.trueStr:t.options.falseStr}const ns={identify:s=>s===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new O(!0),stringify:ss},is={identify:s=>s===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/i,resolve:()=>new O(!1),stringify:ss},sn={identify:s=>typeof s=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?\.(?:inf|Inf|INF|nan|NaN|NAN)$/,resolve:s=>s.slice(-3).toLowerCase()==="nan"?NaN:s[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:K},nn={identify:s=>typeof s=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:s=>parseFloat(s.replace(/_/g,"")),stringify(s){const e=Number(s.value);return isFinite(e)?e.toExponential():K(s)}},rn={identify:s=>typeof s=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(s){const e=new O(parseFloat(s.replace(/_/g,""))),t=s.indexOf(".");if(t!==-1){const n=s.substring(t+1).replace(/_/g,"");n[n.length-1]==="0"&&(e.minFractionDigits=n.length)}return e},stringify:K},Ne=s=>typeof s=="bigint"||Number.isInteger(s);function Ye(s,e,t,{intAsBigInt:n}){const i=s[0];if((i==="-"||i==="+")&&(e+=1),s=s.substring(e).replace(/_/g,""),n){switch(t){case 2:s=`0b${s}`;break;case 8:s=`0o${s}`;break;case 16:s=`0x${s}`;break}const o=BigInt(s);return i==="-"?BigInt(-1)*o:o}const r=parseInt(s,t);return i==="-"?-1*r:r}function mt(s,e,t){const{value:n}=s;if(Ne(n)){const i=n.toString(e);return n<0?"-"+t+i.substr(1):t+i}return K(s)}const on={identify:Ne,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(s,e,t)=>Ye(s,2,2,t),stringify:s=>mt(s,2,"0b")},ln={identify:Ne,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(s,e,t)=>Ye(s,1,8,t),stringify:s=>mt(s,8,"0")},an={identify:Ne,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(s,e,t)=>Ye(s,0,10,t),stringify:K},cn={identify:Ne,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(s,e,t)=>Ye(s,2,16,t),stringify:s=>mt(s,16,"0x")};class ue extends j{constructor(e){super(e),this.tag=ue.tag}add(e){let t;E(e)?t=e:e&&typeof e=="object"&&"key"in e&&"value"in e&&e.value===null?t=new _(e.key,null):t=new _(e,null),z(this.items,t.key)||this.items.push(t)}get(e,t){const n=z(this.items,e);return!t&&E(n)?A(n.key)?n.key.value:n.key:n}set(e,t){if(typeof t!="boolean")throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof t}`);const n=z(this.items,e);n&&!t?this.items.splice(this.items.indexOf(n),1):!n&&t&&this.items.push(new _(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,n);throw new Error("Set items must all have null values")}}ue.tag="tag:yaml.org,2002:set";const yt={collection:"map",identify:s=>s instanceof Set,nodeClass:ue,default:!1,tag:"tag:yaml.org,2002:set",resolve(s,e){if(H(s)){if(s.hasAllNullValues(!0))return Object.assign(new ue,s);e("Set items must all have null values")}else e("Expected a mapping for this tag");return s},createNode(s,e,t){const{replacer:n}=t,i=new ue(s);if(e&&Symbol.iterator in Object(e))for(let r of e)typeof n=="function"&&(r=n.call(e,r,r)),i.items.push(ct(r,null,t));return i}};function gt(s,e){const t=s[0],n=t==="-"||t==="+"?s.substring(1):s,i=o=>e?BigInt(o):Number(o),r=n.replace(/_/g,"").split(":").reduce((o,l)=>o*i(60)+i(l),i(0));return t==="-"?i(-1)*r:r}function rs(s){let{value:e}=s,t=o=>o;if(typeof e=="bigint")t=o=>BigInt(o);else if(isNaN(e)||!isFinite(e))return K(s);let n="";e<0&&(n="-",e*=t(-1));const i=t(60),r=[e%i];return e<60?r.unshift(0):(e=(e-r[0])/i,r.unshift(e%i),e>=60&&(e=(e-r[0])/i,r.unshift(e))),n+r.map(o=>o<10?"0"+String(o):String(o)).join(":").replace(/000000\d*$/,"")}const os={identify:s=>typeof s=="bigint"||Number.isInteger(s),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(s,e,{intAsBigInt:t})=>gt(s,t),stringify:rs},ls={identify:s=>typeof s=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:s=>gt(s,!1),stringify:rs},Je={identify:s=>s 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(s){const e=s.match(Je.test);if(!e)throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd");const[,t,n,i,r,o,l]=e.map(Number),a=e[7]?Number((e[7]+"00").substr(1,3)):0;let c=Date.UTC(t,n-1,i,r||0,o||0,l||0,a);const u=e[8];if(u&&u!=="Z"){let f=gt(u,!1);Math.abs(f)<30&&(f*=60),c-=6e4*f}return new Date(c)},stringify:({value:s})=>s.toISOString().replace(/((T00:00)?:00)?\.000Z$/,"")},as=[ae,ce,Fe,Ue,ns,is,on,ln,an,cn,sn,nn,rn,ht,pt,dt,yt,os,ls,Je],cs=new Map([["core",Zs],["failsafe",[ae,ce,Fe]],["json",tn],["yaml11",as],["yaml-1.1",as]]),fs={binary:ht,bool:ft,float:Wt,floatExp:Qt,floatNaN:Gt,floatTime:ls,int:zt,intHex:Zt,intOct:Xt,intTime:os,map:ae,null:Ue,omap:pt,pairs:dt,seq:ce,set:yt,timestamp:Je},fn={"tag:yaml.org,2002:binary":ht,"tag:yaml.org,2002:omap":pt,"tag:yaml.org,2002:pairs":dt,"tag:yaml.org,2002:set":yt,"tag:yaml.org,2002:timestamp":Je};function bt(s,e){let t=cs.get(e);if(!t)if(Array.isArray(s))t=[];else{const n=Array.from(cs.keys()).filter(i=>i!=="yaml11").map(i=>JSON.stringify(i)).join(", ");throw new Error(`Unknown schema "${e}"; use one of ${n} or define customTags array`)}if(Array.isArray(s))for(const n of s)t=t.concat(n);else typeof s=="function"&&(t=s(t.slice()));return t.map(n=>{if(typeof n!="string")return n;const i=fs[n];if(i)return i;const r=Object.keys(fs).map(o=>JSON.stringify(o)).join(", ");throw new Error(`Unknown custom tag "${n}"; use one of ${r}`)})}const un=(s,e)=>s.key<e.key?-1:s.key>e.key?1:0;class Ge{constructor({compat:e,customTags:t,merge:n,resolveKnownTags:i,schema:r,sortMapEntries:o,toStringDefaults:l}){this.compat=Array.isArray(e)?bt(e,"compat"):e?bt(null,e):null,this.merge=!!n,this.name=typeof r=="string"&&r||"core",this.knownTags=i?fn:{},this.tags=bt(t,this.name),this.toStringOptions=l!=null?l:null,Object.defineProperty(this,Y,{value:ae}),Object.defineProperty(this,R,{value:Fe}),Object.defineProperty(this,ne,{value:ce}),this.sortMapEntries=typeof o=="function"?o:o===!0?un:null}clone(){const e=Object.create(Ge.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}function hn(s,e){var a;const t=[];let n=e.directives===!0;if(e.directives!==!1&&s.directives){const c=s.directives.toString(s);c?(t.push(c),n=!0):s.directives.docStart&&(n=!0)}n&&t.push("---");const i=Ut(s,e),{commentString:r}=i.options;if(s.commentBefore){t.length!==1&&t.unshift("");const c=r(s.commentBefore);t.unshift(V(c,""))}let o=!1,l=null;if(s.contents){if(T(s.contents)){if(s.contents.spaceBefore&&n&&t.push(""),s.contents.commentBefore){const f=r(s.contents.commentBefore);t.push(V(f,""))}i.forceBlockIndent=!!s.comment,l=s.contents.comment}const c=l?void 0:()=>o=!0;let u=X(s.contents,i,()=>l=null,c);l&&(u+=G(u,"",r(l))),(u[0]==="|"||u[0]===">")&&t[t.length-1]==="---"?t[t.length-1]=`--- ${u}`:t.push(u)}else t.push(X(s.contents,i));if((a=s.directives)!=null&&a.docEnd)if(s.comment){const c=r(s.comment);c.includes(`
|
|
51
51
|
`)?(t.push("..."),t.push(V(c,""))):t.push(`... ${c}`)}else t.push("...");else{let c=s.comment;c&&o&&(c=c.replace(/^\n+/,"")),c&&((!o||l)&&t[t.length-1]!==""&&t.push(""),t.push(V(r(c),"")))}return t.join(`
|
|
52
52
|
`)+`
|
|
53
53
|
`}function Oe(s,e,t,n){if(n&&typeof n=="object")if(Array.isArray(n))for(let i=0,r=n.length;i<r;++i){const o=n[i],l=Oe(s,n,String(i),o);l===void 0?delete n[i]:l!==o&&(n[i]=l)}else if(n instanceof Map)for(const i of Array.from(n.keys())){const r=n.get(i),o=Oe(s,n,i,r);o===void 0?n.delete(i):o!==r&&n.set(i,o)}else if(n instanceof Set)for(const i of Array.from(n)){const r=Oe(s,n,i,i);r===void 0?n.delete(i):r!==i&&(n.delete(i),n.add(r))}else for(const[i,r]of Object.entries(n)){const o=Oe(s,n,i,r);o===void 0?delete n[i]:o!==r&&(n[i]=o)}return s.call(e,t,n)}class he{constructor(e,t,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,P,{value:nt});let i=null;typeof t=="function"||Array.isArray(t)?i=t:n===void 0&&t&&(n=t,t=void 0);const r=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,uniqueKeys:!0,version:"1.2"},n);this.options=r;let{version:o}=r;n!=null&&n._directives?(this.directives=n._directives.atDocument(),this.directives.yaml.explicit&&(o=this.directives.yaml.version)):this.directives=new C({version:o}),this.setSchema(o,n),e===void 0?this.contents=null:this.contents=this.createNode(e,i,n)}clone(){const e=Object.create(he.prototype,{[P]:{value:nt}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=T(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){de(this.contents)&&this.contents.add(e)}addIn(e,t){de(this.contents)&&this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){const n=jt(this);e.anchor=!t||n.has(t)?Dt(t||"a",n):t}return new _e(e.anchor)}createNode(e,t,n){let i;if(typeof t=="function")e=t.call({"":e},"",e),i=t;else if(Array.isArray(t)){const m=y=>typeof y=="number"||y instanceof String||y instanceof Number,w=t.filter(m).map(String);w.length>0&&(t=t.concat(w)),i=t}else n===void 0&&t&&(n=t,t=void 0);const{aliasDuplicateObjects:r,anchorPrefix:o,flow:l,keepUndefined:a,onTagObj:c,tag:u}=n!=null?n:{},{onAnchor:f,setAnchors:h,sourceObjects:p}=Ds(this,o||"a"),g={aliasDuplicateObjects:r!=null?r:!0,keepUndefined:a!=null?a:!1,onAnchor:f,onTagObj:c,replacer:i,schema:this.schema,sourceObjects:p},d=ge(e,u,g);return l&&I(d)&&(d.flow=!0),h(),d}createPair(e,t,n={}){const i=this.createNode(e,null,n),r=this.createNode(t,null,n);return new _(i,r)}delete(e){return de(this.contents)?this.contents.delete(e):!1}deleteIn(e){return be(e)?this.contents==null?!1:(this.contents=null,!0):de(this.contents)?this.contents.deleteIn(e):!1}get(e,t){return I(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){return be(e)?!t&&A(this.contents)?this.contents.value:this.contents:I(this.contents)?this.contents.getIn(e,t):void 0}has(e){return I(this.contents)?this.contents.has(e):!1}hasIn(e){return be(e)?this.contents!==void 0:I(this.contents)?this.contents.hasIn(e):!1}set(e,t){this.contents==null?this.contents=Ce(this.schema,[e],t):de(this.contents)&&this.contents.set(e,t)}setIn(e,t){be(e)?this.contents=t:this.contents==null?this.contents=Ce(this.schema,Array.from(e),t):de(this.contents)&&this.contents.setIn(e,t)}setSchema(e,t={}){typeof e=="number"&&(e=String(e));let n;switch(e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new C({version:"1.1"}),n={merge:!0,resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new C({version:e}),n={merge:!1,resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,n=null;break;default:{const i=JSON.stringify(e);throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${i}`)}}if(t.schema instanceof Object)this.schema=t.schema;else if(n)this.schema=new Ge(Object.assign(n,t));else throw new Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:t,mapAsMap:n,maxAliasCount:i,onAnchor:r,reviver:o}={}){const l={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof i=="number"?i:100,stringify:X},a=U(this.contents,t!=null?t:"",l);if(typeof r=="function")for(const{count:c,res:u}of l.anchors.values())r(u,c);return typeof o=="function"?Oe(o,{"":a},"",a):a}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){const t=JSON.stringify(e.indent);throw new Error(`"indent" option must be a positive integer, not ${t}`)}return hn(this,e)}}function de(s){if(I(s))return!0;throw new Error("Expected a YAML collection as document contents")}class wt extends Error{constructor(e,t,n,i){super(),this.name=e,this.code=n,this.message=i,this.pos=t}}class x extends wt{constructor(e,t,n){super("YAMLParseError",e,t,n)}}class us extends wt{constructor(e,t,n){super("YAMLWarning",e,t,n)}}const Qe=(s,e)=>t=>{if(t.pos[0]===-1)return;t.linePos=t.pos.map(l=>e.linePos(l));const{line:n,col:i}=t.linePos[0];t.message+=` at line ${n}, column ${i}`;let r=i-1,o=s.substring(e.lineStarts[n-1],e.lineStarts[n]).replace(/[\n\r]+$/,"");if(r>=60&&o.length>80){const l=Math.min(r-39,o.length-79);o="\u2026"+o.substring(l),r-=l-1}if(o.length>80&&(o=o.substring(0,79)+"\u2026"),n>1&&/^ *$/.test(o.substring(0,r))){let l=s.substring(e.lineStarts[n-2],e.lineStarts[n-1]);l.length>80&&(l=l.substring(0,79)+`\u2026
|
|
54
|
-
`),o=l+o}if(/[^ ]/.test(o)){let l=1;const a=t.linePos[1];a&&a.line===n&&a.col>i&&(l=Math.min(a.col-i,80-r));const c=" ".repeat(r)+"^".repeat(l);t.message+=`:
|
|
54
|
+
`),o=l+o}if(/[^ ]/.test(o)){let l=1;const a=t.linePos[1];a&&a.line===n&&a.col>i&&(l=Math.max(1,Math.min(a.col-i,80-r)));const c=" ".repeat(r)+"^".repeat(l);t.message+=`:
|
|
55
55
|
|
|
56
56
|
${o}
|
|
57
57
|
${c}
|
|
@@ -133,4 +133,4 @@ ${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.pus
|
|
|
133
133
|
`)+1;for(;t!==0;)this.onNewLine(this.offset+t),t=this.source.indexOf(`
|
|
134
134
|
`,t)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;const t=xe(e),n=me(t);return n.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n}]}}case"map-value-ind":{this.onKeyLine=!0;const t=xe(e),n=me(t);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){return this.type!=="comment"||this.indent<=t?!1:e.every(n=>n.type==="newline"||n.type==="space")}*documentEnd(e){this.type!=="doc-mode"&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop())}}}function $s(s){const e=s.prettyErrors!==!1;return{lineCounter:s.lineCounter||e&&new Ls||null,prettyErrors:e}}function Rn(s,e={}){const{lineCounter:t,prettyErrors:n}=$s(e),i=new _t(t==null?void 0:t.addNewLine),r=new At(e),o=Array.from(r.compose(i.parse(s)));if(n&&t)for(const l of o)l.errors.forEach(Qe(s,t)),l.warnings.forEach(Qe(s,t));return o.length>0?o:Object.assign([],{empty:!0},r.streamInfo())}function Cs(s,e={}){const{lineCounter:t,prettyErrors:n}=$s(e),i=new _t(t==null?void 0:t.addNewLine),r=new At(e);let o=null;for(const l of r.compose(i.parse(s),!0,s.length))if(!o)o=l;else if(o.options.logLevel!=="silent"){o.errors.push(new x(l.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}return n&&t&&(o.errors.forEach(Qe(s,t)),o.warnings.forEach(Qe(s,t))),o}function Vn(s,e,t){let n;typeof e=="function"?n=e:t===void 0&&e&&typeof e=="object"&&(t=e);const i=Cs(s,t);if(!i)return null;if(i.warnings.forEach(r=>Rt(i.options.logLevel,r)),i.errors.length>0){if(i.options.logLevel!=="silent")throw i.errors[0];i.errors=[]}return i.toJS(Object.assign({reviver:n},t))}function Yn(s,e,t){var i;let n=null;if(typeof e=="function"||Array.isArray(e)?n=e:t===void 0&&e&&(t=e),typeof t=="string"&&(t=t.length),typeof t=="number"){const r=Math.round(t);t=r<1?void 0:r>8?{indent:8}:{indent:r}}if(s===void 0){const{keepUndefined:r}=(i=t!=null?t:e)!=null?i:{};if(!r)return}return new he(s,n,t).toString(t)}var Jn=tt}}]);})();
|
|
135
135
|
|
|
136
|
-
//# sourceMappingURL=module-yaml.
|
|
136
|
+
//# sourceMappingURL=module-yaml.639cc746.js.map
|