@cfasim-ui/charts 0.4.6 → 0.4.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -283,16 +283,40 @@ function X(e, t) {
283
283
  let n = URL.createObjectURL(e), r = document.createElement("a");
284
284
  r.href = n, r.download = t, r.click(), URL.revokeObjectURL(n);
285
285
  }
286
- function Z(e, t) {
287
- let n = e.cloneNode(!0);
288
- n.setAttribute("xmlns", "http://www.w3.org/2000/svg");
289
- let r = new XMLSerializer().serializeToString(n);
286
+ var Z = [
287
+ "color",
288
+ "font-family",
289
+ "font-size",
290
+ "font-weight"
291
+ ], Q = ["fill", "stroke"];
292
+ function me(e) {
293
+ let t = e.match(/^\s*var\(\s*(--[\w-]+)\s*(?:,\s*([^)]*?)\s*)?\)\s*$/);
294
+ if (!t) return e;
295
+ let [, n, r] = t;
296
+ return window.getComputedStyle(document.documentElement).getPropertyValue(n).trim() || (r ? r.trim() : e);
297
+ }
298
+ function he(e) {
299
+ let t = e.cloneNode(!0);
300
+ t.setAttribute("xmlns", "http://www.w3.org/2000/svg");
301
+ let n = window.getComputedStyle(e), r = [];
302
+ for (let e of Z) {
303
+ let t = n.getPropertyValue(e);
304
+ t && r.push(`${e}: ${t}`);
305
+ }
306
+ let i = t.getAttribute("style") ?? "";
307
+ t.setAttribute("style", [i, ...r].filter(Boolean).join("; "));
308
+ for (let e of t.querySelectorAll("*")) for (let t of Q) {
309
+ let n = e.getAttribute(t);
310
+ !n || !n.includes("var(") || e.setAttribute(t, me(n));
311
+ }
312
+ return t;
313
+ }
314
+ function ge(e, t) {
315
+ let n = he(e), r = new XMLSerializer().serializeToString(n);
290
316
  X(new Blob([r], { type: "image/svg+xml" }), `${t}.svg`);
291
317
  }
292
- function Q(e, t) {
293
- let n = e.cloneNode(!0);
294
- n.setAttribute("xmlns", "http://www.w3.org/2000/svg");
295
- let r = new XMLSerializer().serializeToString(n), i = new Blob([r], { type: "image/svg+xml;charset=utf-8" }), a = URL.createObjectURL(i), o = new Image(), s = e.width.baseVal.value || e.clientWidth, c = e.height.baseVal.value || e.clientHeight;
318
+ function _e(e, t) {
319
+ let n = he(e), r = new XMLSerializer().serializeToString(n), i = new Blob([r], { type: "image/svg+xml;charset=utf-8" }), a = URL.createObjectURL(i), o = new Image(), s = e.width.baseVal.value || e.clientWidth, c = e.height.baseVal.value || e.clientHeight;
296
320
  o.onload = () => {
297
321
  let e = document.createElement("canvas");
298
322
  e.width = s * 2, e.height = c * 2;
@@ -302,12 +326,12 @@ function Q(e, t) {
302
326
  }), URL.revokeObjectURL(a);
303
327
  }, o.src = a;
304
328
  }
305
- function me(e, t) {
329
+ function ve(e, t) {
306
330
  X(new Blob([e], { type: "text/csv" }), `${t}.csv`);
307
331
  }
308
332
  //#endregion
309
333
  //#region src/_shared/useChartMenu.ts
310
- function he(e) {
334
+ function $(e) {
311
335
  let t = v(null);
312
336
  function r() {
313
337
  let t = e.filename();
@@ -321,17 +345,17 @@ function he(e) {
321
345
  let n = r(), i = [{
322
346
  label: "Save as SVG",
323
347
  action: () => {
324
- t.value && Z(t.value, n);
348
+ t.value && ge(t.value, n);
325
349
  }
326
350
  }, {
327
351
  label: "Save as PNG",
328
352
  action: () => {
329
- t.value && Q(t.value, n);
353
+ t.value && _e(t.value, n);
330
354
  }
331
355
  }];
332
356
  return e.downloadLink() || i.push({
333
357
  label: "Download CSV",
334
- action: () => me(e.getCsv(), n)
358
+ action: () => ve(e.getCsv(), n)
335
359
  }), i;
336
360
  }),
337
361
  downloadLinkText: n(() => {
@@ -344,7 +368,7 @@ function he(e) {
344
368
  }
345
369
  //#endregion
346
370
  //#region src/_shared/seriesCsv.ts
347
- function ge(e) {
371
+ function ye(e) {
348
372
  if (e.length === 0) return "";
349
373
  let t = 0;
350
374
  for (let n of e) n.data.length > t && (t = n.data.length);
@@ -356,25 +380,25 @@ function ge(e) {
356
380
  }
357
381
  return i.join("\n");
358
382
  }
359
- function _e(e, t, n = "category") {
383
+ function be(e, t, n = "category") {
360
384
  if (t.length === 0 || e.length === 0) return "";
361
385
  let r = [(t.length === 1 ? [n, t[0].label || "value"] : [n, ...t.map((e, t) => e.label || `series_${t}`)]).join(",")];
362
386
  for (let n = 0; n < e.length; n++) {
363
- let i = [$(e[n])];
387
+ let i = [xe(e[n])];
364
388
  for (let e of t) i.push(n < e.data.length ? String(e.data[n]) : "");
365
389
  r.push(i.join(","));
366
390
  }
367
391
  return r.join("\n");
368
392
  }
369
- function $(e) {
393
+ function xe(e) {
370
394
  return e.includes(",") || e.includes("\"") || e.includes("\n") ? `"${e.replace(/"/g, "\"\"")}"` : e;
371
395
  }
372
396
  //#endregion
373
397
  //#region src/_shared/ChartAnnotations.vue?vue&type=script&setup=true&lang.ts
374
- var ve = {
398
+ var Se = {
375
399
  class: "chart-annotations",
376
400
  "pointer-events": "none"
377
- }, ye = [
401
+ }, Ce = [
378
402
  "x1",
379
403
  "y1",
380
404
  "x2",
@@ -382,13 +406,12 @@ var ve = {
382
406
  "stroke",
383
407
  "stroke-width",
384
408
  "stroke-dasharray"
385
- ], be = [
409
+ ], we = [
386
410
  "d",
387
411
  "stroke",
388
412
  "stroke-width",
389
- "stroke-dasharray",
390
- "marker-start"
391
- ], xe = [
413
+ "stroke-dasharray"
414
+ ], Te = ["fill", "transform"], Ee = [
392
415
  "x",
393
416
  "y",
394
417
  "text-anchor",
@@ -397,7 +420,7 @@ var ve = {
397
420
  "fill",
398
421
  "stroke",
399
422
  "stroke-width"
400
- ], Se = ["x", "dy"], Ce = ["font-weight", "font-style"], we = 13, Te = "normal", Ee = 700, De = "var(--color-bg-0, #fff)", Oe = 3, ke = 1, Ae = 4, je = 6, Me = 1.2, Ne = .35, Pe = 3, Fe = /* @__PURE__ */ l({
423
+ ], De = ["x", "dy"], Oe = ["font-weight", "font-style"], ke = 13, Ae = "normal", je = 700, Me = "var(--color-bg-0, #fff)", Ne = 3, Pe = 1, Fe = 4, Ie = 6, Le = 1.2, Re = .35, ze = /* @__PURE__ */ l({
401
424
  __name: "ChartAnnotations",
402
425
  props: {
403
426
  annotations: { default: () => [] },
@@ -434,13 +457,18 @@ var ve = {
434
457
  if (!n || !isFinite(n.x) || !isFinite(n.y)) continue;
435
458
  let i = t.pointer ?? "curved", a = i.startsWith("rule");
436
459
  if (a && !r.bounds) continue;
437
- let { x: o, y: l } = t.offset, f = n.x + o, p = n.y + l, m = t.color ?? "currentColor", h = t.fontSize ?? we, g = t.fontWeight ?? Te, _ = t.haloColor ?? De, v = t.haloWidth ?? Oe, y = t.lineColor ?? m, ee = t.lineWidth ?? ke, b = s(t.lineDash), te = t.textAnchor ?? (o > 0 ? "start" : o < 0 ? "end" : "middle"), x, S = "";
438
- a && r.bounds ? x = u(i, n.x, n.y, r.bounds) : S = d(n.x, n.y, f, p, h, i), e.push({
460
+ let { x: o, y: l } = t.offset, f = n.x + o, p = n.y + l, m = t.color ?? "currentColor", h = t.fontSize ?? ke, g = t.fontWeight ?? Ae, _ = t.haloColor ?? Me, v = t.haloWidth ?? Ne, y = t.lineColor ?? m, ee = t.lineWidth ?? Pe, b = s(t.lineDash), te = t.textAnchor ?? (o > 0 ? "start" : o < 0 ? "end" : "middle"), x, S = "", C, w = !a && (t.arrow ?? !0);
461
+ if (a && r.bounds) x = u(i, n.x, n.y, r.bounds);
462
+ else {
463
+ let e = d(n.x, n.y, f, p, h, i);
464
+ S = e.path, w && e.arrow && (C = e.arrow);
465
+ }
466
+ e.push({
439
467
  lines: t.text.split("\n").map(c),
440
468
  textX: f,
441
469
  textY: p,
442
470
  textAnchor: te,
443
- dy: h * Me,
471
+ dy: h * Le,
444
472
  fontSize: h,
445
473
  fontWeight: g,
446
474
  color: m,
@@ -450,7 +478,8 @@ var ve = {
450
478
  lineColor: y,
451
479
  lineWidth: ee,
452
480
  lineDash: b,
453
- arrow: !a && (t.arrow ?? !0),
481
+ arrow: w,
482
+ arrowTip: C,
454
483
  rule: x
455
484
  });
456
485
  }
@@ -503,32 +532,34 @@ var ve = {
503
532
  }
504
533
  }
505
534
  function d(e, t, n, r, i, a) {
506
- if (a === "none") return "";
507
- let o = n - e, s = r - t, c = r - i * Ne;
535
+ if (a === "none") return { path: "" };
536
+ let o = n - e, s = r - t, c = r - i * Re;
508
537
  if (o === 0 || s === 0 || a === "straight") {
509
538
  let i = s === 0 ? r : c, a = n - e, o = i - t, l = Math.hypot(a, o);
510
- if (l <= Ae + je) return "";
511
- let u = a / l, d = o / l;
512
- return `M${e + u * Ae},${t + d * Ae} L${n - u * je},${i - d * je}`;
539
+ if (l <= Fe + Ie) return { path: "" };
540
+ let u = a / l, d = o / l, f = e + u * Fe, p = t + d * Fe, m = n - u * Ie, h = i - d * Ie, g = Math.atan2(-d, -u) * 180 / Math.PI;
541
+ return {
542
+ path: `M${f},${p} L${m},${h}`,
543
+ arrow: {
544
+ x: f,
545
+ y: p,
546
+ angle: g
547
+ }
548
+ };
513
549
  }
514
550
  let l = c - t;
515
- if (Math.abs(l) <= Ae || Math.abs(o) <= je) return "";
516
- let u = Math.sign(o), d = Math.sign(l), f = e + u * Pe;
517
- return `M${f},${t + d * Ae} Q${f},${c} ${n - u * je},${c}`;
551
+ if (Math.abs(l) <= Fe || Math.abs(o) <= Ie) return { path: "" };
552
+ let u = Math.sign(o), d = Math.sign(l), f = e, p = t + d * Fe, m = n - u * Ie, h = c, g = d > 0 ? -90 : 90;
553
+ return {
554
+ path: `M${f},${p} Q${f},${c} ${m},${h}`,
555
+ arrow: {
556
+ x: f,
557
+ y: p,
558
+ angle: g
559
+ }
560
+ };
518
561
  }
519
- return (t, n) => (_(), a(e, null, [n[0] ||= o("defs", null, [o("marker", {
520
- id: "chart-annotation-arrow",
521
- viewBox: "0 0 8 8",
522
- refX: "7",
523
- refY: "4",
524
- markerWidth: "6",
525
- markerHeight: "6",
526
- orient: "auto-start-reverse",
527
- markerUnits: "userSpaceOnUse"
528
- }, [o("path", {
529
- d: "M0,0 L8,4 L0,8 Z",
530
- fill: "context-stroke"
531
- })])], -1), o("g", ve, [(_(!0), a(e, null, y(l.value, (t, n) => (_(), a(e, { key: n }, [
562
+ return (t, n) => (_(), a("g", Se, [(_(!0), a(e, null, y(l.value, (t, n) => (_(), a(e, { key: n }, [
532
563
  t.rule ? (_(), a("line", {
533
564
  key: 0,
534
565
  x1: t.rule.x1,
@@ -539,18 +570,22 @@ var ve = {
539
570
  "stroke-width": t.lineWidth,
540
571
  "stroke-dasharray": t.lineDash,
541
572
  "stroke-linecap": "round"
542
- }, null, 8, ye)) : i("", !0),
573
+ }, null, 8, Ce)) : i("", !0),
543
574
  t.pointerPath ? (_(), a("path", {
544
575
  key: 1,
545
576
  d: t.pointerPath,
546
577
  fill: "none",
547
578
  stroke: t.lineColor,
548
- style: m({ color: t.lineColor }),
549
579
  "stroke-width": t.lineWidth,
550
580
  "stroke-dasharray": t.lineDash,
551
- "stroke-linecap": "round",
552
- "marker-start": t.arrow ? "url(#chart-annotation-arrow)" : void 0
553
- }, null, 12, be)) : i("", !0),
581
+ "stroke-linecap": "round"
582
+ }, null, 8, we)) : i("", !0),
583
+ t.arrowTip ? (_(), a("polygon", {
584
+ key: 2,
585
+ points: "0,0 -6,-3 -6,3",
586
+ fill: t.lineColor,
587
+ transform: `translate(${t.arrowTip.x} ${t.arrowTip.y}) rotate(${t.arrowTip.angle})`
588
+ }, null, 8, Te)) : i("", !0),
554
589
  o("text", {
555
590
  x: t.textX,
556
591
  y: t.textY,
@@ -568,14 +603,14 @@ var ve = {
568
603
  dy: r === 0 ? 0 : t.dy
569
604
  }, [(_(!0), a(e, null, y(n, (e, t) => (_(), a("tspan", {
570
605
  key: t,
571
- "font-weight": e.bold ? Ee : void 0,
606
+ "font-weight": e.bold ? je : void 0,
572
607
  "font-style": e.italic ? "italic" : void 0
573
- }, b(e.text), 9, Ce))), 128))], 8, Se))), 128))], 8, xe)
574
- ], 64))), 128))])], 64));
608
+ }, b(e.text), 9, Oe))), 128))], 8, De))), 128))], 8, Ee)
609
+ ], 64))), 128))]));
575
610
  }
