@oomol-lab/open-flow 0.1.0-beta.29 → 0.1.0-beta.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7444,16 +7444,16 @@ var Kd = I(R([L({
7444
7444
  graph: Sf,
7445
7445
  subflows: z(V, xf.extend({ graph: Sf })),
7446
7446
  tasks: z(V, lf)
7447
- });
7448
- L({
7449
- modelVersion: B(2),
7447
+ }), Ef = L({
7448
+ modelVersion: R([B(2), B(3)]),
7450
7449
  document: Tf,
7451
7450
  modules: z(V, wf)
7452
- }).extend({
7451
+ });
7452
+ Ef.extend({ modelVersion: B(3) }), Ef.extend({
7453
7453
  kind: B("open-flow-flow-revision"),
7454
7454
  version: B(1)
7455
7455
  });
7456
- var Ef = {
7456
+ var Df = {
7457
7457
  "binding.create": {
7458
7458
  bindingId: V,
7459
7459
  binding: Cf
@@ -7616,13 +7616,13 @@ var Ef = {
7616
7616
  value: V
7617
7617
  }
7618
7618
  };
7619
- I(R([...new Map(Object.entries(Ef).map(([e, t]) => [e, t instanceof M ? t : L({
7619
+ I(R([...new Map(Object.entries(Df).map(([e, t]) => [e, t instanceof M ? t : L({
7620
7620
  kind: B(e),
7621
7621
  ...t
7622
7622
  })])).values()])).min(1);
7623
7623
  //#endregion
7624
7624
  //#region src/flow/common/change.ts
7625
- var Df = /* @__PURE__ */ new Set([
7625
+ var Of = /* @__PURE__ */ new Set([
7626
7626
  "const",
7627
7627
  "enum",
7628
7628
  "exclusiveMaximum",
@@ -7640,16 +7640,16 @@ var Df = /* @__PURE__ */ new Set([
7640
7640
  "required",
7641
7641
  "type"
7642
7642
  ]);
7643
- function Of(e) {
7644
- return Df.has(e);
7645
- }
7646
7643
  function kf(e) {
7647
- return e.length <= 256 && /^[A-Za-z_][A-Za-z0-9_]*$/.test(e) && e.slice(0, 3).toUpperCase() != "OO_";
7644
+ return Of.has(e);
7648
7645
  }
7649
7646
  function Af(e) {
7650
- return Object.fromEntries(e.flatMap((e) => "handle" in e ? [[e.handle, e]] : []));
7647
+ return e.length <= 256 && /^[A-Za-z_][A-Za-z0-9_]*$/.test(e) && e.slice(0, 3).toUpperCase() != "OO_";
7651
7648
  }
7652
7649
  function jf(e) {
7650
+ return Object.fromEntries(e.flatMap((e) => "handle" in e ? [[e.handle, e]] : []));
7651
+ }
7652
+ function Mf(e) {
7653
7653
  if (!Array.isArray(e)) throw TypeError("Connector capabilities must be an array.");
7654
7654
  let t = /* @__PURE__ */ new Set();
7655
7655
  return e.map((e) => {
@@ -7687,39 +7687,39 @@ function jf(e) {
7687
7687
  }
7688
7688
  //#endregion
7689
7689
  //#region src/flow/common/schema.ts
7690
- function Mf(e, t) {
7690
+ function Nf(e, t) {
7691
7691
  if (e === t) return !0;
7692
7692
  if (e == null || t == null || typeof e != "object" || typeof t != "object") return !1;
7693
- if (Array.isArray(e) || Array.isArray(t)) return Array.isArray(e) && Array.isArray(t) && e.length == t.length && e.every((e, n) => Mf(e, t[n]));
7693
+ if (Array.isArray(e) || Array.isArray(t)) return Array.isArray(e) && Array.isArray(t) && e.length == t.length && e.every((e, n) => Nf(e, t[n]));
7694
7694
  let n = Object.entries(e), r = t;
7695
- return n.length == Object.keys(r).length && n.every(([e, t]) => Object.hasOwn(r, e) && Mf(t, r[e]));
7695
+ return n.length == Object.keys(r).length && n.every(([e, t]) => Object.hasOwn(r, e) && Nf(t, r[e]));
7696
7696
  }
7697
- function Nf(e) {
7697
+ function Pf(e) {
7698
7698
  return typeof e == "object" && e && !Array.isArray(e) ? e : void 0;
7699
7699
  }
7700
- function Pf(e) {
7700
+ function Ff(e) {
7701
7701
  return Array.isArray(e) ? e : void 0;
7702
7702
  }
7703
- var Ff = /* @__PURE__ */ new WeakMap();
7704
- function If(e, t) {
7703
+ var If = /* @__PURE__ */ new WeakMap();
7704
+ function Lf(e, t) {
7705
7705
  if (typeof t == "boolean") return t;
7706
- let n = Nf(t);
7707
- if (n == null || n.properties != null && Nf(n.properties) == null) return !1;
7706
+ let n = Pf(t);
7707
+ if (n == null || n.properties != null && Pf(n.properties) == null) return !1;
7708
7708
  try {
7709
- let t = Ff.get(n);
7709
+ let t = If.get(n);
7710
7710
  if (t == null) {
7711
7711
  let e = typeof n.$schema == "string" ? n.$schema : "", r = e.includes("draft-04") ? "4" : e.includes("draft-07") ? "7" : e.includes("2020-12") ? "2020-12" : "2019-09";
7712
- t = new Ce(structuredClone(n), r), Ff.set(n, t);
7712
+ t = new Ce(structuredClone(n), r), If.set(n, t);
7713
7713
  }
7714
7714
  return t.validate(e).valid;
7715
7715
  } catch {
7716
7716
  return !1;
7717
7717
  }
7718
7718
  }
7719
- function Lf(e, t, n = !1, r = !1) {
7719
+ function Rf(e, t, n = !1, r = !1) {
7720
7720
  if (t === !0) return { kind: "compatible" };
7721
7721
  if (e === !1 || t === !1) return { kind: "incompatible" };
7722
- let i = e === !0 ? {} : Nf(e), a = Nf(t);
7722
+ let i = e === !0 ? {} : Pf(e), a = Pf(t);
7723
7723
  if (i == null || a == null) return {
7724
7724
  kind: "compare-error",
7725
7725
  message: "Port schema must be an object or boolean."
@@ -7738,20 +7738,20 @@ function Lf(e, t, n = !1, r = !1) {
7738
7738
  errorPath: Br(o.errorPath, r)
7739
7739
  } : o;
7740
7740
  }
7741
- function Rf(e, t) {
7741
+ function zf(e, t) {
7742
7742
  let n = e;
7743
7743
  for (let e of t) {
7744
7744
  if (typeof n != "object" || !n) return;
7745
- n = Array.isArray(n) ? n[Number(e)] : Nf(n)?.[String(e)];
7745
+ n = Array.isArray(n) ? n[Number(e)] : Pf(n)?.[String(e)];
7746
7746
  }
7747
7747
  return n;
7748
7748
  }
7749
- function zf(e, t, n) {
7749
+ function Bf(e, t, n) {
7750
7750
  if (e.nullable && !t.nullable) return { kind: "nullable" };
7751
7751
  if (n.error == "edgeError.binDiffType") return { kind: "binary" };
7752
7752
  if (n.error == "edgeError.artifactDiffType") return { kind: "artifact" };
7753
- let r = Nf(e.jsonSchema), i = Nf(t.jsonSchema), a = n.errorPath == null && r != null && i != null ? Bf(r, i) : void 0, o = a == null ? n.errorPath : [a], s = o?.at(-1);
7754
- if (typeof s != "string" || !Of(s)) return {
7753
+ let r = Pf(e.jsonSchema), i = Pf(t.jsonSchema), a = n.errorPath == null && r != null && i != null ? Vf(r, i) : void 0, o = a == null ? n.errorPath : [a], s = o?.at(-1);
7754
+ if (typeof s != "string" || !kf(s)) return {
7755
7755
  kind: "schema",
7756
7756
  path: o
7757
7757
  };
@@ -7760,19 +7760,19 @@ function zf(e, t, n) {
7760
7760
  kind: "keyword",
7761
7761
  keyword: s,
7762
7762
  path: c,
7763
- source: Rf(e.jsonSchema, [...c, s]),
7764
- target: Rf(t.jsonSchema, [...c, s])
7763
+ source: zf(e.jsonSchema, [...c, s]),
7764
+ target: zf(t.jsonSchema, [...c, s])
7765
7765
  };
7766
7766
  }
7767
- function Bf(e, t) {
7768
- if (!Mf(e.type, t.type)) return "type";
7769
- if (t.const !== void 0 && !Mf(e.const, t.const)) return "const";
7770
- if (t.enum !== void 0 && !Mf(e.enum, t.enum)) return "enum";
7767
+ function Vf(e, t) {
7768
+ if (!Nf(e.type, t.type)) return "type";
7769
+ if (t.const !== void 0 && !Nf(e.const, t.const)) return "const";
7770
+ if (t.enum !== void 0 && !Nf(e.enum, t.enum)) return "enum";
7771
7771
  let n = new Set(Array.isArray(e.required) ? e.required : []);
7772
7772
  if (Array.isArray(t.required) && t.required.some((e) => typeof e == "string" && !n.has(e))) return "required";
7773
- for (let n of Vf) if (t[n] !== void 0 && !Mf(e[n], t[n])) return n;
7773
+ for (let n of Hf) if (t[n] !== void 0 && !Nf(e[n], t[n])) return n;
7774
7774
  }
7775
- var Vf = [
7775
+ var Hf = [
7776
7776
  "minLength",
7777
7777
  "maxLength",
7778
7778
  "pattern",
@@ -7786,31 +7786,31 @@ var Vf = [
7786
7786
  "minProperties",
7787
7787
  "maxProperties"
7788
7788
  ];
7789
- function Hf(e, t) {
7790
- let n = Lf(e.jsonSchema, t.jsonSchema, e.nullable, t.nullable);
7789
+ function Uf(e, t) {
7790
+ let n = Rf(e.jsonSchema, t.jsonSchema, e.nullable, t.nullable);
7791
7791
  return n.kind == "incompatible" ? {
7792
7792
  kind: "incompatible",
7793
- mismatch: zf(e, t, n)
7793
+ mismatch: Bf(e, t, n)
7794
7794
  } : n;
7795
7795
  }
7796
- function Uf(e, t) {
7797
- return Hf(e, t).kind == "compatible";
7796
+ function Wf(e, t) {
7797
+ return Uf(e, t).kind == "compatible";
7798
7798
  }
7799
- function Wf(e) {
7800
- let t = Nf(e), n = Pf(t?.type);
7801
- return t != null && n?.includes("string") ? Lf({ type: "string" }, {
7799
+ function Gf(e) {
7800
+ let t = Pf(e), n = Ff(t?.type);
7801
+ return t != null && n?.includes("string") ? Rf({ type: "string" }, {
7802
7802
  ...t,
7803
7803
  type: "string"
7804
- }).kind == "compatible" : Lf({ type: "string" }, e).kind == "compatible";
7804
+ }).kind == "compatible" : Rf({ type: "string" }, e).kind == "compatible";
7805
7805
  }
7806
- function Gf(e) {
7806
+ function Kf(e) {
7807
7807
  if (typeof e != "object" || !e) return !1;
7808
7808
  let t = e;
7809
- return t.contentMediaType == "oomol/ref" || Object.values(t).some(Gf);
7809
+ return t.contentMediaType == "oomol/ref" || Object.values(t).some(Kf);
7810
7810
  }
7811
7811
  //#endregion
7812
7812
  //#region src/trigger/common/contract.ts
7813
- var Kf = [
7813
+ var qf = [
7814
7814
  {
7815
7815
  handle: "headers",
7816
7816
  jsonSchema: {
@@ -7843,7 +7843,7 @@ var Kf = [
7843
7843
  jsonSchema: { type: "string" },
7844
7844
  nullable: !1
7845
7845
  }
7846
- ], qf = [{
7846
+ ], Jf = [{
7847
7847
  description: "The scheduled time that triggered this run, in ISO 8601 format.",
7848
7848
  handle: "scheduledAt",
7849
7849
  jsonSchema: {
@@ -7852,13 +7852,13 @@ var Kf = [
7852
7852
  },
7853
7853
  nullable: !1
7854
7854
  }];
7855
- function Jf(e) {
7855
+ function Yf(e) {
7856
7856
  switch (e.kind) {
7857
7857
  case "manual": return [];
7858
- case "cron": return qf;
7858
+ case "cron": return Jf;
7859
7859
  case "poll":
7860
7860
  case "integration": return e.definition.outputs;
7861
- case "webhook": return Kf.map((t) => t.handle === "body" ? Object.assign({}, t, { jsonSchema: {
7861
+ case "webhook": return qf.map((t) => t.handle === "body" ? Object.assign({}, t, { jsonSchema: {
7862
7862
  type: "object",
7863
7863
  additionalProperties: !1,
7864
7864
  properties: Object.fromEntries(e.bodyFields.map((e) => [e.handle, e.jsonSchema])),
@@ -7866,24 +7866,24 @@ function Jf(e) {
7866
7866
  } }) : t);
7867
7867
  }
7868
7868
  }
7869
- function Yf(e) {
7870
- return Object.fromEntries(Jf(e).map(({ handle: e, ...t }) => [e, t]));
7869
+ function Xf(e) {
7870
+ return Object.fromEntries(Yf(e).map(({ handle: e, ...t }) => [e, t]));
7871
7871
  }
7872
- function Xf(e, n) {
7872
+ function Zf(e, n) {
7873
7873
  if (!t(n)) return !1;
7874
- let r = Jf(e);
7875
- return new Set(r.map((e) => e.handle)).size === r.length && Object.keys(n).length === r.length && r.every((e) => Object.hasOwn(n, e.handle) && (n[e.handle] === null && e.nullable || If(n[e.handle], e.jsonSchema)));
7874
+ let r = Yf(e);
7875
+ return new Set(r.map((e) => e.handle)).size === r.length && Object.keys(n).length === r.length && r.every((e) => Object.hasOwn(n, e.handle) && (n[e.handle] === null && e.nullable || Lf(n[e.handle], e.jsonSchema)));
7876
7876
  }
7877
7877
  //#endregion
7878
7878
  //#region src/execution/common/engineContract.ts
7879
- var Zf = "open-flow-engine/v5", Qf = "open-flow-engine/v5/nodejs-compat-v1", $f = {
7879
+ var Qf = "open-flow-engine/v5", $f = "open-flow-engine/v5/nodejs-compat-v1", ep = {
7880
7880
  platformExports: /* @__PURE__ */ new Set(["engineContract", "identity"]),
7881
7881
  platformModule: "open-flow:platform",
7882
- platformSource: `export const engineContract = ${JSON.stringify(Zf)}
7882
+ platformSource: `export const engineContract = ${JSON.stringify(Qf)}
7883
7883
  export function identity(value) { return value }
7884
7884
  `
7885
- }, ep = {
7886
- ...$f,
7885
+ }, tp = {
7886
+ ...ep,
7887
7887
  builtinModules: new Set([
7888
7888
  "assert",
7889
7889
  "assert/strict",
@@ -7910,13 +7910,13 @@ export function identity(value) { return value }
7910
7910
  "util",
7911
7911
  "zlib"
7912
7912
  ].flatMap((e) => [e, `node:${e}`])),
7913
- platformSource: `export const engineContract = ${JSON.stringify(Qf)}
7913
+ platformSource: `export const engineContract = ${JSON.stringify($f)}
7914
7914
  export function identity(value) { return value }
7915
7915
  `
7916
7916
  };
7917
- function tp(e) {
7918
- if (e == "open-flow-engine/v5") return $f;
7919
- if (e == "open-flow-engine/v5/nodejs-compat-v1") return ep;
7917
+ function np(e) {
7918
+ if (e == "open-flow-engine/v5") return ep;
7919
+ if (e == "open-flow-engine/v5/nodejs-compat-v1") return tp;
7920
7920
  }
7921
7921
  //#endregion
7922
7922
  //#region src/flow/common/agent.ts
@@ -8006,18 +8006,18 @@ var H = Bd(() => R([nd(), dd({
8006
8006
  maximum: F().optional(),
8007
8007
  exclusiveMinimum: F().optional(),
8008
8008
  exclusiveMaximum: F().optional()
8009
- }).transform(({ title: e, default: t, examples: n, readOnly: r, writeOnly: i, deprecated: a, $comment: o, ...s }) => s)])), np = /* @__PURE__ */ new Set([
8009
+ }).transform(({ title: e, default: t, examples: n, readOnly: r, writeOnly: i, deprecated: a, $comment: o, ...s }) => s)])), rp = /* @__PURE__ */ new Set([
8010
8010
  "properties",
8011
8011
  "patternProperties",
8012
8012
  "dependentSchemas",
8013
8013
  "$defs",
8014
8014
  "definitions"
8015
- ]), rp = /* @__PURE__ */ new Set([
8015
+ ]), ip = /* @__PURE__ */ new Set([
8016
8016
  "allOf",
8017
8017
  "anyOf",
8018
8018
  "oneOf",
8019
8019
  "prefixItems"
8020
- ]), ip = /* @__PURE__ */ new Set([
8020
+ ]), ap = /* @__PURE__ */ new Set([
8021
8021
  "not",
8022
8022
  "if",
8023
8023
  "then",
@@ -8030,10 +8030,10 @@ var H = Bd(() => R([nd(), dd({
8030
8030
  "unevaluatedProperties",
8031
8031
  "unevaluatedItems"
8032
8032
  ]);
8033
- function ap(e, t = !0) {
8034
- let n = H.parse(e), r = Nf(n)?.$schema?.toString().includes("draft-07") == 1, i = 0, a = (e, o, s) => {
8033
+ function op(e, t = !0) {
8034
+ let n = H.parse(e), r = Pf(n)?.$schema?.toString().includes("draft-07") == 1, i = 0, a = (e, o, s) => {
8035
8035
  if (++i > 4096 || s > 64) throw Error("Expanded schema exceeds the size or depth limit.");
8036
- let c = Nf(e);
8036
+ let c = Pf(e);
8037
8037
  if (c == null) return e;
8038
8038
  if (typeof c.$ref == "string") {
8039
8039
  let i = c.$ref;
@@ -8044,22 +8044,22 @@ function ap(e, t = !0) {
8044
8044
  }
8045
8045
  let l = n;
8046
8046
  for (let e of i == "#" ? [] : i.slice(2).split("/")) {
8047
- let t = decodeURIComponent(e).replace(/~1/g, "/").replace(/~0/g, "~"), n = Array.isArray(l) ? Object.fromEntries(l.map((e, t) => [String(t), e])) : Nf(l);
8047
+ let t = decodeURIComponent(e).replace(/~1/g, "/").replace(/~0/g, "~"), n = Array.isArray(l) ? Object.fromEntries(l.map((e, t) => [String(t), e])) : Pf(l);
8048
8048
  if (n == null || !Object.hasOwn(n, t)) throw Error(`Unresolved schema reference: ${i}`);
8049
8049
  l = n[t];
8050
8050
  }
8051
- if (typeof l != "boolean" && Nf(l) == null) throw Error(`Reference does not point to a schema: ${i}`);
8051
+ if (typeof l != "boolean" && Pf(l) == null) throw Error(`Reference does not point to a schema: ${i}`);
8052
8052
  let u = a(l, [...o, i], s + 1), { $ref: d, ...f } = c;
8053
8053
  return r || Object.keys(f).length == 0 ? u : { allOf: [u, a(f, o, s + 1)] };
8054
8054
  }
8055
- return Object.fromEntries(Object.entries(c).flatMap(([e, t]) => e == "$defs" || e == "definitions" || e == "$schema" ? [] : np.has(e) ? [[e, Object.fromEntries(Object.entries(Nf(t) ?? {}).map(([e, t]) => [e, a(t, o, s + 1)]))]] : rp.has(e) || e == "items" && Array.isArray(t) ? [[e, t.map((e) => a(e, o, s + 1))]] : ip.has(e) ? [[e, a(t, o, s + 1)]] : e == "dependencies" ? [[e, Object.fromEntries(Object.entries(Nf(t) ?? {}).map(([e, t]) => [e, Array.isArray(t) ? t : a(t, o, s + 1)]))]] : [[e, t]]));
8055
+ return Object.fromEntries(Object.entries(c).flatMap(([e, t]) => e == "$defs" || e == "definitions" || e == "$schema" ? [] : rp.has(e) ? [[e, Object.fromEntries(Object.entries(Pf(t) ?? {}).map(([e, t]) => [e, a(t, o, s + 1)]))]] : ip.has(e) || e == "items" && Array.isArray(t) ? [[e, t.map((e) => a(e, o, s + 1))]] : ap.has(e) ? [[e, a(t, o, s + 1)]] : e == "dependencies" ? [[e, Object.fromEntries(Object.entries(Pf(t) ?? {}).map(([e, t]) => [e, Array.isArray(t) ? t : a(t, o, s + 1)]))]] : [[e, t]]));
8056
8056
  };
8057
8057
  return a(n, [], 0);
8058
8058
  }
8059
- function op(e, t = !1) {
8059
+ function sp(e, t = !1) {
8060
8060
  let n = H.safeParse(e);
8061
8061
  if (n.success) try {
8062
- ap(e, t);
8062
+ op(e, t);
8063
8063
  return;
8064
8064
  } catch (e) {
8065
8065
  return e instanceof Error ? e.message : String(e);
@@ -8072,26 +8072,26 @@ function op(e, t = !1) {
8072
8072
  let i = r.find((e) => e.code == "unrecognized_keys") ?? r.at(-1), a = i.code == "unrecognized_keys" ? `unsupported keywords: ${i.keys.join(", ")}` : i.message;
8073
8073
  return `${i.path.length == 0 ? "" : `${i.path.map(String).join(".")}: `}${a}`;
8074
8074
  }
8075
- function sp(e, t) {
8075
+ function cp(e, t) {
8076
8076
  if (e.executor.kind != "agent") return [];
8077
- let n = e.executor, r = [], i = Af(e.inputs), a = (e, t) => {
8078
- if (e.kind == "value") return !(e.value === null && t.nullable) && !If(e.value, t.jsonSchema);
8077
+ let n = e.executor, r = [], i = jf(e.inputs), a = (e, t) => {
8078
+ if (e.kind == "value") return !(e.value === null && t.nullable) && !Lf(e.value, t.jsonSchema);
8079
8079
  let n = i[e.input];
8080
- return n == null || !Uf(n, t);
8080
+ return n == null || !Wf(n, t);
8081
8081
  };
8082
8082
  n.model.trim().length == 0 && r.push("Choose an Agent model."), (!Number.isSafeInteger(n.maxRounds) || n.maxRounds < 1 || n.maxRounds > 100) && r.push("Agent maxRounds must be between 1 and 100."), a(n.prompt, {
8083
8083
  jsonSchema: { type: "string" },
8084
8084
  nullable: !1
8085
8085
  }) && r.push("Agent prompt must resolve to a string input or value.");
8086
8086
  let o = e.outputs.filter((e) => "handle" in e);
8087
- (o.length != 1 || o[0]?.handle != "output" || o[0].nullable || op(o[0].jsonSchema) != null) && r.push("Agent requires one non-nullable output named output with a supported JSON schema."), (n.tools.length == 0 && n.code != 1 || n.tools.length > 64) && r.push("Declare up to 64 Agent tools and enable at least one tool or code computation.");
8087
+ (o.length != 1 || o[0]?.handle != "output" || o[0].nullable || sp(o[0].jsonSchema) != null) && r.push("Agent requires one non-nullable output named output with a supported JSON schema."), (n.tools.length == 0 && n.code != 1 || n.tools.length > 64) && r.push("Declare up to 64 Agent tools and enable at least one tool or code computation.");
8088
8088
  let s = /* @__PURE__ */ new Set(), c = /* @__PURE__ */ new Set();
8089
8089
  for (let e of n.tools) {
8090
8090
  (e.id.length == 0 || s.has(e.id)) && r.push("Agent tool identities must be non-empty and unique."), (!/^[A-Za-z][A-Za-z0-9_-]{0,63}$/.test(e.name) || c.has(e.name)) && r.push("Agent tool names must be unique provider-compatible names."), (e.name == "read_result" || e.name == "run_code") && r.push(`Tool name ${e.name} is reserved for built-in Agent tools.`), s.add(e.id), c.add(e.name), e.description.trim().length == 0 && r.push(`Tool ${e.name} requires a description.`), (!/^[A-Za-z0-9_-]+\.[A-Za-z0-9_.-]+$/.test(e.action) || e.connectionId === "") && r.push(`Tool ${e.name} has an invalid Action or Connection.`);
8091
8091
  let t = /* @__PURE__ */ new Set();
8092
8092
  for (let n of e.inputs) {
8093
8093
  (n.handle.length == 0 || t.has(n.handle)) && r.push(`Tool ${e.name} has an empty or duplicate input.`), t.add(n.handle);
8094
- let i = op(n.jsonSchema, n.source.kind == "model");
8094
+ let i = sp(n.jsonSchema, n.source.kind == "model");
8095
8095
  i != null && r.push(`Tool ${e.name} input ${n.handle} has an invalid schema (${i}).`), Object.hasOwn(n, "value") && r.push(`Tool ${e.name} input ${n.handle} must specify its value through source.`), n.source.kind != "model" && a(n.source, n) && r.push(`Tool ${e.name} input ${n.handle} has an incompatible source.`);
8096
8096
  }
8097
8097
  }
@@ -8099,8 +8099,8 @@ function sp(e, t) {
8099
8099
  let e = n.notification, i = t[e.taskId];
8100
8100
  if (i?.executor.kind != "connector") r.push("Agent notification must reference a Connector Task.");
8101
8101
  else {
8102
- let t = Af(i.inputs), n = t[e.messageHandle];
8103
- (n == null || !Uf({
8102
+ let t = jf(i.inputs), n = t[e.messageHandle];
8103
+ (n == null || !Wf({
8104
8104
  jsonSchema: { type: "string" },
8105
8105
  nullable: !1
8106
8106
  }, n)) && r.push("Agent notification requires a string message input."), Object.hasOwn(e.inputs, e.messageHandle) && r.push("Agent notification message is supplied by the host.");
@@ -8113,18 +8113,18 @@ function sp(e, t) {
8113
8113
  }
8114
8114
  return r;
8115
8115
  }
8116
- function cp(e, t) {
8116
+ function lp(e, t) {
8117
8117
  if (e.kind == "value") return e.value;
8118
8118
  if (!Object.hasOwn(t, e.input)) throw Error(`Agent input ${e.input} is missing.`);
8119
8119
  return t[e.input];
8120
8120
  }
8121
- function lp(e) {
8121
+ function up(e) {
8122
8122
  let t = e.inputs.filter((e) => e.source.kind == "model");
8123
8123
  return {
8124
8124
  type: "object",
8125
8125
  additionalProperties: !1,
8126
8126
  properties: Object.fromEntries(t.map((e) => {
8127
- let t = ap(e.jsonSchema);
8127
+ let t = op(e.jsonSchema);
8128
8128
  return [e.handle, {
8129
8129
  ...e.nullable ? { anyOf: [t, { type: "null" }] } : typeof t == "object" && t ? t : { allOf: [t] },
8130
8130
  ...e.description == null ? {} : { description: e.description }
@@ -8133,36 +8133,36 @@ function lp(e) {
8133
8133
  required: t.map((e) => e.handle)
8134
8134
  };
8135
8135
  }
8136
- function up(e, t, n) {
8136
+ function dp(e, t, n) {
8137
8137
  Gd(n);
8138
8138
  let r = z(N(), Wd()).parse(n);
8139
- if (!If(r, lp(e))) throw Error(`Tool ${e.name} arguments do not match the model input schema.`);
8139
+ if (!Lf(r, up(e))) throw Error(`Tool ${e.name} arguments do not match the model input schema.`);
8140
8140
  return Object.fromEntries(e.inputs.map((n) => {
8141
- let i = n.source.kind == "model" ? r[n.handle] : cp(n.source, t);
8142
- if (i === void 0 || !(i === null && n.nullable) && !If(i, n.jsonSchema)) throw Error(`Tool ${e.name} input ${n.handle} is invalid.`);
8141
+ let i = n.source.kind == "model" ? r[n.handle] : lp(n.source, t);
8142
+ if (i === void 0 || !(i === null && n.nullable) && !Lf(i, n.jsonSchema)) throw Error(`Tool ${e.name} input ${n.handle} is invalid.`);
8143
8143
  return [n.handle, i];
8144
8144
  }));
8145
8145
  }
8146
8146
  //#endregion
8147
8147
  //#region src/flow/common/encoding.ts
8148
- var dp = new TextEncoder();
8149
- function fp(e) {
8148
+ var fp = new TextEncoder();
8149
+ function pp(e) {
8150
8150
  if (e == null || typeof e == "boolean" || typeof e == "string" || typeof e == "number") return JSON.stringify(e);
8151
- if (Array.isArray(e)) return `[${e.map(fp).join(",")}]`;
8151
+ if (Array.isArray(e)) return `[${e.map(pp).join(",")}]`;
8152
8152
  let t = e;
8153
- return `{${Object.keys(t).toSorted().map((e) => `${JSON.stringify(e)}:${fp(t[e])}`).join(",")}}`;
8153
+ return `{${Object.keys(t).toSorted().map((e) => `${JSON.stringify(e)}:${pp(t[e])}`).join(",")}}`;
8154
8154
  }
8155
- function pp(e) {
8156
- return dp.encode(fp(e));
8155
+ function mp(e) {
8156
+ return fp.encode(pp(e));
8157
8157
  }
8158
- async function mp(e) {
8158
+ async function hp(e) {
8159
8159
  let t = new Uint8Array(e.byteLength);
8160
8160
  return t.set(e), `sha256:${[...new Uint8Array(await crypto.subtle.digest("SHA-256", t))].map((e) => e.toString(16).padStart(2, "0")).join("")}`;
8161
8161
  }
8162
- function hp(e) {
8162
+ function gp(e) {
8163
8163
  return Object.keys(e).toSorted().map((t) => [t, e[t]]);
8164
8164
  }
8165
- function gp(e) {
8165
+ function _p(e) {
8166
8166
  return "handle" in e ? {
8167
8167
  ...e.description == null ? {} : { description: e.description },
8168
8168
  handle: e.handle,
@@ -8174,10 +8174,10 @@ function gp(e) {
8174
8174
  group: e.group
8175
8175
  };
8176
8176
  }
8177
- function _p(e) {
8178
- return e.map(gp);
8179
- }
8180
8177
  function vp(e) {
8178
+ return e.map(_p);
8179
+ }
8180
+ function yp(e) {
8181
8181
  switch (e.kind) {
8182
8182
  case "sources": return {
8183
8183
  kind: e.kind,
@@ -8189,10 +8189,10 @@ function vp(e) {
8189
8189
  };
8190
8190
  }
8191
8191
  }
8192
- function yp(e) {
8193
- return Object.fromEntries(hp(e).map(([e, t]) => [e, vp(t)]));
8194
- }
8195
8192
  function bp(e) {
8193
+ return Object.fromEntries(gp(e).map(([e, t]) => [e, yp(t)]));
8194
+ }
8195
+ function xp(e) {
8196
8196
  return e.map((e) => ({
8197
8197
  ...e.description == null ? {} : { description: e.description },
8198
8198
  handle: e.handle,
@@ -8201,12 +8201,12 @@ function bp(e) {
8201
8201
  sources: e.sources.map((e) => ({ ...e }))
8202
8202
  }));
8203
8203
  }
8204
- function xp(e) {
8205
- if (!("inputs" in e)) return Op(e);
8204
+ function Sp(e) {
8205
+ if (!("inputs" in e)) return Ip(e);
8206
8206
  let t = {
8207
8207
  ...e.description == null ? {} : { description: e.description },
8208
8208
  ...e.icon == null ? {} : { icon: e.icon },
8209
- inputs: yp(e.inputs),
8209
+ inputs: bp(e.inputs),
8210
8210
  ...e.name == null ? {} : { name: e.name },
8211
8211
  ...e.maxExecutions == null ? {} : { maxExecutions: e.maxExecutions },
8212
8212
  ...e.timeoutMs == null ? {} : { timeoutMs: e.timeoutMs }
@@ -8226,7 +8226,7 @@ function xp(e) {
8226
8226
  ...e.defaultOutput == null ? {} : { defaultOutput: e.defaultOutput },
8227
8227
  input: {
8228
8228
  handle: e.input.handle,
8229
- ...gp(e.input)
8229
+ ..._p(e.input)
8230
8230
  },
8231
8231
  kind: e.kind
8232
8232
  };
@@ -8241,54 +8241,114 @@ function xp(e) {
8241
8241
  taskId: e.taskId
8242
8242
  }) : Object.assign({}, t, {
8243
8243
  kind: e.kind,
8244
- task: wp(e.task)
8244
+ task: Mp(e.task)
8245
8245
  });
8246
- return e.additionalInputs != null && (n.additionalInputs = _p(e.additionalInputs)), n;
8246
+ return e.additionalInputs != null && (n.additionalInputs = vp(e.additionalInputs)), n;
8247
8247
  }
8248
8248
  case "value": return {
8249
8249
  ...t,
8250
8250
  kind: e.kind,
8251
- values: _p(e.values)
8251
+ values: vp(e.values)
8252
8252
  };
8253
8253
  case "approval":
8254
8254
  case "wait": return {
8255
8255
  ...t,
8256
8256
  input: {
8257
8257
  handle: e.input.handle,
8258
- ...gp(e.input)
8258
+ ..._p(e.input)
8259
8259
  },
8260
8260
  kind: e.kind,
8261
8261
  prompt: e.prompt
8262
8262
  };
8263
8263
  }
8264
8264
  }
8265
- function Sp(e) {
8265
+ function Cp(e) {
8266
8266
  return {
8267
8267
  edges: e.edges.map((e) => ({ ...e })).toSorted((e, t) => {
8268
- let n = fp(e), r = fp(t);
8268
+ let n = pp(e), r = pp(t);
8269
8269
  return n < r ? -1 : +(n > r);
8270
8270
  }),
8271
- nodes: Object.fromEntries(hp(e.nodes).map(([e, t]) => [e, xp(t)]))
8271
+ nodes: Object.fromEntries(gp(e.nodes).map(([e, t]) => [e, Sp(t)]))
8272
8272
  };
8273
8273
  }
8274
- function Cp(e) {
8274
+ function wp(e) {
8275
+ return new Set(Object.entries(e.nodes).flatMap(([e, t]) => t.kind == "approval" || t.kind == "wait" ? [e] : []));
8276
+ }
8277
+ function Tp(e, t) {
8278
+ let n = typeof e == "object" && e && !Array.isArray(e) ? e : void 0;
8279
+ return n?.kind == "node" && typeof n.nodeId == "string" && t.has(n.nodeId) && n.output == "pending" ? {
8280
+ ...n,
8281
+ output: "notification"
8282
+ } : e;
8283
+ }
8284
+ function Ep(e, t) {
8285
+ let n = bp(e);
8286
+ return Object.fromEntries(gp(n).map(([e, n]) => {
8287
+ let r = typeof n == "object" && n && !Array.isArray(n) ? n : void 0;
8288
+ return r?.kind != "sources" || !Array.isArray(r.sources) ? [e, n] : [e, {
8289
+ ...r,
8290
+ sources: r.sources.map((e) => Tp(e, t))
8291
+ }];
8292
+ }));
8293
+ }
8294
+ function Dp(e) {
8295
+ let t = wp(e);
8296
+ return {
8297
+ edges: e.edges.map((e) => t.has(e.source) && e.sourceHandle == "pending" ? {
8298
+ ...e,
8299
+ sourceHandle: "notification"
8300
+ } : { ...e }).toSorted((e, t) => {
8301
+ let n = pp(e), r = pp(t);
8302
+ return n < r ? -1 : +(n > r);
8303
+ }),
8304
+ nodes: Object.fromEntries(gp(e.nodes).map(([e, n]) => {
8305
+ let r = Sp(n);
8306
+ return n.kind != "approval" && n.kind != "wait" ? [e, "inputs" in n ? {
8307
+ ...r,
8308
+ inputs: Ep(n.inputs, t)
8309
+ } : r] : [e, {
8310
+ ...r,
8311
+ actions: n.kind == "wait" ? ["continue"] : ["approve", "reject"],
8312
+ inputs: Ep(n.inputs, t),
8313
+ kind: "wait"
8314
+ }];
8315
+ }))
8316
+ };
8317
+ }
8318
+ function Op(e, t) {
8319
+ let n = wp(t);
8320
+ return e.map((e) => ({
8321
+ ...e.description == null ? {} : { description: e.description },
8322
+ handle: e.handle,
8323
+ jsonSchema: e.jsonSchema,
8324
+ nullable: e.nullable,
8325
+ sources: e.sources.map((e) => Tp(e, n))
8326
+ }));
8327
+ }
8328
+ function kp(e, t) {
8329
+ return e.modelVersion == 2 ? Dp(t) : Cp(t);
8330
+ }
8331
+ function Ap(e, t, n) {
8332
+ return e.modelVersion == 2 ? Op(t, n) : xp(t);
8333
+ }
8334
+ function jp(e) {
8275
8335
  return {
8276
8336
  executor: e.executor,
8277
- inputs: _p(e.inputs),
8337
+ inputs: vp(e.inputs),
8278
8338
  name: e.name,
8279
- outputs: _p(e.outputs)
8339
+ outputs: vp(e.outputs)
8280
8340
  };
8281
8341
  }
8282
- function wp(e) {
8342
+ function Mp(e) {
8283
8343
  return {
8284
8344
  ...e.capabilities == null ? {} : { capabilities: e.capabilities },
8285
- inputs: _p(e.inputs),
8345
+ inputs: vp(e.inputs),
8286
8346
  moduleId: e.moduleId,
8287
8347
  name: e.name,
8288
- outputs: _p(e.outputs)
8348
+ outputs: vp(e.outputs)
8289
8349
  };
8290
8350
  }
8291
- function Tp(e) {
8351
+ function Np(e) {
8292
8352
  return {
8293
8353
  configSchema: e.configSchema,
8294
8354
  definitionVersion: e.definitionVersion,
@@ -8305,12 +8365,12 @@ function Tp(e) {
8305
8365
  } } : {},
8306
8366
  key: e.key,
8307
8367
  name: e.name,
8308
- outputs: _p(e.outputs),
8368
+ outputs: vp(e.outputs),
8309
8369
  provider: e.provider,
8310
8370
  type: e.type
8311
8371
  };
8312
8372
  }
8313
- function Ep(e) {
8373
+ function Pp(e) {
8314
8374
  return {
8315
8375
  ...e.allowedMethods == null ? {} : { allowedMethods: e.allowedMethods },
8316
8376
  ...e.allowedOrigins == null ? {} : { allowedOrigins: e.allowedOrigins },
@@ -8320,7 +8380,7 @@ function Ep(e) {
8320
8380
  ...e.responseStatusCode == null ? {} : { responseStatusCode: e.responseStatusCode }
8321
8381
  };
8322
8382
  }
8323
- function Dp(e) {
8383
+ function Fp(e) {
8324
8384
  switch (e.type) {
8325
8385
  case "cron": return {
8326
8386
  expression: e.expression,
@@ -8334,7 +8394,7 @@ function Dp(e) {
8334
8394
  };
8335
8395
  }
8336
8396
  }
8337
- function Op(e) {
8397
+ function Ip(e) {
8338
8398
  let t = (t) => ({
8339
8399
  ...e.description == null ? {} : { description: e.description },
8340
8400
  ...e.icon == null ? {} : { icon: e.icon },
@@ -8347,42 +8407,42 @@ function Op(e) {
8347
8407
  ...t(e.kind),
8348
8408
  bodyFields: e.bodyFields.map((e) => ({
8349
8409
  handle: e.handle,
8350
- ...gp(e)
8410
+ ..._p(e)
8351
8411
  })),
8352
- ...e.options == null ? {} : { options: Ep(e.options) }
8412
+ ...e.options == null ? {} : { options: Pp(e.options) }
8353
8413
  };
8354
8414
  case "cron": return {
8355
8415
  ...t(e.kind),
8356
- cronTimes: e.cronTimes.map(Dp)
8416
+ cronTimes: e.cronTimes.map(Fp)
8357
8417
  };
8358
8418
  case "poll": return {
8359
8419
  ...t(e.kind),
8360
8420
  bindingId: e.bindingId,
8361
8421
  config: e.config,
8362
- definition: Tp(e.definition),
8363
- pollTimes: e.pollTimes.map(Dp)
8422
+ definition: Np(e.definition),
8423
+ pollTimes: e.pollTimes.map(Fp)
8364
8424
  };
8365
8425
  case "integration": return {
8366
8426
  ...t(e.kind),
8367
8427
  bindingId: e.bindingId,
8368
8428
  config: e.config,
8369
- definition: Tp(e.definition)
8429
+ definition: Np(e.definition)
8370
8430
  };
8371
8431
  }
8372
8432
  }
8373
- function kp(e) {
8433
+ function Lp(e) {
8374
8434
  return {
8375
8435
  imports: e.imports.toSorted(),
8376
8436
  name: e.name,
8377
8437
  source: e.source
8378
8438
  };
8379
8439
  }
8380
- var Ap = z(N(), od()), jp = L({
8440
+ var Rp = z(N(), od()), zp = L({
8381
8441
  jsonSchema: od(),
8382
8442
  nullable: nd(),
8383
8443
  value: od().optional(),
8384
8444
  description: N().optional()
8385
- }).strict(), Mp = z(N(), jp), Np = R([L({
8445
+ }).strict(), Bp = z(N(), zp), Vp = R([L({
8386
8446
  kind: B("value"),
8387
8447
  value: od()
8388
8448
  }).strict(), L({
@@ -8392,36 +8452,36 @@ var Ap = z(N(), od()), jp = L({
8392
8452
  nodeId: N(),
8393
8453
  output: N()
8394
8454
  }).strict())
8395
- }).strict()]), Pp = {
8455
+ }).strict()]), Hp = {
8396
8456
  name: N().optional(),
8397
8457
  description: N().optional(),
8398
8458
  icon: N().optional()
8399
- }, Fp = R([
8459
+ }, Up = R([
8400
8460
  L({
8401
- ...Pp,
8461
+ ...Hp,
8402
8462
  kind: B("cron"),
8403
8463
  cronTimes: I(od())
8404
8464
  }).strict(),
8405
8465
  L({
8406
- ...Pp,
8466
+ ...Hp,
8407
8467
  kind: B("manual")
8408
8468
  }).strict(),
8409
8469
  L({
8410
- ...Pp,
8470
+ ...Hp,
8411
8471
  kind: B("task"),
8412
8472
  concurrency: B(1).optional(),
8413
- inputs: z(N(), Np),
8473
+ inputs: z(N(), Vp),
8414
8474
  task: L({
8415
8475
  name: N(),
8416
8476
  moduleId: N(),
8417
- inputs: Mp,
8418
- outputs: z(N(), jp.omit({ value: !0 }))
8477
+ inputs: Bp,
8478
+ outputs: z(N(), zp.omit({ value: !0 }))
8419
8479
  }).strict()
8420
8480
  }).strict()
8421
8481
  ]);
8422
8482
  L({
8423
8483
  name: N(),
8424
- graph: L({ nodes: z(N(), Fp) }).strict()
8484
+ graph: L({ nodes: z(N(), Up) }).strict()
8425
8485
  }).strict(), L({
8426
8486
  kind: B("open-flow-project-revision"),
8427
8487
  version: B(1),
@@ -8432,15 +8492,15 @@ L({
8432
8492
  imports: I(N())
8433
8493
  }).strict()),
8434
8494
  document: L({
8435
- bindings: Ap,
8436
- flows: Ap,
8437
- subflows: Ap,
8438
- tasks: Ap
8495
+ bindings: Rp,
8496
+ flows: Rp,
8497
+ subflows: Rp,
8498
+ tasks: Rp
8439
8499
  }).strict()
8440
8500
  }).strict();
8441
8501
  //#endregion
8442
8502
  //#region src/flow/common/graph.ts
8443
- function Ip(e) {
8503
+ function Wp(e) {
8444
8504
  return e?.kind == "approval" || e?.kind == "wait";
8445
8505
  }
8446
8506
  function U(e, t, n, r, i) {
@@ -8454,8 +8514,8 @@ function U(e, t, n, r, i) {
8454
8514
  ...r == null ? {} : { values: r }
8455
8515
  };
8456
8516
  }
8457
- function Lp(e, t, n, r, i) {
8458
- let a = Jf(t).map((e) => e.handle);
8517
+ function Gp(e, t, n, r, i) {
8518
+ let a = Yf(t).map((e) => e.handle);
8459
8519
  if (new Set(a).size !== a.length && i.push(U("graph.port-duplicate", "Trigger output handles must be unique.", `${r}/definition/outputs`)), t.kind == "webhook") {
8460
8520
  let e = /* @__PURE__ */ new Set();
8461
8521
  for (let [n, a] of t.bodyFields.entries()) e.has(a.handle) && i.push(U("trigger.input-duplicate", `Webhook Trigger input "${a.handle}" is declared more than once.`, `${r}/bodyFields/${n}/handle`, { input: a.handle })), e.add(a.handle);
@@ -8464,15 +8524,15 @@ function Lp(e, t, n, r, i) {
8464
8524
  if (t.kind == "cron" || t.kind == "manual") return;
8465
8525
  let o = n.bindings[t.bindingId];
8466
8526
  o == null ? i.push(U("trigger.connection-missing", `Trigger Connection binding "${t.bindingId}" does not exist.`, `${r}/bindingId`, { bindingId: t.bindingId })) : o.kind != "connection" && i.push(U("trigger.connection-invalid", `Trigger binding "${t.bindingId}" must be a Connection.`, `${r}/bindingId`, { bindingId: t.bindingId }));
8467
- let s = Pf(Nf(t.definition.configSchema)?.required)?.filter((e) => typeof e == "string" && !Object.hasOwn(t.config, e)) ?? [];
8468
- s.length > 0 ? i.push(U("trigger.config-incomplete", `Complete the required Trigger config fields: ${s.join(", ")}.`, `${r}/config`, { fields: s.join(", ") })) : If(t.config, t.definition.configSchema) || i.push(U("trigger.config-invalid", `Trigger "${e}" config does not match its fixed definition.`, `${r}/config`, { triggerId: e }));
8527
+ let s = Ff(Pf(t.definition.configSchema)?.required)?.filter((e) => typeof e == "string" && !Object.hasOwn(t.config, e)) ?? [];
8528
+ s.length > 0 ? i.push(U("trigger.config-incomplete", `Complete the required Trigger config fields: ${s.join(", ")}.`, `${r}/config`, { fields: s.join(", ") })) : Lf(t.config, t.definition.configSchema) || i.push(U("trigger.config-invalid", `Trigger "${e}" config does not match its fixed definition.`, `${r}/config`, { triggerId: e }));
8469
8529
  }
8470
- function Rp(e, t) {
8530
+ function Kp(e, t) {
8471
8531
  switch (t.kind) {
8472
8532
  case "condition": return { [t.input.handle]: t.input };
8473
8533
  case "value": return {};
8474
- case "subflow": return Af(e.subflows[t.subflowId]?.inputs ?? []);
8475
- case "task": return Af([...t.task == null ? e.tasks[t.taskId]?.inputs ?? [] : t.task.inputs, ...t.additionalInputs ?? []]);
8534
+ case "subflow": return jf(e.subflows[t.subflowId]?.inputs ?? []);
8535
+ case "task": return jf([...t.task == null ? e.tasks[t.taskId]?.inputs ?? [] : t.task.inputs, ...t.additionalInputs ?? []]);
8476
8536
  case "approval":
8477
8537
  case "wait": return { [t.input.handle]: t.input };
8478
8538
  case "cron":
@@ -8482,11 +8542,11 @@ function Rp(e, t) {
8482
8542
  case "webhook": return {};
8483
8543
  }
8484
8544
  }
8485
- function zp(e) {
8545
+ function qp(e) {
8486
8546
  return e.kind == "wait" ? ["continue"] : ["approve", "reject"];
8487
8547
  }
8488
- function Bp(e) {
8489
- let t = zp(e);
8548
+ function Jp(e) {
8549
+ let t = qp(e);
8490
8550
  return {
8491
8551
  pending: {
8492
8552
  nullable: !1,
@@ -8525,28 +8585,28 @@ function Bp(e) {
8525
8585
  }]))
8526
8586
  };
8527
8587
  }
8528
- function Vp(e, t) {
8588
+ function Yp(e, t) {
8529
8589
  switch (t.kind) {
8530
8590
  case "condition": {
8531
8591
  let e = [...t.cases.map((e) => e.output), ...t.defaultOutput == null ? [] : [t.defaultOutput]];
8532
8592
  return Object.fromEntries(e.map((e) => [e, t.input]));
8533
8593
  }
8534
- case "value": return Af(t.values);
8535
- case "subflow": return Af(e.subflows[t.subflowId]?.outputs ?? []);
8536
- case "task": return Af(t.task == null ? e.tasks[t.taskId]?.outputs ?? [] : t.task.outputs);
8594
+ case "value": return jf(t.values);
8595
+ case "subflow": return jf(e.subflows[t.subflowId]?.outputs ?? []);
8596
+ case "task": return jf(t.task == null ? e.tasks[t.taskId]?.outputs ?? [] : t.task.outputs);
8537
8597
  case "approval":
8538
- case "wait": return Bp(t);
8598
+ case "wait": return Jp(t);
8539
8599
  case "cron":
8540
8600
  case "integration":
8541
8601
  case "poll":
8542
8602
  case "manual":
8543
- case "webhook": return Yf(t);
8603
+ case "webhook": return Xf(t);
8544
8604
  }
8545
8605
  }
8546
- function Hp(e, t, n, r, i, a, o) {
8606
+ function Xp(e, t, n, r, i, a, o) {
8547
8607
  switch (e.kind) {
8548
8608
  case "binding":
8549
- n.bindings[e.bindingId] == null ? o.push(U("graph.binding-missing", `Binding "${e.bindingId}" does not exist.`, a, { bindingId: e.bindingId })) : n.bindings[e.bindingId].kind == "variable" ? i != null && !Wf(i.jsonSchema) && o.push(U("graph.variable-incompatible", `Variable binding "${e.bindingId}" is not compatible with this input.`, a, { bindingId: e.bindingId })) : o.push(U("graph.binding-invalid", `Binding "${e.bindingId}" must be a Variable.`, a, { bindingId: e.bindingId }));
8609
+ n.bindings[e.bindingId] == null ? o.push(U("graph.binding-missing", `Binding "${e.bindingId}" does not exist.`, a, { bindingId: e.bindingId })) : n.bindings[e.bindingId].kind == "variable" ? i != null && !Gf(i.jsonSchema) && o.push(U("graph.variable-incompatible", `Variable binding "${e.bindingId}" is not compatible with this input.`, a, { bindingId: e.bindingId })) : o.push(U("graph.binding-invalid", `Binding "${e.bindingId}" must be a Variable.`, a, { bindingId: e.bindingId }));
8550
8610
  return;
8551
8611
  case "flow": {
8552
8612
  let t = r != null && Object.hasOwn(r, e.input) ? r[e.input] : void 0;
@@ -8555,7 +8615,7 @@ function Hp(e, t, n, r, i, a, o) {
8555
8615
  variant: "flow-input"
8556
8616
  }));
8557
8617
  else if (i != null) {
8558
- let n = Hf(t, i);
8618
+ let n = Uf(t, i);
8559
8619
  n.kind != "compatible" && o.push(U("graph.flow-input-incompatible", `Flow input "${e.input}" is not compatible with this input.`, a, { input: e.input }, n.kind == "incompatible" ? n.mismatch : void 0));
8560
8620
  }
8561
8621
  return t;
@@ -8569,14 +8629,14 @@ function Hp(e, t, n, r, i, a, o) {
8569
8629
  }));
8570
8630
  return;
8571
8631
  }
8572
- let s = Vp(n, r)[e.output];
8632
+ let s = Yp(n, r)[e.output];
8573
8633
  if (s == null) o.push(U("graph.source-missing", `Upstream node "${e.nodeId}" does not expose output "${e.output}".`, a, {
8574
8634
  nodeId: e.nodeId,
8575
8635
  output: e.output,
8576
8636
  variant: "output"
8577
8637
  }));
8578
8638
  else if (i != null) {
8579
- let t = Hf(s, i);
8639
+ let t = Uf(s, i);
8580
8640
  t.kind != "compatible" && o.push(U("graph.node-output-incompatible", `Upstream node "${e.nodeId}" output "${e.output}" is not compatible with this input.`, a, {
8581
8641
  nodeId: e.nodeId,
8582
8642
  output: e.output
@@ -8586,7 +8646,7 @@ function Hp(e, t, n, r, i, a, o) {
8586
8646
  }
8587
8647
  }
8588
8648
  }
8589
- function Up(e) {
8649
+ function Zp(e) {
8590
8650
  let t = new Map(Object.keys(e.nodes).map((e) => [e, /* @__PURE__ */ new Set()])), n = /* @__PURE__ */ new Map();
8591
8651
  for (let r of e.edges) {
8592
8652
  if (!t.has(r.source) || !t.has(r.target)) continue;
@@ -8605,25 +8665,25 @@ function Up(e) {
8605
8665
  }
8606
8666
  return [...r, ...[...t.keys()].toSorted()];
8607
8667
  }
8608
- var Wp = /* @__PURE__ */ new WeakMap();
8609
- function Gp(e, t) {
8668
+ var Qp = /* @__PURE__ */ new WeakMap();
8669
+ function $p(e, t) {
8610
8670
  return Object.entries(e).every(([e, n]) => t[e] == n);
8611
8671
  }
8612
- function Kp(e, t) {
8672
+ function em(e, t) {
8613
8673
  return Object.entries(e).every(([e, n]) => t[e] == null || t[e] == n);
8614
8674
  }
8615
- function qp(e, t) {
8675
+ function tm(e, t) {
8616
8676
  return JSON.stringify([e, t]);
8617
8677
  }
8618
- function Jp(e) {
8619
- let t = Wp.get(e);
8678
+ function nm(e) {
8679
+ let t = Qp.get(e);
8620
8680
  if (t != null) return t;
8621
8681
  let n = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Map(), i = /* @__PURE__ */ new Map(), a = /* @__PURE__ */ new Map();
8622
8682
  for (let t of e.edges) {
8623
8683
  let e = a.get(t.target) ?? [];
8624
8684
  e.push(t), a.set(t.target, e);
8625
8685
  }
8626
- let o = Up(e), s = !0;
8686
+ let o = Zp(e), s = !0;
8627
8687
  for (; s;) {
8628
8688
  s = !1;
8629
8689
  for (let t of o) {
@@ -8631,21 +8691,21 @@ function Jp(e) {
8631
8691
  for (let t of c) {
8632
8692
  l.add(t.source);
8633
8693
  for (let e of i.get(t.source) ?? []) u.add(e);
8634
- Ip(e.nodes[t.source]) && t.sourceHandle != null && u.add(qp(t.source, t.sourceHandle));
8694
+ Wp(e.nodes[t.source]) && t.sourceHandle != null && u.add(tm(t.source, t.sourceHandle));
8635
8695
  for (let e of r.get(t.source) ?? []) l.add(e);
8636
8696
  for (let r of n.get(t.source) ?? []) {
8637
- let n = t.sourceHandle == null || Ip(e.nodes[t.source]) && t.sourceHandle == "pending" ? r : {
8697
+ let n = t.sourceHandle == null || Wp(e.nodes[t.source]) && t.sourceHandle == "pending" ? r : {
8638
8698
  ...r,
8639
8699
  [t.source]: t.sourceHandle
8640
8700
  };
8641
- if (!d.some((e) => Gp(e, n))) {
8642
- for (let e = d.length - 1; e >= 0; e--) Gp(n, d[e]) && d.splice(e, 1);
8701
+ if (!d.some((e) => $p(e, n))) {
8702
+ for (let e = d.length - 1; e >= 0; e--) $p(n, d[e]) && d.splice(e, 1);
8643
8703
  d.push(n);
8644
8704
  }
8645
8705
  }
8646
8706
  }
8647
8707
  let f = c.length == 0 ? "inputs" in o ? [{}] : [{ $trigger: t }] : d, p = n.get(t) ?? [];
8648
- (l.size != (r.get(t)?.size ?? 0) || u.size != (i.get(t)?.size ?? 0) || f.length != p.length || f.some((e) => !p.some((t) => Gp(t, e) && Gp(e, t)))) && (s = !0), r.set(t, l), i.set(t, u), n.set(t, f);
8708
+ (l.size != (r.get(t)?.size ?? 0) || u.size != (i.get(t)?.size ?? 0) || f.length != p.length || f.some((e) => !p.some((t) => $p(t, e) && $p(e, t)))) && (s = !0), r.set(t, l), i.set(t, u), n.set(t, f);
8649
8709
  }
8650
8710
  }
8651
8711
  let c = {
@@ -8653,51 +8713,51 @@ function Jp(e) {
8653
8713
  paths: n,
8654
8714
  resolutionOutputs: i
8655
8715
  };
8656
- return Wp.set(e, c), c;
8716
+ return Qp.set(e, c), c;
8657
8717
  }
8658
- function Yp(e, t, n) {
8718
+ function rm(e, t, n) {
8659
8719
  if (n.kind != "node") return [{}];
8660
8720
  let r = e.nodes[n.nodeId], i = t.get(n.nodeId) ?? [];
8661
- return r?.kind == "condition" || Ip(r) && n.output != "pending" ? i.map((e) => ({
8721
+ return r?.kind == "condition" || Wp(r) && n.output != "pending" ? i.map((e) => ({
8662
8722
  ...e,
8663
8723
  [n.nodeId]: n.output
8664
8724
  })) : i;
8665
8725
  }
8666
- function Xp(e, t, n, r) {
8726
+ function im(e, t, n, r) {
8667
8727
  if (n.kind == "value") return !0;
8668
8728
  let { ancestors: i, paths: a } = r;
8669
- if (t != null && n.sources.some((e) => e.kind == "node" && !i.get(t)?.has(e.nodeId)) || t != null && n.sources.some((n) => n.kind == "node" && Ip(e.nodes[n.nodeId]) && !r.resolutionOutputs.get(t)?.has(qp(n.nodeId, n.output)))) return !1;
8670
- let o = n.sources.map((t) => Yp(e, a, t)), s = t == null ? [{}] : a.get(t) ?? [];
8729
+ if (t != null && n.sources.some((e) => e.kind == "node" && !i.get(t)?.has(e.nodeId)) || t != null && n.sources.some((n) => n.kind == "node" && Wp(e.nodes[n.nodeId]) && !r.resolutionOutputs.get(t)?.has(tm(n.nodeId, n.output)))) return !1;
8730
+ let o = n.sources.map((t) => rm(e, a, t)), s = t == null ? [{}] : a.get(t) ?? [];
8671
8731
  for (let [e, r] of o.entries()) for (let [a, c] of o.slice(e + 1).entries()) {
8672
8732
  let o = n.sources[e], l = n.sources[e + a + 1];
8673
8733
  if (!(t != null && o.kind == "node" && l.kind == "node" && o.nodeId != l.nodeId && !i.get(o.nodeId)?.has(l.nodeId) && !i.get(l.nodeId)?.has(o.nodeId))) for (let e of r) for (let t of s) {
8674
- if (!Kp(e, t)) continue;
8734
+ if (!em(e, t)) continue;
8675
8735
  let n = {
8676
8736
  ...t,
8677
8737
  ...e
8678
8738
  };
8679
- if (c.some((e) => Kp(e, n))) return !1;
8739
+ if (c.some((e) => em(e, n))) return !1;
8680
8740
  }
8681
8741
  }
8682
8742
  return !0;
8683
8743
  }
8684
- function Zp(e, t, n, r) {
8685
- let i = Jp(t);
8744
+ function am(e, t, n, r) {
8745
+ let i = nm(t);
8686
8746
  return Object.fromEntries([...i.ancestors.get(n) ?? []].flatMap((a) => {
8687
8747
  let o = t.nodes[a];
8688
8748
  if (o == null) return [];
8689
- let s = Object.keys(Vp(e, o)).filter((s) => Xp(t, n, {
8749
+ let s = Object.keys(Yp(e, o)).filter((s) => im(t, n, {
8690
8750
  kind: "sources",
8691
8751
  sources: [{
8692
8752
  kind: "node",
8693
8753
  nodeId: a,
8694
8754
  output: s
8695
8755
  }]
8696
- }, i) && (r == null || Uf(Vp(e, o)[s], Rp(e, t.nodes[n])[r])));
8756
+ }, i) && (r == null || Wf(Yp(e, o)[s], Kp(e, t.nodes[n])[r])));
8697
8757
  return s.length == 0 ? [] : [[a, s]];
8698
8758
  }));
8699
8759
  }
8700
- function Qp(e, t, n, r, i) {
8760
+ function om(e, t, n, r, i) {
8701
8761
  let a = /* @__PURE__ */ new Set([
8702
8762
  "description",
8703
8763
  "icon",
@@ -8713,15 +8773,15 @@ function Qp(e, t, n, r, i) {
8713
8773
  nodeId: e
8714
8774
  })), n || i.push(U(`${t.kind}.not-allowed`, `${o} nodes are only allowed in Flows.`, r)), t.input.handle != "value" && i.push(U(`${t.kind}.input-invalid`, `${o} input handle must be "value".`, `${r}/input/handle`)), (typeof t.prompt != "string" || t.prompt.trim().length == 0 || [...t.prompt].length > 1e3) && i.push(U(`${t.kind}.prompt-invalid`, `${o} prompt must contain between 1 and 1,000 Unicode code points.`, `${r}/prompt`));
8715
8775
  }
8716
- function $p(e, t, n, r, i, a) {
8717
- let o = Jp(e), s = Object.entries(e.nodes).filter(([, e]) => e.kind == "manual");
8776
+ function sm(e, t, n, r, i, a) {
8777
+ let o = nm(e), s = Object.entries(e.nodes).filter(([, e]) => e.kind == "manual");
8718
8778
  if (s.length > 1) for (let [e] of s) a.push(U("graph.manual-trigger-duplicate", "A graph can contain only one manual Trigger.", `${i}/nodes/${e}`));
8719
8779
  let c = /* @__PURE__ */ new Set();
8720
8780
  for (let [t, n] of e.edges.entries()) {
8721
8781
  let r = `${i}/edges/${t}`, o = e.nodes[n.source], s = e.nodes[n.target];
8722
8782
  if (o == null || s == null || !("inputs" in s)) a.push(U("graph.edge-invalid", "Execution edges require an existing source and an executable target.", r));
8723
- else if (o.kind == "condition" || Ip(o)) {
8724
- let e = Ip(o) ? Object.keys(Bp(o)) : [...o.cases.map((e) => e.output), ...o.defaultOutput == null ? [] : [o.defaultOutput]];
8783
+ else if (o.kind == "condition" || Wp(o)) {
8784
+ let e = Wp(o) ? Object.keys(Jp(o)) : [...o.cases.map((e) => e.output), ...o.defaultOutput == null ? [] : [o.defaultOutput]];
8725
8785
  (n.sourceHandle == null || !e.some((e) => e == n.sourceHandle)) && a.push(U("graph.edge-invalid", "Choose a declared execution branch.", r));
8726
8786
  } else n.sourceHandle != null && a.push(U("graph.edge-invalid", "Ordinary execution edges do not select a data output.", r));
8727
8787
  let l = JSON.stringify([
@@ -8734,7 +8794,7 @@ function $p(e, t, n, r, i, a) {
8734
8794
  for (let [s, c] of Object.entries(e.nodes)) {
8735
8795
  let l = `${i}/nodes/${s}`;
8736
8796
  if ("inputs" in c && c.maxExecutions != null && (!Number.isSafeInteger(c.maxExecutions) || c.maxExecutions < 1) && a.push(U("node.max-executions-invalid", "Maximum executions must be a positive safe integer.", `${l}/maxExecutions`)), !("inputs" in c)) {
8737
- Jf(c).some((e) => Gf(e.jsonSchema)) && a.push(U("graph.schema-unsupported", "Runtime Ref schemas are not supported.", l)), r ? Lp(s, c, t, l, a) : a.push(U("graph.trigger-not-allowed", "Trigger nodes are only allowed in Flows.", l));
8797
+ Yf(c).some((e) => Kf(e.jsonSchema)) && a.push(U("graph.schema-unsupported", "Runtime Ref schemas are not supported.", l)), r ? Gp(s, c, t, l, a) : a.push(U("graph.trigger-not-allowed", "Trigger nodes are only allowed in Flows.", l));
8738
8798
  continue;
8739
8799
  }
8740
8800
  c.kind == "task" && c.task == null && t.tasks[c.taskId] == null ? a.push(U("graph.target-missing", `Task "${c.taskId}" does not exist.`, `${l}/taskId`, {
@@ -8744,8 +8804,8 @@ function $p(e, t, n, r, i, a) {
8744
8804
  subflowId: c.subflowId,
8745
8805
  variant: "subflow"
8746
8806
  }));
8747
- for (let [t, n] of Object.entries(c.inputs)) Xp(e, s, n, o) || a.push(U("graph.source-unavailable", "Input sources must reference execution ancestors, respect pending Wait decisions, and never provide multiple values on the same path.", `${l}/inputs/${t}`));
8748
- let u = Rp(t, c);
8807
+ for (let [t, n] of Object.entries(c.inputs)) im(e, s, n, o) || a.push(U("graph.source-unavailable", "Input sources must reference execution ancestors, respect pending Wait decisions, and never provide multiple values on the same path.", `${l}/inputs/${t}`));
8808
+ let u = Kp(t, c);
8749
8809
  if (c.kind == "task") {
8750
8810
  let e = [...c.task == null ? t.tasks[c.taskId]?.inputs ?? [] : c.task.inputs, ...c.additionalInputs ?? []], n = /* @__PURE__ */ new Set();
8751
8811
  for (let t of e) "handle" in t && (n.has(t.handle) && a.push(U("graph.input-duplicate", `Node "${s}" declares input "${t.handle}" more than once.`, l, {
@@ -8753,7 +8813,7 @@ function $p(e, t, n, r, i, a) {
8753
8813
  nodeId: s
8754
8814
  })), n.add(t.handle));
8755
8815
  }
8756
- [...Object.values(u), ...Object.values(Vp(t, c))].some((e) => Gf(e.jsonSchema)) && a.push(U("graph.schema-unsupported", "Runtime Ref schemas are not supported.", l));
8816
+ [...Object.values(u), ...Object.values(Yp(t, c))].some((e) => Kf(e.jsonSchema)) && a.push(U("graph.schema-unsupported", "Runtime Ref schemas are not supported.", l));
8757
8817
  let d = new Set(Object.keys(u));
8758
8818
  for (let [r, i] of Object.entries(c.inputs)) {
8759
8819
  let o = `${l}/inputs/${r}`;
@@ -8763,10 +8823,10 @@ function $p(e, t, n, r, i, a) {
8763
8823
  })), i.kind == "sources") {
8764
8824
  let s = i.sources.filter((e) => e.kind == "binding" && t.bindings[e.bindingId]?.kind == "variable");
8765
8825
  s.length > 0 && (s.length != 1 || i.sources.length != 1) && a.push(U("graph.variable-source-mixed", "A Variable must be the only source for an input.", o));
8766
- for (let s of i.sources) Hp(s, e, t, n, u[r], o, a);
8826
+ for (let s of i.sources) Xp(s, e, t, n, u[r], o, a);
8767
8827
  }
8768
8828
  }
8769
- if (Ip(c) && Qp(s, c, r, l, a), c.kind != "condition") continue;
8829
+ if (Wp(c) && om(s, c, r, l, a), c.kind != "condition") continue;
8770
8830
  let f = /* @__PURE__ */ new Set();
8771
8831
  for (let [e, t] of c.cases.entries()) {
8772
8832
  f.has(t.output) && a.push(U("condition.output-duplicate", `Condition output "${t.output}" is declared more than once.`, `${l}/cases/${e}/output`, { output: t.output })), f.add(t.output);
@@ -8774,7 +8834,7 @@ function $p(e, t, n, r, i, a) {
8774
8834
  }
8775
8835
  }
8776
8836
  }
8777
- function em(e, t) {
8837
+ function cm(e, t) {
8778
8838
  let n = /* @__PURE__ */ new Set(), r = [];
8779
8839
  function i(a, o) {
8780
8840
  for (let [s, c] of Object.entries(a.nodes)) {
@@ -8790,35 +8850,35 @@ function em(e, t) {
8790
8850
  }
8791
8851
  i(e.graph, "/document/graph");
8792
8852
  }
8793
- function tm(e, t) {
8853
+ function lm(e, t) {
8794
8854
  let n = [];
8795
- for (let [t, r] of Object.entries(e.document.bindings)) r.kind == "variable" && !kf(r.target) && n.push(U("binding.variable-invalid", `Variable binding "${t}" has an invalid target.`, `/document/bindings/${t}/target`, { bindingId: t }));
8796
- $p(e.document.graph, e.document, void 0, !0, "/document/graph", n);
8855
+ for (let [t, r] of Object.entries(e.document.bindings)) r.kind == "variable" && !Af(r.target) && n.push(U("binding.variable-invalid", `Variable binding "${t}" has an invalid target.`, `/document/bindings/${t}/target`, { bindingId: t }));
8856
+ sm(e.document.graph, e.document, void 0, !0, "/document/graph", n);
8797
8857
  for (let r of [...t.dependencies.subflows].toSorted()) {
8798
8858
  let t = e.document.subflows[r];
8799
8859
  if (t == null) continue;
8800
- let i = `/document/subflows/${r}`, a = Af(t.inputs);
8801
- $p(t.graph, e.document, a, !1, `${i}/graph`, n);
8860
+ let i = `/document/subflows/${r}`, a = jf(t.inputs);
8861
+ sm(t.graph, e.document, a, !1, `${i}/graph`, n);
8802
8862
  for (let r of t.outputs) {
8803
- Xp(t.graph, void 0, {
8863
+ im(t.graph, void 0, {
8804
8864
  kind: "sources",
8805
8865
  sources: r.sources
8806
- }, Jp(t.graph)) || n.push(U("graph.source-unavailable", "Subflow output sources must not provide multiple final values.", `${i}/outputs/${r.handle}/sources`));
8866
+ }, nm(t.graph)) || n.push(U("graph.source-unavailable", "Subflow output sources must not provide multiple final values.", `${i}/outputs/${r.handle}/sources`));
8807
8867
  for (let o of r.sources) {
8808
- let s = Hp(o, t.graph, e.document, a, void 0, `${i}/outputs/${r.handle}/sources`, n), c = s == null ? void 0 : Hf(s, r);
8868
+ let s = Xp(o, t.graph, e.document, a, void 0, `${i}/outputs/${r.handle}/sources`, n), c = s == null ? void 0 : Uf(s, r);
8809
8869
  c != null && c.kind != "compatible" && n.push(U("graph.subflow-output-incompatible", `A source is not compatible with Subflow output "${r.handle}".`, `${i}/outputs/${r.handle}/sources`, { output: r.handle }, c.kind == "incompatible" ? c.mismatch : void 0));
8810
8870
  }
8811
8871
  }
8812
8872
  }
8813
- return em(e.document, n), n;
8873
+ return cm(e.document, n), n;
8814
8874
  }
8815
8875
  //#endregion
8816
8876
  //#region ../../node_modules/.bun/@babel+parser@8.0.4/node_modules/@babel/parser/lib/index.js
8817
- var nm = class {
8877
+ var um = class {
8818
8878
  constructor(e, t, n) {
8819
8879
  this.line = void 0, this.column = void 0, n !== void 0 && (this.index = void 0), this.line = e, this.column = t, n !== void 0 && (this.index = n);
8820
8880
  }
8821
- }, rm = class {
8881
+ }, dm = class {
8822
8882
  start;
8823
8883
  end;
8824
8884
  filename;
@@ -8827,20 +8887,20 @@ var nm = class {
8827
8887
  this.start = e, this.end = t;
8828
8888
  }
8829
8889
  };
8830
- function im(e, t) {
8890
+ function fm(e, t) {
8831
8891
  let { line: n, column: r, index: i } = e;
8832
- return new nm(n, r + t, i + t);
8892
+ return new um(n, r + t, i + t);
8833
8893
  }
8834
- var am = "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED", om = {
8894
+ var pm = "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED", mm = {
8835
8895
  ImportMetaOutsideModule: {
8836
8896
  message: "import.meta may appear only with 'sourceType: \"module\"'",
8837
- code: am
8897
+ code: pm
8838
8898
  },
8839
8899
  ImportOutsideModule: {
8840
8900
  message: "'import' and 'export' may appear only with 'sourceType: \"module\"'",
8841
- code: am
8901
+ code: pm
8842
8902
  }
8843
- }, sm = {
8903
+ }, hm = {
8844
8904
  ArrayPattern: "array destructuring pattern",
8845
8905
  AssignmentExpression: "assignment expression",
8846
8906
  AssignmentPattern: "assignment expression",
@@ -8864,7 +8924,7 @@ var am = "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED", om = {
8864
8924
  },
8865
8925
  VariableDeclarator: "variable declaration",
8866
8926
  YieldExpression: "yield expression"
8867
- }, cm = (e) => e.type === "UpdateExpression" ? sm.UpdateExpression[`${e.prefix}`] : sm[e.type], lm = {
8927
+ }, gm = (e) => e.type === "UpdateExpression" ? hm.UpdateExpression[`${e.prefix}`] : hm[e.type], _m = {
8868
8928
  AccessorIsGenerator: ({ kind: e }) => `A ${e}ter cannot be a generator.`,
8869
8929
  ArgumentsInClass: "'arguments' is only allowed in functions and class methods.",
8870
8930
  AsyncFunctionInSingleStatementContext: "Async functions can only be declared at the top level or inside a block.",
@@ -8921,9 +8981,9 @@ var am = "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED", om = {
8921
8981
  InvalidEscapeSequenceTemplate: "Invalid escape sequence in template.",
8922
8982
  InvalidEscapedReservedWord: ({ reservedWord: e }) => `Escape sequence in keyword ${e}.`,
8923
8983
  InvalidIdentifier: ({ identifierName: e }) => `Invalid identifier ${e}.`,
8924
- InvalidLhs: ({ ancestor: e }) => `Invalid left-hand side in ${cm(e)}.`,
8925
- InvalidLhsBinding: ({ ancestor: e }) => `Binding invalid left-hand side in ${cm(e)}.`,
8926
- InvalidLhsOptionalChaining: ({ ancestor: e }) => `Invalid optional chaining in the left-hand side of ${cm(e)}.`,
8984
+ InvalidLhs: ({ ancestor: e }) => `Invalid left-hand side in ${gm(e)}.`,
8985
+ InvalidLhsBinding: ({ ancestor: e }) => `Binding invalid left-hand side in ${gm(e)}.`,
8986
+ InvalidLhsOptionalChaining: ({ ancestor: e }) => `Invalid optional chaining in the left-hand side of ${gm(e)}.`,
8927
8987
  InvalidNumber: "Invalid number.",
8928
8988
  InvalidOrMissingExponent: "Floating-point numbers require a valid exponent after the 'e'.",
8929
8989
  InvalidOrUnexpectedToken: ({ unexpected: e }) => `Unexpected character '${e}'.`,
@@ -9004,7 +9064,7 @@ var am = "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED", om = {
9004
9064
  YieldInParameter: "Yield expression is not allowed in formal parameters.",
9005
9065
  YieldNotInGeneratorFunction: "'yield' is only allowed within generator functions.",
9006
9066
  ZeroDigitNumericSeparator: "Numeric separator can not be used after leading 0."
9007
- }, um = {
9067
+ }, vm = {
9008
9068
  StrictDelete: "Deleting local variable in strict mode.",
9009
9069
  StrictEvalArguments: ({ referenceName: e }) => `Assigning to '${e}' in strict mode.`,
9010
9070
  StrictEvalArgumentsBinding: ({ bindingName: e }) => `Binding '${e}' in strict mode.`,
@@ -9012,43 +9072,43 @@ var am = "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED", om = {
9012
9072
  StrictNumericEscape: "The only valid numeric escape in strict mode is '\\0'.",
9013
9073
  StrictOctalLiteral: "Legacy octal literals are not allowed in strict mode.",
9014
9074
  StrictWith: "'with' in strict mode."
9015
- }, dm = {
9075
+ }, ym = {
9016
9076
  ParseExpressionEmptyInput: "Unexpected parseExpression() input: The input is empty or contains only comments.",
9017
9077
  ParseExpressionExpectsEOF: ({ unexpected: e }) => `Unexpected parseExpression() input: The input should contain exactly one expression, but the first expression is followed by the unexpected character \`${String.fromCodePoint(e)}\`.`
9018
- }, fm = /* @__PURE__ */ new Set([
9078
+ }, bm = /* @__PURE__ */ new Set([
9019
9079
  "ArrowFunctionExpression",
9020
9080
  "AssignmentExpression",
9021
9081
  "ConditionalExpression",
9022
9082
  "YieldExpression"
9023
- ]), pm = {
9083
+ ]), xm = {
9024
9084
  PipeTopicRequiresHackPipes: "Topic references are only supported when using the `\"proposal\": \"hack\"` version of the pipeline proposal.",
9025
9085
  PipeTopicUnbound: "Topic reference is unbound; it must be inside a pipe body.",
9026
9086
  PipeTopicUnconfiguredToken: ({ token: e }) => `Invalid topic token ${e}. In order to use ${e} as a topic reference, the pipelineOperator plugin must be configured with { "proposal": "hack", "topicToken": "${e}" }.`,
9027
9087
  PipeTopicUnused: "Hack-style pipe body does not contain a topic reference; Hack-style pipes must use topic at least once.",
9028
- PipeUnparenthesizedBody: ({ type: e }) => `Hack-style pipe body cannot be an unparenthesized ${cm({ type: e })}; please wrap it in parentheses.`,
9088
+ PipeUnparenthesizedBody: ({ type: e }) => `Hack-style pipe body cannot be an unparenthesized ${gm({ type: e })}; please wrap it in parentheses.`,
9029
9089
  PipelineUnparenthesized: "Cannot mix binary operator with solo-await F#-style pipeline. Please wrap the pipeline in parentheses."
9030
- }, mm = {
9090
+ }, Sm = {
9031
9091
  UnsupportedBind: "Binding should be performed on object property.",
9032
9092
  UnsupportedBindRHS: "The right-hand side of binding can not be super or import."
9033
9093
  };
9034
- function hm(e, t, n) {
9094
+ function Cm(e, t, n) {
9035
9095
  Object.defineProperty(e, t, {
9036
9096
  enumerable: !1,
9037
9097
  configurable: !0,
9038
9098
  value: n
9039
9099
  });
9040
9100
  }
9041
- function gm({ toMessage: e, code: t, reasonCode: n, syntaxPlugin: r }) {
9101
+ function wm({ toMessage: e, code: t, reasonCode: n, syntaxPlugin: r }) {
9042
9102
  let i = n === "MissingPlugin" || n === "MissingOneOfPlugins";
9043
9103
  return function a(o, s, c) {
9044
9104
  let l = /* @__PURE__ */ SyntaxError();
9045
- return l.code = t, l.reasonCode = n, l.loc = o, l.pos = s, l.syntaxPlugin = r, i && (l.missingPlugin = c.missingPlugin), hm(l, "clone", function(e = {}) {
9105
+ return l.code = t, l.reasonCode = n, l.loc = o, l.pos = s, l.syntaxPlugin = r, i && (l.missingPlugin = c.missingPlugin), Cm(l, "clone", function(e = {}) {
9046
9106
  let { line: t, column: n, index: r = s } = e.loc ?? o;
9047
- return a(new nm(t, n), r, {
9107
+ return a(new um(t, n), r, {
9048
9108
  ...c,
9049
9109
  ...e.details
9050
9110
  });
9051
- }), hm(l, "details", c), Object.defineProperty(l, "message", {
9111
+ }), Cm(l, "details", c), Object.defineProperty(l, "message", {
9052
9112
  configurable: !0,
9053
9113
  get() {
9054
9114
  let t = `${e(c)} (${o.line}:${o.column})`;
@@ -9063,12 +9123,12 @@ function gm({ toMessage: e, code: t, reasonCode: n, syntaxPlugin: r }) {
9063
9123
  }), l;
9064
9124
  };
9065
9125
  }
9066
- function _m(e, t) {
9067
- if (Array.isArray(e)) return (t) => _m(t, e[0]);
9126
+ function Tm(e, t) {
9127
+ if (Array.isArray(e)) return (t) => Tm(t, e[0]);
9068
9128
  let n = {};
9069
9129
  for (let r of Object.keys(e)) {
9070
9130
  let i = e[r], { message: a, ...o } = typeof i == "string" ? { message: () => i } : typeof i == "function" ? { message: i } : i;
9071
- n[r] = gm({
9131
+ n[r] = wm({
9072
9132
  code: "BABEL_PARSER_SYNTAX_ERROR",
9073
9133
  reasonCode: r,
9074
9134
  toMessage: typeof a == "string" ? () => a : a,
@@ -9079,14 +9139,14 @@ function _m(e, t) {
9079
9139
  return n;
9080
9140
  }
9081
9141
  var W = {
9082
- ..._m(om),
9083
- ..._m(lm),
9084
- ..._m(um),
9085
- ..._m(dm),
9086
- ..._m`pipelineOperator`(pm),
9087
- ..._m`functionBind`(mm)
9142
+ ...Tm(mm),
9143
+ ...Tm(_m),
9144
+ ...Tm(vm),
9145
+ ...Tm(ym),
9146
+ ...Tm`pipelineOperator`(xm),
9147
+ ...Tm`functionBind`(Sm)
9088
9148
  };
9089
- function vm() {
9149
+ function Em() {
9090
9150
  return {
9091
9151
  sourceType: "script",
9092
9152
  sourceFilename: void 0,
@@ -9112,8 +9172,8 @@ function vm() {
9112
9172
  annexB: !0
9113
9173
  };
9114
9174
  }
9115
- function ym(e) {
9116
- let t = vm();
9175
+ function Dm(e) {
9176
+ let t = Em();
9117
9177
  if (e == null) return t;
9118
9178
  if (e.annexB != null && e.annexB !== !1) throw Error("The `annexB` option can only be set to `false`.");
9119
9179
  for (let n of Object.keys(t)) e[n] != null && (t[n] = e[n]);
@@ -9126,17 +9186,17 @@ function ym(e) {
9126
9186
  }
9127
9187
  return t;
9128
9188
  }
9129
- function bm(e) {
9189
+ function Om(e) {
9130
9190
  let { start: t, end: n } = e.loc;
9131
- return e.loc.start = new nm(t.line, t.column), e.loc.end = new nm(n.line, n.column), e;
9191
+ return e.loc.start = new um(t.line, t.column), e.loc.end = new um(n.line, n.column), e;
9132
9192
  }
9133
- var xm = (e) => class extends e {
9193
+ var km = (e) => class extends e {
9134
9194
  createPosition(e) {
9135
- return new nm(e.line, e.column);
9195
+ return new um(e.line, e.column);
9136
9196
  }
9137
9197
  parse() {
9138
9198
  let e = super.parse();
9139
- return this.optionFlags & 512 && (e.tokens = e.tokens.map(bm)), bm(e);
9199
+ return this.optionFlags & 512 && (e.tokens = e.tokens.map(Om)), Om(e);
9140
9200
  }
9141
9201
  parseRegExpLiteral({ pattern: e, flags: t }) {
9142
9202
  let n = null;
@@ -9318,22 +9378,22 @@ var xm = (e) => class extends e {
9318
9378
  return e.type === "Literal" ? this.cloneEstreeStringLiteral(e) : super.cloneStringLiteral(e);
9319
9379
  }
9320
9380
  finishNodeAt(e, t, n) {
9321
- return bm(super.finishNodeAt(e, t, n));
9381
+ return Om(super.finishNodeAt(e, t, n));
9322
9382
  }
9323
9383
  finishNodeAtNode(e, t, n) {
9324
- return bm(super.finishNodeAtNode(e, t, n));
9384
+ return Om(super.finishNodeAtNode(e, t, n));
9325
9385
  }
9326
9386
  finishNode(e, t) {
9327
9387
  let n = super.finishNode(e, t);
9328
9388
  return this.fillOptionalPropertiesForTSESLint(n), n;
9329
9389
  }
9330
9390
  resetStartLocation(e, t) {
9331
- super.resetStartLocation(e, t), bm(e);
9391
+ super.resetStartLocation(e, t), Om(e);
9332
9392
  }
9333
9393
  resetEndLocation(e, t = this.state.lastTokEndLoc) {
9334
- super.resetEndLocation(e, t), bm(e);
9394
+ super.resetEndLocation(e, t), Om(e);
9335
9395
  }
9336
- }, G = !0, K = !0, Sm = !0, Cm = !0, wm = !0, Tm = !0, Em = class {
9396
+ }, G = !0, K = !0, Am = !0, jm = !0, Mm = !0, Nm = !0, Pm = class {
9337
9397
  label;
9338
9398
  keyword;
9339
9399
  beforeExpr;
@@ -9347,26 +9407,26 @@ var xm = (e) => class extends e {
9347
9407
  constructor(e, t = {}) {
9348
9408
  this.label = e, this.keyword = t.keyword, this.beforeExpr = !!t.beforeExpr, this.startsExpr = !!t.startsExpr, this.rightAssociative = !!t.rightAssociative, this.isLoop = !!t.isLoop, this.isAssign = !!t.isAssign, this.prefix = !!t.prefix, this.postfix = !!t.postfix, this.binop = t.binop == null ? null : t.binop;
9349
9409
  }
9350
- }, Dm = /* @__PURE__ */ new Map();
9410
+ }, Fm = /* @__PURE__ */ new Map();
9351
9411
  function q(e, t = {}) {
9352
9412
  t.keyword = e;
9353
9413
  let n = J(e, t);
9354
- return Dm.set(e, n), n;
9414
+ return Fm.set(e, n), n;
9355
9415
  }
9356
- function Om(e, t) {
9416
+ function Im(e, t) {
9357
9417
  return J(e, {
9358
9418
  beforeExpr: G,
9359
9419
  binop: t
9360
9420
  });
9361
9421
  }
9362
- var km = -1, Am = [], jm = [], Mm = [], Nm = [], Pm = [], Fm = [];
9422
+ var Lm = -1, Rm = [], zm = [], Bm = [], Vm = [], Hm = [], Um = [];
9363
9423
  function J(e, t = {}) {
9364
- return ++km, jm.push(e), Mm.push(t.binop ?? -1), Nm.push(t.beforeExpr ?? !1), Pm.push(t.startsExpr ?? !1), Fm.push(t.prefix ?? !1), Am.push(new Em(e, t)), km;
9424
+ return ++Lm, zm.push(e), Bm.push(t.binop ?? -1), Vm.push(t.beforeExpr ?? !1), Hm.push(t.startsExpr ?? !1), Um.push(t.prefix ?? !1), Rm.push(new Pm(e, t)), Lm;
9365
9425
  }
9366
9426
  function Y(e, t = {}) {
9367
- return ++km, Dm.set(e, km), jm.push(e), Mm.push(t.binop ?? -1), Nm.push(t.beforeExpr ?? !1), Pm.push(t.startsExpr ?? !1), Fm.push(t.prefix ?? !1), Am.push(new Em("name", t)), km;
9427
+ return ++Lm, Fm.set(e, Lm), zm.push(e), Bm.push(t.binop ?? -1), Vm.push(t.beforeExpr ?? !1), Hm.push(t.startsExpr ?? !1), Um.push(t.prefix ?? !1), Rm.push(new Pm("name", t)), Lm;
9368
9428
  }
9369
- var Im = {
9429
+ var Wm = {
9370
9430
  bracketL: J("[", {
9371
9431
  beforeExpr: G,
9372
9432
  startsExpr: K
@@ -9412,59 +9472,59 @@ var Im = {
9412
9472
  interpreterDirective: J("#!..."),
9413
9473
  eq: J("=", {
9414
9474
  beforeExpr: G,
9415
- isAssign: Cm
9475
+ isAssign: jm
9416
9476
  }),
9417
9477
  assign: J("_=", {
9418
9478
  beforeExpr: G,
9419
- isAssign: Cm
9479
+ isAssign: jm
9420
9480
  }),
9421
9481
  slashAssign: J("_=", {
9422
9482
  beforeExpr: G,
9423
- isAssign: Cm
9483
+ isAssign: jm
9424
9484
  }),
9425
9485
  xorAssign: J("_=", {
9426
9486
  beforeExpr: G,
9427
- isAssign: Cm
9487
+ isAssign: jm
9428
9488
  }),
9429
9489
  moduloAssign: J("_=", {
9430
9490
  beforeExpr: G,
9431
- isAssign: Cm
9491
+ isAssign: jm
9432
9492
  }),
9433
9493
  incDec: J("++/--", {
9434
- prefix: wm,
9435
- postfix: Tm,
9494
+ prefix: Mm,
9495
+ postfix: Nm,
9436
9496
  startsExpr: K
9437
9497
  }),
9438
9498
  bang: J("!", {
9439
9499
  beforeExpr: G,
9440
- prefix: wm,
9500
+ prefix: Mm,
9441
9501
  startsExpr: K
9442
9502
  }),
9443
9503
  tilde: J("~", {
9444
9504
  beforeExpr: G,
9445
- prefix: wm,
9505
+ prefix: Mm,
9446
9506
  startsExpr: K
9447
9507
  }),
9448
9508
  doubleCaret: J("^^", { startsExpr: K }),
9449
9509
  doubleAt: J("@@", { startsExpr: K }),
9450
- pipeline: Om("|>", 0),
9451
- nullishCoalescing: Om("??", 1),
9452
- logicalOR: Om("||", 1),
9453
- logicalAND: Om("&&", 2),
9454
- bitwiseOR: Om("|", 3),
9455
- bitwiseXOR: Om("^", 4),
9456
- bitwiseAND: Om("&", 5),
9457
- equality: Om("==/!=/===/!==", 6),
9458
- lt: Om("</>/<=/>=", 7),
9459
- gt: Om("</>/<=/>=", 7),
9460
- relational: Om("</>/<=/>=", 7),
9461
- bitShift: Om("<</>>/>>>", 8),
9462
- bitShiftL: Om("<</>>/>>>", 8),
9463
- bitShiftR: Om("<</>>/>>>", 8),
9510
+ pipeline: Im("|>", 0),
9511
+ nullishCoalescing: Im("??", 1),
9512
+ logicalOR: Im("||", 1),
9513
+ logicalAND: Im("&&", 2),
9514
+ bitwiseOR: Im("|", 3),
9515
+ bitwiseXOR: Im("^", 4),
9516
+ bitwiseAND: Im("&", 5),
9517
+ equality: Im("==/!=/===/!==", 6),
9518
+ lt: Im("</>/<=/>=", 7),
9519
+ gt: Im("</>/<=/>=", 7),
9520
+ relational: Im("</>/<=/>=", 7),
9521
+ bitShift: Im("<</>>/>>>", 8),
9522
+ bitShiftL: Im("<</>>/>>>", 8),
9523
+ bitShiftR: Im("<</>>/>>>", 8),
9464
9524
  plusMin: J("+/-", {
9465
9525
  beforeExpr: G,
9466
9526
  binop: 9,
9467
- prefix: wm,
9527
+ prefix: Mm,
9468
9528
  startsExpr: K
9469
9529
  }),
9470
9530
  modulo: J("%", {
@@ -9472,7 +9532,7 @@ var Im = {
9472
9532
  startsExpr: K
9473
9533
  }),
9474
9534
  star: J("*", { binop: 10 }),
9475
- slash: Om("/", 10),
9535
+ slash: Im("/", 10),
9476
9536
  exponent: J("**", {
9477
9537
  beforeExpr: G,
9478
9538
  binop: 11,
@@ -9500,7 +9560,7 @@ var Im = {
9500
9560
  _switch: q("switch"),
9501
9561
  _throw: q("throw", {
9502
9562
  beforeExpr: G,
9503
- prefix: wm,
9563
+ prefix: Mm,
9504
9564
  startsExpr: K
9505
9565
  }),
9506
9566
  _try: q("try"),
@@ -9522,25 +9582,25 @@ var Im = {
9522
9582
  _false: q("false", { startsExpr: K }),
9523
9583
  _typeof: q("typeof", {
9524
9584
  beforeExpr: G,
9525
- prefix: wm,
9585
+ prefix: Mm,
9526
9586
  startsExpr: K
9527
9587
  }),
9528
9588
  _void: q("void", {
9529
9589
  beforeExpr: G,
9530
- prefix: wm,
9590
+ prefix: Mm,
9531
9591
  startsExpr: K
9532
9592
  }),
9533
9593
  _delete: q("delete", {
9534
9594
  beforeExpr: G,
9535
- prefix: wm,
9595
+ prefix: Mm,
9536
9596
  startsExpr: K
9537
9597
  }),
9538
9598
  _do: q("do", {
9539
- isLoop: Sm,
9599
+ isLoop: Am,
9540
9600
  beforeExpr: G
9541
9601
  }),
9542
- _for: q("for", { isLoop: Sm }),
9543
- _while: q("while", { isLoop: Sm }),
9602
+ _for: q("for", { isLoop: Am }),
9603
+ _while: q("while", { isLoop: Am }),
9544
9604
  _as: Y("as", { startsExpr: K }),
9545
9605
  _assert: Y("assert", { startsExpr: K }),
9546
9606
  _async: Y("async", { startsExpr: K }),
@@ -9596,75 +9656,75 @@ var Im = {
9596
9656
  function X(e) {
9597
9657
  return e >= 89 && e <= 129;
9598
9658
  }
9599
- function Lm(e) {
9659
+ function Gm(e) {
9600
9660
  return e <= 88;
9601
9661
  }
9602
- function Rm(e) {
9662
+ function Km(e) {
9603
9663
  return e >= 54 && e <= 129;
9604
9664
  }
9605
- function zm(e) {
9665
+ function qm(e) {
9606
9666
  return e >= 54 && e <= 132;
9607
9667
  }
9608
- function Bm(e) {
9609
- return Nm[e];
9668
+ function Jm(e) {
9669
+ return Vm[e];
9610
9670
  }
9611
- function Vm(e) {
9612
- return Pm[e];
9671
+ function Ym(e) {
9672
+ return Hm[e];
9613
9673
  }
9614
- function Hm(e) {
9674
+ function Xm(e) {
9615
9675
  return e >= 25 && e <= 29;
9616
9676
  }
9617
- function Um(e) {
9677
+ function Zm(e) {
9618
9678
  return e >= 125 && e <= 127;
9619
9679
  }
9620
- function Wm(e) {
9680
+ function Qm(e) {
9621
9681
  return e >= 86 && e <= 88;
9622
9682
  }
9623
- function Gm(e) {
9683
+ function $m(e) {
9624
9684
  return e >= 54 && e <= 88;
9625
9685
  }
9626
- function Km(e) {
9686
+ function eh(e) {
9627
9687
  return e >= 35 && e <= 55;
9628
9688
  }
9629
- function qm(e) {
9689
+ function th(e) {
9630
9690
  return e === 30;
9631
9691
  }
9632
- function Jm(e) {
9633
- return Fm[e];
9692
+ function nh(e) {
9693
+ return Um[e];
9634
9694
  }
9635
- function Ym(e) {
9695
+ function rh(e) {
9636
9696
  return e >= 117 && e <= 119;
9637
9697
  }
9638
- function Xm(e) {
9698
+ function ih(e) {
9639
9699
  return e >= 120 && e <= 126;
9640
9700
  }
9641
- function Zm(e) {
9642
- return jm[e];
9701
+ function ah(e) {
9702
+ return zm[e];
9643
9703
  }
9644
- function Qm(e) {
9645
- return Mm[e];
9704
+ function oh(e) {
9705
+ return Bm[e];
9646
9706
  }
9647
- function $m(e) {
9707
+ function sh(e) {
9648
9708
  return e === 53;
9649
9709
  }
9650
- function eh(e) {
9710
+ function ch(e) {
9651
9711
  return e >= 20 && e <= 21;
9652
9712
  }
9653
- function th(e) {
9654
- return Am[e];
9713
+ function lh(e) {
9714
+ return Rm[e];
9655
9715
  }
9656
- var nh = class {
9716
+ var uh = class {
9657
9717
  constructor(e, t) {
9658
9718
  this.token = e, this.preserveSpace = !!t;
9659
9719
  }
9660
9720
  token;
9661
9721
  preserveSpace;
9662
9722
  }, Z = {
9663
- brace: new nh("{"),
9664
- j_oTag: new nh("<tag"),
9665
- j_cTag: new nh("</tag"),
9666
- j_expr: new nh("<tag>...</tag>", !0)
9667
- }, rh = /[\p{ID_Start}\u088f\u0c5c\u0cdc\ua7ce\ua7cf\ua7d2\ua7d4\ua7f1]/u, ih = /[\p{ID_Continue}\u088f\u0c5c\u0cdc\ua7ce\ua7cf\ua7d2\ua7d4\ua7f1\u1acf-\u1add\u1ae0-\u1aeb]/u, ah = [
9723
+ brace: new uh("{"),
9724
+ j_oTag: new uh("<tag"),
9725
+ j_cTag: new uh("</tag"),
9726
+ j_expr: new uh("<tag>...</tag>", !0)
9727
+ }, dh = /[\p{ID_Start}\u088f\u0c5c\u0cdc\ua7ce\ua7cf\ua7d2\ua7d4\ua7f1]/u, fh = /[\p{ID_Continue}\u088f\u0c5c\u0cdc\ua7ce\ua7cf\ua7d2\ua7d4\ua7f1\u1acf-\u1add\u1ae0-\u1aeb]/u, ph = [
9668
9728
  2368,
9669
9729
  25,
9670
9730
  1388,
@@ -9701,7 +9761,7 @@ var nh = class {
9701
9761
  11,
9702
9762
  21763,
9703
9763
  4297
9704
- ], oh = [
9764
+ ], mh = [
9705
9765
  3834,
9706
9766
  1,
9707
9767
  3173,
@@ -9717,7 +9777,7 @@ var nh = class {
9717
9777
  6,
9718
9778
  0
9719
9779
  ];
9720
- function sh(e, t) {
9780
+ function hh(e, t) {
9721
9781
  let n = 65536;
9722
9782
  for (let r = 0, i = t.length; r < i; r += 2) {
9723
9783
  if (n += t[r], n > e) return !1;
@@ -9725,13 +9785,13 @@ function sh(e, t) {
9725
9785
  }
9726
9786
  return !1;
9727
9787
  }
9728
- function ch(e) {
9729
- return e < 65 ? e === 36 : e <= 90 ? !0 : e < 97 ? e === 95 : e <= 122 ? !0 : e <= 65535 ? e >= 170 && rh.test(String.fromCharCode(e)) : !isNaN(e) && e <= 1114111 && (rh.test(String.fromCodePoint(e)) || sh(e, ah));
9788
+ function gh(e) {
9789
+ return e < 65 ? e === 36 : e <= 90 ? !0 : e < 97 ? e === 95 : e <= 122 ? !0 : e <= 65535 ? e >= 170 && dh.test(String.fromCharCode(e)) : !isNaN(e) && e <= 1114111 && (dh.test(String.fromCodePoint(e)) || hh(e, ph));
9730
9790
  }
9731
- function lh(e) {
9732
- return e < 48 ? e === 36 : e < 58 ? !0 : e < 65 ? !1 : e <= 90 ? !0 : e < 97 ? e === 95 : e <= 122 ? !0 : e <= 65535 ? e >= 170 && ih.test(String.fromCharCode(e)) : !isNaN(e) && e <= 1114111 && (ih.test(String.fromCodePoint(e)) || sh(e, ah) || sh(e, oh));
9791
+ function _h(e) {
9792
+ return e < 48 ? e === 36 : e < 58 ? !0 : e < 65 ? !1 : e <= 90 ? !0 : e < 97 ? e === 95 : e <= 122 ? !0 : e <= 65535 ? e >= 170 && fh.test(String.fromCharCode(e)) : !isNaN(e) && e <= 1114111 && (fh.test(String.fromCodePoint(e)) || hh(e, ph) || hh(e, mh));
9733
9793
  }
9734
- var uh = {
9794
+ var vh = {
9735
9795
  keyword: /* @__PURE__ */ "break.case.catch.continue.debugger.default.do.else.finally.for.function.if.return.switch.throw.try.var.const.while.with.new.this.super.class.extends.export.import.null.true.false.in.instanceof.typeof.void.delete".split("."),
9736
9796
  strict: [
9737
9797
  "implements",
@@ -9745,37 +9805,37 @@ var uh = {
9745
9805
  "yield"
9746
9806
  ],
9747
9807
  strictBind: ["eval", "arguments"]
9748
- }, dh = new Set(uh.keyword), fh = new Set(uh.strict), ph = new Set(uh.strictBind);
9749
- function mh(e, t) {
9808
+ }, yh = new Set(vh.keyword), bh = new Set(vh.strict), xh = new Set(vh.strictBind);
9809
+ function Sh(e, t) {
9750
9810
  return t && e === "await" || e === "enum";
9751
9811
  }
9752
- function hh(e, t) {
9753
- return mh(e, t) || fh.has(e);
9812
+ function Ch(e, t) {
9813
+ return Sh(e, t) || bh.has(e);
9754
9814
  }
9755
- function gh(e) {
9756
- return ph.has(e);
9815
+ function wh(e) {
9816
+ return xh.has(e);
9757
9817
  }
9758
- function _h(e, t) {
9759
- return hh(e, t) || gh(e);
9818
+ function Th(e, t) {
9819
+ return Ch(e, t) || wh(e);
9760
9820
  }
9761
- function vh(e) {
9762
- return dh.has(e);
9821
+ function Eh(e) {
9822
+ return yh.has(e);
9763
9823
  }
9764
- function yh(e, t, n) {
9765
- return e === 64 && t === 64 && ch(n);
9824
+ function Dh(e, t, n) {
9825
+ return e === 64 && t === 64 && gh(n);
9766
9826
  }
9767
- var bh = /* @__PURE__ */ new Set(/* @__PURE__ */ "break.case.catch.continue.debugger.default.do.else.finally.for.function.if.return.switch.throw.try.var.const.while.with.new.this.super.class.extends.export.import.null.true.false.in.instanceof.typeof.void.delete.implements.interface.let.package.private.protected.public.static.yield.eval.arguments.enum.await".split("."));
9768
- function xh(e) {
9769
- return bh.has(e);
9827
+ var Oh = /* @__PURE__ */ new Set(/* @__PURE__ */ "break.case.catch.continue.debugger.default.do.else.finally.for.function.if.return.switch.throw.try.var.const.while.with.new.this.super.class.extends.export.import.null.true.false.in.instanceof.typeof.void.delete.implements.interface.let.package.private.protected.public.static.yield.eval.arguments.enum.await".split("."));
9828
+ function kh(e) {
9829
+ return Oh.has(e);
9770
9830
  }
9771
- var Sh = class {
9831
+ var Ah = class {
9772
9832
  flags = 0;
9773
9833
  names = /* @__PURE__ */ new Map();
9774
9834
  firstLexicalName = "";
9775
9835
  constructor(e) {
9776
9836
  this.flags = e;
9777
9837
  }
9778
- }, Ch = class {
9838
+ }, jh = class {
9779
9839
  parser;
9780
9840
  scopeStack = [];
9781
9841
  inModule;
@@ -9822,7 +9882,7 @@ var Sh = class {
9822
9882
  return this.treatFunctionsAsVarInScope(this.currentScope());
9823
9883
  }
9824
9884
  createScope(e) {
9825
- return new Sh(e);
9885
+ return new Ah(e);
9826
9886
  }
9827
9887
  enter(e) {
9828
9888
  this.scopeStack.push(this.createScope(e));
@@ -9873,11 +9933,11 @@ var Sh = class {
9873
9933
  if (t & 3779 && !(t & 4)) return t;
9874
9934
  }
9875
9935
  }
9876
- }, wh = class extends Sh {
9936
+ }, Mh = class extends Ah {
9877
9937
  declareFunctions = /* @__PURE__ */ new Set();
9878
- }, Th = class extends Ch {
9938
+ }, Nh = class extends jh {
9879
9939
  createScope(e) {
9880
- return new wh(e);
9940
+ return new Mh(e);
9881
9941
  }
9882
9942
  declareName(e, t, n) {
9883
9943
  let r = this.currentScope();
@@ -9898,7 +9958,7 @@ var Sh = class {
9898
9958
  checkLocalExport(e) {
9899
9959
  this.scopeStack[0].declareFunctions.has(e.name) || super.checkLocalExport(e);
9900
9960
  }
9901
- }, Eh = /* @__PURE__ */ new Set([
9961
+ }, Ph = /* @__PURE__ */ new Set([
9902
9962
  "_",
9903
9963
  "any",
9904
9964
  "bool",
@@ -9915,7 +9975,7 @@ var Sh = class {
9915
9975
  "true",
9916
9976
  "typeof",
9917
9977
  "void"
9918
- ]), Q = _m`flow`({
9978
+ ]), Q = Tm`flow`({
9919
9979
  AmbiguousConditionalArrow: "Ambiguous expression: wrap the arrow functions in parentheses to disambiguate.",
9920
9980
  AmbiguousDeclareModuleKind: "Found both `declare module.exports` and `declare export` in the same module. Modules can only have 1 since they are either an ES module or they are a CommonJS module.",
9921
9981
  AssignReservedType: ({ reservedType: e }) => `Cannot overwrite reserved type ${e}.`,
@@ -9964,27 +10024,27 @@ var Sh = class {
9964
10024
  UnsupportedStatementInDeclareModule: "Only declares and type imports are allowed inside declare module.",
9965
10025
  UnterminatedFlowComment: "Unterminated flow-comment."
9966
10026
  });
9967
- function Dh(e) {
10027
+ function Fh(e) {
9968
10028
  return e.type === "DeclareExportAllDeclaration" || e.type === "DeclareExportDeclaration" && (!e.declaration || e.declaration.type !== "TypeAlias" && e.declaration.type !== "InterfaceDeclaration");
9969
10029
  }
9970
- function Oh(e) {
10030
+ function Ih(e) {
9971
10031
  return e.importKind === "type" || e.importKind === "typeof";
9972
10032
  }
9973
- var kh = {
10033
+ var Lh = {
9974
10034
  const: "declare export var",
9975
10035
  let: "declare export var",
9976
10036
  type: "export type",
9977
10037
  interface: "export interface"
9978
10038
  };
9979
- function Ah(e, t) {
10039
+ function Rh(e, t) {
9980
10040
  let n = [], r = [];
9981
10041
  for (let i = 0; i < e.length; i++) (t(e[i], i, e) ? n : r).push(e[i]);
9982
10042
  return [n, r];
9983
10043
  }
9984
- var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10044
+ var zh = /\*?\s*@((?:no)?flow)\b/, Bh = (e) => class extends e {
9985
10045
  flowPragma = void 0;
9986
10046
  getScopeHandler() {
9987
- return Th;
10047
+ return Nh;
9988
10048
  }
9989
10049
  shouldParseTypes() {
9990
10050
  return this.getPluginOption("flow", "all") || this.flowPragma === "flow";
@@ -9994,7 +10054,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
9994
10054
  }
9995
10055
  addComment(e) {
9996
10056
  if (this.flowPragma === void 0) {
9997
- let t = jh.exec(e.value);
10057
+ let t = zh.exec(e.value);
9998
10058
  if (t) {
9999
10059
  if (t[1] === "flow") this.flowPragma = "flow";
10000
10060
  else if (t[1] === "noflow") this.flowPragma = "noflow";
@@ -10053,7 +10113,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10053
10113
  this.scope.exit(), this.expect(4), e.body = this.finishNode(t, "BlockStatement");
10054
10114
  let r = null, i = !1;
10055
10115
  return n.forEach((e) => {
10056
- Dh(e) ? (r === "CommonJS" && this.raise(Q.AmbiguousDeclareModuleKind, e), r = "ES") : e.type === "DeclareModuleExports" && (i && this.raise(Q.DuplicateDeclareModuleExports, e), r === "ES" && this.raise(Q.AmbiguousDeclareModuleKind, e), r = "CommonJS", i = !0);
10116
+ Fh(e) ? (r === "CommonJS" && this.raise(Q.AmbiguousDeclareModuleKind, e), r = "ES") : e.type === "DeclareModuleExports" && (i && this.raise(Q.DuplicateDeclareModuleExports, e), r === "ES" && this.raise(Q.AmbiguousDeclareModuleKind, e), r = "CommonJS", i = !0);
10057
10117
  }), e.kind = r || "CommonJS", this.finishNode(e, "DeclareModule");
10058
10118
  }
10059
10119
  flowParseDeclareExportDeclaration(e, t) {
@@ -10062,7 +10122,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10062
10122
  let e = this.state.value;
10063
10123
  throw this.raise(Q.UnsupportedDeclareExportKind, this.state.startLoc, {
10064
10124
  unsupportedExportKind: e,
10065
- suggestion: kh[e]
10125
+ suggestion: Lh[e]
10066
10126
  });
10067
10127
  }
10068
10128
  if (this.match(70) || this.match(64) || this.match(76) || this.isContextual(127)) return e.declaration = this.flowParseDeclare(this.startNode()), e.default = !1, this.finishNode(e, "DeclareExportDeclaration");
@@ -10119,7 +10179,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10119
10179
  e === "_" && this.raise(Q.UnexpectedReservedUnderscore, this.state.startLoc);
10120
10180
  }
10121
10181
  checkReservedType(e, t, n) {
10122
- Eh.has(e) && this.raise(n ? Q.AssignReservedType : Q.UnexpectedReservedType, t, { reservedType: e });
10182
+ Ph.has(e) && this.raise(n ? Q.AssignReservedType : Q.UnexpectedReservedType, t, { reservedType: e });
10123
10183
  }
10124
10184
  flowParseRestrictedIdentifierName(e, t) {
10125
10185
  return this.checkReservedType(this.state.value, this.state.startLoc, t), this.parseIdentifierName(e);
@@ -10234,7 +10294,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10234
10294
  else if (this.match(6) || this.match(43)) a != null && this.unexpected(a), d && this.unexpected(d.start), o.callProperties.push(this.flowParseObjectTypeCallProperty(u, t));
10235
10295
  else {
10236
10296
  let e = "init";
10237
- (this.isContextual(95) || this.isContextual(100)) && zm(this.lookahead().type) && (e = this.state.value, this.next());
10297
+ (this.isContextual(95) || this.isContextual(100)) && qm(this.lookahead().type) && (e = this.state.value, this.next());
10238
10298
  let r = this.flowParseObjectTypeProperty(u, t, a, d, e, n, i ?? !c);
10239
10299
  r === null ? (l = !0, s = this.state.lastTokStartLoc) : o.properties.push(r);
10240
10300
  }
@@ -10365,8 +10425,8 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10365
10425
  case 51: return this.next(), this.finishNode(t, "ExistsTypeAnnotation");
10366
10426
  case 83: return this.flowParseTypeofType();
10367
10427
  default:
10368
- if (Gm(this.state.type)) {
10369
- let e = Zm(this.state.type);
10428
+ if ($m(this.state.type)) {
10429
+ let e = ah(this.state.type);
10370
10430
  return this.next(), super.createIdentifier(t, e);
10371
10431
  }
10372
10432
  if (X(this.state.type)) return this.isContextual(125) ? this.flowParseInterfaceType() : this.flowIdentToTypeAnnotation(e, t, this.parseIdentifier());
@@ -10451,7 +10511,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10451
10511
  }
10452
10512
  parseStatementLike(e) {
10453
10513
  if (this.state.strict && this.isContextual(125)) {
10454
- if (Rm(this.lookahead().type)) {
10514
+ if (Km(this.lookahead().type)) {
10455
10515
  let e = this.startNode();
10456
10516
  return this.next(), this.flowParseInterface(e);
10457
10517
  }
@@ -10476,11 +10536,11 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10476
10536
  }
10477
10537
  shouldParseExportDeclaration() {
10478
10538
  let { type: e } = this.state;
10479
- return e === 122 || Um(e) ? !this.state.containsEsc : super.shouldParseExportDeclaration();
10539
+ return e === 122 || Zm(e) ? !this.state.containsEsc : super.shouldParseExportDeclaration();
10480
10540
  }
10481
10541
  isExportDefaultSpecifier() {
10482
10542
  let { type: e } = this.state;
10483
- return e === 122 || Um(e) ? this.state.containsEsc : super.isExportDefaultSpecifier();
10543
+ return e === 122 || Zm(e) ? this.state.containsEsc : super.isExportDefaultSpecifier();
10484
10544
  }
10485
10545
  parseExportDefaultExpression() {
10486
10546
  if (this.isContextual(122)) {
@@ -10522,7 +10582,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10522
10582
  let e = n.pop();
10523
10583
  e.type === "ArrowFunctionExpression" && e.body.type !== "BlockStatement" ? (e.typeParameters || !e.returnType ? this.finishArrowValidation(e) : r.push(e), n.push(e.body)) : e.type === "ConditionalExpression" && (n.push(e.consequent), n.push(e.alternate));
10524
10584
  }
10525
- return t ? (r.forEach((e) => this.finishArrowValidation(e)), [r, []]) : Ah(r, (e) => e.params.every((e) => this.isAssignable(e, !0)));
10585
+ return t ? (r.forEach((e) => this.finishArrowValidation(e)), [r, []]) : Rh(r, (e) => e.params.every((e) => this.isAssignable(e, !0)));
10526
10586
  }
10527
10587
  finishArrowValidation(e) {
10528
10588
  this.toAssignableList(e.params, e.extra?.trailingCommaLoc, !1), this.scope.enter(518), super.checkParams(e, !1, !0), this.scope.exit();
@@ -10596,7 +10656,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10596
10656
  }
10597
10657
  getTokenFromCode(e) {
10598
10658
  let t = this.input.charCodeAt(this.state.pos + 1);
10599
- e === 123 && t === 124 ? this.finishOp(3, 2) : this.state.inType && (e === 62 || e === 60) ? this.finishOp(e === 62 ? 44 : 43, 1) : this.state.inType && e === 63 ? t === 46 ? this.finishOp(14, 2) : this.finishOp(13, 1) : yh(e, t, this.input.charCodeAt(this.state.pos + 2)) ? (this.state.pos += 2, this.readIterator()) : super.getTokenFromCode(e);
10659
+ e === 123 && t === 124 ? this.finishOp(3, 2) : this.state.inType && (e === 62 || e === 60) ? this.finishOp(e === 62 ? 44 : 43, 1) : this.state.inType && e === 63 ? t === 46 ? this.finishOp(14, 2) : this.finishOp(13, 1) : Dh(e, t, this.input.charCodeAt(this.state.pos + 2)) ? (this.state.pos += 2, this.readIterator()) : super.getTokenFromCode(e);
10600
10660
  }
10601
10661
  isAssignable(e, t) {
10602
10662
  return e.type === "TypeCastExpression" ? this.isAssignable(e.expression, t) : super.isAssignable(e, t);
@@ -10687,7 +10747,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10687
10747
  return n.type === "AssignmentPattern" && n.typeAnnotation && n.right.start < n.typeAnnotation.start && this.raise(Q.TypeBeforeInitializer, n.typeAnnotation), n;
10688
10748
  }
10689
10749
  parseImportSpecifierLocal(e, t, n) {
10690
- t.local = Oh(e) ? this.flowParseRestrictedIdentifier(!0, !0) : this.parseIdentifier(), e.specifiers.push(this.finishImportSpecifier(t, n));
10750
+ t.local = Ih(e) ? this.flowParseRestrictedIdentifier(!0, !0) : this.parseIdentifier(), e.specifiers.push(this.finishImportSpecifier(t, n));
10691
10751
  }
10692
10752
  isPotentialImportPhase(e) {
10693
10753
  if (super.isPotentialImportPhase(e)) return !0;
@@ -10710,16 +10770,16 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
10710
10770
  let s = !1;
10711
10771
  if (this.isContextual(89) && !this.isLookaheadContextual("as")) {
10712
10772
  let t = this.parseIdentifier(!0);
10713
- o !== null && !Rm(this.state.type) ? (e.imported = t, e.importKind = o, e.local = this.cloneIdentifier(t)) : (e.imported = a, e.importKind = null, e.local = this.parseIdentifier());
10773
+ o !== null && !Km(this.state.type) ? (e.imported = t, e.importKind = o, e.local = this.cloneIdentifier(t)) : (e.imported = a, e.importKind = null, e.local = this.parseIdentifier());
10714
10774
  } else {
10715
- if (o !== null && Rm(this.state.type)) e.imported = this.parseIdentifier(!0), e.importKind = o;
10775
+ if (o !== null && Km(this.state.type)) e.imported = this.parseIdentifier(!0), e.importKind = o;
10716
10776
  else {
10717
10777
  if (t) throw this.raise(W.ImportBindingIsString, e, { importName: a.value });
10718
10778
  e.imported = a, e.importKind = null;
10719
10779
  }
10720
10780
  this.eatContextual(89) ? e.local = this.parseIdentifier() : (s = !0, e.local = this.cloneIdentifier(e.imported));
10721
10781
  }
10722
- let c = Oh(e);
10782
+ let c = Ih(e);
10723
10783
  return n && c && this.raise(Q.ImportTypeShorthandOnlyInPureImport, e), (n || c) && this.checkReservedType(e.local.name, e.local.start, !0), s && !n && !c && this.checkReservedWord(e.local.name, e.start, !0, !0), this.finishImportSpecifier(e, "ImportSpecifier");
10724
10784
  }
10725
10785
  parseBindingAtom() {
@@ -11079,7 +11139,7 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
11079
11139
  maybeUnwrapTypeCastExpression(e) {
11080
11140
  return e.type === "TypeCastExpression" ? e.expression : e;
11081
11141
  }
11082
- }, Nh = {
11142
+ }, Vh = {
11083
11143
  __proto__: null,
11084
11144
  quot: "\"",
11085
11145
  amp: "&",
@@ -11334,8 +11394,8 @@ var jh = /\*?\s*@((?:no)?flow)\b/, Mh = (e) => class extends e {
11334
11394
  clubs: "♣",
11335
11395
  hearts: "♥",
11336
11396
  diams: "♦"
11337
- }, Ph = /* @__PURE__ */ RegExp("\\r\\n|[\\r\\n\\u2028\\u2029]", "g");
11338
- function Fh(e) {
11397
+ }, Hh = /* @__PURE__ */ RegExp("\\r\\n|[\\r\\n\\u2028\\u2029]", "g");
11398
+ function Uh(e) {
11339
11399
  switch (e) {
11340
11400
  case 10:
11341
11401
  case 13:
@@ -11344,12 +11404,12 @@ function Fh(e) {
11344
11404
  default: return !1;
11345
11405
  }
11346
11406
  }
11347
- function Ih(e, t, n) {
11348
- for (let r = t; r < n; r++) if (Fh(e.charCodeAt(r))) return !0;
11407
+ function Wh(e, t, n) {
11408
+ for (let r = t; r < n; r++) if (Uh(e.charCodeAt(r))) return !0;
11349
11409
  return !1;
11350
11410
  }
11351
- var Lh = /(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g, Rh = /(?:[^\S\n\r\u2028\u2029]|\/\/.*|\/\*.*?\*\/)*/g;
11352
- function zh(e) {
11411
+ var Gh = /(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g, Kh = /(?:[^\S\n\r\u2028\u2029]|\/\/.*|\/\*.*?\*\/)*/g;
11412
+ function qh(e) {
11353
11413
  switch (e) {
11354
11414
  case 9:
11355
11415
  case 11:
@@ -11375,7 +11435,7 @@ function zh(e) {
11375
11435
  default: return !1;
11376
11436
  }
11377
11437
  }
11378
- var Bh = _m`jsx`({
11438
+ var Jh = Tm`jsx`({
11379
11439
  AttributeIsEmpty: "JSX attributes must only be assigned a non-empty expression.",
11380
11440
  MissingClosingTagElement: ({ openingTagName: e }) => `Expected corresponding JSX closing tag for <${e}>.`,
11381
11441
  MissingClosingTagFragment: "Expected corresponding JSX closing tag for <>.",
@@ -11385,20 +11445,20 @@ var Bh = _m`jsx`({
11385
11445
  UnterminatedJsxContent: "Unterminated JSX contents.",
11386
11446
  UnwrappedAdjacentJSXElements: "Adjacent JSX elements must be wrapped in an enclosing tag. Did you want a JSX fragment <>...</>?"
11387
11447
  });
11388
- function Vh(e) {
11448
+ function Yh(e) {
11389
11449
  return e ? e.type === "JSXOpeningFragment" || e.type === "JSXClosingFragment" : !1;
11390
11450
  }
11391
- function Hh(e) {
11451
+ function Xh(e) {
11392
11452
  if (e.type === "JSXIdentifier") return e.name;
11393
11453
  if (e.type === "JSXNamespacedName") return e.namespace.name + ":" + e.name.name;
11394
- if (e.type === "JSXMemberExpression") return Hh(e.object) + "." + Hh(e.property);
11454
+ if (e.type === "JSXMemberExpression") return Xh(e.object) + "." + Xh(e.property);
11395
11455
  throw Error("Node had unexpected type: " + e.type);
11396
11456
  }
11397
- var Uh = (e) => class extends e {
11457
+ var Zh = (e) => class extends e {
11398
11458
  jsxReadToken() {
11399
11459
  let e = "", t = this.state.pos;
11400
11460
  for (;;) {
11401
- if (this.state.pos >= this.length) throw this.raise(Bh.UnterminatedJsxContent, this.state.startLoc);
11461
+ if (this.state.pos >= this.length) throw this.raise(Jh.UnterminatedJsxContent, this.state.startLoc);
11402
11462
  let n = this.input.charCodeAt(this.state.pos);
11403
11463
  switch (n) {
11404
11464
  case 60:
@@ -11413,11 +11473,11 @@ var Uh = (e) => class extends e {
11413
11473
  e += this.input.slice(t, this.state.pos), e += this.jsxReadEntity(), t = this.state.pos;
11414
11474
  break;
11415
11475
  case 62:
11416
- case 125: this.raise(Bh.UnexpectedToken, this.state.curPosition(), {
11476
+ case 125: this.raise(Jh.UnexpectedToken, this.state.curPosition(), {
11417
11477
  unexpected: this.input[this.state.pos],
11418
11478
  HTMLEntity: n === 125 ? "&rbrace;" : "&gt;"
11419
11479
  });
11420
- default: Fh(n) ? (e += this.input.slice(t, this.state.pos), e += this.jsxReadNewLine(!0), t = this.state.pos) : ++this.state.pos;
11480
+ default: Uh(n) ? (e += this.input.slice(t, this.state.pos), e += this.jsxReadNewLine(!0), t = this.state.pos) : ++this.state.pos;
11421
11481
  }
11422
11482
  }
11423
11483
  }
@@ -11431,7 +11491,7 @@ var Uh = (e) => class extends e {
11431
11491
  if (this.state.pos >= this.length) throw this.raise(W.UnterminatedString, this.state.startLoc);
11432
11492
  let r = this.input.charCodeAt(this.state.pos);
11433
11493
  if (r === e) break;
11434
- r === 38 ? (t += this.input.slice(n, this.state.pos), t += this.jsxReadEntity(), n = this.state.pos) : Fh(r) ? (t += this.input.slice(n, this.state.pos), t += this.jsxReadNewLine(!1), n = this.state.pos) : ++this.state.pos;
11494
+ r === 38 ? (t += this.input.slice(n, this.state.pos), t += this.jsxReadEntity(), n = this.state.pos) : Uh(r) ? (t += this.input.slice(n, this.state.pos), t += this.jsxReadNewLine(!1), n = this.state.pos) : ++this.state.pos;
11435
11495
  }
11436
11496
  t += this.input.slice(n, this.state.pos++), this.finishToken(130, t);
11437
11497
  }
@@ -11447,7 +11507,7 @@ var Uh = (e) => class extends e {
11447
11507
  let t = 0, n = !1;
11448
11508
  for (; t++ < 10 && this.state.pos < this.length && !(n = this.codePointAtPos(this.state.pos) === 59);) ++this.state.pos;
11449
11509
  if (n) {
11450
- let t = Nh[this.input.slice(e, this.state.pos)];
11510
+ let t = Vh[this.input.slice(e, this.state.pos)];
11451
11511
  if (++this.state.pos, t) return t;
11452
11512
  }
11453
11513
  }
@@ -11457,12 +11517,12 @@ var Uh = (e) => class extends e {
11457
11517
  let e, t = this.state.pos;
11458
11518
  do
11459
11519
  e = this.input.charCodeAt(++this.state.pos);
11460
- while (lh(e) || e === 45);
11520
+ while (_h(e) || e === 45);
11461
11521
  this.finishToken(136, this.input.slice(t, this.state.pos));
11462
11522
  }
11463
11523
  jsxParseIdentifier() {
11464
11524
  let e = this.startNode();
11465
- return this.match(136) ? e.name = this.state.value : Gm(this.state.type) ? e.name = Zm(this.state.type) : this.unexpected(), this.next(), this.finishNode(e, "JSXIdentifier");
11525
+ return this.match(136) ? e.name = this.state.value : $m(this.state.type) ? e.name = ah(this.state.type) : this.unexpected(), this.next(), this.finishNode(e, "JSXIdentifier");
11466
11526
  }
11467
11527
  jsxParseNamespacedName() {
11468
11528
  let e = this.state.startLoc, t = this.jsxParseIdentifier();
@@ -11482,10 +11542,10 @@ var Uh = (e) => class extends e {
11482
11542
  jsxParseAttributeValue() {
11483
11543
  let e;
11484
11544
  switch (this.state.type) {
11485
- case 2: return e = this.startNode(), this.setContext(Z.brace), this.next(), e = this.jsxParseExpressionContainer(e, Z.j_oTag), e.expression.type === "JSXEmptyExpression" && this.raise(Bh.AttributeIsEmpty, e), e;
11545
+ case 2: return e = this.startNode(), this.setContext(Z.brace), this.next(), e = this.jsxParseExpressionContainer(e, Z.j_oTag), e.expression.type === "JSXEmptyExpression" && this.raise(Jh.AttributeIsEmpty, e), e;
11486
11546
  case 138:
11487
11547
  case 130: return this.parseExprAtom();
11488
- default: throw this.raise(Bh.UnsupportedJsxValue, this.state.startLoc);
11548
+ default: throw this.raise(Jh.UnsupportedJsxValue, this.state.startLoc);
11489
11549
  }
11490
11550
  }
11491
11551
  jsxParseEmptyExpression() {
@@ -11499,7 +11559,7 @@ var Uh = (e) => class extends e {
11499
11559
  if (this.match(4)) e.expression = this.jsxParseEmptyExpression();
11500
11560
  else {
11501
11561
  let t = this.parseExpression();
11502
- t.type === "SequenceExpression" && !t.extra?.parenthesized && this.raise(Bh.UnexpectedSequenceExpression, t.expressions[1]), e.expression = t;
11562
+ t.type === "SequenceExpression" && !t.extra?.parenthesized && this.raise(Jh.UnexpectedSequenceExpression, t.expressions[1]), e.expression = t;
11503
11563
  }
11504
11564
  return this.setContext(t), this.state.canStartJSXElement = !0, this.expect(4), this.finishNode(e, "JSXExpressionContainer");
11505
11565
  }
@@ -11553,10 +11613,10 @@ var Uh = (e) => class extends e {
11553
11613
  }
11554
11614
  default: this.unexpected();
11555
11615
  }
11556
- Vh(r) && !Vh(i) && i !== null ? this.raise(Bh.MissingClosingTagFragment, i) : (!Vh(r) && Vh(i) || !Vh(r) && !Vh(i) && Hh(i.name) !== Hh(r.name)) && this.raise(Bh.MissingClosingTagElement, i, { openingTagName: Hh(r.name) });
11616
+ Yh(r) && !Yh(i) && i !== null ? this.raise(Jh.MissingClosingTagFragment, i) : (!Yh(r) && Yh(i) || !Yh(r) && !Yh(i) && Xh(i.name) !== Xh(r.name)) && this.raise(Jh.MissingClosingTagElement, i, { openingTagName: Xh(r.name) });
11557
11617
  }
11558
- if (Vh(r) ? (t.openingFragment = r, t.closingFragment = i) : (t.openingElement = r, t.closingElement = i), t.children = n, this.match(43)) throw this.raise(Bh.UnwrappedAdjacentJSXElements, this.state.startLoc);
11559
- return Vh(r) ? this.finishNode(t, "JSXFragment") : this.finishNode(t, "JSXElement");
11618
+ if (Yh(r) ? (t.openingFragment = r, t.closingFragment = i) : (t.openingElement = r, t.closingElement = i), t.children = n, this.match(43)) throw this.raise(Jh.UnwrappedAdjacentJSXElements, this.state.startLoc);
11619
+ return Yh(r) ? this.finishNode(t, "JSXFragment") : this.finishNode(t, "JSXElement");
11560
11620
  }
11561
11621
  jsxParseElement() {
11562
11622
  let e = this.state.startLoc;
@@ -11579,7 +11639,7 @@ var Uh = (e) => class extends e {
11579
11639
  return;
11580
11640
  }
11581
11641
  if (t === Z.j_oTag || t === Z.j_cTag) {
11582
- if (ch(e)) {
11642
+ if (gh(e)) {
11583
11643
  this.jsxReadWord();
11584
11644
  return;
11585
11645
  }
@@ -11605,18 +11665,18 @@ var Uh = (e) => class extends e {
11605
11665
  else if (n === 139) {
11606
11666
  let n = t[t.length - 1];
11607
11667
  n === Z.j_oTag && e === 52 || n === Z.j_cTag ? (t.pop(), this.state.canStartJSXElement = t[t.length - 1] === Z.j_expr) : (this.setContext(Z.j_expr), this.state.canStartJSXElement = !0);
11608
- } else this.state.canStartJSXElement = Bm(n);
11668
+ } else this.state.canStartJSXElement = Jm(n);
11609
11669
  }
11610
- }, Wh = class extends Sh {
11670
+ }, Qh = class extends Ah {
11611
11671
  tsNames = /* @__PURE__ */ new Map();
11612
- }, Gh = class extends Ch {
11672
+ }, $h = class extends jh {
11613
11673
  get inTSNamespace() {
11614
11674
  let e = this.scopeStack;
11615
11675
  return e.length >= 2 && e[e.length - 1].flags === 0 && (e[e.length - 2].flags & 2048) > 0;
11616
11676
  }
11617
11677
  importsStack = [];
11618
11678
  createScope(e) {
11619
- return this.importsStack.push(/* @__PURE__ */ new Set()), new Wh(e);
11679
+ return this.importsStack.push(/* @__PURE__ */ new Set()), new Qh(e);
11620
11680
  }
11621
11681
  enter(e) {
11622
11682
  e & 3072 && this.importsStack.push(/* @__PURE__ */ new Set()), super.enter(e);
@@ -11659,7 +11719,7 @@ var Uh = (e) => class extends e {
11659
11719
  }
11660
11720
  super.checkLocalExport(e);
11661
11721
  }
11662
- }, Kh = class {
11722
+ }, eg = class {
11663
11723
  sawUnambiguousESM = !1;
11664
11724
  ambiguousScriptDifferentAst = !1;
11665
11725
  sourceToOffsetPos(e) {
@@ -11682,21 +11742,21 @@ var Uh = (e) => class extends e {
11682
11742
  return this.plugins.get(e)?.[t];
11683
11743
  }
11684
11744
  };
11685
- function qh(e, t) {
11745
+ function tg(e, t) {
11686
11746
  e.trailingComments === void 0 ? e.trailingComments = t : e.trailingComments.unshift(...t);
11687
11747
  }
11688
- function Jh(e, t) {
11748
+ function ng(e, t) {
11689
11749
  e.leadingComments === void 0 ? e.leadingComments = t : e.leadingComments.unshift(...t);
11690
11750
  }
11691
- function Yh(e, t) {
11751
+ function rg(e, t) {
11692
11752
  e.innerComments === void 0 ? e.innerComments = t : e.innerComments.unshift(...t);
11693
11753
  }
11694
- function Xh(e, t, n) {
11754
+ function ig(e, t, n) {
11695
11755
  let r = null, i = t.length;
11696
11756
  for (; r === null && i > 0;) r = t[--i];
11697
- r === null || r.start > n.start ? Yh(e, n.comments) : qh(r, n.comments);
11757
+ r === null || r.start > n.start ? rg(e, n.comments) : tg(r, n.comments);
11698
11758
  }
11699
- var Zh = class extends Kh {
11759
+ var ag = class extends eg {
11700
11760
  addComment(e) {
11701
11761
  this.filename && (e.loc.filename = this.filename);
11702
11762
  let { commentsLen: t } = this.state;
@@ -11719,21 +11779,21 @@ var Zh = class extends Kh {
11719
11779
  }
11720
11780
  finalizeComment(e) {
11721
11781
  let { comments: t } = e;
11722
- if (e.leadingNode !== null || e.trailingNode !== null) e.leadingNode !== null && qh(e.leadingNode, t), e.trailingNode !== null && Jh(e.trailingNode, t);
11782
+ if (e.leadingNode !== null || e.trailingNode !== null) e.leadingNode !== null && tg(e.leadingNode, t), e.trailingNode !== null && ng(e.trailingNode, t);
11723
11783
  else {
11724
11784
  let n = e.containingNode, r = e.start;
11725
11785
  if (this.input.charCodeAt(this.offsetToSourcePos(r) - 1) === 44) switch (n.type) {
11726
11786
  case "ObjectExpression":
11727
11787
  case "ObjectPattern":
11728
- Xh(n, n.properties, e);
11788
+ ig(n, n.properties, e);
11729
11789
  break;
11730
11790
  case "CallExpression":
11731
11791
  case "NewExpression":
11732
11792
  case "OptionalCallExpression":
11733
- Xh(n, n.arguments, e);
11793
+ ig(n, n.arguments, e);
11734
11794
  break;
11735
11795
  case "ImportExpression":
11736
- Xh(n, [n.source, n.options ?? null], e);
11796
+ ig(n, [n.source, n.options ?? null], e);
11737
11797
  break;
11738
11798
  case "FunctionDeclaration":
11739
11799
  case "FunctionExpression":
@@ -11742,25 +11802,25 @@ var Zh = class extends Kh {
11742
11802
  case "ClassMethod":
11743
11803
  case "ClassPrivateMethod":
11744
11804
  case "TSTypeParameterDeclaration":
11745
- Xh(n, n.params, e);
11805
+ ig(n, n.params, e);
11746
11806
  break;
11747
11807
  case "ArrayExpression":
11748
11808
  case "ArrayPattern":
11749
- Xh(n, n.elements, e);
11809
+ ig(n, n.elements, e);
11750
11810
  break;
11751
11811
  case "ExportNamedDeclaration":
11752
11812
  case "ImportDeclaration":
11753
- Xh(n, n.specifiers, e);
11813
+ ig(n, n.specifiers, e);
11754
11814
  break;
11755
11815
  case "TSEnumBody":
11756
- Xh(n, n.members, e);
11816
+ ig(n, n.members, e);
11757
11817
  break;
11758
11818
  case "TSInterfaceBody":
11759
- Xh(n, n.body, e);
11819
+ ig(n, n.body, e);
11760
11820
  break;
11761
- default: Yh(n, t);
11821
+ default: rg(n, t);
11762
11822
  }
11763
- else Yh(n, t);
11823
+ else rg(n, t);
11764
11824
  }
11765
11825
  }
11766
11826
  finalizeRemainingComments() {
@@ -11785,7 +11845,7 @@ var Zh = class extends Kh {
11785
11845
  else if (o < t) break;
11786
11846
  }
11787
11847
  }
11788
- }, Qh = class e {
11848
+ }, og = class e {
11789
11849
  flags = 2048;
11790
11850
  get strict() {
11791
11851
  return (this.flags & 1) > 0;
@@ -11799,7 +11859,7 @@ var Zh = class extends Kh {
11799
11859
  startLoc;
11800
11860
  endLoc;
11801
11861
  init({ strictMode: e, sourceType: t, startIndex: n, startLine: r, startColumn: i }) {
11802
- this.strict = e === !1 ? !1 : e === !0 || t === "module", this.startIndex = n, this.curLine = r, this.lineStart = -i, this.startLoc = this.endLoc = new nm(r, i, n);
11862
+ this.strict = e === !1 ? !1 : e === !0 || t === "module", this.startIndex = n, this.curLine = r, this.lineStart = -i, this.startLoc = this.endLoc = new um(r, i, n);
11803
11863
  }
11804
11864
  errors = [];
11805
11865
  noArrowAt = [];
@@ -11897,15 +11957,15 @@ var Zh = class extends Kh {
11897
11957
  strictErrors = /* @__PURE__ */ new Map();
11898
11958
  tokensLength = 0;
11899
11959
  curPosition() {
11900
- return new nm(this.curLine, this.pos - this.lineStart, this.pos + this.startIndex);
11960
+ return new um(this.curLine, this.pos - this.lineStart, this.pos + this.startIndex);
11901
11961
  }
11902
11962
  clone() {
11903
11963
  let t = new e();
11904
11964
  return t.flags = this.flags, t.startIndex = this.startIndex, t.curLine = this.curLine, t.lineStart = this.lineStart, t.startLoc = this.startLoc, t.endLoc = this.endLoc, t.errors = this.errors.slice(), t.noArrowAt = this.noArrowAt.slice(), t.noArrowParamsConversionAt = this.noArrowParamsConversionAt.slice(), t.labels = this.labels.slice(), t.commentsLen = this.commentsLen, t.commentStack = this.commentStack.slice(), t.pos = this.pos, t.type = this.type, t.value = this.value, t.start = this.start, t.end = this.end, t.lastTokEndLoc = this.lastTokEndLoc, t.lastTokStartLoc = this.lastTokStartLoc, t.context = this.context.slice(), t.firstInvalidTemplateEscapePos = this.firstInvalidTemplateEscapePos, t.strictErrors = this.strictErrors, t.tokensLength = this.tokensLength, t;
11905
11965
  }
11906
- }, $h = function(e) {
11966
+ }, sg = function(e) {
11907
11967
  return e >= 48 && e <= 57;
11908
- }, eg = {
11968
+ }, cg = {
11909
11969
  decBinOct: /* @__PURE__ */ new Set([
11910
11970
  46,
11911
11971
  66,
@@ -11922,13 +11982,13 @@ var Zh = class extends Kh {
11922
11982
  95,
11923
11983
  120
11924
11984
  ])
11925
- }, tg = {
11985
+ }, lg = {
11926
11986
  bin: (e) => e === 48 || e === 49,
11927
11987
  oct: (e) => e >= 48 && e <= 55,
11928
11988
  dec: (e) => e >= 48 && e <= 57,
11929
11989
  hex: (e) => e >= 48 && e <= 57 || e >= 65 && e <= 70 || e >= 97 && e <= 102
11930
11990
  };
11931
- function ng(e, t, n, r, i, a) {
11991
+ function ug(e, t, n, r, i, a) {
11932
11992
  let o = n, s = r, c = i, l = "", u = null, d = n, { length: f } = t;
11933
11993
  for (;;) {
11934
11994
  if (n >= f) {
@@ -11936,13 +11996,13 @@ function ng(e, t, n, r, i, a) {
11936
11996
  break;
11937
11997
  }
11938
11998
  let p = t.charCodeAt(n);
11939
- if (rg(e, p, t, n)) {
11999
+ if (dg(e, p, t, n)) {
11940
12000
  l += t.slice(d, n);
11941
12001
  break;
11942
12002
  }
11943
12003
  if (p === 92) {
11944
12004
  l += t.slice(d, n);
11945
- let o = ig(t, n, r, i, e === "template", a);
12005
+ let o = fg(t, n, r, i, e === "template", a);
11946
12006
  o.ch === null && !u ? u = {
11947
12007
  pos: n,
11948
12008
  lineStart: r,
@@ -11958,10 +12018,10 @@ function ng(e, t, n, r, i, a) {
11958
12018
  curLine: i
11959
12019
  };
11960
12020
  }
11961
- function rg(e, t, n, r) {
12021
+ function dg(e, t, n, r) {
11962
12022
  return e === "template" ? t === 96 || t === 36 && n.charCodeAt(r + 1) === 123 : t === (e === "double" ? 34 : 39);
11963
12023
  }
11964
- function ig(e, t, n, r, i, a) {
12024
+ function fg(e, t, n, r, i, a) {
11965
12025
  let o = !i;
11966
12026
  t++;
11967
12027
  let s = (e) => ({
@@ -11975,11 +12035,11 @@ function ig(e, t, n, r, i, a) {
11975
12035
  case 114: return s("\r");
11976
12036
  case 120: {
11977
12037
  let i;
11978
- return {code: i, pos: t} = ag(e, t, n, r, 2, !1, o, a), s(i === null ? null : String.fromCharCode(i));
12038
+ return {code: i, pos: t} = pg(e, t, n, r, 2, !1, o, a), s(i === null ? null : String.fromCharCode(i));
11979
12039
  }
11980
12040
  case 117: {
11981
12041
  let i;
11982
- return {code: i, pos: t} = sg(e, t, n, r, o, a), s(i === null ? null : String.fromCodePoint(i));
12042
+ return {code: i, pos: t} = hg(e, t, n, r, o, a), s(i === null ? null : String.fromCodePoint(i));
11983
12043
  }
11984
12044
  case 116: return s(" ");
11985
12045
  case 98: return s("\b");
@@ -12007,15 +12067,15 @@ function ig(e, t, n, r, i, a) {
12007
12067
  return s(String.fromCharCode(c));
12008
12068
  }
12009
12069
  }
12010
- function ag(e, t, n, r, i, a, o, s) {
12070
+ function pg(e, t, n, r, i, a, o, s) {
12011
12071
  let c = t, l;
12012
- return {n: l, pos: t} = og(e, t, n, r, 16, i, a, !1, s, !o), l === null && (o ? s.invalidEscapeSequence(c, n, r) : t = c - 1), {
12072
+ return {n: l, pos: t} = mg(e, t, n, r, 16, i, a, !1, s, !o), l === null && (o ? s.invalidEscapeSequence(c, n, r) : t = c - 1), {
12013
12073
  code: l,
12014
12074
  pos: t
12015
12075
  };
12016
12076
  }
12017
- function og(e, t, n, r, i, a, o, s, c, l) {
12018
- let u = t, d = i === 16 ? eg.hex : eg.decBinOct, f = i === 16 ? tg.hex : i === 10 ? tg.dec : i === 8 ? tg.oct : tg.bin, p = !1, m = 0;
12077
+ function mg(e, t, n, r, i, a, o, s, c, l) {
12078
+ let u = t, d = i === 16 ? cg.hex : cg.decBinOct, f = i === 16 ? lg.hex : i === 10 ? lg.dec : i === 8 ? lg.oct : lg.bin, p = !1, m = 0;
12019
12079
  for (let u = 0, ee = a ?? Infinity; u < ee; ++u) {
12020
12080
  let a = e.charCodeAt(t), u;
12021
12081
  if (a === 95 && s !== "bail") {
@@ -12036,7 +12096,7 @@ function og(e, t, n, r, i, a, o, s, c, l) {
12036
12096
  ++t;
12037
12097
  continue;
12038
12098
  }
12039
- if (u = a >= 97 ? a - 97 + 10 : a >= 65 ? a - 65 + 10 : $h(a) ? a - 48 : Infinity, u >= i) {
12099
+ if (u = a >= 97 ? a - 97 + 10 : a >= 65 ? a - 65 + 10 : sg(a) ? a - 48 : Infinity, u >= i) {
12040
12100
  if (u <= 9 && l) return {
12041
12101
  n: null,
12042
12102
  pos: t
@@ -12055,26 +12115,26 @@ function og(e, t, n, r, i, a, o, s, c, l) {
12055
12115
  pos: t
12056
12116
  };
12057
12117
  }
12058
- function sg(e, t, n, r, i, a) {
12118
+ function hg(e, t, n, r, i, a) {
12059
12119
  let o = e.charCodeAt(t), s;
12060
12120
  if (o === 123) {
12061
- if (++t, {code: s, pos: t} = ag(e, t, n, r, e.indexOf("}", t) - t, !0, i, a), ++t, s !== null && s > 1114111) {
12121
+ if (++t, {code: s, pos: t} = pg(e, t, n, r, e.indexOf("}", t) - t, !0, i, a), ++t, s !== null && s > 1114111) {
12062
12122
  if (i) a.invalidCodePoint(t, n, r);
12063
12123
  else return {
12064
12124
  code: null,
12065
12125
  pos: t
12066
12126
  };
12067
12127
  }
12068
- } else ({code: s, pos: t} = ag(e, t, n, r, 4, !1, i, a));
12128
+ } else ({code: s, pos: t} = pg(e, t, n, r, 4, !1, i, a));
12069
12129
  return {
12070
12130
  code: s,
12071
12131
  pos: t
12072
12132
  };
12073
12133
  }
12074
- function cg(e, t, n) {
12075
- return new nm(n, e - t, e);
12134
+ function gg(e, t, n) {
12135
+ return new um(n, e - t, e);
12076
12136
  }
12077
- var lg = /* @__PURE__ */ new Set([
12137
+ var _g = /* @__PURE__ */ new Set([
12078
12138
  103,
12079
12139
  109,
12080
12140
  115,
@@ -12083,16 +12143,16 @@ var lg = /* @__PURE__ */ new Set([
12083
12143
  117,
12084
12144
  100,
12085
12145
  118
12086
- ]), ug = class {
12146
+ ]), vg = class {
12087
12147
  constructor(e) {
12088
12148
  let t = e.startIndex || 0;
12089
- this.type = e.type, this.value = e.value, this.start = t + e.start, this.end = t + e.end, this.loc = new rm(e.startLoc, e.endLoc);
12149
+ this.type = e.type, this.value = e.value, this.start = t + e.start, this.end = t + e.end, this.loc = new dm(e.startLoc, e.endLoc);
12090
12150
  }
12091
- }, dg, fg = class extends Zh {
12151
+ }, yg, bg = class extends ag {
12092
12152
  isLookahead;
12093
12153
  tokens = [];
12094
12154
  constructor(e, t) {
12095
- super(), this.state = new Qh(), this.state.init(e), this.input = t, this.length = t.length, this.comments = [], this.isLookahead = !1, (!dg || dg.length < (this.length + 1) * 2) && (dg = new Uint32Array((this.length + 1) * 2)), this.locData = dg;
12155
+ super(), this.state = new og(), this.state.init(e), this.input = t, this.length = t.length, this.comments = [], this.isLookahead = !1, (!yg || yg.length < (this.length + 1) * 2) && (yg = new Uint32Array((this.length + 1) * 2)), this.locData = yg;
12096
12156
  }
12097
12157
  setLoc(e) {
12098
12158
  let t = this.offsetToSourcePos(e.index);
@@ -12100,13 +12160,13 @@ var lg = /* @__PURE__ */ new Set([
12100
12160
  }
12101
12161
  getLoc(e) {
12102
12162
  let t = this.offsetToSourcePos(e);
12103
- return new nm(this.locData[t * 2], this.locData[t * 2 + 1], e);
12163
+ return new um(this.locData[t * 2], this.locData[t * 2 + 1], e);
12104
12164
  }
12105
12165
  pushToken(e) {
12106
12166
  this.tokens.length = this.state.tokensLength, this.tokens.push(e), ++this.state.tokensLength;
12107
12167
  }
12108
12168
  next() {
12109
- this.checkKeywordEscapes(), this.optionFlags & 512 && this.pushToken(new ug(this.state)), this.state.lastTokEndLoc = this.state.endLoc, this.state.lastTokStartLoc = this.state.startLoc, this.nextToken();
12169
+ this.checkKeywordEscapes(), this.optionFlags & 512 && this.pushToken(new vg(this.state)), this.state.lastTokEndLoc = this.state.endLoc, this.state.lastTokStartLoc = this.state.startLoc, this.nextToken();
12110
12170
  }
12111
12171
  eat(e) {
12112
12172
  return this.match(e) ? (this.next(), !0) : !1;
@@ -12140,7 +12200,7 @@ var lg = /* @__PURE__ */ new Set([
12140
12200
  return this.nextTokenStartSince(this.state.pos);
12141
12201
  }
12142
12202
  nextTokenStartSince(e) {
12143
- return Lh.lastIndex = e, Lh.test(this.input) ? Lh.lastIndex : e;
12203
+ return Gh.lastIndex = e, Gh.test(this.input) ? Gh.lastIndex : e;
12144
12204
  }
12145
12205
  lookaheadCharCode() {
12146
12206
  return this.lookaheadCharCodeSince(this.state.pos);
@@ -12152,7 +12212,7 @@ var lg = /* @__PURE__ */ new Set([
12152
12212
  return this.nextTokenInLineStartSince(this.state.pos);
12153
12213
  }
12154
12214
  nextTokenInLineStartSince(e) {
12155
- return Rh.lastIndex = e, Rh.test(this.input) ? Rh.lastIndex : e;
12215
+ return Kh.lastIndex = e, Kh.test(this.input) ? Kh.lastIndex : e;
12156
12216
  }
12157
12217
  lookaheadInLineCharCode() {
12158
12218
  return this.input.charCodeAt(this.nextTokenInLineStart());
@@ -12183,14 +12243,14 @@ var lg = /* @__PURE__ */ new Set([
12183
12243
  this.isLookahead || (t = this.state.curPosition());
12184
12244
  let n = this.state.pos, r = this.input.indexOf(e, n + 2);
12185
12245
  if (r === -1) throw this.raise(W.UnterminatedComment, this.state.curPosition());
12186
- for (this.state.pos = r + e.length, Ph.lastIndex = n + 2; Ph.test(this.input) && Ph.lastIndex <= r;) ++this.state.curLine, this.state.lineStart = Ph.lastIndex;
12246
+ for (this.state.pos = r + e.length, Hh.lastIndex = n + 2; Hh.test(this.input) && Hh.lastIndex <= r;) ++this.state.curLine, this.state.lineStart = Hh.lastIndex;
12187
12247
  if (this.isLookahead) return;
12188
12248
  let i = {
12189
12249
  type: "CommentBlock",
12190
12250
  value: this.input.slice(n + 2, r),
12191
12251
  start: this.sourceToOffsetPos(n),
12192
12252
  end: this.sourceToOffsetPos(r + e.length),
12193
- loc: new rm(t, this.state.curPosition())
12253
+ loc: new dm(t, this.state.curPosition())
12194
12254
  };
12195
12255
  return this.optionFlags & 512 && this.pushToken(i), i;
12196
12256
  }
@@ -12198,14 +12258,14 @@ var lg = /* @__PURE__ */ new Set([
12198
12258
  let t = this.state.pos, n;
12199
12259
  this.isLookahead || (n = this.state.curPosition());
12200
12260
  let r = this.input.charCodeAt(this.state.pos += e);
12201
- if (this.state.pos < this.length) for (; !Fh(r) && ++this.state.pos < this.length;) r = this.input.charCodeAt(this.state.pos);
12261
+ if (this.state.pos < this.length) for (; !Uh(r) && ++this.state.pos < this.length;) r = this.input.charCodeAt(this.state.pos);
12202
12262
  if (this.isLookahead) return;
12203
12263
  let i = this.state.pos, a = {
12204
12264
  type: "CommentLine",
12205
12265
  value: this.input.slice(t + e, i),
12206
12266
  start: this.sourceToOffsetPos(t),
12207
12267
  end: this.sourceToOffsetPos(i),
12208
- loc: new rm(n, this.state.curPosition())
12268
+ loc: new dm(n, this.state.curPosition())
12209
12269
  };
12210
12270
  return this.optionFlags & 512 && this.pushToken(a), a;
12211
12271
  }
@@ -12240,7 +12300,7 @@ var lg = /* @__PURE__ */ new Set([
12240
12300
  default: break loop;
12241
12301
  }
12242
12302
  break;
12243
- default: if (zh(n)) ++this.state.pos;
12303
+ default: if (qh(n)) ++this.state.pos;
12244
12304
  else if (n === 45 && !this.inModule && this.optionFlags & 16384) {
12245
12305
  let n = this.state.pos;
12246
12306
  if (this.input.charCodeAt(n + 1) === 45 && this.input.charCodeAt(n + 2) === 62 && (e === 0 || this.state.lineStart > e)) {
@@ -12280,7 +12340,7 @@ var lg = /* @__PURE__ */ new Set([
12280
12340
  if (this.state.pos === 0 && this.readToken_interpreter()) return;
12281
12341
  let e = this.state.pos + 1, t = this.codePointAtPos(e);
12282
12342
  if (t >= 48 && t <= 57) throw this.raise(W.UnexpectedDigitAfterHash, this.state.curPosition());
12283
- ch(t) ? (++this.state.pos, this.finishToken(134, this.readWord1(t))) : t === 92 ? (++this.state.pos, this.finishToken(134, this.readWord1())) : this.finishOp(23, 1);
12343
+ gh(t) ? (++this.state.pos, this.finishToken(134, this.readWord1(t))) : t === 92 ? (++this.state.pos, this.finishToken(134, this.readWord1())) : this.finishOp(23, 1);
12284
12344
  }
12285
12345
  readToken_dot() {
12286
12346
  let e = this.input.charCodeAt(this.state.pos + 1);
@@ -12298,7 +12358,7 @@ var lg = /* @__PURE__ */ new Set([
12298
12358
  let e = this.input.charCodeAt(this.state.pos + 1);
12299
12359
  if (e !== 33) return !1;
12300
12360
  let t = this.state.pos;
12301
- for (this.state.pos += 1; !Fh(e) && ++this.state.pos < this.length;) e = this.input.charCodeAt(this.state.pos);
12361
+ for (this.state.pos += 1; !Uh(e) && ++this.state.pos < this.length;) e = this.input.charCodeAt(this.state.pos);
12302
12362
  let n = this.input.slice(t + 2, this.state.pos);
12303
12363
  return this.finishToken(24, n), !0;
12304
12364
  }
@@ -12500,7 +12560,7 @@ var lg = /* @__PURE__ */ new Set([
12500
12560
  case 92:
12501
12561
  this.readWord();
12502
12562
  return;
12503
- default: if (ch(e)) {
12563
+ default: if (gh(e)) {
12504
12564
  this.readWord(e);
12505
12565
  return;
12506
12566
  }
@@ -12514,9 +12574,9 @@ var lg = /* @__PURE__ */ new Set([
12514
12574
  readRegexp() {
12515
12575
  let e = this.state.startLoc, t = this.state.start + 1, n, r, { pos: i } = this.state;
12516
12576
  for (;; ++i) {
12517
- if (i >= this.length) throw this.raise(W.UnterminatedRegExp, im(e, 1));
12577
+ if (i >= this.length) throw this.raise(W.UnterminatedRegExp, fm(e, 1));
12518
12578
  let t = this.input.charCodeAt(i);
12519
- if (Fh(t)) throw this.raise(W.UnterminatedRegExp, im(e, 1));
12579
+ if (Uh(t)) throw this.raise(W.UnterminatedRegExp, fm(e, 1));
12520
12580
  if (n) n = !1;
12521
12581
  else {
12522
12582
  if (t === 91) r = !0;
@@ -12527,11 +12587,11 @@ var lg = /* @__PURE__ */ new Set([
12527
12587
  }
12528
12588
  let a = this.input.slice(t, i);
12529
12589
  ++i;
12530
- let o = "", s = () => im(e, i + 2 - t);
12590
+ let o = "", s = () => fm(e, i + 2 - t);
12531
12591
  for (; i < this.length;) {
12532
12592
  let e = this.codePointAtPos(i), t = String.fromCharCode(e);
12533
- if (lg.has(e)) e === 118 ? o.includes("u") && this.raise(W.IncompatibleRegExpUVFlags, s()) : e === 117 && o.includes("v") && this.raise(W.IncompatibleRegExpUVFlags, s()), o.includes(t) && this.raise(W.DuplicateRegExpFlags, s());
12534
- else if (lh(e) || e === 92) this.raise(W.MalformedRegExpFlags, s());
12593
+ if (_g.has(e)) e === 118 ? o.includes("u") && this.raise(W.IncompatibleRegExpUVFlags, s()) : e === 117 && o.includes("v") && this.raise(W.IncompatibleRegExpUVFlags, s()), o.includes(t) && this.raise(W.DuplicateRegExpFlags, s());
12594
+ else if (_h(e) || e === 92) this.raise(W.MalformedRegExpFlags, s());
12535
12595
  else break;
12536
12596
  ++i, o += t;
12537
12597
  }
@@ -12541,14 +12601,14 @@ var lg = /* @__PURE__ */ new Set([
12541
12601
  });
12542
12602
  }
12543
12603
  readInt(e, t, n = !1, r = !0) {
12544
- let { n: i, pos: a } = og(this.input, this.state.pos, this.state.lineStart, this.state.curLine, e, t, n, r, this.errorHandlers_readInt, !1);
12604
+ let { n: i, pos: a } = mg(this.input, this.state.pos, this.state.lineStart, this.state.curLine, e, t, n, r, this.errorHandlers_readInt, !1);
12545
12605
  return this.state.pos = a, i;
12546
12606
  }
12547
12607
  readRadixNumber(e) {
12548
12608
  let t = this.state.pos, n = this.state.curPosition(), r = !1;
12549
12609
  this.state.pos += 2;
12550
12610
  let i = this.readInt(e);
12551
- if (i ?? this.raise(W.InvalidDigit, im(n, 2), { radix: e }), this.input.charCodeAt(this.state.pos) === 110 && (++this.state.pos, r = !0), ch(this.codePointAtPos(this.state.pos))) throw this.raise(W.NumberIdentifier, this.state.curPosition());
12611
+ if (i ?? this.raise(W.InvalidDigit, fm(n, 2), { radix: e }), this.input.charCodeAt(this.state.pos) === 110 && (++this.state.pos, r = !0), gh(this.codePointAtPos(this.state.pos))) throw this.raise(W.NumberIdentifier, this.state.curPosition());
12552
12612
  if (r) {
12553
12613
  let e = this.input.slice(t, this.state.pos).replace(/[_n]/g, "");
12554
12614
  this.finishToken(132, e);
@@ -12564,14 +12624,14 @@ var lg = /* @__PURE__ */ new Set([
12564
12624
  let e = this.input.slice(t, this.state.pos);
12565
12625
  if (this.recordStrictModeErrors(W.StrictOctalLiteral, n), !this.state.strict) {
12566
12626
  let t = e.indexOf("_");
12567
- t > 0 && this.raise(W.ZeroDigitNumericSeparator, im(n, t));
12627
+ t > 0 && this.raise(W.ZeroDigitNumericSeparator, fm(n, t));
12568
12628
  }
12569
12629
  a = o && !/[89]/.test(e);
12570
12630
  }
12571
12631
  let s = this.input.charCodeAt(this.state.pos);
12572
12632
  s === 46 && !a && (++this.state.pos, this.readInt(10), r = !0, s = this.input.charCodeAt(this.state.pos)), (s === 69 || s === 101) && !a && (s = this.input.charCodeAt(++this.state.pos), (s === 43 || s === 45) && ++this.state.pos, this.readInt(10) === null && this.raise(W.InvalidOrMissingExponent, n), r = !0, s = this.input.charCodeAt(this.state.pos));
12573
12633
  let c = this.input.slice(t, this.state.pos).replaceAll("_", "");
12574
- if (s === 110 && ((r || o) && this.raise(W.InvalidBigIntLiteral, n), ++this.state.pos, i = !0), ch(this.codePointAtPos(this.state.pos))) throw this.raise(W.NumberIdentifier, this.state.curPosition());
12634
+ if (s === 110 && ((r || o) && this.raise(W.InvalidBigIntLiteral, n), ++this.state.pos, i = !0), gh(this.codePointAtPos(this.state.pos))) throw this.raise(W.NumberIdentifier, this.state.curPosition());
12575
12635
  if (i) {
12576
12636
  this.finishToken(132, c);
12577
12637
  return;
@@ -12580,19 +12640,19 @@ var lg = /* @__PURE__ */ new Set([
12580
12640
  this.finishToken(131, l);
12581
12641
  }
12582
12642
  readCodePoint(e) {
12583
- let { code: t, pos: n } = sg(this.input, this.state.pos, this.state.lineStart, this.state.curLine, e, this.errorHandlers_readCodePoint);
12643
+ let { code: t, pos: n } = hg(this.input, this.state.pos, this.state.lineStart, this.state.curLine, e, this.errorHandlers_readCodePoint);
12584
12644
  return this.state.pos = n, t;
12585
12645
  }
12586
12646
  readString(e) {
12587
- let { str: t, pos: n, curLine: r, lineStart: i } = ng(e === 34 ? "double" : "single", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_string);
12647
+ let { str: t, pos: n, curLine: r, lineStart: i } = ug(e === 34 ? "double" : "single", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_string);
12588
12648
  this.state.pos = n + 1, this.state.lineStart = i, this.state.curLine = r, this.finishToken(130, t);
12589
12649
  }
12590
12650
  readTemplateContinuation() {
12591
12651
  this.match(4) || this.unexpected(null, 4), this.state.pos--, this.readTemplateToken();
12592
12652
  }
12593
12653
  readTemplateToken() {
12594
- let e = this.input[this.state.pos], { str: t, firstInvalidLoc: n, pos: r, curLine: i, lineStart: a } = ng("template", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_template);
12595
- this.state.pos = r + 1, this.state.lineStart = a, this.state.curLine = i, n && (this.state.firstInvalidTemplateEscapePos = new nm(n.curLine, n.pos - n.lineStart, this.sourceToOffsetPos(n.pos))), this.input.codePointAt(r) === 96 ? this.finishToken(20, n ? null : e + t + "`") : (this.state.pos++, this.finishToken(21, n ? null : e + t + "${"));
12654
+ let e = this.input[this.state.pos], { str: t, firstInvalidLoc: n, pos: r, curLine: i, lineStart: a } = ug("template", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_template);
12655
+ this.state.pos = r + 1, this.state.lineStart = a, this.state.curLine = i, n && (this.state.firstInvalidTemplateEscapePos = new um(n.curLine, n.pos - n.lineStart, this.sourceToOffsetPos(n.pos))), this.input.codePointAt(r) === 96 ? this.finishToken(20, n ? null : e + t + "`") : (this.state.pos++, this.finishToken(21, n ? null : e + t + "${"));
12596
12656
  }
12597
12657
  recordStrictModeErrors(e, t) {
12598
12658
  let n = t.index;
@@ -12603,10 +12663,10 @@ var lg = /* @__PURE__ */ new Set([
12603
12663
  let t = "", n = this.state.pos, r = this.state.pos;
12604
12664
  for (e !== void 0 && (this.state.pos += e <= 65535 ? 1 : 2); this.state.pos < this.length;) {
12605
12665
  let e = this.codePointAtPos(this.state.pos);
12606
- if (lh(e)) this.state.pos += e <= 65535 ? 1 : 2;
12666
+ if (_h(e)) this.state.pos += e <= 65535 ? 1 : 2;
12607
12667
  else if (e === 92) {
12608
12668
  this.state.containsEsc = !0, t += this.input.slice(r, this.state.pos);
12609
- let e = this.state.curPosition(), i = this.state.pos === n ? ch : lh;
12669
+ let e = this.state.curPosition(), i = this.state.pos === n ? gh : _h;
12610
12670
  if (this.input.charCodeAt(++this.state.pos) !== 117) {
12611
12671
  this.raise(W.MissingUnicodeEscape, this.state.curPosition()), r = this.state.pos - 1;
12612
12672
  continue;
@@ -12619,20 +12679,20 @@ var lg = /* @__PURE__ */ new Set([
12619
12679
  return t + this.input.slice(r, this.state.pos);
12620
12680
  }
12621
12681
  readWord(e) {
12622
- let t = this.readWord1(e), n = Dm.get(t);
12623
- n === void 0 ? this.finishToken(128, t) : this.finishToken(n, Zm(n));
12682
+ let t = this.readWord1(e), n = Fm.get(t);
12683
+ n === void 0 ? this.finishToken(128, t) : this.finishToken(n, ah(n));
12624
12684
  }
12625
12685
  checkKeywordEscapes() {
12626
12686
  let { type: e } = this.state;
12627
- Gm(e) && this.state.containsEsc && this.raise(W.InvalidEscapedReservedWord, this.state.startLoc, { reservedWord: Zm(e) });
12687
+ $m(e) && this.state.containsEsc && this.raise(W.InvalidEscapedReservedWord, this.state.startLoc, { reservedWord: ah(e) });
12628
12688
  }
12629
12689
  raise(e, t, n = {}) {
12630
- let r = t instanceof nm ? t : typeof t == "number" ? this.getLoc(t) : this.optionFlags & 256 ? t.loc.start : this.getLoc(t.start), i = e(r, t instanceof nm ? r.index : typeof t == "number" ? t : t.start, n);
12690
+ let r = t instanceof um ? t : typeof t == "number" ? this.getLoc(t) : this.optionFlags & 256 ? t.loc.start : this.getLoc(t.start), i = e(r, t instanceof um ? r.index : typeof t == "number" ? t : t.start, n);
12631
12691
  if (!(this.optionFlags & 4096)) throw i;
12632
12692
  return this.isLookahead || this.state.errors.push(i), i;
12633
12693
  }
12634
12694
  raiseOverwrite(e, t, n = {}) {
12635
- let r = t instanceof nm ? t : this.optionFlags & 256 ? t.loc.start : this.getLoc(t.start), i = t instanceof nm ? r.index : t.start, a = this.state.errors;
12695
+ let r = t instanceof um ? t : this.optionFlags & 256 ? t.loc.start : this.getLoc(t.start), i = t instanceof um ? r.index : t.start, a = this.state.errors;
12636
12696
  for (let t = a.length - 1; t >= 0; t--) {
12637
12697
  let o = a[t];
12638
12698
  if (o.pos === i) return a[t] = e(r, i, n);
@@ -12642,7 +12702,7 @@ var lg = /* @__PURE__ */ new Set([
12642
12702
  }
12643
12703
  updateContext(e) {}
12644
12704
  unexpected(e, t) {
12645
- throw this.raise(W.UnexpectedToken, e ?? this.state.startLoc, { expected: t ? Zm(t) : null });
12705
+ throw this.raise(W.UnexpectedToken, e ?? this.state.startLoc, { expected: t ? ah(t) : null });
12646
12706
  }
12647
12707
  expectPlugin(e, t) {
12648
12708
  if (this.hasPlugin(e)) return !0;
@@ -12653,11 +12713,11 @@ var lg = /* @__PURE__ */ new Set([
12653
12713
  }
12654
12714
  errorBuilder(e) {
12655
12715
  return (t, n, r) => {
12656
- this.raise(e, cg(t, n, r));
12716
+ this.raise(e, gg(t, n, r));
12657
12717
  };
12658
12718
  }
12659
12719
  errorHandlers_readInt = {
12660
- invalidDigit: (e, t, n, r) => this.optionFlags & 4096 ? (this.raise(W.InvalidDigit, cg(e, t, n), { radix: r }), !0) : !1,
12720
+ invalidDigit: (e, t, n, r) => this.optionFlags & 4096 ? (this.raise(W.InvalidDigit, gg(e, t, n), { radix: r }), !0) : !1,
12661
12721
  numericSeparatorInEscapeSequence: this.errorBuilder(W.NumericSeparatorInEscapeSequence),
12662
12722
  unexpectedNumericSeparator: this.errorBuilder(W.UnexpectedNumericSeparator)
12663
12723
  };
@@ -12669,24 +12729,24 @@ var lg = /* @__PURE__ */ new Set([
12669
12729
  errorHandlers_readStringContents_string = {
12670
12730
  ...this.errorHandlers_readCodePoint,
12671
12731
  strictNumericEscape: (e, t, n) => {
12672
- this.recordStrictModeErrors(W.StrictNumericEscape, cg(e, t, n));
12732
+ this.recordStrictModeErrors(W.StrictNumericEscape, gg(e, t, n));
12673
12733
  },
12674
12734
  unterminated: (e, t, n) => {
12675
- throw this.raise(W.UnterminatedString, cg(e - 1, t, n));
12735
+ throw this.raise(W.UnterminatedString, gg(e - 1, t, n));
12676
12736
  }
12677
12737
  };
12678
12738
  errorHandlers_readStringContents_template = {
12679
12739
  ...this.errorHandlers_readCodePoint,
12680
12740
  strictNumericEscape: this.errorBuilder(W.StrictNumericEscape),
12681
12741
  unterminated: (e, t, n) => {
12682
- throw this.raise(W.UnterminatedTemplate, cg(e, t, n));
12742
+ throw this.raise(W.UnterminatedTemplate, gg(e, t, n));
12683
12743
  }
12684
12744
  };
12685
- }, pg = class {
12745
+ }, xg = class {
12686
12746
  privateNames = /* @__PURE__ */ new Set();
12687
12747
  loneAccessors = /* @__PURE__ */ new Map();
12688
12748
  undefinedPrivateNames = /* @__PURE__ */ new Map();
12689
- }, mg = class {
12749
+ }, Sg = class {
12690
12750
  parser;
12691
12751
  stack = [];
12692
12752
  constructor(e) {
@@ -12696,7 +12756,7 @@ var lg = /* @__PURE__ */ new Set([
12696
12756
  return this.stack[this.stack.length - 1];
12697
12757
  }
12698
12758
  enter() {
12699
- this.stack.push(new pg());
12759
+ this.stack.push(new xg());
12700
12760
  }
12701
12761
  exit() {
12702
12762
  let e = this.stack.pop(), t = this.current();
@@ -12718,7 +12778,7 @@ var lg = /* @__PURE__ */ new Set([
12718
12778
  for (n of this.stack) if (n.privateNames.has(e)) return;
12719
12779
  n ? n.undefinedPrivateNames.set(e, t) : this.parser.raise(W.InvalidPrivateFieldResolution, t, { identifierName: e });
12720
12780
  }
12721
- }, hg = class {
12781
+ }, Cg = class {
12722
12782
  constructor(e = 0) {
12723
12783
  this.type = e;
12724
12784
  }
@@ -12728,7 +12788,7 @@ var lg = /* @__PURE__ */ new Set([
12728
12788
  isCertainlyParameterDeclaration() {
12729
12789
  return this.type === 3;
12730
12790
  }
12731
- }, gg = class extends hg {
12791
+ }, wg = class extends Cg {
12732
12792
  declarationErrors = /* @__PURE__ */ new Map();
12733
12793
  constructor(e) {
12734
12794
  super(e);
@@ -12742,9 +12802,9 @@ var lg = /* @__PURE__ */ new Set([
12742
12802
  iterateErrors(e) {
12743
12803
  this.declarationErrors.forEach(e);
12744
12804
  }
12745
- }, _g = class {
12805
+ }, Tg = class {
12746
12806
  parser;
12747
- stack = [new hg()];
12807
+ stack = [new Cg()];
12748
12808
  constructor(e) {
12749
12809
  this.parser = e;
12750
12810
  }
@@ -12782,19 +12842,19 @@ var lg = /* @__PURE__ */ new Set([
12782
12842
  });
12783
12843
  }
12784
12844
  };
12785
- function vg() {
12786
- return new hg(3);
12845
+ function Eg() {
12846
+ return new Cg(3);
12787
12847
  }
12788
- function yg() {
12789
- return new gg(1);
12848
+ function Dg() {
12849
+ return new wg(1);
12790
12850
  }
12791
- function bg() {
12792
- return new gg(2);
12851
+ function Og() {
12852
+ return new wg(2);
12793
12853
  }
12794
- function xg() {
12795
- return new hg();
12854
+ function kg() {
12855
+ return new Cg();
12796
12856
  }
12797
- var Sg = class {
12857
+ var Ag = class {
12798
12858
  stacks = [];
12799
12859
  enter(e) {
12800
12860
  this.stacks.push(e);
@@ -12821,10 +12881,10 @@ var Sg = class {
12821
12881
  return !(this.currentFlags() & 16);
12822
12882
  }
12823
12883
  };
12824
- function Cg(e, t) {
12884
+ function jg(e, t) {
12825
12885
  return (e ? 2 : 0) | !!t;
12826
12886
  }
12827
- var wg = class extends fg {
12887
+ var Mg = class extends bg {
12828
12888
  addExtra(e, t, n, r = !0) {
12829
12889
  if (!e) return;
12830
12890
  let { extra: i } = e;
@@ -12839,7 +12899,7 @@ var wg = class extends fg {
12839
12899
  isUnparsedContextual(e, t) {
12840
12900
  if (this.input.startsWith(t, e)) {
12841
12901
  let n = this.input.charCodeAt(e + t.length);
12842
- return !(lh(n) || (n & 64512) == 55296);
12902
+ return !(_h(n) || (n & 64512) == 55296);
12843
12903
  }
12844
12904
  return !1;
12845
12905
  }
@@ -12860,10 +12920,10 @@ var wg = class extends fg {
12860
12920
  return this.match(135) || this.match(4) || this.hasPrecedingLineBreak();
12861
12921
  }
12862
12922
  hasPrecedingLineBreak() {
12863
- return Ih(this.input, this.offsetToSourcePos(this.state.lastTokEndLoc.index), this.state.start);
12923
+ return Wh(this.input, this.offsetToSourcePos(this.state.lastTokEndLoc.index), this.state.start);
12864
12924
  }
12865
12925
  hasFollowingLineBreak() {
12866
- return Ih(this.input, this.state.end, this.nextTokenStart());
12926
+ return Wh(this.input, this.state.end, this.nextTokenStart());
12867
12927
  }
12868
12928
  isLineTerminator() {
12869
12929
  return this.eat(9) || this.canInsertSemicolon();
@@ -12923,7 +12983,7 @@ var wg = class extends fg {
12923
12983
  n != null && this.raise(W.InvalidCoverInitializedName, n), r != null && this.raise(W.DuplicateProto, r), i != null && this.raise(W.UnexpectedPrivateField, i), a != null && this.unexpected(a), o != null && this.raise(W.InvalidCoverDiscardElement, o);
12924
12984
  }
12925
12985
  isLiteralPropertyName() {
12926
- return zm(this.state.type);
12986
+ return qm(this.state.type);
12927
12987
  }
12928
12988
  isPrivateName(e) {
12929
12989
  return e.type === "PrivateName";
@@ -12950,11 +13010,11 @@ var wg = class extends fg {
12950
13010
  let i = this.scope, a = this.getScopeHandler();
12951
13011
  this.scope = new a(this, e);
12952
13012
  let o = this.prodParam;
12953
- this.prodParam = new Sg();
13013
+ this.prodParam = new Ag();
12954
13014
  let s = this.classScope;
12955
- this.classScope = new mg(this);
13015
+ this.classScope = new Sg(this);
12956
13016
  let c = this.expressionScope;
12957
- return this.expressionScope = new _g(this), () => {
13017
+ return this.expressionScope = new Tg(this), () => {
12958
13018
  this.state.labels = t, this.exportedIdentifiers = n, this.inModule = r, this.scope = i, this.prodParam = o, this.classScope = s, this.expressionScope = c;
12959
13019
  };
12960
13020
  }
@@ -12970,18 +13030,18 @@ var wg = class extends fg {
12970
13030
  let { privateKeyLoc: t } = e;
12971
13031
  t !== null && this.expectPlugin("destructuringPrivate", t);
12972
13032
  }
12973
- }, Tg = class {
13033
+ }, Ng = class {
12974
13034
  shorthandAssignLoc = null;
12975
13035
  doubleProtoLoc = null;
12976
13036
  privateKeyLoc = null;
12977
13037
  optionalParametersLoc = null;
12978
13038
  voidPatternLoc = null;
12979
- }, Eg = class {
13039
+ }, Pg = class {
12980
13040
  constructor(e, t, n, r) {
12981
- this.start = n, this.end = 0, r !== void 0 && (this.loc = new rm(r)), e & 128 && (this.range = [n, 0]), r !== void 0 && t && (this.loc.filename = t);
13041
+ this.start = n, this.end = 0, r !== void 0 && (this.loc = new dm(r)), e & 128 && (this.range = [n, 0]), r !== void 0 && t && (this.loc.filename = t);
12982
13042
  }
12983
13043
  type = "";
12984
- }, Dg = Eg.prototype, Og = class extends wg {
13044
+ }, Fg = Pg.prototype, Ig = class extends Mg {
12985
13045
  createPosition(e) {
12986
13046
  return e;
12987
13047
  }
@@ -12991,11 +13051,11 @@ var wg = class extends fg {
12991
13051
  }
12992
13052
  startNodeAt(e) {
12993
13053
  let { optionFlags: t, filename: n } = this;
12994
- return t & 256 ? new Eg(t, n, e.index, this.createPosition(e)) : new Eg(t, n, e.index);
13054
+ return t & 256 ? new Pg(t, n, e.index, this.createPosition(e)) : new Pg(t, n, e.index);
12995
13055
  }
12996
13056
  startNodeAtNode(e) {
12997
13057
  let { optionFlags: t, filename: n } = this;
12998
- return t & 256 ? new Eg(t, n, e.start, e.loc.start) : new Eg(t, n, e.start);
13058
+ return t & 256 ? new Pg(t, n, e.start, e.loc.start) : new Pg(t, n, e.start);
12999
13059
  }
13000
13060
  finishNode(e, t) {
13001
13061
  return this.finishNodeAt(e, t, this.state.lastTokEndLoc);
@@ -13034,17 +13094,17 @@ var wg = class extends fg {
13034
13094
  return e.type = t, e;
13035
13095
  }
13036
13096
  cloneIdentifier(e) {
13037
- let { type: t, start: n, end: r, loc: i, range: a, name: o } = e, s = Object.create(Dg);
13097
+ let { type: t, start: n, end: r, loc: i, range: a, name: o } = e, s = Object.create(Fg);
13038
13098
  return s.type = t, s.start = n, s.end = r, s.loc = i, s.range = a, s.name = o, e.extra && (s.extra = e.extra), s;
13039
13099
  }
13040
13100
  cloneStringLiteral(e) {
13041
- let { type: t, start: n, end: r, loc: i, range: a, extra: o } = e, s = Object.create(Dg);
13101
+ let { type: t, start: n, end: r, loc: i, range: a, extra: o } = e, s = Object.create(Fg);
13042
13102
  return s.type = t, s.start = n, s.end = r, s.loc = i, s.range = a, s.extra = o, s.value = e.value, s;
13043
13103
  }
13044
- }, kg = (e) => e.type === "ParenthesizedExpression" ? kg(e.expression) : e, Ag = class extends Og {
13104
+ }, Lg = (e) => e.type === "ParenthesizedExpression" ? Lg(e.expression) : e, Rg = class extends Ig {
13045
13105
  toAssignable(e, t = !1) {
13046
13106
  let n;
13047
- switch ((e.type === "ParenthesizedExpression" || e.extra?.parenthesized) && (n = kg(e), t ? n.type === "Identifier" ? this.expressionScope.recordArrowParameterBindingError(W.InvalidParenthesizedAssignment, e) : n.type !== "CallExpression" && n.type !== "MemberExpression" && !this.isOptionalMemberExpression(n) && this.raise(W.InvalidParenthesizedAssignment, e) : this.raise(W.InvalidParenthesizedAssignment, e)), e.type) {
13107
+ switch ((e.type === "ParenthesizedExpression" || e.extra?.parenthesized) && (n = Lg(e), t ? n.type === "Identifier" ? this.expressionScope.recordArrowParameterBindingError(W.InvalidParenthesizedAssignment, e) : n.type !== "CallExpression" && n.type !== "MemberExpression" && !this.isOptionalMemberExpression(n) && this.raise(W.InvalidParenthesizedAssignment, e) : this.raise(W.InvalidParenthesizedAssignment, e)), e.type) {
13048
13108
  case "Identifier":
13049
13109
  case "ObjectPattern":
13050
13110
  case "ArrayPattern":
@@ -13211,7 +13271,7 @@ var wg = class extends fg {
13211
13271
  return;
13212
13272
  }
13213
13273
  s === "VoidPattern" && t.type === "CatchClause" && this.raise(W.VoidPatternCatchClauseParam, e);
13214
- let l = kg(e);
13274
+ let l = Lg(e);
13215
13275
  o ||= l.type === "CallExpression" && (l.callee.type === "Import" || l.callee.type === "Super");
13216
13276
  let u = this.isValidLVal(s, o, !(a || e.extra?.parenthesized) && t.type === "AssignmentExpression", n);
13217
13277
  if (u === !0) return;
@@ -13227,7 +13287,7 @@ var wg = class extends fg {
13227
13287
  else m && this.checkLVal(m, p, n, r, i, f, o);
13228
13288
  }
13229
13289
  checkIdentifier(e, t, n = !1) {
13230
- this.state.strict && (n ? _h(e.name, this.inModule) : gh(e.name)) && (t === 64 ? this.raise(W.StrictEvalArguments, e, { referenceName: e.name }) : this.raise(W.StrictEvalArgumentsBinding, e, { bindingName: e.name })), t & 8192 && e.name === "let" && this.raise(W.LetInLexicalBinding, e), t & 64 || this.declareNameFromIdentifier(e, t);
13290
+ this.state.strict && (n ? Th(e.name, this.inModule) : wh(e.name)) && (t === 64 ? this.raise(W.StrictEvalArguments, e, { referenceName: e.name }) : this.raise(W.StrictEvalArgumentsBinding, e, { bindingName: e.name })), t & 8192 && e.name === "let" && this.raise(W.LetInLexicalBinding, e), t & 64 || this.declareNameFromIdentifier(e, t);
13231
13291
  }
13232
13292
  declareNameFromIdentifier(e, t) {
13233
13293
  this.scope.declareName(e.name, t, e.start);
@@ -13247,7 +13307,7 @@ var wg = class extends fg {
13247
13307
  checkCommaAfterRest(e) {
13248
13308
  return this.match(8) ? (this.raise(this.lookaheadCharCode() === e ? W.RestTrailingComma : W.ElementAfterRest, this.state.startLoc), !0) : !1;
13249
13309
  }
13250
- }, jg = class extends Ag {
13310
+ }, zg = class extends Rg {
13251
13311
  checkProto(e, t, n) {
13252
13312
  if (e.type === "SpreadElement" || this.isObjectMethod(e) || e.computed || e.shorthand) return t;
13253
13313
  let r = e.key;
@@ -13260,7 +13320,7 @@ var wg = class extends fg {
13260
13320
  if (this.enterInitialScopes(), this.nextToken(), this.match(135)) throw this.raise(W.ParseExpressionEmptyInput, this.state.startLoc);
13261
13321
  let e = this.parseExpression();
13262
13322
  if (!this.match(135)) throw this.raise(W.ParseExpressionExpectsEOF, this.state.startLoc, { unexpected: this.input.codePointAt(this.state.start) });
13263
- return this.finalizeRemainingComments(), e.comments = this.comments, e.errors = this.state.errors, this.optionFlags & 512 && (e.tokens = Ig(this.tokens)), e;
13323
+ return this.finalizeRemainingComments(), e.comments = this.comments, e.errors = this.state.errors, this.optionFlags & 512 && (e.tokens = Wg(this.tokens)), e;
13264
13324
  }
13265
13325
  parseExpression(e, t) {
13266
13326
  return e ? this.disallowInAnd(() => this.parseExpressionBase(t)) : this.allowInAnd(() => this.parseExpressionBase(t));
@@ -13291,9 +13351,9 @@ var wg = class extends fg {
13291
13351
  return t && (e = t.call(this, e, n)), e;
13292
13352
  }
13293
13353
  let i;
13294
- e ? i = !1 : (e = new Tg(), i = !0), this.state.canStartArrow = !0;
13354
+ e ? i = !1 : (e = new Ng(), i = !0), this.state.canStartArrow = !0;
13295
13355
  let a = this.parseMaybeConditional(e);
13296
- if (t && (a = t.call(this, a, n)), Hm(this.state.type)) {
13356
+ if (t && (a = t.call(this, a, n)), Xm(this.state.type)) {
13297
13357
  let t = this.startNodeAt(n), r = this.state.value;
13298
13358
  if (t.operator = r, this.match(25)) {
13299
13359
  this.toAssignable(a, !0), t.left = a;
@@ -13304,7 +13364,7 @@ var wg = class extends fg {
13304
13364
  }
13305
13365
  if (i && this.checkExpressionErrors(e, !0), r) {
13306
13366
  let { type: e } = this.state;
13307
- if ((this.hasPlugin("v8intrinsic") ? Vm(e) : Vm(e) && !this.match(50)) && !this.isAmbiguousPrefixOrIdentifier()) return this.raiseOverwrite(W.YieldNotInGeneratorFunction, n), this.parseYield(n);
13367
+ if ((this.hasPlugin("v8intrinsic") ? Ym(e) : Ym(e) && !this.match(50)) && !this.isAmbiguousPrefixOrIdentifier()) return this.raiseOverwrite(W.YieldNotInGeneratorFunction, n), this.parseYield(n);
13308
13368
  }
13309
13369
  return a;
13310
13370
  }
@@ -13329,17 +13389,17 @@ var wg = class extends fg {
13329
13389
  parseExprOp(e, t, n) {
13330
13390
  if (this.isPrivateName(e)) {
13331
13391
  let r = this.getPrivateNameSV(e);
13332
- (n >= Qm(54) || !this.prodParam.hasIn || !this.match(54)) && this.raise(W.PrivateInExpectedIn, t, { identifierName: r }), this.classScope.usePrivateName(r, t);
13392
+ (n >= oh(54) || !this.prodParam.hasIn || !this.match(54)) && this.raise(W.PrivateInExpectedIn, t, { identifierName: r }), this.classScope.usePrivateName(r, t);
13333
13393
  }
13334
13394
  let r = this.state.type;
13335
- if (Km(r) && (this.prodParam.hasIn || !this.match(54))) {
13336
- let i = Qm(r);
13395
+ if (eh(r) && (this.prodParam.hasIn || !this.match(54))) {
13396
+ let i = oh(r);
13337
13397
  if (i > n) {
13338
13398
  if (r === 35 && (this.expectPlugin("pipelineOperator"), this.prodParam.inFSharpPipelineDirectBody)) return e;
13339
13399
  let a = this.startNodeAt(t);
13340
13400
  a.left = e, a.operator = this.state.value;
13341
13401
  let o = r === 37 || r === 38, s = r === 36;
13342
- s && (i = Qm(38)), this.next(), a.right = this.parseExprOpRightExpr(r, i);
13402
+ s && (i = oh(38)), this.next(), a.right = this.parseExprOpRightExpr(r, i);
13343
13403
  let c = this.finishNode(a, o || s ? "LogicalExpression" : "BinaryExpression"), l = this.state.type;
13344
13404
  if (s && (l === 37 || l === 38) || o && l === 36) throw this.raise(W.MixingCoalesceWithLogical, this.state.startLoc);
13345
13405
  return this.parseExprOp(c, t, n);
@@ -13358,11 +13418,11 @@ var wg = class extends fg {
13358
13418
  }
13359
13419
  parseExprOpBaseRightExpr(e, t) {
13360
13420
  let n = this.state.startLoc;
13361
- return this.parseExprOp(this.parseMaybeUnaryOrPrivate(), n, $m(e) ? t - 1 : t);
13421
+ return this.parseExprOp(this.parseMaybeUnaryOrPrivate(), n, sh(e) ? t - 1 : t);
13362
13422
  }
13363
13423
  parseHackPipeBody() {
13364
13424
  let { startLoc: e } = this.state, t = this.parseMaybeAssign();
13365
- return fm.has(t.type) && !t.extra?.parenthesized && this.raise(W.PipeUnparenthesizedBody, e, { type: t.type }), this.topicReferenceWasUsedInCurrentContext() || this.raise(W.PipeTopicUnused, e), t;
13425
+ return bm.has(t.type) && !t.extra?.parenthesized && this.raise(W.PipeUnparenthesizedBody, e, { type: t.type }), this.topicReferenceWasUsedInCurrentContext() || this.raise(W.PipeTopicUnused, e), t;
13366
13426
  }
13367
13427
  checkExponentialAfterUnary(e) {
13368
13428
  this.match(53) && this.raise(W.UnexpectedTokenUnaryExponentiation, e.argument);
@@ -13375,7 +13435,7 @@ var wg = class extends fg {
13375
13435
  return t || this.checkExponentialAfterUnary(e), e;
13376
13436
  }
13377
13437
  let i = this.match(30), a = this.startNode();
13378
- if (Jm(this.state.type)) {
13438
+ if (nh(this.state.type)) {
13379
13439
  a.operator = this.state.value, a.prefix = !0, this.state.canStartArrow = !1, this.match(68) && this.expectPlugin("throwExpressions");
13380
13440
  let n = this.match(85);
13381
13441
  if (this.next(), a.argument = this.parseMaybeUnary(null, !0), this.checkExpressionErrors(e, !0), this.state.strict && n) {
@@ -13387,7 +13447,7 @@ var wg = class extends fg {
13387
13447
  let o = this.parseUpdate(a, i, e);
13388
13448
  if (r) {
13389
13449
  let { type: e } = this.state;
13390
- if ((this.hasPlugin("v8intrinsic") ? Vm(e) : Vm(e) && !this.match(50)) && !this.isAmbiguousPrefixOrIdentifier()) return this.raiseOverwrite(W.AwaitNotInAsyncContext, n), this.parseAwait(n);
13450
+ if ((this.hasPlugin("v8intrinsic") ? Ym(e) : Ym(e) && !this.match(50)) && !this.isAmbiguousPrefixOrIdentifier()) return this.raiseOverwrite(W.AwaitNotInAsyncContext, n), this.parseAwait(n);
13391
13451
  }
13392
13452
  return o;
13393
13453
  }
@@ -13398,7 +13458,7 @@ var wg = class extends fg {
13398
13458
  }
13399
13459
  let r = this.state.startLoc, i = this.parseExprSubscripts(n);
13400
13460
  if (this.checkExpressionErrors(n, !1)) return i;
13401
- for (; qm(this.state.type) && !this.canInsertSemicolon();) {
13461
+ for (; th(this.state.type) && !this.canInsertSemicolon();) {
13402
13462
  let e = this.startNodeAt(r);
13403
13463
  e.operator = this.state.value, e.prefix = !1, e.argument = i, this.next(), this.checkLVal(i, i = this.finishNode(e, "UpdateExpression"));
13404
13464
  }
@@ -13424,7 +13484,7 @@ var wg = class extends fg {
13424
13484
  parseSubscript(e, t, n, r) {
13425
13485
  let { type: i } = this.state;
13426
13486
  if (!n && i === 11) return this.parseBind(e, t, r);
13427
- if (eh(i)) return this.parseTaggedTemplateExpression(e, t, r);
13487
+ if (ch(i)) return this.parseTaggedTemplateExpression(e, t, r);
13428
13488
  let a = !1;
13429
13489
  if (i === 14) {
13430
13490
  if (n && (this.raise(W.OptionalChainingNoNew, this.state.startLoc), this.lookaheadCharCode() === 40)) return this.stopParseSubscript(e, r);
@@ -13456,7 +13516,7 @@ var wg = class extends fg {
13456
13516
  let a = this.startNodeAt(t);
13457
13517
  a.callee = e;
13458
13518
  let { maybeAsyncArrow: o, optionalChainMember: s } = n;
13459
- o && (this.expressionScope.enter(bg()), i = new Tg()), s && (a.optional = r), a.arguments = r ? this.parseCallExpressionArguments() : this.parseCallExpressionArguments(e.type !== "Super", a, i);
13519
+ o && (this.expressionScope.enter(Og()), i = new Ng()), s && (a.optional = r), a.arguments = r ? this.parseCallExpressionArguments() : this.parseCallExpressionArguments(e.type !== "Super", a, i);
13460
13520
  let c = this.finishCallExpression(a, s);
13461
13521
  return o && this.shouldParseAsyncArrow() && !r ? (n.stop = !0, this.checkDestructuringPrivate(i), this.expressionScope.validateAsPattern(), this.expressionScope.exit(), c = this.parseAsyncArrowFromCallExpression(this.startNodeAt(t), c)) : (o && (this.checkExpressionErrors(i, !0), this.expressionScope.exit()), this.toReferencedList(a.arguments)), c;
13462
13522
  }
@@ -13490,7 +13550,7 @@ var wg = class extends fg {
13490
13550
  return this.match(15) && !this.canInsertSemicolon();
13491
13551
  }
13492
13552
  parseAsyncArrowFromCallExpression(e, t) {
13493
- return this.resetPreviousNodeTrailingComments(t), this.expect(15), this.parseArrowExpression(e, t.arguments, !0, t.extra?.trailingCommaLoc), t.innerComments && Yh(e, t.innerComments), t.callee.trailingComments && Yh(e, t.callee.trailingComments), e;
13553
+ return this.resetPreviousNodeTrailingComments(t), this.expect(15), this.parseArrowExpression(e, t.arguments, !0, t.extra?.trailingCommaLoc), t.innerComments && rg(e, t.innerComments), t.callee.trailingComments && rg(e, t.callee.trailingComments), e;
13494
13554
  }
13495
13555
  parseNoCallExpr() {
13496
13556
  let e = this.state.startLoc;
@@ -13540,7 +13600,7 @@ var wg = class extends fg {
13540
13600
  }
13541
13601
  case 43: {
13542
13602
  let e = this.input.codePointAt(this.nextTokenStart());
13543
- throw ch(e) || e === 62 ? this.expectOnePlugin([
13603
+ throw gh(e) || e === 62 ? this.expectOnePlugin([
13544
13604
  "jsx",
13545
13605
  "flow",
13546
13606
  "typescript"
@@ -13563,7 +13623,7 @@ var wg = class extends fg {
13563
13623
  }
13564
13624
  parseTopicReferenceThenEqualsSign(e, t) {
13565
13625
  let n = this.getPluginOption("pipelineOperator", "proposal");
13566
- if (n) return this.state.type = e, this.state.value = t, this.state.pos--, this.state.end--, this.state.endLoc = im(this.state.endLoc, -1), this.parseTopicReference(n);
13626
+ if (n) return this.state.type = e, this.state.value = t, this.state.pos--, this.state.end--, this.state.endLoc = fm(this.state.endLoc, -1), this.parseTopicReference(n);
13567
13627
  throw this.unexpected();
13568
13628
  }
13569
13629
  parseTopicReference(e) {
@@ -13572,16 +13632,16 @@ var wg = class extends fg {
13572
13632
  }
13573
13633
  finishTopicReference(e, t, n, r) {
13574
13634
  if (this.testTopicReferenceConfiguration(n, t, r)) return this.topicReferenceIsAllowedInCurrentContext() || this.raise(W.PipeTopicUnbound, t), this.registerTopicReference(), this.finishNode(e, "TopicReference");
13575
- throw this.raise(W.PipeTopicUnconfiguredToken, t, { token: Zm(r) });
13635
+ throw this.raise(W.PipeTopicUnconfiguredToken, t, { token: ah(r) });
13576
13636
  }
13577
13637
  testTopicReferenceConfiguration(e, t, n) {
13578
13638
  switch (e) {
13579
- case "hack": return this.hasPlugin(["pipelineOperator", { topicToken: Zm(n) }]);
13639
+ case "hack": return this.hasPlugin(["pipelineOperator", { topicToken: ah(n) }]);
13580
13640
  default: throw this.raise(W.PipeTopicRequiresHackPipes, t);
13581
13641
  }
13582
13642
  }
13583
13643
  parseAsyncArrowUnaryFunction(e) {
13584
- this.prodParam.enter(Cg(!0, this.prodParam.hasYield));
13644
+ this.prodParam.enter(jg(!0, this.prodParam.hasYield));
13585
13645
  let t = [this.parseIdentifier()];
13586
13646
  return this.prodParam.exit(), this.hasPrecedingLineBreak() && this.raise(W.LineTerminatorBeforeArrow, this.state.curPosition()), this.expect(15), this.parseArrowExpression(e, t, !0);
13587
13647
  }
@@ -13595,7 +13655,7 @@ var wg = class extends fg {
13595
13655
  return this.next(), this.match(6) && !this.scope.allowDirectSuper ? this.raise(W.SuperNotAllowed, e) : this.scope.allowSuper || this.raise(W.UnexpectedSuper, e), !this.match(6) && !this.match(0) && !this.match(12) && this.raise(W.UnsupportedSuper, e), this.finishNode(e, "Super");
13596
13656
  }
13597
13657
  parsePrivateName() {
13598
- let e = this.startNode(), t = this.startNodeAt(im(this.state.startLoc, 1)), n = this.state.value;
13658
+ let e = this.startNode(), t = this.startNodeAt(fm(this.state.startLoc, 1)), n = this.state.value;
13599
13659
  return this.next(), e.id = this.createIdentifier(t, n), this.finishNode(e, "PrivateName");
13600
13660
  }
13601
13661
  parseFunctionOrFunctionSent() {
@@ -13660,8 +13720,8 @@ var wg = class extends fg {
13660
13720
  }
13661
13721
  parseParenAndDistinguishExpression(e) {
13662
13722
  let t = this.state.startLoc, n;
13663
- this.next(), this.expressionScope.enter(yg());
13664
- let r = this.state.startLoc, i = [], a = new Tg(), o = !0, s, c;
13723
+ this.next(), this.expressionScope.enter(Dg());
13724
+ let r = this.state.startLoc, i = [], a = new Ng(), o = !0, s, c;
13665
13725
  for (; !this.match(7);) {
13666
13726
  if (o) o = !1;
13667
13727
  else if (this.expect(8, a.optionalParametersLoc === null ? null : a.optionalParametersLoc), this.match(7)) {
@@ -13714,15 +13774,15 @@ var wg = class extends fg {
13714
13774
  e.callee = n, t && n.type === "ImportExpression" && this.raise(W.ImportCallNotNewExpression, n, n), n.type === "Import" && this.raise(W.ImportCallNotNewExpression, n), n.type === "Super" && this.raise(W.SuperCallNotNewExpression, n);
13715
13775
  }
13716
13776
  parseTemplateElement(e) {
13717
- let { start: t, startLoc: n, end: r, value: i } = this.state, a = t + 1, o = this.startNodeAt(im(n, 1));
13718
- i === null && (e || this.raise(W.InvalidEscapeSequenceTemplate, im(this.state.firstInvalidTemplateEscapePos, 1)));
13777
+ let { start: t, startLoc: n, end: r, value: i } = this.state, a = t + 1, o = this.startNodeAt(fm(n, 1));
13778
+ i === null && (e || this.raise(W.InvalidEscapeSequenceTemplate, fm(this.state.firstInvalidTemplateEscapePos, 1)));
13719
13779
  let s = this.match(20), c = s ? -1 : -2, l = r + c;
13720
13780
  o.value = {
13721
13781
  raw: this.input.slice(a, l).replace(/\r\n?/g, "\n"),
13722
13782
  cooked: i === null ? null : i.slice(1, c)
13723
13783
  }, o.tail = s, this.next();
13724
13784
  let u = this.finishNode(o, "TemplateElement");
13725
- return this.resetEndLocation(u, im(this.state.lastTokEndLoc, c)), u;
13785
+ return this.resetEndLocation(u, fm(this.state.lastTokEndLoc, c)), u;
13726
13786
  }
13727
13787
  parseTemplate(e) {
13728
13788
  let t = this.startNode(), n = this.parseTemplateElement(e), r = [n], i = [];
@@ -13807,7 +13867,7 @@ var wg = class extends fg {
13807
13867
  if (this.eat(0)) e.computed = !0, e.key = this.parseMaybeAssignAllowIn(), this.expect(1);
13808
13868
  else {
13809
13869
  let { type: n, value: r } = this.state, i;
13810
- if (Rm(n)) i = this.parseIdentifier(!0);
13870
+ if (Km(n)) i = this.parseIdentifier(!0);
13811
13871
  else switch (n) {
13812
13872
  case 131:
13813
13873
  i = this.parseNumericLiteral(r);
@@ -13832,7 +13892,7 @@ var wg = class extends fg {
13832
13892
  e.id = null, e.generator = !1, e.async = t;
13833
13893
  }
13834
13894
  parseMethod(e, t, n, r, i, a, o = !1) {
13835
- this.initFunction(e, n), e.generator = t, this.scope.enter(530 | (o ? 576 : 0) | (i ? 32 : 0)), this.prodParam.enter(Cg(n, e.generator)), this.parseFunctionParams(e, r);
13895
+ this.initFunction(e, n), e.generator = t, this.scope.enter(530 | (o ? 576 : 0) | (i ? 32 : 0)), this.prodParam.enter(jg(n, e.generator)), this.parseFunctionParams(e, r);
13836
13896
  let s = this.parseFunctionBodyAndFinish(e, a, !0);
13837
13897
  return this.prodParam.exit(), this.scope.exit(), s;
13838
13898
  }
@@ -13842,7 +13902,7 @@ var wg = class extends fg {
13842
13902
  }
13843
13903
  parseArrowExpression(e, t, n, r) {
13844
13904
  this.scope.enter(518);
13845
- let i = Cg(n, !1);
13905
+ let i = jg(n, !1);
13846
13906
  return this.match(2) || (i |= this.prodParam.currentFlags() & 24), this.prodParam.enter(i), this.initFunction(e, n), t && this.setArrowFunctionParameters(e, t, r), this.parseFunctionBody(e, !0), this.prodParam.exit(), this.scope.exit(), this.finishNode(e, "ArrowFunctionExpression");
13847
13907
  }
13848
13908
  setArrowFunctionParameters(e, t, n) {
@@ -13853,7 +13913,7 @@ var wg = class extends fg {
13853
13913
  }
13854
13914
  parseFunctionBody(e, t, n = !1) {
13855
13915
  let r = t && !this.match(2);
13856
- if (this.expressionScope.enter(xg()), r) e.body = this.parseMaybeAssign(), this.checkParams(e, !1, t, !1);
13916
+ if (this.expressionScope.enter(kg()), r) e.body = this.parseMaybeAssign(), this.checkParams(e, !1, t, !1);
13857
13917
  else {
13858
13918
  let r = this.state.strict, i = this.state.labels;
13859
13919
  this.state.labels = [], this.prodParam.enter(this.prodParam.currentFlags() | 4), e.body = this.parseBlock(!0, !1, (i) => {
@@ -13913,17 +13973,17 @@ var wg = class extends fg {
13913
13973
  }
13914
13974
  parseIdentifierName(e) {
13915
13975
  let t, { start: n, type: r } = this.state;
13916
- Rm(r) ? t = this.state.value : this.unexpected();
13917
- let i = Lm(r);
13976
+ Km(r) ? t = this.state.value : this.unexpected();
13977
+ let i = Gm(r);
13918
13978
  return e ? i && this.replaceToken(128) : this.checkReservedWord(t, this.sourceToOffsetPos(n), i, !1), this.next(), t;
13919
13979
  }
13920
13980
  checkReservedWord(e, t, n, r) {
13921
- if (!(e.length > 10) && xh(e)) {
13922
- if (n && vh(e)) {
13981
+ if (!(e.length > 10) && kh(e)) {
13982
+ if (n && Eh(e)) {
13923
13983
  this.raise(W.UnexpectedKeyword, t, { keyword: e });
13924
13984
  return;
13925
13985
  }
13926
- if ((this.state.strict ? r ? _h : hh : mh)(e, this.inModule)) {
13986
+ if ((this.state.strict ? r ? Th : Ch : Sh)(e, this.inModule)) {
13927
13987
  this.raise(W.UnexpectedReservedWord, t, { reservedWord: e });
13928
13988
  return;
13929
13989
  }
@@ -13961,7 +14021,7 @@ var wg = class extends fg {
13961
14021
  isAmbiguousPrefixOrIdentifier() {
13962
14022
  if (this.hasPrecedingLineBreak()) return !0;
13963
14023
  let { type: e } = this.state;
13964
- return e === 49 || e === 6 || e === 0 || eh(e) || e === 98 && !this.state.containsEsc || e === 133 || e === 52 || this.hasPlugin("v8intrinsic") && e === 50;
14024
+ return e === 49 || e === 6 || e === 0 || ch(e) || e === 98 && !this.state.containsEsc || e === 133 || e === 52 || this.hasPlugin("v8intrinsic") && e === 50;
13965
14025
  }
13966
14026
  parseYield(e) {
13967
14027
  this.setLoc(e);
@@ -14039,7 +14099,7 @@ var wg = class extends fg {
14039
14099
  if (this.isContextual(92) && this.recordAwaitIfAllowed()) {
14040
14100
  this.next(), n = this.parseAwait(t, !0);
14041
14101
  let e = this.state.type;
14042
- Km(e) && e !== 35 && (this.prodParam.hasIn || e !== 54) && this.raise(W.PipelineUnparenthesized, t);
14102
+ eh(e) && e !== 35 && (this.prodParam.hasIn || e !== 54) && this.raise(W.PipelineUnparenthesized, t);
14043
14103
  } else this.state.canStartArrow = !0, n = this.parseExprOp(this.parseMaybeUnaryOrPrivate(), t, e);
14044
14104
  return this.prodParam.exit(), n;
14045
14105
  }
@@ -14071,17 +14131,17 @@ var wg = class extends fg {
14071
14131
  return this.parseMaybeAssignAllowIn(t, n);
14072
14132
  }
14073
14133
  parsePropertyNamePrefixOperator(e) {}
14074
- }, Mg = { kind: 1 }, Ng = { kind: 2 }, Pg = /[\uD800-\uDFFF]/u, Fg = /in(?:stanceof)?/y;
14075
- function Ig(e) {
14134
+ }, Bg = { kind: 1 }, Vg = { kind: 2 }, Hg = /[\uD800-\uDFFF]/u, Ug = /in(?:stanceof)?/y;
14135
+ function Wg(e) {
14076
14136
  for (let t = 0; t < e.length; t++) {
14077
14137
  let n = e[t], { type: r } = n;
14078
- typeof r == "number" && (n.type = th(r));
14138
+ typeof r == "number" && (n.type = lh(r));
14079
14139
  }
14080
14140
  return e;
14081
14141
  }
14082
- var Lg = class extends jg {
14142
+ var Gg = class extends zg {
14083
14143
  parseTopLevel(e, t) {
14084
- return e.program = this.parseProgram(t, 135, this.options.sourceType === "module" ? "module" : "script"), e.comments = this.comments, this.optionFlags & 512 && (e.tokens = Ig(this.tokens)), this.finishNode(e, "File");
14144
+ return e.program = this.parseProgram(t, 135, this.options.sourceType === "module" ? "module" : "script"), e.comments = this.comments, this.optionFlags & 512 && (e.tokens = Wg(this.tokens)), this.finishNode(e, "File");
14085
14145
  }
14086
14146
  parseProgram(e, t, n) {
14087
14147
  if (e.sourceType = n, e.interpreter = this.parseInterpreterDirective(), this.parseBlockBody(e, !0, !0, t), this.inModule) {
@@ -14089,7 +14149,7 @@ var Lg = class extends jg {
14089
14149
  this.addExtra(e, "topLevelAwait", this.state.hasTopLevelAwait);
14090
14150
  }
14091
14151
  let r;
14092
- return r = t === 135 ? this.finishNode(e, "Program") : this.finishNodeAt(e, "Program", im(this.state.startLoc, -1)), r;
14152
+ return r = t === 135 ? this.finishNode(e, "Program") : this.finishNodeAt(e, "Program", fm(this.state.startLoc, -1)), r;
14093
14153
  }
14094
14154
  stmtToDirective(e) {
14095
14155
  let t = this.castNodeTo(e, "Directive"), n = this.castNodeTo(e.expression, "DirectiveLiteral"), r = n.value, i = this.input.slice(this.offsetToSourcePos(n.start), this.offsetToSourcePos(n.end)), a = n.value = i.slice(1, -1);
@@ -14130,10 +14190,10 @@ var Lg = class extends jg {
14130
14190
  return !1;
14131
14191
  }
14132
14192
  chStartsBindingIdentifier(e, t) {
14133
- if (ch(e)) {
14134
- if (Fg.lastIndex = t, Fg.test(this.input)) {
14135
- let e = this.codePointAtPos(Fg.lastIndex);
14136
- if (!lh(e) && e !== 92) return !1;
14193
+ if (gh(e)) {
14194
+ if (Ug.lastIndex = t, Ug.test(this.input)) {
14195
+ let e = this.codePointAtPos(Ug.lastIndex);
14196
+ if (!_h(e) && e !== 92) return !1;
14137
14197
  }
14138
14198
  return !0;
14139
14199
  }
@@ -14289,10 +14349,10 @@ var Lg = class extends jg {
14289
14349
  return this.expect(7), e;
14290
14350
  }
14291
14351
  parseDoWhileStatement(e) {
14292
- return this.next(), this.state.labels.push(Mg), e.body = this.parseStatement(), this.state.labels.pop(), this.expect(88), e.test = this.parseHeaderExpression(), this.eat(9), this.finishNode(e, "DoWhileStatement");
14352
+ return this.next(), this.state.labels.push(Bg), e.body = this.parseStatement(), this.state.labels.pop(), this.expect(88), e.test = this.parseHeaderExpression(), this.eat(9), this.finishNode(e, "DoWhileStatement");
14293
14353
  }
14294
14354
  parseForStatement(e) {
14295
- this.next(), this.state.labels.push(Mg);
14355
+ this.next(), this.state.labels.push(Bg);
14296
14356
  let t = null;
14297
14357
  if (this.isContextual(92) && this.recordAwaitIfAllowed() && (t = this.state.startLoc, this.next()), this.scope.enter(0), this.expect(6), this.match(9)) return t !== null && this.unexpected(t), this.parseFor(e, null);
14298
14358
  let n = this.isContextual(96);
@@ -14305,7 +14365,7 @@ var Lg = class extends jg {
14305
14365
  return s && i && this.raise(W.ForInUsing, o), (s || this.isContextual(98)) && o.declarations.length === 1 ? this.parseForIn(e, o, t) : (t !== null && this.unexpected(t), this.parseFor(e, o));
14306
14366
  }
14307
14367
  }
14308
- let r = this.isContextual(91), i = new Tg(), a = this.parseExpression(!0, i), o = this.isContextual(98);
14368
+ let r = this.isContextual(91), i = new Ng(), a = this.parseExpression(!0, i), o = this.isContextual(98);
14309
14369
  if (o && (n && this.raise(W.ForOfLet, a), t === null && r && a.type === "Identifier" && this.raise(W.ForOfAsync, a)), o || this.match(54)) {
14310
14370
  this.checkDestructuringPrivate(i), this.toAssignable(a, !0);
14311
14371
  let n = o ? "ForOfStatement" : "ForInStatement";
@@ -14325,7 +14385,7 @@ var Lg = class extends jg {
14325
14385
  parseSwitchStatement(e) {
14326
14386
  this.next(), e.discriminant = this.parseHeaderExpression();
14327
14387
  let t = e.cases = [];
14328
- this.expect(2), this.state.labels.push(Ng), this.scope.enter(256);
14388
+ this.expect(2), this.state.labels.push(Vg), this.scope.enter(256);
14329
14389
  let n;
14330
14390
  for (let e; !this.match(4);) if (this.match(57) || this.match(61)) {
14331
14391
  let r = this.match(57);
@@ -14351,7 +14411,7 @@ var Lg = class extends jg {
14351
14411
  return this.next(), this.parseVar(e, !1, t, n), this.semicolon(), this.finishNode(e, "VariableDeclaration");
14352
14412
  }
14353
14413
  parseWhileStatement(e) {
14354
- return this.next(), e.test = this.parseHeaderExpression(), this.state.labels.push(Mg), e.body = this.parseStatement(), this.state.labels.pop(), this.finishNode(e, "WhileStatement");
14414
+ return this.next(), e.test = this.parseHeaderExpression(), this.state.labels.push(Bg), e.body = this.parseStatement(), this.state.labels.pop(), this.finishNode(e, "WhileStatement");
14355
14415
  }
14356
14416
  parseWithStatement(e) {
14357
14417
  return this.state.strict && this.raise(W.StrictWith, this.state.startLoc), this.next(), e.object = this.parseHeaderExpression(), e.body = this.parseStatement(), this.finishNode(e, "WithStatement");
@@ -14361,7 +14421,7 @@ var Lg = class extends jg {
14361
14421
  }
14362
14422
  parseLabeledStatement(e, t, n, r) {
14363
14423
  for (let e of this.state.labels) e.name === t && this.raise(W.LabelRedeclaration, n, { labelName: t });
14364
- let i = Wm(this.state.type) ? 1 : this.match(67) ? 2 : null;
14424
+ let i = Qm(this.state.type) ? 1 : this.match(67) ? 2 : null;
14365
14425
  for (let t = this.state.labels.length - 1; t >= 0; t--) {
14366
14426
  let n = this.state.labels[t];
14367
14427
  if (n.statementStart === e.start) n.statementStart = this.sourceToOffsetPos(this.state.start), n.kind = i;
@@ -14427,13 +14487,13 @@ var Lg = class extends jg {
14427
14487
  }
14428
14488
  parseFunction(e, t = 0) {
14429
14489
  let n = t & 2, r = !!(t & 1), i = r && !(t & 4), a = !!(t & 8);
14430
- return this.initFunction(e, a), this.match(51) && (n && this.raise(W.GeneratorInSingleStatementContext, this.state.startLoc), this.next(), e.generator = !0), r && (e.id = this.parseFunctionId(i)), this.scope.enter(514), this.prodParam.enter(Cg(a, e.generator)), r || (e.id = this.parseFunctionId()), this.parseFunctionParams(e, !1), this.parseFunctionBodyAndFinish(e, r ? "FunctionDeclaration" : "FunctionExpression"), this.prodParam.exit(), this.scope.exit(), r && !n && this.registerFunctionStatementId(e), e;
14490
+ return this.initFunction(e, a), this.match(51) && (n && this.raise(W.GeneratorInSingleStatementContext, this.state.startLoc), this.next(), e.generator = !0), r && (e.id = this.parseFunctionId(i)), this.scope.enter(514), this.prodParam.enter(jg(a, e.generator)), r || (e.id = this.parseFunctionId()), this.parseFunctionParams(e, !1), this.parseFunctionBodyAndFinish(e, r ? "FunctionDeclaration" : "FunctionExpression"), this.prodParam.exit(), this.scope.exit(), r && !n && this.registerFunctionStatementId(e), e;
14431
14491
  }
14432
14492
  parseFunctionId(e) {
14433
14493
  return e || X(this.state.type) ? this.parseIdentifier() : null;
14434
14494
  }
14435
14495
  parseFunctionParams(e, t) {
14436
- this.expect(6), this.expressionScope.enter(vg()), e.params = this.parseBindingList(7, 41, 2 | (t ? 4 : 0)), this.expressionScope.exit();
14496
+ this.expect(6), this.expressionScope.enter(Eg()), e.params = this.parseBindingList(7, 41, 2 | (t ? 4 : 0)), this.expressionScope.exit();
14437
14497
  }
14438
14498
  registerFunctionStatementId(e) {
14439
14499
  e.id && this.scope.declareName(e.id.name, !this.options.annexB || this.state.strict || e.generator || e.async ? this.scope.treatFunctionsAsVar ? 5 : 8201 : 17, e.id.start);
@@ -14587,7 +14647,7 @@ var Lg = class extends jg {
14587
14647
  return this.parseInitializer(e), this.semicolon(), this.finishNode(e, "ClassAccessorProperty");
14588
14648
  }
14589
14649
  parseInitializer(e) {
14590
- this.scope.enter(592), this.expressionScope.enter(xg()), this.prodParam.enter(0), e.value = this.eat(25) ? this.parseMaybeAssignAllowIn() : null, this.expressionScope.exit(), this.prodParam.exit(), this.scope.exit();
14650
+ this.scope.enter(592), this.expressionScope.enter(kg()), this.prodParam.enter(0), e.value = this.eat(25) ? this.parseMaybeAssignAllowIn() : null, this.expressionScope.exit(), this.prodParam.exit(), this.scope.exit();
14591
14651
  }
14592
14652
  parseClassId(e, t, n, r = 8331) {
14593
14653
  if (X(this.state.type)) e.id = this.parseIdentifier(), t && this.declareNameFromIdentifier(e.id, r);
@@ -14748,7 +14808,7 @@ var Lg = class extends jg {
14748
14808
  }
14749
14809
  parseModuleExportName() {
14750
14810
  if (this.match(130)) {
14751
- let e = this.parseStringLiteral(this.state.value), t = Pg.exec(e.value);
14811
+ let e = this.parseStringLiteral(this.state.value), t = Hg.exec(e.value);
14752
14812
  return t && this.raise(W.ModuleExportNameHasLoneSurrogate, e, { surrogateCharCode: t[0].charCodeAt(0) }), e;
14753
14813
  }
14754
14814
  return this.parseIdentifier(!0);
@@ -14766,7 +14826,7 @@ var Lg = class extends jg {
14766
14826
  parseMaybeImportPhase(e, t) {
14767
14827
  if (!this.isPotentialImportPhase(t)) return this.applyImportPhase(e, t, null), null;
14768
14828
  let n = this.startNode(), r = this.parseIdentifierName(!0), { type: i } = this.state;
14769
- return (Rm(i) ? i !== 94 || this.lookaheadCharCode() === 102 : i !== 8) ? (this.applyImportPhase(e, t, r, n.start), null) : (this.applyImportPhase(e, t, null), this.createIdentifier(n, r));
14829
+ return (Km(i) ? i !== 94 || this.lookaheadCharCode() === 102 : i !== 8) ? (this.applyImportPhase(e, t, r, n.start), null) : (this.applyImportPhase(e, t, null), this.createIdentifier(n, r));
14770
14830
  }
14771
14831
  isPrecedingIdImportPhase(e) {
14772
14832
  let { type: t } = this.state;
@@ -14816,7 +14876,7 @@ var Lg = class extends jg {
14816
14876
  let n = this.startNodeAtNode(t);
14817
14877
  return n.local = t, e.specifiers.push(this.finishImportSpecifier(n, "ImportDefaultSpecifier")), !0;
14818
14878
  }
14819
- return Rm(this.state.type) ? (this.parseImportSpecifierLocal(e, this.startNode(), "ImportDefaultSpecifier"), !0) : !1;
14879
+ return Km(this.state.type) ? (this.parseImportSpecifierLocal(e, this.startNode(), "ImportDefaultSpecifier"), !0) : !1;
14820
14880
  }
14821
14881
  maybeParseStarImportSpecifier(e) {
14822
14882
  if (this.match(51)) {
@@ -14851,15 +14911,15 @@ var Lg = class extends jg {
14851
14911
  isThisParam(e) {
14852
14912
  return e.type === "Identifier" && e.name === "this";
14853
14913
  }
14854
- }, Rg = /in(?:stanceof)?|as|satisfies/y;
14855
- function zg(e) {
14914
+ }, Kg = /in(?:stanceof)?|as|satisfies/y;
14915
+ function qg(e) {
14856
14916
  if (e == null) throw Error(`Unexpected ${e} value.`);
14857
14917
  return e;
14858
14918
  }
14859
- function Bg(e) {
14919
+ function Jg(e) {
14860
14920
  if (!e) throw Error("Assert fail");
14861
14921
  }
14862
- var $ = _m`typescript`({
14922
+ var $ = Tm`typescript`({
14863
14923
  AbstractMethodHasImplementation: ({ methodName: e }) => `Method '${e}' cannot have an implementation because it is marked abstract.`,
14864
14924
  AbstractPropertyHasInitializer: ({ propertyName: e }) => `Property '${e}' cannot have an initializer because it is marked abstract.`,
14865
14925
  AccessorCannotBeOptional: "An 'accessor' property cannot be declared optional.",
@@ -14937,7 +14997,7 @@ var $ = _m`typescript`({
14937
14997
  UnsupportedSignatureParameterKind: ({ type: e }) => `Name in a signature must be an Identifier, ObjectPattern or ArrayPattern, instead got ${e}.`,
14938
14998
  UsingDeclarationInAmbientContext: (e) => `'${e}' declarations are not allowed in ambient contexts.`
14939
14999
  });
14940
- function Vg(e) {
15000
+ function Yg(e) {
14941
15001
  switch (e) {
14942
15002
  case "any": return "TSAnyKeyword";
14943
15003
  case "boolean": return "TSBooleanKeyword";
@@ -14952,24 +15012,24 @@ function Vg(e) {
14952
15012
  default: return;
14953
15013
  }
14954
15014
  }
14955
- function Hg(e) {
15015
+ function Xg(e) {
14956
15016
  return e === "private" || e === "public" || e === "protected";
14957
15017
  }
14958
- function Ug(e) {
15018
+ function Zg(e) {
14959
15019
  return e === "in" || e === "out";
14960
15020
  }
14961
- function Wg(e) {
15021
+ function Qg(e) {
14962
15022
  if (e.extra?.parenthesized) return !1;
14963
15023
  switch (e.type) {
14964
15024
  case "Identifier": return !0;
14965
- case "MemberExpression": return !e.computed && Wg(e.object);
14966
- case "TSInstantiationExpression": return Wg(e.expression);
15025
+ case "MemberExpression": return !e.computed && Qg(e.object);
15026
+ case "TSInstantiationExpression": return Qg(e.expression);
14967
15027
  default: return !1;
14968
15028
  }
14969
15029
  }
14970
- var Gg = (e) => class extends e {
15030
+ var $g = (e) => class extends e {
14971
15031
  getScopeHandler() {
14972
- return Gh;
15032
+ return $h;
14973
15033
  }
14974
15034
  tsIsIdentifier() {
14975
15035
  return X(this.state.type);
@@ -15000,7 +15060,7 @@ var Gg = (e) => class extends e {
15000
15060
  for (;;) {
15001
15061
  let { startLoc: s } = this.state, c = this.tsParseModifier(e.concat(t ?? []), n, i.static);
15002
15062
  if (!c) break;
15003
- Hg(c) ? i.accessibility ? this.raise($.DuplicateAccessibilityModifier, s, { modifier: c }) : (a(s, c, c, "override"), a(s, c, c, "static"), a(s, c, c, "readonly"), i.accessibility = c) : Ug(c) ? (i[c] && this.raise($.DuplicateModifier, s, { modifier: c }), i[c] = !0, a(s, c, "in", "out")) : (Object.hasOwn(i, c) ? this.raise($.DuplicateModifier, s, { modifier: c }) : (a(s, c, "static", "readonly"), a(s, c, "static", "override"), a(s, c, "override", "readonly"), a(s, c, "abstract", "override"), o(s, c, "declare", "override"), o(s, c, "static", "abstract")), i[c] = !0), t?.includes(c) && this.raise(r, s, { modifier: c });
15063
+ Xg(c) ? i.accessibility ? this.raise($.DuplicateAccessibilityModifier, s, { modifier: c }) : (a(s, c, c, "override"), a(s, c, c, "static"), a(s, c, c, "readonly"), i.accessibility = c) : Zg(c) ? (i[c] && this.raise($.DuplicateModifier, s, { modifier: c }), i[c] = !0, a(s, c, "in", "out")) : (Object.hasOwn(i, c) ? this.raise($.DuplicateModifier, s, { modifier: c }) : (a(s, c, "static", "readonly"), a(s, c, "static", "override"), a(s, c, "override", "readonly"), a(s, c, "abstract", "override"), o(s, c, "declare", "override"), o(s, c, "static", "abstract")), i[c] = !0), t?.includes(c) && this.raise(r, s, { modifier: c });
15004
15064
  }
15005
15065
  }
15006
15066
  tsIsListTerminator(e) {
@@ -15018,7 +15078,7 @@ var Gg = (e) => class extends e {
15018
15078
  return n;
15019
15079
  }
15020
15080
  tsParseDelimitedList(e, t, n) {
15021
- return zg(this.tsParseDelimitedListWorker(e, t, !0, n));
15081
+ return qg(this.tsParseDelimitedListWorker(e, t, !0, n));
15022
15082
  }
15023
15083
  tsParseDelimitedListWorker(e, t, n, r) {
15024
15084
  let i = [], a = -1;
@@ -15237,7 +15297,7 @@ var Gg = (e) => class extends e {
15237
15297
  }), this.finishNode(e, "TSTupleType");
15238
15298
  }
15239
15299
  tsParseTupleElementType() {
15240
- let e = this.state.startLoc, t = this.eat(17), { startLoc: n } = this.state, r, i, a, o, s = Rm(this.state.type) ? this.lookaheadCharCode() : null;
15300
+ let e = this.state.startLoc, t = this.eat(17), { startLoc: n } = this.state, r, i, a, o, s = Km(this.state.type) ? this.lookaheadCharCode() : null;
15241
15301
  if (s === 58) r = !0, a = !1, i = this.parseIdentifier(!0), this.expect(10), o = this.tsParseType();
15242
15302
  else if (s === 63) {
15243
15303
  a = !0;
@@ -15330,7 +15390,7 @@ var Gg = (e) => class extends e {
15330
15390
  default: {
15331
15391
  let { type: e } = this.state;
15332
15392
  if (X(e) || e === 84 || e === 80) {
15333
- let t = e === 84 ? "TSVoidKeyword" : e === 80 ? "TSNullKeyword" : Vg(this.state.value);
15393
+ let t = e === 84 ? "TSVoidKeyword" : e === 80 ? "TSNullKeyword" : Yg(this.state.value);
15334
15394
  if (t !== void 0 && this.lookaheadCharCode() !== 46) {
15335
15395
  let e = this.startNode();
15336
15396
  return this.next(), this.finishNode(e, t);
@@ -15376,7 +15436,7 @@ var Gg = (e) => class extends e {
15376
15436
  }
15377
15437
  }
15378
15438
  tsParseTypeOperatorOrHigher() {
15379
- return Ym(this.state.type) && !this.state.containsEsc ? this.tsParseTypeOperator() : this.isContextual(111) ? this.tsParseInferType() : this.tsInAllowConditionalTypesContext(() => this.tsParseArrayTypeOrHigher());
15439
+ return rh(this.state.type) && !this.state.containsEsc ? this.tsParseTypeOperator() : this.isContextual(111) ? this.tsParseInferType() : this.tsInAllowConditionalTypesContext(() => this.tsParseArrayTypeOrHigher());
15380
15440
  }
15381
15441
  tsParseUnionOrIntersectionType(e, t, n) {
15382
15442
  let r = this.startNode(), i = this.eat(n), a = [];
@@ -15457,7 +15517,7 @@ var Gg = (e) => class extends e {
15457
15517
  }), this.finishNode(t, "TSTypeAnnotation");
15458
15518
  }
15459
15519
  tsParseType() {
15460
- Bg(this.state.inType);
15520
+ Jg(this.state.inType);
15461
15521
  let e = this.tsParseNonConditionalType();
15462
15522
  if (this.state.inDisallowConditionalTypesContext || this.hasPrecedingLineBreak() || !this.eat(77)) return e;
15463
15523
  let t = this.startNodeAtNode(e);
@@ -15477,7 +15537,7 @@ var Gg = (e) => class extends e {
15477
15537
  tsParseHeritageClause(e) {
15478
15538
  let t = this.state.startLoc, n = this.tsParseDelimitedList("HeritageClauseElement", () => {
15479
15539
  let t = (this.state.canStartArrow = !1, super.parseExprSubscripts());
15480
- Wg(t) || this.raise($.InvalidHeritageClauseType, t.start, { token: e });
15540
+ Qg(t) || this.raise($.InvalidHeritageClauseType, t.start, { token: e });
15481
15541
  let n = e === "extends" ? "TSInterfaceHeritage" : "TSClassImplements";
15482
15542
  if (t.type === "TSInstantiationExpression") return t.type = n, t;
15483
15543
  let r = this.startNodeAtNode(t);
@@ -15668,7 +15728,7 @@ var Gg = (e) => class extends e {
15668
15728
  return e.params = this.tsInType(() => this.tsInTopLevelContext(() => (this.expect(43), this.tsParseDelimitedList("TypeParametersOrArguments", this.tsParseType.bind(this))))), e.params.length === 0 ? this.raise($.EmptyTypeArguments, e) : !this.state.inType && this.curContext() === Z.brace && this.reScan_lt_gt(), this.expect(44), this.finishNode(e, "TSTypeParameterInstantiation");
15669
15729
  }
15670
15730
  tsIsDeclarationStart() {
15671
- return Xm(this.state.type);
15731
+ return ih(this.state.type);
15672
15732
  }
15673
15733
  isExportDefaultSpecifier() {
15674
15734
  return !this.tsIsDeclarationStart() && super.isExportDefaultSpecifier();
@@ -15750,7 +15810,7 @@ var Gg = (e) => class extends e {
15750
15810
  a = this.state.curPosition();
15751
15811
  return;
15752
15812
  }
15753
- if (eh(this.state.type)) {
15813
+ if (ch(this.state.type)) {
15754
15814
  let n = super.parseTaggedTemplateExpression(e, t, r);
15755
15815
  return n.typeArguments = o, n;
15756
15816
  }
@@ -15759,7 +15819,7 @@ var Gg = (e) => class extends e {
15759
15819
  return n.callee = e, n.arguments = this.parseCallExpressionArguments(), this.tsCheckForInvalidTypeCasts(n.arguments), n.typeArguments = o, r.optionalChainMember && (n.optional = i), this.finishCallExpression(n, r.optionalChainMember);
15760
15820
  }
15761
15821
  let s = this.state.type;
15762
- if (s === 44 || s === 48 || s !== 6 && s !== 89 && s !== 116 && Vm(s) && !this.hasPrecedingLineBreak()) return;
15822
+ if (s === 44 || s === 48 || s !== 6 && s !== 89 && s !== 116 && Ym(s) && !this.hasPrecedingLineBreak()) return;
15763
15823
  let c = this.startNodeAt(t);
15764
15824
  return c.expression = e, c.typeArguments = o, this.finishNode(c, "TSInstantiationExpression");
15765
15825
  });
@@ -15774,7 +15834,7 @@ var Gg = (e) => class extends e {
15774
15834
  }
15775
15835
  parseExprOp(e, t, n) {
15776
15836
  let r;
15777
- if (Qm(54) > n && !this.hasPrecedingLineBreak() && (this.isContextual(89) || (r = this.isContextual(116)))) {
15837
+ if (oh(54) > n && !this.hasPrecedingLineBreak() && (this.isContextual(89) || (r = this.isContextual(116)))) {
15778
15838
  let i = this.startNodeAt(t);
15779
15839
  i.expression = e, i.typeAnnotation = this.tsInType(() => (this.next(), this.match(71) ? (r && this.raise(W.UnexpectedKeyword, this.state.startLoc, { keyword: "const" }), this.tsParseTypeReference()) : this.tsParseType()));
15780
15840
  let a = this.finishNode(i, r ? "TSSatisfiesExpression" : "TSAsExpression");
@@ -15853,7 +15913,7 @@ var Gg = (e) => class extends e {
15853
15913
  if (r && !e.declare && (t === "using" || t === "await using")) return this.raiseOverwrite($.UsingDeclarationInAmbientContext, e, t), i;
15854
15914
  for (let e of i.declarations) {
15855
15915
  let { id: n, init: i, definite: a } = e;
15856
- a && (i ? this.raise($.DeclaratorDefiniteAssertionWithInitializer, n) : n.typeAnnotation || this.raise($.DeclaratorDefiniteAssertionRequiresTypeAnnotation, n)), r && i && (t === "var" || t === "let" || n.typeAnnotation ? this.raise($.InitializerNotAllowedInAmbientContext, i) : qg(i, this.hasPlugin("estree")) || this.raise($.ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference, i));
15916
+ a && (i ? this.raise($.DeclaratorDefiniteAssertionWithInitializer, n) : n.typeAnnotation || this.raise($.DeclaratorDefiniteAssertionRequiresTypeAnnotation, n)), r && i && (t === "var" || t === "let" || n.typeAnnotation ? this.raise($.InitializerNotAllowedInAmbientContext, i) : t_(i, this.hasPlugin("estree")) || this.raise($.ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference, i));
15857
15917
  }
15858
15918
  return i;
15859
15919
  }
@@ -15919,7 +15979,7 @@ var Gg = (e) => class extends e {
15919
15979
  ]);
15920
15980
  }
15921
15981
  tsHasSomeModifiers(e, t) {
15922
- return t.some((t) => Hg(t) ? e.accessibility === t : !!e[t]);
15982
+ return t.some((t) => Xg(t) ? e.accessibility === t : !!e[t]);
15923
15983
  }
15924
15984
  tsIsStartOfStaticBlocks() {
15925
15985
  return this.isContextual(102) && this.lookaheadCharCode() === 123;
@@ -16068,12 +16128,12 @@ var Gg = (e) => class extends e {
16068
16128
  let r = super.parseMaybeAssign(e, t);
16069
16129
  if ((r.type !== "ArrowFunctionExpression" || r.extra?.parenthesized) && n(), a?.params.length !== 0 && this.resetStartLocationFromNode(r, a), r.typeParameters = a, this.hasPlugin("jsx") && r.typeParameters.params.length === 1 && !r.typeParameters.extra?.trailingComma) {
16070
16130
  let e = r.typeParameters.params[0];
16071
- e.constraint || this.raise($.SingleTypeParameterWithoutTrailingComma, this.optionFlags & 256 ? im(e.loc.end, 1) : e, { typeParameterName: e.name.name });
16131
+ e.constraint || this.raise($.SingleTypeParameterWithoutTrailingComma, this.optionFlags & 256 ? fm(e.loc.end, 1) : e, { typeParameterName: e.name.name });
16072
16132
  }
16073
16133
  return r;
16074
16134
  }, n);
16075
16135
  if (!o.error && !o.aborted) return a && this.reportReservedArrowTypeParam(a), o.node;
16076
- if (!r && (Bg(!this.hasPlugin("jsx")), i = this.tryParse(() => super.parseMaybeAssign(e, t), n), !i.error)) return i.node;
16136
+ if (!r && (Jg(!this.hasPlugin("jsx")), i = this.tryParse(() => super.parseMaybeAssign(e, t), n), !i.error)) return i.node;
16077
16137
  if (r?.node) return this.state = r.failState, r.node;
16078
16138
  if (o.node) return this.state = o.failState, a && this.reportReservedArrowTypeParam(a), o.node;
16079
16139
  if (i?.node) return this.state = i.failState, i.node;
@@ -16297,9 +16357,9 @@ var Gg = (e) => class extends e {
16297
16357
  let e = this.parseIdentifier();
16298
16358
  if (this.isContextual(89)) {
16299
16359
  let n = this.parseIdentifier();
16300
- Rm(this.state.type) ? (s = !0, a = e, o = t ? this.parseIdentifier() : this.parseModuleExportName(), c = !1) : (o = n, c = !1);
16301
- } else Rm(this.state.type) ? (c = !1, o = t ? this.parseIdentifier() : this.parseModuleExportName()) : (s = !0, a = e);
16302
- } else Rm(this.state.type) && (s = !0, t ? (a = this.parseIdentifier(!0), this.isContextual(89) || this.checkReservedWord(a.name, a.start, !0, !0)) : a = this.parseModuleExportName());
16360
+ Km(this.state.type) ? (s = !0, a = e, o = t ? this.parseIdentifier() : this.parseModuleExportName(), c = !1) : (o = n, c = !1);
16361
+ } else Km(this.state.type) ? (c = !1, o = t ? this.parseIdentifier() : this.parseModuleExportName()) : (s = !0, a = e);
16362
+ } else Km(this.state.type) && (s = !0, t ? (a = this.parseIdentifier(!0), this.isContextual(89) || this.checkReservedWord(a.name, a.start, !0, !0)) : a = this.parseModuleExportName());
16303
16363
  s && n && this.raise(t ? $.TypeModifierIsUsedInTypeImports : $.TypeModifierIsUsedInTypeExports, l), e[r] = a, e[i] = o;
16304
16364
  let u = t ? "importKind" : "exportKind";
16305
16365
  e[u] = s ? "type" : "value", c && this.eatContextual(89) && (e[i] = t ? this.parseIdentifier() : this.parseModuleExportName()), e[i] || (e[i] = this.cloneIdentifier(e[r])), t && this.checkIdentifier(e[i], s ? 4098 : 4096);
@@ -16378,10 +16438,10 @@ var Gg = (e) => class extends e {
16378
16438
  }
16379
16439
  }
16380
16440
  chStartsBindingIdentifierAndNotRelationalOperator(e, t) {
16381
- if (ch(e)) {
16382
- if (Rg.lastIndex = t, Rg.test(this.input)) {
16383
- let e = this.codePointAtPos(Rg.lastIndex);
16384
- if (!lh(e) && e !== 92) return !1;
16441
+ if (gh(e)) {
16442
+ if (Kg.lastIndex = t, Kg.test(this.input)) {
16443
+ let e = this.codePointAtPos(Kg.lastIndex);
16444
+ if (!_h(e) && e !== 92) return !1;
16385
16445
  }
16386
16446
  return !0;
16387
16447
  }
@@ -16396,12 +16456,12 @@ var Gg = (e) => class extends e {
16396
16456
  return t === 34 || t === 39;
16397
16457
  }
16398
16458
  };
16399
- function Kg(e) {
16459
+ function e_(e) {
16400
16460
  if (e.type !== "MemberExpression") return !1;
16401
16461
  let { computed: t, property: n } = e;
16402
- return t && n.type !== "StringLiteral" && (n.type !== "TemplateLiteral" || n.expressions.length > 0) ? !1 : Xg(e.object);
16462
+ return t && n.type !== "StringLiteral" && (n.type !== "TemplateLiteral" || n.expressions.length > 0) ? !1 : i_(e.object);
16403
16463
  }
16404
- function qg(e, t) {
16464
+ function t_(e, t) {
16405
16465
  let { type: n } = e;
16406
16466
  if (e.extra?.parenthesized) return !1;
16407
16467
  if (t) {
@@ -16410,25 +16470,25 @@ function qg(e, t) {
16410
16470
  if (typeof t == "string" || typeof t == "boolean") return !0;
16411
16471
  }
16412
16472
  } else if (n === "StringLiteral" || n === "BooleanLiteral") return !0;
16413
- return !!(Jg(e, t) || Yg(e, t) || n === "TemplateLiteral" && e.expressions.length === 0 || Kg(e));
16473
+ return !!(n_(e, t) || r_(e, t) || n === "TemplateLiteral" && e.expressions.length === 0 || e_(e));
16414
16474
  }
16415
- function Jg(e, t) {
16475
+ function n_(e, t) {
16416
16476
  return t ? e.type === "Literal" && (typeof e.value == "number" || "bigint" in e) : e.type === "NumericLiteral" || e.type === "BigIntLiteral";
16417
16477
  }
16418
- function Yg(e, t) {
16478
+ function r_(e, t) {
16419
16479
  if (e.type === "UnaryExpression") {
16420
16480
  let { operator: n, argument: r } = e;
16421
- if (n === "-" && Jg(r, t)) return !0;
16481
+ if (n === "-" && n_(r, t)) return !0;
16422
16482
  }
16423
16483
  return !1;
16424
16484
  }
16425
- function Xg(e) {
16426
- return e.type === "Identifier" ? !0 : e.type !== "MemberExpression" || e.computed ? !1 : Xg(e.object);
16485
+ function i_(e) {
16486
+ return e.type === "Identifier" ? !0 : e.type !== "MemberExpression" || e.computed ? !1 : i_(e.object);
16427
16487
  }
16428
- var Zg = _m`placeholders`({
16488
+ var a_ = Tm`placeholders`({
16429
16489
  ClassNameIsRequired: "A class name is required.",
16430
16490
  UnexpectedSpace: "Unexpected space in placeholder."
16431
- }), Qg = (e) => class extends e {
16491
+ }), o_ = (e) => class extends e {
16432
16492
  parsePlaceholder(e) {
16433
16493
  if (this.match(129)) {
16434
16494
  let t = this.startNode();
@@ -16498,7 +16558,7 @@ var Zg = _m`placeholders`({
16498
16558
  if (a) {
16499
16559
  if (this.match(77) || this.match(129) || this.match(2)) e.id = a;
16500
16560
  else if (n || !t) return e.id = null, e.body = this.finishPlaceholder(a, "ClassBody"), this.finishNode(e, r);
16501
- else throw this.raise(Zg.ClassNameIsRequired, this.state.startLoc);
16561
+ else throw this.raise(a_.ClassNameIsRequired, this.state.startLoc);
16502
16562
  } else this.parseClassId(e, t, n);
16503
16563
  return super.parseClassSuper(e), e.body = this.parsePlaceholder("ClassBody") || super.parseClassBody(!!e.superClass, i), this.finishNode(e, r);
16504
16564
  }
@@ -16514,7 +16574,7 @@ var Zg = _m`placeholders`({
16514
16574
  isExportDefaultSpecifier() {
16515
16575
  if (this.match(61)) {
16516
16576
  let e = this.nextTokenStart();
16517
- if (this.isUnparsedContextual(e, "from") && this.input.startsWith(Zm(129), this.nextTokenStartSince(e + 4))) return !0;
16577
+ if (this.isUnparsedContextual(e, "from") && this.input.startsWith(ah(129), this.nextTokenStartSince(e + 4))) return !0;
16518
16578
  }
16519
16579
  return super.isExportDefaultSpecifier();
16520
16580
  }
@@ -16536,9 +16596,9 @@ var Zg = _m`placeholders`({
16536
16596
  return this.parsePlaceholder("StringLiteral") || super.parseImportSource();
16537
16597
  }
16538
16598
  assertNoSpace() {
16539
- this.state.start > this.offsetToSourcePos(this.state.lastTokEndLoc.index) && this.raise(Zg.UnexpectedSpace, this.state.lastTokEndLoc);
16599
+ this.state.start > this.offsetToSourcePos(this.state.lastTokEndLoc.index) && this.raise(a_.UnexpectedSpace, this.state.lastTokEndLoc);
16540
16600
  }
16541
- }, $g = (e) => class extends e {
16601
+ }, s_ = (e) => class extends e {
16542
16602
  parseV8Intrinsic() {
16543
16603
  if (this.match(50)) {
16544
16604
  let e = this.state.startLoc, t = this.startNode();
@@ -16552,29 +16612,29 @@ var Zg = _m`placeholders`({
16552
16612
  parseExprAtom(e) {
16553
16613
  return this.parseV8Intrinsic() || super.parseExprAtom(e);
16554
16614
  }
16555
- }, e_ = ["fsharp", "hack"], t_ = [
16615
+ }, c_ = ["fsharp", "hack"], l_ = [
16556
16616
  "^^",
16557
16617
  "@@",
16558
16618
  "^",
16559
16619
  "%",
16560
16620
  "#"
16561
16621
  ];
16562
- function n_(e) {
16622
+ function u_(e) {
16563
16623
  if (e.has("decorators") && e.has("decorators-legacy")) throw Error("Cannot use the decorators and decorators-legacy plugin together");
16564
16624
  if (e.has("flow") && e.has("typescript")) throw Error("Cannot combine flow and typescript plugins.");
16565
16625
  if (e.has("placeholders") && e.has("v8intrinsic")) throw Error("Cannot combine placeholders and v8intrinsic plugins.");
16566
16626
  if (e.has("pipelineOperator")) {
16567
16627
  let t = e.get("pipelineOperator").proposal;
16568
- if (!e_.includes(t)) {
16569
- let e = e_.map((e) => `"${e}"`).join(", ");
16628
+ if (!c_.includes(t)) {
16629
+ let e = c_.map((e) => `"${e}"`).join(", ");
16570
16630
  throw Error(`"pipelineOperator" requires "proposal" option whose value must be one of: ${e}.`);
16571
16631
  }
16572
16632
  if (t === "hack") {
16573
16633
  if (e.has("placeholders")) throw Error("Cannot combine placeholders plugin and Hack-style pipes.");
16574
16634
  if (e.has("v8intrinsic")) throw Error("Cannot combine v8intrinsic plugin and Hack-style pipes.");
16575
16635
  let t = e.get("pipelineOperator").topicToken;
16576
- if (!t_.includes(t)) {
16577
- let e = t_.map((e) => `"${e}"`).join(", ");
16636
+ if (!l_.includes(t)) {
16637
+ let e = l_.map((e) => `"${e}"`).join(", ");
16578
16638
  throw Error(`"pipelineOperator" in "proposal": "hack" mode also requires a "topicToken" option whose value must be one of: ${e}.`);
16579
16639
  }
16580
16640
  }
@@ -16591,22 +16651,22 @@ function n_(e) {
16591
16651
  if (e.has("decimal")) throw Error("The 'decimal' plugin has been removed in Babel 8. Please remove it from your configuration.");
16592
16652
  if (e.has("importReflection")) throw Error("The 'importReflection' plugin has been removed in Babel 8. Use 'sourcePhaseImports' instead, and replace 'import module' with 'import source' in your code.");
16593
16653
  }
16594
- var r_ = {
16595
- estree: xm,
16596
- jsx: Uh,
16597
- flow: Mh,
16598
- typescript: Gg,
16599
- v8intrinsic: $g,
16600
- placeholders: Qg
16601
- }, i_ = Object.keys(r_), a_ = class extends Lg {
16654
+ var d_ = {
16655
+ estree: km,
16656
+ jsx: Zh,
16657
+ flow: Bh,
16658
+ typescript: $g,
16659
+ v8intrinsic: s_,
16660
+ placeholders: o_
16661
+ }, f_ = Object.keys(d_), p_ = class extends Gg {
16602
16662
  constructor(e, t, n) {
16603
- let r = ym(e);
16663
+ let r = Dm(e);
16604
16664
  super(r, t), this.options = r, this.initializeScopes(), this.plugins = n, this.filename = r.sourceFilename, this.startIndex = r.startIndex;
16605
16665
  let i = 0;
16606
16666
  r.allowAwaitOutsideFunction && (i |= 1), r.allowReturnOutsideFunction && (i |= 2), r.allowImportExportEverywhere && (i |= 8), r.allowSuperOutsideMethod && (i |= 16), r.allowUndeclaredExports && (i |= 64), r.allowNewTargetOutsideFunction && (i |= 4), r.allowYieldOutsideFunction && (i |= 32), r.ranges && (i |= 128), r.locations === !0 && (i |= 256), r.tokens && (i |= 512), r.createImportExpressions && (i |= 1024), r.createParenthesizedExpressions && (i |= 2048), r.errorRecovery && (i |= 4096), r.attachComment && (i |= 8192), r.annexB && (i |= 16384), this.optionFlags = i;
16607
16667
  }
16608
16668
  getScopeHandler() {
16609
- return Ch;
16669
+ return jh;
16610
16670
  }
16611
16671
  parse() {
16612
16672
  this.enterInitialScopes();
@@ -16616,91 +16676,91 @@ var r_ = {
16616
16676
  return n.errors = this.state.errors, n.comments.length = this.state.commentsLen, n;
16617
16677
  }
16618
16678
  };
16619
- function o_(e, t) {
16679
+ function m_(e, t) {
16620
16680
  if (t?.sourceType === "unambiguous") {
16621
16681
  t = { ...t };
16622
16682
  try {
16623
16683
  t.sourceType = "module";
16624
- let n = c_(t, e), r = n.parse();
16684
+ let n = g_(t, e), r = n.parse();
16625
16685
  if (n.sawUnambiguousESM) return r;
16626
16686
  if (n.ambiguousScriptDifferentAst) try {
16627
- return t.sourceType = "script", c_(t, e).parse();
16687
+ return t.sourceType = "script", g_(t, e).parse();
16628
16688
  } catch {}
16629
16689
  else r.program.sourceType = "script";
16630
16690
  return r;
16631
16691
  } catch (n) {
16632
16692
  try {
16633
- return t.sourceType = "script", c_(t, e).parse();
16693
+ return t.sourceType = "script", g_(t, e).parse();
16634
16694
  } catch {}
16635
16695
  throw n;
16636
16696
  }
16637
16697
  }
16638
- return c_(t, e).parse();
16698
+ return g_(t, e).parse();
16639
16699
  }
16640
- function s_(e) {
16700
+ function h_(e) {
16641
16701
  let t = {};
16642
- for (let n of Object.keys(e)) t[n] = th(e[n]);
16702
+ for (let n of Object.keys(e)) t[n] = lh(e[n]);
16643
16703
  return t;
16644
16704
  }
16645
- s_(Im);
16646
- function c_(e, t) {
16647
- let n = a_, r = /* @__PURE__ */ new Map();
16705
+ h_(Wm);
16706
+ function g_(e, t) {
16707
+ let n = p_, r = /* @__PURE__ */ new Map();
16648
16708
  if (e?.plugins) {
16649
16709
  for (let t of e.plugins) {
16650
16710
  let e, n;
16651
16711
  typeof t == "string" ? e = t : [e, n] = t, r.has(e) || r.set(e, n || {});
16652
16712
  }
16653
- n_(r), n = u_(r);
16713
+ u_(r), n = v_(r);
16654
16714
  }
16655
16715
  return new n(e, t, r);
16656
16716
  }
16657
- var l_ = /* @__PURE__ */ new Map();
16658
- function u_(e) {
16717
+ var __ = /* @__PURE__ */ new Map();
16718
+ function v_(e) {
16659
16719
  let t = [];
16660
- for (let n of i_) e.has(n) && t.push(n);
16661
- let n = t.join("|"), r = l_.get(n);
16720
+ for (let n of f_) e.has(n) && t.push(n);
16721
+ let n = t.join("|"), r = __.get(n);
16662
16722
  if (!r) {
16663
- r = a_;
16664
- for (let e of t) r = r_[e](r);
16665
- l_.set(n, r);
16723
+ r = p_;
16724
+ for (let e of t) r = d_[e](r);
16725
+ __.set(n, r);
16666
16726
  }
16667
16727
  return r;
16668
16728
  }
16669
16729
  //#endregion
16670
16730
  //#region src/flow/common/modules.ts
16671
- function d_(e) {
16731
+ function y_(e) {
16672
16732
  return {
16673
16733
  column: e.loc?.start.column ?? 0,
16674
16734
  line: e.loc?.start.line ?? 1
16675
16735
  };
16676
16736
  }
16677
- function f_(e) {
16737
+ function b_(e) {
16678
16738
  return `/modules/${e}/source`;
16679
16739
  }
16680
- function p_(e, t) {
16740
+ function x_(e, t) {
16681
16741
  if (typeof e != "object" || !e) return;
16682
16742
  let n = e;
16683
16743
  if (n.type == "Identifier" && typeof n.name == "string") t.add(n.name);
16684
- else if (n.type == "RestElement") p_(n.argument, t);
16685
- else if (n.type == "AssignmentPattern") p_(n.left, t);
16686
- else if (n.type == "ArrayPattern") for (let e of n.elements ?? []) p_(e, t);
16744
+ else if (n.type == "RestElement") x_(n.argument, t);
16745
+ else if (n.type == "AssignmentPattern") x_(n.left, t);
16746
+ else if (n.type == "ArrayPattern") for (let e of n.elements ?? []) x_(e, t);
16687
16747
  else if (n.type == "ObjectPattern") for (let e of n.properties ?? []) {
16688
16748
  let n = e;
16689
- p_(n.type == "RestElement" ? n.argument : n.value, t);
16749
+ x_(n.type == "RestElement" ? n.argument : n.value, t);
16690
16750
  }
16691
16751
  }
16692
- function m_(e) {
16752
+ function S_(e) {
16693
16753
  if (typeof e != "object" || !e) return;
16694
16754
  let t = e;
16695
16755
  if (t.type == "Identifier" && typeof t.name == "string") return t.name;
16696
16756
  if (t.type == "StringLiteral" && typeof t.value == "string") return t.value;
16697
16757
  }
16698
- function h_(e, t, n) {
16758
+ function C_(e, t, n) {
16699
16759
  let r;
16700
16760
  try {
16701
- r = o_(t, {
16761
+ r = m_(t, {
16702
16762
  createImportExpressions: !0,
16703
- sourceFilename: f_(e),
16763
+ sourceFilename: b_(e),
16704
16764
  sourceType: "module"
16705
16765
  }).program;
16706
16766
  } catch (t) {
@@ -16710,7 +16770,7 @@ function h_(e, t, n) {
16710
16770
  column: typeof r == "object" && r && typeof Reflect.get(r, "column") == "number" ? Reflect.get(r, "column") : 0,
16711
16771
  line: typeof r == "object" && r && typeof Reflect.get(r, "line") == "number" ? Reflect.get(r, "line") : 1,
16712
16772
  message: `CodeModule "${e}" contains invalid JavaScript syntax.`,
16713
- path: f_(e),
16773
+ path: b_(e),
16714
16774
  values: { moduleId: e }
16715
16775
  });
16716
16776
  return;
@@ -16721,11 +16781,11 @@ function h_(e, t, n) {
16721
16781
  let e = t.specifiers.flatMap((e) => {
16722
16782
  if (e.type == "ImportNamespaceSpecifier") return [];
16723
16783
  if (e.type == "ImportDefaultSpecifier") return ["default"];
16724
- let t = m_(e.imported);
16784
+ let t = S_(e.imported);
16725
16785
  return t == null ? [] : [t];
16726
16786
  });
16727
16787
  a.push({
16728
- ...d_(t.source),
16788
+ ...y_(t.source),
16729
16789
  imported: e,
16730
16790
  specifier: t.source.value
16731
16791
  });
@@ -16739,9 +16799,9 @@ function h_(e, t, n) {
16739
16799
  if (t.source != null) {
16740
16800
  n.push({
16741
16801
  code: "module.unsupported-import",
16742
- ...d_(t.source),
16802
+ ...y_(t.source),
16743
16803
  message: `CodeModule "${e}" must import before re-exporting values.`,
16744
- path: f_(e),
16804
+ path: b_(e),
16745
16805
  values: {
16746
16806
  moduleId: e,
16747
16807
  variant: "reexport"
@@ -16749,10 +16809,10 @@ function h_(e, t, n) {
16749
16809
  });
16750
16810
  continue;
16751
16811
  }
16752
- if (t.declaration?.type == "VariableDeclaration") for (let e of t.declaration.declarations) p_(e.id, i);
16812
+ if (t.declaration?.type == "VariableDeclaration") for (let e of t.declaration.declarations) x_(e.id, i);
16753
16813
  else (t.declaration?.type == "FunctionDeclaration" || t.declaration?.type == "ClassDeclaration") && t.declaration.id != null && i.add(t.declaration.id.name);
16754
16814
  for (let e of t.specifiers) {
16755
- let t = m_(e.exported);
16815
+ let t = S_(e.exported);
16756
16816
  t != null && i.add(t);
16757
16817
  }
16758
16818
  }
@@ -16766,21 +16826,21 @@ function h_(e, t, n) {
16766
16826
  let r = t, i = r.callee;
16767
16827
  r.type == "ImportExpression" || r.type == "CallExpression" && i?.type == "Import" ? n.push({
16768
16828
  code: "module.dynamic-import",
16769
- ...d_(r),
16829
+ ...y_(r),
16770
16830
  message: `CodeModule "${e}" cannot use dynamic import.`,
16771
- path: f_(e),
16831
+ path: b_(e),
16772
16832
  values: { moduleId: e }
16773
16833
  }) : r.type == "CallExpression" && i?.type == "Identifier" && i.name == "require" ? n.push({
16774
16834
  code: "module.commonjs",
16775
- ...d_(r),
16835
+ ...y_(r),
16776
16836
  message: `CodeModule "${e}" cannot use CommonJS require.`,
16777
- path: f_(e),
16837
+ path: b_(e),
16778
16838
  values: { moduleId: e }
16779
16839
  }) : (r.type == "CallExpression" && i?.type == "Identifier" && (i.name == "eval" || i.name == "Function") || r.type == "NewExpression" && i?.type == "Identifier" && i.name == "Function") && n.push({
16780
16840
  code: "module.dynamic-code",
16781
- ...d_(r),
16841
+ ...y_(r),
16782
16842
  message: `CodeModule "${e}" cannot evaluate dynamic code.`,
16783
- path: f_(e),
16843
+ path: b_(e),
16784
16844
  values: { moduleId: e }
16785
16845
  });
16786
16846
  for (let [e, t] of Object.entries(r)) e != "loc" && e != "tokens" && e != "comments" && o(t);
@@ -16790,21 +16850,21 @@ function h_(e, t, n) {
16790
16850
  imports: a
16791
16851
  };
16792
16852
  }
16793
- function g_(e) {
16853
+ function w_(e) {
16794
16854
  return /^\.\/(.+)\.mjs$/.exec(e)?.[1];
16795
16855
  }
16796
- function __(e, t) {
16856
+ function T_(e, t) {
16797
16857
  return e < t ? -1 : +(e > t);
16798
16858
  }
16799
- function v_(e, t) {
16800
- return __(e.path, t.path) || e.line - t.line || e.column - t.column || __(e.code, t.code) || __(e.message, t.message);
16859
+ function E_(e, t) {
16860
+ return T_(e.path, t.path) || e.line - t.line || e.column - t.column || T_(e.code, t.code) || T_(e.message, t.message);
16801
16861
  }
16802
- function y_(e, t, n) {
16862
+ function D_(e, t, n) {
16803
16863
  let r = [], i = /* @__PURE__ */ new Map();
16804
16864
  for (let n of t.toSorted()) {
16805
16865
  let t = e.modules[n];
16806
16866
  if (t == null) continue;
16807
- let a = h_(n, t.source, r);
16867
+ let a = C_(n, t.source, r);
16808
16868
  a != null && i.set(n, a);
16809
16869
  }
16810
16870
  for (let a of t.toSorted()) {
@@ -16821,7 +16881,7 @@ function y_(e, t, n) {
16821
16881
  column: c.column,
16822
16882
  line: c.line,
16823
16883
  message: `Platform Library does not export "${e}".`,
16824
- path: f_(a),
16884
+ path: b_(a),
16825
16885
  values: {
16826
16886
  name: e,
16827
16887
  variant: "platform"
@@ -16829,14 +16889,14 @@ function y_(e, t, n) {
16829
16889
  });
16830
16890
  continue;
16831
16891
  }
16832
- let o = g_(c.specifier);
16892
+ let o = w_(c.specifier);
16833
16893
  if (o == null) {
16834
16894
  r.push({
16835
16895
  code: "module.unsupported-import",
16836
16896
  column: c.column,
16837
16897
  line: c.line,
16838
16898
  message: `CodeModule "${a}" cannot import "${c.specifier}".`,
16839
- path: f_(a),
16899
+ path: b_(a),
16840
16900
  values: {
16841
16901
  moduleId: a,
16842
16902
  specifier: c.specifier,
@@ -16851,7 +16911,7 @@ function y_(e, t, n) {
16851
16911
  column: c.column,
16852
16912
  line: c.line,
16853
16913
  message: `CodeModule "${o}" does not exist.`,
16854
- path: f_(a),
16914
+ path: b_(a),
16855
16915
  values: { moduleId: o }
16856
16916
  });
16857
16917
  continue;
@@ -16862,7 +16922,7 @@ function y_(e, t, n) {
16862
16922
  column: c.column,
16863
16923
  line: c.line,
16864
16924
  message: `CodeModule "${a}" does not declare its import of "${o}".`,
16865
- path: f_(a),
16925
+ path: b_(a),
16866
16926
  values: {
16867
16927
  importedModuleId: o,
16868
16928
  moduleId: a
@@ -16876,7 +16936,7 @@ function y_(e, t, n) {
16876
16936
  column: c.column,
16877
16937
  line: c.line,
16878
16938
  message: `CodeModule "${o}" does not export "${e}".`,
16879
- path: f_(a),
16939
+ path: b_(a),
16880
16940
  values: {
16881
16941
  moduleId: o,
16882
16942
  name: e,
@@ -16889,7 +16949,7 @@ function y_(e, t, n) {
16889
16949
  column: 0,
16890
16950
  line: 1,
16891
16951
  message: `CodeModule "${a}" declares "${e}" without a matching static import.`,
16892
- path: f_(a),
16952
+ path: b_(a),
16893
16953
  values: {
16894
16954
  importedModuleId: e,
16895
16955
  moduleId: a
@@ -16901,16 +16961,16 @@ function y_(e, t, n) {
16901
16961
  diagnostics: r
16902
16962
  };
16903
16963
  }
16904
- function b_(e, t, n) {
16905
- return y_(e, t, n).diagnostics.toSorted(v_);
16964
+ function O_(e, t, n) {
16965
+ return D_(e, t, n).diagnostics.toSorted(E_);
16906
16966
  }
16907
16967
  //#endregion
16908
16968
  //#region src/flow/common/semantics.ts
16909
- function x_(e) {
16969
+ function k_(e) {
16910
16970
  return Object.keys(e).toSorted().map((t) => [t, e[t]]);
16911
16971
  }
16912
- function S_(e, t) {
16913
- if (t != null) return S_(O_(e, t));
16972
+ function A_(e, t) {
16973
+ if (t != null) return A_(I_(e, t));
16914
16974
  let n = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), a = /* @__PURE__ */ new Set(), o = /* @__PURE__ */ new Set();
16915
16975
  function s(e) {
16916
16976
  n.add(e);
@@ -16925,7 +16985,7 @@ function S_(e, t) {
16925
16985
  for (let t of Object.values(e)) if (t.kind == "sources") for (let e of t.sources) e.kind == "binding" && (r.add(e.bindingId), s(e.bindingId));
16926
16986
  }
16927
16987
  function u(t) {
16928
- for (let [, n] of x_(t.nodes)) switch ("inputs" in n && l(n.inputs), n.kind) {
16988
+ for (let [, n] of k_(t.nodes)) switch ("inputs" in n && l(n.inputs), n.kind) {
16929
16989
  case "condition": break;
16930
16990
  case "subflow":
16931
16991
  d(n.subflowId);
@@ -16959,60 +17019,60 @@ function S_(e, t) {
16959
17019
  tasks: o
16960
17020
  };
16961
17021
  }
16962
- async function C_(e) {
16963
- let t = S_(e), { bindings: n, modules: r, subflows: i, tasks: a } = t;
17022
+ async function j_(e) {
17023
+ let t = A_(e), { bindings: n, modules: r, subflows: i, tasks: a } = t;
16964
17024
  return {
16965
17025
  dependencies: t,
16966
- digest: await mp(pp({
17026
+ digest: await hp(mp({
16967
17027
  bindings: Object.fromEntries([...n].toSorted().map((t) => [t, e.document.bindings[t] ?? null])),
16968
- graph: Sp(e.document.graph),
17028
+ graph: kp(e, e.document.graph),
16969
17029
  kind: "open-flow-semantic-closure",
16970
17030
  modelVersion: e.modelVersion,
16971
- modules: Object.fromEntries([...r].toSorted().map((t) => [t, e.modules[t] == null ? null : kp(e.modules[t])])),
16972
- tasks: Object.fromEntries([...a].toSorted().map((t) => [t, e.document.tasks[t] == null ? null : Cp(e.document.tasks[t])])),
17031
+ modules: Object.fromEntries([...r].toSorted().map((t) => [t, e.modules[t] == null ? null : Lp(e.modules[t])])),
17032
+ tasks: Object.fromEntries([...a].toSorted().map((t) => [t, e.document.tasks[t] == null ? null : jp(e.document.tasks[t])])),
16973
17033
  subflows: Object.fromEntries([...i].toSorted().map((t) => {
16974
17034
  let n = e.document.subflows[t];
16975
17035
  return n == null ? [t, null] : [t, {
16976
- graph: Sp(n.graph),
16977
- inputs: _p(n.inputs),
17036
+ graph: kp(e, n.graph),
17037
+ inputs: vp(n.inputs),
16978
17038
  name: n.name,
16979
- outputs: bp(n.outputs)
17039
+ outputs: Ap(e, n.outputs, n.graph)
16980
17040
  }];
16981
17041
  })),
16982
17042
  version: 2
16983
17043
  }))
16984
17044
  };
16985
17045
  }
16986
- function w_(e, t) {
17046
+ function M_(e, t) {
16987
17047
  return Object.fromEntries([...t].flatMap((t) => {
16988
17048
  let n = e.document.bindings[t];
16989
17049
  return n?.kind == "variable" ? [[t, n.target]] : [];
16990
17050
  }));
16991
17051
  }
16992
- function T_(e, t) {
17052
+ function N_(e, t) {
16993
17053
  if (typeof t != "object" || !t || Array.isArray(t)) return !1;
16994
17054
  let n = t;
16995
17055
  if (Object.keys(n).some((e) => e != "nodeId" && e != "outputs") || typeof n.nodeId != "string" || !Object.hasOwn(n, "outputs")) return !1;
16996
17056
  let r = e.document.graph.nodes[n.nodeId];
16997
- return r != null && !("inputs" in r) && Xf(r, n.outputs);
17057
+ return r != null && !("inputs" in r) && Zf(r, n.outputs);
16998
17058
  }
16999
- function E_(e, t) {
17059
+ function P_(e, t) {
17000
17060
  if (typeof t != "object" || !t || Array.isArray(t)) return "invalid";
17001
17061
  let n = e.document.graph;
17002
17062
  for (let [r, i] of Object.entries(t)) {
17003
17063
  let t = n.nodes[r];
17004
17064
  if (t == null || !("inputs" in t) || typeof i != "object" || !i || Array.isArray(i)) return "invalid";
17005
- let a = Rp(e.document, t);
17065
+ let a = Kp(e.document, t);
17006
17066
  for (let e of Object.keys(i)) {
17007
17067
  let n = a[e];
17008
- if (n == null || Gf(n.jsonSchema) || t.inputs[e] != null || Object.hasOwn(n, "value")) return "invalid";
17068
+ if (n == null || Kf(n.jsonSchema) || t.inputs[e] != null || Object.hasOwn(n, "value")) return "invalid";
17009
17069
  }
17010
17070
  }
17011
17071
  return "valid";
17012
17072
  }
17013
- async function D_(e, t) {
17014
- let n = await C_(e), r = y_(e, [...n.dependencies.modules], t);
17015
- r.diagnostics.push(...tm(e, n));
17073
+ async function F_(e, t) {
17074
+ let n = await j_(e), r = D_(e, [...n.dependencies.modules], t);
17075
+ r.diagnostics.push(...lm(e, n));
17016
17076
  let i = [["/document/graph", e.document.graph], ...[...n.dependencies.subflows].toSorted().flatMap((t) => {
17017
17077
  let n = e.document.subflows[t];
17018
17078
  return n == null ? [] : [[`/document/subflows/${t}/graph`, n.graph]];
@@ -17037,7 +17097,7 @@ async function D_(e, t) {
17037
17097
  values: { moduleId: o.task.moduleId }
17038
17098
  }));
17039
17099
  try {
17040
- jf(o.task.capabilities === void 0 ? [] : o.task.capabilities);
17100
+ Mf(o.task.capabilities === void 0 ? [] : o.task.capabilities);
17041
17101
  } catch {
17042
17102
  r.diagnostics.push({
17043
17103
  code: "task.capability-incomplete",
@@ -17052,7 +17112,7 @@ async function D_(e, t) {
17052
17112
  for (let t of [...n.dependencies.tasks].toSorted()) {
17053
17113
  let i = e.document.tasks[t];
17054
17114
  if (i != null) {
17055
- for (let n of sp(i, e.document.tasks)) r.diagnostics.push({
17115
+ for (let n of cp(i, e.document.tasks)) r.diagnostics.push({
17056
17116
  code: "agent.config-invalid",
17057
17117
  column: 0,
17058
17118
  line: 1,
@@ -17076,14 +17136,14 @@ async function D_(e, t) {
17076
17136
  });
17077
17137
  }
17078
17138
  }
17079
- let o = r.diagnostics.toSorted(v_);
17139
+ let o = r.diagnostics.toSorted(E_);
17080
17140
  return {
17081
17141
  closure: n,
17082
17142
  diagnostics: o,
17083
17143
  valid: o.length == 0
17084
17144
  };
17085
17145
  }
17086
- function O_(e, t) {
17146
+ function I_(e, t) {
17087
17147
  let n = e.document.graph, r = /* @__PURE__ */ new Set([t]);
17088
17148
  for (let e of r) for (let t of n.edges) t.source == e && r.add(t.target);
17089
17149
  function i(e, t) {
@@ -17112,7 +17172,7 @@ function O_(e, t) {
17112
17172
  edges: n.edges.filter((e) => r.has(e.source))
17113
17173
  }
17114
17174
  }
17115
- }, { bindings: s } = S_(o);
17175
+ }, { bindings: s } = A_(o);
17116
17176
  return {
17117
17177
  ...o,
17118
17178
  document: {
@@ -17121,15 +17181,15 @@ function O_(e, t) {
17121
17181
  }
17122
17182
  };
17123
17183
  }
17124
- async function k_(e, t, n) {
17125
- let r = tp(t);
17184
+ async function L_(e, t, n) {
17185
+ let r = np(t);
17126
17186
  if (r == null) return { kind: "engine-unsupported" };
17127
17187
  if (n != null) {
17128
17188
  let t = e.document.graph.nodes[n];
17129
17189
  if (t == null || "inputs" in t) return {
17130
17190
  kind: "flow-invalid",
17131
17191
  validation: {
17132
- closure: await C_(e),
17192
+ closure: await j_(e),
17133
17193
  diagnostics: [{
17134
17194
  code: "graph.trigger-invalid",
17135
17195
  column: 0,
@@ -17141,9 +17201,9 @@ async function k_(e, t, n) {
17141
17201
  valid: !1
17142
17202
  }
17143
17203
  };
17144
- e = O_(e, n);
17204
+ e = I_(e, n);
17145
17205
  }
17146
- let i = await D_(e, r);
17206
+ let i = await F_(e, r);
17147
17207
  if (!i.valid) return {
17148
17208
  kind: "flow-invalid",
17149
17209
  validation: i
@@ -17162,7 +17222,7 @@ async function k_(e, t, n) {
17162
17222
  validation: i
17163
17223
  };
17164
17224
  }
17165
- function A_(e, t, n) {
17225
+ function R_(e, t, n) {
17166
17226
  if (Object.hasOwn(e.modules, t)) return {
17167
17227
  engineContract: e.engineContract,
17168
17228
  engineDigest: n,
@@ -17170,7 +17230,7 @@ function A_(e, t, n) {
17170
17230
  modules: e.modules
17171
17231
  };
17172
17232
  }
17173
- function j_(e) {
17233
+ function z_(e) {
17174
17234
  return Object.values(e.tasks).flatMap((t) => {
17175
17235
  if (t.executor.kind != "agent") return [];
17176
17236
  let n = t.executor.notification == null ? void 0 : e.tasks[t.executor.notification.taskId]?.executor;
@@ -17181,8 +17241,8 @@ function j_(e) {
17181
17241
  }));
17182
17242
  });
17183
17243
  }
17184
- function M_(e) {
17244
+ function B_(e) {
17185
17245
  return [e.graph, ...Object.values(e.subflows).map((e) => e.graph)].flatMap((e) => Object.values(e.nodes).flatMap((e) => e.kind == "task" && e.task != null ? e.task.capabilities ?? [] : []));
17186
17246
  }
17187
17247
  //#endregion
17188
- export { j_ as agentActions, cp as agentInput, up as agentToolInput, lp as agentToolSchema, Zp as availableOutputs, M_ as codeActions, A_ as createRuntimeProgram, C_ as flowClosure, S_ as flowDependencies, Up as graphOrder, If as matchesSchema, Xf as matchesTriggerOutputs, Rp as nodeInputPorts, k_ as prepareFlow, Jf as triggerOutputDefinitions, Yf as triggerOutputPorts, T_ as validRunTrigger, D_ as validateFlow, E_ as validateFlowInputs, b_ as validateModules, w_ as variableBindings, Wf as variableInputCompatible };
17248
+ export { z_ as agentActions, lp as agentInput, dp as agentToolInput, up as agentToolSchema, am as availableOutputs, B_ as codeActions, R_ as createRuntimeProgram, j_ as flowClosure, A_ as flowDependencies, Zp as graphOrder, Lf as matchesSchema, Zf as matchesTriggerOutputs, Kp as nodeInputPorts, L_ as prepareFlow, Yf as triggerOutputDefinitions, Xf as triggerOutputPorts, N_ as validRunTrigger, F_ as validateFlow, P_ as validateFlowInputs, O_ as validateModules, M_ as variableBindings, Gf as variableInputCompatible };