Skip to content

Add time zone support #4814

@tchan

Description

@tchan

I've forked a pen from https://codepen.io/adrianhurt/pen/GqvBzo?editors=1010 in which the x axis displays as intended.

Here is my fork https://codepen.io/travismchan/pen/VMromR
The x axis displays but the data is not aligned correctly, if you hover over the first data point after Jan 16th, it will display a value from January 15. And even then, the January 15th values seem to be shifted too much to the right, the Jan 15th 12:00 is not in the center of the tick from Jan 15-Jan 16 which is expected.

Context

I have a chartjs project that involves dynamic data where you can adjust the start and end dates. When the start and end dates span more than a year, the alignment is off as well. The giant bar after the October tick is from September. Another pain point is that it throws in "Nov 2017" squished in there which sometimes overlaps the second last tick.
screenshot

Edit: I think the squishing of nov 2017 is related to #3051

Environment

Any advice is appreciated.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions