vue-data-ui 2.3.2 → 2.3.4
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/Arrow-B6gJebT9.js +101 -0
- package/dist/Arrow-C5yj6zwY.cjs +1 -0
- package/dist/BaseIcon-7_g11dRj.js +174 -0
- package/dist/BaseIcon-JtWoVorZ.cjs +1 -0
- package/dist/DataTable-CwaOlAsy.js +127 -0
- package/dist/DataTable-Rm9II-m2.cjs +1 -0
- package/dist/Legend-CxvJTjEm.js +62 -0
- package/dist/Legend-D59FIuMs.cjs +1 -0
- package/dist/Shape-CVItL3vh.cjs +1 -0
- package/dist/Shape-CjLV0scA.js +107 -0
- package/dist/Slicer-Bxg5niHl.js +156 -0
- package/dist/Slicer-Cdss5Rus.cjs +1 -0
- package/dist/Title-2iks1ziC.js +46 -0
- package/dist/Title-Bb-A5OSV.cjs +1 -0
- package/dist/Tooltip-C3phqKuU.js +94 -0
- package/dist/Tooltip-C_UE6y-E.cjs +1 -0
- package/dist/_plugin-vue_export-helper-BHFhmbuH.cjs +1 -0
- package/dist/_plugin-vue_export-helper-CHgC5LLL.js +9 -0
- package/dist/html2canvas.esm-BA_v9SIU.cjs +22 -0
- package/dist/html2canvas.esm-d2sM-0Wm.js +4870 -0
- package/dist/index-p5gfZSvB.cjs +4 -0
- package/dist/index-uOtklCCx.js +10268 -0
- package/dist/{index.es-BoVO5twe.js → index.es-YufTdp0y.js} +1 -1
- package/dist/{index.es-w_iDpZ-o.cjs → index.es-uyeSCnWE.cjs} +1 -1
- package/dist/jspdf.es.min-C660YX78.js +8038 -0
- package/dist/jspdf.es.min-DLYY9DTT.cjs +243 -0
- package/dist/pdf-97UbtKC2.js +44 -0
- package/dist/pdf-Cz3729tZ.cjs +1 -0
- package/dist/style.css +1 -1
- package/dist/useNestedProp-2kIU-7On.cjs +1 -0
- package/dist/useNestedProp-BgWkUab_.js +13 -0
- package/dist/usePrinter-B6xQCyL-.js +464 -0
- package/dist/usePrinter-fZlsJid8.cjs +1 -0
- package/dist/useResponsive-B3TrDDIG.cjs +1 -0
- package/dist/useResponsive-NZB-WLRF.js +187 -0
- package/dist/vue-data-ui-Be0rgmbA.cjs +9 -0
- package/dist/vue-data-ui-Ccy6rBZN.js +246 -0
- package/dist/vue-data-ui.cjs +1 -1
- package/dist/vue-data-ui.js +62 -61
- package/dist/vue-ui-3d-bar-BKMPFDi2.js +1085 -0
- package/dist/vue-ui-3d-bar-CKa4UXq4.cjs +19 -0
- package/dist/vue-ui-accordion-C_pwrAJl.cjs +1 -0
- package/dist/vue-ui-accordion-HJPf7My0.js +77 -0
- package/dist/vue-ui-age-pyramid-CE1xnA-8.cjs +1 -0
- package/dist/vue-ui-age-pyramid-DB_CL-gu.js +596 -0
- package/dist/vue-ui-annotator-BAMZcPlH.cjs +371 -0
- package/dist/vue-ui-annotator-DQsAL-nZ.js +2177 -0
- package/dist/vue-ui-candlestick-DCl8fpNu.js +657 -0
- package/dist/vue-ui-candlestick-Duv6oG79.cjs +2 -0
- package/dist/vue-ui-chestnut-BYHA6MT4.js +1051 -0
- package/dist/vue-ui-chestnut-mIZ4-ZEM.cjs +6 -0
- package/dist/vue-ui-cursor-C96IChA3.js +229 -0
- package/dist/vue-ui-cursor-De7dy4Mo.cjs +1 -0
- package/dist/vue-ui-dashboard-B2Yz41yO.js +232 -0
- package/dist/vue-ui-dashboard-BMGwKr0K.cjs +1 -0
- package/dist/vue-ui-digits-BnxLp7zQ.js +153 -0
- package/dist/vue-ui-digits-DSWyL-5K.cjs +1 -0
- package/dist/vue-ui-donut-1kei9ws5.cjs +1 -0
- package/dist/vue-ui-donut-B9iXisHK.js +743 -0
- package/dist/vue-ui-donut-evolution-B7Sun8sw.js +799 -0
- package/dist/vue-ui-donut-evolution-yv17DnGy.cjs +1 -0
- package/dist/vue-ui-dumbbell-BJEf_JEq.cjs +9 -0
- package/dist/vue-ui-dumbbell-DIsDnD1d.js +624 -0
- package/dist/vue-ui-flow-BTivYoGd.js +454 -0
- package/dist/vue-ui-flow-DOxJa8di.cjs +1 -0
- package/dist/vue-ui-galaxy-BEmywfFB.js +485 -0
- package/dist/vue-ui-galaxy-CHGOwCwM.cjs +1 -0
- package/dist/vue-ui-gauge-QAfMl-8t.cjs +1 -0
- package/dist/vue-ui-gauge-o4rDOqF3.js +466 -0
- package/dist/vue-ui-heatmap-BS4EzedX.cjs +1 -0
- package/dist/vue-ui-heatmap-DwqQqEsk.js +598 -0
- package/dist/vue-ui-kpi-F4qkJ_U-.cjs +1 -0
- package/dist/vue-ui-kpi-h8elYTcA.js +54 -0
- package/dist/vue-ui-mini-loader-C_8B2Pm6.cjs +1 -0
- package/dist/vue-ui-mini-loader-Cgoi9rhH.js +131 -0
- package/dist/vue-ui-molecule-Bmv76SWz.js +750 -0
- package/dist/vue-ui-molecule-C5CY_YYc.cjs +1 -0
- package/dist/vue-ui-mood-radar-BN0dzlfp.cjs +1 -0
- package/dist/vue-ui-mood-radar-DeMouUIe.js +548 -0
- package/dist/vue-ui-nested-donuts-ZyFoV-Zn.cjs +16 -0
- package/dist/vue-ui-nested-donuts-wOUkSVyZ.js +771 -0
- package/dist/vue-ui-onion-DCOKG2wG.js +554 -0
- package/dist/vue-ui-onion-VmTUo7TR.cjs +1 -0
- package/dist/vue-ui-parallel-coordinate-plot-BGtO2P4a.js +651 -0
- package/dist/vue-ui-parallel-coordinate-plot-BziXRF8E.cjs +8 -0
- package/dist/vue-ui-quadrant--JOTjPZh.js +1178 -0
- package/dist/vue-ui-quadrant-DawUUrur.cjs +1 -0
- package/dist/vue-ui-quick-chart-LXKfaJgS.js +1310 -0
- package/dist/vue-ui-quick-chart-jFlFtiNV.cjs +13 -0
- package/dist/vue-ui-radar-CWNIqvcA.js +614 -0
- package/dist/vue-ui-radar-VGH-lhaT.cjs +1 -0
- package/dist/vue-ui-rating-BNrIoJHN.js +271 -0
- package/dist/vue-ui-rating-Dtu6pwGx.cjs +1 -0
- package/dist/vue-ui-relation-circle-B3NKudOy.js +304 -0
- package/dist/vue-ui-relation-circle-Dwpx9o18.cjs +1 -0
- package/dist/vue-ui-rings-CsUngX_F.js +510 -0
- package/dist/vue-ui-rings-D9_OG--0.cjs +1 -0
- package/dist/vue-ui-scatter-DUsuh7bd.cjs +1 -0
- package/dist/vue-ui-scatter-DgxTz4Jx.js +874 -0
- package/dist/vue-ui-screenshot-51H_VrYY.js +160 -0
- package/dist/vue-ui-screenshot-C2Dz7CAe.cjs +3 -0
- package/dist/vue-ui-skeleton-BM9rwmxY.js +2064 -0
- package/dist/vue-ui-skeleton-sjfOtCZr.cjs +41 -0
- package/dist/vue-ui-smiley-DNnBtHht.cjs +2 -0
- package/dist/vue-ui-smiley-H5rSN-1B.js +763 -0
- package/dist/vue-ui-spark-trend-CLXZDYlk.js +246 -0
- package/dist/vue-ui-spark-trend-R4JJvfry.cjs +1 -0
- package/dist/vue-ui-sparkbar-C0k4ah-7.js +242 -0
- package/dist/vue-ui-sparkbar-CEUDIw0A.cjs +1 -0
- package/dist/vue-ui-sparkgauge-BHj00A07.js +157 -0
- package/dist/vue-ui-sparkgauge-CaEw6nmI.cjs +1 -0
- package/dist/vue-ui-sparkhistogram-B6GuavEu.cjs +1 -0
- package/dist/vue-ui-sparkhistogram-DbMLYKqE.js +244 -0
- package/dist/vue-ui-sparkline-CJydanLS.cjs +1 -0
- package/dist/vue-ui-sparkline-CYova9x3.js +333 -0
- package/dist/vue-ui-sparkstackbar-Df__yM5b.cjs +1 -0
- package/dist/vue-ui-sparkstackbar-N5rVBM2h.js +244 -0
- package/dist/vue-ui-strip-plot-DJJ1vEWz.js +618 -0
- package/dist/vue-ui-strip-plot-b5lhB35d.cjs +1 -0
- package/dist/vue-ui-table-NHhOVDbs.cjs +14 -0
- package/dist/vue-ui-table-heatmap-Cro2etCY.js +237 -0
- package/dist/vue-ui-table-heatmap-DlL2nCqz.cjs +1 -0
- package/dist/vue-ui-table-sparkline-Bw2Gc_ur.cjs +1 -0
- package/dist/vue-ui-table-sparkline-DppMitqF.js +420 -0
- package/dist/vue-ui-table-xSvwJIa7.js +1430 -0
- package/dist/vue-ui-thermometer-M2kdp1x5.js +385 -0
- package/dist/vue-ui-thermometer-Q_3PX2V3.cjs +1 -0
- package/dist/vue-ui-timer-BtSDeIRp.cjs +64 -0
- package/dist/vue-ui-timer-CAaQ-QD6.js +453 -0
- package/dist/vue-ui-tiremarks-CbGOSEvD.cjs +1 -0
- package/dist/vue-ui-tiremarks-JFv4JLP0.js +249 -0
- package/dist/vue-ui-treemap-BqDX-bPf.cjs +1 -0
- package/dist/vue-ui-treemap-DCnv-xYr.js +722 -0
- package/dist/vue-ui-vertical-bar-CEbApJZl.js +737 -0
- package/dist/vue-ui-vertical-bar-CJB_KXyr.cjs +4 -0
- package/dist/vue-ui-waffle-CTS6C7gu.js +638 -0
- package/dist/vue-ui-waffle-IMEbGe-b.cjs +1 -0
- package/dist/vue-ui-wheel-CuOmEWMQ.cjs +1 -0
- package/dist/vue-ui-wheel-_zyCdFiI.js +227 -0
- package/dist/vue-ui-word-cloud-RDlXBEAN.js +346 -0
- package/dist/vue-ui-word-cloud-Y7Yk7uUJ.cjs +1 -0
- package/dist/vue-ui-xy-BZJQBKnU.cjs +3 -0
- package/dist/vue-ui-xy-DsvN9EIQ.js +2064 -0
- package/dist/vue-ui-xy-canvas-D_dnbyFS.cjs +9 -0
- package/dist/vue-ui-xy-canvas-Dbcw8-9Q.js +1006 -0
- package/package.json +1 -1
- package/dist/index-C6KVJkgd.cjs +0 -843
- package/dist/index-bDBuMYfe.js +0 -57303
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import { useCssVars as S, unref as e, computed as V, ref as k, onMounted as A, openBlock as l, createElementBlock as n, normalizeClass as w, createElementVNode as r, normalizeStyle as i, withKeys as E, createVNode as C, toDisplayString as R, Fragment as p, renderList as v, createCommentVNode as N, renderSlot as $ } from "vue";
|
|
2
|
+
import { _ as I } from "./Shape-CjLV0scA.js";
|
|
3
|
+
import K from "./BaseIcon-7_g11dRj.js";
|
|
4
|
+
import { _ as O } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
5
|
+
const T = { class: "vue-ui-data-table" }, j = { style: { display: "flex", "align-items": "center", "justify-content": "flex-end", "padding-right": "3px", gap: "3px" } }, F = {
|
|
6
|
+
key: 0,
|
|
7
|
+
height: "12",
|
|
8
|
+
width: "12",
|
|
9
|
+
viewBox: "0 0 20 20",
|
|
10
|
+
style: { background: "none" }
|
|
11
|
+
}, L = ["fill"], M = ["data-cell"], q = { style: { display: "flex", "align-items": "center", gap: "5px", "justify-content": "flex-end", width: "100%", "padding-right": "3px" } }, G = {
|
|
12
|
+
key: 0,
|
|
13
|
+
height: "12",
|
|
14
|
+
width: "12",
|
|
15
|
+
viewBox: "0 0 20 20",
|
|
16
|
+
style: { background: "none", overflow: "visible" }
|
|
17
|
+
}, H = {
|
|
18
|
+
__name: "DataTable",
|
|
19
|
+
props: {
|
|
20
|
+
colNames: {
|
|
21
|
+
type: Array,
|
|
22
|
+
default() {
|
|
23
|
+
return [];
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
head: Array,
|
|
27
|
+
body: Array,
|
|
28
|
+
title: String,
|
|
29
|
+
config: Object
|
|
30
|
+
},
|
|
31
|
+
emits: ["close"],
|
|
32
|
+
setup(t, { emit: g }) {
|
|
33
|
+
const b = t;
|
|
34
|
+
S((s) => ({
|
|
35
|
+
"32d68130": e(_)
|
|
36
|
+
}));
|
|
37
|
+
const { backgroundColor: y, color: h, outline: m } = b.config.th, { backgroundColor: B, color: z, outline: _ } = b.config.td, D = V(() => b.config.breakpoint), f = k(null), x = k(!1);
|
|
38
|
+
return A(() => {
|
|
39
|
+
const s = new ResizeObserver((a) => {
|
|
40
|
+
a.forEach((o) => {
|
|
41
|
+
x.value = o.contentRect.width < D.value;
|
|
42
|
+
});
|
|
43
|
+
});
|
|
44
|
+
f.value && s.observe(f.value);
|
|
45
|
+
}), (s, a) => (l(), n("div", {
|
|
46
|
+
ref_key: "tableContainer",
|
|
47
|
+
ref: f,
|
|
48
|
+
style: { width: "100%", "container-type": "inline-size", position: "relative", "padding-top": "36px", overflow: "auto" },
|
|
49
|
+
class: w({ "vue-ui-responsive": x.value })
|
|
50
|
+
}, [
|
|
51
|
+
r("div", {
|
|
52
|
+
"data-html2canvas-ignore": "",
|
|
53
|
+
role: "button",
|
|
54
|
+
tabindex: "0",
|
|
55
|
+
style: i(`width:32px; position: absolute; top: 0; right:4px; padding: 0 0px; display: flex; align-items:center;justify-content:center;height: 36px; width: 32px; cursor:pointer; background:${e(y)};`),
|
|
56
|
+
onClick: a[0] || (a[0] = (o) => g("close")),
|
|
57
|
+
onKeypress: a[1] || (a[1] = E((o) => g("close"), ["enter"]))
|
|
58
|
+
}, [
|
|
59
|
+
C(K, {
|
|
60
|
+
name: "close",
|
|
61
|
+
stroke: e(h),
|
|
62
|
+
"stroke-width": 2
|
|
63
|
+
}, null, 8, ["stroke"])
|
|
64
|
+
], 36),
|
|
65
|
+
r("table", T, [
|
|
66
|
+
r("caption", {
|
|
67
|
+
style: i({ backgroundColor: e(y), color: e(h), outline: e(m) }),
|
|
68
|
+
class: "vue-ui-data-table__caption"
|
|
69
|
+
}, R(t.title), 5),
|
|
70
|
+
r("thead", null, [
|
|
71
|
+
r("tr", {
|
|
72
|
+
role: "row",
|
|
73
|
+
style: i([{ "font-variant-numeric": "tabular-nums" }, { backgroundColor: e(y), color: e(h) }]),
|
|
74
|
+
class: "vue-ui-data-table__thead-row"
|
|
75
|
+
}, [
|
|
76
|
+
(l(!0), n(p, null, v(t.head, (o, c) => (l(), n("th", {
|
|
77
|
+
role: "cell",
|
|
78
|
+
style: i({ outline: e(m) }),
|
|
79
|
+
key: `th_${c}`
|
|
80
|
+
}, [
|
|
81
|
+
r("div", j, [
|
|
82
|
+
o.color ? (l(), n("svg", F, [
|
|
83
|
+
r("circle", {
|
|
84
|
+
cx: "10",
|
|
85
|
+
cy: "10",
|
|
86
|
+
r: "10",
|
|
87
|
+
fill: o.color
|
|
88
|
+
}, null, 8, L)
|
|
89
|
+
])) : N("", !0),
|
|
90
|
+
$(s.$slots, "th", { th: o }, void 0, !0)
|
|
91
|
+
])
|
|
92
|
+
], 4))), 128))
|
|
93
|
+
], 4)
|
|
94
|
+
]),
|
|
95
|
+
r("tbody", null, [
|
|
96
|
+
(l(!0), n(p, null, v(t.body, (o, c) => (l(), n("tr", {
|
|
97
|
+
role: "row",
|
|
98
|
+
style: i([{ "font-variant-numeric": "tabular-nums" }, { backgroundColor: e(B), color: e(z) }]),
|
|
99
|
+
class: w({ "vue-ui-data-table__tbody__row": !0, "vue-ui-data-table__tbody__row-even": c % 2 === 0, "vue-ui-data-table__tbody__row-odd": c % 2 !== 0 })
|
|
100
|
+
}, [
|
|
101
|
+
(l(!0), n(p, null, v(o, (d, u) => (l(), n("td", {
|
|
102
|
+
role: "cell",
|
|
103
|
+
"data-cell": (t.colNames[u] && t.colNames[u].name ? t.colNames[u].name : "") || t.colNames[u] || "",
|
|
104
|
+
style: i({ outline: e(_) }),
|
|
105
|
+
class: "vue-ui-data-table__tbody__td"
|
|
106
|
+
}, [
|
|
107
|
+
r("div", q, [
|
|
108
|
+
d.color ? (l(), n("svg", G, [
|
|
109
|
+
C(I, {
|
|
110
|
+
plot: { x: 10, y: 10 },
|
|
111
|
+
color: d.color,
|
|
112
|
+
radius: 9,
|
|
113
|
+
shape: t.config.shape || d.shape || "circle"
|
|
114
|
+
}, null, 8, ["color", "shape"])
|
|
115
|
+
])) : N("", !0),
|
|
116
|
+
$(s.$slots, "td", { td: d }, void 0, !0)
|
|
117
|
+
])
|
|
118
|
+
], 12, M))), 256))
|
|
119
|
+
], 6))), 256))
|
|
120
|
+
])
|
|
121
|
+
])
|
|
122
|
+
], 2));
|
|
123
|
+
}
|
|
124
|
+
}, W = /* @__PURE__ */ O(H, [["__scopeId", "data-v-4f23609e"]]);
|
|
125
|
+
export {
|
|
126
|
+
W as D
|
|
127
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),v=require("./Shape-CVItL3vh.cjs"),k=require("./BaseIcon-JtWoVorZ.cjs"),_=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),x={class:"vue-ui-data-table"},B={style:{display:"flex","align-items":"center","justify-content":"flex-end","padding-right":"3px",gap:"3px"}},w={key:0,height:"12",width:"12",viewBox:"0 0 20 20",style:{background:"none"}},E=["fill"],N=["data-cell"],V={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},C={key:0,height:"12",width:"12",viewBox:"0 0 20 20",style:{background:"none",overflow:"visible"}},S={__name:"DataTable",props:{colNames:{type:Array,default(){return[]}},head:Array,body:Array,title:String,config:Object},emits:["close"],setup(t,{emit:m}){const i=t;e.useCssVars(n=>({"32d68130":e.unref(p)}));const{backgroundColor:s,color:u,outline:f}=i.config.th,{backgroundColor:b,color:g,outline:p}=i.config.td,h=e.computed(()=>i.config.breakpoint),d=e.ref(null),y=e.ref(!1);return e.onMounted(()=>{const n=new ResizeObserver(l=>{l.forEach(o=>{y.value=o.contentRect.width<h.value})});d.value&&n.observe(d.value)}),(n,l)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"tableContainer",ref:d,style:{width:"100%","container-type":"inline-size",position:"relative","padding-top":"36px",overflow:"auto"},class:e.normalizeClass({"vue-ui-responsive":y.value})},[e.createElementVNode("div",{"data-html2canvas-ignore":"",role:"button",tabindex:"0",style:e.normalizeStyle(`width:32px; position: absolute; top: 0; right:4px; padding: 0 0px; display: flex; align-items:center;justify-content:center;height: 36px; width: 32px; cursor:pointer; background:${e.unref(s)};`),onClick:l[0]||(l[0]=o=>m("close")),onKeypress:l[1]||(l[1]=e.withKeys(o=>m("close"),["enter"]))},[e.createVNode(k.default,{name:"close",stroke:e.unref(u),"stroke-width":2},null,8,["stroke"])],36),e.createElementVNode("table",x,[e.createElementVNode("caption",{style:e.normalizeStyle({backgroundColor:e.unref(s),color:e.unref(u),outline:e.unref(f)}),class:"vue-ui-data-table__caption"},e.toDisplayString(t.title),5),e.createElementVNode("thead",null,[e.createElementVNode("tr",{role:"row",style:e.normalizeStyle([{"font-variant-numeric":"tabular-nums"},{backgroundColor:e.unref(s),color:e.unref(u)}]),class:"vue-ui-data-table__thead-row"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.head,(o,r)=>(e.openBlock(),e.createElementBlock("th",{role:"cell",style:e.normalizeStyle({outline:e.unref(f)}),key:`th_${r}`},[e.createElementVNode("div",B,[o.color?(e.openBlock(),e.createElementBlock("svg",w,[e.createElementVNode("circle",{cx:"10",cy:"10",r:"10",fill:o.color},null,8,E)])):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"th",{th:o},void 0,!0)])],4))),128))],4)]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.body,(o,r)=>(e.openBlock(),e.createElementBlock("tr",{role:"row",style:e.normalizeStyle([{"font-variant-numeric":"tabular-nums"},{backgroundColor:e.unref(b),color:e.unref(g)}]),class:e.normalizeClass({"vue-ui-data-table__tbody__row":!0,"vue-ui-data-table__tbody__row-even":r%2===0,"vue-ui-data-table__tbody__row-odd":r%2!==0})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o,(a,c)=>(e.openBlock(),e.createElementBlock("td",{role:"cell","data-cell":(t.colNames[c]&&t.colNames[c].name?t.colNames[c].name:"")||t.colNames[c]||"",style:e.normalizeStyle({outline:e.unref(p)}),class:"vue-ui-data-table__tbody__td"},[e.createElementVNode("div",V,[a.color?(e.openBlock(),e.createElementBlock("svg",C,[e.createVNode(v._sfc_main,{plot:{x:10,y:10},color:a.color,radius:9,shape:t.config.shape||a.shape||"circle"},null,8,["color","shape"])])):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"td",{td:a},void 0,!0)])],12,N))),256))],6))),256))])])],2))}},z=_._export_sfc(S,[["__scopeId","data-v-4f23609e"]]);exports.DataTable=z;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { openBlock as n, createElementBlock as o, normalizeStyle as c, renderSlot as l, Fragment as s, renderList as g, createVNode as u, createCommentVNode as m } from "vue";
|
|
2
|
+
import { _ as h } from "./Shape-CjLV0scA.js";
|
|
3
|
+
import { _ as k } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
|
+
const y = ["id"], $ = { class: "vue-data-ui-legend-item" }, v = ["onClick", "height", "width"], S = {
|
|
5
|
+
__name: "Legend",
|
|
6
|
+
props: {
|
|
7
|
+
legendSet: {
|
|
8
|
+
type: Array,
|
|
9
|
+
default() {
|
|
10
|
+
return [];
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
config: {
|
|
14
|
+
type: Object,
|
|
15
|
+
default() {
|
|
16
|
+
return {};
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
id: {
|
|
20
|
+
type: String,
|
|
21
|
+
default: ""
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
emits: ["clickMarker"],
|
|
25
|
+
setup(e, { emit: r }) {
|
|
26
|
+
function f(i, d) {
|
|
27
|
+
r("clickMarker", { legend: i, i: d });
|
|
28
|
+
}
|
|
29
|
+
return (i, d) => (n(), o("div", {
|
|
30
|
+
id: e.id,
|
|
31
|
+
class: "vue-data-ui-legend",
|
|
32
|
+
style: c(`background:${e.config.backgroundColor};font-size:${e.config.fontSize}px;color:${e.config.color};padding-bottom:${e.config.paddingBottom}px;padding-top:${e.config.paddingTop || 12}px;font-weight:${e.config.fontWeight}`)
|
|
33
|
+
}, [
|
|
34
|
+
l(i.$slots, "legendTitle", { titleSet: e.legendSet }, void 0, !0),
|
|
35
|
+
(n(!0), o(s, null, g(e.legendSet, (t, a) => (n(), o("div", $, [
|
|
36
|
+
t.shape ? (n(), o("svg", {
|
|
37
|
+
key: 0,
|
|
38
|
+
onClick: (p) => f(t, a),
|
|
39
|
+
height: e.config.fontSize,
|
|
40
|
+
width: e.config.fontSize,
|
|
41
|
+
viewBox: "0 0 20 20",
|
|
42
|
+
style: c(`overflow: visible;opacity:${t.opacity}`)
|
|
43
|
+
}, [
|
|
44
|
+
u(h, {
|
|
45
|
+
shape: t.shape,
|
|
46
|
+
radius: 9,
|
|
47
|
+
stroke: "none",
|
|
48
|
+
plot: { x: 10, y: 10 },
|
|
49
|
+
fill: t.color
|
|
50
|
+
}, null, 8, ["shape", "fill"])
|
|
51
|
+
], 12, v)) : m("", !0),
|
|
52
|
+
l(i.$slots, "item", {
|
|
53
|
+
legend: t,
|
|
54
|
+
index: a
|
|
55
|
+
}, void 0, !0)
|
|
56
|
+
]))), 256))
|
|
57
|
+
], 12, y));
|
|
58
|
+
}
|
|
59
|
+
}, z = /* @__PURE__ */ k(S, [["__scopeId", "data-v-a5a45422"]]);
|
|
60
|
+
export {
|
|
61
|
+
z as L
|
|
62
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),d=require("./Shape-CVItL3vh.cjs"),a=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),u=["id"],s={class:"vue-data-ui-legend-item"},g=["onClick","height","width"],f={__name:"Legend",props:{legendSet:{type:Array,default(){return[]}},config:{type:Object,default(){return{}}},id:{type:String,default:""}},emits:["clickMarker"],setup(t,{emit:l}){function r(o,i){l("clickMarker",{legend:o,i})}return(o,i)=>(e.openBlock(),e.createElementBlock("div",{id:t.id,class:"vue-data-ui-legend",style:e.normalizeStyle(`background:${t.config.backgroundColor};font-size:${t.config.fontSize}px;color:${t.config.color};padding-bottom:${t.config.paddingBottom}px;padding-top:${t.config.paddingTop||12}px;font-weight:${t.config.fontWeight}`)},[e.renderSlot(o.$slots,"legendTitle",{titleSet:t.legendSet},void 0,!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.legendSet,(n,c)=>(e.openBlock(),e.createElementBlock("div",s,[n.shape?(e.openBlock(),e.createElementBlock("svg",{key:0,onClick:h=>r(n,c),height:t.config.fontSize,width:t.config.fontSize,viewBox:"0 0 20 20",style:e.normalizeStyle(`overflow: visible;opacity:${n.opacity}`)},[e.createVNode(d._sfc_main,{shape:n.shape,radius:9,stroke:"none",plot:{x:10,y:10},fill:n.color},null,8,["shape","fill"])],12,g)):e.createCommentVNode("",!0),e.renderSlot(o.$slots,"item",{legend:n,index:c},void 0,!0)]))),256))],12,u))}},k=a._export_sfc(f,[["__scopeId","data-v-a5a45422"]]);exports.Legend=k;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),a=require("./index-p5gfZSvB.cjs"),c=["cx","cy","r","fill","stroke","stroke-width"],m=["d","fill","stroke","stroke-width"],v=["points","fill","stroke","stroke-width"],p={__name:"Shape",props:{color:String,isSelected:{type:Boolean,default:!1},limit:{type:Number,default:3},plot:Object,radius:Number,shape:String,stroke:String,strokeWidth:Number,zoom:{type:Number,default:1.3}},emits:["mouseover","mouseout","click"],setup(n,{emit:r}){const t=n;function d(u){return{circle:{points:1,rotation:0},line:{points:2,rotation:0},triangle:{points:3,rotation:.52},square:{points:4,rotation:.783},diamond:{points:4,rotation:0},pentagon:{points:5,rotation:.95},hexagon:{points:6,rotation:0}}[u]}const s=e.computed(()=>d(t.shape)),i=e.computed(()=>t.shape!=="star"?null:a.createStar({plot:{x:t.plot.x,y:t.plot.y},radius:t.radius*(t.isSelected?t.zoom:1)})),k=e.computed(()=>a.createPolygonPath({plot:{x:t.plot.x,y:t.plot.y},radius:t.radius*(t.isSelected?t.zoom:1),sides:s.value.points,rotation:s.value.rotation}).path);return(u,o)=>(e.openBlock(),e.createElementBlock("g",null,[s.value&&s.value.points===1?(e.openBlock(),e.createElementBlock("circle",{key:0,cx:n.plot.x,cy:n.plot.y,r:t.radius*(t.isSelected?t.zoom:1),fill:n.color,stroke:n.stroke,"stroke-width":n.strokeWidth,onMouseover:o[0]||(o[0]=l=>r("mouseover")),onMouseout:o[1]||(o[1]=l=>r("mouseout")),onClick:o[2]||(o[2]=l=>r("click"))},null,40,c)):e.createCommentVNode("",!0),s.value&&s.value.points>=n.limit?(e.openBlock(),e.createElementBlock("path",{key:1,d:k.value,fill:n.color,stroke:n.stroke,"stroke-width":n.strokeWidth,onMouseover:o[3]||(o[3]=l=>r("mouseover")),onMouseout:o[4]||(o[4]=l=>r("mouseout")),onClick:o[5]||(o[5]=l=>r("click"))},null,40,m)):e.createCommentVNode("",!0),i.value?(e.openBlock(),e.createElementBlock("polygon",{key:2,points:i.value,fill:n.color,stroke:n.stroke,"stroke-width":n.strokeWidth,onMouseover:o[6]||(o[6]=l=>r("mouseover")),onMouseout:o[7]||(o[7]=l=>r("mouseout")),onClick:o[8]||(o[8]=l=>r("click"))},null,40,v)):e.createCommentVNode("",!0)]))}};exports._sfc_main=p;
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import { computed as u, openBlock as l, createElementBlock as i, createCommentVNode as a } from "vue";
|
|
2
|
+
import { O as p, I as f } from "./index-uOtklCCx.js";
|
|
3
|
+
const y = ["cx", "cy", "r", "fill", "stroke", "stroke-width"], c = ["d", "fill", "stroke", "stroke-width"], g = ["points", "fill", "stroke", "stroke-width"], $ = {
|
|
4
|
+
__name: "Shape",
|
|
5
|
+
props: {
|
|
6
|
+
color: String,
|
|
7
|
+
isSelected: {
|
|
8
|
+
type: Boolean,
|
|
9
|
+
default: !1
|
|
10
|
+
},
|
|
11
|
+
limit: {
|
|
12
|
+
type: Number,
|
|
13
|
+
default: 3
|
|
14
|
+
},
|
|
15
|
+
plot: Object,
|
|
16
|
+
radius: Number,
|
|
17
|
+
shape: String,
|
|
18
|
+
stroke: String,
|
|
19
|
+
strokeWidth: Number,
|
|
20
|
+
zoom: {
|
|
21
|
+
type: Number,
|
|
22
|
+
default: 1.3
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
emits: ["mouseover", "mouseout", "click"],
|
|
26
|
+
setup(e, { emit: n }) {
|
|
27
|
+
const t = e;
|
|
28
|
+
function v(k) {
|
|
29
|
+
return {
|
|
30
|
+
circle: {
|
|
31
|
+
points: 1,
|
|
32
|
+
rotation: 0
|
|
33
|
+
},
|
|
34
|
+
line: {
|
|
35
|
+
points: 2,
|
|
36
|
+
rotation: 0
|
|
37
|
+
},
|
|
38
|
+
triangle: {
|
|
39
|
+
points: 3,
|
|
40
|
+
rotation: 0.52
|
|
41
|
+
},
|
|
42
|
+
square: {
|
|
43
|
+
points: 4,
|
|
44
|
+
rotation: 0.783
|
|
45
|
+
},
|
|
46
|
+
diamond: {
|
|
47
|
+
points: 4,
|
|
48
|
+
rotation: 0
|
|
49
|
+
},
|
|
50
|
+
pentagon: {
|
|
51
|
+
points: 5,
|
|
52
|
+
rotation: 0.95
|
|
53
|
+
},
|
|
54
|
+
hexagon: {
|
|
55
|
+
points: 6,
|
|
56
|
+
rotation: 0
|
|
57
|
+
}
|
|
58
|
+
}[k];
|
|
59
|
+
}
|
|
60
|
+
const s = u(() => v(t.shape)), d = u(() => t.shape !== "star" ? null : p({
|
|
61
|
+
plot: { x: t.plot.x, y: t.plot.y },
|
|
62
|
+
radius: t.radius * (t.isSelected ? t.zoom : 1)
|
|
63
|
+
})), m = u(() => f({
|
|
64
|
+
plot: { x: t.plot.x, y: t.plot.y },
|
|
65
|
+
radius: t.radius * (t.isSelected ? t.zoom : 1),
|
|
66
|
+
sides: s.value.points,
|
|
67
|
+
rotation: s.value.rotation
|
|
68
|
+
}).path);
|
|
69
|
+
return (k, o) => (l(), i("g", null, [
|
|
70
|
+
s.value && s.value.points === 1 ? (l(), i("circle", {
|
|
71
|
+
key: 0,
|
|
72
|
+
cx: e.plot.x,
|
|
73
|
+
cy: e.plot.y,
|
|
74
|
+
r: t.radius * (t.isSelected ? t.zoom : 1),
|
|
75
|
+
fill: e.color,
|
|
76
|
+
stroke: e.stroke,
|
|
77
|
+
"stroke-width": e.strokeWidth,
|
|
78
|
+
onMouseover: o[0] || (o[0] = (r) => n("mouseover")),
|
|
79
|
+
onMouseout: o[1] || (o[1] = (r) => n("mouseout")),
|
|
80
|
+
onClick: o[2] || (o[2] = (r) => n("click"))
|
|
81
|
+
}, null, 40, y)) : a("", !0),
|
|
82
|
+
s.value && s.value.points >= e.limit ? (l(), i("path", {
|
|
83
|
+
key: 1,
|
|
84
|
+
d: m.value,
|
|
85
|
+
fill: e.color,
|
|
86
|
+
stroke: e.stroke,
|
|
87
|
+
"stroke-width": e.strokeWidth,
|
|
88
|
+
onMouseover: o[3] || (o[3] = (r) => n("mouseover")),
|
|
89
|
+
onMouseout: o[4] || (o[4] = (r) => n("mouseout")),
|
|
90
|
+
onClick: o[5] || (o[5] = (r) => n("click"))
|
|
91
|
+
}, null, 40, c)) : a("", !0),
|
|
92
|
+
d.value ? (l(), i("polygon", {
|
|
93
|
+
key: 2,
|
|
94
|
+
points: d.value,
|
|
95
|
+
fill: e.color,
|
|
96
|
+
stroke: e.stroke,
|
|
97
|
+
"stroke-width": e.strokeWidth,
|
|
98
|
+
onMouseover: o[6] || (o[6] = (r) => n("mouseover")),
|
|
99
|
+
onMouseout: o[7] || (o[7] = (r) => n("mouseout")),
|
|
100
|
+
onClick: o[8] || (o[8] = (r) => n("click"))
|
|
101
|
+
}, null, 40, g)) : a("", !0)
|
|
102
|
+
]));
|
|
103
|
+
}
|
|
104
|
+
};
|
|
105
|
+
export {
|
|
106
|
+
$ as _
|
|
107
|
+
};
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
import { useCssVars as A, ref as b, computed as i, watch as f, openBlock as d, createElementBlock as c, createElementVNode as o, normalizeStyle as m, toDisplayString as S, createVNode as I, renderSlot as V, createCommentVNode as z, withDirectives as p, vModelText as N, pushScopeId as $, popScopeId as E } from "vue";
|
|
2
|
+
import B from "./BaseIcon-7_g11dRj.js";
|
|
3
|
+
import { _ as R } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
4
|
+
const D = (e) => ($("data-v-d07947ad"), e = e(), E(), e), L = { "data-html2canvas-ignore": "" }, P = { class: "vue-data-ui-slicer-labels" }, U = { key: 0 }, q = { class: "double-range-slider" }, O = /* @__PURE__ */ D(() => /* @__PURE__ */ o("div", { class: "slider-track" }, null, -1)), T = ["min", "max"], j = ["min", "max"], G = {
|
|
5
|
+
__name: "Slicer",
|
|
6
|
+
props: {
|
|
7
|
+
background: {
|
|
8
|
+
type: String,
|
|
9
|
+
default: "#FFFFFF"
|
|
10
|
+
},
|
|
11
|
+
borderColor: {
|
|
12
|
+
type: String,
|
|
13
|
+
default: "#FFFFFF"
|
|
14
|
+
},
|
|
15
|
+
fontSize: {
|
|
16
|
+
type: Number,
|
|
17
|
+
default: 14
|
|
18
|
+
},
|
|
19
|
+
labelLeft: {
|
|
20
|
+
type: String,
|
|
21
|
+
default: ""
|
|
22
|
+
},
|
|
23
|
+
labelRight: {
|
|
24
|
+
type: String,
|
|
25
|
+
default: ""
|
|
26
|
+
},
|
|
27
|
+
textColor: {
|
|
28
|
+
type: String,
|
|
29
|
+
default: "#1A1A1A"
|
|
30
|
+
},
|
|
31
|
+
inputColor: {
|
|
32
|
+
type: String,
|
|
33
|
+
default: "#1A1A1A"
|
|
34
|
+
},
|
|
35
|
+
max: {
|
|
36
|
+
type: Number,
|
|
37
|
+
default: 0
|
|
38
|
+
},
|
|
39
|
+
min: {
|
|
40
|
+
type: Number,
|
|
41
|
+
default: 0
|
|
42
|
+
},
|
|
43
|
+
selectColor: {
|
|
44
|
+
type: String,
|
|
45
|
+
default: "#4A4A4A"
|
|
46
|
+
},
|
|
47
|
+
useResetSlot: {
|
|
48
|
+
type: Boolean,
|
|
49
|
+
default: !1
|
|
50
|
+
},
|
|
51
|
+
valueStart: {
|
|
52
|
+
type: [Number, String],
|
|
53
|
+
default: 0
|
|
54
|
+
},
|
|
55
|
+
valueEnd: {
|
|
56
|
+
type: [Number, String],
|
|
57
|
+
default: 0
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
emits: ["update:start", "update:end", "reset"],
|
|
61
|
+
setup(e, { emit: s }) {
|
|
62
|
+
const t = e;
|
|
63
|
+
A((l) => ({
|
|
64
|
+
"56c736d9": y.value,
|
|
65
|
+
22868166: C.value,
|
|
66
|
+
"99f84204": x.value,
|
|
67
|
+
"621bff06": e.selectColor,
|
|
68
|
+
"0407e48b": h.value
|
|
69
|
+
}));
|
|
70
|
+
const a = b(t.min), u = b(t.max), g = i(() => {
|
|
71
|
+
const l = t.max - t.min, r = (a.value - t.min) / l * 100, n = (u.value - t.min) / l * 100;
|
|
72
|
+
return {
|
|
73
|
+
left: `${r}%`,
|
|
74
|
+
width: `${n - r}%`,
|
|
75
|
+
background: t.selectColor
|
|
76
|
+
};
|
|
77
|
+
}), y = i(() => t.inputColor), h = i(() => t.background), x = i(() => `${t.selectColor}33`), C = i(() => t.borderColor);
|
|
78
|
+
function v() {
|
|
79
|
+
s("reset");
|
|
80
|
+
}
|
|
81
|
+
function k() {
|
|
82
|
+
Number(a.value) > Number(u.value) - 1 && (a.value = Number(u.value) - 1), s("update:start", Number(a.value));
|
|
83
|
+
}
|
|
84
|
+
function F() {
|
|
85
|
+
Number(u.value) < Number(a.value) + 1 && (u.value = Number(a.value) + 1), s("update:end", Number(u.value));
|
|
86
|
+
}
|
|
87
|
+
return f(
|
|
88
|
+
() => t.min,
|
|
89
|
+
(l) => {
|
|
90
|
+
Number(a.value) < Number(l) && (a.value = Number(l)), Number(u.value) < Number(l) && (u.value = Number(l));
|
|
91
|
+
}
|
|
92
|
+
), f(
|
|
93
|
+
() => t.max,
|
|
94
|
+
(l) => {
|
|
95
|
+
Number(a.value) > Number(l) && (a.value = Number(l)), Number(u.value) > Number(l) && (u.value = Number(l));
|
|
96
|
+
}
|
|
97
|
+
), (l, r) => (d(), c("div", L, [
|
|
98
|
+
o("div", P, [
|
|
99
|
+
o("div", {
|
|
100
|
+
class: "vue-data-ui-slicer-label-left",
|
|
101
|
+
style: m({ fontSize: `${t.fontSize}px`, color: t.textColor })
|
|
102
|
+
}, S(e.labelLeft), 5),
|
|
103
|
+
e.valueStart > 0 || e.valueEnd < e.max ? (d(), c("div", U, [
|
|
104
|
+
e.useResetSlot ? V(l.$slots, "reset-action", {
|
|
105
|
+
key: 1,
|
|
106
|
+
reset: v
|
|
107
|
+
}, void 0, !0) : (d(), c("button", {
|
|
108
|
+
key: 0,
|
|
109
|
+
"data-cy-reset": "",
|
|
110
|
+
tabindex: "0",
|
|
111
|
+
role: "button",
|
|
112
|
+
class: "vue-data-ui-refresh-button",
|
|
113
|
+
onClick: v
|
|
114
|
+
}, [
|
|
115
|
+
I(B, {
|
|
116
|
+
name: "refresh",
|
|
117
|
+
stroke: e.textColor
|
|
118
|
+
}, null, 8, ["stroke"])
|
|
119
|
+
]))
|
|
120
|
+
])) : z("", !0),
|
|
121
|
+
o("div", {
|
|
122
|
+
class: "vue-data-ui-slicer-label-right",
|
|
123
|
+
style: m({ fontSize: `${t.fontSize}px`, color: t.textColor })
|
|
124
|
+
}, S(e.labelRight), 5)
|
|
125
|
+
]),
|
|
126
|
+
o("div", q, [
|
|
127
|
+
O,
|
|
128
|
+
o("div", {
|
|
129
|
+
class: "range-highlight",
|
|
130
|
+
style: m(g.value)
|
|
131
|
+
}, null, 4),
|
|
132
|
+
p(o("input", {
|
|
133
|
+
type: "range",
|
|
134
|
+
min: e.min,
|
|
135
|
+
max: e.max,
|
|
136
|
+
"onUpdate:modelValue": r[0] || (r[0] = (n) => a.value = n),
|
|
137
|
+
onInput: k
|
|
138
|
+
}, null, 40, T), [
|
|
139
|
+
[N, a.value]
|
|
140
|
+
]),
|
|
141
|
+
p(o("input", {
|
|
142
|
+
type: "range",
|
|
143
|
+
min: e.min,
|
|
144
|
+
max: e.max,
|
|
145
|
+
"onUpdate:modelValue": r[1] || (r[1] = (n) => u.value = n),
|
|
146
|
+
onInput: F
|
|
147
|
+
}, null, 40, j), [
|
|
148
|
+
[N, u.value]
|
|
149
|
+
])
|
|
150
|
+
])
|
|
151
|
+
]));
|
|
152
|
+
}
|
|
153
|
+
}, Q = /* @__PURE__ */ R(G, [["__scopeId", "data-v-d07947ad"]]);
|
|
154
|
+
export {
|
|
155
|
+
Q as S
|
|
156
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),p=require("./BaseIcon-JtWoVorZ.cjs"),S=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),g=t=>(e.pushScopeId("data-v-d07947ad"),t=t(),e.popScopeId(),t),y={"data-html2canvas-ignore":""},h={class:"vue-data-ui-slicer-labels"},x={key:0},C={class:"double-range-slider"},k=g(()=>e.createElementVNode("div",{class:"slider-track"},null,-1)),V=["min","max"],E=["min","max"],F={__name:"Slicer",props:{background:{type:String,default:"#FFFFFF"},borderColor:{type:String,default:"#FFFFFF"},fontSize:{type:Number,default:14},labelLeft:{type:String,default:""},labelRight:{type:String,default:""},textColor:{type:String,default:"#1A1A1A"},inputColor:{type:String,default:"#1A1A1A"},max:{type:Number,default:0},min:{type:Number,default:0},selectColor:{type:String,default:"#4A4A4A"},useResetSlot:{type:Boolean,default:!1},valueStart:{type:[Number,String],default:0},valueEnd:{type:[Number,String],default:0}},emits:["update:start","update:end","reset"],setup(t,{emit:i}){const l=t;e.useCssVars(a=>({"56c736d9":s.value,22868166:b.value,"99f84204":v.value,"621bff06":t.selectColor,"0407e48b":m.value}));const o=e.ref(l.min),u=e.ref(l.max),c=e.computed(()=>{const a=l.max-l.min,r=(o.value-l.min)/a*100,n=(u.value-l.min)/a*100;return{left:`${r}%`,width:`${n-r}%`,background:l.selectColor}}),s=e.computed(()=>l.inputColor),m=e.computed(()=>l.background),v=e.computed(()=>`${l.selectColor}33`),b=e.computed(()=>l.borderColor);function d(){i("reset")}function f(){Number(o.value)>Number(u.value)-1&&(o.value=Number(u.value)-1),i("update:start",Number(o.value))}function N(){Number(u.value)<Number(o.value)+1&&(u.value=Number(o.value)+1),i("update:end",Number(u.value))}return e.watch(()=>l.min,a=>{Number(o.value)<Number(a)&&(o.value=Number(a)),Number(u.value)<Number(a)&&(u.value=Number(a))}),e.watch(()=>l.max,a=>{Number(o.value)>Number(a)&&(o.value=Number(a)),Number(u.value)>Number(a)&&(u.value=Number(a))}),(a,r)=>(e.openBlock(),e.createElementBlock("div",y,[e.createElementVNode("div",h,[e.createElementVNode("div",{class:"vue-data-ui-slicer-label-left",style:e.normalizeStyle({fontSize:`${l.fontSize}px`,color:l.textColor})},e.toDisplayString(t.labelLeft),5),t.valueStart>0||t.valueEnd<t.max?(e.openBlock(),e.createElementBlock("div",x,[t.useResetSlot?e.renderSlot(a.$slots,"reset-action",{key:1,reset:d},void 0,!0):(e.openBlock(),e.createElementBlock("button",{key:0,"data-cy-reset":"",tabindex:"0",role:"button",class:"vue-data-ui-refresh-button",onClick:d},[e.createVNode(p.default,{name:"refresh",stroke:t.textColor},null,8,["stroke"])]))])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"vue-data-ui-slicer-label-right",style:e.normalizeStyle({fontSize:`${l.fontSize}px`,color:l.textColor})},e.toDisplayString(t.labelRight),5)]),e.createElementVNode("div",C,[k,e.createElementVNode("div",{class:"range-highlight",style:e.normalizeStyle(c.value)},null,4),e.withDirectives(e.createElementVNode("input",{type:"range",min:t.min,max:t.max,"onUpdate:modelValue":r[0]||(r[0]=n=>o.value=n),onInput:f},null,40,V),[[e.vModelText,o.value]]),e.withDirectives(e.createElementVNode("input",{type:"range",min:t.min,max:t.max,"onUpdate:modelValue":r[1]||(r[1]=n=>u.value=n),onInput:N},null,40,E),[[e.vModelText,u.value]])])]))}},A=S._export_sfc(F,[["__scopeId","data-v-d07947ad"]]);exports.Slicer=A;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { openBlock as o, createElementBlock as l, Fragment as c, createElementVNode as s, normalizeStyle as i, unref as e, toDisplayString as n, createCommentVNode as f } from "vue";
|
|
2
|
+
import { u } from "./useNestedProp-BgWkUab_.js";
|
|
3
|
+
const x = {
|
|
4
|
+
__name: "Title",
|
|
5
|
+
props: {
|
|
6
|
+
config: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default() {
|
|
9
|
+
return {};
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
setup(r) {
|
|
14
|
+
const t = u({
|
|
15
|
+
userConfig: r.config,
|
|
16
|
+
defaultConfig: {
|
|
17
|
+
title: {
|
|
18
|
+
cy: "",
|
|
19
|
+
text: "",
|
|
20
|
+
color: "",
|
|
21
|
+
fontSize: 20,
|
|
22
|
+
bold: !0
|
|
23
|
+
},
|
|
24
|
+
subtitle: {
|
|
25
|
+
cy: "",
|
|
26
|
+
text: "",
|
|
27
|
+
color: "",
|
|
28
|
+
fontSize: 14,
|
|
29
|
+
bold: !1
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
return (p, d) => (o(), l(c, null, [
|
|
34
|
+
s("div", {
|
|
35
|
+
style: i(`width: 100%; text-align:center;color:${e(t).title.color};font-size:${e(t).title.fontSize}px;font-weight:${e(t).title.bold ? "bold" : ""}`)
|
|
36
|
+
}, n(e(t).title.text), 5),
|
|
37
|
+
e(t).subtitle.text ? (o(), l("div", {
|
|
38
|
+
key: 0,
|
|
39
|
+
style: i(`width: 100%; text-align:center;color:${e(t).subtitle.color};font-size:${e(t).subtitle.fontSize}px;font-weight:${e(t).subtitle.bold ? "bold" : ""}`)
|
|
40
|
+
}, n(e(t).subtitle.text), 5)) : f("", !0)
|
|
41
|
+
], 64));
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
export {
|
|
45
|
+
x as _
|
|
46
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),l=require("./useNestedProp-2kIU-7On.cjs"),r={__name:"Title",props:{config:{type:Object,default(){return{}}}},setup(o){const n=o,t=l.useNestedProp({userConfig:n.config,defaultConfig:{title:{cy:"",text:"",color:"",fontSize:20,bold:!0},subtitle:{cy:"",text:"",color:"",fontSize:14,bold:!1}}});return(i,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",{style:e.normalizeStyle(`width: 100%; text-align:center;color:${e.unref(t).title.color};font-size:${e.unref(t).title.fontSize}px;font-weight:${e.unref(t).title.bold?"bold":""}`)},e.toDisplayString(e.unref(t).title.text),5),e.unref(t).subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width: 100%; text-align:center;color:${e.unref(t).subtitle.color};font-size:${e.unref(t).subtitle.fontSize}px;font-weight:${e.unref(t).subtitle.bold?"bold":""}`)},e.toDisplayString(e.unref(t).subtitle.text),5)):e.createCommentVNode("",!0)],64))}};exports._sfc_main=r;
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { ref as u, onMounted as f, onUnmounted as m, computed as y, openBlock as b, createElementBlock as v, normalizeClass as p, normalizeStyle as g, unref as $, renderSlot as a, createElementVNode as h, createCommentVNode as x } from "vue";
|
|
2
|
+
import { r as C } from "./index-uOtklCCx.js";
|
|
3
|
+
function S({ tooltip: e, chart: o, clientPosition: t }) {
|
|
4
|
+
const l = u(0), r = u(48);
|
|
5
|
+
if (e && o) {
|
|
6
|
+
const { width: n, height: i } = e.getBoundingClientRect(), { right: d, left: s, bottom: c } = o.getBoundingClientRect();
|
|
7
|
+
t.x + n / 2 > d ? l.value = -n : t.x - n / 2 < s ? l.value = 0 : l.value = -n / 2, t.y + i > c && (r.value = -i - 48);
|
|
8
|
+
}
|
|
9
|
+
return {
|
|
10
|
+
top: t.y + r.value,
|
|
11
|
+
left: t.x + l.value
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
function k(e, o, t) {
|
|
15
|
+
f(() => e.addEventListener(o, t)), m(() => e.removeEventListener(o, t));
|
|
16
|
+
}
|
|
17
|
+
function w() {
|
|
18
|
+
const e = u(0), o = u(0);
|
|
19
|
+
return k(window, "mousemove", (t) => {
|
|
20
|
+
e.value = t.clientX, o.value = t.clientY;
|
|
21
|
+
}), { x: e, y: o };
|
|
22
|
+
}
|
|
23
|
+
const B = ["innerHTML"], z = {
|
|
24
|
+
__name: "Tooltip",
|
|
25
|
+
props: {
|
|
26
|
+
backgroundColor: {
|
|
27
|
+
type: String,
|
|
28
|
+
default: "#FFFFFF"
|
|
29
|
+
},
|
|
30
|
+
color: {
|
|
31
|
+
type: String,
|
|
32
|
+
default: "#000000"
|
|
33
|
+
},
|
|
34
|
+
content: String,
|
|
35
|
+
maxWidth: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: "300px"
|
|
38
|
+
},
|
|
39
|
+
parent: {
|
|
40
|
+
type: Object
|
|
41
|
+
},
|
|
42
|
+
show: {
|
|
43
|
+
type: Boolean,
|
|
44
|
+
default: !1
|
|
45
|
+
},
|
|
46
|
+
isCustom: {
|
|
47
|
+
type: Boolean,
|
|
48
|
+
default: !1
|
|
49
|
+
},
|
|
50
|
+
fontSize: {
|
|
51
|
+
type: [Number, String],
|
|
52
|
+
default: 14
|
|
53
|
+
},
|
|
54
|
+
borderRadius: {
|
|
55
|
+
type: Number,
|
|
56
|
+
default: 4
|
|
57
|
+
},
|
|
58
|
+
borderColor: {
|
|
59
|
+
type: String,
|
|
60
|
+
default: "#e1e5e8"
|
|
61
|
+
},
|
|
62
|
+
borderWidth: {
|
|
63
|
+
type: Number,
|
|
64
|
+
default: 1
|
|
65
|
+
},
|
|
66
|
+
backgroundOpacity: {
|
|
67
|
+
type: Number,
|
|
68
|
+
default: 100
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
setup(e) {
|
|
72
|
+
const o = e, t = u(null), l = u(w()), r = y(() => S({
|
|
73
|
+
tooltip: t.value,
|
|
74
|
+
chart: o.parent,
|
|
75
|
+
clientPosition: l.value
|
|
76
|
+
}));
|
|
77
|
+
return (n, i) => e.show ? (b(), v("div", {
|
|
78
|
+
key: 0,
|
|
79
|
+
ref_key: "tooltip",
|
|
80
|
+
ref: t,
|
|
81
|
+
class: p({ "vue-data-ui-custom-tooltip": e.isCustom, "vue-data-ui-tooltip": !e.isCustom }),
|
|
82
|
+
style: g(`top:${r.value.top}px;left:${r.value.left}px;${e.isCustom ? "" : `background:${e.backgroundColor}${$(C)[e.backgroundOpacity]};color:${e.color};max-width:${e.maxWidth};font-size:${e.fontSize}px`};border-radius:${e.borderRadius}px;border:${e.borderWidth}px solid ${e.borderColor};`)
|
|
83
|
+
}, [
|
|
84
|
+
a(n.$slots, "tooltip-before"),
|
|
85
|
+
a(n.$slots, "default"),
|
|
86
|
+
h("div", { innerHTML: e.content }, null, 8, B),
|
|
87
|
+
a(n.$slots, "tooltip-after")
|
|
88
|
+
], 6)) : x("", !0);
|
|
89
|
+
}
|
|
90
|
+
};
|
|
91
|
+
export {
|
|
92
|
+
z as _,
|
|
93
|
+
w as u
|
|
94
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const t=require("vue"),f=require("./index-p5gfZSvB.cjs");function m({tooltip:e,chart:n,clientPosition:o}){const u=t.ref(0),l=t.ref(48);if(e&&n){const{width:r,height:i}=e.getBoundingClientRect(),{right:d,left:s,bottom:c}=n.getBoundingClientRect();o.x+r/2>d?u.value=-r:o.x-r/2<s?u.value=0:u.value=-r/2,o.y+i>c&&(l.value=-i-48)}return{top:o.y+l.value,left:o.x+u.value}}function y(e,n,o){t.onMounted(()=>e.addEventListener(n,o)),t.onUnmounted(()=>e.removeEventListener(n,o))}function a(){const e=t.ref(0),n=t.ref(0);return y(window,"mousemove",o=>{e.value=o.clientX,n.value=o.clientY}),{x:e,y:n}}const v=["innerHTML"],b={__name:"Tooltip",props:{backgroundColor:{type:String,default:"#FFFFFF"},color:{type:String,default:"#000000"},content:String,maxWidth:{type:String,default:"300px"},parent:{type:Object},show:{type:Boolean,default:!1},isCustom:{type:Boolean,default:!1},fontSize:{type:[Number,String],default:14},borderRadius:{type:Number,default:4},borderColor:{type:String,default:"#e1e5e8"},borderWidth:{type:Number,default:1},backgroundOpacity:{type:Number,default:100}},setup(e){const n=e,o=t.ref(null),u=t.ref(a()),l=t.computed(()=>m({tooltip:o.value,chart:n.parent,clientPosition:u.value}));return(r,i)=>e.show?(t.openBlock(),t.createElementBlock("div",{key:0,ref_key:"tooltip",ref:o,class:t.normalizeClass({"vue-data-ui-custom-tooltip":e.isCustom,"vue-data-ui-tooltip":!e.isCustom}),style:t.normalizeStyle(`top:${l.value.top}px;left:${l.value.left}px;${e.isCustom?"":`background:${e.backgroundColor}${t.unref(f.opacity)[e.backgroundOpacity]};color:${e.color};max-width:${e.maxWidth};font-size:${e.fontSize}px`};border-radius:${e.borderRadius}px;border:${e.borderWidth}px solid ${e.borderColor};`)},[t.renderSlot(r.$slots,"tooltip-before"),t.renderSlot(r.$slots,"default"),t.createElementVNode("div",{innerHTML:e.content},null,8,v),t.renderSlot(r.$slots,"tooltip-after")],6)):t.createCommentVNode("",!0)}};exports._sfc_main=b;exports.useMouse=a;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=(t,o)=>{const c=t.__vccOpts||t;for(const[r,s]of o)c[r]=s;return c};exports._export_sfc=e;
|