mirror of
https://github.com/apache/superset.git
synced 2026-07-27 17:12:36 +00:00
fix(chart-echarts): drop white textBorder from Funnel segment labels (#40468)
(cherry picked from commit c73106b7a2)
This commit is contained in:
@@ -238,8 +238,6 @@ export default function transformProps(
|
||||
formatter,
|
||||
show: showLabels,
|
||||
color: theme.colorText,
|
||||
textBorderColor: theme.colorBgBase,
|
||||
textBorderWidth: 1,
|
||||
};
|
||||
|
||||
const series: FunnelSeriesOption[] = [
|
||||
|
||||
@@ -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', () => {
|
||||
|
||||
Reference in New Issue
Block a user