fix(marker): use raw value without precision rounding when the mark line targets a specific axis value or is in min/max type - #21752
Open
plainheart wants to merge 2 commits into
Open
fix(marker): use raw value without precision rounding when the mark line targets a specific axis value or is in min/max type#21752plainheart wants to merge 2 commits into
min/max type#21752plainheart wants to merge 2 commits into
Conversation
…ult precision when it targets axis value to ensure it is at the expected position
|
Thanks for your contribution! The pull request is marked to be |
There was a problem hiding this comment.
🟡 Changes recommended
Values requiring more than 20 decimal places are still rounded incorrectly.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
Fixes mark-line positioning when explicit axis values exceed the default precision.
Changes:
- Derives precision from explicit axis values.
- Adds a browser regression case.
File summaries
| File | Description |
|---|---|
src/component/marker/MarkLineView.ts |
Adjusts mark-line coordinate rounding. |
test/markLine-precision.html |
Demonstrates explicit-value precision behavior. |
Review details
- Files reviewed: 2/2 changed files
- Comments generated: 1
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
…ine targets a specific axis value or is in `min/max` type
min/max type
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Brief Information
This pull request is in the type of:
What does this PR do?
[Behavior Change]
min/maxtype is now also using the raw value without precision conversion.For example:
Since
precisiondefaults to2, the mark line above is rounded to2.02. So it appears in an unexpected position and even disappears whenyAxis.minis2.015.Fixed issues
Fixes #21743
Comparison
Document Info
One of the following should be checked.
Misc
Security Checking
ZRender Changes
Related test cases or examples to use the new APIs
test/markLine-precision.html
Merging options
Other information