Skip to content

Commit 344a1f2

Browse files
committed
Fix - VueUiXy fixed missing individual scale for bar types
1 parent b54d3f5 commit 344a1f2

File tree

4 files changed

+7
-5
lines changed

4 files changed

+7
-5
lines changed

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "vue-data-ui",
33
"private": false,
4-
"version": "2.1.50",
4+
"version": "2.1.51",
55
"type": "module",
66
"description": "A user-empowering data visualization Vue 3 components library for eloquent data storytelling",
77
"keywords": [

src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ const dataset2 = ref([
9999
{
100100
name: "Series 1",
101101
series: [ 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55],
102-
type: "plot",
102+
type: "bar",
103103
color: "rgb(95,139,238)",
104104
smooth: true,
105105
scaleSteps: 20,

src/components/vue-ui-xy.vue

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1145,6 +1145,8 @@ export default {
11451145
const zeroPosition = this.drawingArea.bottom - (this.drawingArea.height * individualZero / individualMax);
11461146
return {
11471147
individualScale,
1148+
zeroPosition,
1149+
individualMax,
11481150
...datapoint,
11491151
plots: datapoint.series.map((plot, j) => {
11501152
const yRatio = this.chartConfig.chart.grid.labels.yAxis.useIndividualScale ? ((datapoint.absoluteValues[j] + individualZero) / individualMax) : this.ratioToMax(plot)
@@ -1154,7 +1156,7 @@ export default {
11541156
y: this.drawingArea.bottom - (this.drawingArea.height * yRatio),
11551157
value: datapoint.absoluteValues[j],
11561158
zeroPosition,
1157-
individualMax
1159+
individualMax,
11581160
}
11591161
}),
11601162
}

0 commit comments

Comments
 (0)