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: Dump areaStyle polygon when notMerge is true #16772

Merged
merged 3 commits into from
Apr 11, 2022

Conversation

jiawulin001
Copy link
Member

Brief Information

This pull request is in the type of:

  • bug fixing
  • new feature
  • others

What does this PR do?

Fix the problem where area shading is not removed after setting chart to be step chart without areaStyle.

Fixed issues

Details

Before: What was the problem?

When a line chart with area shade on, changes its option in notMerge mode into a step line chart and turned off the area shade, the previous area shade would not disappear. The causing code is discussed here: #16769 (comment).

Before change Option After change Option
before setOption after setOption-bug

After: How is it fixed in this PR?

Add an else to dump the polygon if isAreaChart is false.

Before change Option After change Option
before setOption after setOption-fix

Misc

  • The API has been changed (apache/echarts-doc#xxx).
  • This PR depends on ZRender changes (ecomfe/zrender#xxx).

Related test cases or examples to use the new APIs

A test case is added in test/setOption.html

@echarts-bot
Copy link

echarts-bot bot commented Mar 30, 2022

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.

@pissang
Copy link
Contributor

pissang commented Apr 5, 2022

LGTM

pissang
pissang previously approved these changes Apr 5, 2022
test/setOption.html Outdated Show resolved Hide resolved
@plainheart plainheart merged commit 3b7ff4f into apache:master Apr 11, 2022
@echarts-bot
Copy link

echarts-bot bot commented Apr 11, 2022

Congratulations! Your PR has been merged. Thanks for your contribution! 👍

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

Successfully merging this pull request may close these issues.

[Bug] Changing area chart to step chart is not removing the area shading
3 participants