576
- }), Ie = 400, Le = 200;
577
- function Re(e) {
578
- let { containerRef: t, measuredWidth: r } = K({ debounce: e.debounce }), i = n(() => e.width() ?? (r.value || Ie)), a = n(() => e.height() ?? Le), { padding: o, legendY: s, innerW: c, innerH: l, bounds: u } = q({
611
+ }), Be = 400, Ve = 200;
612
+ function He(e) {
613
+ let { containerRef: t, measuredWidth: r } = K({ debounce: e.debounce }), i = n(() => e.width() ?? (r.value || Be)), a = n(() => e.height() ?? Ve), { padding: o, legendY: s, innerW: c, innerH: l, bounds: u } = q({
579
614
  title: e.title,
580
615
  xLabel: e.xLabel,
581
616
  yLabel: e.yLabel,
@@ -590,7 +625,7 @@ function Re(e) {
590
625
  pointerToIndex: e.pointerToIndex,
591
626
  containerRef: t,
592
627
  onHover: e.onHover
593
- }), { svgRef: h, items: g, downloadLinkText: _, csvHref: v, resolvedFilename: y } = he({
628
+ }), { svgRef: h, items: g, downloadLinkText: _, csvHref: v, resolvedFilename: y } = $({
594
629
  filename: e.filename,
595
630
  legacyMenuLabel: e.menu,
596
631
  getCsv: e.getCsv,
@@ -616,7 +651,7 @@ function Re(e) {
616
651
  menuFilename: y
617
652
  };
618
653
  }
619
- function ze(e, t) {
654
+ function Ue(e, t) {
620
655
  return (n) => {
621
656
  let r = e();
622
657
  if (r) return r(n);
@@ -626,70 +661,70 @@ function ze(e, t) {
626
661
  }
627
662
  //#endregion
628
663
  //#region src/LineChart/LineChart.vue?vue&type=script&setup=true&lang.ts
629
- var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
664
+ var We = ["width", "height"], Ge = ["x"], Ke = { key: 1 }, qe = [
630
665
  "x1",
631
666
  "y1",
632
667
  "x2",
633
668
  "y2",
634
669
  "stroke",
635
670
  "stroke-dasharray"
636
- ], We = [
671
+ ], Je = [
637
672
  "cx",
638
673
  "cy",
639
674
  "fill",
640
675
  "fill-opacity",
641
676
  "stroke"
642
- ], Ge = ["x", "y"], Ke = [
677
+ ], Ye = ["x", "y"], Xe = [
643
678
  "x1",
644
679
  "y1",
645
680
  "x2",
646
681
  "y2"
647
- ], qe = [
682
+ ], Ze = [
648
683
  "x1",
649
684
  "y1",
650
685
  "x2",
651
686
  "y2"
652
- ], Je = [
687
+ ], Qe = [
653
688
  "x1",
654
689
  "y1",
655
690
  "x2",
656
691
  "y2"
657
- ], Ye = [
692
+ ], $e = [
658
693
  "x1",
659
694
  "y1",
660
695
  "x2",
661
696
  "y2"
662
- ], Xe = ["x", "y"], Ze = ["transform"], Qe = [
697
+ ], et = ["x", "y"], tt = ["transform"], nt = [
663
698
  "x",
664
699
  "y",
665
700
  "text-anchor"
666
- ], $e = ["x", "y"], et = [
701
+ ], rt = ["x", "y"], it = [
667
702
  "d",
668
703
  "fill",
669
704
  "fill-opacity"
670
- ], tt = [
705
+ ], at = [
671
706
  "d",
672
707
  "stroke",
673
708
  "stroke-width",
674
709
  "stroke-opacity",
675
710
  "stroke-dasharray"
676
- ], nt = [
711
+ ], ot = [
677
712
  "cx",
678
713
  "cy",
679
714
  "r",
680
715
  "fill",
681
716
  "fill-opacity",
682
717
  "stroke"
683
- ], rt = [
718
+ ], st = [
684
719
  "d",
685
720
  "fill",
686
721
  "fill-opacity"
687
- ], it = [
722
+ ], ct = [
688
723
  "d",
689
724
  "stroke",
690
725
  "stroke-width",
691
726
  "stroke-dasharray"
692
- ], at = [
727
+ ], lt = [
693
728
  "x1",
694
729
  "y1",
695
730
  "x2",
@@ -697,7 +732,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
697
732
  "stroke",
698
733
  "stroke-width",
699
734
  "stroke-dasharray"
700
- ], ot = [
735
+ ], ut = [
701
736
  "x1",
702
737
  "y1",
703
738
  "x2",
@@ -705,44 +740,44 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
705
740
  "stroke",
706
741
  "stroke-width",
707
742
  "stroke-dasharray"
708
- ], st = [
743
+ ], dt = [
709
744
  "x1",
710
745
  "y1",
711
746
  "x2",
712
747
  "y2"
713
- ], ct = [
748
+ ], ft = [
714
749
  "x1",
715
750
  "y1",
716
751
  "x2",
717
752
  "y2"
718
- ], lt = [
753
+ ], pt = [
719
754
  "x1",
720
755
  "y1",
721
756
  "x2",
722
757
  "y2"
723
- ], ut = [
758
+ ], mt = [
724
759
  "cx",
725
760
  "cy",
726
761
  "fill"
727
- ], dt = [
762
+ ], ht = [
728
763
  "x",
729
764
  "y",
730
765
  "width",
731
766
  "height"
732
- ], ft = [
767
+ ], gt = [
733
768
  "cx",
734
769
  "cy",
735
770
  "fill",
736
771
  "fill-opacity",
737
772
  "stroke"
738
- ], pt = [
773
+ ], _t = [
739
774
  "x",
740
775
  "y",
741
776
  "fill"
742
- ], mt = ["x", "y"], ht = { class: "line-chart-tooltip" }, gt = {
777
+ ], vt = ["x", "y"], yt = { class: "line-chart-tooltip" }, bt = {
743
778
  key: 0,
744
779
  class: "line-chart-tooltip-label"
745
- }, _t = ["href", "download"], vt = 36, yt = 12, bt = 7, xt = 16, St = /* @__PURE__ */ B(/* @__PURE__ */ l({
780
+ }, xt = ["href", "download"], St = 36, Ct = 12, wt = 7, Tt = 16, Et = /* @__PURE__ */ B(/* @__PURE__ */ l({
746
781
  __name: "LineChart",
747
782
  props: {
748
783
  y: {},
@@ -790,7 +825,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
790
825
  data: e.y ?? e.data ?? g
791
826
  };
792
827
  }
793
- let x = ze(() => l.tooltipValueFormat, () => l.yTickFormat), C = n(() => {
828
+ let x = Ue(() => l.tooltipValueFormat, () => l.yTickFormat), C = n(() => {
794
829
  if (l.series && l.series.length > 0) return l.series.map(v);
795
830
  let e = l.y ?? l.data;
796
831
  return e ? [{
@@ -919,7 +954,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
919
954
  let t = [], n = Y.value.left + Z.value;
920
955
  for (let r of e) {
921
956
  if (!r.label && !r.description || r.legend === "inline" || r.legend === !1) continue;
922
- let e = r.label ?? "", i = r.description ?? "", a = Math.max(e.length, i.length) * bt, o = F(r, "start") + a / 2 + 2, s = n - a / 2 - 8, c = Math.min(o, s), l = r.color ?? (r.seriesIndex == null ? "#999" : C.value[r.seriesIndex]?.color ?? "currentColor");
957
+ let e = r.label ?? "", i = r.description ?? "", a = Math.max(e.length, i.length) * wt, o = F(r, "start") + a / 2 + 2, s = n - a / 2 - 8, c = Math.min(o, s), l = r.color ?? (r.seriesIndex == null ? "#999" : C.value[r.seriesIndex]?.color ?? "currentColor");
923
958
  t.push({
924
959
  cx: c,
925
960
  labelText: e,
@@ -934,7 +969,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
934
969
  let r = [];
935
970
  for (let e of t) {
936
971
  let t = e.cx - e.textWidth / 2, n = 0;
937
- for (; n < r.length && !(t >= r[n] + xt);) n++;
972
+ for (; n < r.length && !(t >= r[n] + Tt);) n++;
938
973
  e.row = n;
939
974
  let i = e.cx + e.textWidth / 2;
940
975
  r[n] = Math.max(r[n] ?? -Infinity, i);
@@ -944,7 +979,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
944
979
  extraHeight: 0
945
980
  } : {
946
981
  labels: t,
947
- extraHeight: (Math.max(...t.map((e) => e.row)) + 1) * vt + yt
982
+ extraHeight: (Math.max(...t.map((e) => e.row)) + 1) * St + Ct
948
983
  };
949
984
  }), ae = n(() => {
950
985
  let e = [];
@@ -966,7 +1001,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
966
1001
  });
967
1002
  }
968
1003
  return e;
969
- }), oe = n(() => pe.value + ie.value.extraHeight), I = n(() => Y.value.top + Q.value + Y.value.bottom + yt), se = n(() => {
1004
+ }), oe = n(() => pe.value + ie.value.extraHeight), I = n(() => Y.value.top + Q.value + Y.value.bottom + Ct), se = n(() => {
970
1005
  let { min: e, max: t } = M.value, n = (t) => V(Y.value.top + Q.value - (t - e) / M.value.range * Q.value), r = (e) => l.yTickFormat ? l.yTickFormat(e) : W(e);
971
1006
  return e === t ? [{
972
1007
  value: r(e),
@@ -1009,7 +1044,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1009
1044
  });
1010
1045
  });
1011
1046
  function L() {
1012
- return typeof l.csv == "function" ? l.csv() : typeof l.csv == "string" ? l.csv : ge(C.value);
1047
+ return typeof l.csv == "function" ? l.csv() : typeof l.csv == "string" ? l.csv : ye(C.value);
1013
1048
  }
1014
1049
  let R = n(() => !!l.tooltipData || !!l.tooltipTrigger), z = n(() => {
1015
1050
  let e = he.value, t = C.value[0];
@@ -1076,7 +1111,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1076
1111
  let { min: r, max: i } = A.value, a = i - r || 1;
1077
1112
  return H(n, r + (e - t.left - Y.value.left) / Z.value * a);
1078
1113
  }
1079
- let { containerRef: q, svgRef: J, width: fe, height: pe, padding: Y, legendY: X, innerW: Z, innerH: Q, bounds: me, hoverIndex: he, tooltipRef: _e, tooltipPos: $, tooltipHandlers: ve, menuItems: ye, downloadLinkText: be, csvHref: xe, menuFilename: Se } = Re({
1114
+ let { containerRef: q, svgRef: J, width: fe, height: pe, padding: Y, legendY: X, innerW: Z, innerH: Q, bounds: me, hoverIndex: he, tooltipRef: ge, tooltipPos: _e, tooltipHandlers: ve, menuItems: $, downloadLinkText: be, csvHref: xe, menuFilename: Se } = He({
1080
1115
  width: () => l.width,
1081
1116
  height: () => l.height,
1082
1117
  title: () => l.title,
@@ -1102,7 +1137,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1102
1137
  }, [
1103
1138
  t.menu ? (_(), r(le, {
1104
1139
  key: 0,
1105
- items: S(ye)
1140
+ items: S($)
1106
1141
  }, null, 8, ["items"])) : i("", !0),
1107
1142
  (_(), a("svg", {
1108
1143
  ref_key: "svgRef",
@@ -1118,8 +1153,8 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1118
1153
  "font-size": "14",
1119
1154
  "font-weight": "600",
1120
1155
  fill: "currentColor"
1121
- }, b(t.title), 9, Ve)) : i("", !0),
1122
- ae.value.length > 0 ? (_(), a("g", He, [(_(!0), a(e, null, y(ae.value, (t, n) => (_(), a(e, { key: "ileg" + n }, [t.type === "series" ? (_(), a("line", {
1156
+ }, b(t.title), 9, Ge)) : i("", !0),
1157
+ ae.value.length > 0 ? (_(), a("g", Ke, [(_(!0), a(e, null, y(ae.value, (t, n) => (_(), a(e, { key: "ileg" + n }, [t.type === "series" ? (_(), a("line", {
1123
1158
  key: 0,
1124
1159
  x1: S(Y).left + n * 120,
1125
1160
  y1: S(X),
@@ -1128,7 +1163,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1128
1163
  stroke: t.color,
1129
1164
  "stroke-width": "2",
1130
1165
  "stroke-dasharray": t.dashed ? "4 2" : void 0
1131
- }, null, 8, Ue)) : (_(), a("circle", {
1166
+ }, null, 8, qe)) : (_(), a("circle", {
1132
1167
  key: 1,
1133
1168
  cx: S(Y).left + n * 120 + 4,
1134
1169
  cy: S(X),
@@ -1137,12 +1172,12 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1137
1172
  "fill-opacity": t.fillOpacity,
1138
1173
  stroke: t.color,
1139
1174
  "stroke-width": "1.5"
1140
- }, null, 8, We)), o("text", {
1175
+ }, null, 8, Je)), o("text", {
1141
1176
  x: S(Y).left + n * 120 + 18,
1142
1177
  y: S(X) + 4,
1143
1178
  "font-size": "11",
1144
1179
  fill: "currentColor"
1145
- }, b(t.label), 9, Ge)], 64))), 128))])) : i("", !0),
1180
+ }, b(t.label), 9, Ye)], 64))), 128))])) : i("", !0),
1146
1181
  o("line", {
1147
1182
  x1: S(V)(S(Y).left),
1148
1183
  y1: S(V)(S(Y).top),
@@ -1150,7 +1185,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1150
1185
  y2: S(V)(S(Y).top + S(Q)),
1151
1186
  stroke: "currentColor",
1152
1187
  "stroke-opacity": "0.3"
1153
- }, null, 8, Ke),
1188
+ }, null, 8, Xe),
1154
1189
  o("line", {
1155
1190
  x1: S(V)(S(Y).left),
1156
1191
  y1: S(V)(S(Y).top + S(Q)),
@@ -1158,7 +1193,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1158
1193
  y2: S(V)(S(Y).top + S(Q)),
1159
1194
  stroke: "currentColor",
1160
1195
  "stroke-opacity": "0.3"
1161
- }, null, 8, qe),
1196
+ }, null, 8, Ze),
1162
1197
  t.yGrid ? (_(!0), a(e, { key: 2 }, y(se.value, (e, t) => (_(), a("line", {
1163
1198
  key: "yg" + t,
1164
1199
  x1: S(Y).left,
@@ -1167,7 +1202,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1167
1202
  y2: e.y,
1168
1203
  stroke: "currentColor",
1169
1204
  "stroke-opacity": "0.1"
1170
- }, null, 8, Je))), 128)) : i("", !0),
1205
+ }, null, 8, Qe))), 128)) : i("", !0),
1171
1206
  t.xGrid ? (_(!0), a(e, { key: 3 }, y(ce.value, (e, t) => (_(), a("line", {
1172
1207
  key: "xg" + t,
1173
1208
  x1: e.x,
@@ -1176,7 +1211,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1176
1211
  y2: S(Y).top + S(Q),
1177
1212
  stroke: "currentColor",
1178
1213
  "stroke-opacity": "0.1"
1179
- }, null, 8, Ye))), 128)) : i("", !0),
1214
+ }, null, 8, $e))), 128)) : i("", !0),
1180
1215
  (_(!0), a(e, null, y(se.value, (e, t) => (_(), a("text", {
1181
1216
  key: "y" + t,
1182
1217
  "data-testid": "y-tick",
@@ -1187,7 +1222,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1187
1222
  "font-size": "10",
1188
1223
  fill: "currentColor",
1189
1224
  "fill-opacity": "0.6"
1190
- }, b(e.value), 9, Xe))), 128)),
1225
+ }, b(e.value), 9, et))), 128)),
1191
1226
  t.yLabel ? (_(), a("text", {
1192
1227
  key: 4,
1193
1228
  x: 0,
@@ -1196,7 +1231,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1196
1231
  "text-anchor": "middle",
1197
1232
  "font-size": "13",
1198
1233
  fill: "currentColor"
1199
- }, b(t.yLabel), 9, Ze)) : i("", !0),
1234
+ }, b(t.yLabel), 9, tt)) : i("", !0),
1200
1235
  (_(!0), a(e, null, y(ce.value, (e, t) => (_(), a("text", {
1201
1236
  key: "x" + t,
1202
1237
  "data-testid": "x-tick",
@@ -1206,7 +1241,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1206
1241
  "font-size": "10",
1207
1242
  fill: "currentColor",
1208
1243
  "fill-opacity": "0.6"
1209
- }, b(e.value), 9, Qe))), 128)),
1244
+ }, b(e.value), 9, nt))), 128)),
1210
1245
  t.xLabel ? (_(), a("text", {
1211
1246
  key: 5,
1212
1247
  x: S(Y).left + S(Z) / 2,
@@ -1214,14 +1249,14 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1214
1249
  "text-anchor": "middle",
1215
1250
  "font-size": "13",
1216
1251
  fill: "currentColor"
1217
- }, b(t.xLabel), 9, $e)) : i("", !0),
1252
+ }, b(t.xLabel), 9, rt)) : i("", !0),
1218
1253
  (_(!0), a(e, null, y(w.value, (e, t) => (_(), a("path", {
1219
1254
  key: "area" + t,
1220
1255
  d: ne(e),
1221
1256
  fill: e.color ?? "currentColor",
1222
1257
  "fill-opacity": e.opacity ?? .2,
1223
1258
  stroke: "none"
1224
- }, null, 8, et))), 128)),
1259
+ }, null, 8, it))), 128)),
1225
1260
  (_(!0), a(e, null, y(C.value, (n, r) => (_(), a(e, { key: r }, [n.line === !1 ? i("", !0) : (_(), a("path", {
1226
1261
  key: 0,
1227
1262
  d: N(n),
@@ -1230,7 +1265,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1230
1265
  "stroke-width": n.strokeWidth ?? 1.5,
1231
1266
  "stroke-opacity": n.lineOpacity ?? n.opacity ?? t.lineOpacity,
1232
1267
  "stroke-dasharray": n.dashed ? "6 3" : void 0
1233
- }, null, 8, tt)), n.dots ? (_(!0), a(e, { key: 1 }, y(P(n), (e, r) => (_(), a("circle", {
1268
+ }, null, 8, at)), n.dots ? (_(!0), a(e, { key: 1 }, y(P(n), (e, r) => (_(), a("circle", {
1234
1269
  key: r,
1235
1270
  cx: e.x,
1236
1271
  cy: e.y,
@@ -1238,14 +1273,14 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1238
1273
  fill: n.dotFill ?? n.color ?? "currentColor",
1239
1274
  "fill-opacity": n.dotOpacity ?? n.opacity ?? t.lineOpacity,
1240
1275
  stroke: n.dotStroke ?? "none"
1241
- }, null, 8, nt))), 128)) : i("", !0)], 64))), 128)),
1276
+ }, null, 8, ot))), 128)) : i("", !0)], 64))), 128)),
1242
1277
  (_(!0), a(e, null, y(t.areaSections ?? [], (t, n) => (_(), a(e, { key: "areasec" + n }, [
1243
1278
  o("path", {
1244
1279
  d: re(t),
1245
1280
  fill: t.color ?? (t.seriesIndex == null ? "#999" : C.value[t.seriesIndex]?.color ?? "currentColor"),
1246
1281
  "fill-opacity": t.opacity ?? .15,
1247
1282
  stroke: "none"
1248
- }, null, 8, rt),
1283
+ }, null, 8, st),
1249
1284
  t.seriesIndex == null ? i("", !0) : (_(), a("path", {
1250
1285
  key: 0,
1251
1286
  d: re(t, !1),
@@ -1253,7 +1288,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1253
1288
  stroke: t.color ?? C.value[t.seriesIndex]?.color ?? "currentColor",
1254
1289
  "stroke-width": t.strokeWidth ?? 2,
1255
1290
  "stroke-dasharray": t.dashed ? "6 3" : void 0
1256
- }, null, 8, it)),
1291
+ }, null, 8, ct)),
1257
1292
  t.seriesIndex == null ? (_(), a(e, { key: 1 }, [o("line", {
1258
1293
  x1: S(V)(F(t, "start")),
1259
1294
  y1: S(Y).top,
@@ -1262,7 +1297,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1262
1297
  stroke: t.color ?? "#999",
1263
1298
  "stroke-width": t.strokeWidth ?? 2,
1264
1299
  "stroke-dasharray": t.dashed ? "6 3" : void 0
1265
- }, null, 8, at), o("line", {
1300
+ }, null, 8, lt), o("line", {
1266
1301
  x1: S(V)(F(t, "end")),
1267
1302
  y1: S(Y).top,
1268
1303
  x2: S(V)(F(t, "end")),
@@ -1270,7 +1305,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1270
1305
  stroke: t.color ?? "#999",
1271
1306
  "stroke-width": t.strokeWidth ?? 2,
1272
1307
  "stroke-dasharray": t.dashed ? "6 3" : void 0
1273
- }, null, 8, ot)], 64)) : i("", !0),
1308
+ }, null, 8, ut)], 64)) : i("", !0),
1274
1309
  o("line", {
1275
1310
  x1: S(V)(F(t, "start")),
1276
1311
  y1: S(Y).top + S(Q) - 4,
@@ -1278,7 +1313,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1278
1313
  y2: S(Y).top + S(Q) + 4,
1279
1314
  stroke: "currentColor",
1280
1315
  "stroke-opacity": "0.4"
1281
- }, null, 8, st),
1316
+ }, null, 8, dt),
1282
1317
  o("line", {
1283
1318
  x1: S(V)(F(t, "end")),
1284
1319
  y1: S(Y).top + S(Q) - 4,
@@ -1286,7 +1321,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1286
1321
  y2: S(Y).top + S(Q) + 4,
1287
1322
  stroke: "currentColor",
1288
1323
  "stroke-opacity": "0.4"
1289
- }, null, 8, ct)
1324
+ }, null, 8, ft)
1290
1325
  ], 64))), 128)),
