Skip to content

Commit 3592222

Browse files
committed
fix(android): fix android scroll issue in bottom sheet
1 parent 3bb4d36 commit 3592222

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/Provider.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,11 @@ export function useFormSmartScroll({
128128
currentFocus.position + wrapperOffset >
129129
_keyboard.coordinates.end.screenY - currentFocus.height * 2
130130
) {
131-
return -currentFocus.height;
131+
if (wrapperOffset) {
132+
return -Math.abs(currentFocus.height + wrapperOffset);
133+
}
134+
135+
return -Math.abs(currentFocus.height / 4);
132136
}
133137

134138
return 0;

0 commit comments

Comments
 (0)