From d64adc223aa33b359da23770a437ec2c2e379b9a Mon Sep 17 00:00:00 2001 From: wisonic-s Date: Mon, 1 Sep 2025 17:56:33 +0800 Subject: [PATCH] =?UTF-8?q?refactor(=E5=9B=BE=E8=A1=A8):=20=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E5=AF=B9=E7=A7=B0=E6=9D=A1=E5=BD=A2=E5=9B=BE=E9=BB=98?= =?UTF-8?q?=E8=AE=A4=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../panel/charts/g2/bar/bidirectional-bar.ts | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/g2/bar/bidirectional-bar.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/g2/bar/bidirectional-bar.ts index 795900fcf6..41de7529ed 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/g2/bar/bidirectional-bar.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/g2/bar/bidirectional-bar.ts @@ -872,6 +872,24 @@ export class BidirectionalHorizontalBar extends G2ChartView { return options } + setupDefaultOptions(chart: ChartObj): ChartObj { + chart.customStyle.yAxis = { + ...chart.customStyle.yAxis, + position: 'left' + } + chart.customStyle.yAxisExt = { + ...chart.customStyle.yAxisExt, + position: 'left', + splitLine: chart.customStyle.yAxis.splitLine + } + chart.customAttr.label = { + ...chart.customAttr.label, + position: 'right' + } + chart.customAttr.basicStyle.layout = 'horizontal' + return chart + } + protected setupOptions(chart: Chart, options: G2Spec) { return flow( this.configBasicStyle,