fix(chart-line): adaptive y-axis tick precision for small decimal ranges#233
Merged
Conversation
Closed
…-line Agent-Logs-Url: https://github.com/antvis/Infographic/sessions/aca9d170-d41a-44d2-b381-fdf2a616d576 Co-authored-by: Aarebecca <25787943+Aarebecca@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix discontinuous value display on vertical axis
fix(chart-line): adaptive y-axis tick precision for small decimal ranges
Apr 14, 2026
Contributor
|
/gemini review |
Contributor
There was a problem hiding this comment.
Code Review
This pull request introduces dynamic tick formatting for the Y-axis in the ChartLine component, replacing a hardcoded check for integers. The reviewer suggests using D3's built-in tickFormat method instead of manual step and precision calculations to ensure idiomatic usage and better handling of floating-point precision issues.
…ision Agent-Logs-Url: https://github.com/antvis/Infographic/sessions/0c6b28a0-a891-483e-bbf0-14a568d5e00b Co-authored-by: Aarebecca <25787943+Aarebecca@users.noreply.github.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #233 +/- ##
==========================================
- Coverage 46.85% 46.85% -0.01%
==========================================
Files 342 342
Lines 28416 28417 +1
Branches 2400 2400
==========================================
Hits 13315 13315
- Misses 15088 15089 +1
Partials 13 13
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
Agent-Logs-Url: https://github.com/antvis/Infographic/sessions/a166fa68-300b-40e6-a9b2-7936ce472830 Co-authored-by: Aarebecca <25787943+Aarebecca@users.noreply.github.com>
Aarebecca
approved these changes
Apr 15, 2026
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.
npm run versionto bump versionpackage.json:0.2.16→0.2.17src/version.ts:VERSION = '0.2.17'