BugiDev / react-native-calendar-strip

Easy to use and visually stunning calendar component for React Native.
MIT License
959 stars 329 forks source link

when we put minDate ={moment()} then next week not scrolling #338

Open Gaurang-786 opened 2 years ago

Gaurang-786 commented 2 years ago

https://user-images.githubusercontent.com/98010969/150781680-3057cdad-ce3e-4d4f-8713-316dd70b9f89.mp4

vishalpr-hs commented 2 years ago

I am also facing same issue. Found any solution? @Gaurang-786

AhtshamHayee commented 2 years ago

same issue

MoRa2297 commented 2 years ago

Same issue, somebody can give us some answers?

jaxgia93 commented 2 years ago

Same issue, news?

Gaurang-786 commented 2 years ago

no

On Fri, 10 Jun 2022 at 21:14, jaxgia93 @.***> wrote:

Same issue, news?

— Reply to this email directly, view it on GitHub https://github.com/BugiDev/react-native-calendar-strip/issues/338#issuecomment-1152497574, or unsubscribe https://github.com/notifications/unsubscribe-auth/AXLYOWKTDBBNQICJJCI56U3VONPHHANCNFSM5MVGXZ7Q . You are receiving this because you were mentioned.Message ID: @.***>

Nautman commented 2 years ago

Same issue here.

239 seems to address the same problem.

Has anyone found a workaround except simply disabling the scrollable prop?

brycepavey commented 2 years ago

Also facing this with scrollable and minDate. I've narrowed it down to the line this.rlv.scrollToIndex(i, false); inside this.timeoutResetPositionId timeout function of updateDays in Scroller.js, as below:

// RecyclerListView sometimes returns position to old index after
// moving to the new one. Set position again after delay.
this.timeoutResetPositionId = setTimeout(() => {
          this.timeoutResetPositionId = null;
          this.rlv.scrollToIndex(i, false); // <---
          this.shifting = false; // debounce
        }, 800);

I've removed that line and I haven't experienced the issue that the comment in the code is referring to, if that is in fact a problem the solution may need to be refactored to not using a timeout