Copilot commented on code in PR #21600:
URL: https://github.com/apache/echarts/pull/21600#discussion_r3176901301
##########
src/component/dataZoom/AxisProxy.ts:
##########
@@ -297,7 +297,9 @@ class AxisProxy {
each(seriesModels, function (seriesModel) {
let seriesData = seriesModel.getData();
- const dataDims = seriesData.mapDimensionsAll(axisDim);
+ // Use the same dimensions as axis extent calculation. Stacked
series
+ // are rendered by their stack result dimension, not the original
value dimension.
+ const dataDims = getDataDimensionsOnAxis(seriesData, axisDim);
Review Comment:
Using `getDataDimensionsOnAxis` here breaks stacked series when `filterMode`
is `empty`: for a stacked axis it returns the calculated
`stackResultDimension`, but the `empty` branch later only writes `NaN` into
that calculation dimension. The stack processor runs after dataZoom filtering
and recomputes `stackResultDimension` from the original stacked value
dimension, so the out-of-window points come back instead of staying empty.
##########
src/component/dataZoom/AxisProxy.ts:
##########
@@ -297,7 +297,9 @@ class AxisProxy {
each(seriesModels, function (seriesModel) {
let seriesData = seriesModel.getData();
- const dataDims = seriesData.mapDimensionsAll(axisDim);
+ // Use the same dimensions as axis extent calculation. Stacked
series
+ // are rendered by their stack result dimension, not the original
value dimension.
+ const dataDims = getDataDimensionsOnAxis(seriesData, axisDim);
Review Comment:
This helper change also affects the `weakFilter` path, but the new
regression only exercises the default `filter` mode. Since toolbox `dataZoom`
exposes `filterMode`, stacked-series behavior under `weakFilter` is still
unverified here.
--
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]