From 1358198f548a8bf0aaf3ae95b4c564fb44bf8613 Mon Sep 17 00:00:00 2001 From: Sergey Rozhkov Date: Thu, 13 Mar 2025 15:18:56 +0700 Subject: [PATCH] fix: The calendar does not always scroll to the right side of the month when pressed on Android #459 --- src/Date/Swiper.native.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Date/Swiper.native.tsx b/src/Date/Swiper.native.tsx index 22343e76..48a6cdfc 100644 --- a/src/Date/Swiper.native.tsx +++ b/src/Date/Swiper.native.tsx @@ -105,7 +105,7 @@ function SwiperInner({ const contentOffset = e.nativeEvent.contentOffset const viewSize = e.nativeEvent.layoutMeasurement const newIndex = isHorizontal - ? Math.floor(contentOffset.x / viewSize.width) + ? Math.round(contentOffset.x / viewSize.width) : getIndexFromVerticalOffset( contentOffset.y - beginOffset, startWeekOnMonday