@graphysdk/react 1.9.0-beta.1794228873898 → 1.9.0-beta.1794238447086

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.
@@ -14135,7 +14135,7 @@ function bk(e, t, r) {
14135
14135
  function xk(e, t) {
14136
14136
  return t.map((r, n) => e[n] === null ? null : r);
14137
14137
  }
14138
- var ax = (e, t) => e && t ? "solo" : e ? "base" : t ? "tip" : "middle", e8 = class extends _d {
14138
+ var ax = (e, t) => e && t ? "solo" : e ? "base" : t ? "tip" : "middle", ez = class extends _d {
14139
14139
  constructor(...e) {
14140
14140
  super(...e), this.type = "fill";
14141
14141
  }
@@ -14186,7 +14186,7 @@ var ax = (e, t) => e && t ? "solo" : e ? "base" : t ? "tip" : "middle", e8 = cla
14186
14186
  mapping: {}
14187
14187
  };
14188
14188
  }
14189
- }, t8 = class extends _d {
14189
+ }, tz = class extends _d {
14190
14190
  constructor(...e) {
14191
14191
  super(...e), this.type = "identity";
14192
14192
  }
@@ -14196,7 +14196,7 @@ var ax = (e, t) => e && t ? "solo" : e ? "base" : t ? "tip" : "middle", e8 = cla
14196
14196
  mapping: {}
14197
14197
  };
14198
14198
  }
14199
- }, r8 = class extends _d {
14199
+ }, rz = class extends _d {
14200
14200
  constructor(...e) {
14201
14201
  super(...e), this.type = "stack";
14202
14202
  }
@@ -14233,11 +14233,11 @@ var ax = (e, t) => e && t ? "solo" : e ? "base" : t ? "tip" : "middle", e8 = cla
14233
14233
  mapping: {}
14234
14234
  };
14235
14235
  }
14236
- }, n8 = class extends Pa {
14236
+ }, nz = class extends Pa {
14237
14237
  constructor() {
14238
- super("position"), this.register("identity", new t8()), this.register("stack", new r8()), this.register("fill", new e8()), this.register("dodge", new Zj());
14238
+ super("position"), this.register("identity", new tz()), this.register("stack", new rz()), this.register("fill", new ez()), this.register("dodge", new Zj());
14239
14239
  }
14240
- }, i8 = class {
14240
+ }, iz = class {
14241
14241
  map({ data: e, layer: t, getPositionScale: r }) {
14242
14242
  if (t.position !== "dodge" || !G(r("x")?.bandwidth) || !e.hasVariable(O.xMin) || !e.hasVariable(O.xMax)) return e;
14243
14243
  const n = e.getValues(O.x, { type: "numeric" }), i = e.getValues(O.xMin, { type: "numeric" }), o = e.getValues(O.xMax, { type: "numeric" }), a = n.map((s, l) => {
@@ -14246,7 +14246,7 @@ var ax = (e, t) => e && t ? "solo" : e ? "base" : t ? "tip" : "middle", e8 = cla
14246
14246
  });
14247
14247
  return e.addVariable(O.xBand, "numeric", n).addVariable(O.x, "numeric", a);
14248
14248
  }
14249
- }, o8 = class {
14249
+ }, oz = class {
14250
14250
  map({ data: e, layer: t, getPositionScale: r, geomRegistry: n }) {
14251
14251
  let i = e;
14252
14252
  const o = n.get(t.geom);
@@ -14261,16 +14261,16 @@ var ax = (e, t) => e && t ? "solo" : e ? "base" : t ? "tip" : "middle", e8 = cla
14261
14261
  }
14262
14262
  return i;
14263
14263
  }
14264
- }, a8 = class {
14264
+ }, az = class {
14265
14265
  map({ data: e, layer: t, getPositionScale: r, geomRegistry: n }) {
14266
14266
  const i = X(t.mapping.x), o = r("x");
14267
14267
  if (!i || !o) return e;
14268
- if (ii(n.get(t.geom))) return s8(e, o);
14268
+ if (ii(n.get(t.geom))) return sz(e, o);
14269
14269
  const a = e.getValues(i).map((s) => G(s) ? o.map(s) : null);
14270
14270
  return e.addVariable(O.x, "numeric", a);
14271
14271
  }
14272
14272
  };
