You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bar charts not clipped when using filterMode: 'none' #17858
Hello there! I ran into a same trouble a couple of days ago and found a solution how to use a bar chart and line chart so that the filtering does not cut off the data. This solved my problem with dataZoom
All that is needed is to change the weakFilter behavior logic in the sources. For a line chart, using filters causes problems when 1-2 points remain, but @cfwang123 was able to find a solution to the problem of filter behavior, I suggest using the old filter for the bar chart, and in all other situations, the modified filter @cfwang123
from: var thisLeftOut = value < valueWindow[0]; var thisRightOut = value > valueWindow[1];
to: if(seriesModel.subType === 'bar') { var thisLeftOut = value < valueWindow[0]; var thisRightOut = value > valueWindow[1]; } else { var thisLeftOut = value < valueWindow[0] && seriesData.get(dataDims[i], dataIndex+1) < valueWindow[0]; var thisRightOut = value > valueWindow[1] && seriesData.get(dataDims[i], dataIndex-1) > valueWindow[1]; }
At least the lables should be updated, but I have no access to them. The issue is not missing a demo anymore and this is definitelty a bug and not a new feature request.
Nothing from my end. I'm hoping someone someday will have time to solve the issue. The issue still has the "pending" label, although it shouldn't be necessary.
Activity
echarts-bot commentedon Nov 7, 2022
@sirviot Please provide a demo for the issue either with Official Editor, CodePen, CodeSandbox or JSFiddle.
sirviot commentedon Nov 8, 2022
Linked to a JSFiddle and attached an image to visualize the problem.
Skuperday commentedon Jan 20, 2023
Hello there! I ran into a same trouble a couple of days ago and found a solution how to use a bar chart and line chart so that the filtering does not cut off the data. This solved my problem with dataZoom
All that is needed is to change the weakFilter behavior logic in the sources. For a line chart, using filters causes problems when 1-2 points remain, but @cfwang123 was able to find a solution to the problem of filter behavior, I suggest using the old filter for the bar chart, and in all other situations, the modified filter @cfwang123
from:
var thisLeftOut = value < valueWindow[0];var thisRightOut = value > valueWindow[1];to:
if(seriesModel.subType === 'bar') {var thisLeftOut = value < valueWindow[0];var thisRightOut = value > valueWindow[1];} else {var thisLeftOut = value < valueWindow[0] && seriesData.get(dataDims[i], dataIndex+1) < valueWindow[0];var thisRightOut = value > valueWindow[1] && seriesData.get(dataDims[i], dataIndex-1) > valueWindow[1];}B-o-s-s-e commentedon Feb 8, 2023
Any update on this? I have exactly the same problem and i am a bit lost. Is there any workaround to solve this?
sirviot commentedon Feb 14, 2023
At least the lables should be updated, but I have no access to them. The issue is not missing a demo anymore and this is definitelty a bug and not a new feature request.
gowthamicp commentedon Mar 1, 2023
@Ovilia
Bar chart not clipped when filterMode none is selected .Below is the code to replicate the issue :
gowthamicp commentedon Mar 13, 2023
Any update on this?
sirviot commentedon Mar 20, 2023
Nothing from my end. I'm hoping someone someday will have time to solve the issue. The issue still has the "pending" label, although it shouldn't be necessary.
gitter-me commentedon May 23, 2023
I can confirm the exact issue.
This makes zooming problematic if a bar and line series are in one chart.
sirviot commentedon Dec 12, 2023
Is there any possibility to have the issue fixed in some near future? Also, the issue still has the "pending" label.
Skuperday commentedon Jul 9, 2024
fix this behavior too under this pr: #18202, please help me make it more noticeable
akashsonune commentedon Mar 2, 2026
I think after the PR- #21511 This issue should be fixed. can we close?
refactor&feature:
100pah commentedon May 14, 2026
Fix in v6.1.0