From 8caa35c2cf1ae84d0d8dac0c5cbaceab9faa7bbb Mon Sep 17 00:00:00 2001 From: jesperct Date: Thu, 28 May 2026 03:59:51 -0300 Subject: [PATCH] fix(chart-echarts): drop white textBorder from Funnel segment labels (#40468) (cherry picked from commit c73106b7a285f54dc9fc80826881c42bbf26c17d) --- .../plugin-chart-echarts/src/Funnel/transformProps.ts | 2 -- .../test/Funnel/transformProps.test.ts | 9 +++++++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/superset-frontend/plugins/plugin-chart-echarts/src/Funnel/transformProps.ts b/superset-frontend/plugins/plugin-chart-echarts/src/Funnel/transformProps.ts index fd3cce40c08..6739bc61053 100644 --- a/superset-frontend/plugins/plugin-chart-echarts/src/Funnel/transformProps.ts +++ b/superset-frontend/plugins/plugin-chart-echarts/src/Funnel/transformProps.ts @@ -238,8 +238,6 @@ export default function transformProps( formatter, show: showLabels, color: theme.colorText, - textBorderColor: theme.colorBgBase, - textBorderWidth: 1, }; const series: FunnelSeriesOption[] = [ diff --git a/superset-frontend/plugins/plugin-chart-echarts/test/Funnel/transformProps.test.ts b/superset-frontend/plugins/plugin-chart-echarts/test/Funnel/transformProps.test.ts index 9e6a5a10b77..94ef64ce211 100644 --- a/superset-frontend/plugins/plugin-chart-echarts/test/Funnel/transformProps.test.ts +++ b/superset-frontend/plugins/plugin-chart-echarts/test/Funnel/transformProps.test.ts @@ -75,6 +75,15 @@ describe('Funnel transformProps', () => { }), ); }); + + test('does not apply a text border to segment labels', () => { + // A white textBorder washes out the dark text on light-colored segments. + const result = transformProps(chartProps as EchartsFunnelChartProps); + const { label } = (result.echartOptions.series as any)[0]; + expect(label.color).toBe(supersetTheme.colorText); + expect(label.textBorderColor).toBeUndefined(); + expect(label.textBorderWidth).toBeUndefined(); + }); }); describe('formatFunnelLabel', () => {