-
Notifications
You must be signed in to change notification settings - Fork 19.7k
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(toolbox): optimize stack icon toggle experience. #12360
Conversation
Merge some commits from apache/master
… `tiled` if stack is not enabled. close apache#12359.
Thanks for your contribution! The pull request is marked to be |
magictypechanged
should be the type tiled
if stack is not enabled. close #12359.magictypechanged
should return the type tiled
if stack is not enabled. close #12359.
magictypechanged
should return the type tiled
if stack is not enabled. close #12359.magictypechanged
should return the type tiled
if stack is not enabled. close #12359.
magictypechanged
should return the type tiled
if stack is not enabled. close #12359.var iconPaths = featureModel.iconPaths = {}; | ||
zrUtil.each(icons, function (iconStr, iconName) { | ||
// `tiled` is just for changing stack toggle icon, no need to add a path. | ||
if (isMagicType && iconName === 'tiled') { | ||
return; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's better to put this logic in the render
and updateView
method of MagicType.js
. ToolboxView should be not aware of what features it may have.
brush feature is a typical example: https://github.com/apache/incubator-echarts/blob/next/src/component/toolbox/feature/Brush.ts#L47
You may refactor it in the next branch if you wish
Do it in 5.0. |
What's the release date of 5.0? |
Brief Information
This pull request is in the type of:
What does this PR do?
currentType
inmagictypechanged
event should betiled
(Magictype Event #12359)Fixed issues
Related test cases
Test case: refer to
test/toolbox-stackTiledToggle.html