1291
1326
  R.value && S(he) !== null ? (_(), a("line", {
1292
1327
  key: 6,
@@ -1298,7 +1333,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1298
1333
  "stroke-opacity": "0.3",
1299
1334
  "stroke-dasharray": "4 2",
1300
1335
  "pointer-events": "none"
1301
- }, null, 8, lt)) : i("", !0),
1336
+ }, null, 8, pt)) : i("", !0),
1302
1337
  (_(!0), a(e, null, y(ue.value, (e, t) => (_(), a("circle", {
1303
1338
  key: "hd" + t,
1304
1339
  cx: e.x,
@@ -1308,7 +1343,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1308
1343
  stroke: "var(--color-bg-0, #fff)",
1309
1344
  "stroke-width": "2",
1310
1345
  "pointer-events": "none"
1311
- }, null, 8, ut))), 128)),
1346
+ }, null, 8, mt))), 128)),
1312
1347
  R.value ? (_(), a("rect", d({
1313
1348
  key: 7,
1314
1349
  x: S(Y).left,
@@ -1320,8 +1355,8 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1320
1355
  cursor: "crosshair",
1321
1356
  "touch-action": "none"
1322
1357
  }
1323
- }, te(S(ve), !0)), null, 16, dt)) : i("", !0),
1324
- t.annotations && t.annotations.length > 0 ? (_(), r(S(Fe), {
1358
+ }, te(S(ve), !0)), null, 16, ht)) : i("", !0),
1359
+ t.annotations && t.annotations.length > 0 ? (_(), r(S(ze), {
1325
1360
  key: 8,
1326
1361
  annotations: t.annotations,
1327
1362
  project: K,
@@ -1330,45 +1365,45 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1330
1365
  (_(!0), a(e, null, y(ie.value.labels, (e, t) => (_(), a("g", { key: "seclab" + t }, [
1331
1366
  o("circle", {
1332
1367
  cx: e.cx - e.textWidth / 2 - 2,
1333
- cy: I.value + e.row * vt + 4,
1368
+ cy: I.value + e.row * St + 4,
1334
1369
  r: "4",
1335
1370
  fill: e.color,
1336
1371
  "fill-opacity": e.fillOpacity,
1337
1372
  stroke: e.color,
1338
1373
  "stroke-width": "1.5"
1339
- }, null, 8, ft),
1374
+ }, null, 8, gt),
1340
1375
  e.labelText ? (_(), a("text", {
1341
1376
  key: 0,
1342
1377
  x: e.cx - e.textWidth / 2 + 8,
1343
- y: I.value + e.row * vt + 8,
1378
+ y: I.value + e.row * St + 8,
1344
1379
  "font-size": "11",
1345
1380
  "font-weight": "600",
1346
1381
  fill: e.color
1347
- }, b(e.labelText), 9, pt)) : i("", !0),
1382
+ }, b(e.labelText), 9, _t)) : i("", !0),
1348
1383
  e.descText ? (_(), a("text", {
1349
1384
  key: 1,
1350
1385
  x: e.cx - e.textWidth / 2 + 8,
1351
- y: I.value + e.row * vt + 22,
1386
+ y: I.value + e.row * St + 22,
1352
1387
  "font-size": "11",
1353
1388
  fill: "currentColor",
1354
1389
  "fill-opacity": "0.6"
1355
- }, b(e.descText), 9, mt)) : i("", !0)
1390
+ }, b(e.descText), 9, vt)) : i("", !0)
1356
1391
  ]))), 128))