14273
- function s8(e, t) {
14273
+ function sz(e, t) {
14274
14274
  if (!e.hasVariable(O.xMin) || !e.hasVariable(O.xMax)) return e;
14275
14275
  const r = e.getValues(O.xMin, { type: "numeric" }), n = e.getValues(O.xMax, { type: "numeric" }), i = r.map((o, a) => {
14276
14276
  const s = n[a];
@@ -14278,15 +14278,15 @@ function s8(e, t) {
14278
14278
  });
14279
14279
  return e.addVariable(O.x, "numeric", i);
14280
14280
  }
14281
- var l8 = class {
14281
+ var lz = class {
14282
14282
  map({ data: e, getPositionScale: t }) {
14283
14283
  const r = t("x");
14284
14284
  if (!r || !e.hasVariable(O.xMin) || !e.hasVariable(O.xMax)) return e;
14285
- const n = r.bandwidth, i = G(n) && e.hasVariable(O.x) ? c8(e, r, n) : u8(e, r), o = e.addVariable(O.xMin, "numeric", i.min).addVariable(O.xMax, "numeric", i.max);
14285
+ const n = r.bandwidth, i = G(n) && e.hasVariable(O.x) ? cz(e, r, n) : uz(e, r), o = e.addVariable(O.xMin, "numeric", i.min).addVariable(O.xMax, "numeric", i.max);
14286
14286
  return i.tip === null ? o : o.addVariable(O.xTip, "numeric", i.tip);
14287
14287
  }
14288
14288
  };
14289
- function c8(e, t, r) {
14289
+ function cz(e, t, r) {
14290
14290
  const n = e.getValues(O.x, { type: "numeric" }), i = e.getValues(O.xMin, { type: "numeric" }), o = e.getValues(O.xMax, { type: "numeric" }), a = wk(e), s = "reverse" in t.spec && t.spec.reverse === !0, l = e.size(), c = Sk(l, a !== null);
14291
14291
  for (let u = 0; u < l; u++) {
14292
14292
  const d = n[u], h = i[u], f = o[u];
@@ -14297,7 +14297,7 @@ function c8(e, t, r) {
14297
14297
  }
14298
14298
  return c;
14299
14299
  }
14300
- function u8(e, t) {
14300
+ function uz(e, t) {
14301
14301
  const r = e.getValues(O.xMin, { type: "numeric" }), n = e.getValues(O.xMax, { type: "numeric" }), i = wk(e), o = e.size(), a = Sk(o, i !== null);
14302
14302
  for (let s = 0; s < o; s++) {
14303
14303
  const l = r[s], c = n[s];
@@ -14319,22 +14319,22 @@ function Sk(e, t) {
14319
14319
  tip: t ? new Array(e).fill(null) : null
14320
14320
  };
14321
14321
  }
14322
- var d8 = class {
14322
+ var dz = class {
14323
14323
  map({ data: e, layer: t, getPositionScale: r }) {
14324
14324
  const n = X(t.mapping.y), i = r(oi(t.yScaleType));
14325
14325
  if (!n || !i) return e;
14326
14326
  const o = e.getValues(n).map((a) => G(a) ? i.map(a) : null);
14327
14327
  return e.addVariable(O.y, "numeric", o);
14328
14328
  }
14329
- }, h8 = class {
14329
+ }, hz = class {
14330
14330
  map({ data: e, layer: t, getPositionScale: r }) {
14331
14331
  const n = r(oi(t.yScaleType));
14332
14332
  if (!n || !e.hasVariable(O.yMin) || !e.hasVariable(O.yMax)) return e;
14333
- const i = n.bandwidth, o = G(i) && e.hasVariable(O.y) ? f8(e, n, i) : p8(e, n), a = e.addVariable(O.yMin, "numeric", o.min).addVariable(O.yMax, "numeric", o.max);
14333
+ const i = n.bandwidth, o = G(i) && e.hasVariable(O.y) ? fz(e, n, i) : pz(e, n), a = e.addVariable(O.yMin, "numeric", o.min).addVariable(O.yMax, "numeric", o.max);
14334
14334
  return o.tip === null ? a : a.addVariable(O.yTip, "numeric", o.tip);
14335
14335
  }
14336
14336
  };
14337
- function f8(e, t, r) {
14337
+ function fz(e, t, r) {
14338
14338
  const n = e.getValues(O.y, { type: "numeric" }), i = e.getValues(O.yMin, { type: "numeric" }), o = e.getValues(O.yMax, { type: "numeric" }), a = Ak(e), s = "reverse" in t.spec && t.spec.reverse === !0, l = e.size(), c = Tk(l, a !== null);
14339
14339
  for (let u = 0; u < l; u++) {
14340
14340
  const d = n[u], h = i[u], f = o[u];
@@ -14345,7 +14345,7 @@ function f8(e, t, r) {
14345
14345
  }
14346
14346
  return c;
14347
14347
  }
14348
- function p8(e, t) {
14348
+ function pz(e, t) {
14349
14349
  const r = e.getValues(O.yMin, { type: "numeric" }), n = e.getValues(O.yMax, { type: "numeric" }), i = Ak(e), o = e.size(), a = Tk(o, i !== null);
14350
14350
  for (let s = 0; s < o; s++) {
14351
14351
  const l = r[s], c = n[s];
@@ -14367,20 +14367,20 @@ function Tk(e, t) {
14367
14367
  tip: t ? new Array(e).fill(null) : null
14368
14368
  };
14369
14369
  }
14370
- var m8 = [
14371
- new a8(),
14372
- new d8(),
14373
- new l8(),
14374
- new h8(),
14375
- new i8(),
14376
- new o8()
14370
+ var mz = [
14371
+ new az(),
14372
+ new dz(),
14373
+ new lz(),
14374
+ new hz(),
14375
+ new iz(),
14376
+ new oz()
14377
14377
  ];
14378
- function g8(e, t) {
14378
+ function gz(e, t) {
14379
14379
  const r = e[t];
14380
14380
  return r?.kind === "position" ? r : null;
14381
14381
  }
14382
- var v8 = class extends po {
14383
- constructor(e, t = m8) {
14382
+ var vz = class extends po {
14383
+ constructor(e, t = mz) {
14384
14384
  super(), this.container = e, this.mappers = t;
14385
14385
  }
14386
14386
  dependencies(e) {
@@ -14391,7 +14391,7 @@ var v8 = class extends po {
14391
14391
  ];
14392
14392
  }
14393
14393
  compileLayer(e, t) {
14394
- const r = (i) => g8(t.scales, i);
14394
+ const r = (i) => gz(t.scales, i);
14395
14395
  let n = e.data;
14396
14396
  for (const i of this.mappers) n = i.map({
14397
14397
  data: n,
@@ -14402,11 +14402,11 @@ var v8 = class extends po {
14402
14402
  return {
14403
14403
  ...e,
14404
14404
  data: n,
14405
- yZero: y8(r(oi(e.yScaleType)))
14405
+ yZero: yz(r(oi(e.yScaleType)))
14406
14406
  };
14407
14407
  }
14408
14408
  };
14409
- function y8(e) {
14409
+ function yz(e) {
14410
14410
  if (e === null || G(e.bandwidth)) return null;
14411
14411
  const t = e.map(0);
14412
14412
  return Number.isFinite(t) ? t : null;
@@ -14414,9 +14414,9 @@ function y8(e) {
14414
14414
  var sx = (e) => {
14415
14415
  const t = e.find((n) => n.scaledAesthetic === "color"), r = t?.scaleType === "discrete" ? t.range?.[0] : void 0;
14416
14416
  return typeof r == "string" ? r : void 0;
14417
- }, b8 = (e, t) => (ib[e][t] ?? ib[e].default).map((r) => ep[r]), x8 = (e, t) => {
14417
+ }, bz = (e, t) => (ib[e][t] ?? ib[e].default).map((r) => ep[r]), xz = (e, t) => {
14418
14418
  const r = e.palettes?.categorical;
14419
- return r !== void 0 && r.length > 0 ? r : e.hasTouchingGeoms ? b8(e.colorScheme, t) : aE;
14419
+ return r !== void 0 && r.length > 0 ? r : e.hasTouchingGeoms ? bz(e.colorScheme, t) : aE;
14420
14420
  }, $n = {
14421
14421
  transform: "linear",
14422
14422
  reverse: !1,
@@ -14441,20 +14441,20 @@ var sx = (e) => {
14441
14441
  domain: null,
14442
14442
  padding: 0.1,
14443
14443
  reverse: !1
14444
- }, w8 = {
14444
+ }, wz = {
14445
14445
  rgb: lp,
14446
14446
  lab: mU,
14447
14447
  hcl: gU,
14448
14448
  hsl: pU
14449
14449
  };
14450
14450
  function cx(e) {
14451
- const t = S8(e);
14451
+ const t = Sz(e);
14452
14452
  return e.reverse ? (r) => t(1 - r) : t;
14453
14453
  }
14454
- var wg = ({ diverging: e = !1, palettes: t, range: r }) => ux(r) ?? ux(e ? t?.diverging : t?.sequential) ?? (e ? f4 : h4), S8 = (e) => {
14455
- const t = wg(e), r = w8[e.interpolate ?? $n.interpolate];
14454
+ var wg = ({ diverging: e = !1, palettes: t, range: r }) => ux(r) ?? ux(e ? t?.diverging : t?.sequential) ?? (e ? f4 : h4), Sz = (e) => {
14455
+ const t = wg(e), r = wz[e.interpolate ?? $n.interpolate];
14456
14456
  return vU(r, t.map(String));
14457
- }, ux = (e) => e != null && e.length >= 2 ? e : void 0, A8 = class extends hi {
14457
+ }, ux = (e) => e != null && e.length >= 2 ? e : void 0, Az = class extends hi {
14458
14458
  constructor(e, t) {
14459
14459
  super(), this.container = e, this.registry = t;
14460
14460
  }
@@ -14616,7 +14616,7 @@ var wg = ({ diverging: e = !1, palettes: t, range: r }) => ux(r) ?? ux(e ? t?.di
14616
14616
  pinnedHigh: r !== null
14617
14617
  };
14618
14618
  };
14619
- function T8(e) {
14619
+ function Tz(e) {
14620
14620
  const [t, r] = e.domain;
14621
14621
  return t > 0 ? {
14622
14622
  ...e,
@@ -14631,7 +14631,7 @@ function T8(e) {
14631
14631
  function hp(e, t) {
14632
14632
  return [t.pinnedLow ? t.domain[0] : e[0], t.pinnedHigh ? t.domain[1] : e[1]];
14633
14633
  }
14634
- var M8 = class extends Id {
14634
+ var Mz = class extends Id {
14635
14635
  constructor(e) {
14636
14636
  super(), this.container = e, this.compatibleDataTypes = ["numeric"];
14637
14637
  }
@@ -14647,10 +14647,10 @@ var M8 = class extends Id {
14647
14647
  return t === 1 / 0 ? [0, 0] : [t, r];
14648
14648
  }
14649
14649
  createD3Scale(e, t, r, n = !1) {
14650
- const i = dp(e, r.domainMin, r.domainMax), o = n ? T8(i) : i;
14650
+ const i = dp(e, r.domainMin, r.domainMax), o = n ? Tz(i) : i;
14651
14651
  let a = o.domain;
14652
- n && E8(i, o) && this.warnIncompatibleDomain(r, i.domain, `'${r.scaledAesthetic}' holds zero for the geom drawn on it, so the pin at [${i.domain[0]}, ${i.domain[1]}] gives way to [${a[0]}, ${a[1]}].`, `Pin '${r.scaledAesthetic}' at or past zero, or drop the pin.`);
14653
- const s = r.transform === "log" && k8(a);
14652
+ n && Ez(i, o) && this.warnIncompatibleDomain(r, i.domain, `'${r.scaledAesthetic}' holds zero for the geom drawn on it, so the pin at [${i.domain[0]}, ${i.domain[1]}] gives way to [${a[0]}, ${a[1]}].`, `Pin '${r.scaledAesthetic}' at or past zero, or drop the pin.`);
14653
+ const s = r.transform === "log" && kz(a);
14654
14654
  r.transform === "log" && !s && this.warnIncompatibleDomain(r, a, `Log scale on '${r.scaledAesthetic}' needs a strictly positive or negative domain, but the domain is [${a[0]}, ${a[1]}] — rendering a linear scale instead.`, n ? `'${r.scaledAesthetic}' holds zero for the geom drawn on it; use a linear or sqrt transform.` : "Filter out non-positive values or set a positive domainMin so the log scale can apply.");
14655
14655
  const l = s ? ck() : r.transform === "sqrt" ? UU() : Wc();
14656
14656
  return r.nice && !s && (a = hp(l.copy().domain(a).nice().domain(), o)), l.domain(a).range(t).clamp(r.clamp);
@@ -14677,7 +14677,7 @@ var M8 = class extends Id {
14677
14677
  });
14678
14678
  }
14679
14679
  buildVisualScale(e, t) {
14680
- const r = P8(t.range) ?? [0, 1], n = t.reverse ? [r[1], r[0]] : r, i = this.createD3Scale(e, n, t);
14680
+ const r = Pz(t.range) ?? [0, 1], n = t.reverse ? [r[1], r[0]] : r, i = this.createD3Scale(e, n, t);
14681
14681
  return this.createVisualScale(t, {
14682
14682
  map: i,
14683
14683
  domain: i.domain(),
@@ -14756,16 +14756,16 @@ var M8 = class extends Id {
14756
14756
  colormapStops: wg(e).map(String),
14757
14757
  ...t === void 0 || t.length === 0 ? {} : { palette: t }
14758
14758
  };
14759
- }, E8 = (e, t) => e.pinnedLow && e.domain[0] !== t.domain[0] || e.pinnedHigh && e.domain[1] !== t.domain[1], k8 = (e) => {
14759
+ }, Ez = (e, t) => e.pinnedLow && e.domain[0] !== t.domain[0] || e.pinnedHigh && e.domain[1] !== t.domain[1], kz = (e) => {
14760
14760
  const [t, r] = e;
14761
14761
  return t > 0 && r > 0 || t < 0 && r < 0;
14762
14762
  };
14763
- function P8(e) {
14763
+ function Pz(e) {
14764
14764
  if (!e) return null;
14765
14765
  const [t, r] = e;
14766
14766
  return typeof t == "number" && typeof r == "number" ? [t, r] : null;
14767
14767
  }
14768
- var C8 = class extends Id {
14768
+ var Cz = class extends Id {
14769
14769
  constructor(...e) {
14770
14770
  super(...e), this.compatibleDataTypes = ["temporal"];
14771
14771
  }
@@ -14800,7 +14800,7 @@ var C8 = class extends Id {
14800
14800
  }
14801
14801
  createD3Scale(e, t, r) {
14802
14802
  const n = Qj().range(t).clamp(r.clamp);
14803
- if (!_8(e)) return n.domain([]);
14803
+ if (!_z(e)) return n.domain([]);
14804
14804
  const i = dp([e[0].getTime(), e[1].getTime()], r.domainMin, r.domainMax);
14805
14805
  if (n.domain(i.domain), r.nice) {
14806
14806
  const [o, a] = n.nice().domain();
@@ -14817,7 +14817,7 @@ var C8 = class extends Id {
14817
14817
  generateTicks: (l) => l && "atInputs" in l ? s : l && "interval" in l ? o && a ? $G(o, a, l.interval) : [] : i.ticks(l?.count)
14818
14818
  });
14819
14819
  }
14820
- }, _8 = (e) => e.length === 2 && Dt(e[0]) && Dt(e[1]), I8 = class extends Id {
14820
+ }, _z = (e) => e.length === 2 && Dt(e[0]) && Dt(e[1]), Iz = class extends Id {
14821
14821
  constructor(...e) {
14822
14822
  super(...e), this.compatibleDataTypes = [
14823
14823
  "categorical",
@@ -14829,7 +14829,7 @@ var C8 = class extends Id {
14829
14829
  if (e.scaleType !== "discrete") throw new he({ message: "DiscreteScale.compile received non-discrete spec" });
14830
14830
  const n = hd(e.scaledAesthetic), i = $M(t, e);
14831
14831
  if (n) return this.buildPositionScale(i, e);
14832
- const o = e.scaledAesthetic === "color" ? x8(r, i.length) : void 0;
14832
+ const o = e.scaledAesthetic === "color" ? xz(r, i.length) : void 0;
14833
14833
  return this.buildVisualScale(i, e, o);
14834
14834
  }
14835
14835
  buildPositionScale(e, t) {
@@ -14842,7 +14842,7 @@ var C8 = class extends Id {
14842
14842
  });
14843
14843
  }
14844
14844
  buildVisualScale(e, t, r) {
14845
- const n = e.map(String), i = t.range && t.range.length > 0 ? t.range : r, o = i && i.length > 0 ? gg().domain(n).range(i).unknown(i[0]) : null, a = R8(t.scaledAesthetic, i);
14845
+ const n = e.map(String), i = t.range && t.range.length > 0 ? t.range : r, o = i && i.length > 0 ? gg().domain(n).range(i).unknown(i[0]) : null, a = Rz(t.scaledAesthetic, i);
14846
14846
  return this.createVisualScale(t, {
14847
14847
  map: (s) => {
14848
14848
  const l = String(s);
@@ -14854,7 +14854,7 @@ var C8 = class extends Id {
14854
14854
  ...r === void 0 ? {} : { defaultPalette: r }
14855
14855
  });
14856
14856
  }
14857
- }, R8 = (e, t) => {
14857
+ }, Rz = (e, t) => {
14858
14858
  if (e !== "color" || t === void 0 || t.length === 0) return;
14859
14859
  const r = [];
14860
14860
  for (const n of t) {
@@ -14862,7 +14862,7 @@ var C8 = class extends Id {
14862
14862
  r.push(n);
14863
14863
  }
14864
14864
  return r;
14865
- }, L8 = class extends Id {
14865
+ }, Lz = class extends Id {
14866
14866
  constructor(...e) {
14867
14867
  super(...e), this.compatibleDataTypes = [
14868
14868
  "numeric",
@@ -14881,9 +14881,9 @@ var C8 = class extends Id {
14881
14881
  generateTicks: () => []
14882
14882
  };
14883
14883
  }
14884
- }, D8 = class extends Pa {
14884
+ }, Dz = class extends Pa {
14885
14885
  constructor(e) {
14886
- super("scale"), this.register("continuous", new M8(e)), this.register("discrete", new I8()), this.register("datetime", new C8()), this.register("identity", new L8());
14886
+ super("scale"), this.register("continuous", new Mz(e)), this.register("discrete", new Iz()), this.register("datetime", new Cz()), this.register("identity", new Lz());
14887
14887
  }
14888
14888
  };
14889
14889
  function ft(e, t = {}) {
@@ -14951,7 +14951,7 @@ var Mk = {
14951
14951
  alpha: "continuous-range",
14952
14952
  strokeWidth: "continuous-range",
14953
14953
  lineType: "discrete-only"
14954
- }, O8 = {
14954
+ }, Oz = {
14955
14955
  numeric: {
14956
14956
  position: "continuous",
14957
14957
  "color-range": "continuous",
@@ -14985,7 +14985,7 @@ function Sg(e, t) {
14985
14985
  switch (t.scaleType) {
14986
14986
  case "inferred":
14987
14987
  return {
14988
- ...Sg(e, G8(e, t)),
14988
+ ...Sg(e, Gz(e, t)),
14989
14989
  inferredFrom: t
14990
14990
  };
14991
14991
  case "continuous": {
@@ -15018,7 +15018,7 @@ function Sg(e, t) {
15018
15018
  clamp: t.clamp ?? !1
15019
15019
  };
15020
15020
  case "discrete":
15021
- return B8(t, e.demands);
15021
+ return Bz(t, e.demands);
15022
15022
  case "identity":
15023
15023
  return {
15024
15024
  type: t.type,
@@ -15029,16 +15029,16 @@ function Sg(e, t) {
15029
15029
  throw new he({ message: `Unknown scale type: ${t.scaleType}` });
15030
15030
  }
15031
15031
  }
15032
- function N8(e, t) {
15033
- const { scales: r, layers: n, mapping: i, coords: o } = t, a = Ek(e, t), s = z8(j8(W8(e, r, n, i), n), a.demands), l = /* @__PURE__ */ new Map();
15032
+ function Nz(e, t) {
15033
+ const { scales: r, layers: n, mapping: i, coords: o } = t, a = Ek(e, t), s = zz(jz(Wz(e, r, n, i), n), a.demands), l = /* @__PURE__ */ new Map();
15034
15034
  for (const u of s) l.set(u.scaledAesthetic, u);
15035
15035
  const c = [...l.values()].map((u) => {
15036
- const d = V8(a, F8(a, u));
15036
+ const d = Vz(a, Fz(a, u));
15037
15037
  return Sg(a, d);
15038
15038
  });
15039
15039
  return o.coordType === "polar" ? c.map(kk) : c;
15040
15040
  }
15041
- function B8(e, t) {
15041
+ function Bz(e, t) {
15042
15042
  const r = t?.bandPadding[e.scaledAesthetic];
15043
15043
  return {
15044
15044
  type: e.type,
@@ -15047,14 +15047,14 @@ function B8(e, t) {
15047
15047
  range: e.range ?? Ps.range,
15048
15048
  domain: e.domain ?? Ps.domain,
15049
15049
  padding: e.padding ?? r ?? Ps.padding,
15050
- reverse: e.reverse ?? H8(e.scaledAesthetic, t)
15050
+ reverse: e.reverse ?? Hz(e.scaledAesthetic, t)
15051
15051
  };
15052
15052
  }
15053
15053
  var kk = (e) => e.scaleType === "discrete" ? {
15054
15054
  ...e,
15055
15055
  padding: 0
15056
15056
  } : e;
15057
- function F8(e, t) {
15057
+ function Fz(e, t) {
15058
15058
  return t.scaleType === "inferred" || t.scaleType === "discrete" || !e.demands.bandedAxes.includes(t.scaledAesthetic) ? t : (e.container.diagnostics.addWarning({
15059
15059
  code: "UNSUPPORTED_SCALE_TYPE",
15060
15060
  message: `A geom drawn on '${t.scaledAesthetic}' needs it to be a band scale, but the spec declares a '${t.scaleType}' one; the band wins.`,
@@ -15065,7 +15065,7 @@ function F8(e, t) {
15065
15065
  suggestion: `Declare '${t.scaledAesthetic}' as a discrete scale, or omit it and let the geom's band be inferred.`
15066
15066
  }), Kt(t.scaledAesthetic, { ..."reverse" in t && t.reverse !== void 0 && { reverse: t.reverse } }));
15067
15067
  }
15068
- function V8(e, t) {
15068
+ function Vz(e, t) {
15069
15069
  return t.scaleType === "inferred" || t.scaledAesthetic !== e.demands.categorySpanAxis ? t : t.scaleType === "continuous" ? {
15070
15070
  ...t,
15071
15071
  nice: t.nice ?? !1
@@ -15082,11 +15082,11 @@ function V8(e, t) {
15082
15082
  ..."reverse" in t && t.reverse !== void 0 && { reverse: t.reverse }
15083
15083
  }));
15084
15084
  }
15085
- function H8(e, t) {
15085
+ function Hz(e, t) {
15086
15086
  return e === t?.discreteCrossAxis ? !0 : Ps.reverse;
15087
15087
  }
15088
- function G8({ data: e, layers: t, mapping: r, demands: n }, i) {
15089
- const o = $8(t, r, i.scaledAesthetic);
15088
+ function Gz({ data: e, layers: t, mapping: r, demands: n }, i) {
15089
+ const o = $z(t, r, i.scaledAesthetic);
15090
15090
  if (i.scaledAesthetic === n.categorySpanAxis) {
15091
15091
  const u = i.options;
15092
15092
  return ft(i.scaledAesthetic, {
@@ -15106,7 +15106,7 @@ function G8({ data: e, layers: t, mapping: r, demands: n }, i) {
15106
15106
  const s = X(o);
15107
15107
  if (!G(s) || !e.hasVariable(s) || e.size() === 0) return ft(i.scaledAesthetic, i.options);
15108
15108
  const l = e.getType(s), c = Mk[i.scaledAesthetic];
15109
- switch (O8[l][c]) {
15109
+ switch (Oz[l][c]) {
15110
15110
  case "discrete":
15111
15111
  return Kt(i.scaledAesthetic, i.options);
15112
15112
  case "datetime":
@@ -15117,7 +15117,7 @@ function G8({ data: e, layers: t, mapping: r, demands: n }, i) {
15117
15117
  return ms(i.scaledAesthetic);
15118
15118
  }
15119
15119
  }
15120
- function $8(e, t, r) {
15120
+ function $z(e, t, r) {
15121
15121
  const n = We(r);
15122
15122
  for (const i of Pk(r, e)) {
15123
15123
  const o = i.mapping[n] ?? t[n];
@@ -15128,17 +15128,17 @@ function $8(e, t, r) {
15128
15128
  function Pk(e, t) {
15129
15129
  return e === "ySecondary" ? t.filter((r) => r.yScaleType === "secondary") : e === "y" ? t.filter((r) => r.yScaleType === "primary") : t;
15130
15130
  }
15131
- function W8(e, t, r, n) {
15132
- const i = ["x", "y"].filter((o) => !t.some((a) => a.scaledAesthetic === o) && Pk(o, r).some((a) => U8(e, a, o, n)));
15131
+ function Wz(e, t, r, n) {
15132
+ const i = ["x", "y"].filter((o) => !t.some((a) => a.scaledAesthetic === o) && Pk(o, r).some((a) => Uz(e, a, o, n)));
15133
15133
  return [...t, ...i.map((o) => ta(o))];
15134
15134
  }
15135
- function U8(e, t, r, n) {
15135
+ function Uz(e, t, r, n) {
15136
15136
  return e.statRegistry.get(t.stat.type).resolveComputedAesthetics(t.stat, { ...t.params }).has(r) ? !0 : [r, ...e.geomRegistry.get(t.geom).positionRoles.filter((i) => i.axis === r).map((i) => i.aesthetic ?? r)].some((i) => !!X(t.mapping[i] ?? n[i]));
15137
15137
  }
15138
- function j8(e, t) {
15138
+ function jz(e, t) {
15139
15139
  return !t.some((r) => r.yScaleType === "secondary") || e.some((r) => r.scaledAesthetic === "ySecondary") ? e : [...e, ta("ySecondary")];
15140
15140
  }
15141
- function z8(e, t) {
15141
+ function zz(e, t) {
15142
15142
  return e.some((r) => r.scaledAesthetic === "color") ? e : [...e, t.inferColorScale ? ta("color") : Kt("color")];
15143
15143
  }
15144
15144
  var Ck = class extends hi {
@@ -15154,30 +15154,30 @@ var Ck = class extends hi {
15154
15154
  run(e) {
15155
15155
  return e.transforms.reduce((t, r) => this.registry.get(r.transformType).apply(t, r), e.data);
15156
15156
  }
15157
- }, _k = new FE(), Y8 = new Ck(_k), K8 = (e, t) => {
15157
+ }, _k = new FE(), Yz = new Ck(_k), Kz = (e, t) => {
15158
15158
  const r = t.every((n) => _k.has(n.transformType));
15159
- return t.length === 0 || !r ? e : Y8.compile({
15159
+ return t.length === 0 || !r ? e : Yz.compile({
15160
15160
  data: e,
15161
15161
  transforms: t
15162
15162
  });
15163
- }, X8 = { labelCrossPosition: 0.5 }, hx = {
15163
+ }, Xz = { labelCrossPosition: 0.5 }, hx = {
15164
15164
  kind: "rectangle",
15165
15165
  zOrder: "foreground"
15166
15166
  }, fx = {
15167
15167
  zOrder: "foreground",
15168
15168
  fit: "contain"
15169
- }, q8 = {
15169
+ }, qz = {
15170
15170
  x: 8,
15171
15171
  y: 8,
15172
15172
  unit: "px"
15173
- }, Q8 = { align: "center" }, px = {
15173
+ }, Qz = { align: "center" }, px = {
15174
15174
  startArrowheadStyle: "none",
15175
15175
  endArrowheadStyle: "lineArrow"
15176
15176
  }, mx = 0;
15177
15177
  function Lr() {
15178
15178
  return mx += 1, `${Math.random().toString(36).slice(2, 6)}${mx.toString(36)}`;
15179
15179
  }
15180
- var Z8 = {
15180
+ var Zz = {
15181
15181
  top: {
15182
15182
  x: 0,
15183
15183
  y: -1
@@ -15210,21 +15210,21 @@ var Z8 = {
15210
15210
  x: 1,
15211
15211
  y: 1
15212
15212
  }
15213
- }, J8 = (e, t, r) => {
15214
- const n = ez(e, t), i = nz(n);
15213
+ }, Jz = (e, t, r) => {
15214
+ const n = e8(e, t), i = n8(n);
15215
15215
  return {
15216
- differenceArrows: (n.differenceArrows ?? []).map((o) => oz(e, o, r)).filter(G),
15217
- shapes: (n.shapes ?? []).map((o) => cz(e, o, i)).filter(G),
15218
- arrows: (n.arrows ?? []).map((o) => hz(e, o, r, i)).filter(G),
15219
- textAnnotations: (n.textAnnotations ?? []).map((o) => iz(e, o, r, i)).filter(G),
15220
- stickers: (n.stickers ?? []).map((o) => az(e, o, r, i)).filter(G),
15221
- images: (n.images ?? []).map((o) => uz(e, o, i)).filter(G),
15222
- pinnedNumbers: (n.pinnedNumbers ?? []).map((o) => sz(e, o, r)).filter(G),
15223
- comments: (n.comments ?? []).map((o) => lz(e, o, r)).filter(G)
15216
+ differenceArrows: (n.differenceArrows ?? []).map((o) => o8(e, o, r)).filter(G),
15217
+ shapes: (n.shapes ?? []).map((o) => c8(e, o, i)).filter(G),
15218
+ arrows: (n.arrows ?? []).map((o) => h8(e, o, r, i)).filter(G),
15219
+ textAnnotations: (n.textAnnotations ?? []).map((o) => i8(e, o, r, i)).filter(G),
15220
+ stickers: (n.stickers ?? []).map((o) => a8(e, o, r, i)).filter(G),
15221
+ images: (n.images ?? []).map((o) => u8(e, o, i)).filter(G),
15222
+ pinnedNumbers: (n.pinnedNumbers ?? []).map((o) => s8(e, o, r)).filter(G),
15223
+ comments: (n.comments ?? []).map((o) => l8(e, o, r)).filter(G)
15224
15224
  };
15225
- }, ez = (e, t) => {
15225
+ }, e8 = (e, t) => {
15226
15226
  if (t === void 0) return {};
15227
- if (!tz(t)) return t;
15227
+ if (!t8(t)) return t;
15228
15228
  const r = /* @__PURE__ */ new Set(), n = (i) => i.id === void 0 ? i : r.has(i.id) ? (e.diagnostics.addWarning({
15229
15229
  code: "ANNOTATION_DUPLICATE_ID",
15230
15230
  message: `More than one annotation declares id "${i.id}" — giving this one a generated id, so references to "${i.id}" point at the first.`,
@@ -15244,15 +15244,15 @@ var Z8 = {
15244
15244
  pinnedNumbers: t.pinnedNumbers?.map((i) => n(i)),
15245
15245
  comments: t.comments?.map((i) => n(i))
15246
15246
  };
15247
- }, tz = (e) => {
15247
+ }, t8 = (e) => {
15248
15248
  const t = /* @__PURE__ */ new Set();
15249
- for (const r of rz(e))
15249
+ for (const r of r8(e))
15250
15250
  if (r.id !== void 0) {
15251
15251
  if (t.has(r.id)) return !0;
15252
15252
  t.add(r.id);
15253
15253
  }
15254
15254
  return !1;
15255
- }, rz = (e) => [
15255
+ }, r8 = (e) => [
15256
15256
  ...e.differenceArrows ?? [],
15257
15257
  ...e.shapes ?? [],
15258
15258
  ...e.arrows ?? [],
@@ -15261,7 +15261,7 @@ var Z8 = {
15261
15261
  ...e.stickers ?? [],
15262
15262
  ...e.pinnedNumbers ?? [],
15263
15263
  ...e.comments ?? []
15264
- ], nz = (e) => {
15264
+ ], n8 = (e) => {
15265
15265
  const t = /* @__PURE__ */ new Set(), r = [
15266
15266
  e.differenceArrows,
15267
15267
  e.shapes,
@@ -15286,23 +15286,23 @@ var Z8 = {
15286
15286
  },
15287
15287
  suggestion: "Reference the explicit id of another annotation in the same spec, or set an id on the target."
15288
15288
  }), !1;
15289
- }, iz = (e, t, r, n) => {
15289
+ }, i8 = (e, t, r, n) => {
15290
15290
  const i = wu(e, t.at, r, n, t.id);
15291
15291
  return i === null ? null : {
15292
15292
  id: t.id ?? Lr(),
15293
15293
  content: t.content,
15294
15294
  at: i,
15295
15295
  width: t.width,
15296
- align: t.align ?? Q8.align
15296
+ align: t.align ?? Qz.align
15297
15297
  };
15298
- }, oz = (e, t, r) => {
15298
+ }, o8 = (e, t, r) => {
15299
15299
  const n = rl(e, t.start, r), i = rl(e, t.end, r);
15300
15300
  return n === null || i === null ? null : {
15301
15301
  id: t.id ?? Lr(),
15302
15302
  start: n,
15303
15303
  end: i,
15304
15304
  label: t.label,
15305
- labelCrossPosition: t.labelCrossPosition ?? X8.labelCrossPosition
15305
+ labelCrossPosition: t.labelCrossPosition ?? Xz.labelCrossPosition
15306
15306
  };
15307
15307
  }, rl = (e, t, r) => {
15308
15308
  const n = t.align !== void 0 ? { align: t.align } : {};
@@ -15335,43 +15335,43 @@ var Z8 = {
15335
15335
  ...o,
15336
15336
  ...t.offset !== void 0 ? { offset: t.offset } : {}
15337
15337
  };
15338
- }, az = (e, t, r, n) => {
15338
+ }, a8 = (e, t, r, n) => {
15339
15339
  const i = wu(e, t.at, r, n, t.id);
15340
15340
  return i === null ? null : {
15341
15341
  id: t.id ?? Lr(),
15342
15342
  at: i,
15343
15343
  sticker: t.sticker
15344
15344
  };
15345
- }, sz = (e, t, r) => {
15345
+ }, s8 = (e, t, r) => {
15346
15346
  const n = rl(e, t.at, r);
15347
15347
  return n === null ? null : {
15348
15348
  id: t.id ?? Lr(),
15349
15349
  at: n
15350
15350
  };
15351
- }, lz = (e, t, r) => {
15351
+ }, l8 = (e, t, r) => {
15352
15352
  const n = rl(e, t.at, r);
15353
15353
  return n === null ? null : {
15354
15354
  id: t.id ?? Lr(),
15355
15355
  at: n,
15356
15356
  content: t.content
15357
15357
  };
15358
- }, cz = (e, t, r) => t.region.anchorType === "annotation" && !Ag(e, t.region.ref, r, t.id) ? null : {
15358
+ }, c8 = (e, t, r) => t.region.anchorType === "annotation" && !Ag(e, t.region.ref, r, t.id) ? null : {
15359
15359
  id: t.id ?? Lr(),
15360
15360
  kind: t.kind ?? hx.kind,
15361
15361
  zOrder: t.zOrder ?? hx.zOrder,
15362
- region: dz(t.region)
15363
- }, uz = (e, t, r) => t.region.anchorType === "annotation" && !Ag(e, t.region.ref, r, t.id) ? null : {
15362
+ region: d8(t.region)
15363
+ }, u8 = (e, t, r) => t.region.anchorType === "annotation" && !Ag(e, t.region.ref, r, t.id) ? null : {
15364
15364
  id: t.id ?? Lr(),
15365
15365
  src: t.src,
15366
15366
  zOrder: t.zOrder ?? fx.zOrder,
15367
15367
  region: t.region,
15368
15368
  fit: t.fit ?? fx.fit
15369
- }, dz = (e) => e.anchorType !== "selection" || e.padding !== void 0 ? e : {
15369
+ }, d8 = (e) => e.anchorType !== "selection" || e.padding !== void 0 ? e : {
15370
15370
  ...e,
15371
- padding: q8
15371
+ padding: qz
15372
15372
  }, gx = (e) => {
15373
15373
  if (e.anchorType === "panel" || e.anchorType === "axis" || e.offset !== void 0 || e.align === void 0) return e;
15374
- const t = Z8[e.align];
15374
+ const t = Zz[e.align];
15375
15375
  return t === void 0 ? e : {
15376
15376
  ...e,
15377
15377
  offset: {
@@ -15380,7 +15380,7 @@ var Z8 = {
15380
15380
  unit: "px"
15381
15381
  }
15382
15382
  };
15383
- }, hz = (e, t, r, n) => {
15383
+ }, h8 = (e, t, r, n) => {
15384
15384
  const i = wu(e, t.start, r, n, t.id), o = wu(e, t.end, r, n, t.id);
15385
15385
  return i === null || o === null ? null : {
15386
15386
  id: t.id ?? Lr(),
@@ -15389,7 +15389,7 @@ var Z8 = {
15389
15389
  startArrowheadStyle: t.startArrowheadStyle ?? px.startArrowheadStyle,
15390
15390
  endArrowheadStyle: t.endArrowheadStyle ?? px.endArrowheadStyle
15391
15391
  };
15392
- }, fz = {
15392
+ }, f8 = {
15393
15393
  legend: {
15394
15394
  position: "auto",
15395
15395
  display: "auto",
@@ -15454,13 +15454,13 @@ var Z8 = {
15454
15454
  }
15455
15455
  }
15456
15456
  };
15457
- function pz(e, t, r) {
15457
+ function p8(e, t, r) {
15458
15458
  return {
15459
- ...uo({}, fz, t, e),
15459
+ ...uo({}, f8, t, e),
15460
15460
  parsingLocale: r
15461
15461
  };
15462
15462
  }
15463
- var mz = {
15463
+ var m8 = {
15464
15464
  xLimits: null,
15465
15465
  yLimits: null
15466
15466
  }, Kh = {
@@ -15468,11 +15468,11 @@ var mz = {
15468
15468
  startAngle: 0,
15469
15469
  innerRadius: 0
15470
15470
  };
15471
- function gz(e) {
15471
+ function g8(e) {
15472
15472
  const t = e ?? {
15473
15473
  type: "coord",
15474
15474
  coordType: "cartesian"
15475
- }, r = uo({}, mz, t.params ?? {});
15475
+ }, r = uo({}, m8, t.params ?? {});
15476
15476
  switch (t.coordType) {
15477
15477
  case "cartesian":
15478
15478
  case "flip":
@@ -15492,7 +15492,7 @@ function gz(e) {
15492
15492
  };
15493
15493
  }
15494
15494
  }
15495
- function vz(e, t, r) {
15495
+ function v8(e, t, r) {
15496
15496
  const n = [];
15497
15497
  for (const i of t) {
15498
15498
  if (i.layerId !== void 0 && !r.some((o) => o.id === i.layerId)) {
@@ -15517,7 +15517,7 @@ function vz(e, t, r) {
15517
15517
  }
15518
15518
  return n;
15519
15519
  }
15520
- var yz = class {
15520
+ var y8 = class {
15521
15521
  constructor() {
15522
15522
  this.diagnostics = [], this.persistent = [];
15523
15523
  }
@@ -15551,7 +15551,7 @@ var yz = class {
15551
15551
  warnings: r
15552
15552
  };
15553
15553
  }
15554
- }, bz = class {
15554
+ }, b8 = class {
15555
15555
  constructor(e, t) {
15556
15556
  this.sink = e, this.baseContext = t;
15557
15557
  }
@@ -15579,7 +15579,7 @@ function vx(e) {
15579
15579
  return t.has(n) ? !1 : (t.add(n), !0);
15580
15580
  });
15581
15581
  }
15582
- var xz = {
15582
+ var x8 = {
15583
15583
  showDataLabels: !1,
15584
15584
  format: "absolute",
15585
15585
  showStackTotals: !1,
@@ -15594,7 +15594,7 @@ var xz = {
15594
15594
  categoryAlign: "center",
15595
15595
  categoryOffset: 4
15596
15596
  };
15597
- function wz(e, t) {
15597
+ function w8(e, t) {
15598
15598
  const r = e ?? (typeof t == "string" ? t : t.type), n = typeof r == "string" ? r : r.type;
15599
15599
  if (n === "smooth") {
15600
15600
  const i = typeof r == "string" ? void 0 : r;
@@ -15617,15 +15617,15 @@ function wz(e, t) {
15617
15617
  }
15618
15618
  return { type: n };
15619
15619
  }
15620
- function Sz(e, t, r, n, i, o, a) {
15621
- const s = i !== void 0 && o !== void 0 ? new bz(i, { layerIndex: o }) : i, l = e.get(n.geom), c = n.position ?? l.defaultPosition, u = kz({
15622
- dataLabels: _z(e, t, n, c, r, a),
15620
+ function S8(e, t, r, n, i, o, a) {
15621
+ const s = i !== void 0 && o !== void 0 ? new b8(i, { layerIndex: o }) : i, l = e.get(n.geom), c = n.position ?? l.defaultPosition, u = k8({
15622
+ dataLabels: _8(e, t, n, c, r, a),
15623
15623
  geom: l,
15624
15624
  position: c,
15625
15625
  coordType: r,
15626
15626
  diagnostics: s
15627
15627
  });
15628
- return Ez({
15628
+ return E8({
15629
15629
  diagnostics: s,
15630
15630
  coordType: r,
15631
15631
  geom: l,
@@ -15636,7 +15636,7 @@ function Sz(e, t, r, n, i, o, a) {
15636
15636
  type: n.type,
15637
15637
  geom: n.geom,
15638
15638
  mapping: n.mapping ?? {},
15639
- stat: wz(n.stat, l.defaultStat ?? "identity"),
15639
+ stat: w8(n.stat, l.defaultStat ?? "identity"),
15640
15640
  position: c,
15641
15641
  yScaleType: n.yScaleType ?? "primary",
15642
15642
  params: l.resolveParams({
@@ -15650,16 +15650,16 @@ function Sz(e, t, r, n, i, o, a) {
15650
15650
  dataLabels: u
15651
15651
  };
15652
15652
  }
15653
- function Az(e, t, r, n, i, o) {
15654
- const a = n.map((s, l) => Sz(e, t, r, s, i, l, o));
15655
- return Mz(e, a);
15653
+ function A8(e, t, r, n, i, o) {
15654
+ const a = n.map((s, l) => S8(e, t, r, s, i, l, o));
15655
+ return M8(e, a);
15656
15656
  }
15657
- var Tz = (e, t, r, n) => n.label !== void 0 ? n.label : IM({
15657
+ var T8 = (e, t, r, n) => n.label !== void 0 ? n.label : IM({
15658
15658
  geom: e.get(t),
15659
15659
  position: r,
15660
15660
  mapping: n,
15661
15661
  purpose: "label"
15662
- }), Mz = (e, t) => {
15662
+ }), M8 = (e, t) => {
15663
15663
  const r = /* @__PURE__ */ new Set();
15664
15664
  for (const n of t) n.position === "fill" && r.add(n.yScaleType);
15665
15665
  return r.size === 0 ? t : cM(t, (n) => {
@@ -15675,7 +15675,7 @@ var Tz = (e, t, r, n) => n.label !== void 0 ? n.label : IM({
15675
15675
  }
15676
15676
  };
15677
15677
  });
15678
- }, Ez = ({ diagnostics: e, coordType: t, geom: r, position: n, dataLabels: i }) => {
15678
+ }, E8 = ({ diagnostics: e, coordType: t, geom: r, position: n, dataLabels: i }) => {
15679
15679
  if (e === void 0) return;
15680
15680
  const o = r.type === "bar" && t !== "polar";
15681
15681
  if (i.showDataLabels && !r.dataLabelCoordTypes.includes(t)) {
@@ -15699,10 +15699,10 @@ var Tz = (e, t, r, n) => n.label !== void 0 ? n.label : IM({
15699
15699
  message: "showStackTotals only applies to stacked cartesian bars; it will be ignored.",
15700
15700
  suggestion: "Turn off showStackTotals, or use a bar geom with position 'stack'."
15701
15701
  });
15702
- }, kz = ({ dataLabels: e, geom: t, position: r, coordType: n, diagnostics: i }) => {
15702
+ }, k8 = ({ dataLabels: e, geom: t, position: r, coordType: n, diagnostics: i }) => {
15703
15703
  const { justify: o, showDataLabels: a } = e;
15704
15704
  if (o !== "panelStart" && o !== "panelEnd") return e;
15705
- const s = Pz(t, r, n);
15705
+ const s = P8(t, r, n);
15706
15706
  if (s === null) return e;
15707
15707
  const l = o === "panelEnd" ? "end" : "start";
15708
15708
  return a && i?.addWarning({
@@ -15717,16 +15717,16 @@ var Tz = (e, t, r, n) => n.label !== void 0 ? n.label : IM({
15717
15717
  ...e,
15718
15718
  justify: l
15719
15719
  };
15720
- }, Pz = (e, t, r) => r === "polar" ? "Panel-edge anchors do not apply under polar coords" : e.type === "bar" && Wt(t) ? "Stacked bar segments would all pin their labels to the same panel edge" : null, Cz = (e, t) => {
15720
+ }, P8 = (e, t, r) => r === "polar" ? "Panel-edge anchors do not apply under polar coords" : e.type === "bar" && Wt(t) ? "Stacked bar segments would all pin their labels to the same panel edge" : null, C8 = (e, t) => {
15721
15721
  const r = X(e.color);
15722
15722
  return r === null || t?.hasVariable(r) !== !0 ? !1 : t.getType(r) === "categorical";
15723
- }, _z = (e, t, r, n, i, o) => {
15723
+ }, _8 = (e, t, r, n, i, o) => {
15724
15724
  const a = {
15725
15725
  ...t,
15726
15726
  ...r.mapping
15727
- }, s = Tz(e, r.geom, n, a), l = e.get(r.geom), c = Cz(a, o) ? l.categoryColorDataLabels : void 0;
15727
+ }, s = T8(e, r.geom, n, a), l = e.get(r.geom), c = C8(a, o) ? l.categoryColorDataLabels : void 0;
15728
15728
  return {
15729
- ...uo({}, xz, l.resolveDataLabelDefaults?.(n) ?? {}, l.dataLabels?.[i] ?? {}, c ?? {}, r.dataLabels ?? {}),
15729
+ ...uo({}, x8, l.resolveDataLabelDefaults?.(n) ?? {}, l.dataLabels?.[i] ?? {}, c ?? {}, r.dataLabels ?? {}),
15730
15730
  labelSource: s
15731
15731
  };
15732
15732
  }, Ik = (e) => {
@@ -15735,10 +15735,10 @@ var Tz = (e, t, r, n) => n.label !== void 0 ? n.label : IM({
15735
15735
  defaults: [],
15736
15736
  overrides: []
15737
15737
  };
15738
- for (const r of Iz(e))
15738
+ for (const r of I8(e))
15739
15739
  Object.assign(t.tokens, r.tokens), t.defaults.push(...r.defaults ?? []), t.overrides.push(...r.overrides ?? []);
15740
15740
  return t;
15741
- }, Iz = (e) => {
15741
+ }, I8 = (e) => {
15742
15742
  const t = [], r = /* @__PURE__ */ new Set(), n = e === void 0 ? [] : [e];
15743
15743
  for (; n.length > 0; ) {
15744
15744
  const i = n.pop();
@@ -15749,14 +15749,14 @@ var Tz = (e, t, r, n) => n.label !== void 0 ? n.label : IM({
15749
15749
  }
15750
15750
  return t.reverse();
15751
15751
  };
15752
- function Rz(e, t) {
15753
- const r = gz(t.coords), n = K8(t.data, t.transforms), i = Az(e.geomRegistry, t.mapping, r.coordType, t.layers, e.diagnostics, n), o = N8(e, {
15752
+ function R8(e, t) {
15753
+ const r = g8(t.coords), n = Kz(t.data, t.transforms), i = A8(e.geomRegistry, t.mapping, r.coordType, t.layers, e.diagnostics, n), o = Nz(e, {
15754
15754
  data: n,
15755
15755
  scales: t.scales,
15756
15756
  layers: i,
15757
15757
  mapping: t.mapping,
15758
15758
  coords: r
15759
- }), a = pz(t.config, e.theme?.config, t.data.parsingLocale), s = vz(e, t.highlights, i), l = J8(e, t.annotations, i), c = Ik(t.styles);
15759
+ }), a = p8(t.config, e.theme?.config, t.data.parsingLocale), s = v8(e, t.highlights, i), l = Jz(e, t.annotations, i), c = Ik(t.styles);
15760
15760
  return {
15761
15761
  data: t.data,
15762
15762
  mapping: t.mapping,
@@ -15770,18 +15770,18 @@ function Rz(e, t) {
15770
15770
  config: a
15771
15771
  };
15772
15772
  }
15773
- var Lz = class {
15773
+ var L8 = class {
15774
15774
  constructor(e) {
15775
15775
  this.container = e;
15776
15776
  }
15777
15777
  compile({ spec: e, dataset: t }) {
15778
- return Rz(this.container, {
15778
+ return R8(this.container, {
15779
15779
  ...e,
15780
15780
  data: t
15781
15781
  });
15782
15782
  }
15783
15783
  };
15784
- var Dz = class {
15784
+ var D8 = class {
15785
15785
  constructor(e) {
15786
15786
  this.registry = e;
15787
15787
  }
@@ -15793,16 +15793,16 @@ var Dz = class {
15793
15793
  hasDiscreteXScale: t.hasDiscreteXScale,
15794
15794
  params: t.params
15795
15795
  });
15796
- return Nz(r, r.resolveComputedAesthetics(e, t.params), n, t.requiredAesthetics), {
15796
+ return N8(r, r.resolveComputedAesthetics(e, t.params), n, t.requiredAesthetics), {
15797
15797
  data: n.data,
15798
15798
  mapping: {
15799
- ...Oz(t, n.data),
15799
+ ...O8(t, n.data),
15800
15800
  ...n.mapping
15801
15801
  }
15802
15802
  };
15803
15803
  }
15804
15804
  };
15805
- function Oz({ data: e, mapping: t }, r) {
15805
+ function O8({ data: e, mapping: t }, r) {
15806
15806
  const n = {};
15807
15807
  for (const [i, o] of Object.entries(t)) {
15808
15808
  const a = X(o);
@@ -15810,7 +15810,7 @@ function Oz({ data: e, mapping: t }, r) {
15810
15810
  }
15811
15811
  return n;
15812
15812
  }
15813
- function Nz(e, t, { data: r, mapping: n }, i) {
15813
+ function N8(e, t, { data: r, mapping: n }, i) {
15814
15814
  for (const o of i) {
15815
15815
  if (!t.has(o)) continue;
15816
15816
  const a = n[o], s = X(a);
@@ -15835,7 +15835,7 @@ var Tg = {
15835
15835
  sticker: "stickers",
15836
15836
  pinnedNumber: "pinnedNumbers",
15837
15837
  comment: "comments"
15838
- }, Bz = {
15838
+ }, B8 = {
15839
15839
  differenceArrow(e) {
15840
15840
  return {
15841
15841
  type: "annotation",
@@ -15894,12 +15894,12 @@ var Tg = {
15894
15894
  }
15895
15895
  }, Rk = Object.keys(Tg), Lk = (e, t) => {
15896
15896
  for (const r of Rk) {
15897
- const n = Vz(e, r, t);
15897
+ const n = V8(e, r, t);
15898
15898
  if (n) return n;
15899
15899
  }
15900
15900
  return null;
15901
- }, Fz = (e, t) => e[Tg[t]], Vz = (e, t, r) => {
15902
- const n = Fz(e, t), i = n.findIndex((a) => a.id === r), o = n[i];
15901
+ }, F8 = (e, t) => e[Tg[t]], V8 = (e, t, r) => {
15902
+ const n = F8(e, t), i = n.findIndex((a) => a.id === r), o = n[i];
15903
15903
  return o === void 0 ? null : {
15904
15904
  kind: t,
15905
15905
  index: i,
@@ -15908,7 +15908,7 @@ var Tg = {
15908
15908
  }, yx = Object.freeze({
15909
15909
  light: "#898373",
15910
15910
  dark: "#9F9886"
15911
- }), Hz = {
15911
+ }), H8 = {
15912
15912
  graphBackground: ab,
15913
15913
  graphBorder: Object.freeze({
15914
15914
  light: "rgba(58, 56, 51, 0.15)",
@@ -15975,9 +15975,9 @@ var Tg = {
15975
15975
  dark: "#CB3333"
15976
15976
  },
15977
15977
  trendNeutral: yx
15978
- }, Gz = dE(uE()), Mg = Object.freeze({
15979
- tokens: Object.freeze(Hz),
15980
- defaults: Object.freeze(Gz),
15978
+ }, G8 = dE(uE()), Mg = Object.freeze({
15979
+ tokens: Object.freeze(H8),
15980
+ defaults: Object.freeze(G8),
15981
15981
  overrides: Object.freeze([])
15982
15982
  }), Dk = Object.fromEntries(Object.entries(Ee).map(([e, t]) => [e, Eg(t)])), Ok = (e) => e !== "geom" && Object.hasOwn(Ee, e);
15983
15983
  function Nk(e) {
@@ -15989,14 +15989,14 @@ function Nk(e) {
15989
15989
  function Eg(e) {
15990
15990
  const t = Object.fromEntries(Object.entries(e.children ?? {}).map(([i, o]) => [i, Eg(o)]));
15991
15991
  if (Object.keys(e.vocabulary).length === 0) return t;
15992
- const r = Uz(e);
15992
+ const r = U8(e);
15993
15993
  return Object.assign((i, o) => ({
15994
- ...zz(r, o),
15995
- select: jz(e, r, o),
15994
+ ...z8(r, o),
15995
+ select: j8(e, r, o),
15996
15996
  declarations: i
15997
15997
  }), t);
15998
15998
  }
15999
- var Qr = (e) => Object.keys(e.children ?? {}), $z = Qr(Ee.dataLabel), sbe = Qr(Ee.tooltip), lbe = Qr(Ee.source), cbe = Qr(Ee.heading), ube = Qr(Ee.editOutline), dbe = Qr(Ee.annotation), hbe = {
15999
+ var Qr = (e) => Object.keys(e.children ?? {}), $8 = Qr(Ee.dataLabel), sbe = Qr(Ee.tooltip), lbe = Qr(Ee.source), cbe = Qr(Ee.heading), ube = Qr(Ee.editOutline), dbe = Qr(Ee.annotation), hbe = {
16000
16000
  arrow: Qr(Ee.annotation.children.arrow),
16001
16001
  differenceArrow: Qr(Ee.annotation.children.differenceArrow),
16002
16002
  pinnedNumber: Qr(Ee.annotation.children.pinnedNumber),
@@ -16008,15 +16008,15 @@ var Qr = (e) => Object.keys(e.children ?? {}), $z = Qr(Ee.dataLabel), sbe = Qr(E
16008
16008
  for (const s of Object.values(o.children ?? {})) i(s);
16009
16009
  };
16010
16010
  return i(e), r;
16011
- }, Wz = Rd(Ee.dataLabel, "position"), fbe = Rd(Ee.headline.children.item, "part"), pbe = Rd(Ee.legend, "part"), mbe = Rd(Ee.legend.children.item, "part");
16012
- function Uz(e) {
16011
+ }, W8 = Rd(Ee.dataLabel, "position"), fbe = Rd(Ee.headline.children.item, "part"), pbe = Rd(Ee.legend, "part"), mbe = Rd(Ee.legend.children.item, "part");
16012
+ function U8(e) {
16013
16013
  return new Set(e.options ?? []);
16014
16014
  }
16015
- function jz(e, t, r) {
16015
+ function j8(e, t, r) {
16016
16016
  const n = { ...e.select };
16017
16017
  return t.has("layer") && typeof r?.layer == "string" && (n.layer = r.layer), t.has("annotation") && typeof r?.annotation == "string" && (n.annotation = r.annotation), r?.coord !== void 0 && (n.coord = r.coord), n;
16018
16018
  }
16019
- function zz(e, t) {
16019
+ function z8(e, t) {
16020
16020
  const r = {
16021
16021
  ...e.has("where") && t?.where !== void 0 ? { where: t.where } : {},
16022
16022
  ...e.has("state") && t?.state !== void 0 ? { state: t.state } : {}
@@ -16026,7 +16026,7 @@ function zz(e, t) {
16026
16026
  ...Object.keys(r).length === 0 ? {} : { when: r }
16027
16027
  };
16028
16028
  }
16029
- var Yz = class extends po {
16029
+ var Y8 = class extends po {
16030
16030
  constructor(e) {
16031
16031
  super(), this.container = e;
16032
16032
  }
@@ -16073,7 +16073,7 @@ var Yz = class extends po {
16073
16073
  const t = this.container.theme?.styles;
16074
16074
  return t === void 0 ? [[e, "spec"]] : [[t, "theme"], [e, "spec"]];
16075
16075
  }
16076
- }, Kz = class extends hi {
16076
+ }, K8 = class extends hi {
16077
16077
  constructor(e) {
16078
16078
  super(), this.container = e;
16079
16079
  }
@@ -16097,7 +16097,7 @@ var Yz = class extends po {
16097
16097
  geomColor: e.geomColor
16098
16098
  });
16099
16099
  }
16100
- }, Xz = new Ll(), qz = new Set(S5), Qz = /* @__PURE__ */ new WeakMap(), Zz = /* @__PURE__ */ new WeakMap(), bx = {
16100
+ }, X8 = new Ll(), q8 = new Set(S5), Q8 = /* @__PURE__ */ new WeakMap(), Z8 = /* @__PURE__ */ new WeakMap(), bx = {
16101
16101
  stateless: 0,
16102
16102
  dimmed: 1,
16103
16103
  hovered: 2
@@ -16110,7 +16110,7 @@ var Yz = class extends po {
16110
16110
  conditions: ["where", "state"],
16111
16111
  reason: "a layer's bars share one cap, which the browser fits to every column as the chart resizes"
16112
16112
  }
16113
- }, Jz = Object.keys(Bk), e7 = (e, { coord: t = "cartesian", theme: r, geomColor: n } = {}) => {
16113
+ }, J8 = Object.keys(Bk), e7 = (e, { coord: t = "cartesian", theme: r, geomColor: n } = {}) => {
16114
16114
  const i = [], o = Yk(e, r, n), a = {
16115
16115
  ...n7(),
16116
16116
  warnings: i
@@ -16302,7 +16302,7 @@ var Yz = class extends po {
16302
16302
  suggestion: "Declare 'overpaint' without a state or in the 'hovered' state."
16303
16303
  }), delete L.overpaint);
16304
16304
  const _ = [];
16305
- for (const I of Jz) {
16305
+ for (const I of J8) {
16306
16306
  if (L[I] === void 0) continue;
16307
16307
  const { conditions: D, reason: C } = Bk[I], k = D.find((P) => x.when?.[P] !== void 0);
16308
16308
  k !== void 0 && (_.push(I), u.push({
@@ -16394,7 +16394,7 @@ var Yz = class extends po {
16394
16394
  const t = e.options ?? [];
16395
16395
  return t.includes("where") || t.includes("state");
16396
16396
  }, o7 = (e, t) => {
16397
- const r = e === "geom" ? Xz.getAll().find((n) => n.styleTarget !== void 0 && wE(n.styleTarget)[t] !== void 0)?.type : e === "annotation" ? Object.entries(Ee.annotation.children).find(([, n]) => n.vocabulary[t] !== void 0)?.[0] : void 0;
16397
+ const r = e === "geom" ? X8.getAll().find((n) => n.styleTarget !== void 0 && wE(n.styleTarget)[t] !== void 0)?.type : e === "annotation" ? Object.entries(Ee.annotation.children).find(([, n]) => n.vocabulary[t] !== void 0)?.[0] : void 0;
16398
16398
  return r === void 0 ? void 0 : `style.${e}.${r}`;
16399
16399
  }, Ol = (e) => e.select.target === "geom", a7 = (e, t) => e !== void 0 && Object.hasOwn(e, t) ? e[t] : void 0, Vk = (e, t, r, n) => {
16400
16400
  const i = e.get(r) ?? /* @__PURE__ */ new Map();
@@ -16403,7 +16403,7 @@ var Yz = class extends po {
16403
16403
  if (o !== void 0) return o;
16404
16404
  const a = n();
16405
16405
  return i.set(t, a), a;
16406
- }, Hk = (e, t) => Vk(Qz, e, t, () => SE(e, t)), nl = (e, t) => {
16406
+ }, Hk = (e, t) => Vk(Q8, e, t, () => SE(e, t)), nl = (e, t) => {
16407
16407
  const { kind: r, part: n } = e;
16408
16408
  if (r === void 0) return Qs({
16409
16409
  target: "geom",
@@ -16460,7 +16460,7 @@ var Yz = class extends po {
16460
16460
  entry: t,
16461
16461
  kind: wx({ kind: e.layerGeom }, e.styleTarget)
16462
16462
  }, e.tokens);
16463
- }, u7 = (e, t) => Vk(Zz, e, t, () => dE(uE([Hk(e, t)]))), d7 = (e, t) => bx[e.state ?? "stateless"] - bx[t.state ?? "stateless"], h7 = (e, t) => t === void 0 ? `builtin ${e}` : `builtin ${e}.${t}`, f7 = (e, t, r, n) => {
16463
+ }, u7 = (e, t) => Vk(Z8, e, t, () => dE(uE([Hk(e, t)]))), d7 = (e, t) => bx[e.state ?? "stateless"] - bx[t.state ?? "stateless"], h7 = (e, t) => t === void 0 ? `builtin ${e}` : `builtin ${e}.${t}`, f7 = (e, t, r, n) => {
16464
16464
  const i = [], o = { list: "builtin" }, a = (s, l, c, u) => {
16465
16465
  if (s.kind !== void 0 && s.kind !== e) return;
16466
16466
  if (c !== void 0 && !s7(s, t)) {
@@ -16688,7 +16688,7 @@ var Yz = class extends po {
16688
16688
  suggestion: `Declare '${m}' in the stylesheet's tokens.`
16689
16689
  });
16690
16690
  }, f = (p) => {
16691
- const m = qz.has(p), g = o7(s, p), y = g === void 0 ? `Declare '${p}' on a target whose vocabulary carries it.` : `Declare '${p}' on an entry whose kind supports it (e.g. ${g}).`;
16691
+ const m = q8.has(p), g = o7(s, p), y = g === void 0 ? `Declare '${p}' on a target whose vocabulary carries it.` : `Declare '${p}' on an entry whose kind supports it (e.g. ${g}).`;
16692
16692
  a.push({
16693
16693
  code: "INVALID_STYLE_RULE",
16694
16694
  message: `Style ${i} declaration '${p}' ignored: ${m ? "not in this entry's vocabulary" : "not a style property"}.`,
@@ -16840,7 +16840,7 @@ var Yz = class extends po {
16840
16840
  }, E7 = (e) => (t) => G(t) ? e.map(t) : null;
16841
16841
  function k7(e = new Ll(), t, r = new BE()) {
16842
16842
  return {
16843
- diagnostics: new yz(),
16843
+ diagnostics: new y8(),
16844
16844
  geomRegistry: e,
16845
16845
  statRegistry: r,
16846
16846
  theme: t
@@ -17159,7 +17159,7 @@ function Xk(e) {
17159
17159
  coord: C7,
17160
17160
  mapping: I7,
17161
17161
  highlight: _7,
17162
- annotation: Bz,
17162
+ annotation: B8,
17163
17163
  config: P7,
17164
17164
  createSpec: L7,
17165
17165
  pipe: D7,
@@ -17500,9 +17500,9 @@ var J7 = {
17500
17500
  "highlights",
17501
17501
  "annotations"
17502
17502
  ], Tx = "light", oY = ({ plugins: e = [], theme: t } = {}) => {
17503
- const r = VE(e), { geomRegistry: n, statRegistry: i, transformRegistry: o } = N6(r), a = k7(n, tY(t), i), s = new D8(a), l = new Ck(o);
17503
+ const r = VE(e), { geomRegistry: n, statRegistry: i, transformRegistry: o } = N6(r), a = k7(n, tY(t), i), s = new Dz(a), l = new Ck(o);
17504
17504
  for (const c of r.warnings) a.diagnostics.addWarning(c, { persistent: !0 });
17505
- return new iY(a, new hG(), new Lz(a), l, new B3(), new U4(a, l, i, new L4(a, l, new Dz(i), new yG(), new vG(a), new H6(new n8()))), new A8(a, s), new H3(new sG()), new v8(a), new M7(), new r4(a), new A7(a), new Yz(a), new Kz(a), new s4(a), new f3(a));
17505
+ return new iY(a, new hG(), new L8(a), l, new B3(), new U4(a, l, i, new L4(a, l, new D8(i), new yG(), new vG(a), new H6(new nz()))), new Az(a, s), new H3(new sG()), new vz(a), new M7(), new r4(a), new A7(a), new Y8(a), new K8(a), new s4(a), new f3(a));
17506
17506
  };
17507
17507
  function ra(e, t) {
17508
17508
  return e.geom === t;
@@ -41148,9 +41148,9 @@ var zu = {
41148
41148
  };
41149
41149
  }, Sy = (e) => e.headline().resolve(), bh = (e) => {
41150
41150
  const t = {};
41151
- for (const r of $z) {
41151
+ for (const r of $8) {
41152
41152
  const n = {};
41153
- for (const i of Wz) n[i] = T9(e, r, i);
41153
+ for (const i of W8) n[i] = T9(e, r, i);
41154
41154
  t[r] = n;
41155
41155
  }
41156
41156
  return t;
@@ -45085,7 +45085,7 @@ var n0e = (e) => [...new Set(e)], i0e = (e) => ({
45085
45085
  stickers: e.stickers.length,
45086
45086
  pinnedNumbers: e.pinnedNumbers.length,
45087
45087
  comments: e.comments.length
45088
- }), o0e = "https://3b76a42331a1e27a2adb223278bf1b48@o4505108638597120.ingest.us.sentry.io/4512260250992640", a0e = "1.9.0-beta.1794228873898", s0e = /^(https?):\/\/([^@]+)@([^/]+)\/(\d+)\/?$/;
45088
+ }), o0e = "https://3b76a42331a1e27a2adb223278bf1b48@o4505108638597120.ingest.us.sentry.io/4512260250992640", a0e = "1.9.0-beta.1794238447086", s0e = /^(https?):\/\/([^@]+)@([^/]+)\/(\d+)\/?$/;
45089
45089
  function eD() {
45090
45090
  return o0e;
45091
45091
  }
@@ -45247,7 +45247,7 @@ export {
45247
45247
  Cwe as UnitSpaceSvg,
45248
45248
  qe as UserInputError,
45249
45249
  _n as VISUAL_VARIABLES,
45250
- Bz as annotation,
45250
+ B8 as annotation,
45251
45251
  roe as buildDotsEditOutlineShapes,
45252
45252
  Il as buildPanelAnchorBox,
45253
45253
  no as buildPolarBarArcPath,