@record-evolution/widget-linechart 1.6.21 → 1.6.23
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/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "Webcomponent widget-linechart following open-wc recommendations",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "widget-linechart",
|
|
6
|
-
"version": "1.6.
|
|
6
|
+
"version": "1.6.23",
|
|
7
7
|
"type": "module",
|
|
8
8
|
"main": "dist/widget-linechart.js",
|
|
9
9
|
"types": "dist/src/widget-linechart.d.ts",
|
package/src/widget-linechart.ts
CHANGED
|
@@ -84,6 +84,7 @@ export class WidgetLinechart extends LitElement {
|
|
|
84
84
|
title: {
|
|
85
85
|
text: 'Temperature Change in the Coming Week',
|
|
86
86
|
left: 20,
|
|
87
|
+
top: 0,
|
|
87
88
|
textStyle: {
|
|
88
89
|
fontSize: 14
|
|
89
90
|
}
|
|
@@ -439,7 +440,11 @@ export class WidgetLinechart extends LitElement {
|
|
|
439
440
|
// option.yAxis.axisLine.lineStyle.width = 2 * modifier
|
|
440
441
|
// option.yAxis.axisLabel.fontSize = 20 * modifier
|
|
441
442
|
option.yAxis.scale = this.inputData?.axis?.yAxisScaling ?? false
|
|
442
|
-
|
|
443
|
+
if (['value', 'log'].includes(option.yAxis.type))
|
|
444
|
+
option.yAxis.axisLabel = {
|
|
445
|
+
'font-size': 14,
|
|
446
|
+
formatter: (value: number) => Math.round(value * 100) / 100
|
|
447
|
+
}
|
|
443
448
|
|
|
444
449
|
const notMerge = option.series.length !== chart.series.length
|
|
445
450
|
option.series = chart.series
|