1357
- ], 8, Be)),
1392
+ ], 8, We)),
1358
1393
  R.value && S(he) !== null && U.value ? (_(), a("div", {
1359
1394
  key: 1,
1360
1395
  ref_key: "tooltipRef",
1361
- ref: _e,
1396
+ ref: ge,
1362
1397
  class: "chart-tooltip-content",
1363
1398
  style: m({
1364
1399
  position: "absolute",
1365
1400
  top: "0",
1366
1401
  left: "0",
1367
1402
  willChange: "transform",
1368
- transform: S($) ? `translate3d(${S($).left}px, ${S($).top}px, 0) translateY(-50%)` : "translateY(-50%)",
1369
- visibility: S($) ? "visible" : "hidden"
1403
+ transform: S(_e) ? `translate3d(${S(_e).left}px, ${S(_e).top}px, 0) translateY(-50%)` : "translateY(-50%)",
1404
+ visibility: S(_e) ? "visible" : "hidden"
1370
1405
  })
1371
- }, [ee(n.$slots, "tooltip", p(u(U.value)), () => [o("div", ht, [U.value.xLabel ? (_(), a("div", gt, b(U.value.xLabel), 1)) : i("", !0), (_(!0), a(e, null, y(U.value.values, (e) => (_(), a("div", {
1406
+ }, [ee(n.$slots, "tooltip", p(u(U.value)), () => [o("div", yt, [U.value.xLabel ? (_(), a("div", bt, b(U.value.xLabel), 1)) : i("", !0), (_(!0), a(e, null, y(U.value.values, (e) => (_(), a("div", {
1372
1407
  key: e.seriesIndex,
1373
1408
  class: "line-chart-tooltip-row"
1374
1409
  }, [o("span", {
@@ -1380,38 +1415,38 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1380
1415
  class: "line-chart-download-link",
1381
1416
  href: S(xe),
1382
1417
  download: `${S(Se)()}.csv`
1383
- }, b(S(be)), 9, _t)) : i("", !0)
1418
+ }, b(S(be)), 9, xt)) : i("", !0)
1384
1419
  ], 512));
1385
1420
  }
1386
- }), [["__scopeId", "data-v-ebe2731e"]]), Ct = ["width", "height"], wt = ["x"], Tt = { key: 1 }, Et = [
1421
+ }), [["__scopeId", "data-v-ebe2731e"]]), Dt = ["width", "height"], Ot = ["x"], kt = { key: 1 }, At = [
1387
1422
  "x",
1388
1423
  "y",
1389
1424
  "fill"
1390
- ], Dt = ["x", "y"], Ot = [
1425
+ ], jt = ["x", "y"], Mt = [
1391
1426
  "x1",
1392
1427
  "y1",
1393
1428
  "x2",
1394
1429
  "y2"
1395
- ], kt = [
1430
+ ], Nt = [
1396
1431
  "x1",
1397
1432
  "y1",
1398
1433
  "x2",
1399
1434
  "y2"
1400
- ], At = [
1435
+ ], Pt = [
1401
1436
  "x1",
1402
1437
  "y1",
1403
1438
  "x2",
1404
1439
  "y2"
1405
- ], jt = [
1440
+ ], Ft = [
1406
1441
  "x",
1407
1442
  "y",
1408
1443
  "width",
1409
1444
  "height"
1410
- ], Mt = ["x", "y"], Nt = ["x", "y"], Pt = ["transform"], Ft = [
1445
+ ], It = ["x", "y"], Lt = ["x", "y"], Rt = ["transform"], zt = [
1411
1446
  "x",
1412
1447
  "y",
1413
1448
  "text-anchor"
1414
- ], It = ["x", "y"], Lt = ["x", "y"], Rt = [
1449
+ ], Bt = ["x", "y"], Vt = ["x", "y"], Ht = [
1415
1450
  "data-category",
1416
1451
  "data-series",
1417
1452
  "x",
@@ -1420,15 +1455,15 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1420
1455
  "height",
1421
1456
  "fill",
1422
1457
  "fill-opacity"
1423
- ], zt = [
1458
+ ], Ut = [
1424
1459
  "x",
1425
1460
  "y",
1426
1461
  "width",
1427
1462
  "height"
1428
- ], Bt = { class: "bar-chart-tooltip" }, Vt = {
1463
+ ], Wt = { class: "bar-chart-tooltip" }, Gt = {
1429
1464
  key: 0,
1430
1465
  class: "bar-chart-tooltip-label"
1431
- }, Ht = ["href", "download"], Ut = /* @__PURE__ */ B(/* @__PURE__ */ l({
1466
+ }, Kt = ["href", "download"], qt = /* @__PURE__ */ B(/* @__PURE__ */ l({
1432
1467
  __name: "BarChart",
1433
1468
  props: {
1434
1469
  data: {},
@@ -1594,7 +1629,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1594
1629
  function ie(e) {
1595
1630
  return re[e % re.length];
1596
1631
  }
1597
- let ae = ze(() => l.tooltipValueFormat, () => l.valueTickFormat), oe = n(() => {
1632
+ let ae = Ue(() => l.tooltipValueFormat, () => l.valueTickFormat), oe = n(() => {
1598
1633
  let { min: e, max: t } = E.value, n = (e) => l.valueTickFormat ? l.valueTickFormat(e) : W(e);
1599
1634
  if (e === t) return [{
1600
1635
  value: n(e),
@@ -1637,7 +1672,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1637
1672
  label: e.legend,
1638
1673
  data: e.data
1639
1674
  }));
1640
- return _e(w.value, e);
1675
+ return be(w.value, e);
1641
1676
  }
1642
1677
  let L = n(() => !!l.tooltipData || !!l.tooltipTrigger);
1643
1678
  function R(e, t) {
@@ -1659,7 +1694,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1659
1694
  let i = T.value ? e - n.left - K.value.left : t - n.top - K.value.top;
1660
1695
  return Math.max(0, Math.min(r - 1, Math.floor(i / k.value)));
1661
1696
  }
1662
- let { containerRef: B, svgRef: H, width: ue, height: U, padding: K, legendY: de, innerW: q, innerH: J, bounds: fe, hoverIndex: pe, tooltipRef: Y, tooltipPos: X, tooltipHandlers: Z, menuItems: Q, downloadLinkText: me, csvHref: he, menuFilename: ge } = Re({
1697
+ let { containerRef: B, svgRef: H, width: ue, height: U, padding: K, legendY: de, innerW: q, innerH: J, bounds: fe, hoverIndex: pe, tooltipRef: Y, tooltipPos: X, tooltipHandlers: Z, menuItems: Q, downloadLinkText: me, csvHref: he, menuFilename: ge } = He({
1663
1698
  width: () => l.width,
1664
1699
  height: () => l.height,
1665
1700
  title: () => l.title,
@@ -1677,7 +1712,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1677
1712
  getCsv: ce,
1678
1713
  pointerToIndex: z,
1679
1714
  onHover: (e) => f("hover", e)
1680
- }), $ = n(() => {
1715
+ }), _e = n(() => {
1681
1716
  let e = pe.value;
1682
1717
  if (e !== null) return w.value[e];
1683
1718
  }), ve = n(() => {
@@ -1692,7 +1727,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1692
1727
  })),
1693
1728
  data: l.tooltipData?.[e] ?? null
1694
1729
  };
1695
- }), ye = n(() => {
1730
+ }), $ = n(() => {
1696
1731
  let e = pe.value;
1697
1732
  if (e === null) return null;
1698
1733
  let t = M(e);
@@ -1731,19 +1766,19 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1731
1766
  "font-size": "14",
1732
1767
  "font-weight": "600",
1733
1768
  fill: "currentColor"
1734
- }, b(t.title), 9, wt)) : i("", !0),
1735
- se.value.length > 0 ? (_(), a("g", Tt, [(_(!0), a(e, null, y(se.value, (t, n) => (_(), a(e, { key: "ileg" + n }, [o("rect", {
1769
+ }, b(t.title), 9, Ot)) : i("", !0),
1770
+ se.value.length > 0 ? (_(), a("g", kt, [(_(!0), a(e, null, y(se.value, (t, n) => (_(), a(e, { key: "ileg" + n }, [o("rect", {
1736
1771
  x: S(K).left + n * 120,
1737
1772
  y: S(de) - 5,
1738
1773
  width: "12",
1739
1774
  height: "10",
1740
1775
  fill: t.color
1741
- }, null, 8, Et), o("text", {
1776
+ }, null, 8, At), o("text", {
1742
1777
  x: S(K).left + n * 120 + 18,
1743
1778
  y: S(de) + 4,
1744
1779
  "font-size": "11",
1745
1780
  fill: "currentColor"
1746
- }, b(t.label), 9, Dt)], 64))), 128))])) : i("", !0),
1781
+ }, b(t.label), 9, jt)], 64))), 128))])) : i("", !0),
1747
1782
  o("line", {
1748
1783
  x1: S(V)(S(K).left),
1749
1784
  y1: S(V)(S(K).top),
@@ -1751,7 +1786,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1751
1786
  y2: S(V)(S(K).top + S(J)),
1752
1787
  stroke: "currentColor",
1753
1788
  "stroke-opacity": "0.3"
1754
- }, null, 8, Ot),
1789
+ }, null, 8, Mt),
1755
1790
  o("line", {
1756
1791
  x1: S(V)(S(K).left),
1757
1792
  y1: S(V)(S(K).top + S(J)),
@@ -1759,7 +1794,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1759
1794
  y2: S(V)(S(K).top + S(J)),
1760
1795
  stroke: "currentColor",
1761
1796
  "stroke-opacity": "0.3"
1762
- }, null, 8, kt),
1797
+ }, null, 8, Nt),
1763
1798
  t.valueGrid ? (_(!0), a(e, { key: 2 }, y(oe.value, (e, t) => (_(), a("line", {
1764
1799
  key: "vg" + t,
1765
1800
  x1: T.value ? S(K).left : e.pos,
@@ -1768,17 +1803,17 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1768
1803
  y2: T.value ? e.pos : S(K).top + S(J),
1769
1804
  stroke: "currentColor",
1770
1805
  "stroke-opacity": "0.1"
1771
- }, null, 8, At))), 128)) : i("", !0),
1772
- ye.value && L.value ? (_(), a("rect", {
1806
+ }, null, 8, Pt))), 128)) : i("", !0),
1807
+ $.value && L.value ? (_(), a("rect", {
1773
1808
  key: 3,
1774
- x: ye.value.x,
1775
- y: ye.value.y,
1776
- width: ye.value.w,
1777
- height: ye.value.h,
1809
+ x: $.value.x,
1810
+ y: $.value.y,
1811
+ width: $.value.w,
1812
+ height: $.value.h,
1778
1813
  fill: "currentColor",
1779
1814
  "fill-opacity": "0.06",
1780
1815
  "pointer-events": "none"
1781
- }, null, 8, jt)) : i("", !0),
1816
+ }, null, 8, Ft)) : i("", !0),
1782
1817
  T.value ? (_(!0), a(e, { key: 4 }, y(oe.value, (e, t) => (_(), a("text", {
1783
1818
  key: "vt" + t,
1784
1819
  "data-testid": "value-tick",
@@ -1789,7 +1824,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1789
1824
  "font-size": "10",
1790
1825
  fill: "currentColor",
1791
1826
  "fill-opacity": "0.6"
1792
- }, b(e.value), 9, Mt))), 128)) : (_(!0), a(e, { key: 5 }, y(oe.value, (e, t) => (_(), a("text", {
1827
+ }, b(e.value), 9, It))), 128)) : (_(!0), a(e, { key: 5 }, y(oe.value, (e, t) => (_(), a("text", {
1793
1828
  key: "vt" + t,
1794
1829
  "data-testid": "value-tick",
1795
1830
  x: e.pos,
@@ -1798,7 +1833,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1798
1833
  "font-size": "10",
1799
1834
  fill: "currentColor",
1800
1835
  "fill-opacity": "0.6"
1801
- }, b(e.value), 9, Nt))), 128)),
1836
+ }, b(e.value), 9, Lt))), 128)),
1802
1837
  t.yLabel ? (_(), a("text", {
1803
1838
  key: 6,
1804
1839
  x: 0,
@@ -1807,7 +1842,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1807
1842
  "text-anchor": "middle",
1808
1843
  "font-size": "13",
1809
1844
  fill: "currentColor"
1810
- }, b(t.yLabel), 9, Pt)) : i("", !0),
1845
+ }, b(t.yLabel), 9, Rt)) : i("", !0),
1811
1846
  T.value ? (_(!0), a(e, { key: 7 }, y(I.value, (e, t) => (_(), a("text", {
1812
1847
  key: "ct" + t,
1813
1848
  "data-testid": "category-tick",
@@ -1817,7 +1852,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1817
1852
  "font-size": "10",
1818
1853
  fill: "currentColor",
1819
1854
  "fill-opacity": "0.6"
1820
- }, b(e.label), 9, Ft))), 128)) : (_(!0), a(e, { key: 8 }, y(I.value, (e, t) => (_(), a("text", {
1855
+ }, b(e.label), 9, zt))), 128)) : (_(!0), a(e, { key: 8 }, y(I.value, (e, t) => (_(), a("text", {
1821
1856
  key: "ct" + t,
1822
1857
  "data-testid": "category-tick",
1823
1858
  x: S(K).left - 6,
@@ -1827,7 +1862,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1827
1862
  "font-size": "10",
1828
1863
  fill: "currentColor",
1829
1864
  "fill-opacity": "0.6"
1830
- }, b(e.label), 9, It))), 128)),
1865
+ }, b(e.label), 9, Bt))), 128)),
1831
1866
  t.xLabel ? (_(), a("text", {
1832
1867
  key: 9,
1833
1868
  x: S(K).left + S(q) / 2,
@@ -1835,7 +1870,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1835
1870
  "text-anchor": "middle",
1836
1871
  "font-size": "13",
1837
1872
  fill: "currentColor"
1838
- }, b(t.xLabel), 9, Lt)) : i("", !0),
1873
+ }, b(t.xLabel), 9, Vt)) : i("", !0),
1839
1874
  (_(!0), a(e, null, y(F.value, (e, t) => (_(), a("rect", {
1840
1875
  key: "bar" + t,
1841
1876
  "data-testid": "bar",
@@ -1847,7 +1882,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1847
1882
  height: e.h,
1848
1883
  fill: e.color,
1849
1884
  "fill-opacity": e.opacity
1850
- }, null, 8, Rt))), 128)),
1885
+ }, null, 8, Ht))), 128)),
1851
1886
  L.value ? (_(), a("rect", d({
1852
1887
  key: 10,
1853
1888
  x: S(K).left,
@@ -1859,14 +1894,14 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1859
1894
  cursor: "crosshair",
1860
1895
  "touch-action": "none"
1861
1896
  }
1862
- }, te(S(Z), !0)), null, 16, zt)) : i("", !0),
1863
- t.annotations && t.annotations.length > 0 ? (_(), r(S(Fe), {
1897
+ }, te(S(Z), !0)), null, 16, Ut)) : i("", !0),
1898
+ t.annotations && t.annotations.length > 0 ? (_(), r(S(ze), {
1864
1899
  key: 11,
1865
1900
  annotations: t.annotations,
1866
1901
  project: R,
1867
1902
  bounds: S(fe)
1868
1903
  }, null, 8, ["annotations", "bounds"])) : i("", !0)
