@record-evolution/widget-linechart 1.5.1 → 1.5.2
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.5.
|
|
6
|
+
"version": "1.5.2",
|
|
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
|
@@ -92,7 +92,7 @@ export class WidgetLinechart extends LitElement {
|
|
|
92
92
|
})
|
|
93
93
|
})
|
|
94
94
|
// prevent duplicate transformation
|
|
95
|
-
this.inputData.dataseries = []
|
|
95
|
+
// this.inputData.dataseries = []
|
|
96
96
|
// console.log('new linechart datasets', this.canvasList)
|
|
97
97
|
}
|
|
98
98
|
|
|
@@ -115,7 +115,7 @@ export class WidgetLinechart extends LitElement {
|
|
|
115
115
|
|
|
116
116
|
xAxisType(): 'linear' | 'logarithmic' | 'category' | 'time' | 'timeseries' | undefined {
|
|
117
117
|
if (this.inputData?.axis?.timeseries) return 'time'
|
|
118
|
-
const onePoint = this.inputData?.dataseries?.[0]
|
|
118
|
+
const onePoint = this.inputData?.dataseries?.[0]?.data?.[0]
|
|
119
119
|
if (!isNaN(Number(onePoint?.x))) return 'linear'
|
|
120
120
|
return 'category'
|
|
121
121
|
}
|