zudoku 0.4.2-dev.11 → 0.4.2-dev.12

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.
@@ -1,8 +1,8 @@
1
- const ut = Symbol.for("yaml.alias"), rt = Symbol.for("yaml.document"), J = Symbol.for("yaml.map"), Kt = Symbol.for("yaml.pair"), V = Symbol.for("yaml.scalar"), fe = Symbol.for("yaml.seq"), K = Symbol.for("yaml.node.type"), Z = (s) => !!s && typeof s == "object" && s[K] === ut, ue = (s) => !!s && typeof s == "object" && s[K] === rt, he = (s) => !!s && typeof s == "object" && s[K] === J, E = (s) => !!s && typeof s == "object" && s[K] === Kt, A = (s) => !!s && typeof s == "object" && s[K] === V, de = (s) => !!s && typeof s == "object" && s[K] === fe;
2
- function T(s) {
1
+ const ut = Symbol.for("yaml.alias"), rt = Symbol.for("yaml.document"), V = Symbol.for("yaml.map"), jt = Symbol.for("yaml.pair"), R = Symbol.for("yaml.scalar"), fe = Symbol.for("yaml.seq"), j = Symbol.for("yaml.node.type"), Z = (s) => !!s && typeof s == "object" && s[j] === ut, ue = (s) => !!s && typeof s == "object" && s[j] === rt, he = (s) => !!s && typeof s == "object" && s[j] === V, I = (s) => !!s && typeof s == "object" && s[j] === jt, E = (s) => !!s && typeof s == "object" && s[j] === R, de = (s) => !!s && typeof s == "object" && s[j] === fe;
2
+ function L(s) {
3
3
  if (s && typeof s == "object")
4
- switch (s[K]) {
5
- case J:
4
+ switch (s[j]) {
5
+ case V:
6
6
  case fe:
7
7
  return !0;
8
8
  }
@@ -10,29 +10,29 @@ function T(s) {
10
10
  }
11
11
  function $(s) {
12
12
  if (s && typeof s == "object")
13
- switch (s[K]) {
13
+ switch (s[j]) {
14
14
  case ut:
15
- case J:
16
15
  case V:
16
+ case R:
17
17
  case fe:
18
18
  return !0;
19
19
  }
20
20
  return !1;
21
21
  }
22
- const $s = (s) => (A(s) || T(s)) && !!s.anchor, M = Symbol("break visit"), qt = Symbol("skip children"), U = Symbol("remove node");
22
+ const $s = (s) => (E(s) || L(s)) && !!s.anchor, M = Symbol("break visit"), Kt = Symbol("skip children"), U = Symbol("remove node");
23
23
  function Y(s, e) {
24
- const t = Ft(e);
24
+ const t = qt(e);
25
25
  ue(s) ? se(null, s.contents, t, Object.freeze([s])) === U && (s.contents = null) : se(null, s, t, Object.freeze([]));
26
26
  }
27
27
  Y.BREAK = M;
28
- Y.SKIP = qt;
28
+ Y.SKIP = Kt;
29
29
  Y.REMOVE = U;
30
30
  function se(s, e, t, n) {
31
31
  const i = Ut(s, e, t, n);
32
- if ($(i) || E(i))
33
- return Rt(s, n, i), se(s, i, t, n);
32
+ if ($(i) || I(i))
33
+ return Ft(s, n, i), se(s, i, t, n);
34
34
  if (typeof i != "symbol") {
35
- if (T(e)) {
35
+ if (L(e)) {
36
36
  n = Object.freeze(n.concat(e));
37
37
  for (let r = 0; r < e.items.length; ++r) {
38
38
  const o = se(r, e.items[r], t, n);
@@ -44,7 +44,7 @@ function se(s, e, t, n) {
44
44
  o === U && (e.items.splice(r, 1), r -= 1);
45
45
  }
46
46
  }
47
- } else if (E(e)) {
47
+ } else if (I(e)) {
48
48
  n = Object.freeze(n.concat(e));
49
49
  const r = se("key", e.key, t, n);
50
50
  if (r === M)
@@ -58,19 +58,19 @@ function se(s, e, t, n) {
58
58
  }
59
59
  return i;
60
60
  }
61
- async function De(s, e) {
62
- const t = Ft(e);
61
+ async function Ke(s, e) {
62
+ const t = qt(e);
63
63
  ue(s) ? await ne(null, s.contents, t, Object.freeze([s])) === U && (s.contents = null) : await ne(null, s, t, Object.freeze([]));
64
64
  }
65
- De.BREAK = M;
66
- De.SKIP = qt;
67
- De.REMOVE = U;
65
+ Ke.BREAK = M;
66
+ Ke.SKIP = Kt;
67
+ Ke.REMOVE = U;
68
68
  async function ne(s, e, t, n) {
69
69
  const i = await Ut(s, e, t, n);
70
- if ($(i) || E(i))
71
- return Rt(s, n, i), ne(s, i, t, n);
70
+ if ($(i) || I(i))
71
+ return Ft(s, n, i), ne(s, i, t, n);
72
72
  if (typeof i != "symbol") {
73
- if (T(e)) {
73
+ if (L(e)) {
74
74
  n = Object.freeze(n.concat(e));
75
75
  for (let r = 0; r < e.items.length; ++r) {
76
76
  const o = await ne(r, e.items[r], t, n);
@@ -82,7 +82,7 @@ async function ne(s, e, t, n) {
82
82
  o === U && (e.items.splice(r, 1), r -= 1);
83
83
  }
84
84
  }
85
- } else if (E(e)) {
85
+ } else if (I(e)) {
86
86
  n = Object.freeze(n.concat(e));
87
87
  const r = await ne("key", e.key, t, n);
88
88
  if (r === M)
@@ -96,7 +96,7 @@ async function ne(s, e, t, n) {
96
96
  }
97
97
  return i;
98
98
  }
99
- function Ft(s) {
99
+ function qt(s) {
100
100
  return typeof s == "object" && (s.Collection || s.Node || s.Value) ? Object.assign({
101
101
  Alias: s.Node,
102
102
  Map: s.Node,
@@ -119,18 +119,18 @@ function Ut(s, e, t, n) {
119
119
  return (i = t.Map) == null ? void 0 : i.call(t, s, e, n);
120
120
  if (de(e))
121
121
  return (r = t.Seq) == null ? void 0 : r.call(t, s, e, n);
122
- if (E(e))
122
+ if (I(e))
123
123
  return (o = t.Pair) == null ? void 0 : o.call(t, s, e, n);
124
- if (A(e))
124
+ if (E(e))
125
125
  return (l = t.Scalar) == null ? void 0 : l.call(t, s, e, n);
126
126
  if (Z(e))
127
127
  return (a = t.Alias) == null ? void 0 : a.call(t, s, e, n);
128
128
  }
129
- function Rt(s, e, t) {
129
+ function Ft(s, e, t) {
130
130
  const n = e[e.length - 1];
131
- if (T(n))
131
+ if (L(n))
132
132
  n.items[s] = t;
133
- else if (E(n))
133
+ else if (I(n))
134
134
  s === "key" ? n.key = t : n.value = t;
135
135
  else if (ue(n))
136
136
  n.contents = t;
@@ -257,14 +257,14 @@ class B {
257
257
  }
258
258
  B.defaultYaml = { explicit: !1, version: "1.2" };
259
259
  B.defaultTags = { "!!": "tag:yaml.org,2002:" };
260
- function Vt(s) {
260
+ function Rt(s) {
261
261
  if (/[\x00-\x19\s,[\]{}]/.test(s)) {
262
262
  const t = `Anchor must not contain whitespace or control characters: ${JSON.stringify(s)}`;
263
263
  throw new Error(t);
264
264
  }
265
265
  return !0;
266
266
  }
267
- function Jt(s) {
267
+ function Vt(s) {
268
268
  const e = /* @__PURE__ */ new Set();
269
269
  return Y(s, {
270
270
  Value(t, n) {
@@ -284,7 +284,7 @@ function vs(s, e) {
284
284
  let i = null;
285
285
  return {
286
286
  onAnchor: (r) => {
287
- t.push(r), i || (i = Jt(s));
287
+ t.push(r), i || (i = Vt(s));
288
288
  const o = Yt(e, i);
289
289
  return i.add(o), o;
290
290
  },
@@ -296,7 +296,7 @@ function vs(s, e) {
296
296
  setAnchors: () => {
297
297
  for (const r of t) {
298
298
  const o = n.get(r);
299
- if (typeof o == "object" && o.anchor && (A(o.node) || T(o.node)))
299
+ if (typeof o == "object" && o.anchor && (E(o.node) || L(o.node)))
300
300
  o.node.anchor = o.anchor;
301
301
  else {
302
302
  const l = new Error("Failed to resolve repeated object (this should not happen)");
@@ -348,7 +348,7 @@ function D(s, e, t) {
348
348
  }
349
349
  class ht {
350
350
  constructor(e) {
351
- Object.defineProperty(this, K, { value: e });
351
+ Object.defineProperty(this, j, { value: e });
352
352
  }
353
353
  /** Create a copy of this node. */
354
354
  clone() {
@@ -373,7 +373,7 @@ class ht {
373
373
  return typeof r == "function" ? ie(r, { "": l }, "", l) : l;
374
374
  }
375
375
  }
376
- class Ke extends ht {
376
+ class qe extends ht {
377
377
  constructor(e) {
378
378
  super(ut), this.source = e, Object.defineProperty(this, "tag", {
379
379
  set() {
@@ -408,7 +408,7 @@ class Ke extends ht {
408
408
  const a = "This should not happen: Alias anchor was not resolved?";
409
409
  throw new ReferenceError(a);
410
410
  }
411
- if (r >= 0 && (l.count += 1, l.aliasCount === 0 && (l.aliasCount = $e(i, o, n)), l.count * l.aliasCount > r)) {
411
+ if (r >= 0 && (l.count += 1, l.aliasCount === 0 && (l.aliasCount = _e(i, o, n)), l.count * l.aliasCount > r)) {
412
412
  const a = "Excessive alias count indicates a resource exhaustion attack";
413
413
  throw new ReferenceError(a);
414
414
  }
@@ -417,7 +417,7 @@ class Ke extends ht {
417
417
  toString(e, t, n) {
418
418
  const i = `*${this.source}`;
419
419
  if (e) {
420
- if (Vt(this.source), e.options.verifyAliasOrder && !e.anchors.has(this.source)) {
420
+ if (Rt(this.source), e.options.verifyAliasOrder && !e.anchors.has(this.source)) {
421
421
  const r = `Unresolved alias (the anchor must be set before the alias): ${this.source}`;
422
422
  throw new Error(r);
423
423
  }
@@ -427,27 +427,27 @@ class Ke extends ht {
427
427
  return i;
428
428
  }
429
429
  }
430
- function $e(s, e, t) {
430
+ function _e(s, e, t) {
431
431
  if (Z(e)) {
432
432
  const n = e.resolve(s), i = t && n && t.get(n);
433
433
  return i ? i.count * i.aliasCount : 0;
434
- } else if (T(e)) {
434
+ } else if (L(e)) {
435
435
  let n = 0;
436
436
  for (const i of e.items) {
437
- const r = $e(s, i, t);
437
+ const r = _e(s, i, t);
438
438
  r > n && (n = r);
439
439
  }
440
440
  return n;
441
- } else if (E(e)) {
442
- const n = $e(s, e.key, t), i = $e(s, e.value, t);
441
+ } else if (I(e)) {
442
+ const n = _e(s, e.key, t), i = _e(s, e.value, t);
443
443
  return Math.max(n, i);
444
444
  }
445
445
  return 1;
446
446
  }
447
- const Gt = (s) => !s || typeof s != "function" && typeof s != "object";
448
- class N extends ht {
447
+ const Jt = (s) => !s || typeof s != "function" && typeof s != "object";
448
+ class O extends ht {
449
449
  constructor(e) {
450
- super(V), this.value = e;
450
+ super(R), this.value = e;
451
451
  }
452
452
  toJSON(e, t) {
453
453
  return t != null && t.keep ? this.value : D(this.value, e, t);
@@ -456,11 +456,11 @@ class N extends ht {
456
456
  return String(this.value);
457
457
  }
458
458
  }
459
- N.BLOCK_FOLDED = "BLOCK_FOLDED";
460
- N.BLOCK_LITERAL = "BLOCK_LITERAL";
461
- N.PLAIN = "PLAIN";
462
- N.QUOTE_DOUBLE = "QUOTE_DOUBLE";
463
- N.QUOTE_SINGLE = "QUOTE_SINGLE";
459
+ O.BLOCK_FOLDED = "BLOCK_FOLDED";
460
+ O.BLOCK_LITERAL = "BLOCK_LITERAL";
461
+ O.PLAIN = "PLAIN";
462
+ O.QUOTE_DOUBLE = "QUOTE_DOUBLE";
463
+ O.QUOTE_SINGLE = "QUOTE_SINGLE";
464
464
  const Bs = "tag:yaml.org,2002:";
465
465
  function Ms(s, e, t) {
466
466
  if (e) {
@@ -475,35 +475,35 @@ function Ms(s, e, t) {
475
475
  });
476
476
  }
477
477
  function Se(s, e, t) {
478
- var f, u, m;
478
+ var f, d, h;
479
479
  if (ue(s) && (s = s.contents), $(s))
480
480
  return s;
481
- if (E(s)) {
482
- const g = (u = (f = t.schema[J]).createNode) == null ? void 0 : u.call(f, t.schema, null, t);
483
- return g.items.push(s), g;
481
+ if (I(s)) {
482
+ const y = (d = (f = t.schema[V]).createNode) == null ? void 0 : d.call(f, t.schema, null, t);
483
+ return y.items.push(s), y;
484
484
  }
485
485
  (s instanceof String || s instanceof Number || s instanceof Boolean || typeof BigInt < "u" && s instanceof BigInt) && (s = s.valueOf());
486
486
  const { aliasDuplicateObjects: n, onAnchor: i, onTagObj: r, schema: o, sourceObjects: l } = t;
487
487
  let a;
488
488
  if (n && s && typeof s == "object") {
489
489
  if (a = l.get(s), a)
490
- return a.anchor || (a.anchor = i(s)), new Ke(a.anchor);
490
+ return a.anchor || (a.anchor = i(s)), new qe(a.anchor);
491
491
  a = { anchor: null, node: null }, l.set(s, a);
492
492
  }
493
493
  e != null && e.startsWith("!!") && (e = Bs + e.slice(2));
494
494
  let c = Ms(s, e, o.tags);
495
495
  if (!c) {
496
496
  if (s && typeof s.toJSON == "function" && (s = s.toJSON()), !s || typeof s != "object") {
497
- const g = new N(s);
498
- return a && (a.node = g), g;
497
+ const y = new O(s);
498
+ return a && (a.node = y), y;
499
499
  }
500
- c = s instanceof Map ? o[J] : Symbol.iterator in Object(s) ? o[fe] : o[J];
500
+ c = s instanceof Map ? o[V] : Symbol.iterator in Object(s) ? o[fe] : o[V];
501
501
  }
502
502
  r && (r(c), delete t.onTagObj);
503
- const p = c != null && c.createNode ? c.createNode(t.schema, s, t) : typeof ((m = c == null ? void 0 : c.nodeClass) == null ? void 0 : m.from) == "function" ? c.nodeClass.from(t.schema, s, t) : new N(s);
504
- return e ? p.tag = e : c.default || (p.tag = c.tag), a && (a.node = p), p;
503
+ const m = c != null && c.createNode ? c.createNode(t.schema, s, t) : typeof ((h = c == null ? void 0 : c.nodeClass) == null ? void 0 : h.from) == "function" ? c.nodeClass.from(t.schema, s, t) : new O(s);
504
+ return e ? m.tag = e : c.default || (m.tag = c.tag), a && (a.node = m), m;
505
505
  }
506
- function Be(s, e, t) {
506
+ function Me(s, e, t) {
507
507
  let n = t;
508
508
  for (let i = e.length - 1; i >= 0; --i) {
509
509
  const r = e[i];
@@ -524,7 +524,7 @@ function Be(s, e, t) {
524
524
  });
525
525
  }
526
526
  const be = (s) => s == null || typeof s == "object" && !!s[Symbol.iterator]().next().done;
527
- class dt extends ht {
527
+ class Gt extends ht {
528
528
  constructor(e, t) {
529
529
  super(e), Object.defineProperty(this, "schema", {
530
530
  value: t,
@@ -540,7 +540,7 @@ class dt extends ht {
540
540
  */
541
541
  clone(e) {
542
542
  const t = Object.create(Object.getPrototypeOf(this), Object.getOwnPropertyDescriptors(this));
543
- return e && (t.schema = e), t.items = t.items.map((n) => $(n) || E(n) ? n.clone(e) : n), this.range && (t.range = this.range.slice()), t;
543
+ return e && (t.schema = e), t.items = t.items.map((n) => $(n) || I(n) ? n.clone(e) : n), this.range && (t.range = this.range.slice()), t;
544
544
  }
545
545
  /**
546
546
  * Adds a value to the collection. For `!!map` and `!!omap` the value must
@@ -552,10 +552,10 @@ class dt extends ht {
552
552
  this.add(t);
553
553
  else {
554
554
  const [n, ...i] = e, r = this.get(n, !0);
555
- if (T(r))
555
+ if (L(r))
556
556
  r.addIn(i, t);
557
557
  else if (r === void 0 && this.schema)
558
- this.set(n, Be(this.schema, i, t));
558
+ this.set(n, Me(this.schema, i, t));
559
559
  else
560
560
  throw new Error(`Expected YAML collection at ${n}. Remaining path: ${i}`);
561
561
  }
@@ -569,7 +569,7 @@ class dt extends ht {
569
569
  if (n.length === 0)
570
570
  return this.delete(t);
571
571
  const i = this.get(t, !0);
572
- if (T(i))
572
+ if (L(i))
573
573
  return i.deleteIn(n);
574
574
  throw new Error(`Expected YAML collection at ${t}. Remaining path: ${n}`);
575
575
  }
@@ -580,14 +580,14 @@ class dt extends ht {
580
580
  */
581
581
  getIn(e, t) {
582
582
  const [n, ...i] = e, r = this.get(n, !0);
583
- return i.length === 0 ? !t && A(r) ? r.value : r : T(r) ? r.getIn(i, t) : void 0;
583
+ return i.length === 0 ? !t && E(r) ? r.value : r : L(r) ? r.getIn(i, t) : void 0;
584
584
  }
585
585
  hasAllNullValues(e) {
586
586
  return this.items.every((t) => {
587
- if (!E(t))
587
+ if (!I(t))
588
588
  return !1;
589
589
  const n = t.value;
590
- return n == null || e && A(n) && n.value == null && !n.commentBefore && !n.comment && !n.tag;
590
+ return n == null || e && E(n) && n.value == null && !n.commentBefore && !n.comment && !n.tag;
591
591
  });
592
592
  }
593
593
  /**
@@ -598,7 +598,7 @@ class dt extends ht {
598
598
  if (n.length === 0)
599
599
  return this.has(t);
600
600
  const i = this.get(t, !0);
601
- return T(i) ? i.hasIn(n) : !1;
601
+ return L(i) ? i.hasIn(n) : !1;
602
602
  }
603
603
  /**
604
604
  * Sets a value in this collection. For `!!set`, `value` needs to be a
@@ -610,90 +610,90 @@ class dt extends ht {
610
610
  this.set(n, t);
611
611
  else {
612
612
  const r = this.get(n, !0);
613
- if (T(r))
613
+ if (L(r))
614
614
  r.setIn(i, t);
615
615
  else if (r === void 0 && this.schema)
616
- this.set(n, Be(this.schema, i, t));
616
+ this.set(n, Me(this.schema, i, t));
617
617
  else
618
618
  throw new Error(`Expected YAML collection at ${n}. Remaining path: ${i}`);
619
619
  }
620
620
  }
621
621
  }
622
- dt.maxFlowStringSingleLineLength = 60;
623
622
  const Ps = (s) => s.replace(/^(?!$)(?: $)?/gm, "#");
624
- function R(s, e) {
623
+ function F(s, e) {
625
624
  return /^\n+$/.test(s) ? s.substring(1) : e ? s.replace(/^(?! *$)/gm, e) : s;
626
625
  }
627
626
  const W = (s, e, t) => s.endsWith(`
628
- `) ? R(t, e) : t.includes(`
627
+ `) ? F(t, e) : t.includes(`
629
628
  `) ? `
630
- ` + R(t, e) : (s.endsWith(" ") ? "" : " ") + t, Qt = "flow", ot = "block", _e = "quoted";
631
- function qe(s, e, t = "flow", { indentAtStart: n, lineWidth: i = 80, minContentWidth: r = 20, onFold: o, onOverflow: l } = {}) {
629
+ ` + F(t, e) : (s.endsWith(" ") ? "" : " ") + t, Qt = "flow", ot = "block", Ce = "quoted";
630
+ function Ue(s, e, t = "flow", { indentAtStart: n, lineWidth: i = 80, minContentWidth: r = 20, onFold: o, onOverflow: l } = {}) {
632
631
  if (!i || i < 0)
633
632
  return s;
633
+ i < r && (r = 0);
634
634
  const a = Math.max(1 + r, 1 + i - e.length);
635
635
  if (s.length <= a)
636
636
  return s;
637
- const c = [], p = {};
637
+ const c = [], m = {};
638
638
  let f = i - e.length;
639
639
  typeof n == "number" && (n > i - Math.max(2, r) ? c.push(0) : f = i - n);
640
- let u, m, g = !1, h = -1, d = -1, b = -1;
641
- t === ot && (h = Tt(s, h, e.length), h !== -1 && (f = h + a));
642
- for (let k; k = s[h += 1]; ) {
643
- if (t === _e && k === "\\") {
644
- switch (d = h, s[h + 1]) {
640
+ let d, h, y = !1, u = -1, p = -1, g = -1;
641
+ t === ot && (u = It(s, u, e.length), u !== -1 && (f = u + a));
642
+ for (let N; N = s[u += 1]; ) {
643
+ if (t === Ce && N === "\\") {
644
+ switch (p = u, s[u + 1]) {
645
645
  case "x":
646
- h += 3;
646
+ u += 3;
647
647
  break;
648
648
  case "u":
649
- h += 5;
649
+ u += 5;
650
650
  break;
651
651
  case "U":
652
- h += 9;
652
+ u += 9;
653
653
  break;
654
654
  default:
655
- h += 1;
655
+ u += 1;
656
656
  }
657
- b = h;
657
+ g = u;
658
658
  }
659
- if (k === `
659
+ if (N === `
660
660
  `)
661
- t === ot && (h = Tt(s, h, e.length)), f = h + e.length + a, u = void 0;
661
+ t === ot && (u = It(s, u, e.length)), f = u + e.length + a, d = void 0;
662
662
  else {
663
- if (k === " " && m && m !== " " && m !== `
664
- ` && m !== " ") {
665
- const S = s[h + 1];
663
+ if (N === " " && h && h !== " " && h !== `
664
+ ` && h !== " ") {
665
+ const S = s[u + 1];
666
666
  S && S !== " " && S !== `
667
- ` && S !== " " && (u = h);
667
+ ` && S !== " " && (d = u);
668
668
  }
669
- if (h >= f)
670
- if (u)
671
- c.push(u), f = u + a, u = void 0;
672
- else if (t === _e) {
673
- for (; m === " " || m === " "; )
674
- m = k, k = s[h += 1], g = !0;
675
- const S = h > b + 1 ? h - 2 : d - 1;
676
- if (p[S])
669
+ if (u >= f)
670
+ if (d)
671
+ c.push(d), f = d + a, d = void 0;
672
+ else if (t === Ce) {
673
+ for (; h === " " || h === " "; )
674
+ h = N, N = s[u += 1], y = !0;
675
+ const S = u > g + 1 ? u - 2 : p - 1;
676
+ if (m[S])
677
677
  return s;
678
- c.push(S), p[S] = !0, f = S + a, u = void 0;
678
+ c.push(S), m[S] = !0, f = S + a, d = void 0;
679
679
  } else
680
- g = !0;
680
+ y = !0;
681
681
  }
682
- m = k;
682
+ h = N;
683
683
  }
684
- if (g && l && l(), c.length === 0)
684
+ if (y && l && l(), c.length === 0)
685
685
  return s;
686
686
  o && o();
687
687
  let w = s.slice(0, c[0]);
688
- for (let k = 0; k < c.length; ++k) {
689
- const S = c[k], O = c[k + 1] || s.length;
688
+ for (let N = 0; N < c.length; ++N) {
689
+ const S = c[N], A = c[N + 1] || s.length;
690
690
  S === 0 ? w = `
691
- ${e}${s.slice(0, O)}` : (t === _e && p[S] && (w += `${s[S]}\\`), w += `
692
- ${e}${s.slice(S + 1, O)}`);
691
+ ${e}${s.slice(0, A)}` : (t === Ce && m[S] && (w += `${s[S]}\\`), w += `
692
+ ${e}${s.slice(S + 1, A)}`);
693
693
  }
694
694
  return w;
695
695
  }
696
- function Tt(s, e, t) {
696
+ function It(s, e, t) {
697
697
  let n = e, i = e + 1, r = s[i];
698
698
  for (; r === " " || r === " "; )
699
699
  if (e < i + t)
@@ -711,8 +711,8 @@ const Fe = (s, e) => ({
711
711
  indentAtStart: e ? s.indent.length : s.indentAtStart,
712
712
  lineWidth: s.options.lineWidth,
713
713
  minContentWidth: s.options.minContentWidth
714
- }), Ue = (s) => /^(%|---|\.\.\.)/m.test(s);
715
- function js(s, e, t) {
714
+ }), Re = (s) => /^(%|---|\.\.\.)/m.test(s);
715
+ function Ds(s, e, t) {
716
716
  if (!e || e < 0)
717
717
  return !1;
718
718
  const n = e - t, i = s.length;
@@ -732,7 +732,7 @@ function we(s, e) {
732
732
  const t = JSON.stringify(s);
733
733
  if (e.options.doubleQuotedAsJSON)
734
734
  return t;
735
- const { implicitKey: n } = e, i = e.options.doubleQuotedMinMultiLineLength, r = e.indent || (Ue(s) ? " " : "");
735
+ const { implicitKey: n } = e, i = e.options.doubleQuotedMinMultiLineLength, r = e.indent || (Re(s) ? " " : "");
736
736
  let o = "", l = 0;
737
737
  for (let a = 0, c = t[a]; c; c = t[++a])
738
738
  if (c === " " && t[a + 1] === "\\" && t[a + 2] === "n" && (o += t.slice(l, a) + "\\ ", a += 1, l = a, c = "\\"), c === "\\")
@@ -740,8 +740,8 @@ function we(s, e) {
740
740
  case "u":
741
741
  {
742
742
  o += t.slice(l, a);
743
- const p = t.substr(a + 2, 4);
744
- switch (p) {
743
+ const m = t.substr(a + 2, 4);
744
+ switch (m) {
745
745
  case "0000":
746
746
  o += "\\0";
747
747
  break;
@@ -767,7 +767,7 @@ function we(s, e) {
767
767
  o += "\\P";
768
768
  break;
769
769
  default:
770
- p.substr(0, 2) === "00" ? o += "\\x" + p.substr(2) : o += t.substr(a, 6);
770
+ m.substr(0, 2) === "00" ? o += "\\x" + m.substr(2) : o += t.substr(a, 6);
771
771
  }
772
772
  a += 5, l = a + 1;
773
773
  }
@@ -787,15 +787,15 @@ function we(s, e) {
787
787
  default:
788
788
  a += 1;
789
789
  }
790
- return o = l ? o + t.slice(l) : t, n ? o : qe(o, r, _e, Fe(e, !1));
790
+ return o = l ? o + t.slice(l) : t, n ? o : Ue(o, r, Ce, Fe(e, !1));
791
791
  }
792
792
  function lt(s, e) {
793
793
  if (e.options.singleQuote === !1 || e.implicitKey && s.includes(`
794
794
  `) || /[ \t]\n|\n[ \t]/.test(s))
795
795
  return we(s, e);
796
- const t = e.indent || (Ue(s) ? " " : ""), n = "'" + s.replace(/'/g, "''").replace(/\n+/g, `$&
796
+ const t = e.indent || (Re(s) ? " " : ""), n = "'" + s.replace(/'/g, "''").replace(/\n+/g, `$&
797
797
  ${t}`) + "'";
798
- return e.implicitKey ? n : qe(n, t, Qt, Fe(e, !1));
798
+ return e.implicitKey ? n : Ue(n, t, Qt, Fe(e, !1));
799
799
  }
800
800
  function re(s, e) {
801
801
  const { singleQuote: t } = e.options;
@@ -817,103 +817,103 @@ try {
817
817
  } catch {
818
818
  at = /\n+(?!\n|$)/g;
819
819
  }
820
- function Ce({ comment: s, type: e, value: t }, n, i, r) {
820
+ function ve({ comment: s, type: e, value: t }, n, i, r) {
821
821
  const { blockQuote: o, commentString: l, lineWidth: a } = n.options;
822
822
  if (!o || /\n[\t ]+$/.test(t) || /^\s*$/.test(t))
823
823
  return re(t, n);
824
- const c = n.indent || (n.forceBlockIndent || Ue(t) ? " " : ""), p = o === "literal" ? !0 : o === "folded" || e === N.BLOCK_FOLDED ? !1 : e === N.BLOCK_LITERAL ? !0 : !js(t, a, c.length);
824
+ const c = n.indent || (n.forceBlockIndent || Re(t) ? " " : ""), m = o === "literal" ? !0 : o === "folded" || e === O.BLOCK_FOLDED ? !1 : e === O.BLOCK_LITERAL ? !0 : !Ds(t, a, c.length);
825
825
  if (!t)
826
- return p ? `|
826
+ return m ? `|
827
827
  ` : `>
828
828
  `;
829
- let f, u;
830
- for (u = t.length; u > 0; --u) {
831
- const y = t[u - 1];
832
- if (y !== `
833
- ` && y !== " " && y !== " ")
829
+ let f, d;
830
+ for (d = t.length; d > 0; --d) {
831
+ const k = t[d - 1];
832
+ if (k !== `
833
+ ` && k !== " " && k !== " ")
834
834
  break;
835
835
  }
836
- let m = t.substring(u);
837
- const g = m.indexOf(`
836
+ let h = t.substring(d);
837
+ const y = h.indexOf(`
838
838
  `);
839
- g === -1 ? f = "-" : t === m || g !== m.length - 1 ? (f = "+", r && r()) : f = "", m && (t = t.slice(0, -m.length), m[m.length - 1] === `
840
- ` && (m = m.slice(0, -1)), m = m.replace(at, `$&${c}`));
841
- let h = !1, d, b = -1;
842
- for (d = 0; d < t.length; ++d) {
843
- const y = t[d];
844
- if (y === " ")
845
- h = !0;
846
- else if (y === `
839
+ y === -1 ? f = "-" : t === h || y !== h.length - 1 ? (f = "+", r && r()) : f = "", h && (t = t.slice(0, -h.length), h[h.length - 1] === `
840
+ ` && (h = h.slice(0, -1)), h = h.replace(at, `$&${c}`));
841
+ let u = !1, p, g = -1;
842
+ for (p = 0; p < t.length; ++p) {
843
+ const k = t[p];
844
+ if (k === " ")
845
+ u = !0;
846
+ else if (k === `
847
847
  `)
848
- b = d;
848
+ g = p;
849
849
  else
850
850
  break;
851
851
  }
852
- let w = t.substring(0, b < d ? b + 1 : d);
852
+ let w = t.substring(0, g < p ? g + 1 : p);
853
853
  w && (t = t.substring(w.length), w = w.replace(/\n+/g, `$&${c}`));
854
- let S = (p ? "|" : ">") + (h ? c ? "2" : "1" : "") + f;
855
- if (s && (S += " " + l(s.replace(/ ?[\r\n]+/g, " ")), i && i()), p)
854
+ let S = (m ? "|" : ">") + (u ? c ? "2" : "1" : "") + f;
855
+ if (s && (S += " " + l(s.replace(/ ?[\r\n]+/g, " ")), i && i()), m)
856
856
  return t = t.replace(/\n+/g, `$&${c}`), `${S}
857
- ${c}${w}${t}${m}`;
857
+ ${c}${w}${t}${h}`;
858
858
  t = t.replace(/\n+/g, `
859
859
  $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g, "$1$2").replace(/\n+/g, `$&${c}`);
860
- const O = qe(`${w}${t}${m}`, c, ot, Fe(n, !0));
860
+ const A = Ue(`${w}${t}${h}`, c, ot, Fe(n, !0));
861
861
  return `${S}
862
- ${c}${O}`;
862
+ ${c}${A}`;
863
863
  }
864
- function Ds(s, e, t, n) {
865
- const { type: i, value: r } = s, { actualString: o, implicitKey: l, indent: a, indentStep: c, inFlow: p } = e;
864
+ function js(s, e, t, n) {
865
+ const { type: i, value: r } = s, { actualString: o, implicitKey: l, indent: a, indentStep: c, inFlow: m } = e;
866
866
  if (l && r.includes(`
867
- `) || p && /[[\]{},]/.test(r))
867
+ `) || m && /[[\]{},]/.test(r))
868
868
  return re(r, e);
869
869
  if (!r || /^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(r))
870
- return l || p || !r.includes(`
871
- `) ? re(r, e) : Ce(s, e, t, n);
872
- if (!l && !p && i !== N.PLAIN && r.includes(`
870
+ return l || m || !r.includes(`
871
+ `) ? re(r, e) : ve(s, e, t, n);
872
+ if (!l && !m && i !== O.PLAIN && r.includes(`
873
873
  `))
874
- return Ce(s, e, t, n);
875
- if (Ue(r)) {
874
+ return ve(s, e, t, n);
875
+ if (Re(r)) {
876
876
  if (a === "")
877
- return e.forceBlockIndent = !0, Ce(s, e, t, n);
877
+ return e.forceBlockIndent = !0, ve(s, e, t, n);
878
878
  if (l && a === c)
879
879
  return re(r, e);
880
880
  }
881
881
  const f = r.replace(/\n+/g, `$&
882
882
  ${a}`);
883
883
  if (o) {
884
- const u = (h) => {
885
- var d;
886
- return h.default && h.tag !== "tag:yaml.org,2002:str" && ((d = h.test) == null ? void 0 : d.test(f));
887
- }, { compat: m, tags: g } = e.doc.schema;
888
- if (g.some(u) || m != null && m.some(u))
884
+ const d = (u) => {
885
+ var p;
886
+ return u.default && u.tag !== "tag:yaml.org,2002:str" && ((p = u.test) == null ? void 0 : p.test(f));
887
+ }, { compat: h, tags: y } = e.doc.schema;
888
+ if (y.some(d) || h != null && h.some(d))
889
889
  return re(r, e);
890
890
  }
891
- return l ? f : qe(f, a, Qt, Fe(e, !1));
891
+ return l ? f : Ue(f, a, Qt, Fe(e, !1));
892
892
  }
893
893
  function Oe(s, e, t, n) {
894
894
  const { implicitKey: i, inFlow: r } = e, o = typeof s.value == "string" ? s : Object.assign({}, s, { value: String(s.value) });
895
895
  let { type: l } = s;
896
- l !== N.QUOTE_DOUBLE && /[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value) && (l = N.QUOTE_DOUBLE);
897
- const a = (p) => {
898
- switch (p) {
899
- case N.BLOCK_FOLDED:
900
- case N.BLOCK_LITERAL:
901
- return i || r ? re(o.value, e) : Ce(o, e, t, n);
902
- case N.QUOTE_DOUBLE:
896
+ l !== O.QUOTE_DOUBLE && /[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value) && (l = O.QUOTE_DOUBLE);
897
+ const a = (m) => {
898
+ switch (m) {
899
+ case O.BLOCK_FOLDED:
900
+ case O.BLOCK_LITERAL:
901
+ return i || r ? re(o.value, e) : ve(o, e, t, n);
902
+ case O.QUOTE_DOUBLE:
903
903
  return we(o.value, e);
904
- case N.QUOTE_SINGLE:
904
+ case O.QUOTE_SINGLE:
905
905
  return lt(o.value, e);
906
- case N.PLAIN:
907
- return Ds(o, e, t, n);
906
+ case O.PLAIN:
907
+ return js(o, e, t, n);
908
908
  default:
909
909
  return null;
910
910
  }
911
911
  };
912
912
  let c = a(l);
913
913
  if (c === null) {
914
- const { defaultKeyType: p, defaultStringType: f } = e.options, u = i && p || f;
915
- if (c = a(u), c === null)
916
- throw new Error(`Unsupported default string type ${u}`);
914
+ const { defaultKeyType: m, defaultStringType: f } = e.options, d = i && m || f;
915
+ if (c = a(d), c === null)
916
+ throw new Error(`Unsupported default string type ${d}`);
917
917
  }
918
918
  return c;
919
919
  }
@@ -966,7 +966,7 @@ function Ks(s, e) {
966
966
  return r.find((o) => o.format === e.format) ?? r[0];
967
967
  }
968
968
  let t, n;
969
- if (A(e)) {
969
+ if (E(e)) {
970
970
  n = e.value;
971
971
  const r = s.filter((o) => {
972
972
  var l;
@@ -984,14 +984,14 @@ function Ks(s, e) {
984
984
  function qs(s, e, { anchors: t, doc: n }) {
985
985
  if (!n.directives)
986
986
  return "";
987
- const i = [], r = (A(s) || T(s)) && s.anchor;
988
- r && Vt(r) && (t.add(r), i.push(`&${r}`));
987
+ const i = [], r = (E(s) || L(s)) && s.anchor;
988
+ r && Rt(r) && (t.add(r), i.push(`&${r}`));
989
989
  const o = s.tag ? s.tag : e.default ? null : e.tag;
990
990
  return o && i.push(n.directives.tagString(o)), i.join(" ");
991
991
  }
992
992
  function ae(s, e, t, n) {
993
993
  var a;
994
- if (E(s))
994
+ if (I(s))
995
995
  return s.toString(e, t, n);
996
996
  if (Z(s)) {
997
997
  if (e.doc.directives)
@@ -1005,87 +1005,87 @@ function ae(s, e, t, n) {
1005
1005
  i || (i = Ks(e.doc.schema.tags, r));
1006
1006
  const o = qs(r, i, e);
1007
1007
  o.length > 0 && (e.indentAtStart = (e.indentAtStart ?? 0) + o.length + 1);
1008
- const l = typeof i.stringify == "function" ? i.stringify(r, e, t, n) : A(r) ? Oe(r, e, t, n) : r.toString(e, t, n);
1009
- return o ? A(r) || l[0] === "{" || l[0] === "[" ? `${o} ${l}` : `${o}
1008
+ const l = typeof i.stringify == "function" ? i.stringify(r, e, t, n) : E(r) ? Oe(r, e, t, n) : r.toString(e, t, n);
1009
+ return o ? E(r) || l[0] === "{" || l[0] === "[" ? `${o} ${l}` : `${o}
1010
1010
  ${e.indent}${l}` : l;
1011
1011
  }
1012
- function Fs({ key: s, value: e }, t, n, i) {
1013
- const { allNullValues: r, doc: o, indent: l, indentStep: a, options: { commentString: c, indentSeq: p, simpleKeys: f } } = t;
1014
- let u = $(s) && s.comment || null;
1012
+ function Us({ key: s, value: e }, t, n, i) {
1013
+ const { allNullValues: r, doc: o, indent: l, indentStep: a, options: { commentString: c, indentSeq: m, simpleKeys: f } } = t;
1014
+ let d = $(s) && s.comment || null;
1015
1015
  if (f) {
1016
- if (u)
1016
+ if (d)
1017
1017
  throw new Error("With simple keys, key nodes cannot have comments");
1018
- if (T(s)) {
1019
- const I = "With simple keys, collection cannot be used as a key value";
1020
- throw new Error(I);
1018
+ if (L(s) || !$(s) && typeof s == "object") {
1019
+ const T = "With simple keys, collection cannot be used as a key value";
1020
+ throw new Error(T);
1021
1021
  }
1022
1022
  }
1023
- let m = !f && (!s || u && e == null && !t.inFlow || T(s) || (A(s) ? s.type === N.BLOCK_FOLDED || s.type === N.BLOCK_LITERAL : typeof s == "object"));
1023
+ let h = !f && (!s || d && e == null && !t.inFlow || L(s) || (E(s) ? s.type === O.BLOCK_FOLDED || s.type === O.BLOCK_LITERAL : typeof s == "object"));
1024
1024
  t = Object.assign({}, t, {
1025
1025
  allNullValues: !1,
1026
- implicitKey: !m && (f || !r),
1026
+ implicitKey: !h && (f || !r),
1027
1027
  indent: l + a
1028
1028
  });
1029
- let g = !1, h = !1, d = ae(s, t, () => g = !0, () => h = !0);
1030
- if (!m && !t.inFlow && d.length > 1024) {
1029
+ let y = !1, u = !1, p = ae(s, t, () => y = !0, () => u = !0);
1030
+ if (!h && !t.inFlow && p.length > 1024) {
1031
1031
  if (f)
1032
1032
  throw new Error("With simple keys, single line scalar must not span more than 1024 characters");
1033
- m = !0;
1033
+ h = !0;
1034
1034
  }
1035
1035
  if (t.inFlow) {
1036
1036
  if (r || e == null)
1037
- return g && n && n(), d === "" ? "?" : m ? `? ${d}` : d;
1038
- } else if (r && !f || e == null && m)
1039
- return d = `? ${d}`, u && !g ? d += W(d, t.indent, c(u)) : h && i && i(), d;
1040
- g && (u = null), m ? (u && (d += W(d, t.indent, c(u))), d = `? ${d}
1041
- ${l}:`) : (d = `${d}:`, u && (d += W(d, t.indent, c(u))));
1042
- let b, w, k;
1043
- $(e) ? (b = !!e.spaceBefore, w = e.commentBefore, k = e.comment) : (b = !1, w = null, k = null, e && typeof e == "object" && (e = o.createNode(e))), t.implicitKey = !1, !m && !u && A(e) && (t.indentAtStart = d.length + 1), h = !1, !p && a.length >= 2 && !t.inFlow && !m && de(e) && !e.flow && !e.tag && !e.anchor && (t.indent = t.indent.substring(2));
1037
+ return y && n && n(), p === "" ? "?" : h ? `? ${p}` : p;
1038
+ } else if (r && !f || e == null && h)
1039
+ return p = `? ${p}`, d && !y ? p += W(p, t.indent, c(d)) : u && i && i(), p;
1040
+ y && (d = null), h ? (d && (p += W(p, t.indent, c(d))), p = `? ${p}
1041
+ ${l}:`) : (p = `${p}:`, d && (p += W(p, t.indent, c(d))));
1042
+ let g, w, N;
1043
+ $(e) ? (g = !!e.spaceBefore, w = e.commentBefore, N = e.comment) : (g = !1, w = null, N = null, e && typeof e == "object" && (e = o.createNode(e))), t.implicitKey = !1, !h && !d && E(e) && (t.indentAtStart = p.length + 1), u = !1, !m && a.length >= 2 && !t.inFlow && !h && de(e) && !e.flow && !e.tag && !e.anchor && (t.indent = t.indent.substring(2));
1044
1044
  let S = !1;
1045
- const O = ae(e, t, () => S = !0, () => h = !0);
1046
- let y = " ";
1047
- if (u || b || w) {
1048
- if (y = b ? `
1045
+ const A = ae(e, t, () => S = !0, () => u = !0);
1046
+ let k = " ";
1047
+ if (d || g || w) {
1048
+ if (k = g ? `
1049
1049
  ` : "", w) {
1050
- const I = c(w);
1051
- y += `
1052
- ${R(I, t.indent)}`;
1050
+ const T = c(w);
1051
+ k += `
1052
+ ${F(T, t.indent)}`;
1053
1053
  }
1054
- O === "" && !t.inFlow ? y === `
1055
- ` && (y = `
1054
+ A === "" && !t.inFlow ? k === `
1055
+ ` && (k = `
1056
1056
 
1057
- `) : y += `
1057
+ `) : k += `
1058
1058
  ${t.indent}`;
1059
- } else if (!m && T(e)) {
1060
- const I = O[0], L = O.indexOf(`
1061
- `), C = L !== -1, Q = t.inFlow ?? e.flow ?? e.items.length === 0;
1062
- if (C || !Q) {
1059
+ } else if (!h && L(e)) {
1060
+ const T = A[0], b = A.indexOf(`
1061
+ `), _ = b !== -1, G = t.inFlow ?? e.flow ?? e.items.length === 0;
1062
+ if (_ || !G) {
1063
1063
  let x = !1;
1064
- if (C && (I === "&" || I === "!")) {
1065
- let _ = O.indexOf(" ");
1066
- I === "&" && _ !== -1 && _ < L && O[_ + 1] === "!" && (_ = O.indexOf(" ", _ + 1)), (_ === -1 || L < _) && (x = !0);
1064
+ if (_ && (T === "&" || T === "!")) {
1065
+ let C = A.indexOf(" ");
1066
+ T === "&" && C !== -1 && C < b && A[C + 1] === "!" && (C = A.indexOf(" ", C + 1)), (C === -1 || b < C) && (x = !0);
1067
1067
  }
1068
- x || (y = `
1068
+ x || (k = `
1069
1069
  ${t.indent}`);
1070
1070
  }
1071
- } else (O === "" || O[0] === `
1072
- `) && (y = "");
1073
- return d += y + O, t.inFlow ? S && n && n() : k && !S ? d += W(d, t.indent, c(k)) : h && i && i(), d;
1071
+ } else (A === "" || A[0] === `
1072
+ `) && (k = "");
1073
+ return p += k + A, t.inFlow ? S && n && n() : N && !S ? p += W(p, t.indent, c(N)) : u && i && i(), p;
1074
1074
  }
1075
1075
  function Ht(s, e) {
1076
1076
  (s === "debug" || s === "warn") && (typeof process < "u" && process.emitWarning ? process.emitWarning(e) : console.warn(e));
1077
1077
  }
1078
- const Lt = "<<";
1078
+ const Tt = "<<";
1079
1079
  function Xt(s, e, { key: t, value: n }) {
1080
- if (s != null && s.doc.schema.merge && Us(t))
1080
+ if (s != null && s.doc.schema.merge && Fs(t))
1081
1081
  if (n = Z(n) ? n.resolve(s.doc) : n, de(n))
1082
1082
  for (const i of n.items)
1083
- ze(s, e, i);
1083
+ Ze(s, e, i);
1084
1084
  else if (Array.isArray(n))
1085
1085
  for (const i of n)
1086
- ze(s, e, i);
1086
+ Ze(s, e, i);
1087
1087
  else
1088
- ze(s, e, n);
1088
+ Ze(s, e, n);
1089
1089
  else {
1090
1090
  const i = D(t, "", s);
1091
1091
  if (e instanceof Map)
@@ -1104,8 +1104,8 @@ function Xt(s, e, { key: t, value: n }) {
1104
1104
  }
1105
1105
  return e;
1106
1106
  }
1107
- const Us = (s) => s === Lt || A(s) && s.value === Lt && (!s.type || s.type === N.PLAIN);
1108
- function ze(s, e, t) {
1107
+ const Fs = (s) => s === Tt || E(s) && s.value === Tt && (!s.type || s.type === O.PLAIN);
1108
+ function Ze(s, e, t) {
1109
1109
  const n = s && Z(t) ? t.resolve(s.doc) : t;
1110
1110
  if (!he(n))
1111
1111
  throw new Error("Merge sources must be maps or map aliases");
@@ -1139,13 +1139,13 @@ function Rs(s, e, t) {
1139
1139
  }
1140
1140
  return JSON.stringify(e);
1141
1141
  }
1142
- function pt(s, e, t) {
1142
+ function dt(s, e, t) {
1143
1143
  const n = Se(s, void 0, t), i = Se(e, void 0, t);
1144
1144
  return new v(n, i);
1145
1145
  }
1146
1146
  class v {
1147
1147
  constructor(e, t = null) {
1148
- Object.defineProperty(this, K, { value: Kt }), this.key = e, this.value = t;
1148
+ Object.defineProperty(this, j, { value: jt }), this.key = e, this.value = t;
1149
1149
  }
1150
1150
  clone(e) {
1151
1151
  let { key: t, value: n } = this;
@@ -1156,45 +1156,45 @@ class v {
1156
1156
  return Xt(t, n, this);
1157
1157
  }
1158
1158
  toString(e, t, n) {
1159
- return e != null && e.doc ? Fs(this, e, t, n) : JSON.stringify(this);
1159
+ return e != null && e.doc ? Us(this, e, t, n) : JSON.stringify(this);
1160
1160
  }
1161
1161
  }
1162
1162
  function zt(s, e, t) {
1163
- return (e.inFlow ?? s.flow ? Js : Vs)(s, e, t);
1163
+ return (e.inFlow ?? s.flow ? Ys : Vs)(s, e, t);
1164
1164
  }
1165
1165
  function Vs({ comment: s, items: e }, t, { blockItemPrefix: n, flowChars: i, itemIndent: r, onChompKeep: o, onComment: l }) {
1166
- const { indent: a, options: { commentString: c } } = t, p = Object.assign({}, t, { indent: r, type: null });
1166
+ const { indent: a, options: { commentString: c } } = t, m = Object.assign({}, t, { indent: r, type: null });
1167
1167
  let f = !1;
1168
- const u = [];
1169
- for (let g = 0; g < e.length; ++g) {
1170
- const h = e[g];
1171
- let d = null;
1172
- if ($(h))
1173
- !f && h.spaceBefore && u.push(""), Me(t, u, h.commentBefore, f), h.comment && (d = h.comment);
1174
- else if (E(h)) {
1175
- const w = $(h.key) ? h.key : null;
1176
- w && (!f && w.spaceBefore && u.push(""), Me(t, u, w.commentBefore, f));
1168
+ const d = [];
1169
+ for (let y = 0; y < e.length; ++y) {
1170
+ const u = e[y];
1171
+ let p = null;
1172
+ if ($(u))
1173
+ !f && u.spaceBefore && d.push(""), Pe(t, d, u.commentBefore, f), u.comment && (p = u.comment);
1174
+ else if (I(u)) {
1175
+ const w = $(u.key) ? u.key : null;
1176
+ w && (!f && w.spaceBefore && d.push(""), Pe(t, d, w.commentBefore, f));
1177
1177
  }
1178
1178
  f = !1;
1179
- let b = ae(h, p, () => d = null, () => f = !0);
1180
- d && (b += W(b, r, c(d))), f && d && (f = !1), u.push(n + b);
1179
+ let g = ae(u, m, () => p = null, () => f = !0);
1180
+ p && (g += W(g, r, c(p))), f && p && (f = !1), d.push(n + g);
1181
1181
  }
1182
- let m;
1183
- if (u.length === 0)
1184
- m = i.start + i.end;
1182
+ let h;
1183
+ if (d.length === 0)
1184
+ h = i.start + i.end;
1185
1185
  else {
1186
- m = u[0];
1187
- for (let g = 1; g < u.length; ++g) {
1188
- const h = u[g];
1189
- m += h ? `
1190
- ${a}${h}` : `
1186
+ h = d[0];
1187
+ for (let y = 1; y < d.length; ++y) {
1188
+ const u = d[y];
1189
+ h += u ? `
1190
+ ${a}${u}` : `
1191
1191
  `;
1192
1192
  }
1193
1193
  }
1194
- return s ? (m += `
1195
- ` + R(c(s), a), l && l()) : f && o && o(), m;
1194
+ return s ? (h += `
1195
+ ` + F(c(s), a), l && l()) : f && o && o(), h;
1196
1196
  }
1197
- function Js({ items: s }, e, { flowChars: t, itemIndent: n }) {
1197
+ function Ys({ items: s }, e, { flowChars: t, itemIndent: n }) {
1198
1198
  const { indent: i, indentStep: r, flowCollectionPadding: o, options: { commentString: l } } = e;
1199
1199
  n += r;
1200
1200
  const a = Object.assign({}, e, {
@@ -1202,60 +1202,60 @@ function Js({ items: s }, e, { flowChars: t, itemIndent: n }) {
1202
1202
  inFlow: !0,
1203
1203
  type: null
1204
1204
  });
1205
- let c = !1, p = 0;
1205
+ let c = !1, m = 0;
1206
1206
  const f = [];
1207
- for (let g = 0; g < s.length; ++g) {
1208
- const h = s[g];
1209
- let d = null;
1210
- if ($(h))
1211
- h.spaceBefore && f.push(""), Me(e, f, h.commentBefore, !1), h.comment && (d = h.comment);
1212
- else if (E(h)) {
1213
- const w = $(h.key) ? h.key : null;
1214
- w && (w.spaceBefore && f.push(""), Me(e, f, w.commentBefore, !1), w.comment && (c = !0));
1215
- const k = $(h.value) ? h.value : null;
1216
- k ? (k.comment && (d = k.comment), k.commentBefore && (c = !0)) : h.value == null && (w != null && w.comment) && (d = w.comment);
1207
+ for (let y = 0; y < s.length; ++y) {
1208
+ const u = s[y];
1209
+ let p = null;
1210
+ if ($(u))
1211
+ u.spaceBefore && f.push(""), Pe(e, f, u.commentBefore, !1), u.comment && (p = u.comment);
1212
+ else if (I(u)) {
1213
+ const w = $(u.key) ? u.key : null;
1214
+ w && (w.spaceBefore && f.push(""), Pe(e, f, w.commentBefore, !1), w.comment && (c = !0));
1215
+ const N = $(u.value) ? u.value : null;
1216
+ N ? (N.comment && (p = N.comment), N.commentBefore && (c = !0)) : u.value == null && (w != null && w.comment) && (p = w.comment);
1217
1217
  }
1218
- d && (c = !0);
1219
- let b = ae(h, a, () => d = null);
1220
- g < s.length - 1 && (b += ","), d && (b += W(b, n, l(d))), !c && (f.length > p || b.includes(`
1221
- `)) && (c = !0), f.push(b), p = f.length;
1218
+ p && (c = !0);
1219
+ let g = ae(u, a, () => p = null);
1220
+ y < s.length - 1 && (g += ","), p && (g += W(g, n, l(p))), !c && (f.length > m || g.includes(`
1221
+ `)) && (c = !0), f.push(g), m = f.length;
1222
1222
  }
1223
- const { start: u, end: m } = t;
1223
+ const { start: d, end: h } = t;
1224
1224
  if (f.length === 0)
1225
- return u + m;
1225
+ return d + h;
1226
1226
  if (!c) {
1227
- const g = f.reduce((h, d) => h + d.length + 2, 2);
1228
- c = e.options.lineWidth > 0 && g > e.options.lineWidth;
1227
+ const y = f.reduce((u, p) => u + p.length + 2, 2);
1228
+ c = e.options.lineWidth > 0 && y > e.options.lineWidth;
1229
1229
  }
1230
1230
  if (c) {
1231
- let g = u;
1232
- for (const h of f)
1233
- g += h ? `
1234
- ${r}${i}${h}` : `
1231
+ let y = d;
1232
+ for (const u of f)
1233
+ y += u ? `
1234
+ ${r}${i}${u}` : `
1235
1235
  `;
1236
- return `${g}
1237
- ${i}${m}`;
1236
+ return `${y}
1237
+ ${i}${h}`;
1238
1238
  } else
1239
- return `${u}${o}${f.join(" ")}${o}${m}`;
1239
+ return `${d}${o}${f.join(" ")}${o}${h}`;
1240
1240
  }
1241
- function Me({ indent: s, options: { commentString: e } }, t, n, i) {
1241
+ function Pe({ indent: s, options: { commentString: e } }, t, n, i) {
1242
1242
  if (n && i && (n = n.replace(/^\n+/, "")), n) {
1243
- const r = R(e(n), s);
1243
+ const r = F(e(n), s);
1244
1244
  t.push(r.trimStart());
1245
1245
  }
1246
1246
  }
1247
1247
  function H(s, e) {
1248
- const t = A(e) ? e.value : e;
1248
+ const t = E(e) ? e.value : e;
1249
1249
  for (const n of s)
1250
- if (E(n) && (n.key === e || n.key === t || A(n.key) && n.key.value === t))
1250
+ if (I(n) && (n.key === e || n.key === t || E(n.key) && n.key.value === t))
1251
1251
  return n;
1252
1252
  }
1253
- class P extends dt {
1253
+ class P extends Gt {
1254
1254
  static get tagName() {
1255
1255
  return "tag:yaml.org,2002:map";
1256
1256
  }
1257
1257
  constructor(e) {
1258
- super(J, e), this.items = [];
1258
+ super(V, e), this.items = [];
1259
1259
  }
1260
1260
  /**
1261
1261
  * A generic collection parsing method that can be extended
@@ -1267,7 +1267,7 @@ class P extends dt {
1267
1267
  c = r.call(t, a, c);
1268
1268
  else if (Array.isArray(r) && !r.includes(a))
1269
1269
  return;
1270
- (c !== void 0 || i) && o.items.push(pt(a, c, n));
1270
+ (c !== void 0 || i) && o.items.push(dt(a, c, n));
1271
1271
  };
1272
1272
  if (t instanceof Map)
1273
1273
  for (const [a, c] of t)
@@ -1286,12 +1286,12 @@ class P extends dt {
1286
1286
  add(e, t) {
1287
1287
  var o;
1288
1288
  let n;
1289
- E(e) ? n = e : !e || typeof e != "object" || !("key" in e) ? n = new v(e, e == null ? void 0 : e.value) : n = new v(e.key, e.value);
1289
+ I(e) ? n = e : !e || typeof e != "object" || !("key" in e) ? n = new v(e, e == null ? void 0 : e.value) : n = new v(e.key, e.value);
1290
1290
  const i = H(this.items, n.key), r = (o = this.schema) == null ? void 0 : o.sortMapEntries;
1291
1291
  if (i) {
1292
1292
  if (!t)
1293
1293
  throw new Error(`Key ${n.key} already set`);
1294
- A(i.value) && Gt(n.value) ? i.value.value = n.value : i.value = n.value;
1294
+ E(i.value) && Jt(n.value) ? i.value.value = n.value : i.value = n.value;
1295
1295
  } else if (r) {
1296
1296
  const l = this.items.findIndex((a) => r(n, a) < 0);
1297
1297
  l === -1 ? this.items.push(n) : this.items.splice(l, 0, n);
@@ -1304,7 +1304,7 @@ class P extends dt {
1304
1304
  }
1305
1305
  get(e, t) {
1306
1306
  const n = H(this.items, e), i = n == null ? void 0 : n.value;
1307
- return (!t && A(i) ? i.value : i) ?? void 0;
1307
+ return (!t && E(i) ? i.value : i) ?? void 0;
1308
1308
  }
1309
1309
  has(e) {
1310
1310
  return !!H(this.items, e);
@@ -1328,7 +1328,7 @@ class P extends dt {
1328
1328
  if (!e)
1329
1329
  return JSON.stringify(this);
1330
1330
  for (const i of this.items)
1331
- if (!E(i))
1331
+ if (!I(i))
1332
1332
  throw new Error(`Map items must all be pairs; found ${JSON.stringify(i)} instead`);
1333
1333
  return !e.allNullValues && this.hasAllNullValues(!1) && (e = Object.assign({}, e, { allNullValues: !0 })), zt(this, e, {
1334
1334
  blockItemPrefix: "",
@@ -1349,7 +1349,7 @@ const pe = {
1349
1349
  },
1350
1350
  createNode: (s, e, t) => P.from(s, e, t)
1351
1351
  };
1352
- class G extends dt {
1352
+ class J extends Gt {
1353
1353
  static get tagName() {
1354
1354
  return "tag:yaml.org,2002:seq";
1355
1355
  }
@@ -1376,7 +1376,7 @@ class G extends dt {
1376
1376
  if (typeof n != "number")
1377
1377
  return;
1378
1378
  const i = this.items[n];
1379
- return !t && A(i) ? i.value : i;
1379
+ return !t && E(i) ? i.value : i;
1380
1380
  }
1381
1381
  /**
1382
1382
  * Checks if the collection includes a value with the key `key`.
@@ -1400,7 +1400,7 @@ class G extends dt {
1400
1400
  if (typeof n != "number")
1401
1401
  throw new Error(`Expected a valid index, not ${e}.`);
1402
1402
  const i = this.items[n];
1403
- A(i) && Gt(t) ? i.value = t : this.items[n] = t;
1403
+ E(i) && Jt(t) ? i.value = t : this.items[n] = t;
1404
1404
  }
1405
1405
  toJSON(e, t) {
1406
1406
  const n = [];
@@ -1435,19 +1435,19 @@ class G extends dt {
1435
1435
  }
1436
1436
  }
1437
1437
  function Ie(s) {
1438
- let e = A(s) ? s.value : s;
1438
+ let e = E(s) ? s.value : s;
1439
1439
  return e && typeof e == "string" && (e = Number(e)), typeof e == "number" && Number.isInteger(e) && e >= 0 ? e : null;
1440
1440
  }
1441
1441
  const me = {
1442
1442
  collection: "seq",
1443
1443
  default: !0,
1444
- nodeClass: G,
1444
+ nodeClass: J,
1445
1445
  tag: "tag:yaml.org,2002:seq",
1446
1446
  resolve(s, e) {
1447
1447
  return de(s) || e("Expected a sequence for this tag"), s;
1448
1448
  },
1449
- createNode: (s, e, t) => G.from(s, e, t)
1450
- }, Re = {
1449
+ createNode: (s, e, t) => J.from(s, e, t)
1450
+ }, Ve = {
1451
1451
  identify: (s) => typeof s == "string",
1452
1452
  default: !0,
1453
1453
  tag: "tag:yaml.org,2002:str",
@@ -1455,22 +1455,22 @@ const me = {
1455
1455
  stringify(s, e, t, n) {
1456
1456
  return e = Object.assign({ actualString: !0 }, e), Oe(s, e, t, n);
1457
1457
  }
1458
- }, Ve = {
1458
+ }, Ye = {
1459
1459
  identify: (s) => s == null,
1460
- createNode: () => new N(null),
1460
+ createNode: () => new O(null),
1461
1461
  default: !0,
1462
1462
  tag: "tag:yaml.org,2002:null",
1463
1463
  test: /^(?:~|[Nn]ull|NULL)?$/,
1464
- resolve: () => new N(null),
1465
- stringify: ({ source: s }, e) => typeof s == "string" && Ve.test.test(s) ? s : e.options.nullStr
1466
- }, mt = {
1464
+ resolve: () => new O(null),
1465
+ stringify: ({ source: s }, e) => typeof s == "string" && Ye.test.test(s) ? s : e.options.nullStr
1466
+ }, pt = {
1467
1467
  identify: (s) => typeof s == "boolean",
1468
1468
  default: !0,
1469
1469
  tag: "tag:yaml.org,2002:bool",
1470
1470
  test: /^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,
1471
- resolve: (s) => new N(s[0] === "t" || s[0] === "T"),
1471
+ resolve: (s) => new O(s[0] === "t" || s[0] === "T"),
1472
1472
  stringify({ source: s, value: e }, t) {
1473
- if (s && mt.test.test(s)) {
1473
+ if (s && pt.test.test(s)) {
1474
1474
  const n = s[0] === "t" || s[0] === "T";
1475
1475
  if (e === n)
1476
1476
  return s;
@@ -1478,7 +1478,7 @@ const me = {
1478
1478
  return e ? t.options.trueStr : t.options.falseStr;
1479
1479
  }
1480
1480
  };
1481
- function F({ format: s, minFractionDigits: e, tag: t, value: n }) {
1481
+ function q({ format: s, minFractionDigits: e, tag: t, value: n }) {
1482
1482
  if (typeof n == "bigint")
1483
1483
  return String(n);
1484
1484
  const i = typeof n == "number" ? n : Number(n);
@@ -1498,9 +1498,9 @@ const Zt = {
1498
1498
  identify: (s) => typeof s == "number",
1499
1499
  default: !0,
1500
1500
  tag: "tag:yaml.org,2002:float",
1501
- test: /^(?:[-+]?\.(?:inf|Inf|INF|nan|NaN|NAN))$/,
1501
+ test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,
1502
1502
  resolve: (s) => s.slice(-3).toLowerCase() === "nan" ? NaN : s[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY,
1503
- stringify: F
1503
+ stringify: q
1504
1504
  }, xt = {
1505
1505
  identify: (s) => typeof s == "number",
1506
1506
  default: !0,
@@ -1510,7 +1510,7 @@ const Zt = {
1510
1510
  resolve: (s) => parseFloat(s),
1511
1511
  stringify(s) {
1512
1512
  const e = Number(s.value);
1513
- return isFinite(e) ? e.toExponential() : F(s);
1513
+ return isFinite(e) ? e.toExponential() : q(s);
1514
1514
  }
1515
1515
  }, es = {
1516
1516
  identify: (s) => typeof s == "number",
@@ -1518,14 +1518,14 @@ const Zt = {
1518
1518
  tag: "tag:yaml.org,2002:float",
1519
1519
  test: /^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,
1520
1520
  resolve(s) {
1521
- const e = new N(parseFloat(s)), t = s.indexOf(".");
1521
+ const e = new O(parseFloat(s)), t = s.indexOf(".");
1522
1522
  return t !== -1 && s[s.length - 1] === "0" && (e.minFractionDigits = s.length - t - 1), e;
1523
1523
  },
1524
- stringify: F
1525
- }, Je = (s) => typeof s == "bigint" || Number.isInteger(s), yt = (s, e, t, { intAsBigInt: n }) => n ? BigInt(s) : parseInt(s.substring(e), t);
1524
+ stringify: q
1525
+ }, Je = (s) => typeof s == "bigint" || Number.isInteger(s), mt = (s, e, t, { intAsBigInt: n }) => n ? BigInt(s) : parseInt(s.substring(e), t);
1526
1526
  function ts(s, e, t) {
1527
1527
  const { value: n } = s;
1528
- return Je(n) && n >= 0 ? t + n.toString(e) : F(s);
1528
+ return Je(n) && n >= 0 ? t + n.toString(e) : q(s);
1529
1529
  }
1530
1530
  const ss = {
1531
1531
  identify: (s) => Je(s) && s >= 0,
@@ -1533,29 +1533,29 @@ const ss = {
1533
1533
  tag: "tag:yaml.org,2002:int",
1534
1534
  format: "OCT",
1535
1535
  test: /^0o[0-7]+$/,
1536
- resolve: (s, e, t) => yt(s, 2, 8, t),
1536
+ resolve: (s, e, t) => mt(s, 2, 8, t),
1537
1537
  stringify: (s) => ts(s, 8, "0o")
1538
1538
  }, ns = {
1539
1539
  identify: Je,
1540
1540
  default: !0,
1541
1541
  tag: "tag:yaml.org,2002:int",
1542
1542
  test: /^[-+]?[0-9]+$/,
1543
- resolve: (s, e, t) => yt(s, 0, 10, t),
1544
- stringify: F
1543
+ resolve: (s, e, t) => mt(s, 0, 10, t),
1544
+ stringify: q
1545
1545
  }, is = {
1546
1546
  identify: (s) => Je(s) && s >= 0,
1547
1547
  default: !0,
1548
1548
  tag: "tag:yaml.org,2002:int",
1549
1549
  format: "HEX",
1550
1550
  test: /^0x[0-9a-fA-F]+$/,
1551
- resolve: (s, e, t) => yt(s, 2, 16, t),
1551
+ resolve: (s, e, t) => mt(s, 2, 16, t),
1552
1552
  stringify: (s) => ts(s, 16, "0x")
1553
- }, Ys = [
1553
+ }, Js = [
1554
1554
  pe,
1555
1555
  me,
1556
- Re,
1557
1556
  Ve,
1558
- mt,
1557
+ Ye,
1558
+ pt,
1559
1559
  ss,
1560
1560
  ns,
1561
1561
  is,
@@ -1563,7 +1563,7 @@ const ss = {
1563
1563
  xt,
1564
1564
  es
1565
1565
  ];
1566
- function $t(s) {
1566
+ function Lt(s) {
1567
1567
  return typeof s == "bigint" || Number.isInteger(s);
1568
1568
  }
1569
1569
  const Te = ({ value: s }) => JSON.stringify(s), Gs = [
@@ -1576,7 +1576,7 @@ const Te = ({ value: s }) => JSON.stringify(s), Gs = [
1576
1576
  },
1577
1577
  {
1578
1578
  identify: (s) => s == null,
1579
- createNode: () => new N(null),
1579
+ createNode: () => new O(null),
1580
1580
  default: !0,
1581
1581
  tag: "tag:yaml.org,2002:null",
1582
1582
  test: /^null$/,
@@ -1592,12 +1592,12 @@ const Te = ({ value: s }) => JSON.stringify(s), Gs = [
1592
1592
  stringify: Te
1593
1593
  },
1594
1594
  {
1595
- identify: $t,
1595
+ identify: Lt,
1596
1596
  default: !0,
1597
1597
  tag: "tag:yaml.org,2002:int",
1598
1598
  test: /^-?(?:0|[1-9][0-9]*)$/,
1599
1599
  resolve: (s, e, { intAsBigInt: t }) => t ? BigInt(s) : parseInt(s, 10),
1600
- stringify: ({ value: s }) => $t(s) ? s.toString() : JSON.stringify(s)
1600
+ stringify: ({ value: s }) => Lt(s) ? s.toString() : JSON.stringify(s)
1601
1601
  },
1602
1602
  {
1603
1603
  identify: (s) => typeof s == "number",
@@ -1614,7 +1614,7 @@ const Te = ({ value: s }) => JSON.stringify(s), Gs = [
1614
1614
  resolve(s, e) {
1615
1615
  return e(`Unresolved plain scalar ${JSON.stringify(s)}`), s;
1616
1616
  }
1617
- }, Ws = [pe, me].concat(Gs, Qs), gt = {
1617
+ }, Ws = [pe, me].concat(Gs, Qs), yt = {
1618
1618
  identify: (s) => s instanceof Uint8Array,
1619
1619
  // Buffer inherits from Uint8Array
1620
1620
  default: !1,
@@ -1650,11 +1650,11 @@ const Te = ({ value: s }) => JSON.stringify(s), Gs = [
1650
1650
  l = btoa(a);
1651
1651
  } else
1652
1652
  throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");
1653
- if (e || (e = N.BLOCK_LITERAL), e !== N.QUOTE_DOUBLE) {
1654
- const a = Math.max(n.options.lineWidth - n.indent.length, n.options.minContentWidth), c = Math.ceil(l.length / a), p = new Array(c);
1655
- for (let f = 0, u = 0; f < c; ++f, u += a)
1656
- p[f] = l.substr(u, a);
1657
- l = p.join(e === N.BLOCK_LITERAL ? `
1653
+ if (e || (e = O.BLOCK_LITERAL), e !== O.QUOTE_DOUBLE) {
1654
+ const a = Math.max(n.options.lineWidth - n.indent.length, n.options.minContentWidth), c = Math.ceil(l.length / a), m = new Array(c);
1655
+ for (let f = 0, d = 0; f < c; ++f, d += a)
1656
+ m[f] = l.substr(d, a);
1657
+ l = m.join(e === O.BLOCK_LITERAL ? `
1658
1658
  ` : " ");
1659
1659
  }
1660
1660
  return Oe({ comment: s, type: e, value: l }, n, i, r);
@@ -1664,10 +1664,10 @@ function rs(s, e) {
1664
1664
  if (de(s))
1665
1665
  for (let t = 0; t < s.items.length; ++t) {
1666
1666
  let n = s.items[t];
1667
- if (!E(n)) {
1667
+ if (!I(n)) {
1668
1668
  if (he(n)) {
1669
1669
  n.items.length > 1 && e("Each pair must have its own sequence indicator");
1670
- const i = n.items[0] || new v(new N(null));
1670
+ const i = n.items[0] || new v(new O(null));
1671
1671
  if (n.commentBefore && (i.key.commentBefore = i.key.commentBefore ? `${n.commentBefore}
1672
1672
  ${i.key.commentBefore}` : n.commentBefore), n.comment) {
1673
1673
  const r = i.value ?? i.key;
@@ -1676,7 +1676,7 @@ ${r.comment}` : n.comment;
1676
1676
  }
1677
1677
  n = i;
1678
1678
  }
1679
- s.items[t] = E(n) ? n : new v(n);
1679
+ s.items[t] = I(n) ? n : new v(n);
1680
1680
  }
1681
1681
  }
1682
1682
  else
@@ -1684,7 +1684,7 @@ ${r.comment}` : n.comment;
1684
1684
  return s;
1685
1685
  }
1686
1686
  function os(s, e, t) {
1687
- const { replacer: n } = t, i = new G(s);
1687
+ const { replacer: n } = t, i = new J(s);
1688
1688
  i.tag = "tag:yaml.org,2002:pairs";
1689
1689
  let r = 0;
1690
1690
  if (e && Symbol.iterator in Object(e))
@@ -1704,18 +1704,18 @@ function os(s, e, t) {
1704
1704
  throw new TypeError(`Expected tuple with one key, not ${c.length} keys`);
1705
1705
  } else
1706
1706
  l = o;
1707
- i.items.push(pt(l, a, t));
1707
+ i.items.push(dt(l, a, t));
1708
1708
  }
1709
1709
  return i;
1710
1710
  }
1711
- const bt = {
1711
+ const gt = {
1712
1712
  collection: "seq",
1713
1713
  default: !1,
1714
1714
  tag: "tag:yaml.org,2002:pairs",
1715
1715
  resolve: rs,
1716
1716
  createNode: os
1717
1717
  };
1718
- class oe extends G {
1718
+ class oe extends J {
1719
1719
  constructor() {
1720
1720
  super(), this.add = P.prototype.add.bind(this), this.delete = P.prototype.delete.bind(this), this.get = P.prototype.get.bind(this), this.has = P.prototype.has.bind(this), this.set = P.prototype.set.bind(this), this.tag = oe.tag;
1721
1721
  }
@@ -1730,7 +1730,7 @@ class oe extends G {
1730
1730
  t != null && t.onCreate && t.onCreate(n);
1731
1731
  for (const i of this.items) {
1732
1732
  let r, o;
1733
- if (E(i) ? (r = D(i.key, "", t), o = D(i.value, r, t)) : r = D(i, "", t), n.has(r))
1733
+ if (I(i) ? (r = D(i.key, "", t), o = D(i.value, r, t)) : r = D(i, "", t), n.has(r))
1734
1734
  throw new Error("Ordered maps must not include duplicate keys");
1735
1735
  n.set(r, o);
1736
1736
  }
@@ -1742,7 +1742,7 @@ class oe extends G {
1742
1742
  }
1743
1743
  }
1744
1744
  oe.tag = "tag:yaml.org,2002:omap";
1745
- const wt = {
1745
+ const bt = {
1746
1746
  collection: "seq",
1747
1747
  identify: (s) => s instanceof Map,
1748
1748
  nodeClass: oe,
@@ -1751,7 +1751,7 @@ const wt = {
1751
1751
  resolve(s, e) {
1752
1752
  const t = rs(s, e), n = [];
1753
1753
  for (const { key: i } of t.items)
1754
- A(i) && (n.includes(i.value) ? e(`Ordered maps must not include duplicate keys: ${i.value}`) : n.push(i.value));
1754
+ E(i) && (n.includes(i.value) ? e(`Ordered maps must not include duplicate keys: ${i.value}`) : n.push(i.value));
1755
1755
  return Object.assign(new oe(), t);
1756
1756
  },
1757
1757
  createNode: (s, e, t) => oe.from(s, e, t)
@@ -1764,22 +1764,22 @@ const as = {
1764
1764
  default: !0,
1765
1765
  tag: "tag:yaml.org,2002:bool",
1766
1766
  test: /^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,
1767
- resolve: () => new N(!0),
1767
+ resolve: () => new O(!0),
1768
1768
  stringify: ls
1769
1769
  }, cs = {
1770
1770
  identify: (s) => s === !1,
1771
1771
  default: !0,
1772
1772
  tag: "tag:yaml.org,2002:bool",
1773
- test: /^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/i,
1774
- resolve: () => new N(!1),
1773
+ test: /^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,
1774
+ resolve: () => new O(!1),
1775
1775
  stringify: ls
1776
1776
  }, Hs = {
1777
1777
  identify: (s) => typeof s == "number",
1778
1778
  default: !0,
1779
1779
  tag: "tag:yaml.org,2002:float",
1780
- test: /^[-+]?\.(?:inf|Inf|INF|nan|NaN|NAN)$/,
1780
+ test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,
1781
1781
  resolve: (s) => s.slice(-3).toLowerCase() === "nan" ? NaN : s[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY,
1782
- stringify: F
1782
+ stringify: q
1783
1783
  }, Xs = {
1784
1784
  identify: (s) => typeof s == "number",
1785
1785
  default: !0,
@@ -1789,7 +1789,7 @@ const as = {
1789
1789
  resolve: (s) => parseFloat(s.replace(/_/g, "")),
1790
1790
  stringify(s) {
1791
1791
  const e = Number(s.value);
1792
- return isFinite(e) ? e.toExponential() : F(s);
1792
+ return isFinite(e) ? e.toExponential() : q(s);
1793
1793
  }
1794
1794
  }, zs = {
1795
1795
  identify: (s) => typeof s == "number",
@@ -1797,16 +1797,16 @@ const as = {
1797
1797
  tag: "tag:yaml.org,2002:float",
1798
1798
  test: /^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,
1799
1799
  resolve(s) {
1800
- const e = new N(parseFloat(s.replace(/_/g, ""))), t = s.indexOf(".");
1800
+ const e = new O(parseFloat(s.replace(/_/g, ""))), t = s.indexOf(".");
1801
1801
  if (t !== -1) {
1802
1802
  const n = s.substring(t + 1).replace(/_/g, "");
1803
1803
  n[n.length - 1] === "0" && (e.minFractionDigits = n.length);
1804
1804
  }
1805
1805
  return e;
1806
1806
  },
1807
- stringify: F
1807
+ stringify: q
1808
1808
  }, Ae = (s) => typeof s == "bigint" || Number.isInteger(s);
1809
- function Ye(s, e, t, { intAsBigInt: n }) {
1809
+ function Ge(s, e, t, { intAsBigInt: n }) {
1810
1810
  const i = s[0];
1811
1811
  if ((i === "-" || i === "+") && (e += 1), s = s.substring(e).replace(/_/g, ""), n) {
1812
1812
  switch (t) {
@@ -1826,13 +1826,13 @@ function Ye(s, e, t, { intAsBigInt: n }) {
1826
1826
  const r = parseInt(s, t);
1827
1827
  return i === "-" ? -1 * r : r;
1828
1828
  }
1829
- function St(s, e, t) {
1829
+ function wt(s, e, t) {
1830
1830
  const { value: n } = s;
1831
1831
  if (Ae(n)) {
1832
1832
  const i = n.toString(e);
1833
1833
  return n < 0 ? "-" + t + i.substr(1) : t + i;
1834
1834
  }
1835
- return F(s);
1835
+ return q(s);
1836
1836
  }
1837
1837
  const Zs = {
1838
1838
  identify: Ae,
@@ -1840,31 +1840,31 @@ const Zs = {
1840
1840
  tag: "tag:yaml.org,2002:int",
1841
1841
  format: "BIN",
1842
1842
  test: /^[-+]?0b[0-1_]+$/,
1843
- resolve: (s, e, t) => Ye(s, 2, 2, t),
1844
- stringify: (s) => St(s, 2, "0b")
1843
+ resolve: (s, e, t) => Ge(s, 2, 2, t),
1844
+ stringify: (s) => wt(s, 2, "0b")
1845
1845
  }, xs = {
1846
1846
  identify: Ae,
1847
1847
  default: !0,
1848
1848
  tag: "tag:yaml.org,2002:int",
1849
1849
  format: "OCT",
1850
1850
  test: /^[-+]?0[0-7_]+$/,
1851
- resolve: (s, e, t) => Ye(s, 1, 8, t),
1852
- stringify: (s) => St(s, 8, "0")
1851
+ resolve: (s, e, t) => Ge(s, 1, 8, t),
1852
+ stringify: (s) => wt(s, 8, "0")
1853
1853
  }, en = {
1854
1854
  identify: Ae,
1855
1855
  default: !0,
1856
1856
  tag: "tag:yaml.org,2002:int",
1857
1857
  test: /^[-+]?[0-9][0-9_]*$/,
1858
- resolve: (s, e, t) => Ye(s, 0, 10, t),
1859
- stringify: F
1858
+ resolve: (s, e, t) => Ge(s, 0, 10, t),
1859
+ stringify: q
1860
1860
  }, tn = {
1861
1861
  identify: Ae,
1862
1862
  default: !0,
1863
1863
  tag: "tag:yaml.org,2002:int",
1864
1864
  format: "HEX",
1865
1865
  test: /^[-+]?0x[0-9a-fA-F_]+$/,
1866
- resolve: (s, e, t) => Ye(s, 2, 16, t),
1867
- stringify: (s) => St(s, 16, "0x")
1866
+ resolve: (s, e, t) => Ge(s, 2, 16, t),
1867
+ stringify: (s) => wt(s, 16, "0x")
1868
1868
  };
1869
1869
  class le extends P {
1870
1870
  constructor(e) {
@@ -1872,7 +1872,7 @@ class le extends P {
1872
1872
  }
1873
1873
  add(e) {
1874
1874
  let t;
1875
- E(e) ? t = e : e && typeof e == "object" && "key" in e && "value" in e && e.value === null ? t = new v(e.key, null) : t = new v(e, null), H(this.items, t.key) || this.items.push(t);
1875
+ I(e) ? t = e : e && typeof e == "object" && "key" in e && "value" in e && e.value === null ? t = new v(e.key, null) : t = new v(e, null), H(this.items, t.key) || this.items.push(t);
1876
1876
  }
1877
1877
  /**
1878
1878
  * If `keepPair` is `true`, returns the Pair matching `key`.
@@ -1880,7 +1880,7 @@ class le extends P {
1880
1880
  */
1881
1881
  get(e, t) {
1882
1882
  const n = H(this.items, e);
1883
- return !t && E(n) ? A(n.key) ? n.key.value : n.key : n;
1883
+ return !t && I(n) ? E(n.key) ? n.key.value : n.key : n;
1884
1884
  }
1885
1885
  set(e, t) {
1886
1886
  if (typeof t != "boolean")
@@ -1902,12 +1902,12 @@ class le extends P {
1902
1902
  const { replacer: i } = n, r = new this(e);
1903
1903
  if (t && Symbol.iterator in Object(t))
1904
1904
  for (let o of t)
1905
- typeof i == "function" && (o = i.call(t, o, o)), r.items.push(pt(o, null, n));
1905
+ typeof i == "function" && (o = i.call(t, o, o)), r.items.push(dt(o, null, n));
1906
1906
  return r;
1907
1907
  }
1908
1908
  }
1909
1909
  le.tag = "tag:yaml.org,2002:set";
1910
- const kt = {
1910
+ const St = {
1911
1911
  collection: "map",
1912
1912
  identify: (s) => s instanceof Set,
1913
1913
  nodeClass: le,
@@ -1924,7 +1924,7 @@ const kt = {
1924
1924
  return s;
1925
1925
  }
1926
1926
  };
1927
- function Nt(s, e) {
1927
+ function kt(s, e) {
1928
1928
  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));
1929
1929
  return t === "-" ? i(-1) * r : r;
1930
1930
  }
@@ -1933,7 +1933,7 @@ function fs(s) {
1933
1933
  if (typeof e == "bigint")
1934
1934
  t = (o) => BigInt(o);
1935
1935
  else if (isNaN(e) || !isFinite(e))
1936
- return F(s);
1936
+ return q(s);
1937
1937
  let n = "";
1938
1938
  e < 0 && (n = "-", e *= t(-1));
1939
1939
  const i = t(60), r = [e % i];
@@ -1945,7 +1945,7 @@ const us = {
1945
1945
  tag: "tag:yaml.org,2002:int",
1946
1946
  format: "TIME",
1947
1947
  test: /^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,
1948
- resolve: (s, e, { intAsBigInt: t }) => Nt(s, t),
1948
+ resolve: (s, e, { intAsBigInt: t }) => kt(s, t),
1949
1949
  stringify: fs
1950
1950
  }, hs = {
1951
1951
  identify: (s) => typeof s == "number",
@@ -1953,9 +1953,9 @@ const us = {
1953
1953
  tag: "tag:yaml.org,2002:float",
1954
1954
  format: "TIME",
1955
1955
  test: /^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,
1956
- resolve: (s) => Nt(s, !1),
1956
+ resolve: (s) => kt(s, !1),
1957
1957
  stringify: fs
1958
- }, Ge = {
1958
+ }, Qe = {
1959
1959
  identify: (s) => s instanceof Date,
1960
1960
  default: !0,
1961
1961
  tag: "tag:yaml.org,2002:timestamp",
@@ -1964,24 +1964,24 @@ const us = {
1964
1964
  // assumed to be 00:00:00Z (start of day, UTC).
1965
1965
  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})?))?)?$"),
1966
1966
  resolve(s) {
1967
- const e = s.match(Ge.test);
1967
+ const e = s.match(Qe.test);
1968
1968
  if (!e)
1969
1969
  throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd");
1970
1970
  const [, t, n, i, r, o, l] = e.map(Number), a = e[7] ? Number((e[7] + "00").substr(1, 3)) : 0;
1971
1971
  let c = Date.UTC(t, n - 1, i, r || 0, o || 0, l || 0, a);
1972
- const p = e[8];
1973
- if (p && p !== "Z") {
1974
- let f = Nt(p, !1);
1972
+ const m = e[8];
1973
+ if (m && m !== "Z") {
1974
+ let f = kt(m, !1);
1975
1975
  Math.abs(f) < 30 && (f *= 60), c -= 6e4 * f;
1976
1976
  }
1977
1977
  return new Date(c);
1978
1978
  },
1979
1979
  stringify: ({ value: s }) => s.toISOString().replace(/((T00:00)?:00)?\.000Z$/, "")
1980
- }, _t = [
1980
+ }, $t = [
1981
1981
  pe,
1982
1982
  me,
1983
- Re,
1984
1983
  Ve,
1984
+ Ye,
1985
1985
  as,
1986
1986
  cs,
1987
1987
  Zs,
@@ -1991,22 +1991,22 @@ const us = {
1991
1991
  Hs,
1992
1992
  Xs,
1993
1993
  zs,
1994
- gt,
1995
- wt,
1994
+ yt,
1996
1995
  bt,
1997
- kt,
1996
+ gt,
1997
+ St,
1998
1998
  us,
1999
1999
  hs,
2000
- Ge
2001
- ], Ct = /* @__PURE__ */ new Map([
2002
- ["core", Ys],
2003
- ["failsafe", [pe, me, Re]],
2000
+ Qe
2001
+ ], _t = /* @__PURE__ */ new Map([
2002
+ ["core", Js],
2003
+ ["failsafe", [pe, me, Ve]],
2004
2004
  ["json", Ws],
2005
- ["yaml11", _t],
2006
- ["yaml-1.1", _t]
2007
- ]), vt = {
2008
- binary: gt,
2009
- bool: mt,
2005
+ ["yaml11", $t],
2006
+ ["yaml-1.1", $t]
2007
+ ]), Ct = {
2008
+ binary: yt,
2009
+ bool: pt,
2010
2010
  float: es,
2011
2011
  floatExp: xt,
2012
2012
  floatNaN: Zt,
@@ -2016,26 +2016,26 @@ const us = {
2016
2016
  intOct: ss,
2017
2017
  intTime: us,
2018
2018
  map: pe,
2019
- null: Ve,
2020
- omap: wt,
2021
- pairs: bt,
2019
+ null: Ye,
2020
+ omap: bt,
2021
+ pairs: gt,
2022
2022
  seq: me,
2023
- set: kt,
2024
- timestamp: Ge
2023
+ set: St,
2024
+ timestamp: Qe
2025
2025
  }, sn = {
2026
- "tag:yaml.org,2002:binary": gt,
2027
- "tag:yaml.org,2002:omap": wt,
2028
- "tag:yaml.org,2002:pairs": bt,
2029
- "tag:yaml.org,2002:set": kt,
2030
- "tag:yaml.org,2002:timestamp": Ge
2026
+ "tag:yaml.org,2002:binary": yt,
2027
+ "tag:yaml.org,2002:omap": bt,
2028
+ "tag:yaml.org,2002:pairs": gt,
2029
+ "tag:yaml.org,2002:set": St,
2030
+ "tag:yaml.org,2002:timestamp": Qe
2031
2031
  };
2032
- function Ze(s, e) {
2033
- let t = Ct.get(e);
2032
+ function xe(s, e) {
2033
+ let t = _t.get(e);
2034
2034
  if (!t)
2035
2035
  if (Array.isArray(s))
2036
2036
  t = [];
2037
2037
  else {
2038
- const n = Array.from(Ct.keys()).filter((i) => i !== "yaml11").map((i) => JSON.stringify(i)).join(", ");
2038
+ const n = Array.from(_t.keys()).filter((i) => i !== "yaml11").map((i) => JSON.stringify(i)).join(", ");
2039
2039
  throw new Error(`Unknown schema "${e}"; use one of ${n} or define customTags array`);
2040
2040
  }
2041
2041
  if (Array.isArray(s))
@@ -2045,20 +2045,20 @@ function Ze(s, e) {
2045
2045
  return t.map((n) => {
2046
2046
  if (typeof n != "string")
2047
2047
  return n;
2048
- const i = vt[n];
2048
+ const i = Ct[n];
2049
2049
  if (i)
2050
2050
  return i;
2051
- const r = Object.keys(vt).map((o) => JSON.stringify(o)).join(", ");
2051
+ const r = Object.keys(Ct).map((o) => JSON.stringify(o)).join(", ");
2052
2052
  throw new Error(`Unknown custom tag "${n}"; use one of ${r}`);
2053
2053
  });
2054
2054
  }
2055
2055
  const nn = (s, e) => s.key < e.key ? -1 : s.key > e.key ? 1 : 0;
2056
- class Qe {
2056
+ class We {
2057
2057
  constructor({ compat: e, customTags: t, merge: n, resolveKnownTags: i, schema: r, sortMapEntries: o, toStringDefaults: l }) {
2058
- this.compat = Array.isArray(e) ? Ze(e, "compat") : e ? Ze(null, e) : null, this.merge = !!n, this.name = typeof r == "string" && r || "core", this.knownTags = i ? sn : {}, this.tags = Ze(t, this.name), this.toStringOptions = l ?? null, Object.defineProperty(this, J, { value: pe }), Object.defineProperty(this, V, { value: Re }), Object.defineProperty(this, fe, { value: me }), this.sortMapEntries = typeof o == "function" ? o : o === !0 ? nn : null;
2058
+ this.compat = Array.isArray(e) ? xe(e, "compat") : e ? xe(null, e) : null, this.merge = !!n, this.name = typeof r == "string" && r || "core", this.knownTags = i ? sn : {}, this.tags = xe(t, this.name), this.toStringOptions = l ?? null, Object.defineProperty(this, V, { value: pe }), Object.defineProperty(this, R, { value: Ve }), Object.defineProperty(this, fe, { value: me }), this.sortMapEntries = typeof o == "function" ? o : o === !0 ? nn : null;
2059
2059
  }
2060
2060
  clone() {
2061
- const e = Object.create(Qe.prototype, Object.getOwnPropertyDescriptors(this));
2061
+ const e = Object.create(We.prototype, Object.getOwnPropertyDescriptors(this));
2062
2062
  return e.tags = this.tags.slice(), e;
2063
2063
  }
2064
2064
  }
@@ -2075,32 +2075,32 @@ function rn(s, e) {
2075
2075
  if (s.commentBefore) {
2076
2076
  t.length !== 1 && t.unshift("");
2077
2077
  const c = r(s.commentBefore);
2078
- t.unshift(R(c, ""));
2078
+ t.unshift(F(c, ""));
2079
2079
  }
2080
2080
  let o = !1, l = null;
2081
2081
  if (s.contents) {
2082
2082
  if ($(s.contents)) {
2083
2083
  if (s.contents.spaceBefore && n && t.push(""), s.contents.commentBefore) {
2084
2084
  const f = r(s.contents.commentBefore);
2085
- t.push(R(f, ""));
2085
+ t.push(F(f, ""));
2086
2086
  }
2087
2087
  i.forceBlockIndent = !!s.comment, l = s.contents.comment;
2088
2088
  }
2089
2089
  const c = l ? void 0 : () => o = !0;
2090
- let p = ae(s.contents, i, () => l = null, c);
2091
- l && (p += W(p, "", r(l))), (p[0] === "|" || p[0] === ">") && t[t.length - 1] === "---" ? t[t.length - 1] = `--- ${p}` : t.push(p);
2090
+ let m = ae(s.contents, i, () => l = null, c);
2091
+ l && (m += W(m, "", r(l))), (m[0] === "|" || m[0] === ">") && t[t.length - 1] === "---" ? t[t.length - 1] = `--- ${m}` : t.push(m);
2092
2092
  } else
2093
2093
  t.push(ae(s.contents, i));
2094
2094
  if ((a = s.directives) != null && a.docEnd)
2095
2095
  if (s.comment) {
2096
2096
  const c = r(s.comment);
2097
2097
  c.includes(`
2098
- `) ? (t.push("..."), t.push(R(c, ""))) : t.push(`... ${c}`);
2098
+ `) ? (t.push("..."), t.push(F(c, ""))) : t.push(`... ${c}`);
2099
2099
  } else
2100
2100
  t.push("...");
2101
2101
  else {
2102
2102
  let c = s.comment;
2103
- c && o && (c = c.replace(/^\n+/, "")), c && ((!o || l) && t[t.length - 1] !== "" && t.push(""), t.push(R(r(c), "")));
2103
+ c && o && (c = c.replace(/^\n+/, "")), c && ((!o || l) && t[t.length - 1] !== "" && t.push(""), t.push(F(r(c), "")));
2104
2104
  }
2105
2105
  return t.join(`
2106
2106
  `) + `
@@ -2108,7 +2108,7 @@ function rn(s, e) {
2108
2108
  }
2109
2109
  class ye {
2110
2110
  constructor(e, t, n) {
2111
- this.commentBefore = null, this.comment = null, this.errors = [], this.warnings = [], Object.defineProperty(this, K, { value: rt });
2111
+ this.commentBefore = null, this.comment = null, this.errors = [], this.warnings = [], Object.defineProperty(this, j, { value: rt });
2112
2112
  let i = null;
2113
2113
  typeof t == "function" || Array.isArray(t) ? i = t : n === void 0 && t && (n = t, t = void 0);
2114
2114
  const r = Object.assign({
@@ -2131,7 +2131,7 @@ class ye {
2131
2131
  */
2132
2132
  clone() {
2133
2133
  const e = Object.create(ye.prototype, {
2134
- [K]: { value: rt }
2134
+ [j]: { value: rt }
2135
2135
  });
2136
2136
  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 = $(this.contents) ? this.contents.clone(e.schema) : this.contents, this.range && (e.range = this.range.slice()), e;
2137
2137
  }
@@ -2154,34 +2154,34 @@ class ye {
2154
2154
  */
2155
2155
  createAlias(e, t) {
2156
2156
  if (!e.anchor) {
2157
- const n = Jt(this);
2157
+ const n = Vt(this);
2158
2158
  e.anchor = // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
2159
2159
  !t || n.has(t) ? Yt(t || "a", n) : t;
2160
2160
  }
2161
- return new Ke(e.anchor);
2161
+ return new qe(e.anchor);
2162
2162
  }
2163
2163
  createNode(e, t, n) {
2164
2164
  let i;
2165
2165
  if (typeof t == "function")
2166
2166
  e = t.call({ "": e }, "", e), i = t;
2167
2167
  else if (Array.isArray(t)) {
2168
- const d = (w) => typeof w == "number" || w instanceof String || w instanceof Number, b = t.filter(d).map(String);
2169
- b.length > 0 && (t = t.concat(b)), i = t;
2168
+ const p = (w) => typeof w == "number" || w instanceof String || w instanceof Number, g = t.filter(p).map(String);
2169
+ g.length > 0 && (t = t.concat(g)), i = t;
2170
2170
  } else n === void 0 && t && (n = t, t = void 0);
2171
- const { aliasDuplicateObjects: r, anchorPrefix: o, flow: l, keepUndefined: a, onTagObj: c, tag: p } = n ?? {}, { onAnchor: f, setAnchors: u, sourceObjects: m } = vs(
2171
+ const { aliasDuplicateObjects: r, anchorPrefix: o, flow: l, keepUndefined: a, onTagObj: c, tag: m } = n ?? {}, { onAnchor: f, setAnchors: d, sourceObjects: h } = vs(
2172
2172
  this,
2173
2173
  // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
2174
2174
  o || "a"
2175
- ), g = {
2175
+ ), y = {
2176
2176
  aliasDuplicateObjects: r ?? !0,
2177
2177
  keepUndefined: a ?? !1,
2178
2178
  onAnchor: f,
2179
2179
  onTagObj: c,
2180
2180
  replacer: i,
2181
2181
  schema: this.schema,
2182
- sourceObjects: m
2183
- }, h = Se(e, p, g);
2184
- return l && T(h) && (h.flow = !0), u(), h;
2182
+ sourceObjects: h
2183
+ }, u = Se(e, m, y);
2184
+ return l && L(u) && (u.flow = !0), d(), u;
2185
2185
  }
2186
2186
  /**
2187
2187
  * Convert a key and a value into a `Pair` using the current schema,
@@ -2211,7 +2211,7 @@ class ye {
2211
2211
  * `true` (collections are always returned intact).
2212
2212
  */
2213
2213
  get(e, t) {
2214
- return T(this.contents) ? this.contents.get(e, t) : void 0;
2214
+ return L(this.contents) ? this.contents.get(e, t) : void 0;
2215
2215
  }
2216
2216
  /**
2217
2217
  * Returns item at `path`, or `undefined` if not found. By default unwraps
@@ -2219,33 +2219,33 @@ class ye {
2219
2219
  * `true` (collections are always returned intact).
2220
2220
  */
2221
2221
  getIn(e, t) {
2222
- return be(e) ? !t && A(this.contents) ? this.contents.value : this.contents : T(this.contents) ? this.contents.getIn(e, t) : void 0;
2222
+ return be(e) ? !t && E(this.contents) ? this.contents.value : this.contents : L(this.contents) ? this.contents.getIn(e, t) : void 0;
2223
2223
  }
2224
2224
  /**
2225
2225
  * Checks if the document includes a value with the key `key`.
2226
2226
  */
2227
2227
  has(e) {
2228
- return T(this.contents) ? this.contents.has(e) : !1;
2228
+ return L(this.contents) ? this.contents.has(e) : !1;
2229
2229
  }
2230
2230
  /**
2231
2231
  * Checks if the document includes a value at `path`.
2232
2232
  */
2233
2233
  hasIn(e) {
2234
- return be(e) ? this.contents !== void 0 : T(this.contents) ? this.contents.hasIn(e) : !1;
2234
+ return be(e) ? this.contents !== void 0 : L(this.contents) ? this.contents.hasIn(e) : !1;
2235
2235
  }
2236
2236
  /**
2237
2237
  * Sets a value in this document. For `!!set`, `value` needs to be a
2238
2238
  * boolean to add/remove the item from the set.
2239
2239
  */
2240
2240
  set(e, t) {
2241
- this.contents == null ? this.contents = Be(this.schema, [e], t) : ee(this.contents) && this.contents.set(e, t);
2241
+ this.contents == null ? this.contents = Me(this.schema, [e], t) : ee(this.contents) && this.contents.set(e, t);
2242
2242
  }
2243
2243
  /**
2244
2244
  * Sets a value in this document. For `!!set`, `value` needs to be a
2245
2245
  * boolean to add/remove the item from the set.
2246
2246
  */
2247
2247
  setIn(e, t) {
2248
- be(e) ? this.contents = t : this.contents == null ? this.contents = Be(this.schema, Array.from(e), t) : ee(this.contents) && this.contents.setIn(e, t);
2248
+ be(e) ? this.contents = t : this.contents == null ? this.contents = Me(this.schema, Array.from(e), t) : ee(this.contents) && this.contents.setIn(e, t);
2249
2249
  }
2250
2250
  /**
2251
2251
  * Change the YAML version and schema used by the document.
@@ -2276,7 +2276,7 @@ class ye {
2276
2276
  if (t.schema instanceof Object)
2277
2277
  this.schema = t.schema;
2278
2278
  else if (n)
2279
- this.schema = new Qe(Object.assign(n, t));
2279
+ this.schema = new We(Object.assign(n, t));
2280
2280
  else
2281
2281
  throw new Error("With a null YAML version, the { schema: Schema } option is required");
2282
2282
  }
@@ -2291,8 +2291,8 @@ class ye {
2291
2291
  maxAliasCount: typeof i == "number" ? i : 100
2292
2292
  }, a = D(this.contents, t ?? "", l);
2293
2293
  if (typeof r == "function")
2294
- for (const { count: c, res: p } of l.anchors.values())
2295
- r(p, c);
2294
+ for (const { count: c, res: m } of l.anchors.values())
2295
+ r(m, c);
2296
2296
  return typeof o == "function" ? ie(o, { "": a }, "", a) : a;
2297
2297
  }
2298
2298
  /**
@@ -2316,26 +2316,26 @@ class ye {
2316
2316
  }
2317
2317
  }
2318
2318
  function ee(s) {
2319
- if (T(s))
2319
+ if (L(s))
2320
2320
  return !0;
2321
2321
  throw new Error("Expected a YAML collection as document contents");
2322
2322
  }
2323
- class Ot extends Error {
2323
+ class Nt extends Error {
2324
2324
  constructor(e, t, n, i) {
2325
2325
  super(), this.name = e, this.code = n, this.message = i, this.pos = t;
2326
2326
  }
2327
2327
  }
2328
- class X extends Ot {
2328
+ class X extends Nt {
2329
2329
  constructor(e, t, n) {
2330
2330
  super("YAMLParseError", e, t, n);
2331
2331
  }
2332
2332
  }
2333
- class ds extends Ot {
2333
+ class ds extends Nt {
2334
2334
  constructor(e, t, n) {
2335
2335
  super("YAMLWarning", e, t, n);
2336
2336
  }
2337
2337
  }
2338
- const Pe = (s, e) => (t) => {
2338
+ const De = (s, e) => (t) => {
2339
2339
  if (t.pos[0] === -1)
2340
2340
  return;
2341
2341
  t.linePos = t.pos.map((l) => e.linePos(l));
@@ -2363,52 +2363,52 @@ ${c}
2363
2363
  `;
2364
2364
  }
2365
2365
  };
2366
- function ce(s, { flow: e, indicator: t, next: n, offset: i, onError: r, startOnNewline: o }) {
2367
- let l = !1, a = o, c = o, p = "", f = "", u = !1, m = !1, g = !1, h = null, d = null, b = null, w = null, k = null;
2368
- for (const y of s)
2369
- switch (g && (y.type !== "space" && y.type !== "newline" && y.type !== "comma" && r(y.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), g = !1), y.type) {
2366
+ function ce(s, { flow: e, indicator: t, next: n, offset: i, onError: r, parentIndent: o, startOnNewline: l }) {
2367
+ let a = !1, c = l, m = l, f = "", d = "", h = !1, y = !1, u = null, p = null, g = null, w = null, N = null, S = null, A = null;
2368
+ for (const b of s)
2369
+ switch (y && (b.type !== "space" && b.type !== "newline" && b.type !== "comma" && r(b.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), y = !1), u && (c && b.type !== "comment" && b.type !== "newline" && r(u, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), u = null), b.type) {
2370
2370
  case "space":
2371
- !e && a && t !== "doc-start" && y.source[0] === " " && r(y, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), c = !0;
2371
+ !e && (t !== "doc-start" || (n == null ? void 0 : n.type) !== "flow-collection") && b.source.includes(" ") && (u = b), m = !0;
2372
2372
  break;
2373
2373
  case "comment": {
2374
- c || r(y, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters");
2375
- const I = y.source.substring(1) || " ";
2376
- p ? p += f + I : p = I, f = "", a = !1;
2374
+ m || r(b, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters");
2375
+ const _ = b.source.substring(1) || " ";
2376
+ f ? f += d + _ : f = _, d = "", c = !1;
2377
2377
  break;
2378
2378
  }
2379
2379
  case "newline":
2380
- a ? p ? p += y.source : l = !0 : f += y.source, a = !0, u = !0, (h || d) && (m = !0), c = !0;
2380
+ c ? f ? f += b.source : a = !0 : d += b.source, c = !0, h = !0, (p || g) && (w = b), m = !0;
2381
2381
  break;
2382
2382
  case "anchor":
2383
- h && r(y, "MULTIPLE_ANCHORS", "A node can have at most one anchor"), y.source.endsWith(":") && r(y.offset + y.source.length - 1, "BAD_ALIAS", "Anchor ending in : is ambiguous", !0), h = y, k === null && (k = y.offset), a = !1, c = !1, g = !0;
2383
+ p && r(b, "MULTIPLE_ANCHORS", "A node can have at most one anchor"), b.source.endsWith(":") && r(b.offset + b.source.length - 1, "BAD_ALIAS", "Anchor ending in : is ambiguous", !0), p = b, A === null && (A = b.offset), c = !1, m = !1, y = !0;
2384
2384
  break;
2385
2385
  case "tag": {
2386
- d && r(y, "MULTIPLE_TAGS", "A node can have at most one tag"), d = y, k === null && (k = y.offset), a = !1, c = !1, g = !0;
2386
+ g && r(b, "MULTIPLE_TAGS", "A node can have at most one tag"), g = b, A === null && (A = b.offset), c = !1, m = !1, y = !0;
2387
2387
  break;
2388
2388
  }
2389
2389
  case t:
2390
- (h || d) && r(y, "BAD_PROP_ORDER", `Anchors and tags must be after the ${y.source} indicator`), w && r(y, "UNEXPECTED_TOKEN", `Unexpected ${y.source} in ${e ?? "collection"}`), w = y, a = !1, c = !1;
2390
+ (p || g) && r(b, "BAD_PROP_ORDER", `Anchors and tags must be after the ${b.source} indicator`), S && r(b, "UNEXPECTED_TOKEN", `Unexpected ${b.source} in ${e ?? "collection"}`), S = b, c = t === "seq-item-ind" || t === "explicit-key-ind", m = !1;
2391
2391
  break;
2392
2392
  case "comma":
2393
2393
  if (e) {
2394
- b && r(y, "UNEXPECTED_TOKEN", `Unexpected , in ${e}`), b = y, a = !1, c = !1;
2394
+ N && r(b, "UNEXPECTED_TOKEN", `Unexpected , in ${e}`), N = b, c = !1, m = !1;
2395
2395
  break;
2396
2396
  }
2397
2397
  default:
2398
- r(y, "UNEXPECTED_TOKEN", `Unexpected ${y.type} token`), a = !1, c = !1;
2398
+ r(b, "UNEXPECTED_TOKEN", `Unexpected ${b.type} token`), c = !1, m = !1;
2399
2399
  }
2400
- const S = s[s.length - 1], O = S ? S.offset + S.source.length : i;
2401
- return g && n && n.type !== "space" && n.type !== "newline" && n.type !== "comma" && (n.type !== "scalar" || n.source !== "") && r(n.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), {
2402
- comma: b,
2403
- found: w,
2404
- spaceBefore: l,
2405
- comment: p,
2406
- hasNewline: u,
2407
- hasNewlineAfterProp: m,
2408
- anchor: h,
2409
- tag: d,
2410
- end: O,
2411
- start: k ?? O
2400
+ const k = s[s.length - 1], T = k ? k.offset + k.source.length : i;
2401
+ return y && n && n.type !== "space" && n.type !== "newline" && n.type !== "comma" && (n.type !== "scalar" || n.source !== "") && r(n.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), u && (c && u.indent <= o || (n == null ? void 0 : n.type) === "block-map" || (n == null ? void 0 : n.type) === "block-seq") && r(u, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), {
2402
+ comma: N,
2403
+ found: S,
2404
+ spaceBefore: a,
2405
+ comment: f,
2406
+ hasNewline: h,
2407
+ anchor: p,
2408
+ tag: g,
2409
+ newlineAfterProp: w,
2410
+ end: T,
2411
+ start: A ?? T
2412
2412
  };
2413
2413
  }
2414
2414
  function ke(s) {
@@ -2456,76 +2456,79 @@ function ps(s, e, t) {
2456
2456
  const { uniqueKeys: n } = s.options;
2457
2457
  if (n === !1)
2458
2458
  return !1;
2459
- const i = typeof n == "function" ? n : (r, o) => r === o || A(r) && A(o) && r.value === o.value && !(r.value === "<<" && s.schema.merge);
2459
+ const i = typeof n == "function" ? n : (r, o) => r === o || E(r) && E(o) && r.value === o.value && !(r.value === "<<" && s.schema.merge);
2460
2460
  return e.some((r) => i(r.key, t));
2461
2461
  }
2462
- const Bt = "All mapping items must start at the same column";
2462
+ const vt = "All mapping items must start at the same column";
2463
2463
  function on({ composeNode: s, composeEmptyNode: e }, t, n, i, r) {
2464
- var p;
2464
+ var m;
2465
2465
  const o = (r == null ? void 0 : r.nodeClass) ?? P, l = new o(t.schema);
2466
2466
  t.atRoot && (t.atRoot = !1);
2467
2467
  let a = n.offset, c = null;
2468
2468
  for (const f of n.items) {
2469
- const { start: u, key: m, sep: g, value: h } = f, d = ce(u, {
2469
+ const { start: d, key: h, sep: y, value: u } = f, p = ce(d, {
2470
2470
  indicator: "explicit-key-ind",
2471
- next: m ?? (g == null ? void 0 : g[0]),
2471
+ next: h ?? (y == null ? void 0 : y[0]),
2472
2472
  offset: a,
2473
2473
  onError: i,
2474
+ parentIndent: n.indent,
2474
2475
  startOnNewline: !0
2475
- }), b = !d.found;
2476
- if (b) {
2477
- if (m && (m.type === "block-seq" ? i(a, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key") : "indent" in m && m.indent !== n.indent && i(a, "BAD_INDENT", Bt)), !d.anchor && !d.tag && !g) {
2478
- c = d.end, d.comment && (l.comment ? l.comment += `
2479
- ` + d.comment : l.comment = d.comment);
2476
+ }), g = !p.found;
2477
+ if (g) {
2478
+ if (h && (h.type === "block-seq" ? i(a, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key") : "indent" in h && h.indent !== n.indent && i(a, "BAD_INDENT", vt)), !p.anchor && !p.tag && !y) {
2479
+ c = p.end, p.comment && (l.comment ? l.comment += `
2480
+ ` + p.comment : l.comment = p.comment);
2480
2481
  continue;
2481
2482
  }
2482
- (d.hasNewlineAfterProp || ke(m)) && i(m ?? u[u.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line");
2483
- } else ((p = d.found) == null ? void 0 : p.indent) !== n.indent && i(a, "BAD_INDENT", Bt);
2484
- const w = d.end, k = m ? s(t, m, d, i) : e(t, w, u, null, d, i);
2485
- t.schema.compat && ct(n.indent, m, i), ps(t, l.items, k) && i(w, "DUPLICATE_KEY", "Map keys must be unique");
2486
- const S = ce(g ?? [], {
2483
+ (p.newlineAfterProp || ke(h)) && i(h ?? d[d.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line");
2484
+ } else ((m = p.found) == null ? void 0 : m.indent) !== n.indent && i(a, "BAD_INDENT", vt);
2485
+ const w = p.end, N = h ? s(t, h, p, i) : e(t, w, d, null, p, i);
2486
+ t.schema.compat && ct(n.indent, h, i), ps(t, l.items, N) && i(w, "DUPLICATE_KEY", "Map keys must be unique");
2487
+ const S = ce(y ?? [], {
2487
2488
  indicator: "map-value-ind",
2488
- next: h,
2489
- offset: k.range[2],
2489
+ next: u,
2490
+ offset: N.range[2],
2490
2491
  onError: i,
2491
- startOnNewline: !m || m.type === "block-scalar"
2492
+ parentIndent: n.indent,
2493
+ startOnNewline: !h || h.type === "block-scalar"
2492
2494
  });
2493
2495
  if (a = S.end, S.found) {
2494
- b && ((h == null ? void 0 : h.type) === "block-map" && !S.hasNewline && i(a, "BLOCK_AS_IMPLICIT_KEY", "Nested mappings are not allowed in compact mappings"), t.options.strict && d.start < S.found.offset - 1024 && i(k.range, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));
2495
- const O = h ? s(t, h, S, i) : e(t, a, g, null, S, i);
2496
- t.schema.compat && ct(n.indent, h, i), a = O.range[2];
2497
- const y = new v(k, O);
2498
- t.options.keepSourceTokens && (y.srcToken = f), l.items.push(y);
2496
+ g && ((u == null ? void 0 : u.type) === "block-map" && !S.hasNewline && i(a, "BLOCK_AS_IMPLICIT_KEY", "Nested mappings are not allowed in compact mappings"), t.options.strict && p.start < S.found.offset - 1024 && i(N.range, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));
2497
+ const A = u ? s(t, u, S, i) : e(t, a, y, null, S, i);
2498
+ t.schema.compat && ct(n.indent, u, i), a = A.range[2];
2499
+ const k = new v(N, A);
2500
+ t.options.keepSourceTokens && (k.srcToken = f), l.items.push(k);
2499
2501
  } else {
2500
- b && i(k.range, "MISSING_CHAR", "Implicit map keys need to be followed by map values"), S.comment && (k.comment ? k.comment += `
2501
- ` + S.comment : k.comment = S.comment);
2502
- const O = new v(k);
2503
- t.options.keepSourceTokens && (O.srcToken = f), l.items.push(O);
2502
+ g && i(N.range, "MISSING_CHAR", "Implicit map keys need to be followed by map values"), S.comment && (N.comment ? N.comment += `
2503
+ ` + S.comment : N.comment = S.comment);
2504
+ const A = new v(N);
2505
+ t.options.keepSourceTokens && (A.srcToken = f), l.items.push(A);
2504
2506
  }
2505
2507
  }
2506
2508
  return c && c < a && i(c, "IMPOSSIBLE", "Map comment with trailing content"), l.range = [n.offset, a, c ?? a], l;
2507
2509
  }
2508
2510
  function ln({ composeNode: s, composeEmptyNode: e }, t, n, i, r) {
2509
- const o = (r == null ? void 0 : r.nodeClass) ?? G, l = new o(t.schema);
2511
+ const o = (r == null ? void 0 : r.nodeClass) ?? J, l = new o(t.schema);
2510
2512
  t.atRoot && (t.atRoot = !1);
2511
2513
  let a = n.offset, c = null;
2512
- for (const { start: p, value: f } of n.items) {
2513
- const u = ce(p, {
2514
+ for (const { start: m, value: f } of n.items) {
2515
+ const d = ce(m, {
2514
2516
  indicator: "seq-item-ind",
2515
2517
  next: f,
2516
2518
  offset: a,
2517
2519
  onError: i,
2520
+ parentIndent: n.indent,
2518
2521
  startOnNewline: !0
2519
2522
  });
2520
- if (!u.found)
2521
- if (u.anchor || u.tag || f)
2522
- f && f.type === "block-seq" ? i(u.end, "BAD_INDENT", "All sequence items must start at the same column") : i(a, "MISSING_CHAR", "Sequence item without - indicator");
2523
+ if (!d.found)
2524
+ if (d.anchor || d.tag || f)
2525
+ f && f.type === "block-seq" ? i(d.end, "BAD_INDENT", "All sequence items must start at the same column") : i(a, "MISSING_CHAR", "Sequence item without - indicator");
2523
2526
  else {
2524
- c = u.end, u.comment && (l.comment = u.comment);
2527
+ c = d.end, d.comment && (l.comment = d.comment);
2525
2528
  continue;
2526
2529
  }
2527
- const m = f ? s(t, f, u, i) : e(t, u.end, p, null, u, i);
2528
- t.schema.compat && ct(n.indent, f, i), a = m.range[2], l.items.push(m);
2530
+ const h = f ? s(t, f, d, i) : e(t, d.end, m, null, d, i);
2531
+ t.schema.compat && ct(n.indent, f, i), a = h.range[2], l.items.push(h);
2529
2532
  }
2530
2533
  return l.range = [n.offset, a, c ?? a], l;
2531
2534
  }
@@ -2541,8 +2544,8 @@ function Ee(s, e, t, n) {
2541
2544
  break;
2542
2545
  case "comment": {
2543
2546
  t && !r && n(l, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters");
2544
- const p = a.substring(1) || " ";
2545
- i ? i += o + p : i = p, o = "";
2547
+ const m = a.substring(1) || " ";
2548
+ i ? i += o + m : i = m, o = "";
2546
2549
  break;
2547
2550
  }
2548
2551
  case "newline":
@@ -2556,196 +2559,203 @@ function Ee(s, e, t, n) {
2556
2559
  }
2557
2560
  return { comment: i, offset: e };
2558
2561
  }
2559
- const xe = "Block collections are not allowed within flow collections", et = (s) => s && (s.type === "block-map" || s.type === "block-seq");
2562
+ const et = "Block collections are not allowed within flow collections", tt = (s) => s && (s.type === "block-map" || s.type === "block-seq");
2560
2563
  function an({ composeNode: s, composeEmptyNode: e }, t, n, i, r) {
2561
- const o = n.start.source === "{", l = o ? "flow map" : "flow sequence", a = (r == null ? void 0 : r.nodeClass) ?? (o ? P : G), c = new a(t.schema);
2564
+ const o = n.start.source === "{", l = o ? "flow map" : "flow sequence", a = (r == null ? void 0 : r.nodeClass) ?? (o ? P : J), c = new a(t.schema);
2562
2565
  c.flow = !0;
2563
- const p = t.atRoot;
2564
- p && (t.atRoot = !1);
2566
+ const m = t.atRoot;
2567
+ m && (t.atRoot = !1);
2565
2568
  let f = n.offset + n.start.source.length;
2566
- for (let d = 0; d < n.items.length; ++d) {
2567
- const b = n.items[d], { start: w, key: k, sep: S, value: O } = b, y = ce(w, {
2569
+ for (let p = 0; p < n.items.length; ++p) {
2570
+ const g = n.items[p], { start: w, key: N, sep: S, value: A } = g, k = ce(w, {
2568
2571
  flow: l,
2569
2572
  indicator: "explicit-key-ind",
2570
- next: k ?? (S == null ? void 0 : S[0]),
2573
+ next: N ?? (S == null ? void 0 : S[0]),
2571
2574
  offset: f,
2572
2575
  onError: i,
2576
+ parentIndent: n.indent,
2573
2577
  startOnNewline: !1
2574
2578
  });
2575
- if (!y.found) {
2576
- if (!y.anchor && !y.tag && !S && !O) {
2577
- d === 0 && y.comma ? i(y.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${l}`) : d < n.items.length - 1 && i(y.start, "UNEXPECTED_TOKEN", `Unexpected empty item in ${l}`), y.comment && (c.comment ? c.comment += `
2578
- ` + y.comment : c.comment = y.comment), f = y.end;
2579
+ if (!k.found) {
2580
+ if (!k.anchor && !k.tag && !S && !A) {
2581
+ p === 0 && k.comma ? i(k.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${l}`) : p < n.items.length - 1 && i(k.start, "UNEXPECTED_TOKEN", `Unexpected empty item in ${l}`), k.comment && (c.comment ? c.comment += `
2582
+ ` + k.comment : c.comment = k.comment), f = k.end;
2579
2583
  continue;
2580
2584
  }
2581
- !o && t.options.strict && ke(k) && i(
2582
- k,
2585
+ !o && t.options.strict && ke(N) && i(
2586
+ N,
2583
2587
  // checked by containsNewline()
2584
2588
  "MULTILINE_IMPLICIT_KEY",
2585
2589
  "Implicit keys of flow sequence pairs need to be on a single line"
2586
2590
  );
2587
2591
  }
2588
- if (d === 0)
2589
- y.comma && i(y.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${l}`);
2590
- else if (y.comma || i(y.start, "MISSING_CHAR", `Missing , between ${l} items`), y.comment) {
2591
- let I = "";
2592
- e: for (const L of w)
2593
- switch (L.type) {
2592
+ if (p === 0)
2593
+ k.comma && i(k.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${l}`);
2594
+ else if (k.comma || i(k.start, "MISSING_CHAR", `Missing , between ${l} items`), k.comment) {
2595
+ let T = "";
2596
+ e: for (const b of w)
2597
+ switch (b.type) {
2594
2598
  case "comma":
2595
2599
  case "space":
2596
2600
  break;
2597
2601
  case "comment":
2598
- I = L.source.substring(1);
2602
+ T = b.source.substring(1);
2599
2603
  break e;
2600
2604
  default:
2601
2605
  break e;
2602
2606
  }
2603
- if (I) {
2604
- let L = c.items[c.items.length - 1];
2605
- E(L) && (L = L.value ?? L.key), L.comment ? L.comment += `
2606
- ` + I : L.comment = I, y.comment = y.comment.substring(I.length + 1);
2607
+ if (T) {
2608
+ let b = c.items[c.items.length - 1];
2609
+ I(b) && (b = b.value ?? b.key), b.comment ? b.comment += `
2610
+ ` + T : b.comment = T, k.comment = k.comment.substring(T.length + 1);
2607
2611
  }
2608
2612
  }
2609
- if (!o && !S && !y.found) {
2610
- const I = O ? s(t, O, y, i) : e(t, y.end, S, null, y, i);
2611
- c.items.push(I), f = I.range[2], et(O) && i(I.range, "BLOCK_IN_FLOW", xe);
2613
+ if (!o && !S && !k.found) {
2614
+ const T = A ? s(t, A, k, i) : e(t, k.end, S, null, k, i);
2615
+ c.items.push(T), f = T.range[2], tt(A) && i(T.range, "BLOCK_IN_FLOW", et);
2612
2616
  } else {
2613
- const I = y.end, L = k ? s(t, k, y, i) : e(t, I, w, null, y, i);
2614
- et(k) && i(L.range, "BLOCK_IN_FLOW", xe);
2615
- const C = ce(S ?? [], {
2617
+ const T = k.end, b = N ? s(t, N, k, i) : e(t, T, w, null, k, i);
2618
+ tt(N) && i(b.range, "BLOCK_IN_FLOW", et);
2619
+ const _ = ce(S ?? [], {
2616
2620
  flow: l,
2617
2621
  indicator: "map-value-ind",
2618
- next: O,
2619
- offset: L.range[2],
2622
+ next: A,
2623
+ offset: b.range[2],
2620
2624
  onError: i,
2625
+ parentIndent: n.indent,
2621
2626
  startOnNewline: !1
2622
2627
  });
2623
- if (C.found) {
2624
- if (!o && !y.found && t.options.strict) {
2628
+ if (_.found) {
2629
+ if (!o && !k.found && t.options.strict) {
2625
2630
  if (S)
2626
- for (const _ of S) {
2627
- if (_ === C.found)
2631
+ for (const C of S) {
2632
+ if (C === _.found)
2628
2633
  break;
2629
- if (_.type === "newline") {
2630
- i(_, "MULTILINE_IMPLICIT_KEY", "Implicit keys of flow sequence pairs need to be on a single line");
2634
+ if (C.type === "newline") {
2635
+ i(C, "MULTILINE_IMPLICIT_KEY", "Implicit keys of flow sequence pairs need to be on a single line");
2631
2636
  break;
2632
2637
  }
2633
2638
  }
2634
- y.start < C.found.offset - 1024 && i(C.found, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit flow sequence key");
2639
+ k.start < _.found.offset - 1024 && i(_.found, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit flow sequence key");
2635
2640
  }
2636
- } else O && ("source" in O && O.source && O.source[0] === ":" ? i(O, "MISSING_CHAR", `Missing space after : in ${l}`) : i(C.start, "MISSING_CHAR", `Missing , or : between ${l} items`));
2637
- const Q = O ? s(t, O, C, i) : C.found ? e(t, C.end, S, null, C, i) : null;
2638
- Q ? et(O) && i(Q.range, "BLOCK_IN_FLOW", xe) : C.comment && (L.comment ? L.comment += `
2639
- ` + C.comment : L.comment = C.comment);
2640
- const x = new v(L, Q);
2641
- if (t.options.keepSourceTokens && (x.srcToken = b), o) {
2642
- const _ = c;
2643
- ps(t, _.items, L) && i(I, "DUPLICATE_KEY", "Map keys must be unique"), _.items.push(x);
2641
+ } else A && ("source" in A && A.source && A.source[0] === ":" ? i(A, "MISSING_CHAR", `Missing space after : in ${l}`) : i(_.start, "MISSING_CHAR", `Missing , or : between ${l} items`));
2642
+ const G = A ? s(t, A, _, i) : _.found ? e(t, _.end, S, null, _, i) : null;
2643
+ G ? tt(A) && i(G.range, "BLOCK_IN_FLOW", et) : _.comment && (b.comment ? b.comment += `
2644
+ ` + _.comment : b.comment = _.comment);
2645
+ const x = new v(b, G);
2646
+ if (t.options.keepSourceTokens && (x.srcToken = g), o) {
2647
+ const C = c;
2648
+ ps(t, C.items, b) && i(T, "DUPLICATE_KEY", "Map keys must be unique"), C.items.push(x);
2644
2649
  } else {
2645
- const _ = new P(t.schema);
2646
- _.flow = !0, _.items.push(x), c.items.push(_);
2650
+ const C = new P(t.schema);
2651
+ C.flow = !0, C.items.push(x), c.items.push(C);
2647
2652
  }
2648
- f = Q ? Q.range[2] : C.end;
2653
+ f = G ? G.range[2] : _.end;
2649
2654
  }
2650
2655
  }
2651
- const u = o ? "}" : "]", [m, ...g] = n.end;
2652
- let h = f;
2653
- if (m && m.source === u)
2654
- h = m.offset + m.source.length;
2656
+ const d = o ? "}" : "]", [h, ...y] = n.end;
2657
+ let u = f;
2658
+ if (h && h.source === d)
2659
+ u = h.offset + h.source.length;
2655
2660
  else {
2656
- const d = l[0].toUpperCase() + l.substring(1), b = p ? `${d} must end with a ${u}` : `${d} in block collection must be sufficiently indented and end with a ${u}`;
2657
- i(f, p ? "MISSING_CHAR" : "BAD_INDENT", b), m && m.source.length !== 1 && g.unshift(m);
2661
+ const p = l[0].toUpperCase() + l.substring(1), g = m ? `${p} must end with a ${d}` : `${p} in block collection must be sufficiently indented and end with a ${d}`;
2662
+ i(f, m ? "MISSING_CHAR" : "BAD_INDENT", g), h && h.source.length !== 1 && y.unshift(h);
2658
2663
  }
2659
- if (g.length > 0) {
2660
- const d = Ee(g, h, t.options.strict, i);
2661
- d.comment && (c.comment ? c.comment += `
2662
- ` + d.comment : c.comment = d.comment), c.range = [n.offset, h, d.offset];
2664
+ if (y.length > 0) {
2665
+ const p = Ee(y, u, t.options.strict, i);
2666
+ p.comment && (c.comment ? c.comment += `
2667
+ ` + p.comment : c.comment = p.comment), c.range = [n.offset, u, p.offset];
2663
2668
  } else
2664
- c.range = [n.offset, h, h];
2669
+ c.range = [n.offset, u, u];
2665
2670
  return c;
2666
2671
  }
2667
- function tt(s, e, t, n, i, r) {
2672
+ function st(s, e, t, n, i, r) {
2668
2673
  const o = t.type === "block-map" ? on(s, e, t, n, r) : t.type === "block-seq" ? ln(s, e, t, n, r) : an(s, e, t, n, r), l = o.constructor;
2669
2674
  return i === "!" || i === l.tagName ? (o.tag = l.tagName, o) : (i && (o.tag = i), o);
2670
2675
  }
2671
2676
  function cn(s, e, t, n, i) {
2672
- var f;
2673
- const r = n ? e.directives.tagName(n.source, (u) => i(n, "TAG_RESOLVE_FAILED", u)) : null, o = t.type === "block-map" ? "map" : t.type === "block-seq" ? "seq" : t.start.source === "{" ? "map" : "seq";
2674
- if (!n || !r || r === "!" || r === P.tagName && o === "map" || r === G.tagName && o === "seq" || !o)
2675
- return tt(s, e, t, i, r);
2676
- let l = e.schema.tags.find((u) => u.tag === r && u.collection === o);
2677
- if (!l) {
2678
- const u = e.schema.knownTags[r];
2679
- if (u && u.collection === o)
2680
- e.schema.tags.push(Object.assign({}, u, { default: !1 })), l = u;
2677
+ var d;
2678
+ const r = n.tag, o = r ? e.directives.tagName(r.source, (h) => i(r, "TAG_RESOLVE_FAILED", h)) : null;
2679
+ if (t.type === "block-seq") {
2680
+ const { anchor: h, newlineAfterProp: y } = n, u = h && r ? h.offset > r.offset ? h : r : h ?? r;
2681
+ u && (!y || y.offset < u.offset) && i(u, "MISSING_CHAR", "Missing newline after block sequence props");
2682
+ }
2683
+ const l = t.type === "block-map" ? "map" : t.type === "block-seq" ? "seq" : t.start.source === "{" ? "map" : "seq";
2684
+ if (!r || !o || o === "!" || o === P.tagName && l === "map" || o === J.tagName && l === "seq")
2685
+ return st(s, e, t, i, o);
2686
+ let a = e.schema.tags.find((h) => h.tag === o && h.collection === l);
2687
+ if (!a) {
2688
+ const h = e.schema.knownTags[o];
2689
+ if (h && h.collection === l)
2690
+ e.schema.tags.push(Object.assign({}, h, { default: !1 })), a = h;
2681
2691
  else
2682
- return u != null && u.collection ? i(n, "BAD_COLLECTION_TYPE", `${u.tag} used for ${o} collection, but expects ${u.collection}`, !0) : i(n, "TAG_RESOLVE_FAILED", `Unresolved tag: ${r}`, !0), tt(s, e, t, i, r);
2692
+ return h != null && h.collection ? i(r, "BAD_COLLECTION_TYPE", `${h.tag} used for ${l} collection, but expects ${h.collection}`, !0) : i(r, "TAG_RESOLVE_FAILED", `Unresolved tag: ${o}`, !0), st(s, e, t, i, o);
2683
2693
  }
2684
- const a = tt(s, e, t, i, r, l), c = ((f = l.resolve) == null ? void 0 : f.call(l, a, (u) => i(n, "TAG_RESOLVE_FAILED", u), e.options)) ?? a, p = $(c) ? c : new N(c);
2685
- return p.range = a.range, p.tag = r, l != null && l.format && (p.format = l.format), p;
2694
+ const c = st(s, e, t, i, o, a), m = ((d = a.resolve) == null ? void 0 : d.call(a, c, (h) => i(r, "TAG_RESOLVE_FAILED", h), e.options)) ?? c, f = $(m) ? m : new O(m);
2695
+ return f.range = c.range, f.tag = o, a != null && a.format && (f.format = a.format), f;
2686
2696
  }
2687
2697
  function ms(s, e, t) {
2688
- const n = s.offset, i = fn(s, e, t);
2698
+ const n = e.offset, i = fn(e, s.options.strict, t);
2689
2699
  if (!i)
2690
2700
  return { value: "", type: null, comment: "", range: [n, n, n] };
2691
- const r = i.mode === ">" ? N.BLOCK_FOLDED : N.BLOCK_LITERAL, o = s.source ? un(s.source) : [];
2701
+ const r = i.mode === ">" ? O.BLOCK_FOLDED : O.BLOCK_LITERAL, o = e.source ? un(e.source) : [];
2692
2702
  let l = o.length;
2693
- for (let h = o.length - 1; h >= 0; --h) {
2694
- const d = o[h][1];
2695
- if (d === "" || d === "\r")
2696
- l = h;
2703
+ for (let u = o.length - 1; u >= 0; --u) {
2704
+ const p = o[u][1];
2705
+ if (p === "" || p === "\r")
2706
+ l = u;
2697
2707
  else
2698
2708
  break;
2699
2709
  }
2700
2710
  if (l === 0) {
2701
- const h = i.chomp === "+" && o.length > 0 ? `
2711
+ const u = i.chomp === "+" && o.length > 0 ? `
2702
2712
  `.repeat(Math.max(1, o.length - 1)) : "";
2703
- let d = n + i.length;
2704
- return s.source && (d += s.source.length), { value: h, type: r, comment: i.comment, range: [n, d, d] };
2705
- }
2706
- let a = s.indent + i.indent, c = s.offset + i.length, p = 0;
2707
- for (let h = 0; h < l; ++h) {
2708
- const [d, b] = o[h];
2709
- if (b === "" || b === "\r")
2710
- i.indent === 0 && d.length > a && (a = d.length);
2713
+ let p = n + i.length;
2714
+ return e.source && (p += e.source.length), { value: u, type: r, comment: i.comment, range: [n, p, p] };
2715
+ }
2716
+ let a = e.indent + i.indent, c = e.offset + i.length, m = 0;
2717
+ for (let u = 0; u < l; ++u) {
2718
+ const [p, g] = o[u];
2719
+ if (g === "" || g === "\r")
2720
+ i.indent === 0 && p.length > a && (a = p.length);
2711
2721
  else {
2712
- d.length < a && t(c + d.length, "MISSING_CHAR", "Block scalars with more-indented leading empty lines must use an explicit indentation indicator"), i.indent === 0 && (a = d.length), p = h;
2722
+ p.length < a && t(c + p.length, "MISSING_CHAR", "Block scalars with more-indented leading empty lines must use an explicit indentation indicator"), i.indent === 0 && (a = p.length), m = u, a === 0 && !s.atRoot && t(c, "BAD_INDENT", "Block scalar values in collections must be indented");
2713
2723
  break;
2714
2724
  }
2715
- c += d.length + b.length + 1;
2725
+ c += p.length + g.length + 1;
2716
2726
  }
2717
- for (let h = o.length - 1; h >= l; --h)
2718
- o[h][0].length > a && (l = h + 1);
2719
- let f = "", u = "", m = !1;
2720
- for (let h = 0; h < p; ++h)
2721
- f += o[h][0].slice(a) + `
2727
+ for (let u = o.length - 1; u >= l; --u)
2728
+ o[u][0].length > a && (l = u + 1);
2729
+ let f = "", d = "", h = !1;
2730
+ for (let u = 0; u < m; ++u)
2731
+ f += o[u][0].slice(a) + `
2722
2732
  `;
2723
- for (let h = p; h < l; ++h) {
2724
- let [d, b] = o[h];
2725
- c += d.length + b.length + 1;
2726
- const w = b[b.length - 1] === "\r";
2727
- if (w && (b = b.slice(0, -1)), b && d.length < a) {
2733
+ for (let u = m; u < l; ++u) {
2734
+ let [p, g] = o[u];
2735
+ c += p.length + g.length + 1;
2736
+ const w = g[g.length - 1] === "\r";
2737
+ if (w && (g = g.slice(0, -1)), g && p.length < a) {
2728
2738
  const S = `Block scalar lines must not be less indented than their ${i.indent ? "explicit indentation indicator" : "first line"}`;
2729
- t(c - b.length - (w ? 2 : 1), "BAD_INDENT", S), d = "";
2739
+ t(c - g.length - (w ? 2 : 1), "BAD_INDENT", S), p = "";
2730
2740
  }
2731
- r === N.BLOCK_LITERAL ? (f += u + d.slice(a) + b, u = `
2732
- `) : d.length > a || b[0] === " " ? (u === " " ? u = `
2733
- ` : !m && u === `
2734
- ` && (u = `
2741
+ r === O.BLOCK_LITERAL ? (f += d + p.slice(a) + g, d = `
2742
+ `) : p.length > a || g[0] === " " ? (d === " " ? d = `
2743
+ ` : !h && d === `
2744
+ ` && (d = `
2735
2745
 
2736
- `), f += u + d.slice(a) + b, u = `
2737
- `, m = !0) : b === "" ? u === `
2746
+ `), f += d + p.slice(a) + g, d = `
2747
+ `, h = !0) : g === "" ? d === `
2738
2748
  ` ? f += `
2739
- ` : u = `
2740
- ` : (f += u + b, u = " ", m = !1);
2749
+ ` : d = `
2750
+ ` : (f += d + g, d = " ", h = !1);
2741
2751
  }
2742
2752
  switch (i.chomp) {
2743
2753
  case "-":
2744
2754
  break;
2745
2755
  case "+":
2746
- for (let h = l; h < o.length; ++h)
2756
+ for (let u = l; u < o.length; ++u)
2747
2757
  f += `
2748
- ` + o[h][0].slice(a);
2758
+ ` + o[u][0].slice(a);
2749
2759
  f[f.length - 1] !== `
2750
2760
  ` && (f += `
2751
2761
  `);
@@ -2754,48 +2764,48 @@ function ms(s, e, t) {
2754
2764
  f += `
2755
2765
  `;
2756
2766
  }
2757
- const g = n + i.length + s.source.length;
2758
- return { value: f, type: r, comment: i.comment, range: [n, g, g] };
2767
+ const y = n + i.length + e.source.length;
2768
+ return { value: f, type: r, comment: i.comment, range: [n, y, y] };
2759
2769
  }
2760
2770
  function fn({ offset: s, props: e }, t, n) {
2761
2771
  if (e[0].type !== "block-scalar-header")
2762
2772
  return n(e[0], "IMPOSSIBLE", "Block scalar header not found"), null;
2763
2773
  const { source: i } = e[0], r = i[0];
2764
2774
  let o = 0, l = "", a = -1;
2765
- for (let u = 1; u < i.length; ++u) {
2766
- const m = i[u];
2767
- if (!l && (m === "-" || m === "+"))
2768
- l = m;
2775
+ for (let d = 1; d < i.length; ++d) {
2776
+ const h = i[d];
2777
+ if (!l && (h === "-" || h === "+"))
2778
+ l = h;
2769
2779
  else {
2770
- const g = Number(m);
2771
- !o && g ? o = g : a === -1 && (a = s + u);
2780
+ const y = Number(h);
2781
+ !o && y ? o = y : a === -1 && (a = s + d);
2772
2782
  }
2773
2783
  }
2774
2784
  a !== -1 && n(a, "UNEXPECTED_TOKEN", `Block scalar header includes extra characters: ${i}`);
2775
- let c = !1, p = "", f = i.length;
2776
- for (let u = 1; u < e.length; ++u) {
2777
- const m = e[u];
2778
- switch (m.type) {
2785
+ let c = !1, m = "", f = i.length;
2786
+ for (let d = 1; d < e.length; ++d) {
2787
+ const h = e[d];
2788
+ switch (h.type) {
2779
2789
  case "space":
2780
2790
  c = !0;
2781
2791
  case "newline":
2782
- f += m.source.length;
2792
+ f += h.source.length;
2783
2793
  break;
2784
2794
  case "comment":
2785
- t && !c && n(m, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters"), f += m.source.length, p = m.source.substring(1);
2795
+ t && !c && n(h, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters"), f += h.source.length, m = h.source.substring(1);
2786
2796
  break;
2787
2797
  case "error":
2788
- n(m, "UNEXPECTED_TOKEN", m.message), f += m.source.length;
2798
+ n(h, "UNEXPECTED_TOKEN", h.message), f += h.source.length;
2789
2799
  break;
2790
2800
  default: {
2791
- const g = `Unexpected token in block scalar header: ${m.type}`;
2792
- n(m, "UNEXPECTED_TOKEN", g);
2793
- const h = m.source;
2794
- h && typeof h == "string" && (f += h.length);
2801
+ const y = `Unexpected token in block scalar header: ${h.type}`;
2802
+ n(h, "UNEXPECTED_TOKEN", y);
2803
+ const u = h.source;
2804
+ u && typeof u == "string" && (f += u.length);
2795
2805
  }
2796
2806
  }
2797
2807
  }
2798
- return { mode: r, indent: o, chomp: l, comment: p, length: f };
2808
+ return { mode: r, indent: o, chomp: l, comment: m, length: f };
2799
2809
  }
2800
2810
  function un(s) {
2801
2811
  const e = s.split(/\n( *)/), t = e[0], n = t.match(/^( *)/), r = [n != null && n[1] ? [n[1], t.slice(n[1].length)] : ["", t]];
@@ -2806,16 +2816,16 @@ function un(s) {
2806
2816
  function ys(s, e, t) {
2807
2817
  const { offset: n, type: i, source: r, end: o } = s;
2808
2818
  let l, a;
2809
- const c = (u, m, g) => t(n + u, m, g);
2819
+ const c = (d, h, y) => t(n + d, h, y);
2810
2820
  switch (i) {
2811
2821
  case "scalar":
2812
- l = N.PLAIN, a = hn(r, c);
2822
+ l = O.PLAIN, a = hn(r, c);
2813
2823
  break;
2814
2824
  case "single-quoted-scalar":
2815
- l = N.QUOTE_SINGLE, a = dn(r, c);
2825
+ l = O.QUOTE_SINGLE, a = dn(r, c);
2816
2826
  break;
2817
2827
  case "double-quoted-scalar":
2818
- l = N.QUOTE_DOUBLE, a = pn(r, c);
2828
+ l = O.QUOTE_DOUBLE, a = pn(r, c);
2819
2829
  break;
2820
2830
  default:
2821
2831
  return t(s, "UNEXPECTED_TOKEN", `Expected a flow scalar value, but found: ${i}`), {
@@ -2825,12 +2835,12 @@ function ys(s, e, t) {
2825
2835
  range: [n, n + r.length, n + r.length]
2826
2836
  };
2827
2837
  }
2828
- const p = n + r.length, f = Ee(o, p, e, t);
2838
+ const m = n + r.length, f = Ee(o, m, e, t);
2829
2839
  return {
2830
2840
  value: a,
2831
2841
  type: l,
2832
2842
  comment: f.comment,
2833
- range: [n, p, f.offset]
2843
+ range: [n, m, f.offset]
2834
2844
  };
2835
2845
  }
2836
2846
  function hn(s, e) {
@@ -2977,21 +2987,21 @@ function gn(s, e, t, n) {
2977
2987
  return String.fromCodePoint(o);
2978
2988
  }
2979
2989
  function bs(s, e, t, n) {
2980
- const { value: i, type: r, comment: o, range: l } = e.type === "block-scalar" ? ms(e, s.options.strict, n) : ys(e, s.options.strict, n), a = t ? s.directives.tagName(t.source, (f) => n(t, "TAG_RESOLVE_FAILED", f)) : null, c = t && a ? bn(s.schema, i, a, t, n) : e.type === "scalar" ? wn(s, i, e, n) : s.schema[V];
2981
- let p;
2990
+ const { value: i, type: r, comment: o, range: l } = e.type === "block-scalar" ? ms(s, e, n) : ys(e, s.options.strict, n), a = t ? s.directives.tagName(t.source, (f) => n(t, "TAG_RESOLVE_FAILED", f)) : null, c = t && a ? bn(s.schema, i, a, t, n) : e.type === "scalar" ? wn(s, i, e, n) : s.schema[R];
2991
+ let m;
2982
2992
  try {
2983
- const f = c.resolve(i, (u) => n(t ?? e, "TAG_RESOLVE_FAILED", u), s.options);
2984
- p = A(f) ? f : new N(f);
2993
+ const f = c.resolve(i, (d) => n(t ?? e, "TAG_RESOLVE_FAILED", d), s.options);
2994
+ m = E(f) ? f : new O(f);
2985
2995
  } catch (f) {
2986
- const u = f instanceof Error ? f.message : String(f);
2987
- n(t ?? e, "TAG_RESOLVE_FAILED", u), p = new N(i);
2996
+ const d = f instanceof Error ? f.message : String(f);
2997
+ n(t ?? e, "TAG_RESOLVE_FAILED", d), m = new O(i);
2988
2998
  }
2989
- return p.range = l, p.source = i, r && (p.type = r), a && (p.tag = a), c.format && (p.format = c.format), o && (p.comment = o), p;
2999
+ return m.range = l, m.source = i, r && (m.type = r), a && (m.tag = a), c.format && (m.format = c.format), o && (m.comment = o), m;
2990
3000
  }
2991
3001
  function bn(s, e, t, n, i) {
2992
3002
  var l;
2993
3003
  if (t === "!")
2994
- return s[V];
3004
+ return s[R];
2995
3005
  const r = [];
2996
3006
  for (const a of s.tags)
2997
3007
  if (!a.collection && a.tag === t)
@@ -3003,18 +3013,18 @@ function bn(s, e, t, n, i) {
3003
3013
  if ((l = a.test) != null && l.test(e))
3004
3014
  return a;
3005
3015
  const o = s.knownTags[t];
3006
- return o && !o.collection ? (s.tags.push(Object.assign({}, o, { default: !1, test: void 0 })), o) : (i(n, "TAG_RESOLVE_FAILED", `Unresolved tag: ${t}`, t !== "tag:yaml.org,2002:str"), s[V]);
3016
+ return o && !o.collection ? (s.tags.push(Object.assign({}, o, { default: !1, test: void 0 })), o) : (i(n, "TAG_RESOLVE_FAILED", `Unresolved tag: ${t}`, t !== "tag:yaml.org,2002:str"), s[R]);
3007
3017
  }
3008
3018
  function wn({ directives: s, schema: e }, t, n, i) {
3009
3019
  const r = e.tags.find((o) => {
3010
3020
  var l;
3011
3021
  return o.default && ((l = o.test) == null ? void 0 : l.test(t));
3012
- }) || e[V];
3022
+ }) || e[R];
3013
3023
  if (e.compat) {
3014
3024
  const o = e.compat.find((l) => {
3015
3025
  var a;
3016
3026
  return l.default && ((a = l.test) == null ? void 0 : a.test(t));
3017
- }) ?? e[V];
3027
+ }) ?? e[R];
3018
3028
  if (r.tag !== o.tag) {
3019
3029
  const l = s.tagString(r.tag), a = s.tagString(o.tag), c = `Value may be parsed as either ${l} or ${a}`;
3020
3030
  i(n, "TAG_RESOLVE_FAILED", c, !0);
@@ -3041,7 +3051,7 @@ function Sn(s, e, t) {
3041
3051
  }
3042
3052
  return s;
3043
3053
  }
3044
- const kn = { composeNode: ws, composeEmptyNode: At };
3054
+ const kn = { composeNode: ws, composeEmptyNode: Ot };
3045
3055
  function ws(s, e, t, n) {
3046
3056
  const { spaceBefore: i, comment: r, anchor: o, tag: l } = t;
3047
3057
  let a, c = !0;
@@ -3058,26 +3068,26 @@ function ws(s, e, t, n) {
3058
3068
  case "block-map":
3059
3069
  case "block-seq":
3060
3070
  case "flow-collection":
3061
- a = cn(kn, s, e, l, n), o && (a.anchor = o.source.substring(1));
3071
+ a = cn(kn, s, e, t, n), o && (a.anchor = o.source.substring(1));
3062
3072
  break;
3063
3073
  default: {
3064
- const p = e.type === "error" ? e.message : `Unsupported token (type: ${e.type})`;
3065
- n(e, "UNEXPECTED_TOKEN", p), a = At(s, e.offset, void 0, null, t, n), c = !1;
3074
+ const m = e.type === "error" ? e.message : `Unsupported token (type: ${e.type})`;
3075
+ n(e, "UNEXPECTED_TOKEN", m), a = Ot(s, e.offset, void 0, null, t, n), c = !1;
3066
3076
  }
3067
3077
  }
3068
3078
  return o && a.anchor === "" && n(o, "BAD_ALIAS", "Anchor cannot be an empty string"), i && (a.spaceBefore = !0), r && (e.type === "scalar" && e.source === "" ? a.comment = r : a.commentBefore = r), s.options.keepSourceTokens && c && (a.srcToken = e), a;
3069
3079
  }
3070
- function At(s, e, t, n, { spaceBefore: i, comment: r, anchor: o, tag: l, end: a }, c) {
3071
- const p = {
3080
+ function Ot(s, e, t, n, { spaceBefore: i, comment: r, anchor: o, tag: l, end: a }, c) {
3081
+ const m = {
3072
3082
  type: "scalar",
3073
3083
  offset: Sn(e, t, n),
3074
3084
  indent: -1,
3075
3085
  source: ""
3076
- }, f = bs(s, p, l, c);
3086
+ }, f = bs(s, m, l, c);
3077
3087
  return o && (f.anchor = o.source.substring(1), f.anchor === "" && c(o, "BAD_ALIAS", "Anchor cannot be an empty string")), i && (f.spaceBefore = !0), r && (f.comment = r, f.range[2] = a), f;
3078
3088
  }
3079
3089
  function Nn({ options: s }, { offset: e, source: t, end: n }, i) {
3080
- const r = new Ke(t.substring(1));
3090
+ const r = new qe(t.substring(1));
3081
3091
  r.source === "" && i(e, "BAD_ALIAS", "Alias cannot be an empty string"), r.source.endsWith(":") && i(e + t.length - 1, "BAD_ALIAS", "Alias ending in : is ambiguous", !0);
3082
3092
  const o = e + t.length, l = Ee(n, o, s.strict, i);
3083
3093
  return r.range = [e, o, l.offset], l.comment && (r.comment = l.comment), r;
@@ -3088,16 +3098,17 @@ function On(s, e, { offset: t, start: n, value: i, end: r }, o) {
3088
3098
  directives: a.directives,
3089
3099
  options: a.options,
3090
3100
  schema: a.schema
3091
- }, p = ce(n, {
3101
+ }, m = ce(n, {
3092
3102
  indicator: "doc-start",
3093
3103
  next: i ?? (r == null ? void 0 : r[0]),
3094
3104
  offset: t,
3095
3105
  onError: o,
3106
+ parentIndent: 0,
3096
3107
  startOnNewline: !0
3097
3108
  });
3098
- p.found && (a.directives.docStart = !0, i && (i.type === "block-map" || i.type === "block-seq") && !p.hasNewline && o(p.end, "MISSING_CHAR", "Block collection cannot start on same line with directives-end marker")), a.contents = i ? ws(c, i, p, o) : At(c, p.end, n, null, p, o);
3099
- const f = a.contents.range[2], u = Ee(r, f, !1, o);
3100
- return u.comment && (a.comment = u.comment), a.range = [t, f, u.offset], a;
3109
+ m.found && (a.directives.docStart = !0, i && (i.type === "block-map" || i.type === "block-seq") && !m.hasNewline && o(m.end, "MISSING_CHAR", "Block collection cannot start on same line with directives-end marker")), a.contents = i ? ws(c, i, m, o) : Ot(c, m.end, n, null, m, o);
3110
+ const f = a.contents.range[2], d = Ee(r, f, !1, o);
3111
+ return d.comment && (a.comment = d.comment), a.range = [t, f, d.offset], a;
3101
3112
  }
3102
3113
  function ge(s) {
3103
3114
  if (typeof s == "number")
@@ -3107,7 +3118,7 @@ function ge(s) {
3107
3118
  const { offset: e, source: t } = s;
3108
3119
  return [e, e + (typeof t == "string" ? t.length : 1)];
3109
3120
  }
3110
- function Mt(s) {
3121
+ function Bt(s) {
3111
3122
  var i;
3112
3123
  let e = "", t = !1, n = !1;
3113
3124
  for (let r = 0; r < s.length; ++r) {
@@ -3128,7 +3139,7 @@ function Mt(s) {
3128
3139
  }
3129
3140
  return { comment: e, afterEmptyLine: n };
3130
3141
  }
3131
- class Et {
3142
+ class At {
3132
3143
  constructor(e = {}) {
3133
3144
  this.doc = null, this.atDirectives = !1, this.prelude = [], this.errors = [], this.warnings = [], this.onError = (t, n, i, r) => {
3134
3145
  const o = ge(t);
@@ -3136,7 +3147,7 @@ class Et {
3136
3147
  }, this.directives = new B({ version: e.version || "1.2" }), this.options = e;
3137
3148
  }
3138
3149
  decorate(e, t) {
3139
- const { comment: n, afterEmptyLine: i } = Mt(this.prelude);
3150
+ const { comment: n, afterEmptyLine: i } = Bt(this.prelude);
3140
3151
  if (n) {
3141
3152
  const r = e.contents;
3142
3153
  if (t)
@@ -3144,9 +3155,9 @@ class Et {
3144
3155
  ${n}` : n;
3145
3156
  else if (i || e.directives.docStart || !r)
3146
3157
  e.commentBefore = n;
3147
- else if (T(r) && !r.flow && r.items.length > 0) {
3158
+ else if (L(r) && !r.flow && r.items.length > 0) {
3148
3159
  let o = r.items[0];
3149
- E(o) && (o = o.key);
3160
+ I(o) && (o = o.key);
3150
3161
  const l = o.commentBefore;
3151
3162
  o.commentBefore = l ? `${n}
3152
3163
  ${l}` : n;
@@ -3165,7 +3176,7 @@ ${o}` : n;
3165
3176
  */
3166
3177
  streamInfo() {
3167
3178
  return {
3168
- comment: Mt(this.prelude).comment,
3179
+ comment: Bt(this.prelude).comment,
3169
3180
  directives: this.directives,
3170
3181
  errors: this.errors,
3171
3182
  warnings: this.warnings
@@ -3258,7 +3269,7 @@ function An(s, e = !0, t) {
3258
3269
  case "double-quoted-scalar":
3259
3270
  return ys(s, e, n);
3260
3271
  case "block-scalar":
3261
- return ms(s, e, n);
3272
+ return ms({ options: { strict: e } }, s, n);
3262
3273
  }
3263
3274
  }
3264
3275
  return null;
@@ -3277,12 +3288,12 @@ function En(s, e) {
3277
3288
  case "|":
3278
3289
  case ">": {
3279
3290
  const c = l.indexOf(`
3280
- `), p = l.substring(0, c), f = l.substring(c + 1) + `
3281
- `, u = [
3282
- { type: "block-scalar-header", offset: r, indent: n, source: p }
3291
+ `), m = l.substring(0, c), f = l.substring(c + 1) + `
3292
+ `, d = [
3293
+ { type: "block-scalar-header", offset: r, indent: n, source: m }
3283
3294
  ];
3284
- return Ss(u, a) || u.push({ type: "newline", offset: -1, indent: n, source: `
3285
- ` }), { type: "block-scalar", offset: r, indent: n, props: u, source: f };
3295
+ return Ss(d, a) || d.push({ type: "newline", offset: -1, indent: n, source: `
3296
+ ` }), { type: "block-scalar", offset: r, indent: n, props: d, source: f };
3286
3297
  }
3287
3298
  case '"':
3288
3299
  return { type: "double-quoted-scalar", offset: r, indent: n, source: l, end: a };
@@ -3324,13 +3335,13 @@ function In(s, e, t = {}) {
3324
3335
  Tn(s, a);
3325
3336
  break;
3326
3337
  case '"':
3327
- st(s, a, "double-quoted-scalar");
3338
+ nt(s, a, "double-quoted-scalar");
3328
3339
  break;
3329
3340
  case "'":
3330
- st(s, a, "single-quoted-scalar");
3341
+ nt(s, a, "single-quoted-scalar");
3331
3342
  break;
3332
3343
  default:
3333
- st(s, a, "scalar");
3344
+ nt(s, a, "scalar");
3334
3345
  }
3335
3346
  }
3336
3347
  function Tn(s, e) {
@@ -3366,7 +3377,7 @@ function Ss(s, e) {
3366
3377
  }
3367
3378
  return !1;
3368
3379
  }
3369
- function st(s, e, t) {
3380
+ function nt(s, e, t) {
3370
3381
  switch (s.type) {
3371
3382
  case "scalar":
3372
3383
  case "double-quoted-scalar":
@@ -3397,7 +3408,7 @@ function st(s, e, t) {
3397
3408
  }
3398
3409
  }
3399
3410
  }
3400
- const Ln = (s) => "type" in s ? je(s) : ve(s);
3411
+ const Ln = (s) => "type" in s ? je(s) : Be(s);
3401
3412
  function je(s) {
3402
3413
  switch (s.type) {
3403
3414
  case "block-scalar": {
@@ -3410,19 +3421,19 @@ function je(s) {
3410
3421
  case "block-seq": {
3411
3422
  let e = "";
3412
3423
  for (const t of s.items)
3413
- e += ve(t);
3424
+ e += Be(t);
3414
3425
  return e;
3415
3426
  }
3416
3427
  case "flow-collection": {
3417
3428
  let e = s.start.source;
3418
3429
  for (const t of s.items)
3419
- e += ve(t);
3430
+ e += Be(t);
3420
3431
  for (const t of s.end)
3421
3432
  e += t.source;
3422
3433
  return e;
3423
3434
  }
3424
3435
  case "document": {
3425
- let e = ve(s);
3436
+ let e = Be(s);
3426
3437
  if (s.end)
3427
3438
  for (const t of s.end)
3428
3439
  e += t.source;
@@ -3437,7 +3448,7 @@ function je(s) {
3437
3448
  }
3438
3449
  }
3439
3450
  }
3440
- function ve({ start: s, key: e, sep: t, value: n }) {
3451
+ function Be({ start: s, key: e, sep: t, value: n }) {
3441
3452
  let i = "";
3442
3453
  for (const r of s)
3443
3454
  i += r.source;
@@ -3492,14 +3503,14 @@ function Ns(s, e, t) {
3492
3503
  }
3493
3504
  return typeof n == "function" ? n(e, s) : n;
3494
3505
  }
3495
- const We = "\uFEFF", He = "", Xe = "", Ne = "", _n = (s) => !!s && "items" in s, Cn = (s) => !!s && (s.type === "scalar" || s.type === "single-quoted-scalar" || s.type === "double-quoted-scalar" || s.type === "block-scalar");
3506
+ const He = "\uFEFF", Xe = "", ze = "", Ne = "", _n = (s) => !!s && "items" in s, Cn = (s) => !!s && (s.type === "scalar" || s.type === "single-quoted-scalar" || s.type === "double-quoted-scalar" || s.type === "block-scalar");
3496
3507
  function vn(s) {
3497
3508
  switch (s) {
3498
- case We:
3499
- return "<BOM>";
3500
3509
  case He:
3501
- return "<DOC>";
3510
+ return "<BOM>";
3502
3511
  case Xe:
3512
+ return "<DOC>";
3513
+ case ze:
3503
3514
  return "<FLOW_END>";
3504
3515
  case Ne:
3505
3516
  return "<SCALAR>";
@@ -3509,11 +3520,11 @@ function vn(s) {
3509
3520
  }
3510
3521
  function Os(s) {
3511
3522
  switch (s) {
3512
- case We:
3513
- return "byte-order-mark";
3514
3523
  case He:
3515
- return "doc-mode";
3524
+ return "byte-order-mark";
3516
3525
  case Xe:
3526
+ return "doc-mode";
3527
+ case ze:
3517
3528
  return "flow-error-end";
3518
3529
  case Ne:
3519
3530
  return "scalar";
@@ -3568,11 +3579,11 @@ function Os(s) {
3568
3579
  }
3569
3580
  return null;
3570
3581
  }
3571
- const Bn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3582
+ var Bn = /* @__PURE__ */ Object.freeze({
3572
3583
  __proto__: null,
3573
- BOM: We,
3574
- DOCUMENT: He,
3575
- FLOW_END: Xe,
3584
+ BOM: He,
3585
+ DOCUMENT: Xe,
3586
+ FLOW_END: ze,
3576
3587
  SCALAR: Ne,
3577
3588
  createScalarToken: En,
3578
3589
  isCollection: _n,
@@ -3583,8 +3594,8 @@ const Bn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3583
3594
  stringify: Ln,
3584
3595
  tokenType: Os,
3585
3596
  visit: z
3586
- }, Symbol.toStringTag, { value: "Module" }));
3587
- function j(s) {
3597
+ });
3598
+ function K(s) {
3588
3599
  switch (s) {
3589
3600
  case void 0:
3590
3601
  case " ":
@@ -3597,8 +3608,8 @@ function j(s) {
3597
3608
  return !1;
3598
3609
  }
3599
3610
  }
3600
- const Pt = "0123456789ABCDEFabcdef".split(""), Mn = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()".split(""), nt = ",[]{}".split(""), Pn = ` ,[]{}
3601
- \r `.split(""), it = (s) => !s || Pn.includes(s);
3611
+ const Mt = new Set("0123456789ABCDEFabcdef"), Mn = new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"), Le = new Set(",[]{}"), Pn = new Set(` ,[]{}
3612
+ \r `), it = (s) => !s || Pn.has(s);
3602
3613
  class As {
3603
3614
  constructor() {
3604
3615
  this.atEnd = !1, this.blockScalarIndent = -1, this.blockScalarKeep = !1, this.buffer = "", this.flowKey = !1, this.flowLevel = 0, this.indentNext = 0, this.indentValue = 0, this.lineEndPos = null, this.next = null, this.pos = 0;
@@ -3610,7 +3621,12 @@ class As {
3610
3621
  * @returns A generator of lexical tokens
3611
3622
  */
3612
3623
  *lex(e, t = !1) {
3613
- e && (this.buffer = this.buffer ? this.buffer + e : e, this.lineEndPos = null), this.atEnd = !t;
3624
+ if (e) {
3625
+ if (typeof e != "string")
3626
+ throw TypeError("source is not a string");
3627
+ this.buffer = this.buffer ? this.buffer + e : e, this.lineEndPos = null;
3628
+ }
3629
+ this.atEnd = !t;
3614
3630
  let n = this.next ?? "stream";
3615
3631
  for (; n && (t || this.hasChars(1)); )
3616
3632
  n = yield* this.parseNext(n);
@@ -3643,7 +3659,7 @@ class As {
3643
3659
  }
3644
3660
  if (t === "-" || t === ".") {
3645
3661
  const n = this.buffer.substr(e, 3);
3646
- if ((n === "---" || n === "...") && j(this.buffer[e + 3]))
3662
+ if ((n === "---" || n === "...") && K(this.buffer[e + 3]))
3647
3663
  return -1;
3648
3664
  }
3649
3665
  return e;
@@ -3686,12 +3702,15 @@ class As {
3686
3702
  let e = this.getLine();
3687
3703
  if (e === null)
3688
3704
  return this.setNext("stream");
3689
- if (e[0] === We && (yield* this.pushCount(1), e = e.substring(1)), e[0] === "%") {
3690
- let t = e.length;
3691
- const n = e.indexOf("#");
3692
- if (n !== -1) {
3705
+ if (e[0] === He && (yield* this.pushCount(1), e = e.substring(1)), e[0] === "%") {
3706
+ let t = e.length, n = e.indexOf("#");
3707
+ for (; n !== -1; ) {
3693
3708
  const r = e[n - 1];
3694
- (r === " " || r === " ") && (t = n - 1);
3709
+ if (r === " " || r === " ") {
3710
+ t = n - 1;
3711
+ break;
3712
+ } else
3713
+ n = e.indexOf("#", n + 1);
3695
3714
  }
3696
3715
  for (; ; ) {
3697
3716
  const r = e[t - 1];
@@ -3707,7 +3726,7 @@ class As {
3707
3726
  const t = yield* this.pushSpaces(!0);
3708
3727
  return yield* this.pushCount(e.length - t), yield* this.pushNewline(), "stream";
3709
3728
  }
3710
- return yield He, yield* this.parseLineStart();
3729
+ return yield Xe, yield* this.parseLineStart();
3711
3730
  }
3712
3731
  *parseLineStart() {
3713
3732
  const e = this.charAt(0);
@@ -3717,18 +3736,16 @@ class As {
3717
3736
  if (!this.atEnd && !this.hasChars(4))
3718
3737
  return this.setNext("line-start");
3719
3738
  const t = this.peek(3);
3720
- if (t === "---" && j(this.charAt(3)))
3721
- return yield* this.pushCount(3), this.indentValue = 0, this.indentNext = 0, "doc";
3722
- if (t === "..." && j(this.charAt(3)))
3723
- return yield* this.pushCount(3), "stream";
3739
+ if ((t === "---" || t === "...") && K(this.charAt(3)))
3740
+ return yield* this.pushCount(3), this.indentValue = 0, this.indentNext = 0, t === "---" ? "doc" : "stream";
3724
3741
  }
3725
- return this.indentValue = yield* this.pushSpaces(!1), this.indentNext > this.indentValue && !j(this.charAt(1)) && (this.indentNext = this.indentValue), yield* this.parseBlockStart();
3742
+ return this.indentValue = yield* this.pushSpaces(!1), this.indentNext > this.indentValue && !K(this.charAt(1)) && (this.indentNext = this.indentValue), yield* this.parseBlockStart();
3726
3743
  }
3727
3744
  *parseBlockStart() {
3728
3745
  const [e, t] = this.peek(2);
3729
3746
  if (!t && !this.atEnd)
3730
3747
  return this.setNext("block-start");
3731
- if ((e === "-" || e === "?" || e === ":") && j(t)) {
3748
+ if ((e === "-" || e === "?" || e === ":") && K(t)) {
3732
3749
  const n = (yield* this.pushCount(1)) + (yield* this.pushSpaces(!0));
3733
3750
  return this.indentNext = this.indentValue + 1, this.indentValue += n, yield* this.parseBlockStart();
3734
3751
  }
@@ -3771,8 +3788,8 @@ class As {
3771
3788
  const i = this.getLine();
3772
3789
  if (i === null)
3773
3790
  return this.setNext("flow");
3774
- if ((n !== -1 && n < this.indentNext && i[0] !== "#" || n === 0 && (i.startsWith("---") || i.startsWith("...")) && j(i[3])) && !(n === this.indentNext - 1 && this.flowLevel === 1 && (i[0] === "]" || i[0] === "}")))
3775
- return this.flowLevel = 0, yield Xe, yield* this.parseLineStart();
3791
+ if ((n !== -1 && n < this.indentNext && i[0] !== "#" || n === 0 && (i.startsWith("---") || i.startsWith("...")) && K(i[3])) && !(n === this.indentNext - 1 && this.flowLevel === 1 && (i[0] === "]" || i[0] === "}")))
3792
+ return this.flowLevel = 0, yield ze, yield* this.parseLineStart();
3776
3793
  let r = 0;
3777
3794
  for (; i[r] === ","; )
3778
3795
  r += yield* this.pushCount(1), r += yield* this.pushSpaces(!0), this.flowKey = !1;
@@ -3794,7 +3811,7 @@ class As {
3794
3811
  return this.flowKey = !0, yield* this.parseQuotedScalar();
3795
3812
  case ":": {
3796
3813
  const o = this.charAt(1);
3797
- if (this.flowKey || j(o) || o === ",")
3814
+ if (this.flowKey || K(o) || o === ",")
3798
3815
  return this.flowKey = !1, yield* this.pushCount(1), yield* this.pushSpaces(!0), "flow";
3799
3816
  }
3800
3817
  default:
@@ -3848,24 +3865,24 @@ class As {
3848
3865
  else if (t !== "-")
3849
3866
  break;
3850
3867
  }
3851
- return yield* this.pushUntil((t) => j(t) || t === "#");
3868
+ return yield* this.pushUntil((t) => K(t) || t === "#");
3852
3869
  }
3853
3870
  *parseBlockScalar() {
3854
3871
  let e = this.pos - 1, t = 0, n;
3855
- e: for (let i = this.pos; n = this.buffer[i]; ++i)
3872
+ e: for (let r = this.pos; n = this.buffer[r]; ++r)
3856
3873
  switch (n) {
3857
3874
  case " ":
3858
3875
  t += 1;
3859
3876
  break;
3860
3877
  case `
3861
3878
  `:
3862
- e = i, t = 0;
3879
+ e = r, t = 0;
3863
3880
  break;
3864
3881
  case "\r": {
3865
- const r = this.buffer[i + 1];
3866
- if (!r && !this.atEnd)
3882
+ const o = this.buffer[r + 1];
3883
+ if (!o && !this.atEnd)
3867
3884
  return this.setNext("block-scalar");
3868
- if (r === `
3885
+ if (o === `
3869
3886
  `)
3870
3887
  break;
3871
3888
  }
@@ -3875,13 +3892,13 @@ class As {
3875
3892
  if (!n && !this.atEnd)
3876
3893
  return this.setNext("block-scalar");
3877
3894
  if (t >= this.indentNext) {
3878
- this.blockScalarIndent === -1 ? this.indentNext = t : this.indentNext += this.blockScalarIndent;
3895
+ this.blockScalarIndent === -1 ? this.indentNext = t : this.indentNext = this.blockScalarIndent + (this.indentNext === 0 ? 1 : this.indentNext);
3879
3896
  do {
3880
- const i = this.continueScalar(e + 1);
3881
- if (i === -1)
3897
+ const r = this.continueScalar(e + 1);
3898
+ if (r === -1)
3882
3899
  break;
3883
3900
  e = this.buffer.indexOf(`
3884
- `, i);
3901
+ `, r);
3885
3902
  } while (e !== -1);
3886
3903
  if (e === -1) {
3887
3904
  if (!this.atEnd)
@@ -3889,16 +3906,24 @@ class As {
3889
3906
  e = this.buffer.length;
3890
3907
  }
3891
3908
  }
3892
- if (!this.blockScalarKeep)
3909
+ let i = e + 1;
3910
+ for (n = this.buffer[i]; n === " "; )
3911
+ n = this.buffer[++i];
3912
+ if (n === " ") {
3913
+ for (; n === " " || n === " " || n === "\r" || n === `
3914
+ `; )
3915
+ n = this.buffer[++i];
3916
+ e = i - 1;
3917
+ } else if (!this.blockScalarKeep)
3893
3918
  do {
3894
- let i = e - 1, r = this.buffer[i];
3895
- r === "\r" && (r = this.buffer[--i]);
3896
- const o = i;
3897
- for (; r === " " || r === " "; )
3898
- r = this.buffer[--i];
3899
- if (r === `
3900
- ` && i >= this.pos && i + 1 + t > o)
3901
- e = i;
3919
+ let r = e - 1, o = this.buffer[r];
3920
+ o === "\r" && (o = this.buffer[--r]);
3921
+ const l = r;
3922
+ for (; o === " "; )
3923
+ o = this.buffer[--r];
3924
+ if (o === `
3925
+ ` && r >= this.pos && r + 1 + t > l)
3926
+ e = r;
3902
3927
  else
3903
3928
  break;
3904
3929
  } while (!0);
@@ -3910,14 +3935,14 @@ class As {
3910
3935
  for (; i = this.buffer[++n]; )
3911
3936
  if (i === ":") {
3912
3937
  const r = this.buffer[n + 1];
3913
- if (j(r) || e && r === ",")
3938
+ if (K(r) || e && Le.has(r))
3914
3939
  break;
3915
3940
  t = n;
3916
- } else if (j(i)) {
3941
+ } else if (K(i)) {
3917
3942
  let r = this.buffer[n + 1];
3918
3943
  if (i === "\r" && (r === `
3919
3944
  ` ? (n += 1, i = `
3920
- `, r = this.buffer[n + 1]) : t = n), r === "#" || e && nt.includes(r))
3945
+ `, r = this.buffer[n + 1]) : t = n), r === "#" || e && Le.has(r))
3921
3946
  break;
3922
3947
  if (i === `
3923
3948
  `) {
@@ -3927,7 +3952,7 @@ class As {
3927
3952
  n = Math.max(n, o - 2);
3928
3953
  }
3929
3954
  } else {
3930
- if (e && nt.includes(i))
3955
+ if (e && Le.has(i))
3931
3956
  break;
3932
3957
  t = n;
3933
3958
  }
@@ -3950,7 +3975,7 @@ class As {
3950
3975
  case "?":
3951
3976
  case ":": {
3952
3977
  const e = this.flowLevel > 0, t = this.charAt(1);
3953
- if (j(t) || e && nt.includes(t))
3978
+ if (K(t) || e && Le.has(t))
3954
3979
  return e ? this.flowKey && (this.flowKey = !1) : this.indentNext = this.indentValue + 1, (yield* this.pushCount(1)) + (yield* this.pushSpaces(!0)) + (yield* this.pushIndicators());
3955
3980
  }
3956
3981
  }
@@ -3959,15 +3984,15 @@ class As {
3959
3984
  *pushTag() {
3960
3985
  if (this.charAt(1) === "<") {
3961
3986
  let e = this.pos + 2, t = this.buffer[e];
3962
- for (; !j(t) && t !== ">"; )
3987
+ for (; !K(t) && t !== ">"; )
3963
3988
  t = this.buffer[++e];
3964
3989
  return yield* this.pushToIndex(t === ">" ? e + 1 : e, !1);
3965
3990
  } else {
3966
3991
  let e = this.pos + 1, t = this.buffer[e];
3967
3992
  for (; t; )
3968
- if (Mn.includes(t))
3993
+ if (Mn.has(t))
3969
3994
  t = this.buffer[++e];
3970
- else if (t === "%" && Pt.includes(this.buffer[e + 1]) && Pt.includes(this.buffer[e + 2]))
3995
+ else if (t === "%" && Mt.has(this.buffer[e + 1]) && Mt.has(this.buffer[e + 2]))
3971
3996
  t = this.buffer[e += 3];
3972
3997
  else
3973
3998
  break;
@@ -4012,13 +4037,13 @@ class Es {
4012
4037
  };
4013
4038
  }
4014
4039
  }
4015
- function q(s, e) {
4040
+ function Q(s, e) {
4016
4041
  for (let t = 0; t < s.length; ++t)
4017
4042
  if (s[t].type === e)
4018
4043
  return !0;
4019
4044
  return !1;
4020
4045
  }
4021
- function jt(s) {
4046
+ function Pt(s) {
4022
4047
  for (let e = 0; e < s.length; ++e)
4023
4048
  switch (s[e].type) {
4024
4049
  case "space":
@@ -4042,7 +4067,7 @@ function Is(s) {
4042
4067
  return !1;
4043
4068
  }
4044
4069
  }
4045
- function Le(s) {
4070
+ function $e(s) {
4046
4071
  switch (s.type) {
4047
4072
  case "document":
4048
4073
  return s.start;
@@ -4077,9 +4102,9 @@ function te(s) {
4077
4102
  function Dt(s) {
4078
4103
  if (s.start.type === "flow-seq-start")
4079
4104
  for (const e of s.items)
4080
- e.sep && !e.value && !q(e.start, "explicit-key-ind") && !q(e.sep, "map-value-ind") && (e.key && (e.value = e.key), delete e.key, Is(e.value) ? e.value.end ? Array.prototype.push.apply(e.value.end, e.sep) : e.value.end = e.sep : Array.prototype.push.apply(e.start, e.sep), delete e.sep);
4105
+ e.sep && !e.value && !Q(e.start, "explicit-key-ind") && !Q(e.sep, "map-value-ind") && (e.key && (e.value = e.key), delete e.key, Is(e.value) ? e.value.end ? Array.prototype.push.apply(e.value.end, e.sep) : e.value.end = e.sep : Array.prototype.push.apply(e.start, e.sep), delete e.sep);
4081
4106
  }
4082
- class It {
4107
+ class Et {
4083
4108
  /**
4084
4109
  * @param onNewLine - If defined, called separately with the start position of
4085
4110
  * each new line (in `parse()`, including the start of input).
@@ -4213,7 +4238,7 @@ class It {
4213
4238
  } else if (i.sep)
4214
4239
  i.value = t;
4215
4240
  else {
4216
- Object.assign(i, { key: t, sep: [] }), this.onKeyLine = !q(i.start, "explicit-key-ind");
4241
+ Object.assign(i, { key: t, sep: [] }), this.onKeyLine = !i.explicitKey;
4217
4242
  return;
4218
4243
  }
4219
4244
  break;
@@ -4233,7 +4258,7 @@ class It {
4233
4258
  }
4234
4259
  if ((n.type === "document" || n.type === "block-map" || n.type === "block-seq") && (t.type === "block-map" || t.type === "block-seq")) {
4235
4260
  const i = t.items[t.items.length - 1];
4236
- i && !i.sep && !i.value && i.start.length > 0 && jt(i.start) === -1 && (t.indent === 0 || i.start.every((r) => r.type !== "comment" || r.indent < t.indent)) && (n.type === "document" ? n.end = i.start : n.items.push({ start: i.start }), t.items.splice(-1, 1));
4261
+ i && !i.sep && !i.value && i.start.length > 0 && Pt(i.start) === -1 && (t.indent === 0 || i.start.every((r) => r.type !== "comment" || r.indent < t.indent)) && (n.type === "document" ? n.end = i.start : n.items.push({ start: i.start }), t.items.splice(-1, 1));
4237
4262
  }
4238
4263
  }
4239
4264
  }
@@ -4271,7 +4296,7 @@ class It {
4271
4296
  return yield* this.lineEnd(e);
4272
4297
  switch (this.type) {
4273
4298
  case "doc-start": {
4274
- jt(e.start) !== -1 ? (yield* this.pop(), yield* this.step()) : e.start.push(this.sourceToken);
4299
+ Pt(e.start) !== -1 ? (yield* this.pop(), yield* this.step()) : e.start.push(this.sourceToken);
4275
4300
  return;
4276
4301
  }
4277
4302
  case "anchor":
@@ -4292,7 +4317,7 @@ class It {
4292
4317
  }
4293
4318
  *scalar(e) {
4294
4319
  if (this.type === "map-value-ind") {
4295
- const t = Le(this.peek(2)), n = te(t);
4320
+ const t = $e(this.peek(2)), n = te(t);
4296
4321
  let i;
4297
4322
  e.end ? (i = e.end, i.push(this.sourceToken), delete e.end) : i = [this.sourceToken];
4298
4323
  const r = {
@@ -4355,74 +4380,74 @@ class It {
4355
4380
  return;
4356
4381
  }
4357
4382
  if (this.indent >= e.indent) {
4358
- const i = !this.onKeyLine && this.indent === e.indent && t.sep && this.type !== "seq-item-ind";
4359
- let r = [];
4360
- if (i && t.sep && !t.value) {
4361
- const o = [];
4362
- for (let l = 0; l < t.sep.length; ++l) {
4363
- const a = t.sep[l];
4364
- switch (a.type) {
4383
+ const i = !this.onKeyLine && this.indent === e.indent, r = i && (t.sep || t.explicitKey) && this.type !== "seq-item-ind";
4384
+ let o = [];
4385
+ if (r && t.sep && !t.value) {
4386
+ const l = [];
4387
+ for (let a = 0; a < t.sep.length; ++a) {
4388
+ const c = t.sep[a];
4389
+ switch (c.type) {
4365
4390
  case "newline":
4366
- o.push(l);
4391
+ l.push(a);
4367
4392
  break;
4368
4393
  case "space":
4369
4394
  break;
4370
4395
  case "comment":
4371
- a.indent > e.indent && (o.length = 0);
4396
+ c.indent > e.indent && (l.length = 0);
4372
4397
  break;
4373
4398
  default:
4374
- o.length = 0;
4399
+ l.length = 0;
4375
4400
  }
4376
4401
  }
4377
- o.length >= 2 && (r = t.sep.splice(o[1]));
4402
+ l.length >= 2 && (o = t.sep.splice(l[1]));
4378
4403
  }
4379
4404
  switch (this.type) {
4380
4405
  case "anchor":
4381
4406
  case "tag":
4382
- i || t.value ? (r.push(this.sourceToken), e.items.push({ start: r }), this.onKeyLine = !0) : t.sep ? t.sep.push(this.sourceToken) : t.start.push(this.sourceToken);
4407
+ r || t.value ? (o.push(this.sourceToken), e.items.push({ start: o }), this.onKeyLine = !0) : t.sep ? t.sep.push(this.sourceToken) : t.start.push(this.sourceToken);
4383
4408
  return;
4384
4409
  case "explicit-key-ind":
4385
- !t.sep && !q(t.start, "explicit-key-ind") ? t.start.push(this.sourceToken) : i || t.value ? (r.push(this.sourceToken), e.items.push({ start: r })) : this.stack.push({
4410
+ !t.sep && !t.explicitKey ? (t.start.push(this.sourceToken), t.explicitKey = !0) : r || t.value ? (o.push(this.sourceToken), e.items.push({ start: o, explicitKey: !0 })) : this.stack.push({
4386
4411
  type: "block-map",
4387
4412
  offset: this.offset,
4388
4413
  indent: this.indent,
4389
- items: [{ start: [this.sourceToken] }]
4414
+ items: [{ start: [this.sourceToken], explicitKey: !0 }]
4390
4415
  }), this.onKeyLine = !0;
4391
4416
  return;
4392
4417
  case "map-value-ind":
4393
- if (q(t.start, "explicit-key-ind"))
4418
+ if (t.explicitKey)
4394
4419
  if (t.sep)
4395
4420
  if (t.value)
4396
4421
  e.items.push({ start: [], key: null, sep: [this.sourceToken] });
4397
- else if (q(t.sep, "map-value-ind"))
4422
+ else if (Q(t.sep, "map-value-ind"))
4398
4423
  this.stack.push({
4399
4424
  type: "block-map",
4400
4425
  offset: this.offset,
4401
4426
  indent: this.indent,
4402
- items: [{ start: r, key: null, sep: [this.sourceToken] }]
4427
+ items: [{ start: o, key: null, sep: [this.sourceToken] }]
4403
4428
  });
4404
- else if (Is(t.key) && !q(t.sep, "newline")) {
4405
- const o = te(t.start), l = t.key, a = t.sep;
4406
- a.push(this.sourceToken), delete t.key, delete t.sep, this.stack.push({
4429
+ else if (Is(t.key) && !Q(t.sep, "newline")) {
4430
+ const l = te(t.start), a = t.key, c = t.sep;
4431
+ c.push(this.sourceToken), delete t.key, delete t.sep, this.stack.push({
4407
4432
  type: "block-map",
4408
4433
  offset: this.offset,
4409
4434
  indent: this.indent,
4410
- items: [{ start: o, key: l, sep: a }]
4435
+ items: [{ start: l, key: a, sep: c }]
4411
4436
  });
4412
- } else r.length > 0 ? t.sep = t.sep.concat(r, this.sourceToken) : t.sep.push(this.sourceToken);
4413
- else if (q(t.start, "newline"))
4437
+ } else o.length > 0 ? t.sep = t.sep.concat(o, this.sourceToken) : t.sep.push(this.sourceToken);
4438
+ else if (Q(t.start, "newline"))
4414
4439
  Object.assign(t, { key: null, sep: [this.sourceToken] });
4415
4440
  else {
4416
- const o = te(t.start);
4441
+ const l = te(t.start);
4417
4442
  this.stack.push({
4418
4443
  type: "block-map",
4419
4444
  offset: this.offset,
4420
4445
  indent: this.indent,
4421
- items: [{ start: o, key: null, sep: [this.sourceToken] }]
4446
+ items: [{ start: l, key: null, sep: [this.sourceToken] }]
4422
4447
  });
4423
4448
  }
4424
4449
  else
4425
- t.sep ? t.value || i ? e.items.push({ start: r, key: null, sep: [this.sourceToken] }) : q(t.sep, "map-value-ind") ? this.stack.push({
4450
+ t.sep ? t.value || r ? e.items.push({ start: o, key: null, sep: [this.sourceToken] }) : Q(t.sep, "map-value-ind") ? this.stack.push({
4426
4451
  type: "block-map",
4427
4452
  offset: this.offset,
4428
4453
  indent: this.indent,
@@ -4434,14 +4459,14 @@ class It {
4434
4459
  case "scalar":
4435
4460
  case "single-quoted-scalar":
4436
4461
  case "double-quoted-scalar": {
4437
- const o = this.flowScalar(this.type);
4438
- i || t.value ? (e.items.push({ start: r, key: o, sep: [] }), this.onKeyLine = !0) : t.sep ? this.stack.push(o) : (Object.assign(t, { key: o, sep: [] }), this.onKeyLine = !0);
4462
+ const l = this.flowScalar(this.type);
4463
+ r || t.value ? (e.items.push({ start: o, key: l, sep: [] }), this.onKeyLine = !0) : t.sep ? this.stack.push(l) : (Object.assign(t, { key: l, sep: [] }), this.onKeyLine = !0);
4439
4464
  return;
4440
4465
  }
4441
4466
  default: {
4442
- const o = this.startBlockValue(e);
4443
- if (o) {
4444
- i && o.type !== "block-seq" && q(t.start, "explicit-key-ind") && e.items.push({ start: r }), this.stack.push(o);
4467
+ const l = this.startBlockValue(e);
4468
+ if (l) {
4469
+ i && l.type !== "block-seq" && e.items.push({ start: o }), this.stack.push(l);
4445
4470
  return;
4446
4471
  }
4447
4472
  }
@@ -4484,7 +4509,7 @@ class It {
4484
4509
  case "seq-item-ind":
4485
4510
  if (this.indent !== e.indent)
4486
4511
  break;
4487
- t.value || q(t.start, "seq-item-ind") ? e.items.push({ start: [this.sourceToken] }) : t.start.push(this.sourceToken);
4512
+ t.value || Q(t.start, "seq-item-ind") ? e.items.push({ start: [this.sourceToken] }) : t.start.push(this.sourceToken);
4488
4513
  return;
4489
4514
  }
4490
4515
  if (this.indent > e.indent) {
@@ -4539,7 +4564,7 @@ class It {
4539
4564
  if (n.type === "block-map" && (this.type === "map-value-ind" && n.indent === e.indent || this.type === "newline" && !n.items[n.items.length - 1].sep))
4540
4565
  yield* this.pop(), yield* this.step();
4541
4566
  else if (this.type === "map-value-ind" && n.type !== "flow-collection") {
4542
- const i = Le(n), r = te(i);
4567
+ const i = $e(n), r = te(i);
4543
4568
  Dt(e);
4544
4569
  const o = e.end.splice(1, e.end.length);
4545
4570
  o.push(this.sourceToken);
@@ -4603,17 +4628,17 @@ class It {
4603
4628
  };
4604
4629
  case "explicit-key-ind": {
4605
4630
  this.onKeyLine = !0;
4606
- const t = Le(e), n = te(t);
4631
+ const t = $e(e), n = te(t);
4607
4632
  return n.push(this.sourceToken), {
4608
4633
  type: "block-map",
4609
4634
  offset: this.offset,
4610
4635
  indent: this.indent,
4611
- items: [{ start: n }]
4636
+ items: [{ start: n, explicitKey: !0 }]
4612
4637
  };
4613
4638
  }
4614
4639
  case "map-value-ind": {
4615
4640
  this.onKeyLine = !0;
4616
- const t = Le(e), n = te(t);
4641
+ const t = $e(e), n = te(t);
4617
4642
  return {
4618
4643
  type: "block-map",
4619
4644
  offset: this.offset,
@@ -4653,15 +4678,15 @@ function Ts(s) {
4653
4678
  const e = s.prettyErrors !== !1;
4654
4679
  return { lineCounter: s.lineCounter || e && new Es() || null, prettyErrors: e };
4655
4680
  }
4656
- function jn(s, e = {}) {
4657
- const { lineCounter: t, prettyErrors: n } = Ts(e), i = new It(t == null ? void 0 : t.addNewLine), r = new Et(e), o = Array.from(r.compose(i.parse(s)));
4681
+ function Dn(s, e = {}) {
4682
+ const { lineCounter: t, prettyErrors: n } = Ts(e), i = new Et(t == null ? void 0 : t.addNewLine), r = new At(e), o = Array.from(r.compose(i.parse(s)));
4658
4683
  if (n && t)
4659
4684
  for (const l of o)
4660
- l.errors.forEach(Pe(s, t)), l.warnings.forEach(Pe(s, t));
4685
+ l.errors.forEach(De(s, t)), l.warnings.forEach(De(s, t));
4661
4686
  return o.length > 0 ? o : Object.assign([], { empty: !0 }, r.streamInfo());
4662
4687
  }
4663
4688
  function Ls(s, e = {}) {
4664
- const { lineCounter: t, prettyErrors: n } = Ts(e), i = new It(t == null ? void 0 : t.addNewLine), r = new Et(e);
4689
+ const { lineCounter: t, prettyErrors: n } = Ts(e), i = new Et(t == null ? void 0 : t.addNewLine), r = new At(e);
4665
4690
  let o = null;
4666
4691
  for (const l of r.compose(i.parse(s), !0, s.length))
4667
4692
  if (!o)
@@ -4670,9 +4695,9 @@ function Ls(s, e = {}) {
4670
4695
  o.errors.push(new X(l.range.slice(0, 2), "MULTIPLE_DOCS", "Source contains multiple documents; please use YAML.parseAllDocuments()"));
4671
4696
  break;
4672
4697
  }
4673
- return n && t && (o.errors.forEach(Pe(s, t)), o.warnings.forEach(Pe(s, t))), o;
4698
+ return n && t && (o.errors.forEach(De(s, t)), o.warnings.forEach(De(s, t))), o;
4674
4699
  }
4675
- function Dn(s, e, t) {
4700
+ function jn(s, e, t) {
4676
4701
  let n;
4677
4702
  typeof e == "function" ? n = e : t === void 0 && e && typeof e == "object" && (t = e);
4678
4703
  const i = Ls(s, t);
@@ -4698,68 +4723,68 @@ function Kn(s, e, t) {
4698
4723
  }
4699
4724
  return new ye(s, n, t).toString(t);
4700
4725
  }
4701
- const qn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4726
+ var qn = /* @__PURE__ */ Object.freeze({
4702
4727
  __proto__: null,
4703
- Alias: Ke,
4728
+ Alias: qe,
4704
4729
  CST: Bn,
4705
- Composer: Et,
4730
+ Composer: At,
4706
4731
  Document: ye,
4707
4732
  Lexer: As,
4708
4733
  LineCounter: Es,
4709
4734
  Pair: v,
4710
- Parser: It,
4711
- Scalar: N,
4712
- Schema: Qe,
4713
- YAMLError: Ot,
4735
+ Parser: Et,
4736
+ Scalar: O,
4737
+ Schema: We,
4738
+ YAMLError: Nt,
4714
4739
  YAMLMap: P,
4715
4740
  YAMLParseError: X,
4716
- YAMLSeq: G,
4741
+ YAMLSeq: J,
4717
4742
  YAMLWarning: ds,
4718
4743
  isAlias: Z,
4719
- isCollection: T,
4744
+ isCollection: L,
4720
4745
  isDocument: ue,
4721
4746
  isMap: he,
4722
4747
  isNode: $,
4723
- isPair: E,
4724
- isScalar: A,
4748
+ isPair: I,
4749
+ isScalar: E,
4725
4750
  isSeq: de,
4726
- parse: Dn,
4727
- parseAllDocuments: jn,
4751
+ parse: jn,
4752
+ parseAllDocuments: Dn,
4728
4753
  parseDocument: Ls,
4729
4754
  stringify: Kn,
4730
4755
  visit: Y,
4731
- visitAsync: De
4732
- }, Symbol.toStringTag, { value: "Module" }));
4756
+ visitAsync: Ke
4757
+ });
4733
4758
  export {
4734
- Ke as Alias,
4759
+ qe as Alias,
4735
4760
  Bn as CST,
4736
- Et as Composer,
4761
+ At as Composer,
4737
4762
  ye as Document,
4738
4763
  As as Lexer,
4739
4764
  Es as LineCounter,
4740
4765
  v as Pair,
4741
- It as Parser,
4742
- N as Scalar,
4743
- Qe as Schema,
4744
- Ot as YAMLError,
4766
+ Et as Parser,
4767
+ O as Scalar,
4768
+ We as Schema,
4769
+ Nt as YAMLError,
4745
4770
  P as YAMLMap,
4746
4771
  X as YAMLParseError,
4747
- G as YAMLSeq,
4772
+ J as YAMLSeq,
4748
4773
  ds as YAMLWarning,
4749
4774
  qn as default,
4750
4775
  Z as isAlias,
4751
- T as isCollection,
4776
+ L as isCollection,
4752
4777
  ue as isDocument,
4753
4778
  he as isMap,
4754
4779
  $ as isNode,
4755
- E as isPair,
4756
- A as isScalar,
4780
+ I as isPair,
4781
+ E as isScalar,
4757
4782
  de as isSeq,
4758
- Dn as parse,
4759
- jn as parseAllDocuments,
4783
+ jn as parse,
4784
+ Dn as parseAllDocuments,
4760
4785
  Ls as parseDocument,
4761
4786
  Kn as stringify,
4762
4787
  Y as visit,
4763
- De as visitAsync
4788
+ Ke as visitAsync
4764
4789
  };
4765
- //# sourceMappingURL=index-pI9JkN46.js.map
4790
+ //# sourceMappingURL=index-B9EWVYfo.js.map