1869
- ], 8, Ct)),
1904
+ ], 8, Dt)),
1870
1905
  L.value && S(pe) !== null && ve.value ? (_(), a("div", {
1871
1906
  key: 1,
1872
1907
  ref_key: "tooltipRef",
@@ -1880,7 +1915,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1880
1915
  transform: S(X) ? `translate3d(${S(X).left}px, ${S(X).top}px, 0) translateY(-50%)` : "translateY(-50%)",
1881
1916
  visibility: S(X) ? "visible" : "hidden"
1882
1917
  })
1883
- }, [ee(n.$slots, "tooltip", p(u(ve.value)), () => [o("div", Bt, [$.value ? (_(), a("div", Vt, b($.value), 1)) : i("", !0), (_(!0), a(e, null, y(ve.value.values, (e) => (_(), a("div", {
1918
+ }, [ee(n.$slots, "tooltip", p(u(ve.value)), () => [o("div", Wt, [_e.value ? (_(), a("div", Gt, b(_e.value), 1)) : i("", !0), (_(!0), a(e, null, y(ve.value.values, (e) => (_(), a("div", {
1884
1919
  key: e.seriesIndex,
1885
1920
  class: "bar-chart-tooltip-row"
1886
1921
  }, [o("span", {
@@ -1892,10 +1927,10 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
1892
1927
  class: "bar-chart-download-link",
1893
1928
  href: S(he),
1894
1929
  download: `${S(ge)()}.csv`
1895
- }, b(S(me)), 9, Ht)) : i("", !0)
1930
+ }, b(S(me)), 9, Kt)) : i("", !0)
1896
1931
  ], 512));
1897
1932
  }
1898
- }), [["__scopeId", "data-v-690ebb3c"]]), Wt = {
1933
+ }), [["__scopeId", "data-v-690ebb3c"]]), Jt = {
1899
1934
  "01013": "010259",
1900
1935
  "01015": "010177",
1901
1936
  "01029": "010177",
@@ -5056,7 +5091,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
5056
5091
  51019: "510014",
5057
5092
  "02158": "020820",
5058
5093
  46102: "460957"
5059
- }, Gt = {
5094
+ }, Yt = {
5060
5095
  "010259": "Butler, AL",
5061
5096
  "010177": "Calhoun (Anniston), AL - Cleburne, AL",
5062
5097
  "010172": "Chambers, AL - Randolph, AL",
@@ -6006,7 +6041,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6006
6041
  560775: "Teton, WY - Lincoln, WY",
6007
6042
  560792: "Uinta, WY",
6008
6043
  560804: "Weston, WY"
6009
- }, Kt = {
6044
+ }, Xt = {
6010
6045
  ref: "root",
6011
6046
  class: "chart-tooltip-content",
6012
6047
  style: {
@@ -6018,7 +6053,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6018
6053
  "pointer-events": "none",
6019
6054
  transform: "translateY(-50%)"
6020
6055
  }
6021
- }, qt = /* @__PURE__ */ l({
6056
+ }, Zt = /* @__PURE__ */ l({
6022
6057
  __name: "ChoroplethTooltip",
6023
6058
  setup(e, { expose: n }) {
6024
6059
  let a = v(null), s = w("root");
@@ -6029,24 +6064,24 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6029
6064
  getEl() {
6030
6065
  return s.value;
6031
6066
  }
6032
- }), (e, n) => (_(), r(t, { to: "body" }, [o("div", Kt, [a.value ? ee(e.$slots, "default", p(d({ key: 0 }, a.value))) : i("", !0)], 512)]));
6067
+ }), (e, n) => (_(), r(t, { to: "body" }, [o("div", Xt, [a.value ? ee(e.$slots, "default", p(d({ key: 0 }, a.value))) : i("", !0)], 512)]));
6033
6068
  }
6034
- }), Jt = {
6069
+ }), Qt = {
6035
6070
  key: 1,
6036
6071
  class: "choropleth-header"
6037
- }, Yt = {
6072
+ }, $t = {
6038
6073
  key: 0,
6039
6074
  class: "choropleth-title"
6040
- }, Xt = {
6075
+ }, en = {
6041
6076
  key: 1,
6042
6077
  class: "choropleth-legend"
6043
- }, Zt = {
6078
+ }, tn = {
6044
6079
  key: 0,
6045
6080
  class: "choropleth-legend-title"
6046
- }, Qt = {
6081
+ }, nn = {
6047
6082
  key: 2,
6048
6083
  class: "choropleth-legend-continuous"
6049
- }, $t = { class: "choropleth-legend-ticks" }, en = ["viewBox"], tn = ["innerHTML"], nn = "http://www.w3.org/2000/svg", rn = 450, an = 1e3, on = /* @__PURE__ */ B(/* @__PURE__ */ l({
6084
+ }, rn = { class: "choropleth-legend-ticks" }, an = ["viewBox"], on = ["innerHTML"], sn = "http://www.w3.org/2000/svg", cn = 450, ln = 1e3, un = /* @__PURE__ */ B(/* @__PURE__ */ l({
6050
6085
  __name: "ChoroplethMap",
6051
6086
  props: {
6052
6087
  topology: {},
@@ -6107,14 +6142,14 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6107
6142
  at();
6108
6143
  }
6109
6144
  h(() => {
6110
- me(), fe(), dt(), ve(), Xe(), window.addEventListener("scroll", X, {
6145
+ Z(), fe(), dt(), $(), Xe(), window.addEventListener("scroll", X, {
6111
6146
  passive: !0,
6112
6147
  capture: !0
6113
6148
  }), window.addEventListener("resize", X, { passive: !0 });
6114
6149
  }), g(() => {
6115
- H?.disconnect(), J && cancelAnimationFrame(J), he(), Y(), window.removeEventListener("scroll", X, { capture: !0 }), window.removeEventListener("resize", X);
6150
+ H?.disconnect(), J && cancelAnimationFrame(J), Q(), Y(), window.removeEventListener("scroll", X, { capture: !0 }), window.removeEventListener("resize", X);
6116
6151
  });
6117
- function me() {
6152
+ function Z() {
6118
6153
  if (!w.value || !D.value) return;
6119
6154
  let e = oe(w.value), t = Math.max(12, l.focusZoomLevel);
6120
6155
  G = ie().scaleExtent([1, t]).on("start", () => {
@@ -6135,10 +6170,10 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6135
6170
  return (!e.ctrlKey || e.type === "wheel") && !e.button;
6136
6171
  }), e.call(G);
6137
6172
  }
6138
- function he() {
6173
+ function Q() {
6139
6174
  w.value && G && (oe(w.value).on(".zoom", null), G = null);
6140
6175
  }
6141
- function ge(e) {
6176
+ function me(e) {
6142
6177
  let t = Pe.value, n = Ae.value, r = [];
6143
6178
  for (let i of e) {
6144
6179
  let e = i.geoType ?? l.geoType, a = t.get(e);
@@ -6157,15 +6192,15 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6157
6192
  }
6158
6193
  return r;
6159
6194
  }
6160
- function _e(e) {
6195
+ function he(e) {
6161
6196
  let t = /* @__PURE__ */ new Set();
6162
- for (let n of ge(e)) n.geoType === l.geoType && t.add(String(n.feature.id));
6197
+ for (let n of me(e)) n.geoType === l.geoType && t.add(String(n.feature.id));
6163
6198
  return t;
6164
6199
  }
6165
- let $ = !1;
6166
- function ve() {
6200
+ let ve = !1;
6201
+ function $() {
6167
6202
  if (!w.value || !G) return;
6168
- let e = ge(Ne.value), t = e.filter((e) => e.geoType === l.geoType), n = e.filter((e) => e.geoType !== l.geoType), r = /* @__PURE__ */ new Map();
6203
+ let e = me(Ne.value), t = e.filter((e) => e.geoType === l.geoType), n = e.filter((e) => e.geoType !== l.geoType), r = /* @__PURE__ */ new Map();
6169
6204
  for (let e of t) {
6170
6205
  let t = N.get(String(e.feature.id));
6171
6206
  t && r.set(t, e.item.style ?? "solid");
@@ -6175,13 +6210,13 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6175
6210
  R.clear();
6176
6211
  for (let [e, t] of r) R.set(e, t);
6177
6212
  if (ye(n), e.length === 0) {
6178
- $ = !0, at();
6213
+ ve = !0, at();
6179
6214
  return;
6180
6215
  }
6181
6216
  let i = oe(w.value);
6182
6217
  i.interrupt();
6183
- let a = $;
6184
- $ = !0;
6218
+ let a = ve;
6219
+ ve = !0;
6185
6220
  let [[o, s], [c, u]] = Oe.value.bounds({
6186
6221
  type: "FeatureCollection",
6187
6222
  features: e.map((e) => e.feature)
@@ -6192,7 +6227,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6192
6227
  let n = t.getBoundingClientRect();
6193
6228
  Qe(e, n.left + n.width / 2, n.top + n.height / 2);
6194
6229
  };
6195
- a ? (et(), i.transition().duration(rn).call(G.transform, m).on("end", g)) : (G.transform(i, m), g());
6230
+ a ? (et(), i.transition().duration(cn).call(G.transform, m).on("end", g)) : (G.transform(i, m), g());
6196
6231
  }
6197
6232
  function ye(e) {
6198
6233
  let t = k.value;
@@ -6202,29 +6237,29 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6202
6237
  let r = Oe.value, i = ke.value + 1.5;
6203
6238
  for (let { item: n, feature: a, key: o } of e) {
6204
6239
  let e = z.get(o);
6205
- e || (e = document.createElementNS(nn, "path"), e.setAttribute("d", r(a) ?? ""), e.setAttribute("fill", "none"), e.setAttribute("pointer-events", "none"), e.setAttribute("vector-effect", "non-scaling-stroke"), e.setAttribute("stroke-linejoin", "round"), e.setAttribute("class", "focus-overlay"), t.appendChild(e), z.set(o, e)), e.setAttribute("stroke", n.stroke ?? "#fff"), e.setAttribute("stroke-width", String(i)), tt(e, n.style);
6240
+ e || (e = document.createElementNS(sn, "path"), e.setAttribute("d", r(a) ?? ""), e.setAttribute("fill", "none"), e.setAttribute("pointer-events", "none"), e.setAttribute("vector-effect", "non-scaling-stroke"), e.setAttribute("stroke-linejoin", "round"), e.setAttribute("class", "focus-overlay"), t.appendChild(e), z.set(o, e)), e.setAttribute("stroke", n.stroke ?? "#fff"), e.setAttribute("stroke-width", String(i)), tt(e, n.style);
6206
6241
  }
6207
6242
  }
6208
6243
  function be() {
6209
6244
  if (!w.value || !G) return;
6210
6245
  Ne.value.length > 0 && d("update:focus", null);
6211
6246
  let e = oe(w.value);
6212
- e.interrupt(), et(), e.transition().duration(rn).call(G.transform, ae);
6247
+ e.interrupt(), et(), e.transition().duration(cn).call(G.transform, ae);
6213
6248
  }
6214
6249
  T(() => l.focusZoomLevel, () => {
6215
- G && G.scaleExtent([1, Math.max(12, l.focusZoomLevel)]), ve();
6250
+ G && G.scaleExtent([1, Math.max(12, l.focusZoomLevel)]), $();
6216
6251
  });
6217
- let xe = n(() => l.width && l.height ? l.height / l.width : .625), Se = n(() => an), Ce = n(() => an * xe.value), we = n(() => {
6252
+ let xe = n(() => l.width && l.height ? l.height / l.width : .625), Se = n(() => ln), Ce = n(() => ln * xe.value), we = n(() => {
6218
6253
  let e = x(l.topology), t = e.objects.counties.geometries, n = /* @__PURE__ */ new Map();
6219
6254
  for (let e of t) {
6220
- let t = Wt[String(e.id).padStart(5, "0")];
6255
+ let t = Jt[String(e.id).padStart(5, "0")];
6221
6256
  t && (n.has(t) || n.set(t, []), n.get(t).push(e));
6222
6257
  }
6223
6258
  let r = [];
6224
6259
  for (let [t, i] of n) r.push({
6225
6260
  type: "Feature",
6226
6261
  id: t,
6227
- properties: { name: Gt[t] ?? t },
6262
+ properties: { name: Yt[t] ?? t },
6228
6263
  geometry: se(e, i)
6229
6264
  });
6230
6265
  return {
@@ -6255,7 +6290,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6255
6290
  function je(e) {
6256
6291
  let t = l.dataGeoType;
6257
6292
  if (!t || t === l.geoType) return e;
6258
- if (l.geoType === "counties" && t === "hsas") return Wt[e];
6293
+ if (l.geoType === "counties" && t === "hsas") return Jt[e];
6259
6294
  if (l.geoType === "counties" && t === "states" || l.geoType === "hsas" && t === "states") return e.slice(0, 2);
6260
6295
  }
6261
6296
  let Me = n(() => {
@@ -6431,7 +6466,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6431
6466
  name: r.name,
6432
6467
  value: r.value
6433
6468
  };
6434
- e.type === "click" ? (d("stateClick", i), d("update:focus", _e(Ne.value).has(r.id) ? null : r.id)) : e.type === "mouseover" && (it(N.get(n)), M.value && Qe(n, t.clientX, t.clientY), d("stateHover", i));
6469
+ e.type === "click" ? (d("stateClick", i), d("update:focus", he(Ne.value).has(r.id) ? null : r.id)) : e.type === "mouseover" && (it(N.get(n)), M.value && Qe(n, t.clientX, t.clientY), d("stateHover", i));
6435
6470
  }
6436
6471
  function ct(e) {
6437
6472
  B || $e(e.clientX, e.clientY);
@@ -6441,7 +6476,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6441
6476
  t && D.value?.contains(t) || at();
6442
6477
  }
6443
6478
  function ut(e) {
6444
- let t = document.createElementNS(nn, "path");
6479
+ let t = document.createElementNS(sn, "path");
6445
6480
  return e && t.setAttribute("d", e), t;
6446
6481
  }
6447
6482
  function dt() {
@@ -6454,7 +6489,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6454
6489
  for (let e of r) {
6455
6490
  let t = String(e.id), r = qe(e), c = Ge(t), l = ut(n(e));
6456
6491
  if (l.setAttribute("class", "state-path"), l.setAttribute("data-feat-id", t), l.setAttribute("fill", Ke(t)), l.setAttribute("stroke", i), l.setAttribute("stroke-width", a), l.setAttribute("vector-effect", "non-scaling-stroke"), o) {
6457
- let e = document.createElementNS(nn, "title");
6492
+ let e = document.createElementNS(sn, "title");
6458
6493
  e.textContent = Ye(r, c), l.appendChild(e);
6459
6494
  }
6460
6495
  s.appendChild(l), N.set(t, l), P.set(t, {
@@ -6529,12 +6564,12 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6529
6564
  return [{
6530
6565
  label: "Save as SVG",
6531
6566
  action: () => {
6532
- w.value && Z(w.value, e);
6567
+ w.value && ge(w.value, e);
6533
6568
  }
6534
6569
  }, {
6535
6570
  label: "Save as PNG",
6536
6571
  action: () => {
6537
- w.value && Q(w.value, e);
6572
+ w.value && _e(w.value, e);
6538
6573
  }
6539
6574
  }];
6540
6575
  });
@@ -6543,7 +6578,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6543
6578
  l.colorScale,
6544
6579
  l.noDataColor,
6545
6580
  l.dataGeoType
6546
- ], () => ft()), T(() => [l.strokeColor, ke.value], () => pt()), T(() => [Ne.value, Oe.value], () => ve(), { flush: "post" }), (n, c) => (_(), a("div", {
6581
+ ], () => ft()), T(() => [l.strokeColor, ke.value], () => pt()), T(() => [Ne.value, Oe.value], () => $(), { flush: "post" }), (n, c) => (_(), a("div", {
6547
6582
  ref_key: "containerRef",
6548
6583
  ref: S,
6549
6584
  class: f(["choropleth-wrapper", { pannable: t.pan }])
@@ -6552,16 +6587,16 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6552
6587
  key: 0,
6553
6588
  items: St.value
6554
6589
  }, null, 8, ["items"])) : i("", !0),
6555
- t.title || ht.value ? (_(), a("div", Jt, [t.title ? (_(), a("div", Yt, b(t.title), 1)) : i("", !0), ht.value ? (_(), a("div", Xt, [t.legendTitle ? (_(), a("span", Zt, b(t.legendTitle), 1)) : i("", !0), Le.value || Re.value ? (_(!0), a(e, { key: 1 }, y(bt.value, (e) => (_(), a("span", {
6590
+ t.title || ht.value ? (_(), a("div", Qt, [t.title ? (_(), a("div", $t, b(t.title), 1)) : i("", !0), ht.value ? (_(), a("div", en, [t.legendTitle ? (_(), a("span", tn, b(t.legendTitle), 1)) : i("", !0), Le.value || Re.value ? (_(!0), a(e, { key: 1 }, y(bt.value, (e) => (_(), a("span", {
6556
6591
  key: e.key,
6557
6592
  class: "choropleth-legend-item"
6558
6593
  }, [o("span", {
6559
6594
  class: "choropleth-legend-swatch",
6560
6595
  style: m({ background: e.color })
6561
- }, null, 4), s(" " + b(e.label), 1)]))), 128)) : (_(), a("div", Qt, [o("div", {
6596
+ }, null, 4), s(" " + b(e.label), 1)]))), 128)) : (_(), a("div", nn, [o("div", {
6562
6597
  class: "choropleth-legend-gradient",
6563
6598
  style: m({ background: xt.value })
6564
- }, null, 4), o("div", $t, [(_(!0), a(e, null, y(yt.value, (e) => (_(), a("span", {
6599
+ }, null, 4), o("div", rn, [(_(!0), a(e, null, y(yt.value, (e) => (_(), a("span", {
6565
6600
  key: e.value,
6566
6601
  style: m({ left: e.pct + "%" })
6567
6602
  }, b(e.value), 5))), 128))])]))])) : i("", !0)])) : i("", !0),
@@ -6579,7 +6614,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6579
6614
  }, null, 512), o("g", {
6580
6615
  ref_key: "overlayGroupRef",
6581
6616
  ref: k
6582
- }, null, 512)], 512)], 8, en)),
6617
+ }, null, 512)], 512)], 8, an)),
6583
6618
  K.value ? (_(), a("button", {
6584
6619
  key: 2,
6585
6620
  type: "button",
@@ -6587,7 +6622,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6587
6622
  "aria-label": "Reset zoom",
6588
6623
  onClick: be
6589
6624
  }, " Reset ")) : i("", !0),
6590
- M.value ? (_(), r(qt, {
6625
+ M.value ? (_(), r(Zt, {
6591
6626
  key: 3,
6592
6627
  ref_key: "tooltipChildRef",
6593
6628
  ref: A
@@ -6595,12 +6630,12 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6595
6630
  default: E((r) => [ee(n.$slots, "tooltip", p(u(te(r))), () => [t.tooltipFormat ? (_(), a("span", {
6596
6631
  key: 0,
6597
6632
  innerHTML: t.tooltipFormat(r)
6598
- }, null, 8, tn)) : r.value == null ? (_(), a(e, { key: 1 }, [s(b(r.name), 1)], 64)) : (_(), a(e, { key: 2 }, [s(b(r.name) + ": " + b(Je(r.value)), 1)], 64))], !0)]),
6633
+ }, null, 8, on)) : r.value == null ? (_(), a(e, { key: 1 }, [s(b(r.name), 1)], 64)) : (_(), a(e, { key: 2 }, [s(b(r.name) + ": " + b(Je(r.value)), 1)], 64))], !0)]),
6599
6634
  _: 3
6600
6635
  }, 512)) : i("", !0)
6601
6636
  ], 2));
6602
6637
  }
6603
- }), [["__scopeId", "data-v-f0f75b22"]]), sn = /* @__PURE__ */ B(/* @__PURE__ */ l({
6638
+ }), [["__scopeId", "data-v-f0f75b22"]]), dn = /* @__PURE__ */ B(/* @__PURE__ */ l({
6604
6639
  __name: "ChartTooltip",
6605
6640
  props: {
6606
6641
  x: {},
@@ -6651,7 +6686,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6651
6686
  _: 3
6652
6687
  }, 8, ["open"])) : i("", !0);
6653
6688
  }
6654
- }), [["__scopeId", "data-v-44377f70"]]), cn = { class: "TableWrapper" }, ln = /* @__PURE__ */ B(/* @__PURE__ */ l({
6689
+ }), [["__scopeId", "data-v-44377f70"]]), fn = { class: "TableWrapper" }, pn = /* @__PURE__ */ B(/* @__PURE__ */ l({
6655
6690
  __name: "DataTable",
6656
6691
  props: {
6657
6692
  data: {},
@@ -6736,7 +6771,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6736
6771
  }
6737
6772
  let S = n(() => [{
6738
6773
  label: c.downloadMenuLink,
6739
- action: () => me(x(), ee())
6774
+ action: () => ve(x(), ee())
6740
6775
  }]), C = n(() => !!c.menu);
6741
6776
  return (n, s) => (_(), a("div", { class: f(["TableOuter", {
6742
6777
  "full-width": t.fullWidth,
@@ -6745,7 +6780,7 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6745
6780
  key: 0,
6746
6781
  items: S.value,
6747
6782
  "force-dropdown": ""
6748
- }, null, 8, ["items"])) : i("", !0), o("div", cn, [o("table", { class: f(["Table", { "full-width": t.fullWidth }]) }, [
6783
+ }, null, 8, ["items"])) : i("", !0), o("div", fn, [o("table", { class: f(["Table", { "full-width": t.fullWidth }]) }, [
6749
6784
  o("colgroup", null, [(_(!0), a(e, null, y(h.value, (e) => (_(), a("col", {
6750
6785
  key: e.name,
6751
6786
  style: m(u(e.name))
@@ -6763,4 +6798,4 @@ var Be = ["width", "height"], Ve = ["x"], He = { key: 1 }, Ue = [
6763
6798
  }
6764
6799
  }), [["__scopeId", "data-v-d5c290dc"]]);
6765
6800
  //#endregion
6766
- export { Ut as BarChart, sn as ChartTooltip, on as ChoroplethMap, ln as DataTable, St as LineChart, Wt as fipsToHsa, Gt as hsaNames };
6801
+ export { qt as BarChart, dn as ChartTooltip, un as ChoroplethMap, pn as DataTable, Et as LineChart, Jt as fipsToHsa, Yt as hsaNames };