Skip to content

Commit

Permalink
fix: axis date type
Browse files Browse the repository at this point in the history
  • Loading branch information
tannerlinsley committed Oct 1, 2021
1 parent 8eee048 commit 8a69dc6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils/buildAxis.linear.ts
Original file line number Diff line number Diff line change
Expand Up @@ -124,12 +124,12 @@ function buildTimeAxis<TDatum>(

// see https://stackoverflow.com/a/2831422
if (Object.prototype.toString.call(options.min) === '[object Date]') {
minValue = min([options.min, minValue as Date])
minValue = min([options.min as Date, minValue as Date])
shouldNice = false
}

if (Object.prototype.toString.call(options.max) === '[object Date]') {
maxValue = max([options.max, maxValue as Date])
maxValue = max([options.max as Date, maxValue as Date])
shouldNice = false
}

Expand Down

1 comment on commit 8a69dc6

@vercel
Copy link

@vercel vercel bot commented on 8a69dc6 Oct 1, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.