Skip to content

Datetime line brush displays wrong 1:00AM instead of midnight #1453

@fracz

Description

@fracz

Bug report

Codepen

I have modified the brush chart codepen. The only things I changed are: the interval of the datapoints (from 86400 to 600), the start date is set to 2020-03-31T22:00:00+02:00, and the tooltip format has ben changed to display hours instead of dates.

https://codepen.io/fracz/pen/jOPJLoO

Explanation

When you open the codepen, the midnight date is displayed correctly as a 1 Apr.

image

Then, if you move the brush selection slightly to the right the midnight label is being set to 1:00.

image

If you keep moving the selection and pass the next hour, the label is getting back to 0:00 (but not 1 Apr) in the codepen:

image

The tooltip always shows the correct data even when the x-label are messed up.

image

Not a big deal, hovever in my application the labels are not fixed when moving right, so all of the labels are shifted by one hour, and it is much bigger problem. Could not reproduce such behavior in the codepen, though.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingverified

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions