@dendelion/paper-camp 0.30.1 → 0.31.1

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.
Files changed (64) hide show
  1. package/dist/chunks/daemon-state.61FBbbsV.js +332 -0
  2. package/dist/chunks/daemon-state.61FBbbsV.js.map +1 -0
  3. package/dist/chunks/{phase-progress.B7wQZk0L.js → phase-progress.CazP7K7B.js} +1045 -1008
  4. package/dist/chunks/phase-progress.CazP7K7B.js.map +1 -0
  5. package/dist/cli/index.js +9072 -7750
  6. package/dist/cli/index.js.map +1 -1
  7. package/dist/core/daemon-state/daemon-state.d.ts +16 -6
  8. package/dist/core/daemon-state/daemon-state.d.ts.map +1 -1
  9. package/dist/core/doctor/checks/structural.d.ts.map +1 -1
  10. package/dist/core/doctor/rules.d.ts +5 -0
  11. package/dist/core/doctor/rules.d.ts.map +1 -1
  12. package/dist/core/index.js +125 -114
  13. package/dist/core/machine-registry/machine-registry.d.ts +14 -0
  14. package/dist/core/machine-registry/machine-registry.d.ts.map +1 -1
  15. package/dist/core/night-checks.d.ts +14 -0
  16. package/dist/core/night-checks.d.ts.map +1 -0
  17. package/dist/core/night-checks.test.d.ts +2 -0
  18. package/dist/core/night-checks.test.d.ts.map +1 -0
  19. package/dist/core/night-findings.d.ts +9 -0
  20. package/dist/core/night-findings.d.ts.map +1 -0
  21. package/dist/core/night-findings.test.d.ts +2 -0
  22. package/dist/core/night-findings.test.d.ts.map +1 -0
  23. package/dist/core/night-gate.d.ts +14 -0
  24. package/dist/core/night-gate.d.ts.map +1 -0
  25. package/dist/core/night-gate.test.d.ts +2 -0
  26. package/dist/core/night-gate.test.d.ts.map +1 -0
  27. package/dist/core/night-health.d.ts +21 -0
  28. package/dist/core/night-health.d.ts.map +1 -0
  29. package/dist/core/night-health.test.d.ts +2 -0
  30. package/dist/core/night-health.test.d.ts.map +1 -0
  31. package/dist/core/night-prompts.d.ts +16 -0
  32. package/dist/core/night-prompts.d.ts.map +1 -0
  33. package/dist/core/night-prompts.test.d.ts +2 -0
  34. package/dist/core/night-prompts.test.d.ts.map +1 -0
  35. package/dist/core/night-shift.d.ts +33 -0
  36. package/dist/core/night-shift.d.ts.map +1 -0
  37. package/dist/core/night-shift.test.d.ts +2 -0
  38. package/dist/core/night-shift.test.d.ts.map +1 -0
  39. package/dist/core/night-suggestions.d.ts +14 -0
  40. package/dist/core/night-suggestions.d.ts.map +1 -0
  41. package/dist/core/night-suggestions.test.d.ts +2 -0
  42. package/dist/core/night-suggestions.test.d.ts.map +1 -0
  43. package/dist/core/night-worktree.d.ts +7 -0
  44. package/dist/core/night-worktree.d.ts.map +1 -0
  45. package/dist/core/night-worktree.test.d.ts +2 -0
  46. package/dist/core/night-worktree.test.d.ts.map +1 -0
  47. package/dist/core/parse/schemas.d.ts +68 -0
  48. package/dist/core/parse/schemas.d.ts.map +1 -1
  49. package/dist/core/stats.d.ts.map +1 -1
  50. package/dist/core/update-token.d.ts +5 -0
  51. package/dist/core/update-token.d.ts.map +1 -0
  52. package/dist/core/update-token.test.d.ts +2 -0
  53. package/dist/core/update-token.test.d.ts.map +1 -0
  54. package/dist/toolbar/toolbar.js +1431 -1387
  55. package/dist/toolbar/toolbar.js.map +1 -1
  56. package/dist/types/index.d.ts +134 -1
  57. package/dist/types/index.d.ts.map +1 -1
  58. package/dist/types/index.js +32 -12
  59. package/dist/types/index.js.map +1 -1
  60. package/dist/vite/index.js +1 -1
  61. package/package.json +1 -1
  62. package/dist/chunks/daemon-state.sxE7jqkU.js +0 -271
  63. package/dist/chunks/daemon-state.sxE7jqkU.js.map +0 -1
  64. package/dist/chunks/phase-progress.B7wQZk0L.js.map +0 -1
@@ -1,14 +1,14 @@
1
- import { readFile as q, mkdir as oe, writeFile as B, readdir as ct, stat as yi, rename as wi, access as bi } from "node:fs/promises";
2
- import { dirname as Xe, join as $, basename as ki } from "node:path";
1
+ import { readFile as q, mkdir as oe, writeFile as B, readdir as ct, stat as wi, rename as bi, access as ki } from "node:fs/promises";
2
+ import { dirname as Xe, join as A, basename as Si } from "node:path";
3
3
  import { spawn as D } from "node:child_process";
4
- import { AGENT_IDS as Pe, PLAN_KINDS as Si } from "../types/index.js";
5
- import { createHash as Ei } from "node:crypto";
6
- import { existsSync as Ni, readFileSync as vi } from "node:fs";
7
- import { fileURLToPath as Ii } from "node:url";
8
- import { t as $i, u as Ai, c as Ti, k as Oi, a as Ci, s as _i } from "./daemon-state.sxE7jqkU.js";
9
- import { z as y } from "zod";
10
- const Li = /^([A-Za-z_][A-Za-z0-9_]*)\s*=\s*(.*)$/;
11
- function Ri(n) {
4
+ import { AGENT_IDS as Pe, NIGHT_CHECK_IDS as Ei, PLAN_KINDS as Ni } from "../types/index.js";
5
+ import { createHash as vi } from "node:crypto";
6
+ import { existsSync as Ii, readFileSync as Ai } from "node:fs";
7
+ import { fileURLToPath as $i } from "node:url";
8
+ import { y as Ti, z as Oi, e as Ci, n as _i, a as Li, t as Ri } from "./daemon-state.61FBbbsV.js";
9
+ import { z as g } from "zod";
10
+ const Pi = /^([A-Za-z_][A-Za-z0-9_]*)\s*=\s*(.*)$/;
11
+ function Mi(n) {
12
12
  return n.length >= 2 && (n.startsWith('"') && n.endsWith('"') || n.startsWith("'") && n.endsWith("'")) ? n.slice(1, -1) : n;
13
13
  }
14
14
  function bn(n) {
@@ -17,10 +17,10 @@ function bn(n) {
17
17
  function Un(n) {
18
18
  const e = n.trim();
19
19
  if (!e || e.startsWith("#")) return null;
20
- const t = e.match(Li);
21
- return t ? { key: t[1], value: Ri(t[2]) } : null;
20
+ const t = e.match(Pi);
21
+ return t ? { key: t[1], value: Mi(t[2]) } : null;
22
22
  }
23
- function Lc(n) {
23
+ function jc(n) {
24
24
  const e = [];
25
25
  for (const t of n.split(`
26
26
  `)) {
@@ -29,7 +29,7 @@ function Lc(n) {
29
29
  }
30
30
  return e;
31
31
  }
32
- function Rc(n, e) {
32
+ function Bc(n, e) {
33
33
  const t = new Map(e.map((r) => [r.key, r.value])), s = n.length > 0 ? n.split(`
34
34
  `) : [], i = [];
35
35
  for (const r of s) {
@@ -47,7 +47,7 @@ function Rc(n, e) {
47
47
  `)}
48
48
  ` : "";
49
49
  }
50
- function Pc(n) {
50
+ function Fc(n) {
51
51
  return n.archived === !0 || n.status === "done";
52
52
  }
53
53
  function St(n) {
@@ -57,18 +57,18 @@ function St(n) {
57
57
  function lt(n, e, t, s = !1) {
58
58
  return n.kind === "note" || n.status === "dropped" ? n.status : n.archived ? "done" : e ? e.state === "merged" ? St(n) ? "done" : "planned" : e.state === "closed" ? "dropped" : St(n) ? "review" : "in-progress" : t ? n.status === "review" || n.status === "done" ? n.status : s && n.phases.length > 0 ? St(n) ? "review" : "in-progress" : n.phases.length > 0 ? "planned" : "idea" : n.status ?? (n.phases.length > 0 ? "planned" : "idea");
59
59
  }
60
- function Pi(n, e, t) {
60
+ function Di(n, e, t) {
61
61
  return n.kind === "note" || n.kind === "board" || n.status === "dropped" || n.archived || e ? !1 : !t;
62
62
  }
63
- function Mi(n, e) {
63
+ function ji(n, e) {
64
64
  if (n.kind === "note" || n.archived || (e == null ? void 0 : e.state) !== "merged") return !1;
65
65
  const t = lt(n, e, !0);
66
66
  return t === "review" || t === "done";
67
67
  }
68
- function Hn(n) {
68
+ function xn(n) {
69
69
  return n.length === 0 ? "idea" : n.every((e) => e === "done" || e === "dropped") ? "review" : n.some((e) => e !== "idea" && e !== "planned") ? "in-progress" : "planned";
70
70
  }
71
- function Di(n = [], e = [], t = [], s = []) {
71
+ function Bi(n = [], e = [], t = [], s = []) {
72
72
  const i = [
73
73
  ...n.map((o) => ({ kind: "log", date: o.date, text: o.text })),
74
74
  ...e.map((o) => ({ kind: "clarification", date: o.date, text: o.text })),
@@ -83,16 +83,16 @@ function Di(n = [], e = [], t = [], s = []) {
83
83
  function Ft(n, e) {
84
84
  return n.filter((t) => t.kind === e).map((t) => ({ date: t.date ?? "", text: t.text }));
85
85
  }
86
- function xn(n = []) {
86
+ function Hn(n = []) {
87
87
  return Ft(n, "log");
88
88
  }
89
- function ji(n = []) {
89
+ function Fi(n = []) {
90
90
  return Ft(n, "clarification");
91
91
  }
92
- function Bi(n = []) {
92
+ function Ki(n = []) {
93
93
  return Ft(n, "review");
94
94
  }
95
- function Fi(n = []) {
95
+ function qi(n = []) {
96
96
  return n.filter(
97
97
  (e) => e.kind === "note" || e.kind === "decision" || e.kind === "question"
98
98
  ).map((e) => ({
@@ -102,10 +102,10 @@ function Fi(n = []) {
102
102
  kind: e.kind
103
103
  }));
104
104
  }
105
- function Mc(n, e, t) {
105
+ function Kc(n, e, t) {
106
106
  return [...(n ?? []).filter((s) => !e.includes(s.kind)), ...t];
107
107
  }
108
- function Dc(n, e, t, s) {
108
+ function qc(n, e, t, s) {
109
109
  return n.map((i, r) => {
110
110
  if (r !== e) return i;
111
111
  const o = s ? `${i.text}
@@ -116,16 +116,16 @@ ${s}` : i.text;
116
116
  return { ...c, kind: t, text: o };
117
117
  });
118
118
  }
119
- function jc(n = []) {
119
+ function Uc(n = []) {
120
120
  const e = n.reduce((t, s, i) => s.kind === "log" ? i : t, -1);
121
121
  return n.slice(e + 1).filter((t) => t.kind === "chat");
122
122
  }
123
- function Yn(n, e, t = !1, s = !1) {
123
+ function Gn(n, e, t = !1, s = !1) {
124
124
  return {
125
125
  title: n.title,
126
126
  // Non-note entities can't carry the note-only 'open' (schema-enforced).
127
127
  status: lt(n, e, t, s),
128
- statusFallback: Pi(n, e, t),
128
+ statusFallback: Di(n, e, t),
129
129
  kind: n.type,
130
130
  entityKind: n.kind === "note" ? void 0 : n.kind,
131
131
  id: n.id,
@@ -143,16 +143,16 @@ function Yn(n, e, t = !1, s = !1) {
143
143
  body: n.body,
144
144
  phases: n.phases,
145
145
  fixes: n.fixes,
146
- log: xn(n.thread),
147
- clarifications: ji(n.thread),
148
- notes: Fi(n.thread),
149
- review: Bi(n.thread),
146
+ log: Hn(n.thread),
147
+ clarifications: Fi(n.thread),
148
+ notes: qi(n.thread),
149
+ review: Ki(n.thread),
150
150
  thread: n.thread,
151
151
  archived: n.archived,
152
152
  pr: e
153
153
  };
154
154
  }
155
- function Ki(n) {
155
+ function Ui(n) {
156
156
  return {
157
157
  id: n.id,
158
158
  title: n.title,
@@ -162,11 +162,11 @@ function Ki(n) {
162
162
  subject: n.subject,
163
163
  order: n.order,
164
164
  created: n.created,
165
- log: xn(n.thread)
165
+ log: Hn(n.thread)
166
166
  };
167
167
  }
168
- const qi = /^[0-9a-f]{4,40}$/i, Ui = /^Merge pull request #\d+ from \S+\/([a-z]+-\d+)-/i;
169
- function be(n, e) {
168
+ const xi = /^[0-9a-f]{4,40}$/i, Hi = /^Merge pull request #\d+ from \S+\/([a-z]+-\d+)-/i;
169
+ function ke(n, e) {
170
170
  return new Promise((t) => {
171
171
  var r;
172
172
  const s = D("git", e, { cwd: n, stdio: ["ignore", "pipe", "ignore"] });
@@ -176,9 +176,9 @@ function be(n, e) {
176
176
  }), s.on("close", () => t(i)), s.on("error", () => t(""));
177
177
  });
178
178
  }
179
- async function Gn(n) {
179
+ async function Yn(n) {
180
180
  var t;
181
- return ((t = (await be(n, ["symbolic-ref", "refs/remotes/origin/HEAD"])).trim().match(/refs\/remotes\/origin\/(.+)/)) == null ? void 0 : t[1]) ?? "main";
181
+ return ((t = (await ke(n, ["symbolic-ref", "refs/remotes/origin/HEAD"])).trim().match(/refs\/remotes\/origin\/(.+)/)) == null ? void 0 : t[1]) ?? "main";
182
182
  }
183
183
  function Ot(n) {
184
184
  const e = n.match(/^Refs:\s*([A-Za-z]+-\d+)\s*$/m);
@@ -186,26 +186,26 @@ function Ot(n) {
186
186
  const t = n.split(`
187
187
  `, 1)[0], s = t.match(/\(([A-Za-z]+-\d+)\)/);
188
188
  if (s) return s[1].toUpperCase();
189
- const i = t.match(Ui);
189
+ const i = t.match(Hi);
190
190
  return i ? i[1].toUpperCase() : null;
191
191
  }
192
- function Hi(n) {
192
+ function Gi(n) {
193
193
  return n.length > 0 && n.every((e) => e.startsWith("papercamp/"));
194
194
  }
195
195
  async function Vn(n) {
196
- const e = await Gn(n), t = await be(n, ["log", "--format=%x02%B%x00", "--name-only", e]), s = /* @__PURE__ */ new Set();
196
+ const e = await Yn(n), t = await ke(n, ["log", "--format=%x02%B%x00", "--name-only", e]), s = /* @__PURE__ */ new Set();
197
197
  for (const i of t.split("")) {
198
198
  if (!i) continue;
199
199
  const [r, o = ""] = i.split("\0"), a = o.split(`
200
200
  `).map((l) => l.trim()).filter(Boolean);
201
- if (Hi(a)) continue;
201
+ if (Gi(a)) continue;
202
202
  const c = Ot(r.trim());
203
203
  c && s.add(c);
204
204
  }
205
205
  return s;
206
206
  }
207
- const Q = /* @__PURE__ */ new Map(), xi = 5 * 60 * 1e3, Kt = (n) => $(n, "papercamp", "pr-map.json");
208
- async function Yi(n, e, t) {
207
+ const X = /* @__PURE__ */ new Map(), Yi = 5 * 60 * 1e3, Kt = (n) => A(n, "papercamp", "pr-map.json");
208
+ async function Vi(n, e, t) {
209
209
  const s = Kt(n);
210
210
  try {
211
211
  const i = { fetchedAt: t, prs: Object.fromEntries(e) };
@@ -223,13 +223,13 @@ async function Jn(n) {
223
223
  return;
224
224
  }
225
225
  }
226
- const Gi = {
226
+ const Ji = {
227
227
  APPROVED: "approved",
228
228
  CHANGES_REQUESTED: "changes-requested",
229
229
  REVIEW_REQUIRED: "review-required"
230
230
  };
231
- function Vi(n) {
232
- const e = n.state === "MERGED" ? "merged" : n.state === "CLOSED" ? "closed" : n.isDraft ? "draft" : "open", t = Gi[n.reviewDecision];
231
+ function Wi(n) {
232
+ const e = n.state === "MERGED" ? "merged" : n.state === "CLOSED" ? "closed" : n.isDraft ? "draft" : "open", t = Ji[n.reviewDecision];
233
233
  return {
234
234
  number: n.number,
235
235
  url: n.url,
@@ -246,7 +246,7 @@ function Wn(n, e) {
246
246
  const s = e == null ? void 0 : e.match(/^[a-z]+\/([a-z]+-\d+)-/);
247
247
  return s ? s[1].toUpperCase() : null;
248
248
  }
249
- const Ji = `
249
+ const zi = `
250
250
  query($owner: String!, $repo: String!, $number: Int!) {
251
251
  repository(owner: $owner, name: $repo) {
252
252
  pullRequest(number: $number) {
@@ -257,7 +257,7 @@ query($owner: String!, $repo: String!, $number: Int!) {
257
257
  }
258
258
  }
259
259
  }`;
260
- function Wi(n, e) {
260
+ function Qi(n, e) {
261
261
  return `Paper Scout · ${n} · ${e.slice(0, 7)}`;
262
262
  }
263
263
  function Me(n) {
@@ -266,7 +266,7 @@ function Me(n) {
266
266
  const [, t, s, i] = e;
267
267
  return { owner: t, repo: s, number: i };
268
268
  }
269
- const zi = 15e3;
269
+ const Xi = 15e3;
270
270
  function zn(n, e) {
271
271
  return new Promise((t) => {
272
272
  var c, l;
@@ -276,7 +276,7 @@ function zn(n, e) {
276
276
  i || (i = !0, clearTimeout(o), f());
277
277
  }, o = setTimeout(() => {
278
278
  s.kill(), r(() => t(void 0));
279
- }, zi);
279
+ }, Xi);
280
280
  let a = "";
281
281
  (c = s.stdout) == null || c.on("data", (f) => {
282
282
  a += f.toString();
@@ -317,16 +317,16 @@ function Xn(n, e, t) {
317
317
  function Zn(n, e) {
318
318
  return zn(n, ["api", "graphql", ...e]);
319
319
  }
320
- async function Qi(n, e) {
321
- var f, u, h, p, g;
320
+ async function Zi(n, e) {
321
+ var f, u, h, p, y;
322
322
  const t = Me(e);
323
323
  if (!t) return;
324
- const s = await Qn(n, Ji, t.owner, t.repo, t.number), i = (u = (f = s == null ? void 0 : s.data) == null ? void 0 : f.repository) == null ? void 0 : u.pullRequest;
324
+ const s = await Qn(n, zi, t.owner, t.repo, t.number), i = (u = (f = s == null ? void 0 : s.data) == null ? void 0 : f.repository) == null ? void 0 : u.pullRequest;
325
325
  if (!i) return;
326
- const r = i.reviewThreads.nodes.filter((d) => !d.isResolved).length, o = (h = i.commits.nodes[0]) == null ? void 0 : h.commit.committedDate, a = [(p = i.comments.nodes[0]) == null ? void 0 : p.createdAt, (g = i.reviews.nodes.at(-1)) == null ? void 0 : g.createdAt].filter((d) => !!d).sort().at(-1), c = !!(o && a && a > o), l = i.reviews.nodes.map((d) => d.body);
326
+ const r = i.reviewThreads.nodes.filter((d) => !d.isResolved).length, o = (h = i.commits.nodes[0]) == null ? void 0 : h.commit.committedDate, a = [(p = i.comments.nodes[0]) == null ? void 0 : p.createdAt, (y = i.reviews.nodes.at(-1)) == null ? void 0 : y.createdAt].filter((d) => !!d).sort().at(-1), c = !!(o && a && a > o), l = i.reviews.nodes.map((d) => d.body);
327
327
  return { unresolvedThreadCount: r, hasNewCommentsSincePush: c, reviewBodies: l };
328
328
  }
329
- const Xi = `
329
+ const er = `
330
330
  query($owner: String!, $repo: String!, $number: Int!) {
331
331
  repository(owner: $owner, name: $repo) {
332
332
  pullRequest(number: $number) {
@@ -340,11 +340,11 @@ query($owner: String!, $repo: String!, $number: Int!) {
340
340
  }
341
341
  }
342
342
  }`;
343
- async function Bc(n, e) {
343
+ async function xc(n, e) {
344
344
  var r, o, a;
345
345
  const t = Me(e);
346
346
  if (!t) return [];
347
- const s = await Qn(n, Xi, t.owner, t.repo, t.number);
347
+ const s = await Qn(n, er, t.owner, t.repo, t.number);
348
348
  return (((a = (o = (r = s == null ? void 0 : s.data) == null ? void 0 : r.repository) == null ? void 0 : o.pullRequest) == null ? void 0 : a.reviewThreads.nodes) ?? []).filter((c) => !c.isResolved).map((c) => ({ id: c.id, comment: c.comments.nodes[0] })).filter((c) => !!c.comment).map(({ id: c, comment: l }) => {
349
349
  var f;
350
350
  return {
@@ -356,25 +356,25 @@ async function Bc(n, e) {
356
356
  };
357
357
  });
358
358
  }
359
- const Zi = `
359
+ const tr = `
360
360
  mutation($threadId: ID!) {
361
361
  resolveReviewThread(input: { threadId: $threadId }) {
362
362
  thread { id isResolved }
363
363
  }
364
- }`, er = `
364
+ }`, nr = `
365
365
  mutation($threadId: ID!, $body: String!) {
366
366
  addPullRequestReviewThreadReply(input: { pullRequestReviewThreadId: $threadId, body: $body }) {
367
367
  comment { id }
368
368
  }
369
369
  }`;
370
- async function Fc(n, e) {
370
+ async function Hc(n, e) {
371
371
  var s, i, r;
372
- const t = await Xn(n, Zi, { threadId: e });
372
+ const t = await Xn(n, tr, { threadId: e });
373
373
  return !!((r = (i = (s = t == null ? void 0 : t.data) == null ? void 0 : s.resolveReviewThread) == null ? void 0 : i.thread) != null && r.isResolved);
374
374
  }
375
- async function Kc(n, e, t) {
375
+ async function Gc(n, e, t) {
376
376
  var i, r, o;
377
- const s = await Xn(n, er, { threadId: e, body: t });
377
+ const s = await Xn(n, nr, { threadId: e, body: t });
378
378
  return !!((o = (r = (i = s == null ? void 0 : s.data) == null ? void 0 : i.addPullRequestReviewThreadReply) == null ? void 0 : r.comment) != null && o.id);
379
379
  }
380
380
  function es(n, e, t) {
@@ -394,7 +394,7 @@ function es(n, e, t) {
394
394
  }), (c = i.stdin) == null || c.end(JSON.stringify(t));
395
395
  });
396
396
  }
397
- async function qc(n, e, t) {
397
+ async function Yc(n, e, t) {
398
398
  const s = Me(e);
399
399
  return s ? es(
400
400
  n,
@@ -402,25 +402,25 @@ async function qc(n, e, t) {
402
402
  t
403
403
  ) : { delivered: !1 };
404
404
  }
405
- async function Uc(n, e, t) {
405
+ async function Vc(n, e, t) {
406
406
  const s = Me(e);
407
407
  return s ? es(n, `repos/${s.owner}/${s.repo}/dispatches`, {
408
408
  event_type: "paper-camp-review",
409
409
  client_payload: { review: { number: Number(s.number), ...t } }
410
410
  }) : { delivered: !1 };
411
411
  }
412
- async function tr(n, e) {
412
+ async function sr(n, e) {
413
413
  const t = [...e.entries()].filter(
414
414
  ([, i]) => i.state === "open" || i.state === "draft"
415
- ), s = await Promise.all(t.map(([, i]) => Qi(n, i.url)));
415
+ ), s = await Promise.all(t.map(([, i]) => Zi(n, i.url)));
416
416
  t.forEach(([i, r], o) => {
417
417
  const a = s[o];
418
418
  if (!a) return;
419
- const { reviewBodies: c, ...l } = a, f = !!r.headSha && c.some((u) => u.includes(Wi(i, r.headSha)));
419
+ const { reviewBodies: c, ...l } = a, f = !!r.headSha && c.some((u) => u.includes(Qi(i, r.headSha)));
420
420
  e.set(i, { ...r, ...l, ...f && { scoutReviewObserved: f } });
421
421
  });
422
422
  }
423
- async function nr(n) {
423
+ async function ir(n) {
424
424
  const e = await zn(n, [
425
425
  "pr",
426
426
  "list",
@@ -436,41 +436,41 @@ async function nr(n) {
436
436
  for (const s of e) {
437
437
  const i = Wn(s.body, s.headRefName);
438
438
  if (!i) continue;
439
- const r = Vi(s), o = t.get(i);
439
+ const r = Wi(s), o = t.get(i);
440
440
  (!o || kn[r.state] > kn[o.state]) && t.set(i, r);
441
441
  }
442
- return await tr(n, t), t;
442
+ return await sr(n, t), t;
443
443
  }
444
- async function ts(n, e = xi) {
445
- let t = Q.get(n);
444
+ async function ts(n, e = Yi) {
445
+ let t = X.get(n);
446
446
  if (!t) {
447
447
  const i = await Jn(n);
448
- i && (Q.set(n, i), t = i);
448
+ i && (X.set(n, i), t = i);
449
449
  }
450
450
  if (t && Date.now() - t.fetchedAt < e) return t.prs;
451
451
  if (!Number.isFinite(e)) return t == null ? void 0 : t.prs;
452
- const s = await nr(n);
452
+ const s = await ir(n);
453
453
  if (s !== void 0) {
454
454
  const i = Date.now();
455
- return Q.set(n, { prs: s, fetchedAt: i }), await Yi(n, s, i), s;
455
+ return X.set(n, { prs: s, fetchedAt: i }), await Vi(n, s, i), s;
456
456
  }
457
457
  return t == null ? void 0 : t.prs;
458
458
  }
459
- async function Hc(n) {
460
- let e = Q.get(n);
459
+ async function Jc(n) {
460
+ let e = X.get(n);
461
461
  if (!e) {
462
462
  const t = await Jn(n);
463
- t && (Q.set(n, t), e = t);
463
+ t && (X.set(n, t), e = t);
464
464
  }
465
465
  return (e == null ? void 0 : e.fetchedAt) ?? null;
466
466
  }
467
- async function xc(n) {
467
+ async function Wc(n) {
468
468
  if (n === void 0) {
469
- Q.clear();
469
+ X.clear();
470
470
  return;
471
471
  }
472
- const e = Q.get(n);
473
- e && Q.set(n, { ...e, fetchedAt: 0 });
472
+ const e = X.get(n);
473
+ e && X.set(n, { ...e, fetchedAt: 0 });
474
474
  const t = Kt(n);
475
475
  try {
476
476
  const s = await q(t, "utf-8"), i = JSON.parse(s);
@@ -479,12 +479,12 @@ async function xc(n) {
479
479
  } catch {
480
480
  }
481
481
  }
482
- const qt = Symbol.for("yaml.alias"), Ct = Symbol.for("yaml.document"), X = Symbol.for("yaml.map"), ns = Symbol.for("yaml.pair"), G = Symbol.for("yaml.scalar"), ke = Symbol.for("yaml.seq"), K = Symbol.for("yaml.node.type"), Se = (n) => !!n && typeof n == "object" && n[K] === qt, De = (n) => !!n && typeof n == "object" && n[K] === Ct, je = (n) => !!n && typeof n == "object" && n[K] === X, L = (n) => !!n && typeof n == "object" && n[K] === ns, O = (n) => !!n && typeof n == "object" && n[K] === G, Be = (n) => !!n && typeof n == "object" && n[K] === ke;
482
+ const qt = Symbol.for("yaml.alias"), Ct = Symbol.for("yaml.document"), Z = Symbol.for("yaml.map"), ns = Symbol.for("yaml.pair"), Y = Symbol.for("yaml.scalar"), Se = Symbol.for("yaml.seq"), K = Symbol.for("yaml.node.type"), Ee = (n) => !!n && typeof n == "object" && n[K] === qt, De = (n) => !!n && typeof n == "object" && n[K] === Ct, je = (n) => !!n && typeof n == "object" && n[K] === Z, L = (n) => !!n && typeof n == "object" && n[K] === ns, O = (n) => !!n && typeof n == "object" && n[K] === Y, Be = (n) => !!n && typeof n == "object" && n[K] === Se;
483
483
  function C(n) {
484
484
  if (n && typeof n == "object")
485
485
  switch (n[K]) {
486
- case X:
487
- case ke:
486
+ case Z:
487
+ case Se:
488
488
  return !0;
489
489
  }
490
490
  return !1;
@@ -493,25 +493,25 @@ function _(n) {
493
493
  if (n && typeof n == "object")
494
494
  switch (n[K]) {
495
495
  case qt:
496
- case X:
497
- case G:
498
- case ke:
496
+ case Z:
497
+ case Y:
498
+ case Se:
499
499
  return !0;
500
500
  }
501
501
  return !1;
502
502
  }
503
- const ss = (n) => (O(n) || C(n)) && !!n.anchor, ne = Symbol("break visit"), sr = Symbol("skip children"), Oe = Symbol("remove node");
504
- function Ee(n, e) {
505
- const t = ir(e);
506
- De(n) ? fe(null, n.contents, t, Object.freeze([n])) === Oe && (n.contents = null) : fe(null, n, t, Object.freeze([]));
503
+ const ss = (n) => (O(n) || C(n)) && !!n.anchor, ne = Symbol("break visit"), rr = Symbol("skip children"), Ce = Symbol("remove node");
504
+ function Ne(n, e) {
505
+ const t = or(e);
506
+ De(n) ? fe(null, n.contents, t, Object.freeze([n])) === Ce && (n.contents = null) : fe(null, n, t, Object.freeze([]));
507
507
  }
508
- Ee.BREAK = ne;
509
- Ee.SKIP = sr;
510
- Ee.REMOVE = Oe;
508
+ Ne.BREAK = ne;
509
+ Ne.SKIP = rr;
510
+ Ne.REMOVE = Ce;
511
511
  function fe(n, e, t, s) {
512
- const i = rr(n, e, t, s);
512
+ const i = ar(n, e, t, s);
513
513
  if (_(i) || L(i))
514
- return or(n, s, i), fe(n, i, t, s);
514
+ return cr(n, s, i), fe(n, i, t, s);
515
515
  if (typeof i != "symbol") {
516
516
  if (C(e)) {
517
517
  s = Object.freeze(s.concat(e));
@@ -522,7 +522,7 @@ function fe(n, e, t, s) {
522
522
  else {
523
523
  if (o === ne)
524
524
  return ne;
525
- o === Oe && (e.items.splice(r, 1), r -= 1);
525
+ o === Ce && (e.items.splice(r, 1), r -= 1);
526
526
  }
527
527
  }
528
528
  } else if (L(e)) {
@@ -530,16 +530,16 @@ function fe(n, e, t, s) {
530
530
  const r = fe("key", e.key, t, s);
531
531
  if (r === ne)
532
532
  return ne;
533
- r === Oe && (e.key = null);
533
+ r === Ce && (e.key = null);
534
534
  const o = fe("value", e.value, t, s);
535
535
  if (o === ne)
536
536
  return ne;
537
- o === Oe && (e.value = null);
537
+ o === Ce && (e.value = null);
538
538
  }
539
539
  }
540
540
  return i;
541
541
  }
542
- function ir(n) {
542
+ function or(n) {
543
543
  return typeof n == "object" && (n.Collection || n.Node || n.Value) ? Object.assign({
544
544
  Alias: n.Node,
545
545
  Map: n.Node,
@@ -554,7 +554,7 @@ function ir(n) {
554
554
  Seq: n.Collection
555
555
  }, n) : n;
556
556
  }
557
- function rr(n, e, t, s) {
557
+ function ar(n, e, t, s) {
558
558
  var i, r, o, a, c;
559
559
  if (typeof t == "function")
560
560
  return t(n, e, s);
@@ -566,10 +566,10 @@ function rr(n, e, t, s) {
566
566
  return (o = t.Pair) == null ? void 0 : o.call(t, n, e, s);
567
567
  if (O(e))
568
568
  return (a = t.Scalar) == null ? void 0 : a.call(t, n, e, s);
569
- if (Se(e))
569
+ if (Ee(e))
570
570
  return (c = t.Alias) == null ? void 0 : c.call(t, n, e, s);
571
571
  }
572
- function or(n, e, t) {
572
+ function cr(n, e, t) {
573
573
  const s = e[e.length - 1];
574
574
  if (C(s))
575
575
  s.items[n] = t;
@@ -578,18 +578,18 @@ function or(n, e, t) {
578
578
  else if (De(s))
579
579
  s.contents = t;
580
580
  else {
581
- const i = Se(s) ? "alias" : "scalar";
581
+ const i = Ee(s) ? "alias" : "scalar";
582
582
  throw new Error(`Cannot replace node with ${i} parent`);
583
583
  }
584
584
  }
585
- const ar = {
585
+ const lr = {
586
586
  "!": "%21",
587
587
  ",": "%2C",
588
588
  "[": "%5B",
589
589
  "]": "%5D",
590
590
  "{": "%7B",
591
591
  "}": "%7D"
592
- }, cr = (n) => n.replace(/[!,[\]{}]/g, (e) => ar[e]);
592
+ }, ur = (n) => n.replace(/[!,[\]{}]/g, (e) => lr[e]);
593
593
  class P {
594
594
  constructor(e, t) {
595
595
  this.docStart = null, this.docEnd = !1, this.yaml = Object.assign({}, P.defaultYaml, e), this.tags = Object.assign({}, P.defaultTags, t);
@@ -679,7 +679,7 @@ class P {
679
679
  tagString(e) {
680
680
  for (const [t, s] of Object.entries(this.tags))
681
681
  if (e.startsWith(s))
682
- return t + cr(e.substring(s.length));
682
+ return t + ur(e.substring(s.length));
683
683
  return e[0] === "!" ? e : `!<${e}>`;
684
684
  }
685
685
  toString(e) {
@@ -687,7 +687,7 @@ class P {
687
687
  let i;
688
688
  if (e && s.length > 0 && _(e.contents)) {
689
689
  const r = {};
690
- Ee(e.contents, (o, a) => {
690
+ Ne(e.contents, (o, a) => {
691
691
  _(a) && a.tag && (r[a.tag] = !0);
692
692
  }), i = Object.keys(r);
693
693
  } else
@@ -709,7 +709,7 @@ function is(n) {
709
709
  }
710
710
  function rs(n) {
711
711
  const e = /* @__PURE__ */ new Set();
712
- return Ee(n, {
712
+ return Ne(n, {
713
713
  Value(t, s) {
714
714
  s.anchor && e.add(s.anchor);
715
715
  }
@@ -722,7 +722,7 @@ function os(n, e) {
722
722
  return s;
723
723
  }
724
724
  }
725
- function lr(n, e) {
725
+ function fr(n, e) {
726
726
  const t = [], s = /* @__PURE__ */ new Map();
727
727
  let i = null;
728
728
  return {
@@ -816,7 +816,7 @@ class Ut {
816
816
  return typeof r == "function" ? de(r, { "": a }, "", a) : a;
817
817
  }
818
818
  }
819
- class Ht extends Ut {
819
+ class xt extends Ut {
820
820
  constructor(e) {
821
821
  super(qt), this.source = e, Object.defineProperty(this, "tag", {
822
822
  set() {
@@ -832,9 +832,9 @@ class Ht extends Ut {
832
832
  if ((t == null ? void 0 : t.maxAliasCount) === 0)
833
833
  throw new ReferenceError("Alias resolution is disabled");
834
834
  let s;
835
- t != null && t.aliasResolveCache ? s = t.aliasResolveCache : (s = [], Ee(e, {
835
+ t != null && t.aliasResolveCache ? s = t.aliasResolveCache : (s = [], Ne(e, {
836
836
  Node: (r, o) => {
837
- (Se(o) || ss(o)) && s.push(o);
837
+ (Ee(o) || ss(o)) && s.push(o);
838
838
  }
839
839
  }), t && (t.aliasResolveCache = s));
840
840
  let i;
@@ -878,7 +878,7 @@ class Ht extends Ut {
878
878
  }
879
879
  }
880
880
  function Je(n, e, t) {
881
- if (Se(e)) {
881
+ if (Ee(e)) {
882
882
  const s = e.resolve(n), i = t && s && t.get(s);
883
883
  return i ? i.count * i.aliasCount : 0;
884
884
  } else if (C(e)) {
@@ -897,7 +897,7 @@ function Je(n, e, t) {
897
897
  const as = (n) => !n || typeof n != "function" && typeof n != "object";
898
898
  class v extends Ut {
899
899
  constructor(e) {
900
- super(G), this.value = e;
900
+ super(Y), this.value = e;
901
901
  }
902
902
  toJSON(e, t) {
903
903
  return t != null && t.keep ? this.value : F(this.value, e, t);
@@ -911,8 +911,8 @@ v.BLOCK_LITERAL = "BLOCK_LITERAL";
911
911
  v.PLAIN = "PLAIN";
912
912
  v.QUOTE_DOUBLE = "QUOTE_DOUBLE";
913
913
  v.QUOTE_SINGLE = "QUOTE_SINGLE";
914
- const ur = "tag:yaml.org,2002:";
915
- function fr(n, e, t) {
914
+ const dr = "tag:yaml.org,2002:";
915
+ function hr(n, e, t) {
916
916
  if (e) {
917
917
  const s = t.filter((r) => r.tag === e), i = s.find((r) => !r.format) ?? s[0];
918
918
  if (!i)
@@ -924,30 +924,30 @@ function fr(n, e, t) {
924
924
  return ((i = s.identify) == null ? void 0 : i.call(s, n)) && !s.format;
925
925
  });
926
926
  }
927
- function _e(n, e, t) {
927
+ function Le(n, e, t) {
928
928
  var u, h, p;
929
929
  if (De(n) && (n = n.contents), _(n))
930
930
  return n;
931
931
  if (L(n)) {
932
- const g = (h = (u = t.schema[X]).createNode) == null ? void 0 : h.call(u, t.schema, null, t);
933
- return g.items.push(n), g;
932
+ const y = (h = (u = t.schema[Z]).createNode) == null ? void 0 : h.call(u, t.schema, null, t);
933
+ return y.items.push(n), y;
934
934
  }
935
935
  (n instanceof String || n instanceof Number || n instanceof Boolean || typeof BigInt < "u" && n instanceof BigInt) && (n = n.valueOf());
936
936
  const { aliasDuplicateObjects: s, onAnchor: i, onTagObj: r, schema: o, sourceObjects: a } = t;
937
937
  let c;
938
938
  if (s && n && typeof n == "object") {
939
939
  if (c = a.get(n), c)
940
- return c.anchor ?? (c.anchor = i(n)), new Ht(c.anchor);
940
+ return c.anchor ?? (c.anchor = i(n)), new xt(c.anchor);
941
941
  c = { anchor: null, node: null }, a.set(n, c);
942
942
  }
943
- e != null && e.startsWith("!!") && (e = ur + e.slice(2));
944
- let l = fr(n, e, o.tags);
943
+ e != null && e.startsWith("!!") && (e = dr + e.slice(2));
944
+ let l = hr(n, e, o.tags);
945
945
  if (!l) {
946
946
  if (n && typeof n.toJSON == "function" && (n = n.toJSON()), !n || typeof n != "object") {
947
- const g = new v(n);
948
- return c && (c.node = g), g;
947
+ const y = new v(n);
948
+ return c && (c.node = y), y;
949
949
  }
950
- l = n instanceof Map ? o[X] : Symbol.iterator in Object(n) ? o[ke] : o[X];
950
+ l = n instanceof Map ? o[Z] : Symbol.iterator in Object(n) ? o[Se] : o[Z];
951
951
  }
952
952
  r && (r(l), delete t.onTagObj);
953
953
  const f = l != null && l.createNode ? l.createNode(t.schema, n, t) : typeof ((p = l == null ? void 0 : l.nodeClass) == null ? void 0 : p.from) == "function" ? l.nodeClass.from(t.schema, n, t) : new v(n);
@@ -963,7 +963,7 @@ function Ze(n, e, t) {
963
963
  } else
964
964
  s = /* @__PURE__ */ new Map([[r, s]]);
965
965
  }
966
- return _e(s, void 0, {
966
+ return Le(s, void 0, {
967
967
  aliasDuplicateObjects: !1,
968
968
  keepUndefined: !1,
969
969
  onAnchor: () => {
@@ -973,7 +973,7 @@ function Ze(n, e, t) {
973
973
  sourceObjects: /* @__PURE__ */ new Map()
974
974
  });
975
975
  }
976
- const Ae = (n) => n == null || typeof n == "object" && !!n[Symbol.iterator]().next().done;
976
+ const Te = (n) => n == null || typeof n == "object" && !!n[Symbol.iterator]().next().done;
977
977
  class cs extends Ut {
978
978
  constructor(e, t) {
979
979
  super(e), Object.defineProperty(this, "schema", {
@@ -998,7 +998,7 @@ class cs extends Ut {
998
998
  * that already exists in the map.
999
999
  */
1000
1000
  addIn(e, t) {
1001
- if (Ae(e))
1001
+ if (Te(e))
1002
1002
  this.add(t);
1003
1003
  else {
1004
1004
  const [s, ...i] = e, r = this.get(s, !0);
@@ -1069,7 +1069,7 @@ class cs extends Ut {
1069
1069
  }
1070
1070
  }
1071
1071
  }
1072
- const dr = (n) => n.replace(/^(?!$)(?: $)?/gm, "#");
1072
+ const pr = (n) => n.replace(/^(?!$)(?: $)?/gm, "#");
1073
1073
  function J(n, e) {
1074
1074
  return /^\n+$/.test(n) ? n.substring(1) : e ? n.replace(/^(?! *$)/gm, e) : n;
1075
1075
  }
@@ -1087,7 +1087,7 @@ function ut(n, e, t = "flow", { indentAtStart: s, lineWidth: i = 80, minContentW
1087
1087
  const l = [], f = {};
1088
1088
  let u = i - e.length;
1089
1089
  typeof s == "number" && (s > i - Math.max(2, r) ? l.push(0) : u = i - s);
1090
- let h, p, g = !1, d = -1, m = -1, w = -1;
1090
+ let h, p, y = !1, d = -1, m = -1, w = -1;
1091
1091
  t === _t && (d = Sn(n, d, e.length), d !== -1 && (u = d + c));
1092
1092
  for (let E; E = n[d += 1]; ) {
1093
1093
  if (t === We && E === "\\") {
@@ -1121,17 +1121,17 @@ function ut(n, e, t = "flow", { indentAtStart: s, lineWidth: i = 80, minContentW
1121
1121
  l.push(h), u = h + c, h = void 0;
1122
1122
  else if (t === We) {
1123
1123
  for (; p === " " || p === " "; )
1124
- p = E, E = n[d += 1], g = !0;
1124
+ p = E, E = n[d += 1], y = !0;
1125
1125
  const S = d > w + 1 ? d - 2 : m - 1;
1126
1126
  if (f[S])
1127
1127
  return n;
1128
1128
  l.push(S), f[S] = !0, u = S + c, h = void 0;
1129
1129
  } else
1130
- g = !0;
1130
+ y = !0;
1131
1131
  }
1132
1132
  p = E;
1133
1133
  }
1134
- if (g && a && a(), l.length === 0)
1134
+ if (y && a && a(), l.length === 0)
1135
1135
  return n;
1136
1136
  o && o();
1137
1137
  let b = n.slice(0, l[0]);
@@ -1162,7 +1162,7 @@ const ft = (n, e) => ({
1162
1162
  lineWidth: n.options.lineWidth,
1163
1163
  minContentWidth: n.options.minContentWidth
1164
1164
  }), dt = (n) => /^(%|---|\.\.\.)/m.test(n);
1165
- function hr(n, e, t) {
1165
+ function mr(n, e, t) {
1166
1166
  if (!e || e < 0)
1167
1167
  return !1;
1168
1168
  const s = e - t, i = n.length;
@@ -1178,7 +1178,7 @@ function hr(n, e, t) {
1178
1178
  }
1179
1179
  return !0;
1180
1180
  }
1181
- function Ce(n, e) {
1181
+ function _e(n, e) {
1182
1182
  const t = JSON.stringify(n);
1183
1183
  if (e.options.doubleQuotedAsJSON)
1184
1184
  return t;
@@ -1242,7 +1242,7 @@ function Ce(n, e) {
1242
1242
  function Lt(n, e) {
1243
1243
  if (e.options.singleQuote === !1 || e.implicitKey && n.includes(`
1244
1244
  `) || /[ \t]\n|\n[ \t]/.test(n))
1245
- return Ce(n, e);
1245
+ return _e(n, e);
1246
1246
  const t = e.indent || (dt(n) ? " " : ""), s = "'" + n.replace(/'/g, "''").replace(/\n+/g, `$&
1247
1247
  ${t}`) + "'";
1248
1248
  return e.implicitKey ? s : ut(s, t, ls, ft(e, !1));
@@ -1251,10 +1251,10 @@ function he(n, e) {
1251
1251
  const { singleQuote: t } = e.options;
1252
1252
  let s;
1253
1253
  if (t === !1)
1254
- s = Ce;
1254
+ s = _e;
1255
1255
  else {
1256
1256
  const i = n.includes('"'), r = n.includes("'");
1257
- i && !r ? s = Lt : r && !i ? s = Ce : s = t ? Lt : Ce;
1257
+ i && !r ? s = Lt : r && !i ? s = _e : s = t ? Lt : _e;
1258
1258
  }
1259
1259
  return s(n, e);
1260
1260
  }
@@ -1271,7 +1271,7 @@ function ze({ comment: n, type: e, value: t }, s, i, r) {
1271
1271
  const { blockQuote: o, commentString: a, lineWidth: c } = s.options;
1272
1272
  if (!o || /\n[\t ]+$/.test(t))
1273
1273
  return he(t, s);
1274
- const l = s.indent || (s.forceBlockIndent || dt(t) ? " " : ""), f = o === "literal" ? !0 : o === "folded" || e === v.BLOCK_FOLDED ? !1 : e === v.BLOCK_LITERAL ? !0 : !hr(t, c, l.length);
1274
+ const l = s.indent || (s.forceBlockIndent || dt(t) ? " " : ""), f = o === "literal" ? !0 : o === "folded" || e === v.BLOCK_FOLDED ? !1 : e === v.BLOCK_LITERAL ? !0 : !mr(t, c, l.length);
1275
1275
  if (!t)
1276
1276
  return f ? `|
1277
1277
  ` : `>
@@ -1284,9 +1284,9 @@ function ze({ comment: n, type: e, value: t }, s, i, r) {
1284
1284
  break;
1285
1285
  }
1286
1286
  let p = t.substring(h);
1287
- const g = p.indexOf(`
1287
+ const y = p.indexOf(`
1288
1288
  `);
1289
- g === -1 ? u = "-" : t === p || g !== p.length - 1 ? (u = "+", r && r()) : u = "", p && (t = t.slice(0, -p.length), p[p.length - 1] === `
1289
+ y === -1 ? u = "-" : t === p || y !== p.length - 1 ? (u = "+", r && r()) : u = "", p && (t = t.slice(0, -p.length), p[p.length - 1] === `
1290
1290
  ` && (p = p.slice(0, -1)), p = p.replace(Rt, `$&${l}`));
1291
1291
  let d = !1, m, w = -1;
1292
1292
  for (m = 0; m < t.length; ++m) {
@@ -1305,20 +1305,20 @@ function ze({ comment: n, type: e, value: t }, s, i, r) {
1305
1305
  if (n && (S += " " + a(n.replace(/ ?[\r\n]+/g, " ")), i && i()), !f) {
1306
1306
  const N = t.replace(/\n+/g, `
1307
1307
  $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g, "$1$2").replace(/\n+/g, `$&${l}`);
1308
- let A = !1;
1308
+ let $ = !1;
1309
1309
  const I = ft(s, !0);
1310
1310
  o !== "folded" && e !== v.BLOCK_FOLDED && (I.onOverflow = () => {
1311
- A = !0;
1311
+ $ = !0;
1312
1312
  });
1313
1313
  const k = ut(`${b}${N}${p}`, l, _t, I);
1314
- if (!A)
1314
+ if (!$)
1315
1315
  return `>${S}
1316
1316
  ${l}${k}`;
1317
1317
  }
1318
1318
  return t = t.replace(/\n+/g, `$&${l}`), `|${S}
1319
1319
  ${l}${b}${t}${p}`;
1320
1320
  }
1321
- function pr(n, e, t, s) {
1321
+ function gr(n, e, t, s) {
1322
1322
  const { type: i, value: r } = n, { actualString: o, implicitKey: a, indent: c, indentStep: l, inFlow: f } = e;
1323
1323
  if (a && r.includes(`
1324
1324
  `) || f && /[[\]{},]/.test(r))
@@ -1341,13 +1341,13 @@ ${c}`);
1341
1341
  const h = (d) => {
1342
1342
  var m;
1343
1343
  return d.default && d.tag !== "tag:yaml.org,2002:str" && ((m = d.test) == null ? void 0 : m.test(u));
1344
- }, { compat: p, tags: g } = e.doc.schema;
1345
- if (g.some(h) || p != null && p.some(h))
1344
+ }, { compat: p, tags: y } = e.doc.schema;
1345
+ if (y.some(h) || p != null && p.some(h))
1346
1346
  return he(r, e);
1347
1347
  }
1348
1348
  return a ? u : ut(u, c, ls, ft(e, !1));
1349
1349
  }
1350
- function xt(n, e, t, s) {
1350
+ function Ht(n, e, t, s) {
1351
1351
  const { implicitKey: i, inFlow: r } = e, o = typeof n.value == "string" ? n : Object.assign({}, n, { value: String(n.value) });
1352
1352
  let { type: a } = n;
1353
1353
  a !== v.QUOTE_DOUBLE && /[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value) && (a = v.QUOTE_DOUBLE);
@@ -1357,11 +1357,11 @@ function xt(n, e, t, s) {
1357
1357
  case v.BLOCK_LITERAL:
1358
1358
  return i || r ? he(o.value, e) : ze(o, e, t, s);
1359
1359
  case v.QUOTE_DOUBLE:
1360
- return Ce(o.value, e);
1360
+ return _e(o.value, e);
1361
1361
  case v.QUOTE_SINGLE:
1362
1362
  return Lt(o.value, e);
1363
1363
  case v.PLAIN:
1364
- return pr(o, e, t, s);
1364
+ return gr(o, e, t, s);
1365
1365
  default:
1366
1366
  return null;
1367
1367
  }
@@ -1377,7 +1377,7 @@ function xt(n, e, t, s) {
1377
1377
  function us(n, e) {
1378
1378
  const t = Object.assign({
1379
1379
  blockQuote: !0,
1380
- commentString: dr,
1380
+ commentString: pr,
1381
1381
  defaultKeyType: null,
1382
1382
  defaultStringType: "PLAIN",
1383
1383
  directives: null,
@@ -1416,7 +1416,7 @@ function us(n, e) {
1416
1416
  options: t
1417
1417
  };
1418
1418
  }
1419
- function mr(n, e) {
1419
+ function yr(n, e) {
1420
1420
  var i;
1421
1421
  if (e.tag) {
1422
1422
  const r = n.filter((o) => o.tag === e.tag);
@@ -1443,7 +1443,7 @@ function mr(n, e) {
1443
1443
  }
1444
1444
  return t;
1445
1445
  }
1446
- function gr(n, e, { anchors: t, doc: s }) {
1446
+ function wr(n, e, { anchors: t, doc: s }) {
1447
1447
  if (!s.directives)
1448
1448
  return "";
1449
1449
  const i = [], r = (O(n) || C(n)) && n.anchor;
@@ -1455,7 +1455,7 @@ function ye(n, e, t, s) {
1455
1455
  var c;
1456
1456
  if (L(n))
1457
1457
  return n.toString(e, t, s);
1458
- if (Se(n)) {
1458
+ if (Ee(n)) {
1459
1459
  if (e.doc.directives)
1460
1460
  return n.toString(e);
1461
1461
  if ((c = e.resolvedAliases) != null && c.has(n))
@@ -1464,14 +1464,14 @@ function ye(n, e, t, s) {
1464
1464
  }
1465
1465
  let i;
1466
1466
  const r = _(n) ? n : e.doc.createNode(n, { onTagObj: (l) => i = l });
1467
- i ?? (i = mr(e.doc.schema.tags, r));
1468
- const o = gr(r, i, e);
1467
+ i ?? (i = yr(e.doc.schema.tags, r));
1468
+ const o = wr(r, i, e);
1469
1469
  o.length > 0 && (e.indentAtStart = (e.indentAtStart ?? 0) + o.length + 1);
1470
- const a = typeof i.stringify == "function" ? i.stringify(r, e, t, s) : O(r) ? xt(r, e, t, s) : r.toString(e, t, s);
1470
+ const a = typeof i.stringify == "function" ? i.stringify(r, e, t, s) : O(r) ? Ht(r, e, t, s) : r.toString(e, t, s);
1471
1471
  return o ? O(r) || a[0] === "{" || a[0] === "[" ? `${o} ${a}` : `${o}
1472
1472
  ${e.indent}${a}` : a;
1473
1473
  }
1474
- function yr({ key: n, value: e }, t, s, i) {
1474
+ function br({ key: n, value: e }, t, s, i) {
1475
1475
  const { allNullValues: r, doc: o, indent: a, indentStep: c, options: { commentString: l, indentSeq: f, simpleKeys: u } } = t;
1476
1476
  let h = _(n) && n.comment || null;
1477
1477
  if (u) {
@@ -1488,7 +1488,7 @@ function yr({ key: n, value: e }, t, s, i) {
1488
1488
  implicitKey: !p && (u || !r),
1489
1489
  indent: a + c
1490
1490
  });
1491
- let g = !1, d = !1, m = ye(n, t, () => g = !0, () => d = !0);
1491
+ let y = !1, d = !1, m = ye(n, t, () => y = !0, () => d = !0);
1492
1492
  if (!p && !t.inFlow && m.length > 1024) {
1493
1493
  if (u)
1494
1494
  throw new Error("With simple keys, single line scalar must not span more than 1024 characters");
@@ -1496,27 +1496,27 @@ function yr({ key: n, value: e }, t, s, i) {
1496
1496
  }
1497
1497
  if (t.inFlow) {
1498
1498
  if (r || e == null)
1499
- return g && s && s(), m === "" ? "?" : p ? `? ${m}` : m;
1499
+ return y && s && s(), m === "" ? "?" : p ? `? ${m}` : m;
1500
1500
  } else if (r && !u || e == null && p)
1501
- return m = `? ${m}`, h && !g ? m += se(m, t.indent, l(h)) : d && i && i(), m;
1502
- g && (h = null), p ? (h && (m += se(m, t.indent, l(h))), m = `? ${m}
1501
+ return m = `? ${m}`, h && !y ? m += se(m, t.indent, l(h)) : d && i && i(), m;
1502
+ y && (h = null), p ? (h && (m += se(m, t.indent, l(h))), m = `? ${m}
1503
1503
  ${a}:`) : (m = `${m}:`, h && (m += se(m, t.indent, l(h))));
1504
1504
  let w, b, E;
1505
1505
  _(e) ? (w = !!e.spaceBefore, b = e.commentBefore, E = e.comment) : (w = !1, b = null, E = null, e && typeof e == "object" && (e = o.createNode(e))), t.implicitKey = !1, !p && !h && O(e) && (t.indentAtStart = m.length + 1), d = !1, !f && c.length >= 2 && !t.inFlow && !p && Be(e) && !e.flow && !e.tag && !e.anchor && (t.indent = t.indent.substring(2));
1506
1506
  let S = !1;
1507
1507
  const N = ye(e, t, () => S = !0, () => d = !0);
1508
- let A = " ";
1508
+ let $ = " ";
1509
1509
  if (h || w || b) {
1510
- if (A = w ? `
1510
+ if ($ = w ? `
1511
1511
  ` : "", b) {
1512
1512
  const I = l(b);
1513
- A += `
1513
+ $ += `
1514
1514
  ${J(I, t.indent)}`;
1515
1515
  }
1516
- N === "" && !t.inFlow ? A === `
1517
- ` && E && (A = `
1516
+ N === "" && !t.inFlow ? $ === `
1517
+ ` && E && ($ = `
1518
1518
 
1519
- `) : A += `
1519
+ `) : $ += `
1520
1520
  ${t.indent}`;
1521
1521
  } else if (!p && C(e)) {
1522
1522
  const I = N[0], k = N.indexOf(`
@@ -1527,26 +1527,26 @@ ${t.indent}`;
1527
1527
  let U = N.indexOf(" ");
1528
1528
  I === "&" && U !== -1 && U < k && N[U + 1] === "!" && (U = N.indexOf(" ", U + 1)), (U === -1 || k < U) && (V = !0);
1529
1529
  }
1530
- V || (A = `
1530
+ V || ($ = `
1531
1531
  ${t.indent}`);
1532
1532
  }
1533
1533
  } else (N === "" || N[0] === `
1534
- `) && (A = "");
1535
- return m += A + N, t.inFlow ? S && s && s() : E && !S ? m += se(m, t.indent, l(E)) : d && i && i(), m;
1534
+ `) && ($ = "");
1535
+ return m += $ + N, t.inFlow ? S && s && s() : E && !S ? m += se(m, t.indent, l(E)) : d && i && i(), m;
1536
1536
  }
1537
1537
  function fs(n, e) {
1538
1538
  (n === "debug" || n === "warn") && console.warn(e);
1539
1539
  }
1540
- const He = "<<", W = {
1541
- identify: (n) => n === He || typeof n == "symbol" && n.description === He,
1540
+ const xe = "<<", W = {
1541
+ identify: (n) => n === xe || typeof n == "symbol" && n.description === xe,
1542
1542
  default: "key",
1543
1543
  tag: "tag:yaml.org,2002:merge",
1544
1544
  test: /^<<$/,
1545
- resolve: () => Object.assign(new v(Symbol(He)), {
1545
+ resolve: () => Object.assign(new v(Symbol(xe)), {
1546
1546
  addToJSMap: ds
1547
1547
  }),
1548
- stringify: () => He
1549
- }, wr = (n, e) => (W.identify(e) || O(e) && (!e.type || e.type === v.PLAIN) && W.identify(e.value)) && (n == null ? void 0 : n.doc.schema.tags.some((t) => t.tag === W.tag && t.default));
1548
+ stringify: () => xe
1549
+ }, kr = (n, e) => (W.identify(e) || O(e) && (!e.type || e.type === v.PLAIN) && W.identify(e.value)) && (n == null ? void 0 : n.doc.schema.tags.some((t) => t.tag === W.tag && t.default));
1550
1550
  function ds(n, e, t) {
1551
1551
  const s = hs(n, t);
1552
1552
  if (Be(s))
@@ -1573,12 +1573,12 @@ function Et(n, e, t) {
1573
1573
  return e;
1574
1574
  }
1575
1575
  function hs(n, e) {
1576
- return n && Se(e) ? e.resolve(n.doc, n) : e;
1576
+ return n && Ee(e) ? e.resolve(n.doc, n) : e;
1577
1577
  }
1578
1578
  function ps(n, e, { key: t, value: s }) {
1579
1579
  if (_(t) && t.addToJSMap)
1580
1580
  t.addToJSMap(n, e, s);
1581
- else if (wr(n, t))
1581
+ else if (kr(n, t))
1582
1582
  ds(n, e, s);
1583
1583
  else {
1584
1584
  const i = F(t, "", n);
@@ -1587,7 +1587,7 @@ function ps(n, e, { key: t, value: s }) {
1587
1587
  else if (e instanceof Set)
1588
1588
  e.add(i);
1589
1589
  else {
1590
- const r = br(t, i, n), o = F(s, r, n);
1590
+ const r = Sr(t, i, n), o = F(s, r, n);
1591
1591
  r in e ? Object.defineProperty(e, r, {
1592
1592
  value: o,
1593
1593
  writable: !0,
@@ -1598,7 +1598,7 @@ function ps(n, e, { key: t, value: s }) {
1598
1598
  }
1599
1599
  return e;
1600
1600
  }
1601
- function br(n, e, t) {
1601
+ function Sr(n, e, t) {
1602
1602
  if (e === null)
1603
1603
  return "";
1604
1604
  if (typeof e != "object")
@@ -1618,8 +1618,8 @@ function br(n, e, t) {
1618
1618
  }
1619
1619
  return JSON.stringify(e);
1620
1620
  }
1621
- function Yt(n, e, t) {
1622
- const s = _e(n, void 0, t), i = _e(e, void 0, t);
1621
+ function Gt(n, e, t) {
1622
+ const s = Le(n, void 0, t), i = Le(e, void 0, t);
1623
1623
  return new M(s, i);
1624
1624
  }
1625
1625
  class M {
@@ -1635,18 +1635,18 @@ class M {
1635
1635
  return ps(t, s, this);
1636
1636
  }
1637
1637
  toString(e, t, s) {
1638
- return e != null && e.doc ? yr(this, e, t, s) : JSON.stringify(this);
1638
+ return e != null && e.doc ? br(this, e, t, s) : JSON.stringify(this);
1639
1639
  }
1640
1640
  }
1641
1641
  function ms(n, e, t) {
1642
- return (e.inFlow ?? n.flow ? Sr : kr)(n, e, t);
1642
+ return (e.inFlow ?? n.flow ? Nr : Er)(n, e, t);
1643
1643
  }
1644
- function kr({ comment: n, items: e }, t, { blockItemPrefix: s, flowChars: i, itemIndent: r, onChompKeep: o, onComment: a }) {
1644
+ function Er({ comment: n, items: e }, t, { blockItemPrefix: s, flowChars: i, itemIndent: r, onChompKeep: o, onComment: a }) {
1645
1645
  const { indent: c, options: { commentString: l } } = t, f = Object.assign({}, t, { indent: r, type: null });
1646
1646
  let u = !1;
1647
1647
  const h = [];
1648
- for (let g = 0; g < e.length; ++g) {
1649
- const d = e[g];
1648
+ for (let y = 0; y < e.length; ++y) {
1649
+ const d = e[y];
1650
1650
  let m = null;
1651
1651
  if (_(d))
1652
1652
  !u && d.spaceBefore && h.push(""), et(t, h, d.commentBefore, u), d.comment && (m = d.comment);
@@ -1663,8 +1663,8 @@ function kr({ comment: n, items: e }, t, { blockItemPrefix: s, flowChars: i, ite
1663
1663
  p = i.start + i.end;
1664
1664
  else {
1665
1665
  p = h[0];
1666
- for (let g = 1; g < h.length; ++g) {
1667
- const d = h[g];
1666
+ for (let y = 1; y < h.length; ++y) {
1667
+ const d = h[y];
1668
1668
  p += d ? `
1669
1669
  ${c}${d}` : `
1670
1670
  `;
@@ -1673,7 +1673,7 @@ ${c}${d}` : `
1673
1673
  return n ? (p += `
1674
1674
  ` + J(l(n), c), a && a()) : u && o && o(), p;
1675
1675
  }
1676
- function Sr({ items: n }, e, { flowChars: t, itemIndent: s }) {
1676
+ function Nr({ items: n }, e, { flowChars: t, itemIndent: s }) {
1677
1677
  const { indent: i, indentStep: r, flowCollectionPadding: o, options: { commentString: a } } = e;
1678
1678
  s += r;
1679
1679
  const c = Object.assign({}, e, {
@@ -1683,8 +1683,8 @@ function Sr({ items: n }, e, { flowChars: t, itemIndent: s }) {
1683
1683
  });
1684
1684
  let l = !1, f = 0;
1685
1685
  const u = [];
1686
- for (let g = 0; g < n.length; ++g) {
1687
- const d = n[g];
1686
+ for (let y = 0; y < n.length; ++y) {
1687
+ const d = n[y];
1688
1688
  let m = null;
1689
1689
  if (_(d))
1690
1690
  d.spaceBefore && u.push(""), et(e, u, d.commentBefore, !1), d.comment && (m = d.comment);
@@ -1697,22 +1697,22 @@ function Sr({ items: n }, e, { flowChars: t, itemIndent: s }) {
1697
1697
  m && (l = !0);
1698
1698
  let w = ye(d, c, () => m = null);
1699
1699
  l || (l = u.length > f || w.includes(`
1700
- `)), g < n.length - 1 ? w += "," : e.options.trailingComma && (e.options.lineWidth > 0 && (l || (l = u.reduce((b, E) => b + E.length + 2, 2) + (w.length + 2) > e.options.lineWidth)), l && (w += ",")), m && (w += se(w, s, a(m))), u.push(w), f = u.length;
1700
+ `)), y < n.length - 1 ? w += "," : e.options.trailingComma && (e.options.lineWidth > 0 && (l || (l = u.reduce((b, E) => b + E.length + 2, 2) + (w.length + 2) > e.options.lineWidth)), l && (w += ",")), m && (w += se(w, s, a(m))), u.push(w), f = u.length;
1701
1701
  }
1702
1702
  const { start: h, end: p } = t;
1703
1703
  if (u.length === 0)
1704
1704
  return h + p;
1705
1705
  if (!l) {
1706
- const g = u.reduce((d, m) => d + m.length + 2, 2);
1707
- l = e.options.lineWidth > 0 && g > e.options.lineWidth;
1706
+ const y = u.reduce((d, m) => d + m.length + 2, 2);
1707
+ l = e.options.lineWidth > 0 && y > e.options.lineWidth;
1708
1708
  }
1709
1709
  if (l) {
1710
- let g = h;
1710
+ let y = h;
1711
1711
  for (const d of u)
1712
- g += d ? `
1712
+ y += d ? `
1713
1713
  ${r}${i}${d}` : `
1714
1714
  `;
1715
- return `${g}
1715
+ return `${y}
1716
1716
  ${i}${p}`;
1717
1717
  } else
1718
1718
  return `${h}${o}${u.join(" ")}${o}${p}`;
@@ -1734,7 +1734,7 @@ class j extends cs {
1734
1734
  return "tag:yaml.org,2002:map";
1735
1735
  }
1736
1736
  constructor(e) {
1737
- super(X, e), this.items = [];
1737
+ super(Z, e), this.items = [];
1738
1738
  }
1739
1739
  /**
1740
1740
  * A generic collection parsing method that can be extended
@@ -1746,7 +1746,7 @@ class j extends cs {
1746
1746
  l = r.call(t, c, l);
1747
1747
  else if (Array.isArray(r) && !r.includes(c))
1748
1748
  return;
1749
- (l !== void 0 || i) && o.items.push(Yt(c, l, s));
1749
+ (l !== void 0 || i) && o.items.push(Gt(c, l, s));
1750
1750
  };
1751
1751
  if (t instanceof Map)
1752
1752
  for (const [c, l] of t)
@@ -1818,7 +1818,7 @@ class j extends cs {
1818
1818
  });
1819
1819
  }
1820
1820
  }
1821
- const Ne = {
1821
+ const ve = {
1822
1822
  collection: "map",
1823
1823
  default: !0,
1824
1824
  nodeClass: j,
@@ -1833,7 +1833,7 @@ class ae extends cs {
1833
1833
  return "tag:yaml.org,2002:seq";
1834
1834
  }
1835
1835
  constructor(e) {
1836
- super(ke, e), this.items = [];
1836
+ super(Se, e), this.items = [];
1837
1837
  }
1838
1838
  add(e) {
1839
1839
  this.items.push(e);
@@ -1847,11 +1847,11 @@ class ae extends cs {
1847
1847
  * @returns `true` if the item was found and removed.
1848
1848
  */
1849
1849
  delete(e) {
1850
- const t = xe(e);
1850
+ const t = He(e);
1851
1851
  return typeof t != "number" ? !1 : this.items.splice(t, 1).length > 0;
1852
1852
  }
1853
1853
  get(e, t) {
1854
- const s = xe(e);
1854
+ const s = He(e);
1855
1855
  if (typeof s != "number")
1856
1856
  return;
1857
1857
  const i = this.items[s];
@@ -1864,7 +1864,7 @@ class ae extends cs {
1864
1864
  * It may be wrapped in a `Scalar`.
1865
1865
  */
1866
1866
  has(e) {
1867
- const t = xe(e);
1867
+ const t = He(e);
1868
1868
  return typeof t == "number" && t < this.items.length;
1869
1869
  }
1870
1870
  /**
@@ -1875,7 +1875,7 @@ class ae extends cs {
1875
1875
  * It may be wrapped in a `Scalar`.
1876
1876
  */
1877
1877
  set(e, t) {
1878
- const s = xe(e);
1878
+ const s = He(e);
1879
1879
  if (typeof s != "number")
1880
1880
  throw new Error(`Expected a valid index, not ${e}.`);
1881
1881
  const i = this.items[s];
@@ -1907,17 +1907,17 @@ class ae extends cs {
1907
1907
  const c = t instanceof Set ? a : String(o++);
1908
1908
  a = i.call(t, c, a);
1909
1909
  }
1910
- r.items.push(_e(a, void 0, s));
1910
+ r.items.push(Le(a, void 0, s));
1911
1911
  }
1912
1912
  }
1913
1913
  return r;
1914
1914
  }
1915
1915
  }
1916
- function xe(n) {
1916
+ function He(n) {
1917
1917
  let e = O(n) ? n.value : n;
1918
1918
  return e && typeof e == "string" && (e = Number(e)), typeof e == "number" && Number.isInteger(e) && e >= 0 ? e : null;
1919
1919
  }
1920
- const ve = {
1920
+ const Ie = {
1921
1921
  collection: "seq",
1922
1922
  default: !0,
1923
1923
  nodeClass: ae,
@@ -1932,7 +1932,7 @@ const ve = {
1932
1932
  tag: "tag:yaml.org,2002:str",
1933
1933
  resolve: (n) => n,
1934
1934
  stringify(n, e, t, s) {
1935
- return e = Object.assign({ actualString: !0 }, e), xt(n, e, t, s);
1935
+ return e = Object.assign({ actualString: !0 }, e), Ht(n, e, t, s);
1936
1936
  }
1937
1937
  }, pt = {
1938
1938
  identify: (n) => n == null,
@@ -1942,14 +1942,14 @@ const ve = {
1942
1942
  test: /^(?:~|[Nn]ull|NULL)?$/,
1943
1943
  resolve: () => new v(null),
1944
1944
  stringify: ({ source: n }, e) => typeof n == "string" && pt.test.test(n) ? n : e.options.nullStr
1945
- }, Gt = {
1945
+ }, Yt = {
1946
1946
  identify: (n) => typeof n == "boolean",
1947
1947
  default: !0,
1948
1948
  tag: "tag:yaml.org,2002:bool",
1949
1949
  test: /^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,
1950
1950
  resolve: (n) => new v(n[0] === "t" || n[0] === "T"),
1951
1951
  stringify({ source: n, value: e }, t) {
1952
- if (n && Gt.test.test(n)) {
1952
+ if (n && Yt.test.test(n)) {
1953
1953
  const s = n[0] === "t" || n[0] === "T";
1954
1954
  if (e === s)
1955
1955
  return n;
@@ -1957,7 +1957,7 @@ const ve = {
1957
1957
  return e ? t.options.trueStr : t.options.falseStr;
1958
1958
  }
1959
1959
  };
1960
- function Y({ format: n, minFractionDigits: e, tag: t, value: s }) {
1960
+ function G({ format: n, minFractionDigits: e, tag: t, value: s }) {
1961
1961
  if (typeof s == "bigint")
1962
1962
  return String(s);
1963
1963
  const i = typeof s == "number" ? s : Number(s);
@@ -1979,7 +1979,7 @@ const gs = {
1979
1979
  tag: "tag:yaml.org,2002:float",
1980
1980
  test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,
1981
1981
  resolve: (n) => n.slice(-3).toLowerCase() === "nan" ? NaN : n[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY,
1982
- stringify: Y
1982
+ stringify: G
1983
1983
  }, ys = {
1984
1984
  identify: (n) => typeof n == "number",
1985
1985
  default: !0,
@@ -1989,7 +1989,7 @@ const gs = {
1989
1989
  resolve: (n) => parseFloat(n),
1990
1990
  stringify(n) {
1991
1991
  const e = Number(n.value);
1992
- return isFinite(e) ? e.toExponential() : Y(n);
1992
+ return isFinite(e) ? e.toExponential() : G(n);
1993
1993
  }
1994
1994
  }, ws = {
1995
1995
  identify: (n) => typeof n == "number",
@@ -2000,11 +2000,11 @@ const gs = {
2000
2000
  const e = new v(parseFloat(n)), t = n.indexOf(".");
2001
2001
  return t !== -1 && n[n.length - 1] === "0" && (e.minFractionDigits = n.length - t - 1), e;
2002
2002
  },
2003
- stringify: Y
2003
+ stringify: G
2004
2004
  }, mt = (n) => typeof n == "bigint" || Number.isInteger(n), Vt = (n, e, t, { intAsBigInt: s }) => s ? BigInt(n) : parseInt(n.substring(e), t);
2005
2005
  function bs(n, e, t) {
2006
2006
  const { value: s } = n;
2007
- return mt(s) && s >= 0 ? t + s.toString(e) : Y(n);
2007
+ return mt(s) && s >= 0 ? t + s.toString(e) : G(n);
2008
2008
  }
2009
2009
  const ks = {
2010
2010
  identify: (n) => mt(n) && n >= 0,
@@ -2020,7 +2020,7 @@ const ks = {
2020
2020
  tag: "tag:yaml.org,2002:int",
2021
2021
  test: /^[-+]?[0-9]+$/,
2022
2022
  resolve: (n, e, t) => Vt(n, 0, 10, t),
2023
- stringify: Y
2023
+ stringify: G
2024
2024
  }, Es = {
2025
2025
  identify: (n) => mt(n) && n >= 0,
2026
2026
  default: !0,
@@ -2029,12 +2029,12 @@ const ks = {
2029
2029
  test: /^0x[0-9a-fA-F]+$/,
2030
2030
  resolve: (n, e, t) => Vt(n, 2, 16, t),
2031
2031
  stringify: (n) => bs(n, 16, "0x")
2032
- }, Er = [
2033
- Ne,
2032
+ }, vr = [
2034
2033
  ve,
2034
+ Ie,
2035
2035
  ht,
2036
2036
  pt,
2037
- Gt,
2037
+ Yt,
2038
2038
  ks,
2039
2039
  Ss,
2040
2040
  Es,
@@ -2045,13 +2045,13 @@ const ks = {
2045
2045
  function En(n) {
2046
2046
  return typeof n == "bigint" || Number.isInteger(n);
2047
2047
  }
2048
- const Ye = ({ value: n }) => JSON.stringify(n), Nr = [
2048
+ const Ge = ({ value: n }) => JSON.stringify(n), Ir = [
2049
2049
  {
2050
2050
  identify: (n) => typeof n == "string",
2051
2051
  default: !0,
2052
2052
  tag: "tag:yaml.org,2002:str",
2053
2053
  resolve: (n) => n,
2054
- stringify: Ye
2054
+ stringify: Ge
2055
2055
  },
2056
2056
  {
2057
2057
  identify: (n) => n == null,
@@ -2060,7 +2060,7 @@ const Ye = ({ value: n }) => JSON.stringify(n), Nr = [
2060
2060
  tag: "tag:yaml.org,2002:null",
2061
2061
  test: /^null$/,
2062
2062
  resolve: () => null,
2063
- stringify: Ye
2063
+ stringify: Ge
2064
2064
  },
2065
2065
  {
2066
2066
  identify: (n) => typeof n == "boolean",
@@ -2068,7 +2068,7 @@ const Ye = ({ value: n }) => JSON.stringify(n), Nr = [
2068
2068
  tag: "tag:yaml.org,2002:bool",
2069
2069
  test: /^true$|^false$/,
2070
2070
  resolve: (n) => n === "true",
2071
- stringify: Ye
2071
+ stringify: Ge
2072
2072
  },
2073
2073
  {
2074
2074
  identify: En,
@@ -2084,16 +2084,16 @@ const Ye = ({ value: n }) => JSON.stringify(n), Nr = [
2084
2084
  tag: "tag:yaml.org,2002:float",
2085
2085
  test: /^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,
2086
2086
  resolve: (n) => parseFloat(n),
2087
- stringify: Ye
2087
+ stringify: Ge
2088
2088
  }
2089
- ], vr = {
2089
+ ], Ar = {
2090
2090
  default: !0,
2091
2091
  tag: "",
2092
2092
  test: /^/,
2093
2093
  resolve(n, e) {
2094
2094
  return e(`Unresolved plain scalar ${JSON.stringify(n)}`), n;
2095
2095
  }
2096
- }, Ir = [Ne, ve].concat(Nr, vr), Jt = {
2096
+ }, $r = [ve, Ie].concat(Ir, Ar), Jt = {
2097
2097
  identify: (n) => n instanceof Uint8Array,
2098
2098
  // Buffer inherits from Uint8Array
2099
2099
  default: !1,
@@ -2134,7 +2134,7 @@ const Ye = ({ value: n }) => JSON.stringify(n), Nr = [
2134
2134
  a = f.join(e === v.BLOCK_LITERAL ? `
2135
2135
  ` : " ");
2136
2136
  }
2137
- return xt({ comment: n, type: e, value: a }, s, i, r);
2137
+ return Ht({ comment: n, type: e, value: a }, s, i, r);
2138
2138
  }
2139
2139
  };
2140
2140
  function Ns(n, e) {
@@ -2181,7 +2181,7 @@ function vs(n, e, t) {
2181
2181
  throw new TypeError(`Expected tuple with one key, not ${l.length} keys`);
2182
2182
  } else
2183
2183
  a = o;
2184
- i.items.push(Yt(a, c, t));
2184
+ i.items.push(Gt(a, c, t));
2185
2185
  }
2186
2186
  return i;
2187
2187
  }
@@ -2234,30 +2234,30 @@ const zt = {
2234
2234
  createNode: (n, e, t) => pe.from(n, e, t)
2235
2235
  };
2236
2236
  function Is({ value: n, source: e }, t) {
2237
- return e && (n ? $s : As).test.test(e) ? e : n ? t.options.trueStr : t.options.falseStr;
2237
+ return e && (n ? As : $s).test.test(e) ? e : n ? t.options.trueStr : t.options.falseStr;
2238
2238
  }
2239
- const $s = {
2239
+ const As = {
2240
2240
  identify: (n) => n === !0,
2241
2241
  default: !0,
2242
2242
  tag: "tag:yaml.org,2002:bool",
2243
2243
  test: /^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,
2244
2244
  resolve: () => new v(!0),
2245
2245
  stringify: Is
2246
- }, As = {
2246
+ }, $s = {
2247
2247
  identify: (n) => n === !1,
2248
2248
  default: !0,
2249
2249
  tag: "tag:yaml.org,2002:bool",
2250
2250
  test: /^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,
2251
2251
  resolve: () => new v(!1),
2252
2252
  stringify: Is
2253
- }, $r = {
2253
+ }, Tr = {
2254
2254
  identify: (n) => typeof n == "number",
2255
2255
  default: !0,
2256
2256
  tag: "tag:yaml.org,2002:float",
2257
2257
  test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,
2258
2258
  resolve: (n) => n.slice(-3).toLowerCase() === "nan" ? NaN : n[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY,
2259
- stringify: Y
2260
- }, Ar = {
2259
+ stringify: G
2260
+ }, Or = {
2261
2261
  identify: (n) => typeof n == "number",
2262
2262
  default: !0,
2263
2263
  tag: "tag:yaml.org,2002:float",
@@ -2266,9 +2266,9 @@ const $s = {
2266
2266
  resolve: (n) => parseFloat(n.replace(/_/g, "")),
2267
2267
  stringify(n) {
2268
2268
  const e = Number(n.value);
2269
- return isFinite(e) ? e.toExponential() : Y(n);
2269
+ return isFinite(e) ? e.toExponential() : G(n);
2270
2270
  }
2271
- }, Tr = {
2271
+ }, Cr = {
2272
2272
  identify: (n) => typeof n == "number",
2273
2273
  default: !0,
2274
2274
  tag: "tag:yaml.org,2002:float",
@@ -2281,7 +2281,7 @@ const $s = {
2281
2281
  }
2282
2282
  return e;
2283
2283
  },
2284
- stringify: Y
2284
+ stringify: G
2285
2285
  }, Fe = (n) => typeof n == "bigint" || Number.isInteger(n);
2286
2286
  function gt(n, e, t, { intAsBigInt: s }) {
2287
2287
  const i = n[0];
@@ -2309,9 +2309,9 @@ function Qt(n, e, t) {
2309
2309
  const i = s.toString(e);
2310
2310
  return s < 0 ? "-" + t + i.substr(1) : t + i;
2311
2311
  }
2312
- return Y(n);
2312
+ return G(n);
2313
2313
  }
2314
- const Or = {
2314
+ const _r = {
2315
2315
  identify: Fe,
2316
2316
  default: !0,
2317
2317
  tag: "tag:yaml.org,2002:int",
@@ -2319,7 +2319,7 @@ const Or = {
2319
2319
  test: /^[-+]?0b[0-1_]+$/,
2320
2320
  resolve: (n, e, t) => gt(n, 2, 2, t),
2321
2321
  stringify: (n) => Qt(n, 2, "0b")
2322
- }, Cr = {
2322
+ }, Lr = {
2323
2323
  identify: Fe,
2324
2324
  default: !0,
2325
2325
  tag: "tag:yaml.org,2002:int",
@@ -2327,14 +2327,14 @@ const Or = {
2327
2327
  test: /^[-+]?0[0-7_]+$/,
2328
2328
  resolve: (n, e, t) => gt(n, 1, 8, t),
2329
2329
  stringify: (n) => Qt(n, 8, "0")
2330
- }, _r = {
2330
+ }, Rr = {
2331
2331
  identify: Fe,
2332
2332
  default: !0,
2333
2333
  tag: "tag:yaml.org,2002:int",
2334
2334
  test: /^[-+]?[0-9][0-9_]*$/,
2335
2335
  resolve: (n, e, t) => gt(n, 0, 10, t),
2336
- stringify: Y
2337
- }, Lr = {
2336
+ stringify: G
2337
+ }, Pr = {
2338
2338
  identify: Fe,
2339
2339
  default: !0,
2340
2340
  tag: "tag:yaml.org,2002:int",
@@ -2379,7 +2379,7 @@ class me extends j {
2379
2379
  const { replacer: i } = s, r = new this(e);
2380
2380
  if (t && Symbol.iterator in Object(t))
2381
2381
  for (let o of t)
2382
- typeof i == "function" && (o = i.call(t, o, o)), r.items.push(Yt(o, null, s));
2382
+ typeof i == "function" && (o = i.call(t, o, o)), r.items.push(Gt(o, null, s));
2383
2383
  return r;
2384
2384
  }
2385
2385
  }
@@ -2410,7 +2410,7 @@ function Ts(n) {
2410
2410
  if (typeof e == "bigint")
2411
2411
  t = (o) => BigInt(o);
2412
2412
  else if (isNaN(e) || !isFinite(e))
2413
- return Y(n);
2413
+ return G(n);
2414
2414
  let s = "";
2415
2415
  e < 0 && (s = "-", e *= t(-1));
2416
2416
  const i = t(60), r = [e % i];
@@ -2455,19 +2455,19 @@ const Os = {
2455
2455
  },
2456
2456
  stringify: ({ value: n }) => (n == null ? void 0 : n.toISOString().replace(/(T00:00:00)?\.000Z$/, "")) ?? ""
2457
2457
  }, Nn = [
2458
- Ne,
2459
2458
  ve,
2459
+ Ie,
2460
2460
  ht,
2461
2461
  pt,
2462
- $s,
2463
2462
  As,
2464
- Or,
2465
- Cr,
2463
+ $s,
2466
2464
  _r,
2467
2465
  Lr,
2468
- $r,
2469
- Ar,
2466
+ Rr,
2467
+ Pr,
2470
2468
  Tr,
2469
+ Or,
2470
+ Cr,
2471
2471
  Jt,
2472
2472
  W,
2473
2473
  zt,
@@ -2477,14 +2477,14 @@ const Os = {
2477
2477
  Cs,
2478
2478
  yt
2479
2479
  ], vn = /* @__PURE__ */ new Map([
2480
- ["core", Er],
2481
- ["failsafe", [Ne, ve, ht]],
2482
- ["json", Ir],
2480
+ ["core", vr],
2481
+ ["failsafe", [ve, Ie, ht]],
2482
+ ["json", $r],
2483
2483
  ["yaml11", Nn],
2484
2484
  ["yaml-1.1", Nn]
2485
2485
  ]), In = {
2486
2486
  binary: Jt,
2487
- bool: Gt,
2487
+ bool: Yt,
2488
2488
  float: ws,
2489
2489
  floatExp: ys,
2490
2490
  floatNaN: gs,
@@ -2493,15 +2493,15 @@ const Os = {
2493
2493
  intHex: Es,
2494
2494
  intOct: ks,
2495
2495
  intTime: Os,
2496
- map: Ne,
2496
+ map: ve,
2497
2497
  merge: W,
2498
2498
  null: pt,
2499
2499
  omap: zt,
2500
2500
  pairs: Wt,
2501
- seq: ve,
2501
+ seq: Ie,
2502
2502
  set: Xt,
2503
2503
  timestamp: yt
2504
- }, Rr = {
2504
+ }, Mr = {
2505
2505
  "tag:yaml.org,2002:binary": Jt,
2506
2506
  "tag:yaml.org,2002:merge": W,
2507
2507
  "tag:yaml.org,2002:omap": zt,
@@ -2534,17 +2534,17 @@ function Nt(n, e, t) {
2534
2534
  return r.includes(a) || r.push(a), r;
2535
2535
  }, []);
2536
2536
  }
2537
- const Pr = (n, e) => n.key < e.key ? -1 : n.key > e.key ? 1 : 0;
2537
+ const Dr = (n, e) => n.key < e.key ? -1 : n.key > e.key ? 1 : 0;
2538
2538
  class en {
2539
2539
  constructor({ compat: e, customTags: t, merge: s, resolveKnownTags: i, schema: r, sortMapEntries: o, toStringDefaults: a }) {
2540
- this.compat = Array.isArray(e) ? Nt(e, "compat") : e ? Nt(null, e) : null, this.name = typeof r == "string" && r || "core", this.knownTags = i ? Rr : {}, this.tags = Nt(t, this.name, s), this.toStringOptions = a ?? null, Object.defineProperty(this, X, { value: Ne }), Object.defineProperty(this, G, { value: ht }), Object.defineProperty(this, ke, { value: ve }), this.sortMapEntries = typeof o == "function" ? o : o === !0 ? Pr : null;
2540
+ this.compat = Array.isArray(e) ? Nt(e, "compat") : e ? Nt(null, e) : null, this.name = typeof r == "string" && r || "core", this.knownTags = i ? Mr : {}, this.tags = Nt(t, this.name, s), this.toStringOptions = a ?? null, Object.defineProperty(this, Z, { value: ve }), Object.defineProperty(this, Y, { value: ht }), Object.defineProperty(this, Se, { value: Ie }), this.sortMapEntries = typeof o == "function" ? o : o === !0 ? Dr : null;
2541
2541
  }
2542
2542
  clone() {
2543
2543
  const e = Object.create(en.prototype, Object.getOwnPropertyDescriptors(this));
2544
2544
  return e.tags = this.tags.slice(), e;
2545
2545
  }
2546
2546
  }
2547
- function Mr(n, e) {
2547
+ function jr(n, e) {
2548
2548
  var c;
2549
2549
  const t = [];
2550
2550
  let s = e.directives === !0;
@@ -2641,7 +2641,7 @@ class Ke {
2641
2641
  e.anchor = // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
2642
2642
  !t || s.has(t) ? os(t || "a", s) : t;
2643
2643
  }
2644
- return new Ht(e.anchor);
2644
+ return new xt(e.anchor);
2645
2645
  }
2646
2646
  createNode(e, t, s) {
2647
2647
  let i;
@@ -2651,11 +2651,11 @@ class Ke {
2651
2651
  const m = (b) => typeof b == "number" || b instanceof String || b instanceof Number, w = t.filter(m).map(String);
2652
2652
  w.length > 0 && (t = t.concat(w)), i = t;
2653
2653
  } else s === void 0 && t && (s = t, t = void 0);
2654
- const { aliasDuplicateObjects: r, anchorPrefix: o, flow: a, keepUndefined: c, onTagObj: l, tag: f } = s ?? {}, { onAnchor: u, setAnchors: h, sourceObjects: p } = lr(
2654
+ const { aliasDuplicateObjects: r, anchorPrefix: o, flow: a, keepUndefined: c, onTagObj: l, tag: f } = s ?? {}, { onAnchor: u, setAnchors: h, sourceObjects: p } = fr(
2655
2655
  this,
2656
2656
  // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
2657
2657
  o || "a"
2658
- ), g = {
2658
+ ), y = {
2659
2659
  aliasDuplicateObjects: r ?? !0,
2660
2660
  keepUndefined: c ?? !1,
2661
2661
  onAnchor: u,
@@ -2663,7 +2663,7 @@ class Ke {
2663
2663
  replacer: i,
2664
2664
  schema: this.schema,
2665
2665
  sourceObjects: p
2666
- }, d = _e(e, f, g);
2666
+ }, d = Le(e, f, y);
2667
2667
  return a && C(d) && (d.flow = !0), h(), d;
2668
2668
  }
2669
2669
  /**
@@ -2686,7 +2686,7 @@ class Ke {
2686
2686
  * @returns `true` if the item was found and removed.
2687
2687
  */
2688
2688
  deleteIn(e) {
2689
- return Ae(e) ? this.contents == null ? !1 : (this.contents = null, !0) : le(this.contents) ? this.contents.deleteIn(e) : !1;
2689
+ return Te(e) ? this.contents == null ? !1 : (this.contents = null, !0) : le(this.contents) ? this.contents.deleteIn(e) : !1;
2690
2690
  }
2691
2691
  /**
2692
2692
  * Returns item at `key`, or `undefined` if not found. By default unwraps
@@ -2702,7 +2702,7 @@ class Ke {
2702
2702
  * `true` (collections are always returned intact).
2703
2703
  */
2704
2704
  getIn(e, t) {
2705
- return Ae(e) ? !t && O(this.contents) ? this.contents.value : this.contents : C(this.contents) ? this.contents.getIn(e, t) : void 0;
2705
+ return Te(e) ? !t && O(this.contents) ? this.contents.value : this.contents : C(this.contents) ? this.contents.getIn(e, t) : void 0;
2706
2706
  }
2707
2707
  /**
2708
2708
  * Checks if the document includes a value with the key `key`.
@@ -2714,7 +2714,7 @@ class Ke {
2714
2714
  * Checks if the document includes a value at `path`.
2715
2715
  */
2716
2716
  hasIn(e) {
2717
- return Ae(e) ? this.contents !== void 0 : C(this.contents) ? this.contents.hasIn(e) : !1;
2717
+ return Te(e) ? this.contents !== void 0 : C(this.contents) ? this.contents.hasIn(e) : !1;
2718
2718
  }
2719
2719
  /**
2720
2720
  * Sets a value in this document. For `!!set`, `value` needs to be a
@@ -2728,7 +2728,7 @@ class Ke {
2728
2728
  * boolean to add/remove the item from the set.
2729
2729
  */
2730
2730
  setIn(e, t) {
2731
- Ae(e) ? this.contents = t : this.contents == null ? this.contents = Ze(this.schema, Array.from(e), t) : le(this.contents) && this.contents.setIn(e, t);
2731
+ Te(e) ? this.contents = t : this.contents == null ? this.contents = Ze(this.schema, Array.from(e), t) : le(this.contents) && this.contents.setIn(e, t);
2732
2732
  }
2733
2733
  /**
2734
2734
  * Change the YAML version and schema used by the document.
@@ -2795,7 +2795,7 @@ class Ke {
2795
2795
  const t = JSON.stringify(e.indent);
2796
2796
  throw new Error(`"indent" option must be a positive integer, not ${t}`);
2797
2797
  }
2798
- return Mr(this, e);
2798
+ return jr(this, e);
2799
2799
  }
2800
2800
  }
2801
2801
  function le(n) {
@@ -2808,17 +2808,17 @@ class _s extends Error {
2808
2808
  super(), this.name = e, this.code = s, this.message = i, this.pos = t;
2809
2809
  }
2810
2810
  }
2811
- class Te extends _s {
2811
+ class Oe extends _s {
2812
2812
  constructor(e, t, s) {
2813
2813
  super("YAMLParseError", e, t, s);
2814
2814
  }
2815
2815
  }
2816
- class Dr extends _s {
2816
+ class Br extends _s {
2817
2817
  constructor(e, t, s) {
2818
2818
  super("YAMLWarning", e, t, s);
2819
2819
  }
2820
2820
  }
2821
- const $n = (n, e) => (t) => {
2821
+ const An = (n, e) => (t) => {
2822
2822
  if (t.pos[0] === -1)
2823
2823
  return;
2824
2824
  t.linePos = t.pos.map((a) => e.linePos(a));
@@ -2847,9 +2847,9 @@ ${l}
2847
2847
  }
2848
2848
  };
2849
2849
  function we(n, { flow: e, indicator: t, next: s, offset: i, onError: r, parentIndent: o, startOnNewline: a }) {
2850
- let c = !1, l = a, f = a, u = "", h = "", p = !1, g = !1, d = null, m = null, w = null, b = null, E = null, S = null, N = null;
2850
+ let c = !1, l = a, f = a, u = "", h = "", p = !1, y = !1, d = null, m = null, w = null, b = null, E = null, S = null, N = null;
2851
2851
  for (const k of n)
2852
- switch (g && (k.type !== "space" && k.type !== "newline" && k.type !== "comma" && r(k.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), g = !1), d && (l && k.type !== "comment" && k.type !== "newline" && r(d, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), d = null), k.type) {
2852
+ switch (y && (k.type !== "space" && k.type !== "newline" && k.type !== "comma" && r(k.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), y = !1), d && (l && k.type !== "comment" && k.type !== "newline" && r(d, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), d = null), k.type) {
2853
2853
  case "space":
2854
2854
  !e && (t !== "doc-start" || (s == null ? void 0 : s.type) !== "flow-collection") && k.source.includes(" ") && (d = k), f = !0;
2855
2855
  break;
@@ -2863,10 +2863,10 @@ function we(n, { flow: e, indicator: t, next: s, offset: i, onError: r, parentIn
2863
2863
  l ? u ? u += k.source : (!S || t !== "seq-item-ind") && (c = !0) : h += k.source, l = !0, p = !0, (m || w) && (b = k), f = !0;
2864
2864
  break;
2865
2865
  case "anchor":
2866
- m && r(k, "MULTIPLE_ANCHORS", "A node can have at most one anchor"), k.source.endsWith(":") && r(k.offset + k.source.length - 1, "BAD_ALIAS", "Anchor ending in : is ambiguous", !0), m = k, N ?? (N = k.offset), l = !1, f = !1, g = !0;
2866
+ m && r(k, "MULTIPLE_ANCHORS", "A node can have at most one anchor"), k.source.endsWith(":") && r(k.offset + k.source.length - 1, "BAD_ALIAS", "Anchor ending in : is ambiguous", !0), m = k, N ?? (N = k.offset), l = !1, f = !1, y = !0;
2867
2867
  break;
2868
2868
  case "tag": {
2869
- w && r(k, "MULTIPLE_TAGS", "A node can have at most one tag"), w = k, N ?? (N = k.offset), l = !1, f = !1, g = !0;
2869
+ w && r(k, "MULTIPLE_TAGS", "A node can have at most one tag"), w = k, N ?? (N = k.offset), l = !1, f = !1, y = !0;
2870
2870
  break;
2871
2871
  }
2872
2872
  case t:
@@ -2880,8 +2880,8 @@ function we(n, { flow: e, indicator: t, next: s, offset: i, onError: r, parentIn
2880
2880
  default:
2881
2881
  r(k, "UNEXPECTED_TOKEN", `Unexpected ${k.type} token`), l = !1, f = !1;
2882
2882
  }
2883
- const A = n[n.length - 1], I = A ? A.offset + A.source.length : i;
2884
- return g && s && s.type !== "space" && s.type !== "newline" && s.type !== "comma" && (s.type !== "scalar" || s.source !== "") && r(s.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), d && (l && d.indent <= o || (s == null ? void 0 : s.type) === "block-map" || (s == null ? void 0 : s.type) === "block-seq") && r(d, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), {
2883
+ const $ = n[n.length - 1], I = $ ? $.offset + $.source.length : i;
2884
+ return y && s && s.type !== "space" && s.type !== "newline" && s.type !== "comma" && (s.type !== "scalar" || s.source !== "") && r(s.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), d && (l && d.indent <= o || (s == null ? void 0 : s.type) === "block-map" || (s == null ? void 0 : s.type) === "block-seq") && r(d, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), {
2885
2885
  comma: E,
2886
2886
  found: S,
2887
2887
  spaceBefore: c,
@@ -2894,7 +2894,7 @@ function we(n, { flow: e, indicator: t, next: s, offset: i, onError: r, parentIn
2894
2894
  start: N ?? I
2895
2895
  };
2896
2896
  }
2897
- function Le(n) {
2897
+ function Re(n) {
2898
2898
  if (!n)
2899
2899
  return null;
2900
2900
  switch (n.type) {
@@ -2921,7 +2921,7 @@ function Le(n) {
2921
2921
  if (t.type === "newline")
2922
2922
  return !0;
2923
2923
  }
2924
- if (Le(e.key) || Le(e.value))
2924
+ if (Re(e.key) || Re(e.value))
2925
2925
  return !0;
2926
2926
  }
2927
2927
  return !1;
@@ -2932,7 +2932,7 @@ function Le(n) {
2932
2932
  function Pt(n, e, t) {
2933
2933
  if ((e == null ? void 0 : e.type) === "flow-collection") {
2934
2934
  const s = e.end[0];
2935
- s.indent === n && (s.source === "]" || s.source === "}") && Le(e) && t(s, "BAD_INDENT", "Flow end indicator should be more indented than parent", !0);
2935
+ s.indent === n && (s.source === "]" || s.source === "}") && Re(e) && t(s, "BAD_INDENT", "Flow end indicator should be more indented than parent", !0);
2936
2936
  }
2937
2937
  }
2938
2938
  function Ls(n, e, t) {
@@ -2942,33 +2942,33 @@ function Ls(n, e, t) {
2942
2942
  const i = typeof s == "function" ? s : (r, o) => r === o || O(r) && O(o) && r.value === o.value;
2943
2943
  return e.some((r) => i(r.key, t));
2944
2944
  }
2945
- const An = "All mapping items must start at the same column";
2946
- function jr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
2945
+ const $n = "All mapping items must start at the same column";
2946
+ function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
2947
2947
  var f;
2948
2948
  const o = (r == null ? void 0 : r.nodeClass) ?? j, a = new o(t.schema);
2949
2949
  t.atRoot && (t.atRoot = !1);
2950
2950
  let c = s.offset, l = null;
2951
2951
  for (const u of s.items) {
2952
- const { start: h, key: p, sep: g, value: d } = u, m = we(h, {
2952
+ const { start: h, key: p, sep: y, value: d } = u, m = we(h, {
2953
2953
  indicator: "explicit-key-ind",
2954
- next: p ?? (g == null ? void 0 : g[0]),
2954
+ next: p ?? (y == null ? void 0 : y[0]),
2955
2955
  offset: c,
2956
2956
  onError: i,
2957
2957
  parentIndent: s.indent,
2958
2958
  startOnNewline: !0
2959
2959
  }), w = !m.found;
2960
2960
  if (w) {
2961
- if (p && (p.type === "block-seq" ? i(c, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key") : "indent" in p && p.indent !== s.indent && i(c, "BAD_INDENT", An)), !m.anchor && !m.tag && !g) {
2961
+ if (p && (p.type === "block-seq" ? i(c, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key") : "indent" in p && p.indent !== s.indent && i(c, "BAD_INDENT", $n)), !m.anchor && !m.tag && !y) {
2962
2962
  l = m.end, m.comment && (a.comment ? a.comment += `
2963
2963
  ` + m.comment : a.comment = m.comment);
2964
2964
  continue;
2965
2965
  }
2966
- (m.newlineAfterProp || Le(p)) && i(p ?? h[h.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line");
2967
- } else ((f = m.found) == null ? void 0 : f.indent) !== s.indent && i(c, "BAD_INDENT", An);
2966
+ (m.newlineAfterProp || Re(p)) && i(p ?? h[h.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line");
2967
+ } else ((f = m.found) == null ? void 0 : f.indent) !== s.indent && i(c, "BAD_INDENT", $n);
2968
2968
  t.atKey = !0;
2969
2969
  const b = m.end, E = p ? n(t, p, m, i) : e(t, b, h, null, m, i);
2970
2970
  t.schema.compat && Pt(s.indent, p, i), t.atKey = !1, Ls(t, a.items, E) && i(b, "DUPLICATE_KEY", "Map keys must be unique");
2971
- const S = we(g ?? [], {
2971
+ const S = we(y ?? [], {
2972
2972
  indicator: "map-value-ind",
2973
2973
  next: d,
2974
2974
  offset: E.range[2],
@@ -2978,10 +2978,10 @@ function jr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
2978
2978
  });
2979
2979
  if (c = S.end, S.found) {
2980
2980
  w && ((d == null ? void 0 : d.type) === "block-map" && !S.hasNewline && i(c, "BLOCK_AS_IMPLICIT_KEY", "Nested mappings are not allowed in compact mappings"), t.options.strict && m.start < S.found.offset - 1024 && i(E.range, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));
2981
- const N = d ? n(t, d, S, i) : e(t, c, g, null, S, i);
2981
+ const N = d ? n(t, d, S, i) : e(t, c, y, null, S, i);
2982
2982
  t.schema.compat && Pt(s.indent, d, i), c = N.range[2];
2983
- const A = new M(E, N);
2984
- t.options.keepSourceTokens && (A.srcToken = u), a.items.push(A);
2983
+ const $ = new M(E, N);
2984
+ t.options.keepSourceTokens && ($.srcToken = u), a.items.push($);
2985
2985
  } else {
2986
2986
  w && i(E.range, "MISSING_CHAR", "Implicit map keys need to be followed by map values"), S.comment && (E.comment ? E.comment += `
2987
2987
  ` + S.comment : E.comment = S.comment);
@@ -2991,7 +2991,7 @@ function jr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
2991
2991
  }
2992
2992
  return l && l < c && i(l, "IMPOSSIBLE", "Map comment with trailing content"), a.range = [s.offset, c, l ?? c], a;
2993
2993
  }
2994
- function Br({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
2994
+ function Kr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
2995
2995
  const o = (r == null ? void 0 : r.nodeClass) ?? ae, a = new o(t.schema);
2996
2996
  t.atRoot && (t.atRoot = !1), t.atKey && (t.atKey = !1);
2997
2997
  let c = s.offset, l = null;
@@ -3044,7 +3044,7 @@ function qe(n, e, t, s) {
3044
3044
  return { comment: i, offset: e };
3045
3045
  }
3046
3046
  const vt = "Block collections are not allowed within flow collections", It = (n) => n && (n.type === "block-map" || n.type === "block-seq");
3047
- function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
3047
+ function qr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
3048
3048
  var m;
3049
3049
  const o = s.start.source === "{", a = o ? "flow map" : "flow sequence", c = (r == null ? void 0 : r.nodeClass) ?? (o ? j : ae), l = new c(t.schema);
3050
3050
  l.flow = !0;
@@ -3052,7 +3052,7 @@ function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
3052
3052
  f && (t.atRoot = !1), t.atKey && (t.atKey = !1);
3053
3053
  let u = s.offset + s.start.source.length;
3054
3054
  for (let w = 0; w < s.items.length; ++w) {
3055
- const b = s.items[w], { start: E, key: S, sep: N, value: A } = b, I = we(E, {
3055
+ const b = s.items[w], { start: E, key: S, sep: N, value: $ } = b, I = we(E, {
3056
3056
  flow: a,
3057
3057
  indicator: "explicit-key-ind",
3058
3058
  next: S ?? (N == null ? void 0 : N[0]),
@@ -3062,12 +3062,12 @@ function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
3062
3062
  startOnNewline: !1
3063
3063
  });
3064
3064
  if (!I.found) {
3065
- if (!I.anchor && !I.tag && !N && !A) {
3065
+ if (!I.anchor && !I.tag && !N && !$) {
3066
3066
  w === 0 && I.comma ? i(I.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${a}`) : w < s.items.length - 1 && i(I.start, "UNEXPECTED_TOKEN", `Unexpected empty item in ${a}`), I.comment && (l.comment ? l.comment += `
3067
3067
  ` + I.comment : l.comment = I.comment), u = I.end;
3068
3068
  continue;
3069
3069
  }
3070
- !o && t.options.strict && Le(S) && i(
3070
+ !o && t.options.strict && Re(S) && i(
3071
3071
  S,
3072
3072
  // checked by containsNewline()
3073
3073
  "MULTILINE_IMPLICIT_KEY",
@@ -3096,8 +3096,8 @@ function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
3096
3096
  }
3097
3097
  }
3098
3098
  if (!o && !N && !I.found) {
3099
- const k = A ? n(t, A, I, i) : e(t, I.end, N, null, I, i);
3100
- l.items.push(k), u = k.range[2], It(A) && i(k.range, "BLOCK_IN_FLOW", vt);
3099
+ const k = $ ? n(t, $, I, i) : e(t, I.end, N, null, I, i);
3100
+ l.items.push(k), u = k.range[2], It($) && i(k.range, "BLOCK_IN_FLOW", vt);
3101
3101
  } else {
3102
3102
  t.atKey = !0;
3103
3103
  const k = I.end, T = S ? n(t, S, I, i) : e(t, k, E, null, I, i);
@@ -3105,7 +3105,7 @@ function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
3105
3105
  const R = we(N ?? [], {
3106
3106
  flow: a,
3107
3107
  indicator: "map-value-ind",
3108
- next: A,
3108
+ next: $,
3109
3109
  offset: T.range[2],
3110
3110
  onError: i,
3111
3111
  parentIndent: s.indent,
@@ -3114,79 +3114,79 @@ function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
3114
3114
  if (R.found) {
3115
3115
  if (!o && !I.found && t.options.strict) {
3116
3116
  if (N)
3117
- for (const H of N) {
3118
- if (H === R.found)
3117
+ for (const x of N) {
3118
+ if (x === R.found)
3119
3119
  break;
3120
- if (H.type === "newline") {
3121
- i(H, "MULTILINE_IMPLICIT_KEY", "Implicit keys of flow sequence pairs need to be on a single line");
3120
+ if (x.type === "newline") {
3121
+ i(x, "MULTILINE_IMPLICIT_KEY", "Implicit keys of flow sequence pairs need to be on a single line");
3122
3122
  break;
3123
3123
  }
3124
3124
  }
3125
3125
  I.start < R.found.offset - 1024 && i(R.found, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit flow sequence key");
3126
3126
  }
3127
- } else A && ("source" in A && ((m = A.source) == null ? void 0 : m[0]) === ":" ? i(A, "MISSING_CHAR", `Missing space after : in ${a}`) : i(R.start, "MISSING_CHAR", `Missing , or : between ${a} items`));
3128
- const V = A ? n(t, A, R, i) : R.found ? e(t, R.end, N, null, R, i) : null;
3129
- V ? It(A) && i(V.range, "BLOCK_IN_FLOW", vt) : R.comment && (T.comment ? T.comment += `
3127
+ } else $ && ("source" in $ && ((m = $.source) == null ? void 0 : m[0]) === ":" ? i($, "MISSING_CHAR", `Missing space after : in ${a}`) : i(R.start, "MISSING_CHAR", `Missing , or : between ${a} items`));
3128
+ const V = $ ? n(t, $, R, i) : R.found ? e(t, R.end, N, null, R, i) : null;
3129
+ V ? It($) && i(V.range, "BLOCK_IN_FLOW", vt) : R.comment && (T.comment ? T.comment += `
3130
3130
  ` + R.comment : T.comment = R.comment);
3131
3131
  const U = new M(T, V);
3132
3132
  if (t.options.keepSourceTokens && (U.srcToken = b), o) {
3133
- const H = l;
3134
- Ls(t, H.items, T) && i(k, "DUPLICATE_KEY", "Map keys must be unique"), H.items.push(U);
3133
+ const x = l;
3134
+ Ls(t, x.items, T) && i(k, "DUPLICATE_KEY", "Map keys must be unique"), x.items.push(U);
3135
3135
  } else {
3136
- const H = new j(t.schema);
3137
- H.flow = !0, H.items.push(U);
3136
+ const x = new j(t.schema);
3137
+ x.flow = !0, x.items.push(U);
3138
3138
  const wn = (V ?? T).range;
3139
- H.range = [T.range[0], wn[1], wn[2]], l.items.push(H);
3139
+ x.range = [T.range[0], wn[1], wn[2]], l.items.push(x);
3140
3140
  }
3141
3141
  u = V ? V.range[2] : R.end;
3142
3142
  }
3143
3143
  }
3144
- const h = o ? "}" : "]", [p, ...g] = s.end;
3144
+ const h = o ? "}" : "]", [p, ...y] = s.end;
3145
3145
  let d = u;
3146
3146
  if ((p == null ? void 0 : p.source) === h)
3147
3147
  d = p.offset + p.source.length;
3148
3148
  else {
3149
3149
  const w = a[0].toUpperCase() + a.substring(1), b = f ? `${w} must end with a ${h}` : `${w} in block collection must be sufficiently indented and end with a ${h}`;
3150
- i(u, f ? "MISSING_CHAR" : "BAD_INDENT", b), p && p.source.length !== 1 && g.unshift(p);
3150
+ i(u, f ? "MISSING_CHAR" : "BAD_INDENT", b), p && p.source.length !== 1 && y.unshift(p);
3151
3151
  }
3152
- if (g.length > 0) {
3153
- const w = qe(g, d, t.options.strict, i);
3152
+ if (y.length > 0) {
3153
+ const w = qe(y, d, t.options.strict, i);
3154
3154
  w.comment && (l.comment ? l.comment += `
3155
3155
  ` + w.comment : l.comment = w.comment), l.range = [s.offset, d, w.offset];
3156
3156
  } else
3157
3157
  l.range = [s.offset, d, d];
3158
3158
  return l;
3159
3159
  }
3160
- function $t(n, e, t, s, i, r) {
3161
- const o = t.type === "block-map" ? jr(n, e, t, s, r) : t.type === "block-seq" ? Br(n, e, t, s, r) : Fr(n, e, t, s, r), a = o.constructor;
3160
+ function At(n, e, t, s, i, r) {
3161
+ const o = t.type === "block-map" ? Fr(n, e, t, s, r) : t.type === "block-seq" ? Kr(n, e, t, s, r) : qr(n, e, t, s, r), a = o.constructor;
3162
3162
  return i === "!" || i === a.tagName ? (o.tag = a.tagName, o) : (i && (o.tag = i), o);
3163
3163
  }
3164
- function Kr(n, e, t, s, i) {
3164
+ function Ur(n, e, t, s, i) {
3165
3165
  var h;
3166
3166
  const r = s.tag, o = r ? e.directives.tagName(r.source, (p) => i(r, "TAG_RESOLVE_FAILED", p)) : null;
3167
3167
  if (t.type === "block-seq") {
3168
- const { anchor: p, newlineAfterProp: g } = s, d = p && r ? p.offset > r.offset ? p : r : p ?? r;
3169
- d && (!g || g.offset < d.offset) && i(d, "MISSING_CHAR", "Missing newline after block sequence props");
3168
+ const { anchor: p, newlineAfterProp: y } = s, d = p && r ? p.offset > r.offset ? p : r : p ?? r;
3169
+ d && (!y || y.offset < d.offset) && i(d, "MISSING_CHAR", "Missing newline after block sequence props");
3170
3170
  }
3171
3171
  const a = t.type === "block-map" ? "map" : t.type === "block-seq" ? "seq" : t.start.source === "{" ? "map" : "seq";
3172
3172
  if (!r || !o || o === "!" || o === j.tagName && a === "map" || o === ae.tagName && a === "seq")
3173
- return $t(n, e, t, i, o);
3173
+ return At(n, e, t, i, o);
3174
3174
  let c = e.schema.tags.find((p) => p.tag === o && p.collection === a);
3175
3175
  if (!c) {
3176
3176
  const p = e.schema.knownTags[o];
3177
3177
  if ((p == null ? void 0 : p.collection) === a)
3178
3178
  e.schema.tags.push(Object.assign({}, p, { default: !1 })), c = p;
3179
3179
  else
3180
- return p ? i(r, "BAD_COLLECTION_TYPE", `${p.tag} used for ${a} collection, but expects ${p.collection ?? "scalar"}`, !0) : i(r, "TAG_RESOLVE_FAILED", `Unresolved tag: ${o}`, !0), $t(n, e, t, i, o);
3180
+ return p ? i(r, "BAD_COLLECTION_TYPE", `${p.tag} used for ${a} collection, but expects ${p.collection ?? "scalar"}`, !0) : i(r, "TAG_RESOLVE_FAILED", `Unresolved tag: ${o}`, !0), At(n, e, t, i, o);
3181
3181
  }
3182
- const l = $t(n, e, t, i, o, c), f = ((h = c.resolve) == null ? void 0 : h.call(c, l, (p) => i(r, "TAG_RESOLVE_FAILED", p), e.options)) ?? l, u = _(f) ? f : new v(f);
3182
+ const l = At(n, e, t, i, o, c), f = ((h = c.resolve) == null ? void 0 : h.call(c, l, (p) => i(r, "TAG_RESOLVE_FAILED", p), e.options)) ?? l, u = _(f) ? f : new v(f);
3183
3183
  return u.range = l.range, u.tag = o, c != null && c.format && (u.format = c.format), u;
3184
3184
  }
3185
- function qr(n, e, t) {
3186
- const s = e.offset, i = Ur(e, n.options.strict, t);
3185
+ function xr(n, e, t) {
3186
+ const s = e.offset, i = Hr(e, n.options.strict, t);
3187
3187
  if (!i)
3188
3188
  return { value: "", type: null, comment: "", range: [s, s, s] };
3189
- const r = i.mode === ">" ? v.BLOCK_FOLDED : v.BLOCK_LITERAL, o = e.source ? Hr(e.source) : [];
3189
+ const r = i.mode === ">" ? v.BLOCK_FOLDED : v.BLOCK_LITERAL, o = e.source ? Gr(e.source) : [];
3190
3190
  let a = o.length;
3191
3191
  for (let d = o.length - 1; d >= 0; --d) {
3192
3192
  const m = o[d][1];
@@ -3252,10 +3252,10 @@ function qr(n, e, t) {
3252
3252
  u += `
3253
3253
  `;
3254
3254
  }
3255
- const g = s + i.length + e.source.length;
3256
- return { value: u, type: r, comment: i.comment, range: [s, g, g] };
3255
+ const y = s + i.length + e.source.length;
3256
+ return { value: u, type: r, comment: i.comment, range: [s, y, y] };
3257
3257
  }
3258
- function Ur({ offset: n, props: e }, t, s) {
3258
+ function Hr({ offset: n, props: e }, t, s) {
3259
3259
  if (e[0].type !== "block-scalar-header")
3260
3260
  return s(e[0], "IMPOSSIBLE", "Block scalar header not found"), null;
3261
3261
  const { source: i } = e[0], r = i[0];
@@ -3265,8 +3265,8 @@ function Ur({ offset: n, props: e }, t, s) {
3265
3265
  if (!a && (p === "-" || p === "+"))
3266
3266
  a = p;
3267
3267
  else {
3268
- const g = Number(p);
3269
- !o && g ? o = g : c === -1 && (c = n + h);
3268
+ const y = Number(p);
3269
+ !o && y ? o = y : c === -1 && (c = n + h);
3270
3270
  }
3271
3271
  }
3272
3272
  c !== -1 && s(c, "UNEXPECTED_TOKEN", `Block scalar header includes extra characters: ${i}`);
@@ -3286,8 +3286,8 @@ function Ur({ offset: n, props: e }, t, s) {
3286
3286
  s(p, "UNEXPECTED_TOKEN", p.message), u += p.source.length;
3287
3287
  break;
3288
3288
  default: {
3289
- const g = `Unexpected token in block scalar header: ${p.type}`;
3290
- s(p, "UNEXPECTED_TOKEN", g);
3289
+ const y = `Unexpected token in block scalar header: ${p.type}`;
3290
+ s(p, "UNEXPECTED_TOKEN", y);
3291
3291
  const d = p.source;
3292
3292
  d && typeof d == "string" && (u += d.length);
3293
3293
  }
@@ -3295,25 +3295,25 @@ function Ur({ offset: n, props: e }, t, s) {
3295
3295
  }
3296
3296
  return { mode: r, indent: o, chomp: a, comment: f, length: u };
3297
3297
  }
3298
- function Hr(n) {
3298
+ function Gr(n) {
3299
3299
  const e = n.split(/\n( *)/), t = e[0], s = t.match(/^( *)/), r = [s != null && s[1] ? [s[1], t.slice(s[1].length)] : ["", t]];
3300
3300
  for (let o = 1; o < e.length; o += 2)
3301
3301
  r.push([e[o], e[o + 1]]);
3302
3302
  return r;
3303
3303
  }
3304
- function xr(n, e, t) {
3304
+ function Yr(n, e, t) {
3305
3305
  const { offset: s, type: i, source: r, end: o } = n;
3306
3306
  let a, c;
3307
- const l = (h, p, g) => t(s + h, p, g);
3307
+ const l = (h, p, y) => t(s + h, p, y);
3308
3308
  switch (i) {
3309
3309
  case "scalar":
3310
- a = v.PLAIN, c = Yr(r, l);
3310
+ a = v.PLAIN, c = Vr(r, l);
3311
3311
  break;
3312
3312
  case "single-quoted-scalar":
3313
- a = v.QUOTE_SINGLE, c = Gr(r, l);
3313
+ a = v.QUOTE_SINGLE, c = Jr(r, l);
3314
3314
  break;
3315
3315
  case "double-quoted-scalar":
3316
- a = v.QUOTE_DOUBLE, c = Vr(r, l);
3316
+ a = v.QUOTE_DOUBLE, c = Wr(r, l);
3317
3317
  break;
3318
3318
  default:
3319
3319
  return t(n, "UNEXPECTED_TOKEN", `Expected a flow scalar value, but found: ${i}`), {
@@ -3331,7 +3331,7 @@ function xr(n, e, t) {
3331
3331
  range: [s, f, u.offset]
3332
3332
  };
3333
3333
  }
3334
- function Yr(n, e) {
3334
+ function Vr(n, e) {
3335
3335
  let t = "";
3336
3336
  switch (n[0]) {
3337
3337
  case " ":
@@ -3356,7 +3356,7 @@ function Yr(n, e) {
3356
3356
  }
3357
3357
  return t && e(0, "BAD_SCALAR_START", `Plain value cannot start with ${t}`), Rs(n);
3358
3358
  }
3359
- function Gr(n, e) {
3359
+ function Jr(n, e) {
3360
3360
  return (n[n.length - 1] !== "'" || n.length === 1) && e(n.length, "MISSING_CHAR", "Missing closing 'quote"), Rs(n.slice(1, -1)).replace(/''/g, "'");
3361
3361
  }
3362
3362
  function Rs(n) {
@@ -3379,7 +3379,7 @@ function Rs(n) {
3379
3379
  const a = /[ \t]*(.*)/sy;
3380
3380
  return a.lastIndex = o, s = a.exec(n), i + r + ((s == null ? void 0 : s[1]) ?? "");
3381
3381
  }
3382
- function Vr(n, e) {
3382
+ function Wr(n, e) {
3383
3383
  let t = "";
3384
3384
  for (let s = 1; s < n.length - 1; ++s) {
3385
3385
  const i = n[s];
@@ -3387,11 +3387,11 @@ function Vr(n, e) {
3387
3387
  `))
3388
3388
  if (i === `
3389
3389
  `) {
3390
- const { fold: r, offset: o } = Jr(n, s);
3390
+ const { fold: r, offset: o } = zr(n, s);
3391
3391
  t += r, s = o;
3392
3392
  } else if (i === "\\") {
3393
3393
  let r = n[++s];
3394
- const o = Wr[r];
3394
+ const o = Qr[r];
3395
3395
  if (o)
3396
3396
  t += o;
3397
3397
  else if (r === `
@@ -3404,7 +3404,7 @@ function Vr(n, e) {
3404
3404
  r = n[++s + 1];
3405
3405
  else if (r === "x" || r === "u" || r === "U") {
3406
3406
  const a = r === "x" ? 2 : r === "u" ? 4 : 8;
3407
- t += zr(n, s + 1, a, e), s += a;
3407
+ t += Xr(n, s + 1, a, e), s += a;
3408
3408
  } else {
3409
3409
  const a = n.substr(s - 1, 2);
3410
3410
  e(s - 1, "BAD_DQ_ESCAPE", `Invalid escape sequence ${a}`), t += a;
@@ -3422,7 +3422,7 @@ function Vr(n, e) {
3422
3422
  }
3423
3423
  return (n[n.length - 1] !== '"' || n.length === 1) && e(n.length, "MISSING_CHAR", 'Missing closing "quote'), t;
3424
3424
  }
3425
- function Jr(n, e) {
3425
+ function zr(n, e) {
3426
3426
  let t = "", s = n[e + 1];
3427
3427
  for (; (s === " " || s === " " || s === `
3428
3428
  ` || s === "\r") && !(s === "\r" && n[e + 2] !== `
@@ -3432,7 +3432,7 @@ function Jr(n, e) {
3432
3432
  `), e += 1, s = n[e + 1];
3433
3433
  return t || (t = " "), { fold: t, offset: e };
3434
3434
  }
3435
- const Wr = {
3435
+ const Qr = {
3436
3436
  0: "\0",
3437
3437
  // null character
3438
3438
  a: "\x07",
@@ -3466,7 +3466,7 @@ const Wr = {
3466
3466
  "\\": "\\",
3467
3467
  " ": " "
3468
3468
  };
3469
- function zr(n, e, t, s) {
3469
+ function Xr(n, e, t, s) {
3470
3470
  const i = n.substr(e, t), o = i.length === t && /^[0-9a-fA-F]+$/.test(i) ? parseInt(i, 16) : NaN;
3471
3471
  try {
3472
3472
  return String.fromCodePoint(o);
@@ -3476,9 +3476,9 @@ function zr(n, e, t, s) {
3476
3476
  }
3477
3477
  }
3478
3478
  function Ps(n, e, t, s) {
3479
- const { value: i, type: r, comment: o, range: a } = e.type === "block-scalar" ? qr(n, e, s) : xr(e, n.options.strict, s), c = t ? n.directives.tagName(t.source, (u) => s(t, "TAG_RESOLVE_FAILED", u)) : null;
3479
+ const { value: i, type: r, comment: o, range: a } = e.type === "block-scalar" ? xr(n, e, s) : Yr(e, n.options.strict, s), c = t ? n.directives.tagName(t.source, (u) => s(t, "TAG_RESOLVE_FAILED", u)) : null;
3480
3480
  let l;
3481
- n.options.stringKeys && n.atKey ? l = n.schema[G] : c ? l = Qr(n.schema, i, c, t, s) : e.type === "scalar" ? l = Xr(n, i, e, s) : l = n.schema[G];
3481
+ n.options.stringKeys && n.atKey ? l = n.schema[Y] : c ? l = Zr(n.schema, i, c, t, s) : e.type === "scalar" ? l = eo(n, i, e, s) : l = n.schema[Y];
3482
3482
  let f;
3483
3483
  try {
3484
3484
  const u = l.resolve(i, (h) => s(t ?? e, "TAG_RESOLVE_FAILED", h), n.options);
@@ -3489,10 +3489,10 @@ function Ps(n, e, t, s) {
3489
3489
  }
3490
3490
  return f.range = a, f.source = i, r && (f.type = r), c && (f.tag = c), l.format && (f.format = l.format), o && (f.comment = o), f;
3491
3491
  }
3492
- function Qr(n, e, t, s, i) {
3492
+ function Zr(n, e, t, s, i) {
3493
3493
  var a;
3494
3494
  if (t === "!")
3495
- return n[G];
3495
+ return n[Y];
3496
3496
  const r = [];
3497
3497
  for (const c of n.tags)
3498
3498
  if (!c.collection && c.tag === t)
@@ -3504,18 +3504,18 @@ function Qr(n, e, t, s, i) {
3504
3504
  if ((a = c.test) != null && a.test(e))
3505
3505
  return c;
3506
3506
  const o = n.knownTags[t];
3507
- return o && !o.collection ? (n.tags.push(Object.assign({}, o, { default: !1, test: void 0 })), o) : (i(s, "TAG_RESOLVE_FAILED", `Unresolved tag: ${t}`, t !== "tag:yaml.org,2002:str"), n[G]);
3507
+ return o && !o.collection ? (n.tags.push(Object.assign({}, o, { default: !1, test: void 0 })), o) : (i(s, "TAG_RESOLVE_FAILED", `Unresolved tag: ${t}`, t !== "tag:yaml.org,2002:str"), n[Y]);
3508
3508
  }
3509
- function Xr({ atKey: n, directives: e, schema: t }, s, i, r) {
3509
+ function eo({ atKey: n, directives: e, schema: t }, s, i, r) {
3510
3510
  const o = t.tags.find((a) => {
3511
3511
  var c;
3512
3512
  return (a.default === !0 || n && a.default === "key") && ((c = a.test) == null ? void 0 : c.test(s));
3513
- }) || t[G];
3513
+ }) || t[Y];
3514
3514
  if (t.compat) {
3515
3515
  const a = t.compat.find((c) => {
3516
3516
  var l;
3517
3517
  return c.default && ((l = c.test) == null ? void 0 : l.test(s));
3518
- }) ?? t[G];
3518
+ }) ?? t[Y];
3519
3519
  if (o.tag !== a.tag) {
3520
3520
  const c = e.tagString(o.tag), l = e.tagString(a.tag), f = `Value may be parsed as either ${c} or ${l}`;
3521
3521
  r(i, "TAG_RESOLVE_FAILED", f, !0);
@@ -3523,7 +3523,7 @@ function Xr({ atKey: n, directives: e, schema: t }, s, i, r) {
3523
3523
  }
3524
3524
  return o;
3525
3525
  }
3526
- function Zr(n, e, t) {
3526
+ function to(n, e, t) {
3527
3527
  if (e) {
3528
3528
  t ?? (t = e.length);
3529
3529
  for (let s = t - 1; s >= 0; --s) {
@@ -3542,13 +3542,13 @@ function Zr(n, e, t) {
3542
3542
  }
3543
3543
  return n;
3544
3544
  }
3545
- const eo = { composeNode: Ms, composeEmptyNode: tn };
3545
+ const no = { composeNode: Ms, composeEmptyNode: tn };
3546
3546
  function Ms(n, e, t, s) {
3547
3547
  const i = n.atKey, { spaceBefore: r, comment: o, anchor: a, tag: c } = t;
3548
3548
  let l, f = !0;
3549
3549
  switch (e.type) {
3550
3550
  case "alias":
3551
- l = to(n, e, s), (a || c) && s(e, "ALIAS_PROPS", "An alias node must not specify any properties");
3551
+ l = so(n, e, s), (a || c) && s(e, "ALIAS_PROPS", "An alias node must not specify any properties");
3552
3552
  break;
3553
3553
  case "scalar":
3554
3554
  case "single-quoted-scalar":
@@ -3560,7 +3560,7 @@ function Ms(n, e, t, s) {
3560
3560
  case "block-seq":
3561
3561
  case "flow-collection":
3562
3562
  try {
3563
- l = Kr(eo, n, e, t, s), a && (l.anchor = a.source.substring(1));
3563
+ l = Ur(no, n, e, t, s), a && (l.anchor = a.source.substring(1));
3564
3564
  } catch (u) {
3565
3565
  const h = u instanceof Error ? u.message : String(u);
3566
3566
  s(e, "RESOURCE_EXHAUSTION", h);
@@ -3576,19 +3576,19 @@ function Ms(n, e, t, s) {
3576
3576
  function tn(n, e, t, s, { spaceBefore: i, comment: r, anchor: o, tag: a, end: c }, l) {
3577
3577
  const f = {
3578
3578
  type: "scalar",
3579
- offset: Zr(e, t, s),
3579
+ offset: to(e, t, s),
3580
3580
  indent: -1,
3581
3581
  source: ""
3582
3582
  }, u = Ps(n, f, a, l);
3583
3583
  return o && (u.anchor = o.source.substring(1), u.anchor === "" && l(o, "BAD_ALIAS", "Anchor cannot be an empty string")), i && (u.spaceBefore = !0), r && (u.comment = r, u.range[2] = c), u;
3584
3584
  }
3585
- function to({ options: n }, { offset: e, source: t, end: s }, i) {
3586
- const r = new Ht(t.substring(1));
3585
+ function so({ options: n }, { offset: e, source: t, end: s }, i) {
3586
+ const r = new xt(t.substring(1));
3587
3587
  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);
3588
3588
  const o = e + t.length, a = qe(s, o, n.strict, i);
3589
3589
  return r.range = [e, o, a.offset], a.comment && (r.comment = a.comment), r;
3590
3590
  }
3591
- function no(n, e, { offset: t, start: s, value: i, end: r }, o) {
3591
+ function io(n, e, { offset: t, start: s, value: i, end: r }, o) {
3592
3592
  const a = Object.assign({ _directives: e }, n), c = new Ke(void 0, a), l = {
3593
3593
  atKey: !1,
3594
3594
  atRoot: !0,
@@ -3636,11 +3636,11 @@ function Tn(n) {
3636
3636
  }
3637
3637
  return { comment: e, afterEmptyLine: s };
3638
3638
  }
3639
- class so {
3639
+ class ro {
3640
3640
  constructor(e = {}) {
3641
3641
  this.doc = null, this.atDirectives = !1, this.prelude = [], this.errors = [], this.warnings = [], this.onError = (t, s, i, r) => {
3642
3642
  const o = $e(t);
3643
- r ? this.warnings.push(new Dr(o, s, i)) : this.errors.push(new Te(o, s, i));
3643
+ r ? this.warnings.push(new Br(o, s, i)) : this.errors.push(new Oe(o, s, i));
3644
3644
  }, this.directives = new P({ version: e.version || "1.2" }), this.options = e;
3645
3645
  }
3646
3646
  decorate(e, t) {
@@ -3707,7 +3707,7 @@ ${o}` : s;
3707
3707
  }), this.prelude.push(e.source), this.atDirectives = !0;
3708
3708
  break;
3709
3709
  case "document": {
3710
- const t = no(this.options, this.directives, e, this.onError);
3710
+ const t = io(this.options, this.directives, e, this.onError);
3711
3711
  this.atDirectives && !t.directives.docStart && this.onError(e, "MISSING_CHAR", "Missing directives-end/doc-start indicator line"), this.decorate(t, !1), this.doc && (yield this.doc), this.doc = t, this.atDirectives = !1;
3712
3712
  break;
3713
3713
  }
@@ -3719,14 +3719,14 @@ ${o}` : s;
3719
3719
  this.prelude.push(e.source);
3720
3720
  break;
3721
3721
  case "error": {
3722
- const t = e.source ? `${e.message}: ${JSON.stringify(e.source)}` : e.message, s = new Te($e(e), "UNEXPECTED_TOKEN", t);
3722
+ const t = e.source ? `${e.message}: ${JSON.stringify(e.source)}` : e.message, s = new Oe($e(e), "UNEXPECTED_TOKEN", t);
3723
3723
  this.atDirectives || !this.doc ? this.errors.push(s) : this.doc.errors.push(s);
3724
3724
  break;
3725
3725
  }
3726
3726
  case "doc-end": {
3727
3727
  if (!this.doc) {
3728
3728
  const s = "Unexpected doc-end without preceding document";
3729
- this.errors.push(new Te($e(e), "UNEXPECTED_TOKEN", s));
3729
+ this.errors.push(new Oe($e(e), "UNEXPECTED_TOKEN", s));
3730
3730
  break;
3731
3731
  }
3732
3732
  this.doc.directives.docEnd = !0;
@@ -3740,7 +3740,7 @@ ${t.comment}` : t.comment;
3740
3740
  break;
3741
3741
  }
3742
3742
  default:
3743
- this.errors.push(new Te($e(e), "UNEXPECTED_TOKEN", `Unsupported token ${e.type}`));
3743
+ this.errors.push(new Oe($e(e), "UNEXPECTED_TOKEN", `Unsupported token ${e.type}`));
3744
3744
  }
3745
3745
  }
3746
3746
  /**
@@ -3759,7 +3759,7 @@ ${t.comment}` : t.comment;
3759
3759
  }
3760
3760
  }
3761
3761
  const Ds = "\uFEFF", js = "", Bs = "", Mt = "";
3762
- function io(n) {
3762
+ function oo(n) {
3763
3763
  switch (n) {
3764
3764
  case Ds:
3765
3765
  return "byte-order-mark";
@@ -3820,7 +3820,7 @@ function io(n) {
3820
3820
  }
3821
3821
  return null;
3822
3822
  }
3823
- function x(n) {
3823
+ function H(n) {
3824
3824
  switch (n) {
3825
3825
  case void 0:
3826
3826
  case " ":
@@ -3833,9 +3833,9 @@ function x(n) {
3833
3833
  return !1;
3834
3834
  }
3835
3835
  }
3836
- const On = new Set("0123456789ABCDEFabcdef"), ro = new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"), Ge = new Set(",[]{}"), oo = new Set(` ,[]{}
3837
- \r `), At = (n) => !n || oo.has(n);
3838
- class ao {
3836
+ const On = new Set("0123456789ABCDEFabcdef"), ao = new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"), Ye = new Set(",[]{}"), co = new Set(` ,[]{}
3837
+ \r `), $t = (n) => !n || co.has(n);
3838
+ class lo {
3839
3839
  constructor() {
3840
3840
  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;
3841
3841
  }
@@ -3884,7 +3884,7 @@ class ao {
3884
3884
  }
3885
3885
  if (t === "-" || t === ".") {
3886
3886
  const s = this.buffer.substr(e, 3);
3887
- if ((s === "---" || s === "...") && x(this.buffer[e + 3]))
3887
+ if ((s === "---" || s === "...") && H(this.buffer[e + 3]))
3888
3888
  return -1;
3889
3889
  }
3890
3890
  return e;
@@ -3961,16 +3961,16 @@ class ao {
3961
3961
  if (!this.atEnd && !this.hasChars(4))
3962
3962
  return this.setNext("line-start");
3963
3963
  const t = this.peek(3);
3964
- if ((t === "---" || t === "...") && x(this.charAt(3)))
3964
+ if ((t === "---" || t === "...") && H(this.charAt(3)))
3965
3965
  return yield* this.pushCount(3), this.indentValue = 0, this.indentNext = 0, t === "---" ? "doc" : "stream";
3966
3966
  }
3967
- return this.indentValue = yield* this.pushSpaces(!1), this.indentNext > this.indentValue && !x(this.charAt(1)) && (this.indentNext = this.indentValue), yield* this.parseBlockStart();
3967
+ return this.indentValue = yield* this.pushSpaces(!1), this.indentNext > this.indentValue && !H(this.charAt(1)) && (this.indentNext = this.indentValue), yield* this.parseBlockStart();
3968
3968
  }
3969
3969
  *parseBlockStart() {
3970
3970
  const [e, t] = this.peek(2);
3971
3971
  if (!t && !this.atEnd)
3972
3972
  return this.setNext("block-start");
3973
- if ((e === "-" || e === "?" || e === ":") && x(t)) {
3973
+ if ((e === "-" || e === "?" || e === ":") && H(t)) {
3974
3974
  const s = (yield* this.pushCount(1)) + (yield* this.pushSpaces(!0));
3975
3975
  return this.indentNext = this.indentValue + 1, this.indentValue += s, "block-start";
3976
3976
  }
@@ -3994,7 +3994,7 @@ class ao {
3994
3994
  case "]":
3995
3995
  return yield* this.pushCount(1), "doc";
3996
3996
  case "*":
3997
- return yield* this.pushUntil(At), "doc";
3997
+ return yield* this.pushUntil($t), "doc";
3998
3998
  case '"':
3999
3999
  case "'":
4000
4000
  return yield* this.parseQuotedScalar();
@@ -4013,7 +4013,7 @@ class ao {
4013
4013
  const i = this.getLine();
4014
4014
  if (i === null)
4015
4015
  return this.setNext("flow");
4016
- if ((s !== -1 && s < this.indentNext && i[0] !== "#" || s === 0 && (i.startsWith("---") || i.startsWith("...")) && x(i[3])) && !(s === this.indentNext - 1 && this.flowLevel === 1 && (i[0] === "]" || i[0] === "}")))
4016
+ if ((s !== -1 && s < this.indentNext && i[0] !== "#" || s === 0 && (i.startsWith("---") || i.startsWith("...")) && H(i[3])) && !(s === this.indentNext - 1 && this.flowLevel === 1 && (i[0] === "]" || i[0] === "}")))
4017
4017
  return this.flowLevel = 0, yield Bs, yield* this.parseLineStart();
4018
4018
  let r = 0;
4019
4019
  for (; i[r] === ","; )
@@ -4030,13 +4030,13 @@ class ao {
4030
4030
  case "]":
4031
4031
  return yield* this.pushCount(1), this.flowKey = !0, this.flowLevel -= 1, this.flowLevel ? "flow" : "doc";
4032
4032
  case "*":
4033
- return yield* this.pushUntil(At), "flow";
4033
+ return yield* this.pushUntil($t), "flow";
4034
4034
  case '"':
4035
4035
  case "'":
4036
4036
  return this.flowKey = !0, yield* this.parseQuotedScalar();
4037
4037
  case ":": {
4038
4038
  const o = this.charAt(1);
4039
- if (this.flowKey || x(o) || o === ",")
4039
+ if (this.flowKey || H(o) || o === ",")
4040
4040
  return this.flowKey = !1, yield* this.pushCount(1), yield* this.pushSpaces(!0), "flow";
4041
4041
  }
4042
4042
  default:
@@ -4090,7 +4090,7 @@ class ao {
4090
4090
  else if (t !== "-")
4091
4091
  break;
4092
4092
  }
4093
- return yield* this.pushUntil((t) => x(t) || t === "#");
4093
+ return yield* this.pushUntil((t) => H(t) || t === "#");
4094
4094
  }
4095
4095
  *parseBlockScalar() {
4096
4096
  let e = this.pos - 1, t = 0, s;
@@ -4160,14 +4160,14 @@ class ao {
4160
4160
  for (; i = this.buffer[++s]; )
4161
4161
  if (i === ":") {
4162
4162
  const r = this.buffer[s + 1];
4163
- if (x(r) || e && Ge.has(r))
4163
+ if (H(r) || e && Ye.has(r))
4164
4164
  break;
4165
4165
  t = s;
4166
- } else if (x(i)) {
4166
+ } else if (H(i)) {
4167
4167
  let r = this.buffer[s + 1];
4168
4168
  if (i === "\r" && (r === `
4169
4169
  ` ? (s += 1, i = `
4170
- `, r = this.buffer[s + 1]) : t = s), r === "#" || e && Ge.has(r))
4170
+ `, r = this.buffer[s + 1]) : t = s), r === "#" || e && Ye.has(r))
4171
4171
  break;
4172
4172
  if (i === `
4173
4173
  `) {
@@ -4177,7 +4177,7 @@ class ao {
4177
4177
  s = Math.max(s, o - 2);
4178
4178
  }
4179
4179
  } else {
4180
- if (e && Ge.has(i))
4180
+ if (e && Ye.has(i))
4181
4181
  break;
4182
4182
  t = s;
4183
4183
  }
@@ -4198,13 +4198,13 @@ class ao {
4198
4198
  e += yield* this.pushTag(), e += yield* this.pushSpaces(!0);
4199
4199
  continue e;
4200
4200
  case "&":
4201
- e += yield* this.pushUntil(At), e += yield* this.pushSpaces(!0);
4201
+ e += yield* this.pushUntil($t), e += yield* this.pushSpaces(!0);
4202
4202
  continue e;
4203
4203
  case "-":
4204
4204
  case "?":
4205
4205
  case ":": {
4206
4206
  const t = this.flowLevel > 0, s = this.charAt(1);
4207
- if (x(s) || t && Ge.has(s)) {
4207
+ if (H(s) || t && Ye.has(s)) {
4208
4208
  t ? this.flowKey && (this.flowKey = !1) : this.indentNext = this.indentValue + 1, e += yield* this.pushCount(1), e += yield* this.pushSpaces(!0);
4209
4209
  continue e;
4210
4210
  }
@@ -4217,13 +4217,13 @@ class ao {
4217
4217
  *pushTag() {
4218
4218
  if (this.charAt(1) === "<") {
4219
4219
  let e = this.pos + 2, t = this.buffer[e];
4220
- for (; !x(t) && t !== ">"; )
4220
+ for (; !H(t) && t !== ">"; )
4221
4221
  t = this.buffer[++e];
4222
4222
  return yield* this.pushToIndex(t === ">" ? e + 1 : e, !1);
4223
4223
  } else {
4224
4224
  let e = this.pos + 1, t = this.buffer[e];
4225
4225
  for (; t; )
4226
- if (ro.has(t))
4226
+ if (ao.has(t))
4227
4227
  t = this.buffer[++e];
4228
4228
  else if (t === "%" && On.has(this.buffer[e + 1]) && On.has(this.buffer[e + 2]))
4229
4229
  t = this.buffer[e += 3];
@@ -4253,7 +4253,7 @@ class ao {
4253
4253
  return yield* this.pushToIndex(t, !1);
4254
4254
  }
4255
4255
  }
4256
- class co {
4256
+ class uo {
4257
4257
  constructor() {
4258
4258
  this.lineStarts = [], this.addNewLine = (e) => this.lineStarts.push(e), this.linePos = (e) => {
4259
4259
  let t = 0, s = this.lineStarts.length;
@@ -4270,7 +4270,7 @@ class co {
4270
4270
  };
4271
4271
  }
4272
4272
  }
4273
- function z(n, e) {
4273
+ function Q(n, e) {
4274
4274
  for (let t = 0; t < n.length; ++t)
4275
4275
  if (n[t].type === e)
4276
4276
  return !0;
@@ -4342,15 +4342,15 @@ function tt(n, e) {
4342
4342
  function _n(n) {
4343
4343
  if (n.start.type === "flow-seq-start")
4344
4344
  for (const e of n.items)
4345
- e.sep && !e.value && !z(e.start, "explicit-key-ind") && !z(e.sep, "map-value-ind") && (e.key && (e.value = e.key), delete e.key, Fs(e.value) ? e.value.end ? tt(e.value.end, e.sep) : e.value.end = e.sep : tt(e.start, e.sep), delete e.sep);
4345
+ 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, Fs(e.value) ? e.value.end ? tt(e.value.end, e.sep) : e.value.end = e.sep : tt(e.start, e.sep), delete e.sep);
4346
4346
  }
4347
- class lo {
4347
+ class fo {
4348
4348
  /**
4349
4349
  * @param onNewLine - If defined, called separately with the start position of
4350
4350
  * each new line (in `parse()`, including the start of input).
4351
4351
  */
4352
4352
  constructor(e) {
4353
- this.atNewLine = !0, this.atScalar = !1, this.indent = 0, this.offset = 0, this.onKeyLine = !1, this.stack = [], this.source = "", this.type = "", this.lexer = new ao(), this.onNewLine = e;
4353
+ this.atNewLine = !0, this.atScalar = !1, this.indent = 0, this.offset = 0, this.onKeyLine = !1, this.stack = [], this.source = "", this.type = "", this.lexer = new lo(), this.onNewLine = e;
4354
4354
  }
4355
4355
  /**
4356
4356
  * Parse `source` as a YAML stream.
@@ -4374,7 +4374,7 @@ class lo {
4374
4374
  this.atScalar = !1, yield* this.step(), this.offset += e.length;
4375
4375
  return;
4376
4376
  }
4377
- const t = io(e);
4377
+ const t = oo(e);
4378
4378
  if (t)
4379
4379
  if (t === "scalar")
4380
4380
  this.atNewLine = !1, this.atScalar = !0, this.type = "scalar";
@@ -4659,14 +4659,14 @@ class lo {
4659
4659
  if (t.sep)
4660
4660
  if (t.value)
4661
4661
  e.items.push({ start: [], key: null, sep: [this.sourceToken] });
4662
- else if (z(t.sep, "map-value-ind"))
4662
+ else if (Q(t.sep, "map-value-ind"))
4663
4663
  this.stack.push({
4664
4664
  type: "block-map",
4665
4665
  offset: this.offset,
4666
4666
  indent: this.indent,
4667
4667
  items: [{ start: o, key: null, sep: [this.sourceToken] }]
4668
4668
  });
4669
- else if (Fs(t.key) && !z(t.sep, "newline")) {
4669
+ else if (Fs(t.key) && !Q(t.sep, "newline")) {
4670
4670
  const a = ue(t.start), c = t.key, l = t.sep;
4671
4671
  l.push(this.sourceToken), delete t.key, delete t.sep, this.stack.push({
4672
4672
  type: "block-map",
@@ -4675,7 +4675,7 @@ class lo {
4675
4675
  items: [{ start: a, key: c, sep: l }]
4676
4676
  });
4677
4677
  } else o.length > 0 ? t.sep = t.sep.concat(o, this.sourceToken) : t.sep.push(this.sourceToken);
4678
- else if (z(t.start, "newline"))
4678
+ else if (Q(t.start, "newline"))
4679
4679
  Object.assign(t, { key: null, sep: [this.sourceToken] });
4680
4680
  else {
4681
4681
  const a = ue(t.start);
@@ -4687,7 +4687,7 @@ class lo {
4687
4687
  });
4688
4688
  }
4689
4689
  else
4690
- t.sep ? t.value || r ? e.items.push({ start: o, key: null, sep: [this.sourceToken] }) : z(t.sep, "map-value-ind") ? this.stack.push({
4690
+ t.sep ? t.value || r ? e.items.push({ start: o, key: null, sep: [this.sourceToken] }) : Q(t.sep, "map-value-ind") ? this.stack.push({
4691
4691
  type: "block-map",
4692
4692
  offset: this.offset,
4693
4693
  indent: this.indent,
@@ -4707,7 +4707,7 @@ class lo {
4707
4707
  const a = this.startBlockValue(e);
4708
4708
  if (a) {
4709
4709
  if (a.type === "block-seq") {
4710
- if (!t.explicitKey && t.sep && !z(t.sep, "newline")) {
4710
+ if (!t.explicitKey && t.sep && !Q(t.sep, "newline")) {
4711
4711
  yield* this.pop({
4712
4712
  type: "error",
4713
4713
  offset: this.offset,
@@ -4760,7 +4760,7 @@ class lo {
4760
4760
  case "seq-item-ind":
4761
4761
  if (this.indent !== e.indent)
4762
4762
  break;
4763
- t.value || z(t.start, "seq-item-ind") ? e.items.push({ start: [this.sourceToken] }) : t.start.push(this.sourceToken);
4763
+ t.value || Q(t.start, "seq-item-ind") ? e.items.push({ start: [this.sourceToken] }) : t.start.push(this.sourceToken);
4764
4764
  return;
4765
4765
  }
4766
4766
  if (this.indent > e.indent) {
@@ -4925,25 +4925,25 @@ class lo {
4925
4925
  }
4926
4926
  }
4927
4927
  }
4928
- function uo(n) {
4928
+ function ho(n) {
4929
4929
  const e = n.prettyErrors !== !1;
4930
- return { lineCounter: n.lineCounter || e && new co() || null, prettyErrors: e };
4930
+ return { lineCounter: n.lineCounter || e && new uo() || null, prettyErrors: e };
4931
4931
  }
4932
- function fo(n, e = {}) {
4933
- const { lineCounter: t, prettyErrors: s } = uo(e), i = new lo(t == null ? void 0 : t.addNewLine), r = new so(e);
4932
+ function po(n, e = {}) {
4933
+ const { lineCounter: t, prettyErrors: s } = ho(e), i = new fo(t == null ? void 0 : t.addNewLine), r = new ro(e);
4934
4934
  let o = null;
4935
4935
  for (const a of r.compose(i.parse(n), !0, n.length))
4936
4936
  if (!o)
4937
4937
  o = a;
4938
4938
  else if (o.options.logLevel !== "silent") {
4939
- o.errors.push(new Te(a.range.slice(0, 2), "MULTIPLE_DOCS", "Source contains multiple documents; please use YAML.parseAllDocuments()"));
4939
+ o.errors.push(new Oe(a.range.slice(0, 2), "MULTIPLE_DOCS", "Source contains multiple documents; please use YAML.parseAllDocuments()"));
4940
4940
  break;
4941
4941
  }
4942
- return s && t && (o.errors.forEach($n(n, t)), o.warnings.forEach($n(n, t))), o;
4942
+ return s && t && (o.errors.forEach(An(n, t)), o.warnings.forEach(An(n, t))), o;
4943
4943
  }
4944
4944
  function wt(n, e, t) {
4945
4945
  let s;
4946
- const i = fo(n, t);
4946
+ const i = po(n, t);
4947
4947
  if (!i)
4948
4948
  return null;
4949
4949
  if (i.warnings.forEach((r) => fs(i.options.logLevel, r)), i.errors.length > 0) {
@@ -4953,7 +4953,7 @@ function wt(n, e, t) {
4953
4953
  }
4954
4954
  return i.toJS(Object.assign({ reviver: s }, t));
4955
4955
  }
4956
- function ho(n, e, t) {
4956
+ function mo(n, e, t) {
4957
4957
  let s = null;
4958
4958
  if (Array.isArray(e) && (s = e), n === void 0) {
4959
4959
  const { keepUndefined: i } = {};
@@ -4962,7 +4962,7 @@ function ho(n, e, t) {
4962
4962
  }
4963
4963
  return De(n) && !s ? n.toString(t) : new Ke(n, s, t).toString(t);
4964
4964
  }
4965
- const Ks = /^#{2,3}\s+/, nt = /^[-*]\s+\[([ xX])\]\s+(.*)$/, po = /^\[(review|manual|issue)\]\s+(.*)$/, mo = /^run:\s*(.+)$/, Ln = /^-\s+(\d{4}-\d{2}-\d{2}):\s*(.*)$/, go = /^\[(?:phase:(\d+)|body)\]\s+(?:\[(decision|question)\]\s+)?(.*)$/, Rn = /^-\s+\[([ xX])\]\s+(?:(\d{4}-\d{2}-\d{2})\s+)?\[(log|clarification|review|note|decision|question|chat)\]\s+(\[agent\]\s+)?(.*)$/, yo = ["note", "decision", "question"];
4965
+ const Ks = /^#{2,3}\s+/, nt = /^[-*]\s+\[([ xX])\]\s+(.*)$/, go = /^\[(review|manual|issue)\]\s+(.*)$/, yo = /^run:\s*(.+)$/, Ln = /^-\s+(\d{4}-\d{2}-\d{2}):\s*(.*)$/, wo = /^\[(?:phase:(\d+)|body)\]\s+(?:\[(decision|question)\]\s+)?(.*)$/, Rn = /^-\s+\[([ xX])\]\s+(?:(\d{4}-\d{2}-\d{2})\s+)?\[(log|clarification|review|note|decision|question|chat)\]\s+(\[agent\]\s+)?(.*)$/, bo = ["note", "decision", "question"];
4966
4966
  function nn(n, e, t, s) {
4967
4967
  const i = [];
4968
4968
  let r = e;
@@ -4984,14 +4984,14 @@ function qs(n, e, t) {
4984
4984
  for (; i < t; ) {
4985
4985
  const r = n[i].match(nt);
4986
4986
  if (r) {
4987
- const o = r[1].toLowerCase() === "x", a = r[2].trim(), c = a.match(po), l = c ? c[2].trim() : a, f = c ? c[1] : void 0, u = [];
4987
+ const o = r[1].toLowerCase() === "x", a = r[2].trim(), c = a.match(go), l = c ? c[2].trim() : a, f = c ? c[1] : void 0, u = [];
4988
4988
  let h;
4989
4989
  for (i++; i < t; ) {
4990
4990
  const p = n[i];
4991
4991
  if (p.trim() === "" || nt.test(p) || Ks.test(p)) break;
4992
4992
  if (/^\s/.test(p)) {
4993
- const g = p.trimStart(), d = g.match(mo), m = d ? $i(d[1]) : void 0;
4994
- m ? h = m : u.push(g), i++;
4993
+ const y = p.trimStart(), d = y.match(yo), m = d ? Ti(d[1]) : void 0;
4994
+ m ? h = m : u.push(y), i++;
4995
4995
  } else
4996
4996
  break;
4997
4997
  }
@@ -5029,21 +5029,21 @@ function Us(n, e) {
5029
5029
  if (t.push(`- [${s.done ? "x" : " "}] ${i}`), s.description)
5030
5030
  for (const r of s.description.split(`
5031
5031
  `)) t.push(` ${r}`);
5032
- s.run && t.push(` run: ${Ai(s.run)}`);
5032
+ s.run && t.push(` run: ${Oi(s.run)}`);
5033
5033
  }
5034
5034
  return t;
5035
5035
  }
5036
5036
  function on(n, e) {
5037
5037
  return [n, ...e.map((t) => `- ${t.date}: ${t.text}`)];
5038
5038
  }
5039
- function wo(n) {
5039
+ function ko(n) {
5040
5040
  return n.kind === "phase" ? `[phase:${n.index}]` : "[body]";
5041
5041
  }
5042
- function bo(n, e, t) {
5042
+ function So(n, e, t) {
5043
5043
  const s = [];
5044
5044
  let i = e;
5045
5045
  for (; i < t; ) {
5046
- const r = n[i].match(nt), o = r ? r[2].trim().match(go) : null;
5046
+ const r = n[i].match(nt), o = r ? r[2].trim().match(wo) : null;
5047
5047
  if (!r || !o) {
5048
5048
  i++;
5049
5049
  continue;
@@ -5058,12 +5058,12 @@ function bo(n, e, t) {
5058
5058
  }
5059
5059
  return s;
5060
5060
  }
5061
- function ko(n) {
5061
+ function Eo(n) {
5062
5062
  const e = ["### Notes"];
5063
5063
  for (const t of n) {
5064
5064
  const s = t.kind && t.kind !== "note" ? `[${t.kind}] ` : "";
5065
5065
  e.push(
5066
- `- [${t.state === "resolved" ? "x" : " "}] ${wo(t.anchor)} ${s}${t.prose}`
5066
+ `- [${t.state === "resolved" ? "x" : " "}] ${ko(t.anchor)} ${s}${t.prose}`
5067
5067
  );
5068
5068
  }
5069
5069
  return e;
@@ -5072,7 +5072,7 @@ const bt = {
5072
5072
  headingRe: /^#{2,3}\s+Phases\s*$/i,
5073
5073
  parseEntries: qs,
5074
5074
  formatLines: (n) => Us("### Phases", n)
5075
- }, Hs = {
5075
+ }, xs = {
5076
5076
  headingRe: /^#{2,3}\s+Fixes\s*$/i,
5077
5077
  parseEntries: qs,
5078
5078
  formatLines: (n) => Us("### Fixes", n)
@@ -5086,14 +5086,14 @@ const bt = {
5086
5086
  formatLines: (n) => on("### Clarifications", n)
5087
5087
  }, cn = {
5088
5088
  headingRe: /^#{2,3}\s+Notes\s*$/i,
5089
- parseEntries: bo,
5090
- formatLines: ko
5091
- }, So = {
5089
+ parseEntries: So,
5090
+ formatLines: Eo
5091
+ }, No = {
5092
5092
  headingRe: /^#{2,3}\s+Review\s*$/i,
5093
5093
  parseEntries: rn,
5094
5094
  formatLines: (n) => on("### Review", n)
5095
5095
  };
5096
- function Eo(n, e, t) {
5096
+ function vo(n, e, t) {
5097
5097
  const s = [];
5098
5098
  let i = e;
5099
5099
  for (; i < t; ) {
@@ -5103,11 +5103,11 @@ function Eo(n, e, t) {
5103
5103
  continue;
5104
5104
  }
5105
5105
  const o = r[3], a = nn(n, i + 1, t, Rn), c = { kind: o, text: sn(r[5], a.text) };
5106
- r[2] && (c.date = r[2]), r[4] && (c.from = "agent"), yo.includes(o) && (c.state = r[1].toLowerCase() === "x" ? "resolved" : "open"), s.push(c), i = a.next;
5106
+ r[2] && (c.date = r[2]), r[4] && (c.from = "agent"), bo.includes(o) && (c.state = r[1].toLowerCase() === "x" ? "resolved" : "open"), s.push(c), i = a.next;
5107
5107
  }
5108
5108
  return s;
5109
5109
  }
5110
- function No(n) {
5110
+ function Io(n) {
5111
5111
  const e = ["### Thread"];
5112
5112
  for (const t of n) {
5113
5113
  const s = t.state ? t.state === "resolved" : !0, i = t.date ? `${t.date} ` : "", r = t.from === "agent" ? "[agent] " : "";
@@ -5115,78 +5115,78 @@ function No(n) {
5115
5115
  }
5116
5116
  return e;
5117
5117
  }
5118
- const xs = {
5118
+ const Hs = {
5119
5119
  headingRe: /^#{2,3}\s+Thread\s*$/i,
5120
- parseEntries: Eo,
5121
- formatLines: No
5122
- }, te = y.preprocess(
5120
+ parseEntries: vo,
5121
+ formatLines: Io
5122
+ }, z = g.preprocess(
5123
5123
  (n) => typeof n == "string" ? { agent: n } : n,
5124
- y.object({
5125
- agent: y.enum(Pe),
5126
- model: y.string().optional(),
5127
- effort: y.string().optional()
5124
+ g.object({
5125
+ agent: g.enum(Pe),
5126
+ model: g.string().optional(),
5127
+ effort: g.string().optional()
5128
5128
  })
5129
- ), Z = y.string().regex(/^\d{4}-\d{2}-\d{2}$/, "expected YYYY-MM-DD"), vo = y.object({
5130
- status: y.enum(["idea", "planned", "in-progress", "review", "done", "dropped"]),
5131
- kind: y.enum(["feat", "fix", "chore", "docs", "refactor"]).optional(),
5132
- id: y.string().optional(),
5133
- idea: y.string().optional(),
5134
- agent: y.enum(Pe).optional(),
5135
- created: Z,
5136
- updated: Z.optional(),
5137
- tags: y.string().optional()
5138
- }), Io = y.object({
5139
- id: y.string().describe("Permanent plan ID, e.g. FEAT-24"),
5140
- title: y.string().describe('Human-readable plan name, e.g. "Plan storage architecture"'),
5141
- kind: y.enum(["feat", "fix", "chore", "docs", "refactor"]).describe("Plan kind matching Conventional Commits types"),
5142
- status: y.enum(["idea", "planned", "in-progress", "review", "done", "dropped"]).describe("Current lifecycle status"),
5143
- idea: y.string().optional().describe("IDEA-N backlink if this plan grew out of an idea"),
5144
- agent: y.enum(Pe).optional().describe("Per-plan agent override"),
5145
- created: Z.describe("Creation date (YYYY-MM-DD)"),
5146
- updated: Z.optional().describe("Last significant update date (YYYY-MM-DD)"),
5147
- audited: Z.optional().describe("Date of last successful convergence audit (YYYY-MM-DD)"),
5148
- "audited-hash": y.string().optional().describe("Content hash of the plan at last audit, used to detect edits regardless of mtime"),
5149
- tags: y.array(y.string()).optional().describe("Tagging categories")
5150
- }).passthrough(), $o = y.object({
5151
- id: y.string().describe("Permanent idea ID, e.g. IDEA-20"),
5152
- title: y.string().describe("Short idea headline (3-6 words)"),
5153
- kind: y.enum(["idea", "note"]).optional().describe('"note" for ideas that never need a plan; omitted means a plan-bearing idea'),
5154
- status: y.enum(["open", "done", "dropped"]).optional().describe("Manual lifecycle, valid only on notes — plan-bearing ideas carry no status")
5129
+ ), ee = g.string().regex(/^\d{4}-\d{2}-\d{2}$/, "expected YYYY-MM-DD"), Ao = g.object({
5130
+ status: g.enum(["idea", "planned", "in-progress", "review", "done", "dropped"]),
5131
+ kind: g.enum(["feat", "fix", "chore", "docs", "refactor"]).optional(),
5132
+ id: g.string().optional(),
5133
+ idea: g.string().optional(),
5134
+ agent: g.enum(Pe).optional(),
5135
+ created: ee,
5136
+ updated: ee.optional(),
5137
+ tags: g.string().optional()
5138
+ }), $o = g.object({
5139
+ id: g.string().describe("Permanent plan ID, e.g. FEAT-24"),
5140
+ title: g.string().describe('Human-readable plan name, e.g. "Plan storage architecture"'),
5141
+ kind: g.enum(["feat", "fix", "chore", "docs", "refactor"]).describe("Plan kind matching Conventional Commits types"),
5142
+ status: g.enum(["idea", "planned", "in-progress", "review", "done", "dropped"]).describe("Current lifecycle status"),
5143
+ idea: g.string().optional().describe("IDEA-N backlink if this plan grew out of an idea"),
5144
+ agent: g.enum(Pe).optional().describe("Per-plan agent override"),
5145
+ created: ee.describe("Creation date (YYYY-MM-DD)"),
5146
+ updated: ee.optional().describe("Last significant update date (YYYY-MM-DD)"),
5147
+ audited: ee.optional().describe("Date of last successful convergence audit (YYYY-MM-DD)"),
5148
+ "audited-hash": g.string().optional().describe("Content hash of the plan at last audit, used to detect edits regardless of mtime"),
5149
+ tags: g.array(g.string()).optional().describe("Tagging categories")
5150
+ }).passthrough(), To = g.object({
5151
+ id: g.string().describe("Permanent idea ID, e.g. IDEA-20"),
5152
+ title: g.string().describe("Short idea headline (3-6 words)"),
5153
+ kind: g.enum(["idea", "note"]).optional().describe('"note" for ideas that never need a plan; omitted means a plan-bearing idea'),
5154
+ status: g.enum(["open", "done", "dropped"]).optional().describe("Manual lifecycle, valid only on notes — plan-bearing ideas carry no status")
5155
5155
  }).passthrough().refine((n) => n.status === void 0 || n.kind === "note", {
5156
5156
  message: "status is only valid on ideas with kind: note",
5157
5157
  path: ["status"]
5158
- }), Ys = y.object({
5159
- id: y.string().describe("Permanent lifetime entity ID, e.g. IDEA-45 — never changes"),
5160
- title: y.string().describe("Human-readable entity name"),
5161
- type: y.enum(["feat", "fix", "chore", "docs", "refactor"]).optional().describe(
5158
+ }), Gs = g.object({
5159
+ id: g.string().describe("Permanent lifetime entity ID, e.g. IDEA-45 — never changes"),
5160
+ title: g.string().describe("Human-readable entity name"),
5161
+ type: g.enum(["feat", "fix", "chore", "docs", "refactor"]).optional().describe(
5162
5162
  "Work classification (Conventional Commits values) driving commit types and branch prefixes; usually set once a plan is drafted"
5163
5163
  ),
5164
- kind: y.enum(["note", "fix", "board", "ticket"]).optional().describe(
5164
+ kind: g.enum(["note", "fix", "board", "ticket"]).optional().describe(
5165
5165
  '"note" marks an entity that never grows phases; "fix" is a follow-up entity linked to a done/archived parent via `idea`; "board" decomposes into "ticket" children instead of phases; "ticket" is a full entity linked back to its board via `idea`; omitted for normal ideas'
5166
5166
  ),
5167
- status: y.enum(["idea", "planned", "in-progress", "review", "done", "dropped", "open"]).optional().describe(
5167
+ status: g.enum(["idea", "planned", "in-progress", "review", "done", "dropped", "open"]).optional().describe(
5168
5168
  "Stored override, no longer the source of truth: most lifecycle states derive from phases/branch/PR. Only dropped, a planless idea/note being closed, or the offline fallback need this set."
5169
5169
  ),
5170
- agent: y.enum(Pe).optional().describe("Per-entity agent override"),
5171
- created: Z.describe("Creation date (YYYY-MM-DD)"),
5172
- updated: Z.optional().describe("Last significant update date (YYYY-MM-DD)"),
5173
- audited: Z.optional().describe("Date of last successful convergence audit (YYYY-MM-DD)"),
5174
- "audited-hash": y.string().optional().describe(
5170
+ agent: g.enum(Pe).optional().describe("Per-entity agent override"),
5171
+ created: ee.describe("Creation date (YYYY-MM-DD)"),
5172
+ updated: ee.optional().describe("Last significant update date (YYYY-MM-DD)"),
5173
+ audited: ee.optional().describe("Date of last successful convergence audit (YYYY-MM-DD)"),
5174
+ "audited-hash": g.string().optional().describe(
5175
5175
  "Content hash of the entity at last audit, used to detect edits regardless of mtime"
5176
5176
  ),
5177
- released: y.string().optional().describe(
5177
+ released: g.string().optional().describe(
5178
5178
  "Version tag (e.g. v0.13.1) that first shipped this idea, stamped from the release train"
5179
5179
  ),
5180
- tags: y.array(y.string()).optional().describe("Tagging categories"),
5181
- idea: y.string().optional().describe("IDEA-N backlink to the parent this fix addresses; required when kind: fix"),
5182
- subject: y.string().optional().describe('Subject group name; absent renders as the virtual "No subject" group'),
5183
- order: y.number().int().optional().describe("Run order; absent means unordered, sorting after ordered entries"),
5184
- issueSource: y.string().optional().describe(
5180
+ tags: g.array(g.string()).optional().describe("Tagging categories"),
5181
+ idea: g.string().optional().describe("IDEA-N backlink to the parent this fix addresses; required when kind: fix"),
5182
+ subject: g.string().optional().describe('Subject group name; absent renders as the virtual "No subject" group'),
5183
+ order: g.number().int().optional().describe("Run order; absent means unordered, sorting after ordered entries"),
5184
+ issueSource: g.string().optional().describe(
5185
5185
  "sourceKind:sourceKey of the Issue (IDEA-192) this entity was promoted from, if any"
5186
5186
  )
5187
- }).passthrough(), Ao = new Set(
5188
- Object.keys(Ys.shape)
5189
- ), Gs = Ys.refine(
5187
+ }).passthrough(), Oo = new Set(
5188
+ Object.keys(Gs.shape)
5189
+ ), Ys = Gs.refine(
5190
5190
  (n) => n.kind !== "note" || n.status === void 0 || ["open", "done", "dropped"].includes(n.status),
5191
5191
  {
5192
5192
  message: "a note entity must use status open, done, or dropped",
@@ -5201,66 +5201,85 @@ const xs = {
5201
5201
  }).refine((n) => n.kind !== "ticket" || n.idea !== void 0, {
5202
5202
  message: "a kind: ticket entity requires an idea: link to its board",
5203
5203
  path: ["idea"]
5204
- }), To = y.object({
5205
- name: y.string(),
5206
- cmd: y.string(),
5207
- port: y.number().int().positive().optional(),
5208
- healthcheck: y.string().optional()
5209
- }), Oo = y.object({
5210
- name: y.string(),
5211
- cmd: y.string(),
5212
- fixCmd: y.string().optional()
5213
- }), Co = y.object({
5214
- repo: y.string(),
5215
- branch: y.string().optional(),
5216
- releasePlease: y.boolean().optional()
5217
- }), _o = y.object({
5218
- services: y.array(To).optional(),
5219
- checks: y.array(Oo).optional(),
5220
- ci: Co.optional()
5221
- }), Lo = y.object({
5222
- version: y.number().int().describe("Corpus format version (see CORPUS_FORMAT_VERSION), not the package version"),
5223
- projectName: y.string(),
5224
- initializedAt: y.string(),
5225
- nextId: y.object({
5204
+ }), Co = g.object({
5205
+ name: g.string(),
5206
+ cmd: g.string(),
5207
+ port: g.number().int().positive().optional(),
5208
+ healthcheck: g.string().optional()
5209
+ }), _o = g.object({
5210
+ name: g.string(),
5211
+ cmd: g.string(),
5212
+ fixCmd: g.string().optional()
5213
+ }), Lo = g.object({
5214
+ repo: g.string(),
5215
+ branch: g.string().optional(),
5216
+ releasePlease: g.boolean().optional()
5217
+ }), Ro = g.object({
5218
+ services: g.array(Co).optional(),
5219
+ checks: g.array(_o).optional(),
5220
+ ci: Lo.optional()
5221
+ }), Po = g.object({
5222
+ from: g.string(),
5223
+ to: g.string()
5224
+ }), Mo = g.object({
5225
+ name: g.string(),
5226
+ prompt: g.string()
5227
+ }), Do = g.object({
5228
+ ceiling: g.number().optional(),
5229
+ floor: g.number().optional(),
5230
+ window: Po.optional(),
5231
+ roots: g.array(g.string()).optional(),
5232
+ maxChunks: g.number().int().positive().optional(),
5233
+ threshold: g.number().min(0).max(100).optional(),
5234
+ checks: g.record(g.enum(Ei), g.boolean()).optional(),
5235
+ customChecks: g.array(Mo).optional(),
5236
+ maxTurns: g.number().int().positive().optional(),
5237
+ maxCostUsd: g.number().positive().optional()
5238
+ }), jo = g.object({
5239
+ version: g.number().int().describe("Corpus format version (see CORPUS_FORMAT_VERSION), not the package version"),
5240
+ projectName: g.string(),
5241
+ initializedAt: g.string(),
5242
+ nextId: g.object({
5226
5243
  // idea: unified-entity counter minting lifetime IDEA-N ids. ticket: board/ticket
5227
5244
  // counter (IDEA-201) minting TICKET-N ids. The rest are legacy per-kind counters.
5228
- idea: y.number().optional(),
5229
- ticket: y.number().optional(),
5230
- feat: y.number().optional(),
5231
- fix: y.number().optional(),
5232
- chore: y.number().optional(),
5233
- docs: y.number().optional(),
5234
- refactor: y.number().optional()
5245
+ idea: g.number().optional(),
5246
+ ticket: g.number().optional(),
5247
+ feat: g.number().optional(),
5248
+ fix: g.number().optional(),
5249
+ chore: g.number().optional(),
5250
+ docs: g.number().optional(),
5251
+ refactor: g.number().optional()
5235
5252
  }).optional(),
5236
- defaultAgent: y.enum(Pe).optional(),
5237
- defaultAgents: y.object({
5238
- phase: te,
5239
- planDraft: te,
5240
- ideaExtend: te,
5241
- commitSuggest: te,
5242
- feedback: te,
5243
- codeReview: te,
5244
- deskDiscovery: te
5253
+ defaultAgent: g.enum(Pe).optional(),
5254
+ defaultAgents: g.object({
5255
+ phase: z,
5256
+ planDraft: z,
5257
+ ideaExtend: z,
5258
+ commitSuggest: z,
5259
+ feedback: z,
5260
+ codeReview: z,
5261
+ deskDiscovery: z,
5262
+ nightShift: z
5245
5263
  }).optional(),
5246
- desk: _o.optional()
5247
- }), Ro = y.object({
5248
- id: y.string(),
5249
- kind: y.enum(["completed", "reply"]),
5250
- entityId: y.string(),
5251
- entityTitle: y.string(),
5252
- text: y.string(),
5253
- date: y.string(),
5254
- read: y.boolean(),
5255
- outcome: y.enum(["done", "error"]).optional()
5256
- }), Pn = /^##\s+(.+?)\s*$/, Po = /^\*\*([A-Za-z][A-Za-z-]*):\*\*\s*(.*)$/, Mo = /^#{2,3}\s+/;
5264
+ desk: Ro.optional(),
5265
+ night: Do.optional()
5266
+ }), Bo = g.object({
5267
+ id: g.string(),
5268
+ kind: g.enum(["completed", "reply"]),
5269
+ entityId: g.string(),
5270
+ entityTitle: g.string(),
5271
+ text: g.string(),
5272
+ date: g.string(),
5273
+ read: g.boolean(),
5274
+ outcome: g.enum(["done", "error"]).optional()
5275
+ }), Pn = /^##\s+(.+?)\s*$/, Fo = /^\*\*([A-Za-z][A-Za-z-]*):\*\*\s*(.*)$/, Ko = /^#{2,3}\s+/;
5257
5276
  function st(n, e) {
5258
5277
  const t = n.split(`
5259
5278
  `), s = t.findIndex((a) => e.headingRe.test(a));
5260
5279
  if (s === -1) return { body: n, entries: [] };
5261
5280
  let i = t.length;
5262
5281
  for (let a = s + 1; a < t.length; a++)
5263
- if (Mo.test(t[a])) {
5282
+ if (Ko.test(t[a])) {
5264
5283
  i = a;
5265
5284
  break;
5266
5285
  }
@@ -5273,7 +5292,7 @@ const Mn = {
5273
5292
  log: Ue,
5274
5293
  clarifications: an,
5275
5294
  notes: cn,
5276
- review: So
5295
+ review: No
5277
5296
  };
5278
5297
  function ln(n) {
5279
5298
  const e = {
@@ -5290,7 +5309,7 @@ function ln(n) {
5290
5309
  }
5291
5310
  return { body: t, ...e };
5292
5311
  }
5293
- function Do(n) {
5312
+ function qo(n) {
5294
5313
  const e = n.split(`
5295
5314
  `), t = [];
5296
5315
  for (let i = 0; i < e.length; i++)
@@ -5302,21 +5321,21 @@ function Do(n) {
5302
5321
  for (; l < c.length && c[l].trim() === ""; ) l++;
5303
5322
  const f = {};
5304
5323
  for (; l < c.length; ) {
5305
- const b = c[l].match(Po);
5324
+ const b = c[l].match(Fo);
5306
5325
  if (!b) break;
5307
5326
  f[b[1].toLowerCase()] = b[2].trim(), l++;
5308
5327
  }
5309
5328
  for (; l < c.length && c[l].trim() === ""; ) l++;
5310
5329
  const u = c.slice(l).join(`
5311
- `).trim(), { body: h, phases: p, log: g, clarifications: d, notes: m, review: w } = ln(u);
5312
- s.push({ title: a, fields: f, body: h, phases: p, log: g, clarifications: d, notes: m, review: w });
5330
+ `).trim(), { body: h, phases: p, log: y, clarifications: d, notes: m, review: w } = ln(u);
5331
+ s.push({ title: a, fields: f, body: h, phases: p, log: y, clarifications: d, notes: m, review: w });
5313
5332
  }
5314
5333
  return s;
5315
5334
  }
5316
- function Yc(n) {
5335
+ function zc(n) {
5317
5336
  const e = [], t = [];
5318
- for (const s of Do(n)) {
5319
- const i = vo.safeParse(s.fields);
5337
+ for (const s of qo(n)) {
5338
+ const i = Ao.safeParse(s.fields);
5320
5339
  if (!i.success) {
5321
5340
  t.push({
5322
5341
  title: s.title,
@@ -5345,9 +5364,9 @@ function Yc(n) {
5345
5364
  }
5346
5365
  return { entries: e, warnings: t };
5347
5366
  }
5348
- const jo = /^---\s*\r?\n([\s\S]*?)\r?\n---\s*(?:\r?\n)?/;
5367
+ const Uo = /^---\s*\r?\n([\s\S]*?)\r?\n---\s*(?:\r?\n)?/;
5349
5368
  function un(n, e) {
5350
- const t = [], s = n.match(jo);
5369
+ const t = [], s = n.match(Uo);
5351
5370
  if (!s)
5352
5371
  return { data: null, body: n.trim(), warnings: t };
5353
5372
  const i = s[1], r = n.slice(s[0].length).trim();
@@ -5375,7 +5394,7 @@ function un(n, e) {
5375
5394
  }
5376
5395
  return { data: a.data, body: r, warnings: t };
5377
5396
  }
5378
- function Bo(n, e) {
5397
+ function xo(n, e) {
5379
5398
  const t = Object.fromEntries(
5380
5399
  Object.entries(n).filter(([s]) => !e.has(s))
5381
5400
  );
@@ -5386,7 +5405,7 @@ function Vs(n) {
5386
5405
  data: t,
5387
5406
  body: s,
5388
5407
  warnings: i
5389
- } = un(n, Gs);
5408
+ } = un(n, Ys);
5390
5409
  if (e.push(...i), !t)
5391
5410
  return { entries: [], warnings: e };
5392
5411
  const {
@@ -5396,12 +5415,12 @@ function Vs(n) {
5396
5415
  clarifications: c,
5397
5416
  notes: l,
5398
5417
  review: f
5399
- } = ln(s), { body: u, entries: h } = st(r, Hs), { body: p, entries: g } = st(u, xs), d = [...g, ...Di(a, c, l, f)];
5418
+ } = ln(s), { body: u, entries: h } = st(r, xs), { body: p, entries: y } = st(u, Hs), d = [...y, ...Bi(a, c, l, f)];
5400
5419
  t.kind === "note" && o.length > 0 && e.push({
5401
5420
  title: t.title,
5402
5421
  message: "note entities must not carry a Phases section — kept, but fix the file"
5403
5422
  });
5404
- const m = Bo(t, Ao);
5423
+ const m = xo(t, Oo);
5405
5424
  return { entries: [{
5406
5425
  id: t.id,
5407
5426
  title: t.title,
@@ -5426,12 +5445,12 @@ function Vs(n) {
5426
5445
  ...m && { unknownFrontmatter: m }
5427
5446
  }], warnings: e };
5428
5447
  }
5429
- function Gc(n) {
5448
+ function Qc(n) {
5430
5449
  const e = [], {
5431
5450
  data: t,
5432
5451
  body: s,
5433
5452
  warnings: i
5434
- } = un(n, Io);
5453
+ } = un(n, $o);
5435
5454
  if (e.push(...i), !t)
5436
5455
  return { entries: [], warnings: e };
5437
5456
  const { body: r, phases: o, log: a, clarifications: c, notes: l, review: f } = ln(s);
@@ -5455,12 +5474,12 @@ function Gc(n) {
5455
5474
  review: f
5456
5475
  }], warnings: e };
5457
5476
  }
5458
- function Vc(n) {
5477
+ function Xc(n) {
5459
5478
  const {
5460
5479
  data: e,
5461
5480
  body: t,
5462
5481
  warnings: s
5463
- } = un(n, $o);
5482
+ } = un(n, To);
5464
5483
  if (!e)
5465
5484
  return { entries: [], warnings: s };
5466
5485
  const { body: i, entries: r } = st(t, Ue);
@@ -5473,17 +5492,17 @@ function Vc(n) {
5473
5492
  ...r.length > 0 && { log: r }
5474
5493
  }], warnings: s };
5475
5494
  }
5476
- const Fo = /^(IDEA-\d+):\s*/, Ko = /\n---+\n/;
5477
- function Jc(n) {
5478
- return n.split(Ko).filter(Boolean).map((t) => {
5495
+ const Ho = /^(IDEA-\d+):\s*/, Go = /\n---+\n/;
5496
+ function Zc(n) {
5497
+ return n.split(Go).filter(Boolean).map((t) => {
5479
5498
  var c;
5480
5499
  const s = t.match(/^#{1,3}\s+(.+)/m), i = s ? s[1].trim() : ((c = t.trim().split(`
5481
- `)[0]) == null ? void 0 : c.trim()) ?? "Untitled", r = i.match(Fo), o = (r == null ? void 0 : r[1]) ?? null, a = o ? i.slice(r[0].length) : i;
5500
+ `)[0]) == null ? void 0 : c.trim()) ?? "Untitled", r = i.match(Ho), o = (r == null ? void 0 : r[1]) ?? null, a = o ? i.slice(r[0].length) : i;
5482
5501
  return { id: o, title: a, body: t.trim() };
5483
5502
  });
5484
5503
  }
5485
5504
  const Dn = 40;
5486
- function qo(n, e = []) {
5505
+ function Yo(n, e = []) {
5487
5506
  const t = [];
5488
5507
  for (const s of n)
5489
5508
  if (!s.archived && (s.subject && !e.includes(s.subject) && t.push({
@@ -5504,7 +5523,7 @@ function qo(n, e = []) {
5504
5523
  }
5505
5524
  return t;
5506
5525
  }
5507
- function Uo(n) {
5526
+ function Vo(n) {
5508
5527
  const e = /* @__PURE__ */ new Map(), t = [];
5509
5528
  for (const s of n.split(`
5510
5529
  `)) {
@@ -5521,14 +5540,14 @@ function Uo(n) {
5521
5540
  }
5522
5541
  return t.map((s) => e.get(s));
5523
5542
  }
5524
- function Wc(n) {
5543
+ function el(n) {
5525
5544
  const e = [];
5526
5545
  for (const t of n.split(`
5527
5546
  `)) {
5528
5547
  const s = t.trim();
5529
5548
  if (s)
5530
5549
  try {
5531
- const i = Ro.safeParse(JSON.parse(s));
5550
+ const i = Bo.safeParse(JSON.parse(s));
5532
5551
  i.success && e.push(i.data);
5533
5552
  } catch {
5534
5553
  }
@@ -5536,7 +5555,7 @@ function Wc(n) {
5536
5555
  return e;
5537
5556
  }
5538
5557
  const Js = /^-\s+(\d{4}-\d{2}-\d{2}):\s+(.+?)\s+—\s+(.*)$/;
5539
- function zc(n) {
5558
+ function tl(n) {
5540
5559
  const e = [];
5541
5560
  for (const t of n.split(`
5542
5561
  `)) {
@@ -5546,7 +5565,7 @@ function zc(n) {
5546
5565
  return e;
5547
5566
  }
5548
5567
  const Dt = " — ";
5549
- function Ho(n) {
5568
+ function Jo(n) {
5550
5569
  return n.split(`
5551
5570
  `).map((e) => e.trim()).filter((e) => e.length > 0).map((e) => {
5552
5571
  const t = e.indexOf(Dt);
@@ -5556,12 +5575,12 @@ function Ho(n) {
5556
5575
  };
5557
5576
  });
5558
5577
  }
5559
- function Qc(n) {
5578
+ function nl(n) {
5560
5579
  return n.length === 0 ? "" : `${n.map((e) => `${e.id}${Dt}${e.title}`).join(`
5561
5580
  `)}
5562
5581
  `;
5563
5582
  }
5564
- async function xo(n) {
5583
+ async function Wo(n) {
5565
5584
  try {
5566
5585
  return await ct(n);
5567
5586
  } catch {
@@ -5575,20 +5594,20 @@ async function Ws(n) {
5575
5594
  return "";
5576
5595
  }
5577
5596
  }
5578
- async function Yo(n) {
5579
- const e = await Ws($(n, "..", "run-order.md"));
5580
- return new Map(Ho(e).map((t, s) => [t.id, s + 1]));
5597
+ async function zo(n) {
5598
+ const e = await Ws(A(n, "..", "run-order.md"));
5599
+ return new Map(Jo(e).map((t, s) => [t.id, s + 1]));
5581
5600
  }
5582
- async function Ie(n) {
5601
+ async function Ae(n) {
5583
5602
  const e = [], t = [];
5584
5603
  let s = 0;
5585
- const i = await Yo(n);
5586
- for (const r of [n, $(n, "archive")]) {
5587
- const o = r !== n, a = (await xo(r)).filter((l) => l.endsWith(".md") && l !== "index.md");
5604
+ const i = await zo(n);
5605
+ for (const r of [n, A(n, "archive")]) {
5606
+ const o = r !== n, a = (await Wo(r)).filter((l) => l.endsWith(".md") && l !== "index.md");
5588
5607
  s += a.length;
5589
5608
  const c = await Promise.all(
5590
5609
  a.map(async (l) => {
5591
- const f = await Ws($(r, l));
5610
+ const f = await Ws(A(r, l));
5592
5611
  return f ? Vs(f) : { warnings: [{ title: l, message: "Could not read entity file" }] };
5593
5612
  })
5594
5613
  );
@@ -5605,13 +5624,13 @@ async function Ie(n) {
5605
5624
  return { entries: e, warnings: t, fileCount: s };
5606
5625
  }
5607
5626
  async function fn(n, e) {
5608
- const { entries: t, warnings: s } = await Ie(n), i = $(n, "..", ".."), [r, o] = await Promise.all([
5627
+ const { entries: t, warnings: s } = await Ae(n), i = A(n, "..", ".."), [r, o] = await Promise.all([
5609
5628
  ts(i, e),
5610
5629
  Vn(i)
5611
5630
  ]);
5612
5631
  return { entries: t, warnings: s, prs: r, resolved: r !== void 0, mainActivityIds: o };
5613
5632
  }
5614
- async function Xc(n) {
5633
+ async function sl(n) {
5615
5634
  const { entries: e, warnings: t, prs: s, resolved: i, mainActivityIds: r } = await fn(n), o = e.map((c) => ({
5616
5635
  ...c,
5617
5636
  status: lt(c, s == null ? void 0 : s.get(c.id), i, r.has(c.id))
@@ -5619,39 +5638,39 @@ async function Xc(n) {
5619
5638
  return { entries: o.map((c) => {
5620
5639
  if (c.kind !== "board" || c.archived || c.status === "done" || c.status === "dropped") return c;
5621
5640
  const l = o.filter((f) => f.kind === "ticket" && f.idea === c.id).map((f) => f.status ?? "idea");
5622
- return { ...c, status: Hn(l) };
5641
+ return { ...c, status: xn(l) };
5623
5642
  }), warnings: t };
5624
5643
  }
5625
- async function Zc(n, e) {
5644
+ async function il(n, e) {
5626
5645
  const { entries: t, warnings: s, prs: i, resolved: r, mainActivityIds: o } = await fn(
5627
5646
  n,
5628
5647
  e
5629
- ), a = t.filter((l) => l.kind !== "note").map((l) => Yn(l, i == null ? void 0 : i.get(l.id), r, o.has(l.id)));
5648
+ ), a = t.filter((l) => l.kind !== "note").map((l) => Gn(l, i == null ? void 0 : i.get(l.id), r, o.has(l.id)));
5630
5649
  return { entries: a.map((l) => {
5631
5650
  if (l.entityKind !== "board" || l.archived || l.status === "done" || l.status === "dropped")
5632
5651
  return l;
5633
5652
  const f = a.filter((u) => u.entityKind === "ticket" && u.idea === l.id).map((u) => u.status);
5634
- return { ...l, status: Hn(f) };
5653
+ return { ...l, status: xn(f) };
5635
5654
  }), warnings: s, resolved: r };
5636
5655
  }
5637
- async function el(n) {
5656
+ async function rl(n) {
5638
5657
  const { entries: e, prs: t, resolved: s } = await fn(n);
5639
5658
  return {
5640
5659
  entries: e.flatMap((i) => {
5641
5660
  const r = t == null ? void 0 : t.get(i.id);
5642
- return r && Mi(i, r) ? [{ id: i.id, title: i.title, pr: r }] : [];
5661
+ return r && ji(i, r) ? [{ id: i.id, title: i.title, pr: r }] : [];
5643
5662
  }),
5644
5663
  resolved: s
5645
5664
  };
5646
5665
  }
5647
- async function tl(n) {
5648
- const { entries: e, warnings: t } = await Ie(n);
5666
+ async function ol(n) {
5667
+ const { entries: e, warnings: t } = await Ae(n);
5649
5668
  return {
5650
- entries: e.filter((s) => s.kind === "note").map(Ki),
5669
+ entries: e.filter((s) => s.kind === "note").map(Ui),
5651
5670
  warnings: t
5652
5671
  };
5653
5672
  }
5654
- const Go = [
5673
+ const Qo = [
5655
5674
  {
5656
5675
  id: "frontmatter-schema",
5657
5676
  category: "metadata",
@@ -5694,6 +5713,12 @@ const Go = [
5694
5713
  severity: "error",
5695
5714
  summary: "A kind: note entity carries a Phases section; notes never grow phases."
5696
5715
  },
5716
+ {
5717
+ id: "duplicate-phases-section",
5718
+ category: "structural",
5719
+ severity: "error",
5720
+ summary: "A file carries more than one Phases heading — a redraft appended instead of replacing the existing list in place."
5721
+ },
5697
5722
  {
5698
5723
  id: "archive-placement",
5699
5724
  category: "structural",
@@ -5706,11 +5731,11 @@ const Go = [
5706
5731
  severity: "warning",
5707
5732
  summary: "A [[IDEA-N]] wikilink targets an id that no entity in the corpus defines."
5708
5733
  }
5709
- ], Vo = Object.fromEntries(
5710
- Go.map((n) => [n.id, n])
5734
+ ], Xo = Object.fromEntries(
5735
+ Qo.map((n) => [n.id, n])
5711
5736
  );
5712
5737
  function it(n) {
5713
- return Vo[n.rule].severity;
5738
+ return Xo[n.rule].severity;
5714
5739
  }
5715
5740
  const jn = { error: 0, warning: 1 };
5716
5741
  function zs(n) {
@@ -5718,7 +5743,7 @@ function zs(n) {
5718
5743
  (e, t) => e.file.localeCompare(t.file) || e.line - t.line || jn[it(e)] - jn[it(t)] || e.rule.localeCompare(t.rule)
5719
5744
  );
5720
5745
  }
5721
- function nl(n) {
5746
+ function al(n) {
5722
5747
  const e = zs(n).map((t) => ({
5723
5748
  ...t,
5724
5749
  severity: it(t)
@@ -5729,7 +5754,7 @@ function nl(n) {
5729
5754
  warningCount: e.filter((t) => t.severity === "warning").length
5730
5755
  };
5731
5756
  }
5732
- function sl(n) {
5757
+ function cl(n) {
5733
5758
  const e = zs(n);
5734
5759
  let t = 0, s = 0;
5735
5760
  const i = e.map((o) => {
@@ -5743,11 +5768,11 @@ function sl(n) {
5743
5768
  warningCount: s
5744
5769
  };
5745
5770
  }
5746
- const ee = 1;
5747
- class Jo extends Error {
5771
+ const te = 1;
5772
+ class Zo extends Error {
5748
5773
  constructor(e) {
5749
5774
  super(
5750
- `This corpus is in format version ${e}, newer than the format version ${ee} this paper-camp understands. Writes are refused so a field this version doesn’t recognise is never dropped — upgrade paper-camp to edit this corpus.`
5775
+ `This corpus is in format version ${e}, newer than the format version ${te} this paper-camp understands. Writes are refused so a field this version doesn’t recognise is never dropped — upgrade paper-camp to edit this corpus.`
5751
5776
  ), this.name = "CorpusTooNewError";
5752
5777
  }
5753
5778
  }
@@ -5769,19 +5794,19 @@ function Xs(n) {
5769
5794
  const e = n == null ? void 0 : n.version;
5770
5795
  return typeof e == "number" ? e : null;
5771
5796
  }
5772
- async function il(n) {
5797
+ async function ll(n) {
5773
5798
  const e = Xs(await Qs(n));
5774
- if (e !== null && e > ee)
5775
- throw new Jo(e);
5799
+ if (e !== null && e > te)
5800
+ throw new Zo(e);
5776
5801
  }
5777
- async function rl(n) {
5802
+ async function ul(n) {
5778
5803
  const e = await Qs(n);
5779
5804
  if (!e) return null;
5780
5805
  const t = Xs(e);
5781
- return t !== null && t >= ee ? null : (e.version = ee, await B(n, `${JSON.stringify(e, null, 2)}
5782
- `, "utf-8"), { from: t, to: ee });
5806
+ return t !== null && t >= te ? null : (e.version = te, await B(n, `${JSON.stringify(e, null, 2)}
5807
+ `, "utf-8"), { from: t, to: te });
5783
5808
  }
5784
- const Zs = /^---\s*\r?\n([\s\S]*?)\r?\n---\s*(?:\r?\n)?/, Wo = 2;
5809
+ const Zs = /^---\s*\r?\n([\s\S]*?)\r?\n---\s*(?:\r?\n)?/, ea = 2;
5785
5810
  function dn(n) {
5786
5811
  const e = n.content.match(Zs);
5787
5812
  if (!e) return null;
@@ -5796,7 +5821,7 @@ function dn(n) {
5796
5821
  function ei(n, e) {
5797
5822
  const t = new RegExp(`^\\s*${e}:`), s = n.split(`
5798
5823
  `).findIndex((i) => t.test(i));
5799
- return s === -1 ? 1 : Wo + s;
5824
+ return s === -1 ? 1 : ea + s;
5800
5825
  }
5801
5826
  function hn(n) {
5802
5827
  const e = dn(n);
@@ -5810,7 +5835,7 @@ function ti(n) {
5810
5835
  function re(n, e, t, s) {
5811
5836
  return { file: n.path, line: e, rule: t, message: s };
5812
5837
  }
5813
- const zo = ({ files: n }) => n.flatMap((e) => {
5838
+ const ta = ({ files: n }) => n.flatMap((e) => {
5814
5839
  const t = e.content.match(Zs);
5815
5840
  if (!t)
5816
5841
  return [re(e, 1, "frontmatter-schema", "missing YAML frontmatter block")];
@@ -5822,12 +5847,12 @@ const zo = ({ files: n }) => n.flatMap((e) => {
5822
5847
  }
5823
5848
  if (typeof s != "object" || s === null || Array.isArray(s))
5824
5849
  return [re(e, 1, "frontmatter-schema", "frontmatter is not a key/value mapping")];
5825
- const i = Gs.safeParse(s);
5850
+ const i = Ys.safeParse(s);
5826
5851
  return i.success ? [] : i.error.issues.map((r) => {
5827
5852
  const o = String(r.path[0] ?? ""), a = r.path.length > 0 ? `${r.path.join(".")}: ${r.message}` : r.message;
5828
5853
  return re(e, o ? ei(t[1], o) : 1, "frontmatter-schema", a);
5829
5854
  });
5830
- }), Qo = ({ files: n }) => n.flatMap((e) => {
5855
+ }), na = ({ files: n }) => n.flatMap((e) => {
5831
5856
  var s, i;
5832
5857
  const t = (i = (s = dn(e)) == null ? void 0 : s.data) == null ? void 0 : i.id;
5833
5858
  return typeof t != "string" || t === e.id ? [] : [
@@ -5838,7 +5863,7 @@ const zo = ({ files: n }) => n.flatMap((e) => {
5838
5863
  `frontmatter id "${t}" does not match file name ${e.id}.md`
5839
5864
  )
5840
5865
  ];
5841
- }), Xo = ({ files: n }) => {
5866
+ }), sa = ({ files: n }) => {
5842
5867
  const e = /* @__PURE__ */ new Map();
5843
5868
  for (const s of n) {
5844
5869
  const i = ti(s), r = e.get(i);
@@ -5859,7 +5884,7 @@ const zo = ({ files: n }) => n.flatMap((e) => {
5859
5884
  );
5860
5885
  }
5861
5886
  return t;
5862
- }, Zo = ({ files: n, config: e }) => {
5887
+ }, ia = ({ files: n, config: e }) => {
5863
5888
  var s;
5864
5889
  const t = (s = e == null ? void 0 : e.nextId) == null ? void 0 : s.idea;
5865
5890
  return t == null ? [] : n.flatMap((i) => {
@@ -5873,25 +5898,25 @@ const zo = ({ files: n }) => n.flatMap((e) => {
5873
5898
  )
5874
5899
  ] : [];
5875
5900
  });
5876
- }, ea = ({ config: n }) => {
5901
+ }, ra = ({ config: n }) => {
5877
5902
  const e = n == null ? void 0 : n.version;
5878
- return typeof e != "number" || e <= ee ? [] : [
5903
+ return typeof e != "number" || e <= te ? [] : [
5879
5904
  {
5880
5905
  file: "papercamp/config.json",
5881
5906
  line: 1,
5882
5907
  rule: "corpus-format-too-new",
5883
- message: `config.version ${e} is newer than the format version ${ee} this paper-camp understands; writes are refused until it's upgraded`
5908
+ message: `config.version ${e} is newer than the format version ${te} this paper-camp understands; writes are refused until it's upgraded`
5884
5909
  }
5885
5910
  ];
5886
- }, ta = [
5887
- zo,
5888
- Qo,
5889
- Xo,
5890
- Zo,
5891
- ea
5892
- ], na = /^---\s*\r?\n([\s\S]*?)\r?\n---\s*(?:\r?\n)?/, sa = /^#{1,6}\s+(.+?)\s*$/, ia = /^[-*]\s+\[[ xX]\]\s+(.*)$/, ra = /^(phases|fixes)$/i, oa = /^#{1,6}\s+Phases\s*$/i, aa = /^(?:\d{4}-\d{2}-\d{2}\s+)?\[(?:log|clarification|review|note|decision|question|chat)\]/, ca = /^\[(?:phase:\d+|body)\]/, la = /\[\[\s*((?:IDEA|TICKET)-\d+)(?:\s*\|[^\]]*)?\s*\]\]/g, ua = /* @__PURE__ */ new Set(["idea", "planned", "in-progress", "review", "open"]), fa = /* @__PURE__ */ new Set(["done", "dropped"]);
5911
+ }, oa = [
5912
+ ta,
5913
+ na,
5914
+ sa,
5915
+ ia,
5916
+ ra
5917
+ ], aa = /^---\s*\r?\n([\s\S]*?)\r?\n---\s*(?:\r?\n)?/, ca = /^#{1,6}\s+(.+?)\s*$/, la = /^[-*]\s+\[[ xX]\]\s+(.*)$/, ua = /^(phases|fixes)$/i, ni = /^#{1,6}\s+Phases\s*$/i, fa = /^(?:\d{4}-\d{2}-\d{2}\s+)?\[(?:log|clarification|review|note|decision|question|chat)\]/, da = /^\[(?:phase:\d+|body)\]/, ha = /\[\[\s*((?:IDEA|TICKET)-\d+)(?:\s*\|[^\]]*)?\s*\]\]/g, pa = /* @__PURE__ */ new Set(["idea", "planned", "in-progress", "review", "open"]), ma = /* @__PURE__ */ new Set(["done", "dropped"]);
5893
5918
  function pn(n) {
5894
- const e = n.match(na);
5919
+ const e = n.match(aa);
5895
5920
  if (!e) return null;
5896
5921
  try {
5897
5922
  const t = wt(e[1]);
@@ -5901,30 +5926,30 @@ function pn(n) {
5901
5926
  }
5902
5927
  return null;
5903
5928
  }
5904
- function da(n, e) {
5929
+ function ga(n, e) {
5905
5930
  const t = n.split(`
5906
5931
  `).findIndex((s) => e.test(s));
5907
5932
  return t === -1 ? 1 : t + 1;
5908
5933
  }
5909
- function Re(n, e, t, s) {
5934
+ function be(n, e, t, s) {
5910
5935
  return { file: n.path, line: e, rule: t, message: s };
5911
5936
  }
5912
- const ha = ({ files: n }) => n.flatMap((e) => {
5937
+ const ya = ({ files: n }) => n.flatMap((e) => {
5913
5938
  const t = e.content.split(`
5914
5939
  `), s = [];
5915
5940
  let i = !1;
5916
5941
  for (let r = 0; r < t.length; r++) {
5917
- const o = t[r].match(sa);
5942
+ const o = t[r].match(ca);
5918
5943
  if (o) {
5919
- i = ra.test(o[1].trim());
5944
+ i = ua.test(o[1].trim());
5920
5945
  continue;
5921
5946
  }
5922
5947
  if (i) continue;
5923
- const a = t[r].match(ia);
5948
+ const a = t[r].match(la);
5924
5949
  if (!a) continue;
5925
5950
  const c = a[1].trim();
5926
- aa.test(c) || ca.test(c) || s.push(
5927
- Re(
5951
+ fa.test(c) || da.test(c) || s.push(
5952
+ be(
5928
5953
  e,
5929
5954
  r + 1,
5930
5955
  "phases-list-split",
@@ -5933,33 +5958,41 @@ const ha = ({ files: n }) => n.flatMap((e) => {
5933
5958
  );
5934
5959
  }
5935
5960
  return s;
5936
- }), pa = ({ files: n }) => n.flatMap((e) => {
5961
+ }), wa = ({ files: n }) => n.flatMap((e) => {
5937
5962
  var i;
5938
5963
  if (((i = pn(e.content)) == null ? void 0 : i.kind) !== "note") return [];
5939
5964
  const s = e.content.split(`
5940
- `).findIndex((r) => oa.test(r));
5941
- return s === -1 ? [] : [Re(e, s + 1, "note-has-phases", "a kind: note entity carries a Phases section")];
5942
- }), ma = ({ files: n }) => n.flatMap((e) => {
5965
+ `).findIndex((r) => ni.test(r));
5966
+ return s === -1 ? [] : [be(e, s + 1, "note-has-phases", "a kind: note entity carries a Phases section")];
5967
+ }), ba = ({ files: n }) => n.flatMap((e) => e.content.split(`
5968
+ `).flatMap((i, r) => ni.test(i) ? [r] : []).slice(1).map(
5969
+ (i) => be(
5970
+ e,
5971
+ i + 1,
5972
+ "duplicate-phases-section",
5973
+ "a second Phases heading exists — a redraft must replace the existing list in place, not append a new one"
5974
+ )
5975
+ )), ka = ({ files: n }) => n.flatMap((e) => {
5943
5976
  var i;
5944
5977
  const t = (i = pn(e.content)) == null ? void 0 : i.status;
5945
5978
  if (typeof t != "string") return [];
5946
- const s = da(e.content, /^status:/);
5947
- return e.archived && ua.has(t) ? [
5948
- Re(
5979
+ const s = ga(e.content, /^status:/);
5980
+ return e.archived && pa.has(t) ? [
5981
+ be(
5949
5982
  e,
5950
5983
  s,
5951
5984
  "archive-placement",
5952
5985
  `status "${t}" is active but the file is under ideas/archive/`
5953
5986
  )
5954
- ] : !e.archived && fa.has(t) ? [
5955
- Re(
5987
+ ] : !e.archived && ma.has(t) ? [
5988
+ be(
5956
5989
  e,
5957
5990
  s,
5958
5991
  "archive-placement",
5959
5992
  `status "${t}" is closed but the file is still under ideas/ — it should be archived`
5960
5993
  )
5961
5994
  ] : [];
5962
- }), ga = ({ files: n }) => {
5995
+ }), Sa = ({ files: n }) => {
5963
5996
  var t;
5964
5997
  const e = /* @__PURE__ */ new Set();
5965
5998
  for (const s of n) {
@@ -5971,9 +6004,9 @@ const ha = ({ files: n }) => n.flatMap((e) => {
5971
6004
  const i = s.content.split(`
5972
6005
  `), r = [];
5973
6006
  for (let o = 0; o < i.length; o++)
5974
- for (const a of i[o].matchAll(la))
6007
+ for (const a of i[o].matchAll(ha))
5975
6008
  e.has(a[1]) || r.push(
5976
- Re(
6009
+ be(
5977
6010
  s,
5978
6011
  o + 1,
5979
6012
  "dangling-link",
@@ -5982,29 +6015,30 @@ const ha = ({ files: n }) => n.flatMap((e) => {
5982
6015
  );
5983
6016
  return r;
5984
6017
  });
5985
- }, ya = [
5986
- ha,
5987
- pa,
5988
- ma,
5989
- ga
5990
- ], wa = [...ta, ...ya];
5991
- function ni(n) {
6018
+ }, Ea = [
6019
+ ya,
6020
+ wa,
6021
+ ba,
6022
+ ka,
6023
+ Sa
6024
+ ], Na = [...oa, ...Ea];
6025
+ function si(n) {
5992
6026
  return (n == null ? void 0 : n.code) === "ENOENT";
5993
6027
  }
5994
- async function ba(n) {
6028
+ async function va(n) {
5995
6029
  try {
5996
6030
  return await ct(n);
5997
6031
  } catch (e) {
5998
- if (ni(e)) return [];
6032
+ if (si(e)) return [];
5999
6033
  throw e;
6000
6034
  }
6001
6035
  }
6002
- async function ka(n) {
6036
+ async function Ia(n) {
6003
6037
  let e;
6004
6038
  try {
6005
6039
  e = await q(n, "utf-8");
6006
6040
  } catch (t) {
6007
- if (ni(t)) return null;
6041
+ if (si(t)) return null;
6008
6042
  throw t;
6009
6043
  }
6010
6044
  try {
@@ -6013,47 +6047,47 @@ async function ka(n) {
6013
6047
  return null;
6014
6048
  }
6015
6049
  }
6016
- async function Sa(n) {
6017
- const e = $(n, "ideas"), t = [], s = [
6050
+ async function Aa(n) {
6051
+ const e = A(n, "ideas"), t = [], s = [
6018
6052
  { dir: e, archived: !1, names: await ct(e) },
6019
6053
  {
6020
- dir: $(e, "archive"),
6054
+ dir: A(e, "archive"),
6021
6055
  archived: !0,
6022
- names: await ba($(e, "archive"))
6056
+ names: await va(A(e, "archive"))
6023
6057
  }
6024
6058
  ];
6025
6059
  for (const { dir: i, archived: r, names: o } of s) {
6026
6060
  const a = o.filter((c) => c.endsWith(".md") && c !== "index.md").sort();
6027
6061
  for (const c of a)
6028
6062
  t.push({
6029
- id: ki(c, ".md"),
6063
+ id: Si(c, ".md"),
6030
6064
  path: `papercamp/ideas${r ? "/archive" : ""}/${c}`,
6031
- content: await q($(i, c), "utf-8"),
6065
+ content: await q(A(i, c), "utf-8"),
6032
6066
  archived: r
6033
6067
  });
6034
6068
  }
6035
- return { files: t, config: await ka($(n, "config.json")) };
6069
+ return { files: t, config: await Ia(A(n, "config.json")) };
6036
6070
  }
6037
- function Ea(n) {
6038
- return wa.flatMap((e) => e(n));
6071
+ function $a(n) {
6072
+ return Na.flatMap((e) => e(n));
6039
6073
  }
6040
- async function ol(n) {
6041
- return Ea(await Sa(n));
6074
+ async function fl(n) {
6075
+ return $a(await Aa(n));
6042
6076
  }
6043
- const Na = {
6077
+ const Ta = {
6044
6078
  rule: "archive-placement",
6045
6079
  fix: (n, e) => ({
6046
6080
  kind: "move",
6047
6081
  from: e.path,
6048
6082
  to: e.archived ? e.path.replace("/archive/", "/") : e.path.replace(/\/(?=[^/]+$)/, "/archive/")
6049
6083
  })
6050
- }, va = [Na], Ia = new Map(
6051
- va.map((n) => [n.rule, n])
6084
+ }, Oa = [Ta], Ca = new Map(
6085
+ Oa.map((n) => [n.rule, n])
6052
6086
  );
6053
- function al(n, e) {
6087
+ function dl(n, e) {
6054
6088
  const t = new Map(n.files.map((a) => [a.path, a])), s = [], i = [], r = [], o = [];
6055
6089
  for (const a of e) {
6056
- const c = Ia.get(a.rule), l = t.get(a.file), f = c && l ? c.fix(a, l) : null;
6090
+ const c = Ca.get(a.rule), l = t.get(a.file), f = c && l ? c.fix(a, l) : null;
6057
6091
  if (!f) {
6058
6092
  r.push(a);
6059
6093
  continue;
@@ -6073,27 +6107,27 @@ async function rt(n) {
6073
6107
  return "";
6074
6108
  }
6075
6109
  }
6076
- function si(n, e) {
6110
+ function ii(n, e) {
6077
6111
  var t;
6078
6112
  return (t = n.split(`
6079
6113
  `).find((s) => s.includes(`(${e})`))) == null ? void 0 : t.trim();
6080
6114
  }
6081
- const $a = /^## \[.+?\]\(.*\/compare\/(.+?)\.\.\.(.+?)\)/;
6082
- function Aa(n) {
6115
+ const _a = /^## \[.+?\]\(.*\/compare\/(.+?)\.\.\.(.+?)\)/;
6116
+ function La(n) {
6083
6117
  return n.split(`
6084
- `).map((e) => $a.exec(e)).filter((e) => e !== null).map((e) => ({ version: e[2], range: `${e[1]}..${e[2]}` }));
6118
+ `).map((e) => _a.exec(e)).filter((e) => e !== null).map((e) => ({ version: e[2], range: `${e[1]}..${e[2]}` }));
6085
6119
  }
6086
- function Ta(n, e) {
6120
+ function Ra(n, e) {
6087
6121
  return n.split(`
6088
6122
  `).find((t) => {
6089
6123
  const s = t.match(/\/commit\/([0-9a-f]+)\)/i);
6090
6124
  return s ? s[1].startsWith(e) || e.startsWith(s[1]) : !1;
6091
6125
  });
6092
6126
  }
6093
- const Oa = /^[a-z]+\/([a-z]+-\d+)-/;
6094
- async function Ca(n, e) {
6127
+ const Pa = /^[a-z]+\/([a-z]+-\d+)-/;
6128
+ async function Ma(n, e) {
6095
6129
  var i;
6096
- const t = await be(n, [
6130
+ const t = await ke(n, [
6097
6131
  "for-each-ref",
6098
6132
  "--format=%(refname)",
6099
6133
  "refs/heads",
@@ -6102,26 +6136,26 @@ async function Ca(n, e) {
6102
6136
  for (const r of t.split(`
6103
6137
  `)) {
6104
6138
  const o = r.replace(/^refs\/heads\//, "").replace(/^refs\/remotes\/[^/]+\//, "");
6105
- if (((i = Oa.exec(o)) == null ? void 0 : i[1]) === s) return o;
6139
+ if (((i = Pa.exec(o)) == null ? void 0 : i[1]) === s) return o;
6106
6140
  }
6107
6141
  }
6108
- async function _a(n, e) {
6109
- const t = await Ca(n, e);
6142
+ async function Da(n, e) {
6143
+ const t = await Ma(n, e);
6110
6144
  if (!t) return [];
6111
- const s = await Gn(n);
6112
- return (await be(n, ["log", "--format=%s", `${s}..${t}`])).split(`
6145
+ const s = await Yn(n);
6146
+ return (await ke(n, ["log", "--format=%s", `${s}..${t}`])).split(`
6113
6147
  `).map((r) => r.trim()).filter(Boolean);
6114
6148
  }
6115
- async function La(n, e) {
6116
- if (!qi.test(e)) return null;
6117
- const t = await be(n, ["log", "-1", "--format=%B", e]), s = t ? Ot(t) : null;
6149
+ async function ja(n, e) {
6150
+ if (!xi.test(e)) return null;
6151
+ const t = await ke(n, ["log", "-1", "--format=%B", e]), s = t ? Ot(t) : null;
6118
6152
  if (s) return s;
6119
- const i = await rt($(n, "CHANGELOG.md")), r = Ta(i, e);
6153
+ const i = await rt(A(n, "CHANGELOG.md")), r = Ra(i, e);
6120
6154
  return r ? Ot(r) : null;
6121
6155
  }
6122
- async function Ra(n, e) {
6123
- const s = (await be(n, ["log", "--format=%H", "--reverse", e])).split(`
6124
- `).map((o) => o.trim()).filter(Boolean), i = await Promise.all(s.map((o) => La(n, o))), r = /* @__PURE__ */ new Map();
6156
+ async function Ba(n, e) {
6157
+ const s = (await ke(n, ["log", "--format=%H", "--reverse", e])).split(`
6158
+ `).map((o) => o.trim()).filter(Boolean), i = await Promise.all(s.map((o) => ja(n, o))), r = /* @__PURE__ */ new Map();
6125
6159
  return s.forEach((o, a) => {
6126
6160
  const c = i[a];
6127
6161
  if (!c) return;
@@ -6129,15 +6163,15 @@ async function Ra(n, e) {
6129
6163
  l ? l.push(o) : r.set(c, [o]);
6130
6164
  }), r;
6131
6165
  }
6132
- async function cl(n, e) {
6166
+ async function hl(n, e) {
6133
6167
  const [{ entries: t }, s, i, r, o, a] = await Promise.all([
6134
- Ie($(n, "papercamp", "ideas")),
6168
+ Ae(A(n, "papercamp", "ideas")),
6135
6169
  ts(n),
6136
- rt($(n, "papercamp", "tasks.log")),
6137
- rt($(n, "CHANGELOG.md")),
6138
- _a(n, e),
6170
+ rt(A(n, "papercamp", "tasks.log")),
6171
+ rt(A(n, "CHANGELOG.md")),
6172
+ Da(n, e),
6139
6173
  Vn(n)
6140
- ]), c = t.find((h) => h.id === e), l = s == null ? void 0 : s.get(e), f = Uo(i).filter((h) => h.planId === e), u = si(r, e);
6174
+ ]), c = t.find((h) => h.id === e), l = s == null ? void 0 : s.get(e), f = Vo(i).filter((h) => h.planId === e), u = ii(r, e);
6141
6175
  return {
6142
6176
  id: e,
6143
6177
  idea: c ? {
@@ -6155,7 +6189,7 @@ async function cl(n, e) {
6155
6189
  releaseLine: u ? { reached: !0, data: u } : { reached: !1 }
6156
6190
  };
6157
6191
  }
6158
- const Qe = /^##\s+/, Pa = /^##\s+The goal\s*$/i, ii = /^##\s+(Horizon\s+\d+\s*[—-].*)\r?$/i, Ma = /^##\s+Standing concerns\s*$/i, ot = /^-\s+\*\*(.+?)\*\*\s+[—-]\s+(.*)\r?$/, Da = /^\s+-\s+→\s+(.+?)\r?$/, ri = /^\s+-\s+(.+?)\r?$/, oi = /^\s+\S/;
6192
+ const Qe = /^##\s+/, Fa = /^##\s+The goal\s*$/i, ri = /^##\s+(Horizon\s+\d+\s*[—-].*)\r?$/i, Ka = /^##\s+Standing concerns\s*$/i, ot = /^-\s+\*\*(.+?)\*\*\s+[—-]\s+(.*)\r?$/, qa = /^\s+-\s+→\s+(.+?)\r?$/, oi = /^\s+-\s+(.+?)\r?$/, ai = /^\s+\S/;
6159
6193
  function Bn(n, e, t) {
6160
6194
  const s = [];
6161
6195
  let i = e;
@@ -6167,45 +6201,45 @@ function Bn(n, e, t) {
6167
6201
  }
6168
6202
  const o = [r[2].trim()], a = [], c = [];
6169
6203
  for (i++; i < t && !ot.test(n[i]); ) {
6170
- const l = n[i].match(Da);
6204
+ const l = n[i].match(qa);
6171
6205
  if (l) {
6172
6206
  c.push(l[1].trim()), i++;
6173
6207
  continue;
6174
6208
  }
6175
- const f = n[i].match(ri);
6209
+ const f = n[i].match(oi);
6176
6210
  if (f) {
6177
6211
  a.push(f[1].trim()), i++;
6178
6212
  continue;
6179
6213
  }
6180
- if (!oi.test(n[i])) break;
6214
+ if (!ai.test(n[i])) break;
6181
6215
  o.push(n[i].trim()), i++;
6182
6216
  }
6183
6217
  s.push({ name: r[1].trim(), description: o.join(" "), candidates: a, linked: c });
6184
6218
  }
6185
6219
  return s;
6186
6220
  }
6187
- function ja(n) {
6221
+ function Ua(n) {
6188
6222
  const e = n.split(`
6189
6223
  `);
6190
6224
  let t = "";
6191
6225
  const s = [];
6192
6226
  let i = [];
6193
6227
  for (let r = 0; r < e.length; r++) {
6194
- if (Pa.test(e[r])) {
6228
+ if (Fa.test(e[r])) {
6195
6229
  let a = r + 1;
6196
6230
  for (; a < e.length && !Qe.test(e[a]); ) a++;
6197
6231
  t = e.slice(r + 1, a).join(`
6198
6232
  `).trim(), r = a - 1;
6199
6233
  continue;
6200
6234
  }
6201
- const o = e[r].match(ii);
6235
+ const o = e[r].match(ri);
6202
6236
  if (o) {
6203
6237
  let a = r + 1;
6204
6238
  for (; a < e.length && !Qe.test(e[a]); ) a++;
6205
6239
  s.push({ title: o[1].trim(), items: Bn(e, r + 1, a) }), r = a - 1;
6206
6240
  continue;
6207
6241
  }
6208
- if (Ma.test(e[r])) {
6242
+ if (Ka.test(e[r])) {
6209
6243
  let a = r + 1;
6210
6244
  for (; a < e.length && !Qe.test(e[a]); ) a++;
6211
6245
  i = Bn(e, r + 1, a), r = a - 1;
@@ -6213,9 +6247,9 @@ function ja(n) {
6213
6247
  }
6214
6248
  return { goal: t, horizons: s, standingConcerns: i };
6215
6249
  }
6216
- function ai(n, e) {
6250
+ function ci(n, e) {
6217
6251
  for (let t = 0; t < n.length; t++) {
6218
- const s = n[t].match(ii);
6252
+ const s = n[t].match(ri);
6219
6253
  if (!s || s[1].trim() !== e) continue;
6220
6254
  let i = t + 1;
6221
6255
  for (; i < n.length && !Qe.test(n[i]); ) i++;
@@ -6223,18 +6257,18 @@ function ai(n, e) {
6223
6257
  }
6224
6258
  }
6225
6259
  function mn(n, e, t) {
6226
- const s = ai(n, e);
6260
+ const s = ci(n, e);
6227
6261
  if (s)
6228
6262
  for (let i = s.start; i < s.end; i++) {
6229
6263
  const r = n[i].match(ot);
6230
6264
  if (!r || r[1].trim() !== t) continue;
6231
6265
  let o = i + 1;
6232
- for (; o < s.end && !ot.test(n[o]) && oi.test(n[o]); )
6266
+ for (; o < s.end && !ot.test(n[o]) && ai.test(n[o]); )
6233
6267
  o++;
6234
6268
  return { start: i, end: o };
6235
6269
  }
6236
6270
  }
6237
- function ll(n, e, t, s) {
6271
+ function pl(n, e, t, s) {
6238
6272
  const i = n.split(`
6239
6273
  `), r = mn(i, e, t);
6240
6274
  if (!r) return n;
@@ -6242,58 +6276,58 @@ function ll(n, e, t, s) {
6242
6276
  return i.splice(r.start, r.end - r.start), i.join(`
6243
6277
  `);
6244
6278
  for (let o = r.start + 1; o < r.end; o++) {
6245
- const a = i[o].match(ri);
6279
+ const a = i[o].match(oi);
6246
6280
  if (a && a[1].trim() === s)
6247
6281
  return i.splice(o, 1), i.join(`
6248
6282
  `);
6249
6283
  }
6250
6284
  return n;
6251
6285
  }
6252
- function ul(n, e, t, s) {
6286
+ function ml(n, e, t, s) {
6253
6287
  const i = n.split(`
6254
- `), r = ai(i, e);
6288
+ `), r = ci(i, e);
6255
6289
  if (!r) return n;
6256
6290
  let o = r.end;
6257
6291
  for (; o > r.start && i[o - 1].trim() === ""; ) o--;
6258
6292
  return i.splice(o, 0, `- **${t}** — ${s}`), i.join(`
6259
6293
  `);
6260
6294
  }
6261
- function fl(n, e, t, s) {
6295
+ function gl(n, e, t, s) {
6262
6296
  const i = n.split(`
6263
6297
  `), r = mn(i, e, t);
6264
6298
  return r ? (i.splice(r.end, 0, ` - ${s}`), i.join(`
6265
6299
  `)) : n;
6266
6300
  }
6267
- function dl(n, e, t, s) {
6301
+ function yl(n, e, t, s) {
6268
6302
  const i = n.split(`
6269
6303
  `), r = mn(i, e, t);
6270
6304
  return r ? (i.splice(r.end, 0, ` - → ${s}`), i.join(`
6271
6305
  `)) : n;
6272
6306
  }
6273
- function Ba(n) {
6307
+ function xa(n) {
6274
6308
  return [
6275
6309
  ...n.horizons.flatMap((e) => e.items.map((t) => t.name)),
6276
6310
  ...n.standingConcerns.map((e) => e.name)
6277
6311
  ];
6278
6312
  }
6279
- function hl(n, e, t = [], s = "") {
6313
+ function wl(n, e, t = [], s = "") {
6280
6314
  const i = new Map(e.filter((c) => c.id).map((c) => [c.id, c])), r = /* @__PURE__ */ new Map();
6281
6315
  for (const c of t)
6282
6316
  c.planId && r.set(c.planId, (r.get(c.planId) ?? 0) + 1);
6283
6317
  const o = n.horizons.map((c) => {
6284
6318
  const l = c.items.map((u) => {
6285
- const h = u.linked.flatMap((g) => {
6286
- const d = i.get(g);
6319
+ const h = u.linked.flatMap((y) => {
6320
+ const d = i.get(y);
6287
6321
  return d != null && d.status ? [
6288
6322
  {
6289
- id: g,
6323
+ id: y,
6290
6324
  status: d.status,
6291
- taskRuns: r.get(g) ?? 0,
6325
+ taskRuns: r.get(y) ?? 0,
6292
6326
  pr: d.pr,
6293
- released: si(s, g) !== void 0
6327
+ released: ii(s, y) !== void 0
6294
6328
  }
6295
6329
  ] : [];
6296
- }), p = { total: h.length, done: h.filter((g) => g.status === "done").length };
6330
+ }), p = { total: h.length, done: h.filter((y) => y.status === "done").length };
6297
6331
  return { ...u, links: h, rollup: p };
6298
6332
  }), f = l.reduce(
6299
6333
  (u, h) => ({
@@ -6303,10 +6337,10 @@ function hl(n, e, t = [], s = "") {
6303
6337
  { total: 0, done: 0 }
6304
6338
  );
6305
6339
  return { title: c.title, items: l, rollup: f };
6306
- }), a = Fa(n, e, t);
6340
+ }), a = Ha(n, e, t);
6307
6341
  return { goal: n.goal, horizons: o, events: a };
6308
6342
  }
6309
- function Fa(n, e, t) {
6343
+ function Ha(n, e, t) {
6310
6344
  const s = /* @__PURE__ */ new Map();
6311
6345
  for (const r of n.horizons)
6312
6346
  for (const o of r.items)
@@ -6339,7 +6373,7 @@ function Fa(n, e, t) {
6339
6373
  }
6340
6374
  return i.sort((r, o) => Date.parse(r.date) - Date.parse(o.date));
6341
6375
  }
6342
- function Ka(n) {
6376
+ function Ga(n) {
6343
6377
  const e = JSON.stringify({
6344
6378
  body: n.body,
6345
6379
  phases: n.phases.map((t) => ({
@@ -6349,7 +6383,7 @@ function Ka(n) {
6349
6383
  source: t.source ?? null
6350
6384
  }))
6351
6385
  });
6352
- return Ei("sha256").update(e).digest("hex");
6386
+ return vi("sha256").update(e).digest("hex");
6353
6387
  }
6354
6388
  const gn = /* @__PURE__ */ new Set([
6355
6389
  "core",
@@ -6371,10 +6405,10 @@ const gn = /* @__PURE__ */ new Set([
6371
6405
  "release",
6372
6406
  "main"
6373
6407
  ]);
6374
- function qa(n, e) {
6408
+ function Ya(n, e) {
6375
6409
  return (n == null ? void 0 : n.find((t) => gn.has(t))) ?? e;
6376
6410
  }
6377
- function ci(n, e) {
6411
+ function li(n, e) {
6378
6412
  return new Promise((t) => {
6379
6413
  var r, o;
6380
6414
  const s = D(
@@ -6402,8 +6436,8 @@ function ci(n, e) {
6402
6436
  }), s.on("error", () => t(void 0));
6403
6437
  });
6404
6438
  }
6405
- const Ua = 6e4;
6406
- function pl(n, e, t = Ua) {
6439
+ const Va = 6e4;
6440
+ function bl(n, e, t = Va) {
6407
6441
  return new Promise((s) => {
6408
6442
  var o, a;
6409
6443
  const i = D("gh", ["pr", "diff", e], { cwd: n, stdio: ["ignore", "pipe", "pipe"] });
@@ -6423,45 +6457,45 @@ function pl(n, e, t = Ua) {
6423
6457
  }), i.on("error", () => s(void 0));
6424
6458
  });
6425
6459
  }
6426
- async function Ha(n, e) {
6427
- for (const t of ["ideas", $("ideas", "archive")]) {
6428
- const s = $(n, "papercamp", t, `${e}.md`);
6460
+ async function Ja(n, e) {
6461
+ for (const t of ["ideas", A("ideas", "archive")]) {
6462
+ const s = A(n, "papercamp", t, `${e}.md`);
6429
6463
  try {
6430
- return await yi(s), s;
6464
+ return await wi(s), s;
6431
6465
  } catch {
6432
6466
  }
6433
6467
  }
6434
6468
  return null;
6435
6469
  }
6436
6470
  async function ce(n, e) {
6437
- const t = await ci(n, e), s = Wn(t == null ? void 0 : t.body, (t == null ? void 0 : t.headRefName) ?? e);
6471
+ const t = await li(n, e), s = Wn(t == null ? void 0 : t.body, (t == null ? void 0 : t.headRefName) ?? e);
6438
6472
  if (!s) return;
6439
- const i = await Ha(n, s);
6473
+ const i = await Ja(n, s);
6440
6474
  if (!i) return;
6441
6475
  const { entries: r } = Vs(await q(i, "utf-8")), o = r[0];
6442
6476
  if (o)
6443
6477
  return { id: s, view: t, entry: o };
6444
6478
  }
6445
- async function ml(n, e) {
6479
+ async function kl(n, e) {
6446
6480
  const t = await ce(n, e);
6447
6481
  if (!t) return;
6448
6482
  const { id: s, entry: i } = t;
6449
6483
  return { id: s, kind: i.type, tags: i.tags, phases: i.phases };
6450
6484
  }
6451
- const li = "<!-- papercamp:phases:start -->", ui = "<!-- papercamp:phases:end -->", Fn = new RegExp(`${li}[\\s\\S]*?${ui}`);
6452
- function xa(n, e) {
6485
+ const ui = "<!-- papercamp:phases:start -->", fi = "<!-- papercamp:phases:end -->", Fn = new RegExp(`${ui}[\\s\\S]*?${fi}`);
6486
+ function Wa(n, e) {
6453
6487
  const t = e.map((r) => `- [${r.done ? "x" : " "}] ${r.text}`).join(`
6454
- `), s = `${li}
6488
+ `), s = `${ui}
6455
6489
  ### Phases
6456
6490
  ${t}
6457
- ${ui}`;
6491
+ ${fi}`;
6458
6492
  if (Fn.test(n)) return n.replace(Fn, () => s);
6459
6493
  const i = n.trimEnd();
6460
6494
  return i.length > 0 ? `${i}
6461
6495
 
6462
6496
  ${s}` : s;
6463
6497
  }
6464
- function Ya(n, e, t) {
6498
+ function za(n, e, t) {
6465
6499
  return new Promise((s) => {
6466
6500
  var r, o;
6467
6501
  const i = D("gh", ["pr", "edit", e, "--body-file", "-"], {
@@ -6472,20 +6506,20 @@ function Ya(n, e, t) {
6472
6506
  }), i.on("close", (a) => s(a === 0)), i.on("error", () => s(!1)), (o = i.stdin) == null || o.end(t);
6473
6507
  });
6474
6508
  }
6475
- async function gl(n, e) {
6509
+ async function Sl(n, e) {
6476
6510
  const t = await ce(n, e);
6477
6511
  if (!(t != null && t.view)) return "unresolved";
6478
- const { view: s, entry: i } = t, r = xa(s.body, i.phases);
6479
- return r === s.body ? "unchanged" : await Ya(n, e, r) ? "updated" : "unresolved";
6512
+ const { view: s, entry: i } = t, r = Wa(s.body, i.phases);
6513
+ return r === s.body ? "unchanged" : await za(n, e, r) ? "updated" : "unresolved";
6480
6514
  }
6481
- function Ga(n) {
6515
+ function Qa(n) {
6482
6516
  const e = /* @__PURE__ */ new Set();
6483
6517
  n.kind && e.add(n.kind);
6484
6518
  for (const t of n.tags)
6485
6519
  gn.has(t) && e.add(t);
6486
6520
  return [...e];
6487
6521
  }
6488
- function Va(n) {
6522
+ function Xa(n) {
6489
6523
  return new Promise((e) => {
6490
6524
  var i, r;
6491
6525
  const t = D("gh", ["label", "list", "--limit", "200", "--json", "name"], {
@@ -6510,7 +6544,7 @@ function Va(n) {
6510
6544
  }), t.on("error", () => e(void 0));
6511
6545
  });
6512
6546
  }
6513
- function Ja(n, e) {
6547
+ function Za(n, e) {
6514
6548
  return new Promise((t) => {
6515
6549
  var i;
6516
6550
  const s = D("gh", ["label", "create", e, "--color", "ededed"], {
@@ -6521,7 +6555,7 @@ function Ja(n, e) {
6521
6555
  }), s.on("close", (r) => t(r === 0)), s.on("error", () => t(!1));
6522
6556
  });
6523
6557
  }
6524
- function Wa(n, e, t) {
6558
+ function ec(n, e, t) {
6525
6559
  return new Promise((s) => {
6526
6560
  var r;
6527
6561
  const i = D("gh", ["pr", "edit", e, "--add-label", t.join(",")], {
@@ -6532,29 +6566,29 @@ function Wa(n, e, t) {
6532
6566
  }), i.on("close", (o) => s(o === 0)), i.on("error", () => s(!1));
6533
6567
  });
6534
6568
  }
6535
- async function yl(n, e) {
6569
+ async function El(n, e) {
6536
6570
  const t = await ce(n, e);
6537
6571
  if (!(t != null && t.view)) return "unresolved";
6538
- const { view: s, entry: i } = t, r = Ga({ kind: i.type, tags: i.tags }), o = new Set((s.labels ?? []).map((f) => f.name)), a = r.filter((f) => !o.has(f));
6572
+ const { view: s, entry: i } = t, r = Qa({ kind: i.type, tags: i.tags }), o = new Set((s.labels ?? []).map((f) => f.name)), a = r.filter((f) => !o.has(f));
6539
6573
  if (a.length === 0) return "unchanged";
6540
- const c = await Va(n);
6574
+ const c = await Xa(n);
6541
6575
  if (c) {
6542
6576
  const f = a.filter((u) => !c.has(u));
6543
6577
  for (const u of f)
6544
- await Ja(n, u);
6578
+ await Za(n, u);
6545
6579
  }
6546
- return await Wa(n, e, a) ? "updated" : "unresolved";
6580
+ return await ec(n, e, a) ? "updated" : "unresolved";
6547
6581
  }
6548
- function fi(n, e) {
6549
- const t = e.type ?? "feat", s = qa(e.tags, "repo");
6582
+ function di(n, e) {
6583
+ const t = e.type ?? "feat", s = Ya(e.tags, "repo");
6550
6584
  return `${t}(${s}): ${e.title} (${n})`;
6551
6585
  }
6552
- const za = new RegExp(`^(${Si.join("|")})\\(([a-z-]+)\\): .+$`);
6553
- function Qa(n) {
6554
- const e = n.match(za);
6586
+ const tc = new RegExp(`^(${Ni.join("|")})\\(([a-z-]+)\\): .+$`);
6587
+ function nc(n) {
6588
+ const e = n.match(tc);
6555
6589
  return !!e && gn.has(e[2]);
6556
6590
  }
6557
- function Xa(n, e, t) {
6591
+ function sc(n, e, t) {
6558
6592
  return new Promise((s) => {
6559
6593
  var r;
6560
6594
  const i = D("gh", ["pr", "edit", e, "--title", t], {
@@ -6565,19 +6599,19 @@ function Xa(n, e, t) {
6565
6599
  }), i.on("close", (o) => s(o === 0)), i.on("error", () => s(!1));
6566
6600
  });
6567
6601
  }
6568
- async function wl(n, e) {
6602
+ async function Nl(n, e) {
6569
6603
  const t = await ce(n, e);
6570
6604
  if (!(t != null && t.view)) return "unresolved";
6571
- const { id: s, view: i, entry: r } = t, o = fi(s, r);
6572
- return i.title === o ? "unchanged" : await Xa(n, e, o) ? "updated" : "unresolved";
6605
+ const { id: s, view: i, entry: r } = t, o = di(s, r);
6606
+ return i.title === o ? "unchanged" : await sc(n, e, o) ? "updated" : "unresolved";
6573
6607
  }
6574
- async function bl(n, e) {
6575
- const t = await ci(n, e);
6608
+ async function vl(n, e) {
6609
+ const t = await li(n, e);
6576
6610
  if (!t) return "no-pr";
6577
6611
  const s = await ce(n, e);
6578
- return s ? t.title === fi(s.id, s.entry) ? "valid" : "invalid" : Qa(t.title) ? "valid" : "invalid";
6612
+ return s ? t.title === di(s.id, s.entry) ? "valid" : "invalid" : nc(t.title) ? "valid" : "invalid";
6579
6613
  }
6580
- function kl(n, e) {
6614
+ function Il(n, e) {
6581
6615
  return new Promise((t) => {
6582
6616
  var r;
6583
6617
  const s = D("gh", ["pr", "merge", e, "--squash"], {
@@ -6595,7 +6629,7 @@ function kl(n, e) {
6595
6629
  }), s.on("error", (o) => t({ ok: !1, message: o.message }));
6596
6630
  });
6597
6631
  }
6598
- function Za(n, e) {
6632
+ function ic(n, e) {
6599
6633
  return new Promise((t) => {
6600
6634
  var i;
6601
6635
  const s = D("gh", ["pr", "ready", e], {
@@ -6606,7 +6640,7 @@ function Za(n, e) {
6606
6640
  }), s.on("close", (r) => t(r === 0)), s.on("error", () => t(!1));
6607
6641
  });
6608
6642
  }
6609
- function ec(n, e) {
6643
+ function rc(n, e) {
6610
6644
  return new Promise((t) => {
6611
6645
  var i;
6612
6646
  const s = D("gh", ["pr", "close", e], {
@@ -6617,14 +6651,14 @@ function ec(n, e) {
6617
6651
  }), s.on("close", (r) => t(r === 0)), s.on("error", () => t(!1));
6618
6652
  });
6619
6653
  }
6620
- async function Sl(n, e) {
6654
+ async function Al(n, e) {
6621
6655
  const t = await ce(n, e);
6622
6656
  if (!(t != null && t.view)) return "unresolved";
6623
6657
  const { view: s, entry: i } = t;
6624
- return i.status === "dropped" ? s.state !== "OPEN" ? "unchanged" : await ec(n, e) ? "closed" : "unresolved" : !(i.phases.length > 0 && i.phases.every((a) => a.done)) || !s.isDraft ? "unchanged" : await Za(n, e) ? "ready" : "unresolved";
6658
+ return i.status === "dropped" ? s.state !== "OPEN" ? "unchanged" : await rc(n, e) ? "closed" : "unresolved" : !(i.phases.length > 0 && i.phases.every((a) => a.done)) || !s.isDraft ? "unchanged" : await ic(n, e) ? "ready" : "unresolved";
6625
6659
  }
6626
- const di = "<!-- papercamp:consistency:start -->", tc = "<!-- papercamp:consistency:end -->";
6627
- function nc(n, e) {
6660
+ const hi = "<!-- papercamp:consistency:start -->", oc = "<!-- papercamp:consistency:end -->";
6661
+ function ac(n, e) {
6628
6662
  const t = ["### Paper Camp checks", ""];
6629
6663
  if (n.length === 0)
6630
6664
  t.push("No consistency issues found.");
@@ -6633,12 +6667,12 @@ function nc(n, e) {
6633
6667
  t.push(`- **${s.kind}** (${s.section}): ${s.message}`);
6634
6668
  return e && (t.push(""), t.push(
6635
6669
  e.stale ? `Convergence audit: last run \`${e.audited}\`, plan has changed since — due for a re-audit.` : `Convergence audit: last run \`${e.audited}\`, still current.`
6636
- )), `${di}
6670
+ )), `${hi}
6637
6671
  ${t.join(`
6638
6672
  `)}
6639
- ${tc}`;
6673
+ ${oc}`;
6640
6674
  }
6641
- function sc(n, e, t) {
6675
+ function cc(n, e, t) {
6642
6676
  return new Promise((s) => {
6643
6677
  var r, o;
6644
6678
  const i = D("gh", ["pr", "comment", e, "--body-file", "-"], {
@@ -6649,7 +6683,7 @@ function sc(n, e, t) {
6649
6683
  }), i.on("close", (a) => s(a === 0)), i.on("error", () => s(!1)), (o = i.stdin) == null || o.end(t);
6650
6684
  });
6651
6685
  }
6652
- function ic(n, e, t, s, i) {
6686
+ function lc(n, e, t, s, i) {
6653
6687
  return new Promise((r) => {
6654
6688
  var a, c;
6655
6689
  const o = D(
@@ -6668,25 +6702,25 @@ function ic(n, e, t, s, i) {
6668
6702
  }), o.on("close", (l) => r(l === 0)), o.on("error", () => r(!1)), (c = o.stdin) == null || c.end(i);
6669
6703
  });
6670
6704
  }
6671
- async function El(n, e) {
6672
- var g, d;
6705
+ async function $l(n, e) {
6706
+ var y, d;
6673
6707
  const t = await ce(n, e);
6674
- if (!((g = t == null ? void 0 : t.view) != null && g.url)) return "unresolved";
6708
+ if (!((y = t == null ? void 0 : t.view) != null && y.url)) return "unresolved";
6675
6709
  const { view: s, entry: i } = t, [{ entries: r }, o] = await Promise.all([
6676
- Ie($(n, "papercamp", "ideas")),
6677
- q($(n, "ROADMAP.md"), "utf-8").catch(() => "")
6678
- ]), a = r.filter((m) => m.kind !== "note").map((m) => Yn(m)), c = o ? Ba(ja(o)) : [], l = qo(a, c), f = i.audited && i.auditedHash ? {
6710
+ Ae(A(n, "papercamp", "ideas")),
6711
+ q(A(n, "ROADMAP.md"), "utf-8").catch(() => "")
6712
+ ]), a = r.filter((m) => m.kind !== "note").map((m) => Gn(m)), c = o ? xa(Ua(o)) : [], l = Yo(a, c), f = i.audited && i.auditedHash ? {
6679
6713
  audited: i.audited,
6680
- stale: Ka(i) !== i.auditedHash
6681
- } : void 0, u = nc(l, f), h = (s.comments ?? []).find((m) => m.body.includes(di));
6714
+ stale: Ga(i) !== i.auditedHash
6715
+ } : void 0, u = ac(l, f), h = (s.comments ?? []).find((m) => m.body.includes(hi));
6682
6716
  if (h) {
6683
6717
  if (h.body === u) return "unchanged";
6684
6718
  const m = Me(s.url), w = (d = h.url.match(/issuecomment-(\d+)/)) == null ? void 0 : d[1];
6685
- return !m || !w ? "unresolved" : await ic(n, m.owner, m.repo, w, u) ? "updated" : "unresolved";
6719
+ return !m || !w ? "unresolved" : await lc(n, m.owner, m.repo, w, u) ? "updated" : "unresolved";
6686
6720
  }
6687
- return await sc(n, e, u) ? "created" : "unresolved";
6721
+ return await cc(n, e, u) ? "created" : "unresolved";
6688
6722
  }
6689
- function Nl(n, e, t) {
6723
+ function Tl(n, e, t) {
6690
6724
  if (!n) return;
6691
6725
  const s = (e ?? "feat").toLowerCase(), i = t.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, ""), r = i.length <= 40 ? i : i[40] === "-" ? i.slice(0, 40) : i.slice(0, 40).replace(/-[^-]*$/, "");
6692
6726
  return `${s}/${n.toLowerCase()}-${r}`;
@@ -6696,19 +6730,19 @@ function kt(n, e) {
6696
6730
  t && t.length > 0 && n.push(s.formatLines(t).join(`
6697
6731
  `));
6698
6732
  }
6699
- function hi() {
6733
+ function pi() {
6700
6734
  return (/* @__PURE__ */ new Date()).toISOString().slice(0, 10);
6701
6735
  }
6702
- function vl(n, e = "log") {
6736
+ function Ol(n, e = "log") {
6703
6737
  return {
6704
6738
  kind: e,
6705
- date: hi(),
6739
+ date: pi(),
6706
6740
  text: n,
6707
6741
  from: "agent",
6708
6742
  ...e === "question" ? { state: "open" } : {}
6709
6743
  };
6710
6744
  }
6711
- function rc(n) {
6745
+ function uc(n) {
6712
6746
  const e = [`## ${n.title}`, "", `**Status:** ${n.status}`];
6713
6747
  n.kind && e.push(`**Kind:** ${n.kind}`), n.id && e.push(`**Id:** ${n.id}`), n.idea && e.push(`**Idea:** ${n.idea}`), n.agent && e.push(`**Agent:** ${n.agent}`), e.push(`**Created:** ${n.created}`), n.updated && e.push(`**Updated:** ${n.updated}`), n.tags && n.tags.length > 0 && e.push(`**Tags:** ${n.tags.join(", ")}`);
6714
6748
  const t = [e.join(`
@@ -6722,18 +6756,18 @@ function rc(n) {
6722
6756
 
6723
6757
  `).trimEnd();
6724
6758
  }
6725
- function Il(n) {
6726
- return n.length === 0 ? "" : `${n.map((e) => rc(e)).join(`
6759
+ function Cl(n) {
6760
+ return n.length === 0 ? "" : `${n.map((e) => uc(e)).join(`
6727
6761
 
6728
6762
  `)}
6729
6763
  `;
6730
6764
  }
6731
6765
  function yn(n) {
6732
6766
  return `---
6733
- ${ho(n).trimEnd()}
6767
+ ${mo(n).trimEnd()}
6734
6768
  ---`;
6735
6769
  }
6736
- function $l(n) {
6770
+ function _l(n) {
6737
6771
  const e = {
6738
6772
  id: n.id,
6739
6773
  title: n.title,
@@ -6752,7 +6786,7 @@ function $l(n) {
6752
6786
 
6753
6787
  `).trimEnd();
6754
6788
  }
6755
- function oc(n) {
6789
+ function fc(n) {
6756
6790
  const e = {
6757
6791
  id: n.id,
6758
6792
  title: n.title
@@ -6763,13 +6797,13 @@ function oc(n) {
6763
6797
  const t = [yn(e)];
6764
6798
  return n.body && t.push(n.body), kt(t, [
6765
6799
  { entries: n.phases, section: bt },
6766
- { entries: n.fixes, section: Hs },
6767
- { entries: n.thread, section: xs }
6800
+ { entries: n.fixes, section: xs },
6801
+ { entries: n.thread, section: Hs }
6768
6802
  ]), t.join(`
6769
6803
 
6770
6804
  `).trimEnd();
6771
6805
  }
6772
- function Al(n) {
6806
+ function Ll(n) {
6773
6807
  const e = {
6774
6808
  id: n.id,
6775
6809
  title: n.title
@@ -6782,7 +6816,7 @@ ${n.body}` : s), kt(t, [{ entries: n.log, section: Ue }]), t.join(`
6782
6816
 
6783
6817
  `).trimEnd();
6784
6818
  }
6785
- function Tl(n, e) {
6819
+ function Rl(n, e) {
6786
6820
  let t = !1;
6787
6821
  const s = n.split(`
6788
6822
  `).filter((i) => {
@@ -6797,12 +6831,12 @@ function Tl(n, e) {
6797
6831
  `) : n;
6798
6832
  }
6799
6833
  let at = Promise.resolve();
6800
- async function ac(n, e) {
6834
+ async function dc(n, e) {
6801
6835
  const t = new RegExp(`^${e.toUpperCase()}-(\\d+)\\.md$`), s = [
6802
- $(n, "ideas"),
6803
- $(n, "ideas", "archive"),
6804
- $(n, "plans"),
6805
- $(n, "plans", "archive")
6836
+ A(n, "ideas"),
6837
+ A(n, "ideas", "archive"),
6838
+ A(n, "plans"),
6839
+ A(n, "plans", "archive")
6806
6840
  ];
6807
6841
  let i = 0;
6808
6842
  for (const r of s) {
@@ -6819,7 +6853,7 @@ async function ac(n, e) {
6819
6853
  }
6820
6854
  return i;
6821
6855
  }
6822
- async function pi(n, e) {
6856
+ async function mi(n, e) {
6823
6857
  const t = at.then(async () => {
6824
6858
  let s = null;
6825
6859
  try {
@@ -6828,20 +6862,20 @@ async function pi(n, e) {
6828
6862
  return;
6829
6863
  }
6830
6864
  if (!(s != null && s.nextId)) return;
6831
- const i = s.nextId[e] ?? 1, r = await ac(Xe(n), e), o = Math.max(i, r + 1), a = `${e.toUpperCase()}-${o}`;
6865
+ const i = s.nextId[e] ?? 1, r = await dc(Xe(n), e), o = Math.max(i, r + 1), a = `${e.toUpperCase()}-${o}`;
6832
6866
  return s.nextId[e] = o + 1, await B(n, `${JSON.stringify(s, null, 2)}
6833
6867
  `), a;
6834
6868
  });
6835
6869
  return at = t.catch(() => {
6836
6870
  }), t;
6837
6871
  }
6838
- async function Ol(n) {
6839
- return pi(n, "idea");
6872
+ async function Pl(n) {
6873
+ return mi(n, "idea");
6840
6874
  }
6841
- async function Cl(n) {
6842
- return pi(n, "ticket");
6875
+ async function Ml(n) {
6876
+ return mi(n, "ticket");
6843
6877
  }
6844
- async function _l(n, e) {
6878
+ async function Dl(n, e) {
6845
6879
  const t = at.then(async () => {
6846
6880
  let s = null;
6847
6881
  try {
@@ -6856,17 +6890,17 @@ async function _l(n, e) {
6856
6890
  return at = t.catch(() => {
6857
6891
  }), t;
6858
6892
  }
6859
- async function Ll(n, e) {
6860
- const t = $(n, "papercamp", "ideas"), s = $(t, "archive"), i = $(t, `${e}.md`), r = $(s, `${e}.md`);
6893
+ async function jl(n, e) {
6894
+ const t = A(n, "papercamp", "ideas"), s = A(t, "archive"), i = A(t, `${e}.md`), r = A(s, `${e}.md`);
6861
6895
  await oe(s, { recursive: !0 });
6862
6896
  try {
6863
- return await wi(i, r), !0;
6897
+ return await bi(i, r), !0;
6864
6898
  } catch (o) {
6865
6899
  if (o.code === "ENOENT") return !1;
6866
6900
  throw o;
6867
6901
  }
6868
6902
  }
6869
- const cc = `---
6903
+ const hc = `---
6870
6904
  name: paper-camp
6871
6905
  description: Work inside a project that has a papercamp/ folder — its unified idea entities (each holding its plan as a section), with decisions and open questions logged as notes on the idea they bind. Use this whenever the working directory contains papercamp/ (papercamp/ideas/), and especially before starting, continuing, or completing any plan phase, drafting an idea, logging a decision, or answering "what are we working on / what's next".
6872
6906
  ---
@@ -6935,13 +6969,13 @@ session start from live plan data, not hand-maintained here. It does
6935
6969
  not define the file formats in full; treat the existing files under
6936
6970
  \`papercamp/\` as the grammar reference (mirror their structure exactly rather
6937
6971
  than inventing a new shape).
6938
- `, lc = "$CLAUDE_PROJECT_DIR/node_modules/.bin/paper-camp", uc = `${JSON.stringify(
6972
+ `, pc = "$CLAUDE_PROJECT_DIR/node_modules/.bin/paper-camp", mc = `${JSON.stringify(
6939
6973
  {
6940
6974
  hooks: {
6941
6975
  SessionStart: [
6942
6976
  {
6943
6977
  matcher: "*",
6944
- hooks: [{ type: "command", command: `"${lc}" session-focus` }]
6978
+ hooks: [{ type: "command", command: `"${pc}" session-focus` }]
6945
6979
  }
6946
6980
  ]
6947
6981
  }
@@ -6949,14 +6983,14 @@ than inventing a new shape).
6949
6983
  null,
6950
6984
  2
6951
6985
  )}
6952
- `, fc = 5;
6953
- function dc() {
6986
+ `, gc = 5;
6987
+ function yc() {
6954
6988
  try {
6955
- let n = Xe(Ii(import.meta.url));
6956
- for (let e = 0; e < fc; e++) {
6957
- const t = $(n, "package.json");
6958
- if (Ni(t))
6959
- return JSON.parse(vi(t, "utf-8")).version ?? "0.0.0";
6989
+ let n = Xe($i(import.meta.url));
6990
+ for (let e = 0; e < gc; e++) {
6991
+ const t = A(n, "package.json");
6992
+ if (Ii(t))
6993
+ return JSON.parse(Ai(t, "utf-8")).version ?? "0.0.0";
6960
6994
  n = Xe(n);
6961
6995
  }
6962
6996
  return "0.0.0";
@@ -6964,42 +6998,42 @@ function dc() {
6964
6998
  return "0.0.0";
6965
6999
  }
6966
7000
  }
6967
- const Rl = dc();
6968
- class hc extends Error {
7001
+ const Bl = yc();
7002
+ class wc extends Error {
6969
7003
  constructor(e) {
6970
7004
  super(`Paper Camp is already initialized in ${e} (papercamp/config.json exists).`);
6971
7005
  }
6972
7006
  }
6973
7007
  async function ge(n) {
6974
7008
  try {
6975
- return await bi(n), !0;
7009
+ return await ki(n), !0;
6976
7010
  } catch {
6977
7011
  return !1;
6978
7012
  }
6979
7013
  }
6980
- const pc = ["suggestions.md"];
6981
- async function Pl(n, e) {
6982
- const t = $(n, "papercamp"), s = $(t, "config.json");
7014
+ const bc = ["suggestions.md"];
7015
+ async function Fl(n, e) {
7016
+ const t = A(n, "papercamp"), s = A(t, "config.json");
6983
7017
  if (await ge(s))
6984
- throw new hc(n);
7018
+ throw new wc(n);
6985
7019
  const i = {
6986
- version: ee,
7020
+ version: te,
6987
7021
  projectName: e.projectName,
6988
7022
  initializedAt: (/* @__PURE__ */ new Date()).toISOString(),
6989
7023
  nextId: { idea: 2 }
6990
7024
  };
6991
- Lo.parse(i), await oe(t, { recursive: !0 });
6992
- const r = $(t, "ideas");
7025
+ jo.parse(i), await oe(t, { recursive: !0 });
7026
+ const r = A(t, "ideas");
6993
7027
  await oe(r, { recursive: !0 });
6994
- const o = $(r, "archive");
7028
+ const o = A(r, "archive");
6995
7029
  await oe(o, { recursive: !0 });
6996
- const a = $(r, "IDEA-1.md");
7030
+ const a = A(r, "IDEA-1.md");
6997
7031
  if (!await ge(a)) {
6998
- const c = oc({
7032
+ const c = fc({
6999
7033
  id: "IDEA-1",
7000
7034
  title: "Capture your first idea",
7001
7035
  status: "idea",
7002
- created: hi(),
7036
+ created: pi(),
7003
7037
  body: `This is an example idea, in the format Paper Camp expects: a short title, a status, and a paragraph of context. Read it, then archive or delete it once you've written your own.
7004
7038
 
7005
7039
  Use the New idea button to capture what you're building next, or ask an agent for suggestions.`
@@ -7007,20 +7041,20 @@ Use the New idea button to capture what you're building next, or ask an agent fo
7007
7041
  await B(a, `${c}
7008
7042
  `, "utf-8");
7009
7043
  }
7010
- for (const c of pc) {
7011
- const l = $(t, c);
7044
+ for (const c of bc) {
7045
+ const l = A(t, c);
7012
7046
  await ge(l) || await B(l, "", "utf-8");
7013
7047
  }
7014
7048
  await B(s, `${JSON.stringify(i, null, 2)}
7015
- `, "utf-8"), await gc(n), await yc(n), await mc(n, e.projectName);
7049
+ `, "utf-8"), await Sc(n), await Ec(n), await kc(n, e.projectName);
7016
7050
  }
7017
- async function mc(n, e) {
7018
- const t = Ti(), s = await Oi(t), { registry: i, created: r } = Ci(s, n, e);
7019
- r && await _i(t, i);
7051
+ async function kc(n, e) {
7052
+ const t = Ci(), s = await _i(t), { registry: i, created: r } = Li(s, n, e);
7053
+ r && await Ri(t, i);
7020
7054
  }
7021
7055
  const Tt = "papercamp/.pairing.json";
7022
- async function gc(n) {
7023
- const e = $(n, ".gitignore"), t = await ge(e) ? await q(e, "utf-8") : "", s = t.length > 0 ? t.split(`
7056
+ async function Sc(n) {
7057
+ const e = A(n, ".gitignore"), t = await ge(e) ? await q(e, "utf-8") : "", s = t.length > 0 ? t.split(`
7024
7058
  `) : [];
7025
7059
  if (s.some((r) => r.trim() === Tt)) return;
7026
7060
  const i = s.reduce(
@@ -7038,42 +7072,42 @@ async function gc(n) {
7038
7072
  s.splice(i + 1, 0, Tt), await B(e, s.join(`
7039
7073
  `), "utf-8");
7040
7074
  }
7041
- async function yc(n) {
7042
- const e = $(n, ".claude", "skills", "paper-camp");
7075
+ async function Ec(n) {
7076
+ const e = A(n, ".claude", "skills", "paper-camp");
7043
7077
  await oe(e, { recursive: !0 });
7044
- const t = $(e, "SKILL.md");
7045
- await ge(t) || await B(t, cc, "utf-8");
7046
- const s = $(n, ".claude");
7078
+ const t = A(e, "SKILL.md");
7079
+ await ge(t) || await B(t, hc, "utf-8");
7080
+ const s = A(n, ".claude");
7047
7081
  await oe(s, { recursive: !0 });
7048
- const i = $(s, "settings.json");
7049
- await ge(i) || await B(i, uc, "utf-8");
7082
+ const i = A(s, "settings.json");
7083
+ await ge(i) || await B(i, mc, "utf-8");
7050
7084
  }
7051
- const mi = {
7085
+ const gi = {
7052
7086
  feat: "Features",
7053
7087
  fix: "Bug Fixes",
7054
7088
  refactor: "Code Refactoring",
7055
7089
  docs: "Documentation",
7056
7090
  chore: "Miscellaneous"
7057
- }, wc = Array.from(new Set(Object.values(mi)));
7058
- async function Ml(n, e) {
7059
- const t = await rt($(n, "CHANGELOG.md")), s = Aa(t).find((a) => a.version === e);
7091
+ }, Nc = Array.from(new Set(Object.values(gi)));
7092
+ async function Kl(n, e) {
7093
+ const t = await rt(A(n, "CHANGELOG.md")), s = La(t).find((a) => a.version === e);
7060
7094
  if (!s) return null;
7061
7095
  const [{ entries: i }, r] = await Promise.all([
7062
- Ie($(n, "papercamp", "ideas")),
7063
- Ra(n, s.range)
7096
+ Ae(A(n, "papercamp", "ideas")),
7097
+ Ba(n, s.range)
7064
7098
  ]), o = /* @__PURE__ */ new Map();
7065
7099
  for (const a of r.keys()) {
7066
7100
  const c = i.find((u) => u.id === a);
7067
7101
  if (!c) continue;
7068
- const l = mi[c.type ?? "chore"], f = o.get(l) ?? [];
7102
+ const l = gi[c.type ?? "chore"], f = o.get(l) ?? [];
7069
7103
  f.push({ id: c.id, title: c.title }), o.set(l, f);
7070
7104
  }
7071
- return wc.filter((a) => o.has(a)).map((a) => ({
7105
+ return Nc.filter((a) => o.has(a)).map((a) => ({
7072
7106
  label: a,
7073
7107
  ideas: o.get(a)
7074
7108
  }));
7075
7109
  }
7076
- function Dl(n, e) {
7110
+ function ql(n, e) {
7077
7111
  const t = [`## ${n}`];
7078
7112
  for (const s of e) {
7079
7113
  t.push("", `### ${s.label}`, "");
@@ -7083,26 +7117,26 @@ function Dl(n, e) {
7083
7117
  return t.join(`
7084
7118
  `);
7085
7119
  }
7086
- function bc(n) {
7120
+ function vc(n) {
7087
7121
  return Math.floor((Date.now() - Date.parse(n)) / 864e5);
7088
7122
  }
7089
- const kc = (n, e) => n === "question" && (e ?? "open") === "open";
7090
- function Sc(n) {
7123
+ const Ic = (n, e) => n === "question" && (e ?? "open") === "open";
7124
+ function Ac(n) {
7091
7125
  return n.flatMap(
7092
- (e) => (e.thread ?? []).filter((t) => kc(t.kind, t.state)).map((t) => ({
7126
+ (e) => (e.thread ?? []).filter((t) => Ic(t.kind, t.state)).map((t) => ({
7093
7127
  entityId: e.id,
7094
7128
  entityTitle: e.title,
7095
7129
  text: t.text,
7096
7130
  date: t.date,
7097
- ageDays: t.date ? bc(t.date) : Number.POSITIVE_INFINITY
7131
+ ageDays: t.date ? vc(t.date) : Number.POSITIVE_INFINITY
7098
7132
  }))
7099
7133
  ).sort((e, t) => t.ageDays - e.ageDays);
7100
7134
  }
7101
- async function jl(n) {
7102
- const { entries: e } = await Ie(n);
7103
- return Sc(e);
7135
+ async function Ul(n) {
7136
+ const { entries: e } = await Ae(n);
7137
+ return Ac(e);
7104
7138
  }
7105
- const jt = 0.95, gi = 3e4, Bt = {
7139
+ const jt = 0.95, yi = 3e4, Bt = {
7106
7140
  implement: { from: 0, to: 0.6 },
7107
7141
  verify: { from: 0.6, to: 0.9 },
7108
7142
  checkbox: { from: 0.95, to: 0.95 }
@@ -7116,7 +7150,7 @@ function qn(n, ...e) {
7116
7150
  if (typeof (n == null ? void 0 : n[t]) == "string") return n[t];
7117
7151
  return "";
7118
7152
  }
7119
- function Bl(n, e) {
7153
+ function xl(n, e) {
7120
7154
  const t = n.toLowerCase();
7121
7155
  if (t === "bash")
7122
7156
  return (typeof (e == null ? void 0 : e.command) == "string" ? e.command : "").includes("check-types") ? "verify" : null;
@@ -7126,29 +7160,29 @@ function Bl(n, e) {
7126
7160
  }
7127
7161
  return null;
7128
7162
  }
7129
- function Fl(n, e) {
7163
+ function Hl(n, e) {
7130
7164
  return n ? Kn[e] > Kn[n] ? e : n : e;
7131
7165
  }
7132
- function Kl(n, e) {
7133
- return n === void 0 ? !1 : e - n >= gi;
7166
+ function Gl(n, e) {
7167
+ return n === void 0 ? !1 : e - n >= yi;
7134
7168
  }
7135
- function Ec(n) {
7169
+ function $c(n) {
7136
7170
  const e = [...n].sort((s, i) => s - i), t = Math.floor(e.length / 2);
7137
7171
  return e.length % 2 === 0 ? (e[t - 1] + e[t]) / 2 : e[t];
7138
7172
  }
7139
- function ql(n) {
7173
+ function Yl(n) {
7140
7174
  const e = n.filter((i) => i.taskKind === "phase" && i.outcome === "done").map(
7141
7175
  (i) => (i.endedAt ? Date.parse(i.endedAt) : Number.NaN) - Date.parse(i.startedAt)
7142
7176
  ).filter((i) => Number.isFinite(i) && i > 0);
7143
7177
  if (e.length === 0) return {};
7144
- const t = Ec(e), s = {};
7178
+ const t = $c(e), s = {};
7145
7179
  for (const i of ["implement", "verify"]) {
7146
7180
  const r = Bt[i].to - Bt[i].from;
7147
7181
  s[i] = t * r / jt;
7148
7182
  }
7149
7183
  return s;
7150
7184
  }
7151
- function Ul({
7185
+ function Vl({
7152
7186
  anchor: n,
7153
7187
  anchorEnteredAt: e,
7154
7188
  lastStreamAt: t,
@@ -7159,140 +7193,143 @@ function Ul({
7159
7193
  const r = Bt[n], o = Math.min(r.from, jt), a = i == null ? void 0 : i[n];
7160
7194
  if (!a || a <= 0 || e === void 0 || r.to === r.from)
7161
7195
  return o;
7162
- const c = t === void 0 ? s : Math.min(s, t + gi), l = Math.min(1, Math.max(0, c - e) / a);
7196
+ const c = t === void 0 ? s : Math.min(s, t + yi), l = Math.min(1, Math.max(0, c - e) / a);
7163
7197
  return Math.min(r.from + l * (r.to - r.from), jt);
7164
7198
  }
7165
7199
  export {
7166
- oc as $,
7167
- hc as A,
7168
- Z as B,
7169
- uc as C,
7170
- wa as D,
7171
- Ga as E,
7172
- Fa as F,
7173
- Ba as G,
7174
- nl as H,
7175
- Oo as I,
7176
- Co as J,
7177
- _o as K,
7178
- To as L,
7200
+ fc as $,
7201
+ wc as A,
7202
+ ee as B,
7203
+ mc as C,
7204
+ Na as D,
7205
+ Qa as E,
7206
+ Ha as F,
7207
+ xa as G,
7208
+ al as H,
7209
+ _o as I,
7210
+ Lo as J,
7211
+ Ro as K,
7212
+ Co as L,
7179
7213
  Dn as M,
7180
- Uc as N,
7181
- _l as O,
7182
- Rl as P,
7183
- Ao as Q,
7184
- Gs as R,
7185
- cc as S,
7186
- Ki as T,
7187
- Yn as U,
7188
- pl as V,
7189
- Bc as W,
7190
- el as X,
7191
- qo as Y,
7192
- si as Z,
7214
+ Vc as N,
7215
+ Dl as O,
7216
+ Bl as P,
7217
+ Oo as Q,
7218
+ Ys as R,
7219
+ hc as S,
7220
+ Ui as T,
7221
+ Gn as U,
7222
+ bl as V,
7223
+ xc as W,
7224
+ rl as X,
7225
+ Yo as Y,
7226
+ ii as Z,
7193
7227
  it as _,
7194
7228
  gn as a,
7195
- wl as a$,
7196
- Al as a0,
7197
- rc as a1,
7198
- $l as a2,
7199
- Il as a3,
7200
- Dl as a4,
7201
- Hc as a5,
7202
- $o as a6,
7203
- Pl as a7,
7204
- Qa as a8,
7205
- Kl as a9,
7206
- Tl as aA,
7207
- nc as aB,
7208
- xa as aC,
7209
- Kc as aD,
7210
- sl as aE,
7211
- La as aF,
7212
- cl as aG,
7213
- Ot as aH,
7214
- Ra as aI,
7215
- ml as aJ,
7216
- qa as aK,
7217
- ts as aL,
7218
- Ml as aM,
7219
- Aa as aN,
7220
- Fc as aO,
7221
- hl as aP,
7222
- ol as aQ,
7223
- Ea as aR,
7224
- Wi as aS,
7225
- yn as aT,
7226
- zs as aU,
7227
- kl as aV,
7228
- Ro as aW,
7229
- El as aX,
7230
- gl as aY,
7231
- yl as aZ,
7232
- Sl as a_,
7233
- dl as aa,
7234
- ql as ab,
7235
- Lo as ac,
7236
- Vs as ad,
7237
- Lc as ae,
7238
- un as af,
7239
- Vc as ag,
7240
- Jc as ah,
7241
- Wc as ai,
7242
- Gc as aj,
7243
- Yc as ak,
7244
- Do as al,
7245
- ja as am,
7229
+ Sl as a$,
7230
+ Ll as a0,
7231
+ uc as a1,
7232
+ _l as a2,
7233
+ Cl as a3,
7234
+ ql as a4,
7235
+ Jc as a5,
7236
+ To as a6,
7237
+ Fl as a7,
7238
+ nc as a8,
7239
+ Gl as a9,
7240
+ Vo as aA,
7241
+ il as aB,
7242
+ pl as aC,
7243
+ Rl as aD,
7244
+ ac as aE,
7245
+ Wa as aF,
7246
+ Gc as aG,
7247
+ cl as aH,
7248
+ ja as aI,
7249
+ hl as aJ,
7250
+ Ot as aK,
7251
+ Ba as aL,
7252
+ kl as aM,
7253
+ Ya as aN,
7254
+ ts as aO,
7255
+ Kl as aP,
7256
+ La as aQ,
7257
+ Hc as aR,
7258
+ wl as aS,
7259
+ fl as aT,
7260
+ $a as aU,
7261
+ Qi as aV,
7262
+ yn as aW,
7263
+ zs as aX,
7264
+ Il as aY,
7265
+ Bo as aZ,
7266
+ $l as a_,
7267
+ yl as aa,
7268
+ Yl as ab,
7269
+ Do as ac,
7270
+ Mo as ad,
7271
+ Po as ae,
7272
+ jo as af,
7273
+ Vs as ag,
7274
+ jc as ah,
7275
+ un as ai,
7276
+ Xc as aj,
7277
+ Zc as ak,
7278
+ el as al,
7279
+ Qc as am,
7246
7280
  zc as an,
7247
- Ul as ao,
7248
- al as ap,
7249
- vo as aq,
7250
- Io as ar,
7251
- Ie as as,
7252
- Xc as at,
7253
- rt as au,
7254
- tl as av,
7255
- jl as aw,
7256
- Uo as ax,
7257
- Zc as ay,
7258
- ll as az,
7259
- qi as b,
7260
- hi as b0,
7261
- bl as b1,
7262
- il as b2,
7263
- Ho as b3,
7264
- Qc as b4,
7265
- Pc as b5,
7266
- Dc as b6,
7267
- xn as b7,
7268
- be as b8,
7269
- jc as b9,
7270
- Mc as ba,
7271
- Di as bb,
7272
- rl as bc,
7273
- va as c,
7274
- Go as d,
7275
- Vo as e,
7281
+ qo as ao,
7282
+ Ua as ap,
7283
+ tl as aq,
7284
+ Vl as ar,
7285
+ dl as as,
7286
+ Ao as at,
7287
+ $o as au,
7288
+ Ae as av,
7289
+ sl as aw,
7290
+ rt as ax,
7291
+ ol as ay,
7292
+ Ul as az,
7293
+ xi as b,
7294
+ El as b0,
7295
+ Al as b1,
7296
+ Nl as b2,
7297
+ pi as b3,
7298
+ vl as b4,
7299
+ ll as b5,
7300
+ Jo as b6,
7301
+ nl as b7,
7302
+ Fc as b8,
7303
+ qc as b9,
7304
+ Hn as ba,
7305
+ ke as bb,
7306
+ Uc as bc,
7307
+ Kc as bd,
7308
+ Bi as be,
7309
+ ul as bf,
7310
+ Oa as c,
7311
+ Qo as d,
7312
+ Xo as e,
7276
7313
  jt as f,
7277
- gi as g,
7314
+ yi as g,
7278
7315
  Js as h,
7279
- fl as i,
7280
- ul as j,
7281
- Fl as k,
7282
- te as l,
7283
- vl as m,
7284
- Rc as n,
7285
- Ll as o,
7286
- Ol as p,
7287
- pi as q,
7288
- Cl as r,
7289
- Nl as s,
7290
- Bl as t,
7291
- xc as u,
7292
- Sa as v,
7293
- Sc as w,
7294
- Ka as x,
7295
- fi as y,
7296
- qc as z
7316
+ gl as i,
7317
+ ml as j,
7318
+ Hl as k,
7319
+ z as l,
7320
+ Ol as m,
7321
+ Bc as n,
7322
+ jl as o,
7323
+ Pl as p,
7324
+ mi as q,
7325
+ Ml as r,
7326
+ Tl as s,
7327
+ xl as t,
7328
+ Wc as u,
7329
+ Aa as v,
7330
+ Ac as w,
7331
+ Ga as x,
7332
+ di as y,
7333
+ Yc as z
7297
7334
  };
7298
- //# sourceMappingURL=phase-progress.B7wQZk0L.js.map
7335
+ //# sourceMappingURL=phase-progress.CazP7K7B.js.map