From 68ab6a088e387b11036ffe58dea5f89a9392a8cc Mon Sep 17 00:00:00 2001 From: jianneng-fit2cloud Date: Wed, 4 Dec 2024 21:56:42 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E5=9B=BE=E8=A1=A8):=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E8=B1=A1=E9=99=90=E5=9B=BE=E6=8B=96=E5=85=A5=E5=BF=85=E8=A6=81?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E5=90=8E=E6=98=BE=E7=A4=BA=E7=A9=BA=E7=99=BD?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../chart/components/js/panel/charts/others/quadrant.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/quadrant.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/quadrant.ts index f81f1b34ef..cb15ae690f 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/quadrant.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/quadrant.ts @@ -217,8 +217,11 @@ export class Quadrant extends G2PlotChartView { newChart.on('point:click', action) newChart.on('click', () => quadrantDefaultBaseline(defaultBaselineQuadrant)) newChart.on('afterrender', () => quadrantDefaultBaseline(defaultBaselineQuadrant)) - configYaxisTitleLengthLimit(chart, newChart) - configAxisLabelLengthLimit(chart, newChart, 'axis-title') + const yAxis = parseJson(chart.customStyle).yAxis + if (yAxis?.name) { + configYaxisTitleLengthLimit(chart, newChart) + configAxisLabelLengthLimit(chart, newChart, 'axis-title') + } configPlotTooltipEvent(chart, newChart) return newChart }