Skip to content

bug: selecting the same day in range mode when range is open #2813

@rodgobbi

Description

@rodgobbi

Based on the discussion #2796 (comment)

To reproduce

Using the following Code Sandbox: https://codesandbox.io/p/devbox/daypicker-bug-report-forked-wwk9mh

Click on any day in the calendar, then click again on the same day.

Actual Behavior

When providing a date range with only from date, clicking on the same day unselects the date range.

Expected Behavior

When providing a date range with only from date, clicking on the same day completes the date range selection, with the range being the same day.

Notes

This seems like an edge case when min is equal to zero.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions