Copilot commented on code in PR #42854:
URL: https://github.com/apache/superset/pull/42854#discussion_r3737509945
##########
superset-frontend/plugins/plugin-chart-echarts/test/Timeseries/transformers.test.ts:
##########
@@ -87,6 +90,70 @@ describe('transformSeries', () => {
);
});
+ describe('stacked value labels', () => {
+ // Two series stacked on one category: A is 32, B is 0. The zero-height
+ // B segment must not render a label over A's label.
+ const buildFormatter = (thresholdValues: number[]) => {
+ const result = transformSeries(series, mockColorScale, 'test-key', {
+ showValue: true,
+ stack: StackControlsValue.Stack,
+ onlyTotal: false,
+ formatter: (v: any) => String(v),
Review Comment:
Avoid introducing an explicit `any` type in the test formatter.
`transformSeries` passes a numeric value here, and `String(...)` works fine
with `unknown`, preserving type-safety without loosening types further.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]