react-date-range
react-date-range copied to clipboard
Is there any props can stop jumping to start date after selecting endDate
Subject of the issue
Currently when we select start Date and end Date , the calendar will scroll or jump to start date. This is kind of confusing for some people to see what happening after selecting end Dat.
Do we have any option to stop this behaviour?
[BUG] Bug Reproduce Steps
- Select start date
- Select end date
- View will scroll to start date
[BUG] Expected behaviour
- Select start date
- Select end date
- View remain on end Date
Environment
Package Version: lates React version: 17.0.1 Node version: 14.0 Browser: Any
Hey, can you take a look into 1.4.0, we release https://github.com/hypeserver/react-date-range/pull/428 that fixes https://github.com/hypeserver/react-date-range/issues/427 , I guess this is a duplicate of that.
Thanks @kamyar , I am using it with scroll propc(vertical mode) , however in release note mentioned "allow prevention of unnecessary refocus on selection of a date in viewing range (for non-scrolled calendars)".
Also could you please mentioned what exactly need to pass to disable this auto focus ?
Thanks
I could not find
allow prevention of unnecessary refocus on selection of a date in viewing range (for non-scrolled calendars)
Can you link to it?
can you try passing preventSnapRefocus={true}
?
Hey guys!
I faced the same problem with scrolling to the start date after selecting the date period.
preventSnapRefocus={true}
- this only fixed unnecessary scroll to the left side of the 2-month calendar when we tried to select a date on the right side.
So it would be really great if we could remove the scroll of the calendar on any date interaction.
n you link to it?
Hi , Sure this is link of release notes [https://github.com/hypeserver/react-date-range/pull/428]
also I am using DateRange , for some reason show type error, (version 1.4.0)
for preventSnapRefocus={true}.
I created simple PR with an additional prop to prevent any unnecessary month jumpings
#516
Hi, getting the same problem in v1.4.0. Is there a solution for this? Thanks!
any solution yet? preventSnapRefocus={true} not work for daterange