sadpandajoe commented on code in PR #42882:
URL: https://github.com/apache/superset/pull/42882#discussion_r3821280588
##########
superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts:
##########
@@ -467,9 +467,19 @@ export function transformSeries(
return formatter(numericValue);
}
if (!onlyTotal) {
+ // A zero-height stacked segment has no meaningful position to
+ // attach a label to: it starts and ends at the same y-coordinate
+ // as the top of the previous segment, so its label would render
+ // directly on top of that segment's own label. Excluding exactly
+ // 0 keeps this independent of the configured percentage
+ // threshold, whose default of 0 would otherwise let a value of
+ // exactly 0 pass (#42702) — a strictly-positive check would also
+ // wrongly suppress a genuine negative value that clears a
+ // (possibly also negative) threshold.
if (
+ numericValue !== 0 &&
Review Comment:
This drops an explicitly enabled `0` label on stacked line or area series
even when it has its own coordinate, because this formatter is shared across
all series types. Should the zero suppression be limited to bar series, where
the overlap occurs?
--
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]