@progress/kendo-vue-charts 6.1.0-develop.6 → 6.1.0-develop.8
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/BaseChart.js +1 -1
- package/BaseChart.mjs +1 -1
- package/components/Legend.js +1 -1
- package/components/Legend.mjs +5 -0
- package/components/SeriesDefaults.js +1 -1
- package/components/SeriesDefaults.mjs +8 -3
- package/dist/cdn/js/kendo-vue-charts.js +1 -1
- package/index.d.mts +1237 -1019
- package/index.d.ts +1237 -1019
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +6 -6
- package/sankey/Sankey.js +1 -1
- package/sankey/Sankey.mjs +10 -13
- package/theming/theme-service.js +1 -44
- package/theming/theme-service.mjs +8 -105
- package/sankey/theme-service.js +0 -29
- package/sankey/theme-service.mjs +0 -99
package/package-metadata.js
CHANGED
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={name:"@progress/kendo-vue-charts",productName:"Kendo UI for Vue",productCode:"KENDOUIVUE",productCodes:["KENDOUIVUE"],publishDate:
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={name:"@progress/kendo-vue-charts",productName:"Kendo UI for Vue",productCode:"KENDOUIVUE",productCodes:["KENDOUIVUE"],publishDate: 1738925012,version:"6.1.0-develop.8",licensingDocsUrl:"https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning"};exports.packageMetadata=e;
|
package/package-metadata.mjs
CHANGED
|
@@ -10,8 +10,8 @@ const e = {
|
|
|
10
10
|
productName: "Kendo UI for Vue",
|
|
11
11
|
productCode: "KENDOUIVUE",
|
|
12
12
|
productCodes: ["KENDOUIVUE"],
|
|
13
|
-
publishDate:
|
|
14
|
-
version: "6.1.0-develop.
|
|
13
|
+
publishDate: 1738925012,
|
|
14
|
+
version: "6.1.0-develop.8",
|
|
15
15
|
licensingDocsUrl: "https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning"
|
|
16
16
|
};
|
|
17
17
|
export {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-vue-charts",
|
|
3
|
-
"version": "6.1.0-develop.
|
|
3
|
+
"version": "6.1.0-develop.8",
|
|
4
4
|
"description": "TODO",
|
|
5
5
|
"author": "Progress",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
@@ -19,14 +19,14 @@
|
|
|
19
19
|
"sideEffects": false,
|
|
20
20
|
"peerDependencies": {
|
|
21
21
|
"@progress/kendo-licensing": "^1.3.4",
|
|
22
|
-
"@progress/kendo-vue-common": "6.1.0-develop.
|
|
23
|
-
"@progress/kendo-vue-intl": "6.1.0-develop.
|
|
24
|
-
"@progress/kendo-vue-popup": "6.1.0-develop.
|
|
22
|
+
"@progress/kendo-vue-common": "6.1.0-develop.8",
|
|
23
|
+
"@progress/kendo-vue-intl": "6.1.0-develop.8",
|
|
24
|
+
"@progress/kendo-vue-popup": "6.1.0-develop.8",
|
|
25
25
|
"@progress/kendo-svg-icons": "^4.0.0",
|
|
26
26
|
"vue": "^3.0.2"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@progress/kendo-charts": "2.
|
|
29
|
+
"@progress/kendo-charts": "2.7.1"
|
|
30
30
|
},
|
|
31
31
|
"keywords": [
|
|
32
32
|
"Kendo UI",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"package": {
|
|
45
45
|
"productName": "Kendo UI for Vue",
|
|
46
46
|
"productCode": "KENDOUIVUE",
|
|
47
|
-
"publishDate":
|
|
47
|
+
"publishDate": 1738925012,
|
|
48
48
|
"licensingDocsUrl": "https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning"
|
|
49
49
|
}
|
|
50
50
|
},
|
package/sankey/Sankey.js
CHANGED
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("vue"),i=require("@progress/kendo-vue-common"),
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("vue"),i=require("@progress/kendo-vue-common"),k=require("../package-metadata.js"),d=require("@progress/kendo-charts"),g=require("./tooltip.js"),u={visible:!0,offset:12},y=r.defineComponent({name:"KendoSankey",emits:{linkclick:null,linkenter:null,linkleave:null,nodeclick:null,nodeenter:null,nodeleave:null},inheritAttrs:!1,props:{dataNodes:{type:Array,required:!0},dataLinks:{type:Array,required:!0},disableAutoLayout:Boolean,disableKeyboardNavigation:Boolean,dir:String,labels:Object,legend:Object,links:Object,nodes:Object,title:Object,tooltip:Object},created(){i.validatePackage(k.packageMetadata),this.instance=null},data(){return{currentTooltip:null,currentDir:void 0}},watch:{dataNodes:function(){this.update(this)},dataLinks:function(){this.update(this)},links:function(){this.update(this)},nodes:function(){this.update(this)},labels:function(){this.update(this)},title:function(){this.update(this)},legend:function(){this.update(this)},disableAutoLayout:function(){this.update(this)},disableKeyboardNavigation:function(){this.update(this)},dir:function(){this.update(this)},tooltip:function(){this.update(this)}},computed:{sankeyClasses(){const t=this.$attrs.class;return{"k-chart k-sankey":!0,[t]:!!t}}},mounted(){this.element=i.getRef(this,"element"),this.currentDir=i.getDir(this.element,this.$props.dir),this.createSankey(this)},unmounted(){this.destroySankey()},methods:{exportVisual(t){return this.instance.exportVisual(t)},destroySankey(){this.instance&&(this.instance.destroy(),this.instance=null)},createSankey(){const t=this.element;if(!t)return;const e=this.sankeyOptions(),n=d.sankeyTheme(t);this.instance=new d.Sankey(t,e,n),this.bindEvents(this.instance)},update(){this.instance&&this.instance.setOptions(this.sankeyOptions())},bindEvents(t){t.bind("nodeEnter",this.triggerEvent),t.bind("nodeLeave",this.triggerEvent),t.bind("linkEnter",this.triggerEvent),t.bind("linkLeave",this.triggerEvent),t.bind("nodeClick",this.triggerEvent),t.bind("linkClick",this.triggerEvent),t.bind("tooltipShow",this.onTooltipShow),t.bind("tooltipHide",this.onTooltipHide)},triggerEvent(t){const e={...t,target:this};this.$emit(t.type.toLowerCase(),e)},sankeyOptions(){const{dataNodes:t,dataLinks:e,links:n,nodes:o,labels:a,title:s,legend:l,disableAutoLayout:h,disableKeyboardNavigation:c,tooltip:p}=this.$props;return{data:{nodes:t,links:e},links:n,nodes:o,labels:a,title:s,legend:l,disableAutoLayout:h,disableKeyboardNavigation:c,rtl:this.currentDir==="rtl",tooltip:{...u,...p}}},onTooltipShow(t){const{visible:e}={...u,...this.$props.tooltip};if(e){const n={tooltipData:t.tooltipData,eventData:{dataItem:t.dataItem,nodeValue:t.nodeValue,targetType:t.targetType}};this.currentTooltip=n}},onTooltipHide(){this.currentTooltip=null}},render(){const{nodeContent:t,linkContent:e,offset:n}=this.$props.tooltip||{},o=i.templateRendering.call(this,t,i.getListeners.call(this)),a=i.templateRendering.call(this,e,i.getListeners.call(this)),s=this.$props.dir||this.currentDir;return[r.createVNode("div",{ref:i.setRef(this,"element"),class:this.sankeyClasses,style:this.$attrs.style,dir:s},null),this.currentTooltip&&r.createVNode(g.Tooltip,{tooltipData:this.currentTooltip.tooltipData,eventData:this.currentTooltip.eventData,dir:s,offset:n||12,nodeContent:o,linkContent:a},null)]}});exports.Sankey=y;
|
package/sankey/Sankey.mjs
CHANGED
|
@@ -6,15 +6,14 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
import { defineComponent as k, createVNode as r } from "vue";
|
|
9
|
-
import { validatePackage as f, getRef as
|
|
10
|
-
import { packageMetadata as
|
|
11
|
-
import {
|
|
12
|
-
import { Sankey as T } from "@progress/kendo-charts";
|
|
9
|
+
import { validatePackage as f, getRef as y, getDir as g, templateRendering as l, getListeners as d, setRef as b } from "@progress/kendo-vue-common";
|
|
10
|
+
import { packageMetadata as m } from "../package-metadata.mjs";
|
|
11
|
+
import { sankeyTheme as v, Sankey as T } from "@progress/kendo-charts";
|
|
13
12
|
import { Tooltip as D } from "./tooltip.mjs";
|
|
14
13
|
const h = {
|
|
15
14
|
visible: !0,
|
|
16
15
|
offset: 12
|
|
17
|
-
},
|
|
16
|
+
}, $ = /* @__PURE__ */ k({
|
|
18
17
|
name: "KendoSankey",
|
|
19
18
|
emits: {
|
|
20
19
|
linkclick: null,
|
|
@@ -45,7 +44,7 @@ const h = {
|
|
|
45
44
|
tooltip: Object
|
|
46
45
|
},
|
|
47
46
|
created() {
|
|
48
|
-
f(
|
|
47
|
+
f(m), this.instance = null;
|
|
49
48
|
},
|
|
50
49
|
data() {
|
|
51
50
|
return {
|
|
@@ -98,7 +97,7 @@ const h = {
|
|
|
98
97
|
}
|
|
99
98
|
},
|
|
100
99
|
mounted() {
|
|
101
|
-
this.element =
|
|
100
|
+
this.element = y(this, "element"), this.currentDir = g(this.element, this.$props.dir), this.createSankey(this);
|
|
102
101
|
},
|
|
103
102
|
unmounted() {
|
|
104
103
|
this.destroySankey();
|
|
@@ -114,10 +113,8 @@ const h = {
|
|
|
114
113
|
const t = this.element;
|
|
115
114
|
if (!t)
|
|
116
115
|
return;
|
|
117
|
-
const e = this.sankeyOptions();
|
|
118
|
-
|
|
119
|
-
this.instance = new T(t, e, i), this.bindEvents(this.instance);
|
|
120
|
-
});
|
|
116
|
+
const e = this.sankeyOptions(), i = v(t);
|
|
117
|
+
this.instance = new T(t, e, i), this.bindEvents(this.instance);
|
|
121
118
|
},
|
|
122
119
|
update() {
|
|
123
120
|
this.instance && this.instance.setOptions(this.sankeyOptions());
|
|
@@ -194,7 +191,7 @@ const h = {
|
|
|
194
191
|
offset: i
|
|
195
192
|
} = this.$props.tooltip || {}, o = l.call(this, t, d.call(this)), s = l.call(this, e, d.call(this)), n = this.$props.dir || this.currentDir;
|
|
196
193
|
return [r("div", {
|
|
197
|
-
ref:
|
|
194
|
+
ref: b(this, "element"),
|
|
198
195
|
class: this.sankeyClasses,
|
|
199
196
|
style: this.$attrs.style,
|
|
200
197
|
dir: n
|
|
@@ -209,5 +206,5 @@ const h = {
|
|
|
209
206
|
}
|
|
210
207
|
});
|
|
211
208
|
export {
|
|
212
|
-
|
|
209
|
+
$ as Sankey
|
|
213
210
|
};
|
package/theming/theme-service.js
CHANGED
|
@@ -5,47 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
9
|
-
<div class="k-var--series-a"></div>
|
|
10
|
-
<div class="k-var--series-b"></div>
|
|
11
|
-
<div class="k-var--series-c"></div>
|
|
12
|
-
<div class="k-var--series-d"></div>
|
|
13
|
-
<div class="k-var--series-e"></div>
|
|
14
|
-
<div class="k-var--series-f"></div>
|
|
15
|
-
`;for(let e=0;e<m;e++)s+=`
|
|
16
|
-
<div class="k-var--series-${e+1}"></div>`;return s},f=`
|
|
17
|
-
<div class="k-var--primary"></div>
|
|
18
|
-
<div class="k-var--base"></div>
|
|
19
|
-
<div class="k-var--background"></div>
|
|
20
|
-
|
|
21
|
-
<div class="k-var--normal-background"></div>
|
|
22
|
-
<div class="k-var--normal-text-color"></div>
|
|
23
|
-
<div class="k-var--hover-background"></div>
|
|
24
|
-
<div class="k-var--hover-text-color"></div>
|
|
25
|
-
<div class="k-var--selected-background"></div>
|
|
26
|
-
<div class="k-var--selected-text-color"></div>
|
|
27
|
-
<div class="k-var--chart-error-bars-background"></div>
|
|
28
|
-
<div class="k-var--chart-notes-background"></div>
|
|
29
|
-
<div class="k-var--chart-notes-border"></div>
|
|
30
|
-
<div class="k-var--chart-notes-lines"></div>
|
|
31
|
-
<div class="k-var--chart-crosshair-background"></div>
|
|
32
|
-
|
|
33
|
-
<div class="k-var--chart-inactive"></div>
|
|
34
|
-
<div class="k-var--chart-major-lines"></div>
|
|
35
|
-
<div class="k-var--chart-minor-lines"></div>
|
|
36
|
-
<div class="k-var--chart-area-opacity"></div>
|
|
37
|
-
<div class="k-var--chart-area-inactive-opacity"></div>
|
|
38
|
-
<div class="k-var--chart-line-inactive-opacity"></div>
|
|
39
|
-
|
|
40
|
-
<div class="k-widget k-chart">
|
|
41
|
-
<div class="k-var--chart-font"></div>
|
|
42
|
-
<div class="k-var--chart-title-font"></div>
|
|
43
|
-
<div class="k-var--chart-pane-title-font"></div>
|
|
44
|
-
<div class="k-var--chart-label-font"></div>
|
|
45
|
-
</div>
|
|
46
|
-
|
|
47
|
-
<div class="k-var--series-unset"></div>
|
|
48
|
-
<div class="k-var--series">
|
|
49
|
-
${p()}
|
|
50
|
-
</div>
|
|
51
|
-
`;class y{constructor(e){this.store=e}setStyle(e,t){this.store.dispatch({type:"set",payload:{field:e,value:t}})}setColors(){this.mapColor("axisDefaults.crosshair.color","chart-crosshair-background"),this.mapColor("axisDefaults.labels.color","normal-text-color"),this.mapColor("axisDefaults.line.color","chart-major-lines"),this.mapColor("axisDefaults.majorGridLines.color","chart-major-lines"),this.mapColor("axisDefaults.minorGridLines.color","chart-minor-lines"),this.mapColor("axisDefaults.notes.icon.background","chart-notes-background"),this.mapColor("axisDefaults.notes.icon.border.color","chart-notes-border"),this.mapColor("axisDefaults.notes.line.color","chart-notes-lines"),this.mapColor("axisDefaults.title.color","normal-text-color"),this.mapColor("chartArea.background","background"),this.mapColor("legend.inactiveItems.labels.color","chart-inactive"),this.mapColor("legend.inactiveItems.markers.color","chart-inactive"),this.mapColor("legend.labels.color","normal-text-color"),this.mapColor("seriesDefaults.boxPlot.downColor","chart-major-lines"),this.mapColor("seriesDefaults.boxPlot.mean.color","base"),this.mapColor("seriesDefaults.boxPlot.median.color","base"),this.mapColor("seriesDefaults.boxPlot.whiskers.color","primary"),this.mapColor("seriesDefaults.bullet.target.color","normal-text-color"),this.mapColor("seriesDefaults.candlestick.downColor","normal-text-color"),this.mapColor("seriesDefaults.candlestick.line.color","normal-text-color"),this.mapColor("seriesDefaults.errorBars.color","chart-error-bars-background"),this.mapColor("seriesDefaults.horizontalWaterfall.line.color","chart-major-lines"),this.mapColor("seriesDefaults.icon.border.color","chart-major-lines"),this.mapColor("seriesDefaults.labels.background","background"),this.mapColor("seriesDefaults.labels.color","normal-text-color"),this.mapColor("seriesDefaults.notes.icon.background","chart-notes-background"),this.mapColor("seriesDefaults.notes.icon.border.color","chart-notes-border"),this.mapColor("seriesDefaults.notes.line.color","chart-notes-lines"),this.mapColor("seriesDefaults.verticalBoxPlot.downColor","chart-major-lines"),this.mapColor("seriesDefaults.verticalBoxPlot.mean.color","base"),this.mapColor("seriesDefaults.verticalBoxPlot.median.color","base"),this.mapColor("seriesDefaults.verticalBoxPlot.whiskers.color","primary"),this.mapColor("seriesDefaults.verticalBullet.target.color","normal-text-color"),this.mapColor("seriesDefaults.waterfall.line.color","chart-major-lines"),this.mapColor("title.color","normal-text-color");const e=parseFloat(this.queryStyle("chart-area-opacity").opacity);isNaN(e)||(this.setStyle("seriesDefaults.area.opacity",e),this.setStyle("seriesDefaults.radarArea.opacity",e),this.setStyle("seriesDefaults.verticalArea.opacity",e),this.setStyle("seriesDefaults.labels.opacity",e)),this.setInactiveOpacity(["area","verticalArea"],"chart-area-inactive-opacity"),this.setInactiveOpacity(["line","verticalLine"],"chart-line-inactive-opacity")}setFonts(){const e=r(this.queryStyle("chart-font")),t=r(this.queryStyle("chart-title-font")),a=r(this.queryStyle("chart-pane-title-font")),o=r(this.queryStyle("chart-label-font"));this.setStyle("axisDefaults.labels.font",o),this.setStyle("axisDefaults.notes.label.font",e),this.setStyle("axisDefaults.title.font",e),this.setStyle("legend.labels.font",e),this.setStyle("seriesDefaults.labels.font",o),this.setStyle("seriesDefaults.notes.label.font",e),this.setStyle("title.font",t),this.setStyle("paneDefaults.title.font",a)}setSeriesColors(){const e=this.element,t=[].slice.call(e==null?void 0:e.querySelectorAll(".k-var--series div")),a=d(e==null?void 0:e.querySelector(".k-var--series-unset")),o=t.reduce((i,l)=>{const h=u(l.className),c=d(l);return c!==a&&(i[h]=c),i},[]);this.setStyle("seriesColors",o)}mapColor(e,t){this.setStyle(e,this.queryStyle(t).backgroundColor)}queryStyle(e){const t=this.element;return window.getComputedStyle(t==null?void 0:t.querySelector(`.k-var--${e}`))}setInactiveOpacity(e,t){const a=parseFloat(this.queryStyle(t).opacity);!isNaN(a)&&a<1&&e.forEach(o=>this.setStyle(`seriesDefaults.${o}.highlight.inactiveOpacity`,a))}}const k=(s,e)=>{const t=new y(s);if(typeof document=="undefined"){s.dispatch({type:"push",payload:n.chartBaseTheme()});return}const a=t.element=document.createElement("div");a.style.display="none",a.innerHTML=f,document.body.appendChild(a);try{s.dispatch({type:"push",payload:n.chartBaseTheme()}),t.setColors(),t.setFonts(),t.setSeriesColors()}finally{document.body.removeChild(t.element),delete t.element,e()}};exports.loadTheme=k;
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("@progress/kendo-charts"),n=(t,h,o)=>{const a=e.chartBaseTheme();if(typeof document=="undefined"){t.dispatch({type:"push",payload:a});return}let d={};try{d=e.chartTheme(o)}finally{t.dispatch({type:"push",payload:e.deepExtend(a,d)}),h()}};exports.loadTheme=n;
|
|
@@ -5,117 +5,20 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import { chartBaseTheme as
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
if (e !== null)
|
|
12
|
-
return v(e[1]);
|
|
13
|
-
const t = s.split("--series-")[1];
|
|
14
|
-
return parseInt(t, 10) - 1;
|
|
15
|
-
}, m = 30, p = () => {
|
|
16
|
-
let s = `
|
|
17
|
-
<div class="k-var--series-a"></div>
|
|
18
|
-
<div class="k-var--series-b"></div>
|
|
19
|
-
<div class="k-var--series-c"></div>
|
|
20
|
-
<div class="k-var--series-d"></div>
|
|
21
|
-
<div class="k-var--series-e"></div>
|
|
22
|
-
<div class="k-var--series-f"></div>
|
|
23
|
-
`;
|
|
24
|
-
for (let e = 0; e < m; e++)
|
|
25
|
-
s += `
|
|
26
|
-
<div class="k-var--series-${e + 1}"></div>`;
|
|
27
|
-
return s;
|
|
28
|
-
}, f = `
|
|
29
|
-
<div class="k-var--primary"></div>
|
|
30
|
-
<div class="k-var--base"></div>
|
|
31
|
-
<div class="k-var--background"></div>
|
|
32
|
-
|
|
33
|
-
<div class="k-var--normal-background"></div>
|
|
34
|
-
<div class="k-var--normal-text-color"></div>
|
|
35
|
-
<div class="k-var--hover-background"></div>
|
|
36
|
-
<div class="k-var--hover-text-color"></div>
|
|
37
|
-
<div class="k-var--selected-background"></div>
|
|
38
|
-
<div class="k-var--selected-text-color"></div>
|
|
39
|
-
<div class="k-var--chart-error-bars-background"></div>
|
|
40
|
-
<div class="k-var--chart-notes-background"></div>
|
|
41
|
-
<div class="k-var--chart-notes-border"></div>
|
|
42
|
-
<div class="k-var--chart-notes-lines"></div>
|
|
43
|
-
<div class="k-var--chart-crosshair-background"></div>
|
|
44
|
-
|
|
45
|
-
<div class="k-var--chart-inactive"></div>
|
|
46
|
-
<div class="k-var--chart-major-lines"></div>
|
|
47
|
-
<div class="k-var--chart-minor-lines"></div>
|
|
48
|
-
<div class="k-var--chart-area-opacity"></div>
|
|
49
|
-
<div class="k-var--chart-area-inactive-opacity"></div>
|
|
50
|
-
<div class="k-var--chart-line-inactive-opacity"></div>
|
|
51
|
-
|
|
52
|
-
<div class="k-widget k-chart">
|
|
53
|
-
<div class="k-var--chart-font"></div>
|
|
54
|
-
<div class="k-var--chart-title-font"></div>
|
|
55
|
-
<div class="k-var--chart-pane-title-font"></div>
|
|
56
|
-
<div class="k-var--chart-label-font"></div>
|
|
57
|
-
</div>
|
|
58
|
-
|
|
59
|
-
<div class="k-var--series-unset"></div>
|
|
60
|
-
<div class="k-var--series">
|
|
61
|
-
${p()}
|
|
62
|
-
</div>
|
|
63
|
-
`;
|
|
64
|
-
class y {
|
|
65
|
-
constructor(e) {
|
|
66
|
-
this.store = e;
|
|
67
|
-
}
|
|
68
|
-
setStyle(e, t) {
|
|
69
|
-
this.store.dispatch({ type: "set", payload: { field: e, value: t } });
|
|
70
|
-
}
|
|
71
|
-
setColors() {
|
|
72
|
-
this.mapColor("axisDefaults.crosshair.color", "chart-crosshair-background"), this.mapColor("axisDefaults.labels.color", "normal-text-color"), this.mapColor("axisDefaults.line.color", "chart-major-lines"), this.mapColor("axisDefaults.majorGridLines.color", "chart-major-lines"), this.mapColor("axisDefaults.minorGridLines.color", "chart-minor-lines"), this.mapColor("axisDefaults.notes.icon.background", "chart-notes-background"), this.mapColor("axisDefaults.notes.icon.border.color", "chart-notes-border"), this.mapColor("axisDefaults.notes.line.color", "chart-notes-lines"), this.mapColor("axisDefaults.title.color", "normal-text-color"), this.mapColor("chartArea.background", "background"), this.mapColor("legend.inactiveItems.labels.color", "chart-inactive"), this.mapColor("legend.inactiveItems.markers.color", "chart-inactive"), this.mapColor("legend.labels.color", "normal-text-color"), this.mapColor("seriesDefaults.boxPlot.downColor", "chart-major-lines"), this.mapColor("seriesDefaults.boxPlot.mean.color", "base"), this.mapColor("seriesDefaults.boxPlot.median.color", "base"), this.mapColor("seriesDefaults.boxPlot.whiskers.color", "primary"), this.mapColor("seriesDefaults.bullet.target.color", "normal-text-color"), this.mapColor("seriesDefaults.candlestick.downColor", "normal-text-color"), this.mapColor("seriesDefaults.candlestick.line.color", "normal-text-color"), this.mapColor("seriesDefaults.errorBars.color", "chart-error-bars-background"), this.mapColor("seriesDefaults.horizontalWaterfall.line.color", "chart-major-lines"), this.mapColor("seriesDefaults.icon.border.color", "chart-major-lines"), this.mapColor("seriesDefaults.labels.background", "background"), this.mapColor("seriesDefaults.labels.color", "normal-text-color"), this.mapColor("seriesDefaults.notes.icon.background", "chart-notes-background"), this.mapColor("seriesDefaults.notes.icon.border.color", "chart-notes-border"), this.mapColor("seriesDefaults.notes.line.color", "chart-notes-lines"), this.mapColor("seriesDefaults.verticalBoxPlot.downColor", "chart-major-lines"), this.mapColor("seriesDefaults.verticalBoxPlot.mean.color", "base"), this.mapColor("seriesDefaults.verticalBoxPlot.median.color", "base"), this.mapColor("seriesDefaults.verticalBoxPlot.whiskers.color", "primary"), this.mapColor("seriesDefaults.verticalBullet.target.color", "normal-text-color"), this.mapColor("seriesDefaults.waterfall.line.color", "chart-major-lines"), this.mapColor("title.color", "normal-text-color");
|
|
73
|
-
const e = parseFloat(this.queryStyle("chart-area-opacity").opacity);
|
|
74
|
-
isNaN(e) || (this.setStyle("seriesDefaults.area.opacity", e), this.setStyle("seriesDefaults.radarArea.opacity", e), this.setStyle("seriesDefaults.verticalArea.opacity", e), this.setStyle("seriesDefaults.labels.opacity", e)), this.setInactiveOpacity(["area", "verticalArea"], "chart-area-inactive-opacity"), this.setInactiveOpacity(["line", "verticalLine"], "chart-line-inactive-opacity");
|
|
75
|
-
}
|
|
76
|
-
setFonts() {
|
|
77
|
-
const e = r(this.queryStyle("chart-font")), t = r(this.queryStyle("chart-title-font")), a = r(this.queryStyle("chart-pane-title-font")), o = r(this.queryStyle("chart-label-font"));
|
|
78
|
-
this.setStyle("axisDefaults.labels.font", o), this.setStyle("axisDefaults.notes.label.font", e), this.setStyle("axisDefaults.title.font", e), this.setStyle("legend.labels.font", e), this.setStyle("seriesDefaults.labels.font", o), this.setStyle("seriesDefaults.notes.label.font", e), this.setStyle("title.font", t), this.setStyle("paneDefaults.title.font", a);
|
|
79
|
-
}
|
|
80
|
-
setSeriesColors() {
|
|
81
|
-
const e = this.element, t = [].slice.call(e == null ? void 0 : e.querySelectorAll(".k-var--series div")), a = d(e == null ? void 0 : e.querySelector(".k-var--series-unset")), o = t.reduce(
|
|
82
|
-
(i, l) => {
|
|
83
|
-
const h = u(l.className), c = d(l);
|
|
84
|
-
return c !== a && (i[h] = c), i;
|
|
85
|
-
},
|
|
86
|
-
[]
|
|
87
|
-
// Will populate the series colors in this array
|
|
88
|
-
);
|
|
89
|
-
this.setStyle("seriesColors", o);
|
|
90
|
-
}
|
|
91
|
-
mapColor(e, t) {
|
|
92
|
-
this.setStyle(e, this.queryStyle(t).backgroundColor);
|
|
93
|
-
}
|
|
94
|
-
queryStyle(e) {
|
|
95
|
-
const t = this.element;
|
|
96
|
-
return window.getComputedStyle(t == null ? void 0 : t.querySelector(`.k-var--${e}`));
|
|
97
|
-
}
|
|
98
|
-
setInactiveOpacity(e, t) {
|
|
99
|
-
const a = parseFloat(this.queryStyle(t).opacity);
|
|
100
|
-
!isNaN(a) && a < 1 && e.forEach(
|
|
101
|
-
(o) => this.setStyle(`seriesDefaults.${o}.highlight.inactiveOpacity`, a)
|
|
102
|
-
);
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
const C = (s, e) => {
|
|
106
|
-
const t = new y(s);
|
|
8
|
+
import { chartBaseTheme as d, chartTheme as o, deepExtend as m } from "@progress/kendo-charts";
|
|
9
|
+
const c = (e, p, h) => {
|
|
10
|
+
const t = d();
|
|
107
11
|
if (typeof document == "undefined") {
|
|
108
|
-
|
|
12
|
+
e.dispatch({ type: "push", payload: t });
|
|
109
13
|
return;
|
|
110
14
|
}
|
|
111
|
-
|
|
112
|
-
a.style.display = "none", a.innerHTML = f, document.body.appendChild(a);
|
|
15
|
+
let a = {};
|
|
113
16
|
try {
|
|
114
|
-
|
|
17
|
+
a = o(h);
|
|
115
18
|
} finally {
|
|
116
|
-
|
|
19
|
+
e.dispatch({ type: "push", payload: m(t, a) }), p();
|
|
117
20
|
}
|
|
118
21
|
};
|
|
119
22
|
export {
|
|
120
|
-
|
|
23
|
+
c as loadTheme
|
|
121
24
|
};
|
package/sankey/theme-service.js
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
*-------------------------------------------------------------------------------------------
|
|
4
|
-
* Copyright © 2025 Progress Software Corporation. All rights reserved.
|
|
5
|
-
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
-
*-------------------------------------------------------------------------------------------
|
|
7
|
-
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("@progress/kendo-charts");const c=t=>`${t.fontWeight} ${t.fontSize} ${t.fontFamily}`,d=t=>window.getComputedStyle(t).backgroundColor,v=t=>t.toLowerCase().charCodeAt(0)-97,u=t=>{const e=t.match(/series-([a-z])$/);if(e!==null)return v(e[1]);const s=t.split("--series-")[1];return parseInt(s,10)-1},h=30,m=()=>{let t=`
|
|
9
|
-
<div class="k-var--series-a"></div>
|
|
10
|
-
<div class="k-var--series-b"></div>
|
|
11
|
-
<div class="k-var--series-c"></div>
|
|
12
|
-
<div class="k-var--series-d"></div>
|
|
13
|
-
<div class="k-var--series-e"></div>
|
|
14
|
-
<div class="k-var--series-f"></div>
|
|
15
|
-
`;for(let e=0;e<h;e++)t+=`
|
|
16
|
-
<div class="k-var--series-${e+1}"></div>`;return t},k=`
|
|
17
|
-
<div class="k-var--background"></div>
|
|
18
|
-
<div class="k-var--normal-text-color"></div>
|
|
19
|
-
<div class="k-var--kendo-color-subtle"></div>
|
|
20
|
-
|
|
21
|
-
<div class="k-widget k-chart">
|
|
22
|
-
<div class="k-var--chart-font"></div>
|
|
23
|
-
<div class="k-var--chart-title-font"></div>
|
|
24
|
-
</div>
|
|
25
|
-
<div class="k-var--series-unset"></div>
|
|
26
|
-
<div class="k-var--series">
|
|
27
|
-
${m()}
|
|
28
|
-
</div>
|
|
29
|
-
`;class y{constructor(e){this.store=e}setStyle(e,s){const o=e.split(".");let l=this.store;o.forEach((i,a,n)=>{a<n.length-1&&(l=l[i]=l[i]||{})});const r=o.pop();r&&(l[r]=s)}setColors(){this.mapColor("labels.color","normal-text-color"),this.mapColor("labels.stroke.color","background");const e=this.element.querySelector(".k-var--kendo-color-subtle");e.style.color="var(--kendo-color-subtle)",this.mapColor("links.color","kendo-color-subtle","color"),this.mapColor("legend.labels.color","normal-text-color"),this.mapColor("title.color","normal-text-color")}setFonts(){const e=c(this.queryStyle("chart-title-font")),s=c(this.queryStyle("chart-font"));this.setStyle("title.font",e),this.setStyle("labels.font",s),this.setStyle("legend.labels.font",s)}setNodeColors(){const e=this.element;if(!e)return;const s=[].slice.call(e.querySelectorAll(".k-var--series div")),o=d(e.querySelector(".k-var--series-unset")),l=s.reduce((r,i)=>{const a=u(i.className),n=d(i);return n!==o&&(r[a]=n),r},[]);this.setStyle("nodeColors",l)}mapColor(e,s,o="backgroundColor"){this.setStyle(e,this.queryStyle(s)[o])}queryStyle(e){const s=this.element;return window.getComputedStyle(s.querySelector(`.k-var--${e}`))}}const C=(t,e)=>{const s={nodeColors:[]},o=new y(s),l=o.element=t.createElement("div");l.style.display="none",l.innerHTML=k,t.body.appendChild(l);try{o.setColors(),o.setFonts(),o.setNodeColors()}finally{t.body.removeChild(o.element),o.element=null,e(s)}};exports.loadTheme=C;
|
package/sankey/theme-service.mjs
DELETED
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
*-------------------------------------------------------------------------------------------
|
|
4
|
-
* Copyright © 2025 Progress Software Corporation. All rights reserved.
|
|
5
|
-
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
-
*-------------------------------------------------------------------------------------------
|
|
7
|
-
*/
|
|
8
|
-
import "@progress/kendo-charts";
|
|
9
|
-
const a = (t) => `${t.fontWeight} ${t.fontSize} ${t.fontFamily}`, d = (t) => window.getComputedStyle(t).backgroundColor, v = (t) => t.toLowerCase().charCodeAt(0) - 97, u = (t) => {
|
|
10
|
-
const e = t.match(/series-([a-z])$/);
|
|
11
|
-
if (e !== null)
|
|
12
|
-
return v(e[1]);
|
|
13
|
-
const s = t.split("--series-")[1];
|
|
14
|
-
return parseInt(s, 10) - 1;
|
|
15
|
-
}, h = 30, m = () => {
|
|
16
|
-
let t = `
|
|
17
|
-
<div class="k-var--series-a"></div>
|
|
18
|
-
<div class="k-var--series-b"></div>
|
|
19
|
-
<div class="k-var--series-c"></div>
|
|
20
|
-
<div class="k-var--series-d"></div>
|
|
21
|
-
<div class="k-var--series-e"></div>
|
|
22
|
-
<div class="k-var--series-f"></div>
|
|
23
|
-
`;
|
|
24
|
-
for (let e = 0; e < h; e++)
|
|
25
|
-
t += `
|
|
26
|
-
<div class="k-var--series-${e + 1}"></div>`;
|
|
27
|
-
return t;
|
|
28
|
-
}, k = `
|
|
29
|
-
<div class="k-var--background"></div>
|
|
30
|
-
<div class="k-var--normal-text-color"></div>
|
|
31
|
-
<div class="k-var--kendo-color-subtle"></div>
|
|
32
|
-
|
|
33
|
-
<div class="k-widget k-chart">
|
|
34
|
-
<div class="k-var--chart-font"></div>
|
|
35
|
-
<div class="k-var--chart-title-font"></div>
|
|
36
|
-
</div>
|
|
37
|
-
<div class="k-var--series-unset"></div>
|
|
38
|
-
<div class="k-var--series">
|
|
39
|
-
${m()}
|
|
40
|
-
</div>
|
|
41
|
-
`;
|
|
42
|
-
class y {
|
|
43
|
-
constructor(e) {
|
|
44
|
-
this.store = e;
|
|
45
|
-
}
|
|
46
|
-
setStyle(e, s) {
|
|
47
|
-
const o = e.split(".");
|
|
48
|
-
let l = this.store;
|
|
49
|
-
o.forEach((i, c, n) => {
|
|
50
|
-
c < n.length - 1 && (l = l[i] = l[i] || {});
|
|
51
|
-
});
|
|
52
|
-
const r = o.pop();
|
|
53
|
-
r && (l[r] = s);
|
|
54
|
-
}
|
|
55
|
-
setColors() {
|
|
56
|
-
this.mapColor("labels.color", "normal-text-color"), this.mapColor("labels.stroke.color", "background");
|
|
57
|
-
const e = this.element.querySelector(".k-var--kendo-color-subtle");
|
|
58
|
-
e.style.color = "var(--kendo-color-subtle)", this.mapColor("links.color", "kendo-color-subtle", "color"), this.mapColor("legend.labels.color", "normal-text-color"), this.mapColor("title.color", "normal-text-color");
|
|
59
|
-
}
|
|
60
|
-
setFonts() {
|
|
61
|
-
const e = a(this.queryStyle("chart-title-font")), s = a(this.queryStyle("chart-font"));
|
|
62
|
-
this.setStyle("title.font", e), this.setStyle("labels.font", s), this.setStyle("legend.labels.font", s);
|
|
63
|
-
}
|
|
64
|
-
setNodeColors() {
|
|
65
|
-
const e = this.element;
|
|
66
|
-
if (!e)
|
|
67
|
-
return;
|
|
68
|
-
const s = [].slice.call(e.querySelectorAll(".k-var--series div")), o = d(e.querySelector(".k-var--series-unset")), l = s.reduce(
|
|
69
|
-
(r, i) => {
|
|
70
|
-
const c = u(i.className), n = d(i);
|
|
71
|
-
return n !== o && (r[c] = n), r;
|
|
72
|
-
},
|
|
73
|
-
[]
|
|
74
|
-
// Will populate the colors in this array
|
|
75
|
-
);
|
|
76
|
-
this.setStyle("nodeColors", l);
|
|
77
|
-
}
|
|
78
|
-
mapColor(e, s, o = "backgroundColor") {
|
|
79
|
-
this.setStyle(e, this.queryStyle(s)[o]);
|
|
80
|
-
}
|
|
81
|
-
queryStyle(e) {
|
|
82
|
-
const s = this.element;
|
|
83
|
-
return window.getComputedStyle(s.querySelector(`.k-var--${e}`));
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
const p = (t, e) => {
|
|
87
|
-
const s = {
|
|
88
|
-
nodeColors: []
|
|
89
|
-
}, o = new y(s), l = o.element = t.createElement("div");
|
|
90
|
-
l.style.display = "none", l.innerHTML = k, t.body.appendChild(l);
|
|
91
|
-
try {
|
|
92
|
-
o.setColors(), o.setFonts(), o.setNodeColors();
|
|
93
|
-
} finally {
|
|
94
|
-
t.body.removeChild(o.element), o.element = null, e(s);
|
|
95
|
-
}
|
|
96
|
-
};
|
|
97
|
-
export {
|
|
98
|
-
p as loadTheme
|
|
99
|
-
};
|