vvplot 0.5.2 → 0.5.3
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/vvplot.esm.js +406 -283
- package/dist/vvplot.esm.min.js +18 -18
- package/dist/vvplot.global.js +406 -283
- package/dist/vvplot.global.min.js +18 -18
- package/package.json +2 -1
package/dist/vvplot.global.js
CHANGED
|
@@ -1958,6 +1958,16 @@ var VVPlot = (function(exports, vue) {
|
|
|
1958
1958
|
if (infinity_rm) arr = arr.filter((x2) => isFinite(x2));
|
|
1959
1959
|
return Array.from(arr).reduce((a, b) => a > b ? a : b, -Infinity);
|
|
1960
1960
|
},
|
|
1961
|
+
sum(arr, { na_rm = true, infinity_rm = true } = {}) {
|
|
1962
|
+
if (na_rm) arr = arr.filter(is_continuous);
|
|
1963
|
+
if (infinity_rm) arr = arr.filter((x2) => isFinite(x2));
|
|
1964
|
+
return Array.from(arr).reduce((a, b) => a + b, 0);
|
|
1965
|
+
},
|
|
1966
|
+
diff(arr, { na_rm = true, infinity_rm = true } = {}) {
|
|
1967
|
+
if (na_rm) arr = arr.filter(is_continuous);
|
|
1968
|
+
if (infinity_rm) arr = arr.filter((x2) => isFinite(x2));
|
|
1969
|
+
return Array.from(arr).slice(1).map((v, i) => v - arr[i]);
|
|
1970
|
+
},
|
|
1961
1971
|
mean(arr, { na_rm = true, infinity_rm = true } = {}) {
|
|
1962
1972
|
if (na_rm) arr = arr.filter(is_continuous);
|
|
1963
1973
|
if (infinity_rm) arr = arr.filter((x2) => isFinite(x2));
|
|
@@ -1989,6 +1999,14 @@ var VVPlot = (function(exports, vue) {
|
|
|
1989
1999
|
}
|
|
1990
2000
|
};
|
|
1991
2001
|
const vecutils = {
|
|
2002
|
+
coalesce(value, defaultValue) {
|
|
2003
|
+
if (Array.isArray(defaultValue)) {
|
|
2004
|
+
if (!Array.isArray(value) || value.length != defaultValue.length) throw new Error("Value and defaultValue must be arrays of the same length");
|
|
2005
|
+
return value.map((v, i) => v == null ? defaultValue[i] : v);
|
|
2006
|
+
}
|
|
2007
|
+
if (Array.isArray(value)) return value.map((v) => v ?? defaultValue);
|
|
2008
|
+
return value ?? defaultValue;
|
|
2009
|
+
},
|
|
1992
2010
|
/* vectorized summation of numbers */
|
|
1993
2011
|
sum(...values) {
|
|
1994
2012
|
if (values.some((x2) => x2 == null)) return null;
|
|
@@ -1998,12 +2016,10 @@ var VVPlot = (function(exports, vue) {
|
|
|
1998
2016
|
values = values.filter((x2) => Array.isArray(x2));
|
|
1999
2017
|
if (values.length == 0)
|
|
2000
2018
|
return [nums];
|
|
2001
|
-
if (values.some((v) => v.length == 0))
|
|
2002
|
-
return [];
|
|
2003
2019
|
let length = values[0].length;
|
|
2004
2020
|
if (values.some((v) => v.length != length))
|
|
2005
2021
|
throw new Error("Arrays must have the same length");
|
|
2006
|
-
return Array.from({ length }, (_, i) => values.reduce((s, a) => +(a[i] ?? 0) + s, nums));
|
|
2022
|
+
return Array.from({ length }, (_, i) => values.reduce((s, a) => +(a[i] ?? void 0) + s, nums));
|
|
2007
2023
|
},
|
|
2008
2024
|
/* vectorized opposite of numbers */
|
|
2009
2025
|
opposite(value) {
|
|
@@ -2257,7 +2273,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
2257
2273
|
},
|
|
2258
2274
|
axis_v: {
|
|
2259
2275
|
title_offset: 30,
|
|
2260
|
-
title_angle: 90
|
|
2276
|
+
title_angle: -90
|
|
2261
2277
|
},
|
|
2262
2278
|
axis_left: {
|
|
2263
2279
|
tick_position: "left",
|
|
@@ -2343,7 +2359,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
2343
2359
|
line_color: "black",
|
|
2344
2360
|
tick_color: "black",
|
|
2345
2361
|
label_color: "black",
|
|
2346
|
-
title_color: "black"
|
|
2362
|
+
title_color: "black",
|
|
2363
|
+
grid_color: null
|
|
2347
2364
|
}
|
|
2348
2365
|
};
|
|
2349
2366
|
const theme_void = {
|
|
@@ -2464,11 +2481,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2464
2481
|
return null;
|
|
2465
2482
|
}
|
|
2466
2483
|
};
|
|
2467
|
-
let psum$a = vecutils
|
|
2484
|
+
let { sum: psum$a, coalesce: coalesce$a } = vecutils;
|
|
2468
2485
|
const boxplot$1 = {
|
|
2469
2486
|
scale_attrs: ["fill", "color", "linewidth", "linetype", "alpha"],
|
|
2470
2487
|
coord_scale(ds, levels) {
|
|
2471
|
-
let xnudge = ds.xnudge
|
|
2488
|
+
let xnudge = coalesce$a(ds.xnudge, 0), ynudge = coalesce$a(ds.ynudge, 0);
|
|
2472
2489
|
if (ds.x) {
|
|
2473
2490
|
let x2 = psum$a(levels.x?.apply?.(ds.x) ?? ds.x, xnudge), xmin = psum$a(x2, ds.width?.map?.((x3) => -x3 / 2) ?? -0.5), xmax = psum$a(x2, ds.width?.map?.((x3) => +x3 / 2) ?? 0.5), lwisker = psum$a(ds.lwisker, ynudge), Q1 = psum$a(ds.Q1, ynudge), median = psum$a(ds.median, ynudge), Q3 = psum$a(ds.Q3, ynudge), uwisker = psum$a(ds.uwisker, ynudge), outliers = vecutils.apply(
|
|
2474
2491
|
($x, { y: ys, $raw }, nudge) => psum$a(ys, nudge).map(($y, i) => ({ x: $x, y: $y, $raw: $raw[i] })),
|
|
@@ -2543,12 +2560,12 @@ var VVPlot = (function(exports, vue) {
|
|
|
2543
2560
|
return d;
|
|
2544
2561
|
}
|
|
2545
2562
|
};
|
|
2546
|
-
let psum$9 = vecutils
|
|
2563
|
+
let { sum: psum$9, coalesce: coalesce$9 } = vecutils;
|
|
2547
2564
|
const ellipse$1 = {
|
|
2548
2565
|
scale_attrs: ["fill", "color", "linewidth", "linetype", "alpha"],
|
|
2549
2566
|
coord_scale(ds, levels) {
|
|
2550
2567
|
let { A, B, C } = ds;
|
|
2551
|
-
let xnudge = ds.xnudge
|
|
2568
|
+
let xnudge = coalesce$9(ds.xnudge, 0), ynudge = coalesce$9(ds.ynudge, 0), cx = psum$9(levels.x?.apply?.(ds.cx) ?? ds.cx, xnudge), cy = psum$9(levels.y?.apply?.(ds.cy) ?? ds.cy, ynudge);
|
|
2552
2569
|
return { cx, cy, A, B, C };
|
|
2553
2570
|
},
|
|
2554
2571
|
get_range(ds, orientation) {
|
|
@@ -2566,11 +2583,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2566
2583
|
return d;
|
|
2567
2584
|
}
|
|
2568
2585
|
};
|
|
2569
|
-
let psum$8 = vecutils
|
|
2586
|
+
let { sum: psum$8, coalesce: coalesce$8 } = vecutils;
|
|
2570
2587
|
const line$2 = {
|
|
2571
2588
|
scale_attrs: ["color", "linewidth", "linetype", "alpha"],
|
|
2572
2589
|
coord_scale(ds, levels) {
|
|
2573
|
-
let xnudge = ds.xnudge
|
|
2590
|
+
let xnudge = coalesce$8(ds.xnudge, 0), ynudge = coalesce$8(ds.ynudge, 0), x2 = psum$8(levels.x?.apply?.(ds.x) ?? ds.x, xnudge), y2 = psum$8(levels.y?.apply?.(ds.y) ?? ds.y, ynudge), xend = psum$8(levels.x?.apply?.(ds.xend) ?? ds.xend, xnudge), yend = psum$8(levels.y?.apply?.(ds.yend) ?? ds.yend, ynudge);
|
|
2574
2591
|
return { x: x2, y: y2, xend, yend };
|
|
2575
2592
|
},
|
|
2576
2593
|
get_range(ds, orientation) {
|
|
@@ -2582,11 +2599,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2582
2599
|
return d;
|
|
2583
2600
|
}
|
|
2584
2601
|
};
|
|
2585
|
-
let psum$7 = vecutils
|
|
2602
|
+
let { sum: psum$7, coalesce: coalesce$7 } = vecutils;
|
|
2586
2603
|
const markdown = {
|
|
2587
2604
|
scale_attrs: ["size", "color", "stroke", "linewidth", "linetype", "alpha"],
|
|
2588
2605
|
coord_scale(ds, levels) {
|
|
2589
|
-
let xnudge = ds.xnudge
|
|
2606
|
+
let xnudge = coalesce$7(ds.xnudge, 0), ynudge = coalesce$7(ds.ynudge, 0), x2 = psum$7(levels.x?.apply?.(ds.x) ?? ds.x, xnudge), y2 = psum$7(levels.y?.apply?.(ds.y) ?? ds.y, ynudge);
|
|
2590
2607
|
return { x: x2, y: y2 };
|
|
2591
2608
|
},
|
|
2592
2609
|
get_range(ds, orientation) {
|
|
@@ -2598,11 +2615,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2598
2615
|
return d;
|
|
2599
2616
|
}
|
|
2600
2617
|
};
|
|
2601
|
-
let psum$6 = vecutils
|
|
2618
|
+
let { sum: psum$6, coalesce: coalesce$6 } = vecutils;
|
|
2602
2619
|
const markdownsegment = {
|
|
2603
2620
|
scale_attrs: ["size", "color", "stroke", "linewidth", "linetype", "alpha"],
|
|
2604
2621
|
coord_scale(ds, levels) {
|
|
2605
|
-
let xnudge = ds.xnudge
|
|
2622
|
+
let xnudge = coalesce$6(ds.xnudge, 0), ynudge = coalesce$6(ds.ynudge, 0), x2 = psum$6(levels.x?.apply?.(ds.x) ?? ds.x, xnudge), y2 = psum$6(levels.y?.apply?.(ds.y) ?? ds.y, ynudge), xend = psum$6(levels.x?.apply?.(ds.xend) ?? ds.xend, xnudge), yend = psum$6(levels.y?.apply?.(ds.yend) ?? ds.yend, ynudge);
|
|
2606
2623
|
return { x: x2, y: y2, xend, yend };
|
|
2607
2624
|
},
|
|
2608
2625
|
get_range(ds, orientation) {
|
|
@@ -2614,11 +2631,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2614
2631
|
return d;
|
|
2615
2632
|
}
|
|
2616
2633
|
};
|
|
2617
|
-
let psum$5 = vecutils
|
|
2634
|
+
let { sum: psum$5, coalesce: coalesce$5 } = vecutils;
|
|
2618
2635
|
const point$3 = {
|
|
2619
2636
|
scale_attrs: ["shape", "size", "color", "stroke", "linewidth", "linetype", "alpha"],
|
|
2620
2637
|
coord_scale(ds, levels) {
|
|
2621
|
-
let xnudge = ds.xnudge
|
|
2638
|
+
let xnudge = coalesce$5(ds.xnudge, 0), ynudge = coalesce$5(ds.ynudge, 0), x2 = psum$5(levels.x?.apply?.(ds.x) ?? ds.x, xnudge), y2 = psum$5(levels.y?.apply?.(ds.y) ?? ds.y, ynudge);
|
|
2622
2639
|
return { x: x2, y: y2 };
|
|
2623
2640
|
},
|
|
2624
2641
|
get_range(ds, orientation) {
|
|
@@ -2648,11 +2665,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2648
2665
|
return d;
|
|
2649
2666
|
}
|
|
2650
2667
|
};
|
|
2651
|
-
let psum$4 = vecutils
|
|
2668
|
+
let { sum: psum$4, coalesce: coalesce$4 } = vecutils;
|
|
2652
2669
|
const rect$2 = {
|
|
2653
2670
|
scale_attrs: ["fill", "color", "linewidth", "linetype", "alpha"],
|
|
2654
2671
|
coord_scale(ds, levels) {
|
|
2655
|
-
let xnudge = ds.xnudge
|
|
2672
|
+
let xnudge = coalesce$4(ds.xnudge, 0), ynudge = coalesce$4(ds.ynudge, 0), xmin = psum$4(levels.x?.apply?.(ds.xmin) ?? ds.xmin, xnudge), xmax = psum$4(levels.x?.apply?.(ds.xmax) ?? ds.xmax, xnudge), ymin = psum$4(levels.y?.apply?.(ds.ymin) ?? ds.ymin, ynudge), ymax = psum$4(levels.y?.apply?.(ds.ymax) ?? ds.ymax, ynudge);
|
|
2656
2673
|
return { xmin, xmax, ymin, ymax };
|
|
2657
2674
|
},
|
|
2658
2675
|
get_range(ds, orientation) {
|
|
@@ -2686,11 +2703,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2686
2703
|
return d;
|
|
2687
2704
|
}
|
|
2688
2705
|
};
|
|
2689
|
-
let psum$3 = vecutils
|
|
2706
|
+
let { sum: psum$3, coalesce: coalesce$3 } = vecutils;
|
|
2690
2707
|
const stick$1 = {
|
|
2691
2708
|
scale_attrs: ["color", "linewidth", "linetype", "alpha"],
|
|
2692
2709
|
coord_scale(ds, levels) {
|
|
2693
|
-
let xnudge = ds.xnudge
|
|
2710
|
+
let xnudge = coalesce$3(ds.xnudge, 0), ynudge = coalesce$3(ds.ynudge, 0), x2 = psum$3(levels.x?.apply?.(ds.x) ?? ds.x, xnudge), y2 = psum$3(levels.y?.apply?.(ds.y) ?? ds.y, ynudge), xend = psum$3(x2, ds.dx), yend = psum$3(y2, ds.dy);
|
|
2694
2711
|
return { x: x2, y: y2, xend, yend };
|
|
2695
2712
|
},
|
|
2696
2713
|
get_values(ds, orientation) {
|
|
@@ -2706,11 +2723,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2706
2723
|
return d;
|
|
2707
2724
|
}
|
|
2708
2725
|
};
|
|
2709
|
-
let psum$2 = vecutils
|
|
2726
|
+
let { sum: psum$2, coalesce: coalesce$2 } = vecutils;
|
|
2710
2727
|
const text$3 = {
|
|
2711
2728
|
scale_attrs: ["size", "color", "stroke", "linewidth", "linetype", "alpha"],
|
|
2712
2729
|
coord_scale(ds, levels) {
|
|
2713
|
-
let xnudge = ds.xnudge
|
|
2730
|
+
let xnudge = coalesce$2(ds.xnudge, 0), ynudge = coalesce$2(ds.ynudge, 0), x2 = psum$2(levels.x?.apply?.(ds.x) ?? ds.x, xnudge), y2 = psum$2(levels.y?.apply?.(ds.y) ?? ds.y, ynudge);
|
|
2714
2731
|
return { x: x2, y: y2 };
|
|
2715
2732
|
},
|
|
2716
2733
|
get_range(ds, orientation) {
|
|
@@ -2722,11 +2739,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2722
2739
|
return d;
|
|
2723
2740
|
}
|
|
2724
2741
|
};
|
|
2725
|
-
let psum$1 = vecutils
|
|
2742
|
+
let { sum: psum$1, coalesce: coalesce$1 } = vecutils;
|
|
2726
2743
|
const textsegment$1 = {
|
|
2727
2744
|
scale_attrs: ["size", "color", "stroke", "linewidth", "linetype", "alpha"],
|
|
2728
2745
|
coord_scale(ds, levels) {
|
|
2729
|
-
let xnudge = ds.xnudge
|
|
2746
|
+
let xnudge = coalesce$1(ds.xnudge, 0), ynudge = coalesce$1(ds.ynudge, 0), x2 = psum$1(levels.x?.apply?.(ds.x) ?? ds.x, xnudge), y2 = psum$1(levels.y?.apply?.(ds.y) ?? ds.y, ynudge), xend = psum$1(levels.x?.apply?.(ds.xend) ?? ds.xend, xnudge), yend = psum$1(levels.y?.apply?.(ds.yend) ?? ds.yend, ynudge);
|
|
2730
2747
|
return { x: x2, y: y2, xend, yend };
|
|
2731
2748
|
},
|
|
2732
2749
|
get_range(ds, orientation) {
|
|
@@ -2738,11 +2755,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
2738
2755
|
return d;
|
|
2739
2756
|
}
|
|
2740
2757
|
};
|
|
2741
|
-
let psum = vecutils
|
|
2758
|
+
let { sum: psum, coalesce } = vecutils;
|
|
2742
2759
|
const tile$1 = {
|
|
2743
2760
|
scale_attrs: ["fill", "color", "linewidth", "linetype", "alpha"],
|
|
2744
2761
|
coord_scale(ds, levels) {
|
|
2745
|
-
let xnudge = ds.xnudge
|
|
2762
|
+
let xnudge = coalesce(ds.xnudge, 0), ynudge = coalesce(ds.ynudge, 0), x2 = levels.x?.apply?.(ds.x) ?? ds.x, y2 = levels.y?.apply?.(ds.y) ?? ds.y, xmin = psum(x2, ds.width?.map?.((x3) => -x3 / 2) ?? -0.5, xnudge), xmax = psum(x2, ds.width?.map?.((x3) => +x3 / 2) ?? 0.5, xnudge), ymin = psum(y2, ds.height?.map?.((x3) => -x3 / 2) ?? -0.5, ynudge), ymax = psum(y2, ds.height?.map?.((x3) => +x3 / 2) ?? 0.5, ynudge);
|
|
2746
2763
|
return { xmin, xmax, ymin, ymax };
|
|
2747
2764
|
},
|
|
2748
2765
|
get_values(ds, orientation) {
|
|
@@ -2795,20 +2812,21 @@ var VVPlot = (function(exports, vue) {
|
|
|
2795
2812
|
let group = intraaction(Object.fromEntries(keys.map((k) => [k, data[k]])));
|
|
2796
2813
|
let inter = intraaction({ group: group ?? 0, value: values });
|
|
2797
2814
|
let groups = Map.groupBy(data.$raw, (_, i) => inter.categories[inter[i]]);
|
|
2798
|
-
let $raw = Array.from(groups.values()), cates = Array.from(groups.keys());
|
|
2815
|
+
let $raw = Array.from(groups.values()), cates = Array.from(groups.keys()), val = $raw.map((v) => v.length);
|
|
2799
2816
|
let result = {
|
|
2800
2817
|
$raw,
|
|
2801
|
-
$group: cates.map((x2) => x2.group)
|
|
2818
|
+
$group: cates.map((x2) => x2.group),
|
|
2819
|
+
[cateAes]: cates.map((v) => v.value)
|
|
2802
2820
|
};
|
|
2803
2821
|
for (let key of keys) {
|
|
2804
2822
|
result[key] = cates.map((x2) => x2.group).map((i) => group.categories[i][key]);
|
|
2805
2823
|
}
|
|
2806
2824
|
if (cateAes == "x") {
|
|
2807
|
-
|
|
2808
|
-
result.height =
|
|
2825
|
+
width ??= 0.9;
|
|
2826
|
+
result.height = val;
|
|
2809
2827
|
} else {
|
|
2810
|
-
|
|
2811
|
-
result.width =
|
|
2828
|
+
height ??= 0.9;
|
|
2829
|
+
result.width = val;
|
|
2812
2830
|
}
|
|
2813
2831
|
if (position == "stack") {
|
|
2814
2832
|
let cate_group = Object.groupBy(result.$group, (v, i) => group.categories[v][cateAes]);
|
|
@@ -2817,7 +2835,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
2817
2835
|
let s = 0;
|
|
2818
2836
|
for (let i of cate_group[cate]) {
|
|
2819
2837
|
offset[i] = s;
|
|
2820
|
-
s +=
|
|
2838
|
+
s += val[i];
|
|
2821
2839
|
}
|
|
2822
2840
|
}
|
|
2823
2841
|
if (cateAes == "x") {
|
|
@@ -2907,6 +2925,85 @@ var VVPlot = (function(exports, vue) {
|
|
|
2907
2925
|
}
|
|
2908
2926
|
return result;
|
|
2909
2927
|
}, { core_attrs: ["x", "y", "xnudge", "ynudge"] });
|
|
2928
|
+
const col = Object.assign(function(data, { position = "stack", width, height, orientation = "x" }) {
|
|
2929
|
+
let missingAes = ["x", "y"].filter((a) => data[a] == null);
|
|
2930
|
+
if (missingAes.length > 0)
|
|
2931
|
+
throw new Error(`Missing aesthetics for "StatCol": "${missingAes.join('", "')}"`);
|
|
2932
|
+
let isXdiscrete = data.x.some(is_categorical);
|
|
2933
|
+
let isYdiscrete = data.y.some(is_categorical);
|
|
2934
|
+
if (isXdiscrete && isYdiscrete)
|
|
2935
|
+
throw new Error(`Both "x" and "y" are discrete, "StatCol" requires at most one discrete aesthetic`);
|
|
2936
|
+
let cateAes = isXdiscrete == isYdiscrete ? orientation != "y" ? "x" : "y" : isXdiscrete ? "x" : "y";
|
|
2937
|
+
let valueAes = cateAes == "x" ? "y" : "x";
|
|
2938
|
+
let keys = Object.keys(data).filter((k) => k != valueAes && !k.startsWith("$"));
|
|
2939
|
+
let group = intraaction(Object.fromEntries(keys.map((k) => [k, data[k]])));
|
|
2940
|
+
let inter = intraaction({ group: group ?? 0, cate: data[cateAes] });
|
|
2941
|
+
let groupIdx = Map.groupBy(inter.map((_, i) => i), (_, i) => inter.categories[inter[i]]);
|
|
2942
|
+
let groups = Map.groupBy(data.$raw, (_, i) => inter.categories[inter[i]]);
|
|
2943
|
+
let cates = Array.from(groups.keys()), $raw = Array.from(groupIdx.values()).map((arr) => arr.map((idx) => data.$raw[idx])), val = Array.from(groupIdx.values()).map((arr) => numutils.sum(arr.map((idx) => data[valueAes][idx])));
|
|
2944
|
+
let result = {
|
|
2945
|
+
$raw,
|
|
2946
|
+
$group: cates.map((x2) => x2.group),
|
|
2947
|
+
[cateAes]: cates.map((v) => v.value)
|
|
2948
|
+
};
|
|
2949
|
+
for (let key of keys) {
|
|
2950
|
+
result[key] = cates.map((x2) => x2.group).map((i) => group.categories[i][key]);
|
|
2951
|
+
}
|
|
2952
|
+
if (cateAes == "x") {
|
|
2953
|
+
if (isXdiscrete) {
|
|
2954
|
+
width ??= 0.9;
|
|
2955
|
+
} else {
|
|
2956
|
+
width ??= numutils.min(numutils.diff(Array.from(new Set(data[cateAes])).sort((a, b) => a - b))) * 0.9;
|
|
2957
|
+
}
|
|
2958
|
+
result.height = val;
|
|
2959
|
+
} else {
|
|
2960
|
+
if (isYdiscrete) {
|
|
2961
|
+
height ??= 0.9;
|
|
2962
|
+
} else {
|
|
2963
|
+
height ??= numutils.min(numutils.diff(Array.from(new Set(data[cateAes])).sort((a, b) => a - b))) * 0.9;
|
|
2964
|
+
}
|
|
2965
|
+
result.width = val;
|
|
2966
|
+
}
|
|
2967
|
+
if (position == "stack") {
|
|
2968
|
+
let cate_group = Object.groupBy(result.$group, (v, i) => group.categories[v][cateAes]);
|
|
2969
|
+
let offset = cates.map((_) => 0);
|
|
2970
|
+
for (let cate in cate_group) {
|
|
2971
|
+
let s = 0;
|
|
2972
|
+
for (let i of cate_group[cate]) {
|
|
2973
|
+
offset[i] = s;
|
|
2974
|
+
s += val[i];
|
|
2975
|
+
}
|
|
2976
|
+
}
|
|
2977
|
+
if (cateAes == "x") {
|
|
2978
|
+
result.y = result.height.map((v, i) => offset[i] + v / 2);
|
|
2979
|
+
result.width = cates.map((_) => width);
|
|
2980
|
+
} else {
|
|
2981
|
+
result.x = result.width.map((v, i) => offset[i] + v / 2);
|
|
2982
|
+
result.height = cates.map((_) => height);
|
|
2983
|
+
}
|
|
2984
|
+
} else if (position == "dodge") {
|
|
2985
|
+
let cate_group = Object.groupBy(result.$group, (v, i) => group.categories[v][cateAes]);
|
|
2986
|
+
let $group = result.$group.map((v) => cate_group[group.categories[v][cateAes]]);
|
|
2987
|
+
if (cateAes == "x") {
|
|
2988
|
+
result.y = result.height.map((v) => v / 2);
|
|
2989
|
+
result.width = $group.map((arr) => width / arr.length);
|
|
2990
|
+
result.xnudge = $group.map((arr, i) => (result.xnudge?.[i] ?? 0) + ((arr.indexOf(result.$group[i]) + 0.5) / arr.length - 0.5) * width);
|
|
2991
|
+
} else {
|
|
2992
|
+
result.x = result.width.map((v) => v / 2);
|
|
2993
|
+
result.height = $group.map((arr) => height / arr.length);
|
|
2994
|
+
result.ynudge = $group.map((arr, i) => (result.ynudge?.[i] ?? 0) + ((arr.indexOf(result.$group[i]) + 0.5) / arr.length - 0.5) * height);
|
|
2995
|
+
}
|
|
2996
|
+
} else {
|
|
2997
|
+
if (cateAes == "x") {
|
|
2998
|
+
result.y = result.height.map((v) => v / 2);
|
|
2999
|
+
result.width = cates.map((_) => width);
|
|
3000
|
+
} else {
|
|
3001
|
+
result.x = result.width.map((v) => v / 2);
|
|
3002
|
+
result.height = cates.map((_) => height);
|
|
3003
|
+
}
|
|
3004
|
+
}
|
|
3005
|
+
return result;
|
|
3006
|
+
}, { core_attrs: ["x", "y", "xnudge", "ynudge"] });
|
|
2910
3007
|
const curve = Object.assign(function(data) {
|
|
2911
3008
|
if (data.points != null) return data;
|
|
2912
3009
|
let missingAes = ["x", "y"].filter((a) => data[a] == null);
|
|
@@ -3331,6 +3428,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
3331
3428
|
__proto__: null,
|
|
3332
3429
|
bar,
|
|
3333
3430
|
boxplot,
|
|
3431
|
+
col,
|
|
3334
3432
|
curve,
|
|
3335
3433
|
density,
|
|
3336
3434
|
ellipse,
|
|
@@ -7537,9 +7635,9 @@ var VVPlot = (function(exports, vue) {
|
|
|
7537
7635
|
return breaks;
|
|
7538
7636
|
}
|
|
7539
7637
|
}
|
|
7540
|
-
const _hoisted_1$
|
|
7638
|
+
const _hoisted_1$q = ["font-size"];
|
|
7541
7639
|
const _hoisted_2$8 = { key: 0 };
|
|
7542
|
-
const _sfc_main$
|
|
7640
|
+
const _sfc_main$18 = {
|
|
7543
7641
|
__name: "CoreText",
|
|
7544
7642
|
props: {
|
|
7545
7643
|
x: { type: Number, default: 0 },
|
|
@@ -7567,8 +7665,9 @@ var VVPlot = (function(exports, vue) {
|
|
|
7567
7665
|
setup(__props) {
|
|
7568
7666
|
const ele = vue.useTemplateRef("ele");
|
|
7569
7667
|
const textBox = vue.reactive({ width: 0, height: 0 });
|
|
7668
|
+
const visible = vue.inject("vvplot-visible", true);
|
|
7570
7669
|
vue.watch(
|
|
7571
|
-
[ele, () => __props.fontSize, () => __props.size, () => __props.text, () => __props.textLength, () => __props.fontFamily],
|
|
7670
|
+
[ele, visible, () => __props.fontSize, () => __props.size, () => __props.text, () => __props.textLength, () => __props.fontFamily],
|
|
7572
7671
|
async ([e]) => {
|
|
7573
7672
|
if (!e) return;
|
|
7574
7673
|
await vue.nextTick();
|
|
@@ -7626,7 +7725,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
7626
7725
|
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_2$8, vue.toDisplayString(__props.title), 1)) : vue.createCommentVNode("", true),
|
|
7627
7726
|
vue.createTextVNode(" " + vue.toDisplayString(__props.text?.replace(/ /g, " ")), 1)
|
|
7628
7727
|
])
|
|
7629
|
-
], 16, _hoisted_1$
|
|
7728
|
+
], 16, _hoisted_1$q);
|
|
7630
7729
|
};
|
|
7631
7730
|
}
|
|
7632
7731
|
};
|
|
@@ -14788,9 +14887,9 @@ var VVPlot = (function(exports, vue) {
|
|
|
14788
14887
|
XmlRenderer.prototype.cr = cr;
|
|
14789
14888
|
XmlRenderer.prototype.tag = tag;
|
|
14790
14889
|
XmlRenderer.prototype.esc = escapeXml;
|
|
14791
|
-
const _hoisted_1$
|
|
14890
|
+
const _hoisted_1$p = ["text-anchor", "font-size"];
|
|
14792
14891
|
const _hoisted_2$7 = { key: 0 };
|
|
14793
|
-
const _sfc_main$
|
|
14892
|
+
const _sfc_main$17 = {
|
|
14794
14893
|
__name: "CoreMarkdown",
|
|
14795
14894
|
props: {
|
|
14796
14895
|
x: { type: Number, default: 0 },
|
|
@@ -14819,8 +14918,9 @@ var VVPlot = (function(exports, vue) {
|
|
|
14819
14918
|
const parser = new Parser();
|
|
14820
14919
|
const ele = vue.useTemplateRef("ele");
|
|
14821
14920
|
const textBox = vue.reactive({ width: 0, height: 0 });
|
|
14921
|
+
const visible = vue.inject("vvplot-visible", true);
|
|
14822
14922
|
vue.watch(
|
|
14823
|
-
[ele, () => __props.fontSize, () => __props.size, () => __props.text, () => __props.textLength, () => __props.fontFamily],
|
|
14923
|
+
[ele, visible, () => __props.fontSize, () => __props.size, () => __props.text, () => __props.textLength, () => __props.fontFamily],
|
|
14824
14924
|
async ([e]) => {
|
|
14825
14925
|
if (!e) return;
|
|
14826
14926
|
await vue.nextTick();
|
|
@@ -14933,11 +15033,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
14933
15033
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(textFragments.value, (span) => {
|
|
14934
15034
|
return vue.openBlock(), vue.createElementBlock("tspan", vue.mergeProps({ ref_for: true }, span.vbind), vue.toDisplayString(span.text), 17);
|
|
14935
15035
|
}), 256))
|
|
14936
|
-
], 16, _hoisted_1$
|
|
15036
|
+
], 16, _hoisted_1$p);
|
|
14937
15037
|
};
|
|
14938
15038
|
}
|
|
14939
15039
|
};
|
|
14940
|
-
const _sfc_main$
|
|
15040
|
+
const _sfc_main$16 = {
|
|
14941
15041
|
__name: "CoreAxisLabel",
|
|
14942
15042
|
props: {
|
|
14943
15043
|
type: String,
|
|
@@ -14999,11 +15099,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
14999
15099
|
}
|
|
15000
15100
|
};
|
|
15001
15101
|
return (_ctx, _cache) => {
|
|
15002
|
-
return __props.type == "markdown" ? (vue.openBlock(), vue.createBlock(_sfc_main$
|
|
15102
|
+
return __props.type == "markdown" ? (vue.openBlock(), vue.createBlock(_sfc_main$17, vue.mergeProps({ key: 0 }, vue.toHandlers(vOn)), null, 16)) : (vue.openBlock(), vue.createBlock(_sfc_main$18, vue.mergeProps({ key: 1 }, vue.toHandlers(vOn)), null, 16));
|
|
15003
15103
|
};
|
|
15004
15104
|
}
|
|
15005
15105
|
};
|
|
15006
|
-
const _hoisted_1$
|
|
15106
|
+
const _hoisted_1$o = ["transform"];
|
|
15007
15107
|
const _hoisted_2$6 = ["x2"];
|
|
15008
15108
|
const _hoisted_3$4 = {
|
|
15009
15109
|
class: "vvplot-interactive",
|
|
@@ -15016,7 +15116,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
15016
15116
|
fill: "transparent"
|
|
15017
15117
|
};
|
|
15018
15118
|
const _hoisted_6$2 = ["x"];
|
|
15019
|
-
const _sfc_main$
|
|
15119
|
+
const _sfc_main$15 = {
|
|
15020
15120
|
__name: "CoreAxisH",
|
|
15021
15121
|
props: {
|
|
15022
15122
|
coord: String,
|
|
@@ -15205,16 +15305,15 @@ var VVPlot = (function(exports, vue) {
|
|
|
15205
15305
|
let { xmin, xmax, ymin, ymax } = __props.pos2coord({ hmin: hmin0 + dh, hmax: hmax0 + dh });
|
|
15206
15306
|
Object.assign(rangePreview, { xmin, xmax, ymin, ymax });
|
|
15207
15307
|
};
|
|
15208
|
-
e.target.
|
|
15308
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
15209
15309
|
e.target.onpointermove = null;
|
|
15210
|
-
e.target.onpointerup = null;
|
|
15211
15310
|
e.target.style.cursor = null;
|
|
15212
15311
|
if (!pointerMoved) return;
|
|
15213
15312
|
moveTimer = setTimeout(() => {
|
|
15214
15313
|
applyTransform(act, ev);
|
|
15215
15314
|
movementX = 0;
|
|
15216
15315
|
}, 300);
|
|
15217
|
-
};
|
|
15316
|
+
}, { once: true });
|
|
15218
15317
|
}
|
|
15219
15318
|
function axisRescaleLeftPointerdown(e) {
|
|
15220
15319
|
let act = __props.action.find((a) => a.action == "rescale");
|
|
@@ -15240,11 +15339,10 @@ var VVPlot = (function(exports, vue) {
|
|
|
15240
15339
|
});
|
|
15241
15340
|
Object.assign(rangePreview, { xmin, xmax, ymin, ymax });
|
|
15242
15341
|
};
|
|
15243
|
-
e.target.
|
|
15342
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
15244
15343
|
e.target.onpointermove = null;
|
|
15245
|
-
e.target.onpointerup = null;
|
|
15246
15344
|
applyTransform(act, ev);
|
|
15247
|
-
};
|
|
15345
|
+
}, { once: true });
|
|
15248
15346
|
}
|
|
15249
15347
|
function axisRescaleRightPointerdown(e) {
|
|
15250
15348
|
let act = __props.action.find((a) => a.action == "rescale");
|
|
@@ -15270,11 +15368,10 @@ var VVPlot = (function(exports, vue) {
|
|
|
15270
15368
|
});
|
|
15271
15369
|
Object.assign(rangePreview, { xmin, xmax, ymin, ymax });
|
|
15272
15370
|
};
|
|
15273
|
-
e.target.
|
|
15371
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
15274
15372
|
e.target.onpointermove = null;
|
|
15275
|
-
e.target.onpointerup = null;
|
|
15276
15373
|
applyTransform(act, ev);
|
|
15277
|
-
};
|
|
15374
|
+
}, { once: true });
|
|
15278
15375
|
}
|
|
15279
15376
|
let wheelDelta = 0, wheelTimer;
|
|
15280
15377
|
function axisWheel(e) {
|
|
@@ -15382,7 +15479,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
15382
15479
|
_cache[2] || (_cache[2] = vue.createTextVNode()),
|
|
15383
15480
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(tickTexts.value, (tick) => {
|
|
15384
15481
|
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, tick.wrapper), [
|
|
15385
|
-
vue.createVNode(_sfc_main$
|
|
15482
|
+
vue.createVNode(_sfc_main$16, vue.mergeProps({ ref_for: true }, tick.text, { getPosition }), null, 16)
|
|
15386
15483
|
], 16);
|
|
15387
15484
|
}), 256)),
|
|
15388
15485
|
_cache[3] || (_cache[3] = vue.createTextVNode()),
|
|
@@ -15415,13 +15512,13 @@ var VVPlot = (function(exports, vue) {
|
|
|
15415
15512
|
])) : vue.createCommentVNode("", true),
|
|
15416
15513
|
_cache[5] || (_cache[5] = vue.createTextVNode()),
|
|
15417
15514
|
axisTitle.value.text ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 2 }, [
|
|
15418
|
-
__props.theme.title_type == "markdown" ? (vue.openBlock(), vue.createBlock(_sfc_main$
|
|
15515
|
+
__props.theme.title_type == "markdown" ? (vue.openBlock(), vue.createBlock(_sfc_main$17, vue.normalizeProps(vue.mergeProps({ key: 0 }, axisTitle.value)), null, 16)) : (vue.openBlock(), vue.createBlock(_sfc_main$18, vue.normalizeProps(vue.mergeProps({ key: 1 }, axisTitle.value)), null, 16))
|
|
15419
15516
|
], 64)) : vue.createCommentVNode("", true)
|
|
15420
|
-
], 12, _hoisted_1$
|
|
15517
|
+
], 12, _hoisted_1$o);
|
|
15421
15518
|
};
|
|
15422
15519
|
}
|
|
15423
15520
|
};
|
|
15424
|
-
const _hoisted_1$
|
|
15521
|
+
const _hoisted_1$n = ["transform"];
|
|
15425
15522
|
const _hoisted_2$5 = ["y2"];
|
|
15426
15523
|
const _hoisted_3$3 = {
|
|
15427
15524
|
class: "vvplot-interactive",
|
|
@@ -15434,7 +15531,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
15434
15531
|
fill: "transparent"
|
|
15435
15532
|
};
|
|
15436
15533
|
const _hoisted_6$1 = ["y"];
|
|
15437
|
-
const _sfc_main$
|
|
15534
|
+
const _sfc_main$14 = {
|
|
15438
15535
|
__name: "CoreAxisV",
|
|
15439
15536
|
props: {
|
|
15440
15537
|
coord: String,
|
|
@@ -15623,16 +15720,15 @@ var VVPlot = (function(exports, vue) {
|
|
|
15623
15720
|
let { xmin, xmax, ymin, ymax } = __props.pos2coord({ vmin: vmin0 + dv, vmax: vmax0 + dv });
|
|
15624
15721
|
Object.assign(rangePreview, { xmin, xmax, ymin, ymax });
|
|
15625
15722
|
};
|
|
15626
|
-
e.target.
|
|
15723
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
15627
15724
|
e.target.onpointermove = null;
|
|
15628
|
-
e.target.onpointerup = null;
|
|
15629
15725
|
e.target.style.cursor = null;
|
|
15630
15726
|
if (!pointerMoved) return;
|
|
15631
15727
|
moveTimer = setTimeout(() => {
|
|
15632
15728
|
applyTransform(act, ev);
|
|
15633
15729
|
movementY = 0;
|
|
15634
15730
|
}, 300);
|
|
15635
|
-
};
|
|
15731
|
+
}, { once: true });
|
|
15636
15732
|
}
|
|
15637
15733
|
function axisRescaleTopPointerdown(e) {
|
|
15638
15734
|
let act = __props.action.find((a) => a.action == "rescale");
|
|
@@ -15658,11 +15754,10 @@ var VVPlot = (function(exports, vue) {
|
|
|
15658
15754
|
});
|
|
15659
15755
|
Object.assign(rangePreview, { xmin, xmax, ymin, ymax });
|
|
15660
15756
|
};
|
|
15661
|
-
e.target.
|
|
15757
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
15662
15758
|
e.target.onpointermove = null;
|
|
15663
|
-
e.target.onpointerup = null;
|
|
15664
15759
|
applyTransform(act, ev);
|
|
15665
|
-
};
|
|
15760
|
+
}, { once: true });
|
|
15666
15761
|
}
|
|
15667
15762
|
function axisRescaleBottomPointerdown(e) {
|
|
15668
15763
|
let act = __props.action.find((a) => a.action == "rescale");
|
|
@@ -15688,11 +15783,10 @@ var VVPlot = (function(exports, vue) {
|
|
|
15688
15783
|
});
|
|
15689
15784
|
Object.assign(rangePreview, { xmin, xmax, ymin, ymax });
|
|
15690
15785
|
};
|
|
15691
|
-
e.target.
|
|
15786
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
15692
15787
|
e.target.onpointermove = null;
|
|
15693
|
-
e.target.onpointerup = null;
|
|
15694
15788
|
applyTransform(act, ev);
|
|
15695
|
-
};
|
|
15789
|
+
}, { once: true });
|
|
15696
15790
|
}
|
|
15697
15791
|
let wheelDelta = 0, wheelTimer;
|
|
15698
15792
|
function axisWheel(e) {
|
|
@@ -15800,7 +15894,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
15800
15894
|
_cache[2] || (_cache[2] = vue.createTextVNode()),
|
|
15801
15895
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(tickTexts.value, (tick) => {
|
|
15802
15896
|
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, tick.wrapper), [
|
|
15803
|
-
vue.createVNode(_sfc_main$
|
|
15897
|
+
vue.createVNode(_sfc_main$16, vue.mergeProps({ ref_for: true }, tick.text, { getPosition }), null, 16)
|
|
15804
15898
|
], 16);
|
|
15805
15899
|
}), 256)),
|
|
15806
15900
|
_cache[3] || (_cache[3] = vue.createTextVNode()),
|
|
@@ -15833,13 +15927,13 @@ var VVPlot = (function(exports, vue) {
|
|
|
15833
15927
|
])) : vue.createCommentVNode("", true),
|
|
15834
15928
|
_cache[5] || (_cache[5] = vue.createTextVNode()),
|
|
15835
15929
|
axisTitle.value.text ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 2 }, [
|
|
15836
|
-
__props.theme.title_type == "markdown" ? (vue.openBlock(), vue.createBlock(_sfc_main$
|
|
15930
|
+
__props.theme.title_type == "markdown" ? (vue.openBlock(), vue.createBlock(_sfc_main$17, vue.normalizeProps(vue.mergeProps({ key: 0 }, axisTitle.value)), null, 16)) : (vue.openBlock(), vue.createBlock(_sfc_main$18, vue.normalizeProps(vue.mergeProps({ key: 1 }, axisTitle.value)), null, 16))
|
|
15837
15931
|
], 64)) : vue.createCommentVNode("", true)
|
|
15838
|
-
], 12, _hoisted_1$
|
|
15932
|
+
], 12, _hoisted_1$n);
|
|
15839
15933
|
};
|
|
15840
15934
|
}
|
|
15841
15935
|
};
|
|
15842
|
-
const _sfc_main$
|
|
15936
|
+
const _sfc_main$13 = {
|
|
15843
15937
|
__name: "CoreAxis",
|
|
15844
15938
|
props: {
|
|
15845
15939
|
theme: { type: Object, default: () => ({}) },
|
|
@@ -15848,8 +15942,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
15848
15942
|
},
|
|
15849
15943
|
setup(__props) {
|
|
15850
15944
|
const axis = {
|
|
15851
|
-
h: _sfc_main$
|
|
15852
|
-
v: _sfc_main$
|
|
15945
|
+
h: _sfc_main$15,
|
|
15946
|
+
v: _sfc_main$14
|
|
15853
15947
|
};
|
|
15854
15948
|
return (_ctx, _cache) => {
|
|
15855
15949
|
return __props.position != "none" ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(axis[__props.orientation]), {
|
|
@@ -15860,7 +15954,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
15860
15954
|
};
|
|
15861
15955
|
}
|
|
15862
15956
|
};
|
|
15863
|
-
const _sfc_main$
|
|
15957
|
+
const _sfc_main$12 = {
|
|
15864
15958
|
__name: "CoreGridH",
|
|
15865
15959
|
props: {
|
|
15866
15960
|
breaks: { type: Array, default: () => [] },
|
|
@@ -15932,7 +16026,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
15932
16026
|
};
|
|
15933
16027
|
}
|
|
15934
16028
|
};
|
|
15935
|
-
const _sfc_main$
|
|
16029
|
+
const _sfc_main$11 = {
|
|
15936
16030
|
__name: "CoreGridV",
|
|
15937
16031
|
props: {
|
|
15938
16032
|
breaks: { type: Array, default: () => [] },
|
|
@@ -16004,7 +16098,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
16004
16098
|
};
|
|
16005
16099
|
}
|
|
16006
16100
|
};
|
|
16007
|
-
const _sfc_main
|
|
16101
|
+
const _sfc_main$10 = {
|
|
16008
16102
|
__name: "CoreCanvasBoxplot",
|
|
16009
16103
|
props: {
|
|
16010
16104
|
extendX: { type: Number, default: 0 },
|
|
@@ -16140,11 +16234,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
16140
16234
|
dispatchEvent: (event) => layerCanvas.value?.dispatchEvent?.(event)
|
|
16141
16235
|
});
|
|
16142
16236
|
return (_ctx, _cache) => {
|
|
16143
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
16237
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
16144
16238
|
};
|
|
16145
16239
|
}
|
|
16146
16240
|
};
|
|
16147
|
-
const _sfc_main
|
|
16241
|
+
const _sfc_main$$ = {
|
|
16148
16242
|
__name: "CoreCanvasCurve",
|
|
16149
16243
|
props: {
|
|
16150
16244
|
extendX: { type: Number, default: 0 },
|
|
@@ -16247,11 +16341,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
16247
16341
|
natural: natural$1
|
|
16248
16342
|
};
|
|
16249
16343
|
return (_ctx, _cache) => {
|
|
16250
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
16344
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
16251
16345
|
};
|
|
16252
16346
|
}
|
|
16253
16347
|
};
|
|
16254
|
-
const _sfc_main$
|
|
16348
|
+
const _sfc_main$_ = {
|
|
16255
16349
|
__name: "CoreCanvasEllipse",
|
|
16256
16350
|
props: {
|
|
16257
16351
|
extendX: { type: Number, default: 0 },
|
|
@@ -16350,11 +16444,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
16350
16444
|
dispatchEvent: (event) => layerCanvas.value?.dispatchEvent?.(event)
|
|
16351
16445
|
});
|
|
16352
16446
|
return (_ctx, _cache) => {
|
|
16353
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
16447
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
16354
16448
|
};
|
|
16355
16449
|
}
|
|
16356
16450
|
};
|
|
16357
|
-
const _sfc_main$
|
|
16451
|
+
const _sfc_main$Z = {
|
|
16358
16452
|
__name: "CoreCanvasLine",
|
|
16359
16453
|
props: {
|
|
16360
16454
|
extendX: { type: Number, default: 0 },
|
|
@@ -16440,11 +16534,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
16440
16534
|
dispatchEvent: (event) => layerCanvas.value?.dispatchEvent?.(event)
|
|
16441
16535
|
});
|
|
16442
16536
|
return (_ctx, _cache) => {
|
|
16443
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
16537
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
16444
16538
|
};
|
|
16445
16539
|
}
|
|
16446
16540
|
};
|
|
16447
|
-
const _sfc_main$
|
|
16541
|
+
const _sfc_main$Y = {
|
|
16448
16542
|
__name: "CoreCanvasPoint",
|
|
16449
16543
|
props: {
|
|
16450
16544
|
extendX: { type: Number, default: 0 },
|
|
@@ -16560,11 +16654,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
16560
16654
|
dispatchEvent: (event) => layerCanvas.value?.dispatchEvent?.(event)
|
|
16561
16655
|
});
|
|
16562
16656
|
return (_ctx, _cache) => {
|
|
16563
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
16657
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
16564
16658
|
};
|
|
16565
16659
|
}
|
|
16566
16660
|
};
|
|
16567
|
-
const _sfc_main$
|
|
16661
|
+
const _sfc_main$X = {
|
|
16568
16662
|
__name: "CoreCanvasPolygon",
|
|
16569
16663
|
props: {
|
|
16570
16664
|
extendX: { type: Number, default: 0 },
|
|
@@ -16655,11 +16749,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
16655
16749
|
dispatchEvent: (event) => layerCanvas.value?.dispatchEvent?.(event)
|
|
16656
16750
|
});
|
|
16657
16751
|
return (_ctx, _cache) => {
|
|
16658
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
16752
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
16659
16753
|
};
|
|
16660
16754
|
}
|
|
16661
16755
|
};
|
|
16662
|
-
const _sfc_main$
|
|
16756
|
+
const _sfc_main$W = {
|
|
16663
16757
|
__name: "CoreCanvasRect",
|
|
16664
16758
|
props: {
|
|
16665
16759
|
extendX: { type: Number, default: 0 },
|
|
@@ -16748,11 +16842,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
16748
16842
|
dispatchEvent: (event) => layerCanvas.value?.dispatchEvent?.(event)
|
|
16749
16843
|
});
|
|
16750
16844
|
return (_ctx, _cache) => {
|
|
16751
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
16845
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
16752
16846
|
};
|
|
16753
16847
|
}
|
|
16754
16848
|
};
|
|
16755
|
-
const _sfc_main$
|
|
16849
|
+
const _sfc_main$V = {
|
|
16756
16850
|
__name: "CoreCanvasText",
|
|
16757
16851
|
props: {
|
|
16758
16852
|
extendX: { type: Number, default: 0 },
|
|
@@ -16881,11 +16975,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
16881
16975
|
dispatchEvent: (event) => layerCanvas.value?.dispatchEvent?.(event)
|
|
16882
16976
|
});
|
|
16883
16977
|
return (_ctx, _cache) => {
|
|
16884
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
16978
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
16885
16979
|
};
|
|
16886
16980
|
}
|
|
16887
16981
|
};
|
|
16888
|
-
const _sfc_main$
|
|
16982
|
+
const _sfc_main$U = {
|
|
16889
16983
|
__name: "CoreCanvasTextsegment",
|
|
16890
16984
|
props: {
|
|
16891
16985
|
extendX: { type: Number, default: 0 },
|
|
@@ -17051,26 +17145,27 @@ var VVPlot = (function(exports, vue) {
|
|
|
17051
17145
|
return result;
|
|
17052
17146
|
}
|
|
17053
17147
|
return (_ctx, _cache) => {
|
|
17054
|
-
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps(vBind.value, { ref: "container" }), null, 16);
|
|
17148
|
+
return vue.openBlock(), vue.createElementBlock("foreignObject", vue.mergeProps({ class: "vvplot-layer" }, vBind.value, { ref: "container" }), null, 16);
|
|
17055
17149
|
};
|
|
17056
17150
|
}
|
|
17057
17151
|
};
|
|
17058
17152
|
const canvas = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
17059
17153
|
__proto__: null,
|
|
17060
|
-
boxplot: _sfc_main
|
|
17061
|
-
curve: _sfc_main
|
|
17062
|
-
ellipse: _sfc_main$
|
|
17063
|
-
line: _sfc_main$
|
|
17064
|
-
point: _sfc_main$
|
|
17065
|
-
polygon: _sfc_main$
|
|
17066
|
-
rect: _sfc_main$
|
|
17067
|
-
shape: _sfc_main
|
|
17068
|
-
stick: _sfc_main$
|
|
17069
|
-
text: _sfc_main$
|
|
17070
|
-
textsegment: _sfc_main$
|
|
17071
|
-
tile: _sfc_main$
|
|
17154
|
+
boxplot: _sfc_main$10,
|
|
17155
|
+
curve: _sfc_main$$,
|
|
17156
|
+
ellipse: _sfc_main$_,
|
|
17157
|
+
line: _sfc_main$Z,
|
|
17158
|
+
point: _sfc_main$Y,
|
|
17159
|
+
polygon: _sfc_main$X,
|
|
17160
|
+
rect: _sfc_main$W,
|
|
17161
|
+
shape: _sfc_main$$,
|
|
17162
|
+
stick: _sfc_main$Z,
|
|
17163
|
+
text: _sfc_main$V,
|
|
17164
|
+
textsegment: _sfc_main$U,
|
|
17165
|
+
tile: _sfc_main$W
|
|
17072
17166
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
17073
|
-
const
|
|
17167
|
+
const _hoisted_1$m = { class: "vvplot-layer" };
|
|
17168
|
+
const _sfc_main$T = {
|
|
17074
17169
|
__name: "CoreSvgBlank",
|
|
17075
17170
|
props: {
|
|
17076
17171
|
extendX: { type: Number, default: 0 },
|
|
@@ -17085,12 +17180,12 @@ var VVPlot = (function(exports, vue) {
|
|
|
17085
17180
|
emits: ["click", "contextmenu", "pointerover", "pointerout", "pointerenter", "pointerleave", "pointermove", "pointerdown", "pointerup"],
|
|
17086
17181
|
setup(__props, { emit: __emit }) {
|
|
17087
17182
|
return (_ctx, _cache) => {
|
|
17088
|
-
return vue.openBlock(), vue.createElementBlock("g");
|
|
17183
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$m);
|
|
17089
17184
|
};
|
|
17090
17185
|
}
|
|
17091
17186
|
};
|
|
17092
|
-
const _hoisted_1$
|
|
17093
|
-
const _sfc_main$
|
|
17187
|
+
const _hoisted_1$l = { key: 0 };
|
|
17188
|
+
const _sfc_main$S = {
|
|
17094
17189
|
__name: "CoreTile",
|
|
17095
17190
|
props: {
|
|
17096
17191
|
x: { type: Number, default: 0 },
|
|
@@ -17125,14 +17220,14 @@ var VVPlot = (function(exports, vue) {
|
|
|
17125
17220
|
});
|
|
17126
17221
|
return (_ctx, _cache) => {
|
|
17127
17222
|
return vue.openBlock(), vue.createElementBlock("rect", vue.normalizeProps(vue.guardReactiveProps(binds.value)), [
|
|
17128
|
-
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$
|
|
17223
|
+
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$l, vue.toDisplayString(__props.title), 1)) : vue.createCommentVNode("", true)
|
|
17129
17224
|
], 16);
|
|
17130
17225
|
};
|
|
17131
17226
|
}
|
|
17132
17227
|
};
|
|
17133
|
-
const _hoisted_1$
|
|
17228
|
+
const _hoisted_1$k = { key: 0 };
|
|
17134
17229
|
const _hoisted_2$4 = { key: 0 };
|
|
17135
|
-
const _sfc_main$
|
|
17230
|
+
const _sfc_main$R = {
|
|
17136
17231
|
__name: "CorePoint",
|
|
17137
17232
|
props: {
|
|
17138
17233
|
x: { type: Number, default: 0 },
|
|
@@ -17183,15 +17278,15 @@ var VVPlot = (function(exports, vue) {
|
|
|
17183
17278
|
});
|
|
17184
17279
|
return (_ctx, _cache) => {
|
|
17185
17280
|
return binds.value.d ? (vue.openBlock(), vue.createElementBlock("path", vue.normalizeProps(vue.mergeProps({ key: 0 }, binds.value)), [
|
|
17186
|
-
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$
|
|
17281
|
+
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$k, vue.toDisplayString(__props.title), 1)) : vue.createCommentVNode("", true)
|
|
17187
17282
|
], 16)) : (vue.openBlock(), vue.createElementBlock("circle", vue.normalizeProps(vue.mergeProps({ key: 1 }, binds.value)), [
|
|
17188
17283
|
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_2$4, vue.toDisplayString(__props.title), 1)) : vue.createCommentVNode("", true)
|
|
17189
17284
|
], 16));
|
|
17190
17285
|
};
|
|
17191
17286
|
}
|
|
17192
17287
|
};
|
|
17193
|
-
const _hoisted_1$
|
|
17194
|
-
const _sfc_main$
|
|
17288
|
+
const _hoisted_1$j = { key: 0 };
|
|
17289
|
+
const _sfc_main$Q = {
|
|
17195
17290
|
__name: "CoreLine",
|
|
17196
17291
|
props: {
|
|
17197
17292
|
x1: { type: Number, default: 0 },
|
|
@@ -17224,12 +17319,13 @@ var VVPlot = (function(exports, vue) {
|
|
|
17224
17319
|
});
|
|
17225
17320
|
return (_ctx, _cache) => {
|
|
17226
17321
|
return vue.openBlock(), vue.createElementBlock("line", vue.normalizeProps(vue.guardReactiveProps(binds.value)), [
|
|
17227
|
-
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$
|
|
17322
|
+
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$j, vue.toDisplayString(__props.title), 1)) : vue.createCommentVNode("", true)
|
|
17228
17323
|
], 16);
|
|
17229
17324
|
};
|
|
17230
17325
|
}
|
|
17231
17326
|
};
|
|
17232
|
-
const
|
|
17327
|
+
const _hoisted_1$i = { class: "vvplot-layer" };
|
|
17328
|
+
const _sfc_main$P = {
|
|
17233
17329
|
__name: "CoreSvgBoxplot",
|
|
17234
17330
|
props: {
|
|
17235
17331
|
extendX: { type: Number, default: 0 },
|
|
@@ -17387,23 +17483,23 @@ var VVPlot = (function(exports, vue) {
|
|
|
17387
17483
|
}).filter((x2) => x2 != null));
|
|
17388
17484
|
});
|
|
17389
17485
|
return (_ctx, _cache) => {
|
|
17390
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
17486
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$i, [
|
|
17391
17487
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
17392
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17488
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17393
17489
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbinds, von]) => {
|
|
17394
17490
|
return vue.openBlock(), vue.createElementBlock("g", null, [
|
|
17395
|
-
vue.createVNode(_sfc_main$
|
|
17491
|
+
vue.createVNode(_sfc_main$Q, vue.mergeProps({ ref_for: true }, vbinds.line), null, 16),
|
|
17396
17492
|
_cache[0] || (_cache[0] = vue.createTextVNode()),
|
|
17397
|
-
vue.createVNode(_sfc_main$
|
|
17493
|
+
vue.createVNode(_sfc_main$S, vue.mergeProps({ ref_for: true }, vbinds.rect, vue.toHandlers(von)), null, 16),
|
|
17398
17494
|
_cache[1] || (_cache[1] = vue.createTextVNode()),
|
|
17399
|
-
vue.createVNode(_sfc_main$
|
|
17495
|
+
vue.createVNode(_sfc_main$Q, vue.mergeProps({ ref_for: true }, vbinds.midline), null, 16),
|
|
17400
17496
|
_cache[2] || (_cache[2] = vue.createTextVNode()),
|
|
17401
|
-
vue.createVNode(_sfc_main$
|
|
17497
|
+
vue.createVNode(_sfc_main$Q, vue.mergeProps({ ref_for: true }, vbinds.uwisker), null, 16),
|
|
17402
17498
|
_cache[3] || (_cache[3] = vue.createTextVNode()),
|
|
17403
|
-
vue.createVNode(_sfc_main$
|
|
17499
|
+
vue.createVNode(_sfc_main$Q, vue.mergeProps({ ref_for: true }, vbinds.lwisker), null, 16),
|
|
17404
17500
|
_cache[4] || (_cache[4] = vue.createTextVNode()),
|
|
17405
17501
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(vbinds.outliers, ([vbind, von2]) => {
|
|
17406
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
17502
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$R, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von2)), null, 16);
|
|
17407
17503
|
}), 256))
|
|
17408
17504
|
]);
|
|
17409
17505
|
}), 256))
|
|
@@ -17413,8 +17509,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
17413
17509
|
};
|
|
17414
17510
|
}
|
|
17415
17511
|
};
|
|
17416
|
-
const _hoisted_1$
|
|
17417
|
-
const _sfc_main$
|
|
17512
|
+
const _hoisted_1$h = { key: 0 };
|
|
17513
|
+
const _sfc_main$O = {
|
|
17418
17514
|
__name: "CoreCurve",
|
|
17419
17515
|
props: {
|
|
17420
17516
|
points: { type: Array, default: () => [] },
|
|
@@ -17454,12 +17550,13 @@ var VVPlot = (function(exports, vue) {
|
|
|
17454
17550
|
};
|
|
17455
17551
|
return (_ctx, _cache) => {
|
|
17456
17552
|
return vue.openBlock(), vue.createElementBlock("path", vue.normalizeProps(vue.guardReactiveProps(binds.value)), [
|
|
17457
|
-
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$
|
|
17553
|
+
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$h, vue.toDisplayString(__props.title), 1)) : vue.createCommentVNode("", true)
|
|
17458
17554
|
], 16);
|
|
17459
17555
|
};
|
|
17460
17556
|
}
|
|
17461
17557
|
};
|
|
17462
|
-
const
|
|
17558
|
+
const _hoisted_1$g = { class: "vvplot-layer vvplot-layer-curve" };
|
|
17559
|
+
const _sfc_main$N = {
|
|
17463
17560
|
__name: "CoreSvgCurve",
|
|
17464
17561
|
props: {
|
|
17465
17562
|
extendX: { type: Number, default: 0 },
|
|
@@ -17519,11 +17616,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
17519
17616
|
}).filter((x2) => x2 != null));
|
|
17520
17617
|
});
|
|
17521
17618
|
return (_ctx, _cache) => {
|
|
17522
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
17619
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$g, [
|
|
17523
17620
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
17524
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17621
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17525
17622
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
17526
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
17623
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$O, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
17527
17624
|
}), 256))
|
|
17528
17625
|
], 16);
|
|
17529
17626
|
}), 256))
|
|
@@ -17531,8 +17628,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
17531
17628
|
};
|
|
17532
17629
|
}
|
|
17533
17630
|
};
|
|
17534
|
-
const _hoisted_1$
|
|
17535
|
-
const _sfc_main$
|
|
17631
|
+
const _hoisted_1$f = { key: 0 };
|
|
17632
|
+
const _sfc_main$M = {
|
|
17536
17633
|
__name: "CoreEllipse",
|
|
17537
17634
|
props: {
|
|
17538
17635
|
cx: { type: Number, default: 0 },
|
|
@@ -17572,12 +17669,13 @@ var VVPlot = (function(exports, vue) {
|
|
|
17572
17669
|
});
|
|
17573
17670
|
return (_ctx, _cache) => {
|
|
17574
17671
|
return vue.openBlock(), vue.createElementBlock("ellipse", vue.normalizeProps(vue.guardReactiveProps(binds.value)), [
|
|
17575
|
-
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$
|
|
17672
|
+
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$f, vue.toDisplayString(__props.title), 1)) : vue.createCommentVNode("", true)
|
|
17576
17673
|
], 16);
|
|
17577
17674
|
};
|
|
17578
17675
|
}
|
|
17579
17676
|
};
|
|
17580
|
-
const
|
|
17677
|
+
const _hoisted_1$e = { class: "vvplot-layer vvplot-layer-ellipse" };
|
|
17678
|
+
const _sfc_main$L = {
|
|
17581
17679
|
__name: "CoreSvgEllipse",
|
|
17582
17680
|
props: {
|
|
17583
17681
|
extendX: { type: Number, default: 0 },
|
|
@@ -17647,11 +17745,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
17647
17745
|
}).filter((x2) => x2 != null));
|
|
17648
17746
|
});
|
|
17649
17747
|
return (_ctx, _cache) => {
|
|
17650
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
17748
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$e, [
|
|
17651
17749
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
17652
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17750
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17653
17751
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
17654
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
17752
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$M, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
17655
17753
|
}), 256))
|
|
17656
17754
|
], 16);
|
|
17657
17755
|
}), 256))
|
|
@@ -17659,7 +17757,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
17659
17757
|
};
|
|
17660
17758
|
}
|
|
17661
17759
|
};
|
|
17662
|
-
const
|
|
17760
|
+
const _hoisted_1$d = { class: "vvplot-layer vvplot-layer-line" };
|
|
17761
|
+
const _sfc_main$K = {
|
|
17663
17762
|
__name: "CoreSvgLine",
|
|
17664
17763
|
props: {
|
|
17665
17764
|
extendX: { type: Number, default: 0 },
|
|
@@ -17722,11 +17821,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
17722
17821
|
}).filter((x2) => x2 != null));
|
|
17723
17822
|
});
|
|
17724
17823
|
return (_ctx, _cache) => {
|
|
17725
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
17824
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$d, [
|
|
17726
17825
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
17727
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17826
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17728
17827
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
17729
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
17828
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$Q, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
17730
17829
|
}), 256))
|
|
17731
17830
|
], 16);
|
|
17732
17831
|
}), 256))
|
|
@@ -17734,7 +17833,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
17734
17833
|
};
|
|
17735
17834
|
}
|
|
17736
17835
|
};
|
|
17737
|
-
const
|
|
17836
|
+
const _hoisted_1$c = { class: "vvplot-layer" };
|
|
17837
|
+
const _sfc_main$J = {
|
|
17738
17838
|
__name: "CoreSvgMarkdown",
|
|
17739
17839
|
props: {
|
|
17740
17840
|
extendX: { type: Number, default: 0 },
|
|
@@ -17821,11 +17921,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
17821
17921
|
}).filter((x2) => x2 != null));
|
|
17822
17922
|
});
|
|
17823
17923
|
return (_ctx, _cache) => {
|
|
17824
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
17924
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$c, [
|
|
17825
17925
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
17826
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17926
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17827
17927
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
17828
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
17928
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$17, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
17829
17929
|
}), 256))
|
|
17830
17930
|
], 16);
|
|
17831
17931
|
}), 256))
|
|
@@ -17833,7 +17933,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
17833
17933
|
};
|
|
17834
17934
|
}
|
|
17835
17935
|
};
|
|
17836
|
-
const
|
|
17936
|
+
const _hoisted_1$b = { class: "vvplot-layer" };
|
|
17937
|
+
const _sfc_main$I = {
|
|
17837
17938
|
__name: "CoreSvgMarkdownsegment",
|
|
17838
17939
|
props: {
|
|
17839
17940
|
extendX: { type: Number, default: 0 },
|
|
@@ -17942,11 +18043,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
17942
18043
|
}).filter((x2) => x2 != null));
|
|
17943
18044
|
});
|
|
17944
18045
|
return (_ctx, _cache) => {
|
|
17945
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
18046
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$b, [
|
|
17946
18047
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
17947
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18048
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
17948
18049
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
17949
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
18050
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$17, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
17950
18051
|
}), 256))
|
|
17951
18052
|
], 16);
|
|
17952
18053
|
}), 256))
|
|
@@ -17954,7 +18055,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
17954
18055
|
};
|
|
17955
18056
|
}
|
|
17956
18057
|
};
|
|
17957
|
-
const
|
|
18058
|
+
const _hoisted_1$a = { class: "vvplot-layer" };
|
|
18059
|
+
const _sfc_main$H = {
|
|
17958
18060
|
__name: "CoreSvgPoint",
|
|
17959
18061
|
props: {
|
|
17960
18062
|
extendX: { type: Number, default: 0 },
|
|
@@ -18021,11 +18123,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
18021
18123
|
}).filter((x2) => x2 != null));
|
|
18022
18124
|
});
|
|
18023
18125
|
return (_ctx, _cache) => {
|
|
18024
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
18126
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$a, [
|
|
18025
18127
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
18026
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18128
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18027
18129
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
18028
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
18130
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$R, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
18029
18131
|
}), 256))
|
|
18030
18132
|
], 16);
|
|
18031
18133
|
}), 256))
|
|
@@ -18033,8 +18135,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
18033
18135
|
};
|
|
18034
18136
|
}
|
|
18035
18137
|
};
|
|
18036
|
-
const _hoisted_1$
|
|
18037
|
-
const _sfc_main$
|
|
18138
|
+
const _hoisted_1$9 = { key: 0 };
|
|
18139
|
+
const _sfc_main$G = {
|
|
18038
18140
|
__name: "CorePolygon",
|
|
18039
18141
|
props: {
|
|
18040
18142
|
points: { type: Array, default: () => [] },
|
|
@@ -18063,12 +18165,13 @@ var VVPlot = (function(exports, vue) {
|
|
|
18063
18165
|
});
|
|
18064
18166
|
return (_ctx, _cache) => {
|
|
18065
18167
|
return vue.openBlock(), vue.createElementBlock("polygon", vue.normalizeProps(vue.guardReactiveProps(binds.value)), [
|
|
18066
|
-
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$
|
|
18168
|
+
__props.title ? (vue.openBlock(), vue.createElementBlock("title", _hoisted_1$9, vue.toDisplayString(__props.title), 1)) : vue.createCommentVNode("", true)
|
|
18067
18169
|
], 16);
|
|
18068
18170
|
};
|
|
18069
18171
|
}
|
|
18070
18172
|
};
|
|
18071
|
-
const
|
|
18173
|
+
const _hoisted_1$8 = { class: "vvplot-layer" };
|
|
18174
|
+
const _sfc_main$F = {
|
|
18072
18175
|
__name: "CoreSvgPolygon",
|
|
18073
18176
|
props: {
|
|
18074
18177
|
extendX: { type: Number, default: 0 },
|
|
@@ -18128,11 +18231,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
18128
18231
|
}).filter((x2) => x2 != null));
|
|
18129
18232
|
});
|
|
18130
18233
|
return (_ctx, _cache) => {
|
|
18131
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
18234
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$8, [
|
|
18132
18235
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
18133
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18236
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18134
18237
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
18135
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
18238
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$G, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
18136
18239
|
}), 256))
|
|
18137
18240
|
], 16);
|
|
18138
18241
|
}), 256))
|
|
@@ -18140,7 +18243,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
18140
18243
|
};
|
|
18141
18244
|
}
|
|
18142
18245
|
};
|
|
18143
|
-
const
|
|
18246
|
+
const _hoisted_1$7 = { class: "vvplot-layer" };
|
|
18247
|
+
const _sfc_main$E = {
|
|
18144
18248
|
__name: "CoreSvgRect",
|
|
18145
18249
|
props: {
|
|
18146
18250
|
extendX: { type: Number, default: 0 },
|
|
@@ -18200,11 +18304,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
18200
18304
|
}).filter((x2) => x2 != null));
|
|
18201
18305
|
});
|
|
18202
18306
|
return (_ctx, _cache) => {
|
|
18203
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
18307
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$7, [
|
|
18204
18308
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
18205
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18309
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18206
18310
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
18207
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
18311
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$S, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
18208
18312
|
}), 256))
|
|
18209
18313
|
], 16);
|
|
18210
18314
|
}), 256))
|
|
@@ -18212,7 +18316,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
18212
18316
|
};
|
|
18213
18317
|
}
|
|
18214
18318
|
};
|
|
18215
|
-
const
|
|
18319
|
+
const _hoisted_1$6 = { class: "vvplot-layer" };
|
|
18320
|
+
const _sfc_main$D = {
|
|
18216
18321
|
__name: "CoreSvgText",
|
|
18217
18322
|
props: {
|
|
18218
18323
|
extendX: { type: Number, default: 0 },
|
|
@@ -18299,11 +18404,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
18299
18404
|
}).filter((x2) => x2 != null));
|
|
18300
18405
|
});
|
|
18301
18406
|
return (_ctx, _cache) => {
|
|
18302
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
18407
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$6, [
|
|
18303
18408
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
18304
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18409
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18305
18410
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von]) => {
|
|
18306
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
18411
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$18, vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von)), null, 16);
|
|
18307
18412
|
}), 256))
|
|
18308
18413
|
], 16);
|
|
18309
18414
|
}), 256))
|
|
@@ -18311,7 +18416,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
18311
18416
|
};
|
|
18312
18417
|
}
|
|
18313
18418
|
};
|
|
18314
|
-
const
|
|
18419
|
+
const _hoisted_1$5 = { class: "vvplot-layer" };
|
|
18420
|
+
const _sfc_main$C = {
|
|
18315
18421
|
__name: "CoreSvgTextsegment",
|
|
18316
18422
|
props: {
|
|
18317
18423
|
extendX: { type: Number, default: 0 },
|
|
@@ -18463,9 +18569,9 @@ var VVPlot = (function(exports, vue) {
|
|
|
18463
18569
|
return result;
|
|
18464
18570
|
}
|
|
18465
18571
|
return (_ctx, _cache) => {
|
|
18466
|
-
return vue.openBlock(), vue.createElementBlock("g",
|
|
18572
|
+
return vue.openBlock(), vue.createElementBlock("g", _hoisted_1$5, [
|
|
18467
18573
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(binds.value, (group) => {
|
|
18468
|
-
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18574
|
+
return vue.openBlock(), vue.createElementBlock("g", vue.mergeProps({ class: "vvplot-group" }, { ref_for: true }, { class: __props.groupClass, style: __props.groupStyle }), [
|
|
18469
18575
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(group, ([vbind, von, content, title]) => {
|
|
18470
18576
|
return vue.openBlock(), vue.createElementBlock("text", vue.mergeProps({ ref_for: true }, vbind, vue.toHandlers(von, true)), [
|
|
18471
18577
|
vue.createElementVNode("title", null, vue.toDisplayString(title), 1),
|
|
@@ -18490,23 +18596,23 @@ var VVPlot = (function(exports, vue) {
|
|
|
18490
18596
|
};
|
|
18491
18597
|
const svg = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
18492
18598
|
__proto__: null,
|
|
18493
|
-
blank: _sfc_main$
|
|
18494
|
-
boxplot: _sfc_main$
|
|
18495
|
-
curve: _sfc_main$
|
|
18496
|
-
ellipse: _sfc_main$
|
|
18497
|
-
line: _sfc_main$
|
|
18498
|
-
markdown: _sfc_main$
|
|
18499
|
-
markdownsegment: _sfc_main$
|
|
18500
|
-
point: _sfc_main$
|
|
18501
|
-
polygon: _sfc_main$
|
|
18502
|
-
rect: _sfc_main$
|
|
18503
|
-
shape: _sfc_main$
|
|
18504
|
-
stick: _sfc_main$
|
|
18505
|
-
text: _sfc_main$
|
|
18506
|
-
textsegment: _sfc_main$
|
|
18507
|
-
tile: _sfc_main$
|
|
18599
|
+
blank: _sfc_main$T,
|
|
18600
|
+
boxplot: _sfc_main$P,
|
|
18601
|
+
curve: _sfc_main$N,
|
|
18602
|
+
ellipse: _sfc_main$L,
|
|
18603
|
+
line: _sfc_main$K,
|
|
18604
|
+
markdown: _sfc_main$J,
|
|
18605
|
+
markdownsegment: _sfc_main$I,
|
|
18606
|
+
point: _sfc_main$H,
|
|
18607
|
+
polygon: _sfc_main$F,
|
|
18608
|
+
rect: _sfc_main$E,
|
|
18609
|
+
shape: _sfc_main$N,
|
|
18610
|
+
stick: _sfc_main$K,
|
|
18611
|
+
text: _sfc_main$D,
|
|
18612
|
+
textsegment: _sfc_main$C,
|
|
18613
|
+
tile: _sfc_main$E
|
|
18508
18614
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
18509
|
-
const _sfc_main$
|
|
18615
|
+
const _sfc_main$B = {
|
|
18510
18616
|
__name: "CoreLayer",
|
|
18511
18617
|
props: {
|
|
18512
18618
|
data: Object,
|
|
@@ -18547,7 +18653,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18547
18653
|
};
|
|
18548
18654
|
const _hoisted_1$4 = { key: 0 };
|
|
18549
18655
|
const _hoisted_2$3 = ["onPointerdown"];
|
|
18550
|
-
const _sfc_main$
|
|
18656
|
+
const _sfc_main$A = {
|
|
18551
18657
|
__name: "CoreSelection",
|
|
18552
18658
|
props: /* @__PURE__ */ vue.mergeModels({
|
|
18553
18659
|
coord2pos: Function,
|
|
@@ -18636,9 +18742,6 @@ var VVPlot = (function(exports, vue) {
|
|
|
18636
18742
|
transform2.push(`scale(${sclH}, ${sclV})`);
|
|
18637
18743
|
return transform2.join(" ") || null;
|
|
18638
18744
|
});
|
|
18639
|
-
const translating = vue.computed(
|
|
18640
|
-
() => __props.activeTransform.translateH != 0 || __props.activeTransform.translateV != 0 || __props.activeTransform.scaleH != 1 || __props.activeTransform.scaleV != 1
|
|
18641
|
-
);
|
|
18642
18745
|
const rectBind = vue.computed(() => {
|
|
18643
18746
|
if (!position.value) return null;
|
|
18644
18747
|
let { hmin, hmax, vmin, vmax, pos } = position.value;
|
|
@@ -18663,7 +18766,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18663
18766
|
};
|
|
18664
18767
|
});
|
|
18665
18768
|
const interactiveBind = vue.computed(() => {
|
|
18666
|
-
if (!position.value
|
|
18769
|
+
if (!position.value) return null;
|
|
18667
18770
|
let size = 10;
|
|
18668
18771
|
let { hmin, hmax, vmin, vmax, pos } = position.value;
|
|
18669
18772
|
let width = Math.max(0, hmax - hmin), height = Math.max(0, vmax - vmin);
|
|
@@ -18678,7 +18781,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18678
18781
|
};
|
|
18679
18782
|
if (config.resize) {
|
|
18680
18783
|
if (pos.hmin != null)
|
|
18681
|
-
binds.l = { x: hmin - size / 2, y: vmin, width: size, height, style: "cursor:ew-resize;"
|
|
18784
|
+
binds.l = { x: hmin - size / 2, y: vmin, width: size, height, style: "cursor:ew-resize;" };
|
|
18682
18785
|
if (pos.hmax != null)
|
|
18683
18786
|
binds.r = { x: hmax - size / 2, y: vmin, width: size, height, style: "cursor:ew-resize;" };
|
|
18684
18787
|
if (pos.vmin != null)
|
|
@@ -18758,8 +18861,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18758
18861
|
if (ymin > ymax) [ymin, ymax] = [ymax, ymin];
|
|
18759
18862
|
emit("selecting", { xmin, xmax, ymin, ymax }, __props.theme);
|
|
18760
18863
|
};
|
|
18761
|
-
e.target.
|
|
18762
|
-
ev.currentTarget.onpointerup = null;
|
|
18864
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
18763
18865
|
ev.currentTarget.onpointermove = null;
|
|
18764
18866
|
if (config.buttons & 1) {
|
|
18765
18867
|
ev.currentTarget.onclick = (event2) => {
|
|
@@ -18785,7 +18887,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18785
18887
|
model.value = dropNull(res);
|
|
18786
18888
|
emit("selectend");
|
|
18787
18889
|
emit("select", dropNull(res), event);
|
|
18788
|
-
};
|
|
18890
|
+
}, { once: true });
|
|
18789
18891
|
}
|
|
18790
18892
|
return (_ctx, _cache) => {
|
|
18791
18893
|
return rectBind.value ? (vue.openBlock(), vue.createElementBlock("g", _hoisted_1$4, [
|
|
@@ -18804,7 +18906,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18804
18906
|
const _hoisted_1$3 = ["height", "width"];
|
|
18805
18907
|
const _hoisted_2$2 = ["y1", "y2"];
|
|
18806
18908
|
const _hoisted_3$2 = ["y"];
|
|
18807
|
-
const _sfc_main$
|
|
18909
|
+
const _sfc_main$z = {
|
|
18808
18910
|
__name: "CoreGuideGradientbar",
|
|
18809
18911
|
props: {
|
|
18810
18912
|
scales: Array,
|
|
@@ -18844,7 +18946,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18844
18946
|
ref: "svg"
|
|
18845
18947
|
}, [
|
|
18846
18948
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(gradient_values.value, (v, i) => {
|
|
18847
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
18949
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$S, vue.mergeProps({
|
|
18848
18950
|
width: 10,
|
|
18849
18951
|
height: 3.1,
|
|
18850
18952
|
x: 10,
|
|
@@ -18876,12 +18978,12 @@ var VVPlot = (function(exports, vue) {
|
|
|
18876
18978
|
};
|
|
18877
18979
|
const element = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
18878
18980
|
__proto__: null,
|
|
18879
|
-
curve: _sfc_main$
|
|
18880
|
-
line: _sfc_main$
|
|
18881
|
-
point: _sfc_main$
|
|
18882
|
-
polygon: _sfc_main$
|
|
18883
|
-
text: _sfc_main$
|
|
18884
|
-
tile: _sfc_main$
|
|
18981
|
+
curve: _sfc_main$O,
|
|
18982
|
+
line: _sfc_main$Q,
|
|
18983
|
+
point: _sfc_main$R,
|
|
18984
|
+
polygon: _sfc_main$G,
|
|
18985
|
+
text: _sfc_main$18,
|
|
18986
|
+
tile: _sfc_main$S
|
|
18885
18987
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
18886
18988
|
const _hoisted_1$2 = ["height", "width"];
|
|
18887
18989
|
const _hoisted_2$1 = ["transform"];
|
|
@@ -18891,7 +18993,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18891
18993
|
y: "10",
|
|
18892
18994
|
"alignment-baseline": "central"
|
|
18893
18995
|
};
|
|
18894
|
-
const _sfc_main$
|
|
18996
|
+
const _sfc_main$y = {
|
|
18895
18997
|
__name: "CoreGuideLegendkey",
|
|
18896
18998
|
props: {
|
|
18897
18999
|
scales: Array,
|
|
@@ -18958,7 +19060,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
18958
19060
|
};
|
|
18959
19061
|
}
|
|
18960
19062
|
};
|
|
18961
|
-
const _sfc_main$
|
|
19063
|
+
const _sfc_main$x = /* @__PURE__ */ Object.assign({ inheritAttrs: false }, {
|
|
18962
19064
|
__name: "CoreGuide",
|
|
18963
19065
|
props: {
|
|
18964
19066
|
scales: Array,
|
|
@@ -18966,8 +19068,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
18966
19068
|
},
|
|
18967
19069
|
setup(__props) {
|
|
18968
19070
|
const guide = {
|
|
18969
|
-
legendkey: _sfc_main$
|
|
18970
|
-
gradientbar: _sfc_main$
|
|
19071
|
+
legendkey: _sfc_main$y,
|
|
19072
|
+
gradientbar: _sfc_main$z
|
|
18971
19073
|
};
|
|
18972
19074
|
const title = vue.computed(() => {
|
|
18973
19075
|
return __props.scales.reduce((v, [s]) => v ?? s.title, null) ?? __props.scales.reduce((v, [s]) => v ?? s._title, null);
|
|
@@ -19011,7 +19113,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19011
19113
|
};
|
|
19012
19114
|
}
|
|
19013
19115
|
});
|
|
19014
|
-
const _sfc_main$
|
|
19116
|
+
const _sfc_main$w = {
|
|
19015
19117
|
__name: "CoreLegend",
|
|
19016
19118
|
props: {
|
|
19017
19119
|
theme: { type: Object, default: () => ({}) },
|
|
@@ -19045,7 +19147,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19045
19147
|
style: vue.normalizeStyle({ gap: __props.theme.spacing + "px" })
|
|
19046
19148
|
}, [
|
|
19047
19149
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(guides.value, ([[key, type], scales]) => {
|
|
19048
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
19150
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$x, {
|
|
19049
19151
|
key,
|
|
19050
19152
|
type,
|
|
19051
19153
|
scales
|
|
@@ -19059,11 +19161,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
19059
19161
|
const _hoisted_2 = ["width", "height"];
|
|
19060
19162
|
const _hoisted_3 = ["transform", "width", "height", "fill"];
|
|
19061
19163
|
const _hoisted_4 = ["transform"];
|
|
19062
|
-
const _hoisted_5 = ["transform"
|
|
19063
|
-
const _hoisted_6 = ["
|
|
19064
|
-
const _hoisted_7 = ["clip-path"];
|
|
19164
|
+
const _hoisted_5 = ["transform"];
|
|
19165
|
+
const _hoisted_6 = ["clip-path"];
|
|
19166
|
+
const _hoisted_7 = ["transform", "clip-path"];
|
|
19065
19167
|
const _hoisted_8 = { key: 1 };
|
|
19066
|
-
const _sfc_main$
|
|
19168
|
+
const _sfc_main$v = /* @__PURE__ */ Object.assign({ inheritAttrs: false }, {
|
|
19067
19169
|
__name: "CorePlot",
|
|
19068
19170
|
props: /* @__PURE__ */ vue.mergeModels({
|
|
19069
19171
|
schema: Object,
|
|
@@ -19107,6 +19209,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19107
19209
|
"pointermove",
|
|
19108
19210
|
"wheel",
|
|
19109
19211
|
"select",
|
|
19212
|
+
"selecting",
|
|
19110
19213
|
"move",
|
|
19111
19214
|
"zoom",
|
|
19112
19215
|
"rescale",
|
|
@@ -19414,11 +19517,13 @@ var VVPlot = (function(exports, vue) {
|
|
|
19414
19517
|
res.ymin = ystart > yend ? yend : ystart;
|
|
19415
19518
|
res.ymax = ystart > yend ? ystart : yend;
|
|
19416
19519
|
}
|
|
19520
|
+
if (!emitEvent(sel["onSelecting"], dropNull(res), sel.theme)) {
|
|
19521
|
+
emit("selecting", dropNull(res), sel.theme);
|
|
19522
|
+
}
|
|
19417
19523
|
selectionPreview.value = res;
|
|
19418
19524
|
selectionPreviewTheme.value = sel.theme;
|
|
19419
19525
|
};
|
|
19420
|
-
e.target.
|
|
19421
|
-
ev.currentTarget.onpointerup = null;
|
|
19526
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
19422
19527
|
ev.currentTarget.onpointermove = null;
|
|
19423
19528
|
svg2.style.userSelect = null;
|
|
19424
19529
|
selectionPreview.value = {};
|
|
@@ -19466,7 +19571,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19466
19571
|
emit("select", dropNull(res), event);
|
|
19467
19572
|
}
|
|
19468
19573
|
}
|
|
19469
|
-
};
|
|
19574
|
+
}, { once: true });
|
|
19470
19575
|
return;
|
|
19471
19576
|
}
|
|
19472
19577
|
let act = props.action.find((a) => a.action == "move" && ["buttons", "ctrlKey", "shiftKey", "altKey", "metaKey"].every((k) => a[k] == e[k]));
|
|
@@ -19496,15 +19601,14 @@ var VVPlot = (function(exports, vue) {
|
|
|
19496
19601
|
let { xmin, xmax, ymin, ymax } = pos2coord({ hmin: h1, hmax: h2, vmin: v1, vmax: v2 });
|
|
19497
19602
|
Object.assign(rangePreview, { xmin, xmax, ymin, ymax });
|
|
19498
19603
|
};
|
|
19499
|
-
e.target.
|
|
19500
|
-
ev.currentTarget.onpointerup = null;
|
|
19604
|
+
e.target.addEventListener("pointerup", function(ev) {
|
|
19501
19605
|
ev.currentTarget.onpointermove = null;
|
|
19502
19606
|
svg2.style.userSelect = null;
|
|
19503
19607
|
moveTimer = setTimeout(() => {
|
|
19504
19608
|
applyTransform(act, ev);
|
|
19505
19609
|
movementX = movementY = 0;
|
|
19506
19610
|
}, 300);
|
|
19507
|
-
};
|
|
19611
|
+
}, { once: true });
|
|
19508
19612
|
return;
|
|
19509
19613
|
}
|
|
19510
19614
|
}
|
|
@@ -19762,7 +19866,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19762
19866
|
transform: `translate(${vue.unref(panel).left}, ${vue.unref(panel).top})`,
|
|
19763
19867
|
style: { "pointer-events": "none" }
|
|
19764
19868
|
}, [
|
|
19765
|
-
vue.createVNode(_sfc_main$
|
|
19869
|
+
vue.createVNode(_sfc_main$12, {
|
|
19766
19870
|
breaks: gridBreaks.value.h,
|
|
19767
19871
|
layout: vue.unref(innerRect),
|
|
19768
19872
|
activeTransform: activeTransform.value,
|
|
@@ -19770,7 +19874,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19770
19874
|
transition: transition.value
|
|
19771
19875
|
}, null, 8, ["breaks", "layout", "activeTransform", "transition"]),
|
|
19772
19876
|
_cache[2] || (_cache[2] = vue.createTextVNode()),
|
|
19773
|
-
vue.createVNode(_sfc_main$
|
|
19877
|
+
vue.createVNode(_sfc_main$11, {
|
|
19774
19878
|
breaks: gridBreaks.value.v,
|
|
19775
19879
|
layout: vue.unref(innerRect),
|
|
19776
19880
|
activeTransform: activeTransform.value,
|
|
@@ -19779,6 +19883,30 @@ var VVPlot = (function(exports, vue) {
|
|
|
19779
19883
|
}, null, 8, ["breaks", "layout", "activeTransform", "transition"])
|
|
19780
19884
|
], 8, _hoisted_4),
|
|
19781
19885
|
_cache[8] || (_cache[8] = vue.createTextVNode()),
|
|
19886
|
+
vue.createElementVNode("g", {
|
|
19887
|
+
transform: `translate(${vue.unref(panel).left}, ${vue.unref(panel).top})`
|
|
19888
|
+
}, [
|
|
19889
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(axes.value.filter((a) => typeof a.bind.position !== "number"), (axis) => {
|
|
19890
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$13, vue.mergeProps({ ref_for: true }, axis.bind, vue.toHandlers(axis.on), {
|
|
19891
|
+
transition: transition.value,
|
|
19892
|
+
"onUpdate:transition": _cache[0] || (_cache[0] = ($event) => transition.value = $event),
|
|
19893
|
+
activeTransform: activeTransform.value
|
|
19894
|
+
}), null, 16, ["transition", "activeTransform"]);
|
|
19895
|
+
}), 256)),
|
|
19896
|
+
_cache[3] || (_cache[3] = vue.createTextVNode()),
|
|
19897
|
+
vue.createElementVNode("g", {
|
|
19898
|
+
"clip-path": props.clip ? `url(#${vue.unref(vid)}-plot-clip)` : null
|
|
19899
|
+
}, [
|
|
19900
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(axes.value.filter((a) => typeof a.bind.position === "number"), (axis) => {
|
|
19901
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$13, vue.mergeProps({ ref_for: true }, axis.bind, vue.toHandlers(axis.on), {
|
|
19902
|
+
transition: transition.value,
|
|
19903
|
+
"onUpdate:transition": _cache[1] || (_cache[1] = ($event) => transition.value = $event),
|
|
19904
|
+
activeTransform: activeTransform.value
|
|
19905
|
+
}), null, 16, ["transition", "activeTransform"]);
|
|
19906
|
+
}), 256))
|
|
19907
|
+
], 8, _hoisted_6)
|
|
19908
|
+
], 8, _hoisted_5),
|
|
19909
|
+
_cache[9] || (_cache[9] = vue.createTextVNode()),
|
|
19782
19910
|
vue.createElementVNode("g", {
|
|
19783
19911
|
transform: `translate(${vue.unref(panel).left}, ${vue.unref(panel).top})`,
|
|
19784
19912
|
"clip-path": props.clip ? `url(#${vue.unref(vid)}-plot-clip)` : null
|
|
@@ -19787,7 +19915,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19787
19915
|
style: { transition: transition.value }
|
|
19788
19916
|
}), [
|
|
19789
19917
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(vplot.value.layers, (layer) => {
|
|
19790
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
19918
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$B, vue.mergeProps({
|
|
19791
19919
|
ref_for: true,
|
|
19792
19920
|
ref_key: "layers",
|
|
19793
19921
|
ref: layers,
|
|
@@ -19802,9 +19930,9 @@ var VVPlot = (function(exports, vue) {
|
|
|
19802
19930
|
}), null, 16, ["data", "layout", "geom", "default-render", "default-dpi"]);
|
|
19803
19931
|
}), 256))
|
|
19804
19932
|
], 16),
|
|
19805
|
-
_cache[
|
|
19933
|
+
_cache[4] || (_cache[4] = vue.createTextVNode()),
|
|
19806
19934
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(props.selections, (sel) => {
|
|
19807
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$
|
|
19935
|
+
return vue.openBlock(), vue.createBlock(_sfc_main$A, vue.mergeProps({
|
|
19808
19936
|
coord2pos,
|
|
19809
19937
|
pos2coord,
|
|
19810
19938
|
layout: vue.unref(innerRect),
|
|
@@ -19814,8 +19942,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
19814
19942
|
activeTransform: activeTransform.value
|
|
19815
19943
|
}, { ref_for: true }, sel, { flip: __props.flip }), null, 16, ["layout", "transition", "activeTransform", "flip"]);
|
|
19816
19944
|
}), 256)),
|
|
19817
|
-
_cache[
|
|
19818
|
-
vue.createVNode(_sfc_main$
|
|
19945
|
+
_cache[5] || (_cache[5] = vue.createTextVNode()),
|
|
19946
|
+
vue.createVNode(_sfc_main$A, {
|
|
19819
19947
|
coord2pos,
|
|
19820
19948
|
pos2coord,
|
|
19821
19949
|
layout: vue.unref(innerRect),
|
|
@@ -19825,31 +19953,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19825
19953
|
theme: _selectionPreviewTheme.value,
|
|
19826
19954
|
flip: __props.flip
|
|
19827
19955
|
}, null, 8, ["layout", "modelValue", "transition", "activeTransform", "theme", "flip"])
|
|
19828
|
-
], 8,
|
|
19829
|
-
_cache[9] || (_cache[9] = vue.createTextVNode()),
|
|
19830
|
-
vue.createElementVNode("g", {
|
|
19831
|
-
transform: `translate(${vue.unref(panel).left}, ${vue.unref(panel).top})`
|
|
19832
|
-
}, [
|
|
19833
|
-
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(axes.value.filter((a) => typeof a.bind.position !== "number"), (axis) => {
|
|
19834
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$12, vue.mergeProps({ ref_for: true }, axis.bind, vue.toHandlers(axis.on), {
|
|
19835
|
-
transition: transition.value,
|
|
19836
|
-
"onUpdate:transition": _cache[0] || (_cache[0] = ($event) => transition.value = $event),
|
|
19837
|
-
activeTransform: activeTransform.value
|
|
19838
|
-
}), null, 16, ["transition", "activeTransform"]);
|
|
19839
|
-
}), 256)),
|
|
19840
|
-
_cache[5] || (_cache[5] = vue.createTextVNode()),
|
|
19841
|
-
vue.createElementVNode("g", {
|
|
19842
|
-
"clip-path": props.clip ? `url(#${vue.unref(vid)}-plot-clip)` : null
|
|
19843
|
-
}, [
|
|
19844
|
-
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(axes.value.filter((a) => typeof a.bind.position === "number"), (axis) => {
|
|
19845
|
-
return vue.openBlock(), vue.createBlock(_sfc_main$12, vue.mergeProps({ ref_for: true }, axis.bind, vue.toHandlers(axis.on), {
|
|
19846
|
-
transition: transition.value,
|
|
19847
|
-
"onUpdate:transition": _cache[1] || (_cache[1] = ($event) => transition.value = $event),
|
|
19848
|
-
activeTransform: activeTransform.value
|
|
19849
|
-
}), null, 16, ["transition", "activeTransform"]);
|
|
19850
|
-
}), 256))
|
|
19851
|
-
], 8, _hoisted_7)
|
|
19852
|
-
], 8, _hoisted_6),
|
|
19956
|
+
], 8, _hoisted_7),
|
|
19853
19957
|
_cache[10] || (_cache[10] = vue.createTextVNode()),
|
|
19854
19958
|
vue.renderSlot(_ctx.$slots, "default"),
|
|
19855
19959
|
_cache[11] || (_cache[11] = vue.createTextVNode()),
|
|
@@ -19858,7 +19962,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
19858
19962
|
defer: "",
|
|
19859
19963
|
to: props.legendTeleport
|
|
19860
19964
|
}, [
|
|
19861
|
-
vue.createVNode(_sfc_main$
|
|
19965
|
+
vue.createVNode(_sfc_main$w, {
|
|
19862
19966
|
scales: vplot.value?.scales,
|
|
19863
19967
|
theme: __props.theme.legend
|
|
19864
19968
|
}, null, 8, ["scales", "theme"])
|
|
@@ -19868,14 +19972,14 @@ var VVPlot = (function(exports, vue) {
|
|
|
19868
19972
|
};
|
|
19869
19973
|
}
|
|
19870
19974
|
});
|
|
19871
|
-
const _sfc_main$
|
|
19975
|
+
const _sfc_main$u = {
|
|
19872
19976
|
$_type: "action",
|
|
19873
19977
|
$_props: {}
|
|
19874
19978
|
};
|
|
19875
|
-
const _sfc_main$
|
|
19979
|
+
const _sfc_main$t = {
|
|
19876
19980
|
$_type: "layer"
|
|
19877
19981
|
};
|
|
19878
|
-
const _sfc_main$
|
|
19982
|
+
const _sfc_main$s = {
|
|
19879
19983
|
$_props: {
|
|
19880
19984
|
geom: "tile",
|
|
19881
19985
|
stat: "bar"
|
|
@@ -19883,14 +19987,14 @@ var VVPlot = (function(exports, vue) {
|
|
|
19883
19987
|
$_type: "layer",
|
|
19884
19988
|
$_argnames: ["width", "height", "position"]
|
|
19885
19989
|
};
|
|
19886
|
-
const _sfc_main$
|
|
19990
|
+
const _sfc_main$r = {
|
|
19887
19991
|
$_props: {
|
|
19888
19992
|
geom: "blank",
|
|
19889
19993
|
stat: "identity"
|
|
19890
19994
|
},
|
|
19891
19995
|
$_type: "layer"
|
|
19892
19996
|
};
|
|
19893
|
-
const _sfc_main$
|
|
19997
|
+
const _sfc_main$q = {
|
|
19894
19998
|
$_props: {
|
|
19895
19999
|
geom: "boxplot",
|
|
19896
20000
|
stat: "boxplot"
|
|
@@ -19898,6 +20002,14 @@ var VVPlot = (function(exports, vue) {
|
|
|
19898
20002
|
$_type: "layer",
|
|
19899
20003
|
$_argnames: ["width", "height", "position"]
|
|
19900
20004
|
};
|
|
20005
|
+
const _sfc_main$p = {
|
|
20006
|
+
$_props: {
|
|
20007
|
+
geom: "tile",
|
|
20008
|
+
stat: "col"
|
|
20009
|
+
},
|
|
20010
|
+
$_type: "layer",
|
|
20011
|
+
$_argnames: ["width", "height", "position", "orientation"]
|
|
20012
|
+
};
|
|
19901
20013
|
const _sfc_main$o = {
|
|
19902
20014
|
$_props: {
|
|
19903
20015
|
geom: "curve",
|
|
@@ -20047,10 +20159,11 @@ var VVPlot = (function(exports, vue) {
|
|
|
20047
20159
|
};
|
|
20048
20160
|
const geom_components = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
20049
20161
|
__proto__: null,
|
|
20050
|
-
VVGeom: _sfc_main$
|
|
20051
|
-
VVGeomBar: _sfc_main$
|
|
20052
|
-
VVGeomBlank: _sfc_main$
|
|
20053
|
-
VVGeomBoxplot: _sfc_main$
|
|
20162
|
+
VVGeom: _sfc_main$t,
|
|
20163
|
+
VVGeomBar: _sfc_main$s,
|
|
20164
|
+
VVGeomBlank: _sfc_main$r,
|
|
20165
|
+
VVGeomBoxplot: _sfc_main$q,
|
|
20166
|
+
VVGeomCol: _sfc_main$p,
|
|
20054
20167
|
VVGeomCurve: _sfc_main$o,
|
|
20055
20168
|
VVGeomDensity: _sfc_main$n,
|
|
20056
20169
|
VVGeomEllipse: _sfc_main$m,
|
|
@@ -20139,8 +20252,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
20139
20252
|
const components = {
|
|
20140
20253
|
...geom_components,
|
|
20141
20254
|
...axis_components,
|
|
20142
|
-
VVAction: _sfc_main$
|
|
20143
|
-
VVSelection: _sfc_main$
|
|
20255
|
+
VVAction: _sfc_main$u,
|
|
20256
|
+
VVSelection: _sfc_main$u
|
|
20144
20257
|
};
|
|
20145
20258
|
const opponents = {
|
|
20146
20259
|
x: "y",
|
|
@@ -20197,8 +20310,12 @@ var VVPlot = (function(exports, vue) {
|
|
|
20197
20310
|
}
|
|
20198
20311
|
}).filter((x2) => x2 != null);
|
|
20199
20312
|
let res = Object.groupBy(comps, (c) => c.type.$_type ?? "dom");
|
|
20200
|
-
for (let type in
|
|
20201
|
-
|
|
20313
|
+
for (let type in vnodes) {
|
|
20314
|
+
if (res[type] == null) {
|
|
20315
|
+
delete vnodes[type][key];
|
|
20316
|
+
} else {
|
|
20317
|
+
vnodes[type][key] = res[type];
|
|
20318
|
+
}
|
|
20202
20319
|
}
|
|
20203
20320
|
}, { immediate: true });
|
|
20204
20321
|
}
|
|
@@ -20605,6 +20722,8 @@ var VVPlot = (function(exports, vue) {
|
|
|
20605
20722
|
const plotRef = vue.useTemplateRef("plot");
|
|
20606
20723
|
const width = vue.useModel(__props, "width");
|
|
20607
20724
|
const height = vue.useModel(__props, "height");
|
|
20725
|
+
const visible = vue.ref(null);
|
|
20726
|
+
vue.provide("vvplot-visible", visible);
|
|
20608
20727
|
vue.onMounted(() => {
|
|
20609
20728
|
vue.watch(width, (v) => {
|
|
20610
20729
|
wrapperRef.value.style.width = str_c(v, "px") ?? null;
|
|
@@ -20614,8 +20733,10 @@ var VVPlot = (function(exports, vue) {
|
|
|
20614
20733
|
}, { immediate: true });
|
|
20615
20734
|
});
|
|
20616
20735
|
let oldSize = { width: 0, height: 0 };
|
|
20617
|
-
useResizeObserver(plotRef, (
|
|
20618
|
-
|
|
20736
|
+
useResizeObserver(plotRef, ([entry]) => {
|
|
20737
|
+
visible.value = entry.target.getClientRects().length > 0;
|
|
20738
|
+
if (!visible.value) return;
|
|
20739
|
+
let { width: w, height: h } = entry.contentRect;
|
|
20619
20740
|
if (width.value - w < 0.5 && height.value - h < 0.5) return;
|
|
20620
20741
|
if (wrapperRef.value.style.width) width.value = w;
|
|
20621
20742
|
if (wrapperRef.value.style.height) height.value = h;
|
|
@@ -20658,7 +20779,7 @@ var VVPlot = (function(exports, vue) {
|
|
|
20658
20779
|
class: "vvplot",
|
|
20659
20780
|
style: wrapperStyle.value
|
|
20660
20781
|
}, vBind.value.wrapper), [
|
|
20661
|
-
vue.createVNode(_sfc_main$
|
|
20782
|
+
vue.createVNode(_sfc_main$v, vue.mergeProps({
|
|
20662
20783
|
ref: "plot",
|
|
20663
20784
|
paddings,
|
|
20664
20785
|
schema: schema.value,
|
|
@@ -20720,15 +20841,16 @@ var VVPlot = (function(exports, vue) {
|
|
|
20720
20841
|
};
|
|
20721
20842
|
const index = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
20722
20843
|
__proto__: null,
|
|
20723
|
-
VVAction: _sfc_main$
|
|
20844
|
+
VVAction: _sfc_main$u,
|
|
20724
20845
|
VVAxis: _sfc_main$5,
|
|
20725
20846
|
VVAxisBreak: _sfc_main$2,
|
|
20726
20847
|
VVAxisX: _sfc_main$4,
|
|
20727
20848
|
VVAxisY: _sfc_main$3,
|
|
20728
|
-
VVGeom: _sfc_main$
|
|
20729
|
-
VVGeomBar: _sfc_main$
|
|
20730
|
-
VVGeomBlank: _sfc_main$
|
|
20731
|
-
VVGeomBoxplot: _sfc_main$
|
|
20849
|
+
VVGeom: _sfc_main$t,
|
|
20850
|
+
VVGeomBar: _sfc_main$s,
|
|
20851
|
+
VVGeomBlank: _sfc_main$r,
|
|
20852
|
+
VVGeomBoxplot: _sfc_main$q,
|
|
20853
|
+
VVGeomCol: _sfc_main$p,
|
|
20732
20854
|
VVGeomCurve: _sfc_main$o,
|
|
20733
20855
|
VVGeomDensity: _sfc_main$n,
|
|
20734
20856
|
VVGeomEllipse: _sfc_main$m,
|
|
@@ -20751,15 +20873,16 @@ var VVPlot = (function(exports, vue) {
|
|
|
20751
20873
|
VVPlot: _sfc_main$1,
|
|
20752
20874
|
VVSelection: _sfc_main
|
|
20753
20875
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
20754
|
-
exports.VVAction = _sfc_main$
|
|
20876
|
+
exports.VVAction = _sfc_main$u;
|
|
20755
20877
|
exports.VVAxis = _sfc_main$5;
|
|
20756
20878
|
exports.VVAxisBreak = _sfc_main$2;
|
|
20757
20879
|
exports.VVAxisX = _sfc_main$4;
|
|
20758
20880
|
exports.VVAxisY = _sfc_main$3;
|
|
20759
|
-
exports.VVGeom = _sfc_main$
|
|
20760
|
-
exports.VVGeomBar = _sfc_main$
|
|
20761
|
-
exports.VVGeomBlank = _sfc_main$
|
|
20762
|
-
exports.VVGeomBoxplot = _sfc_main$
|
|
20881
|
+
exports.VVGeom = _sfc_main$t;
|
|
20882
|
+
exports.VVGeomBar = _sfc_main$s;
|
|
20883
|
+
exports.VVGeomBlank = _sfc_main$r;
|
|
20884
|
+
exports.VVGeomBoxplot = _sfc_main$q;
|
|
20885
|
+
exports.VVGeomCol = _sfc_main$p;
|
|
20763
20886
|
exports.VVGeomCurve = _sfc_main$o;
|
|
20764
20887
|
exports.VVGeomDensity = _sfc_main$n;
|
|
20765
20888
|
exports.VVGeomEllipse = _sfc_main$m;
|