Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(scale): #20265 when dataZomm.filterMode is “empty” or ‘none’, the line graph is scaled to only one category, it is not filtered correctly #20495

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

linlang171
Copy link

@linlang171 linlang171 commented Nov 10, 2024

Brief Information

This pull request is in the type of:

  • bug fixing
  • new feature
  • others

What does this PR do?

fix bug #20265 issue

Fixed issues

#20265 : datazoom.filterMode设为'empty'时line图在缩放至只剩一条数据时所有数据都依旧会渲然,未依照empty的规则进行筛选。

Details

Before: What was the problem?

when dataZomm.filterMode is “empty” or ‘none’, the line graph is scaled to only one category, it is not filtered correctly

image

After: How does it behave after the fixing?

The data is correctly filtered. And The bug is caused by calling the normalize method when calculating rendering values. When extra [1]==extra [0], it does not consider the possibility of NaN and returns 0.5 directly

8182f6148467cd28dbf5856e39d95bb

Document Info

One of the following should be checked.

  • This PR doesn't relate to document changes
  • The document should be updated later
  • The document changes have been made in apache/echarts-doc#xxx

Misc

ZRender Changes

  • This PR depends on ZRender changes (ecomfe/zrender#xxx).

Related test cases or examples to use the new APIs

N.A.

Others

Merging options

  • Please squash the commits into a single one when merging.

Other information

Copy link

echarts-bot bot commented Nov 10, 2024

Thanks for your contribution!
The community will review it ASAP. In the meanwhile, please checkout the coding standard and Wiki about How to make a pull request.

⚠️ MISSING DOCUMENT INFO: Please make sure one of the document options are checked in this PR's description. Search "Document Info" in the description of this PR. This should be done either by the author or the reviewers of the PR.

Copy link

echarts-bot bot commented Nov 10, 2024

Document changes are required in this PR. Please also make a PR to apache/echarts-doc for document changes and update the issue id in the PR description. When the doc PR is merged, the maintainers will remove the PR: awaiting doc label.

@echarts-bot echarts-bot bot added the PR: awaiting doc Document changes is required for this PR. label Nov 10, 2024
@linlang171 linlang171 closed this Nov 10, 2024
@echarts-bot echarts-bot bot added PR: doc unchanged and removed PR: awaiting review PR: awaiting doc Document changes is required for this PR. labels Nov 10, 2024
@linlang171 linlang171 reopened this Nov 10, 2024
@linlang171 linlang171 changed the title fix #20265 when dataZomm.filterMode is “empty” or ‘none’, the line graph is scaled to only one category, it is not filtered correctly fix(scale): #20265 when dataZomm.filterMode is “empty” or ‘none’, the line graph is scaled to only one category, it is not filtered correctly Nov 11, 2024
@linlang171
Copy link
Author

Is it possible to include this PR in the next version?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant