Repository navigation
feat(charts): time axis for line charts with date X columns (#1159) - #1225
Merged
Merged
Conversation
A line chart drew its X axis by row number, so dates were spaced evenly whatever the real gaps. When every X cell is an ISO date or timestamp, points are sorted by time and placed at their real distance, and the axis shows dates: hours, days or months, picked from the range. The SVG export does the same. Other X columns keep their row order.
…me-axis test (#1159) DateTime rolls an impossible date over, so 2026-13-45 parsed as 2027-02-14. The parsed fields must now match the text. 1 January to 1 March is 59 days, not 58: the gap ratio of 58 to 1 in the issue holds.
3 tasks
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.
Closes #1159
What was wrong
The line chart used the row number as X, so dates were spaced evenly regardless of the real gaps, and the axis did not show time.
Changes
ChartData.parseTimereads ISO dates and timestamps (with or without a time or zone).isTimeColumndecides when the X column is a time column.Not in this PR
columnDataTypes) is not used; detection parses the cells. The issue allowed either.Not verified locally
Tests were not run locally, per the project rule.