fix(viewer): use info.index * windowWidth for onScrollToIndexFailed offset

This commit is contained in:
arnauda-gh
2026-10-09 09:05:27 +02:00
parent 200404483c
commit 465eeffd1e
+1 -1
View File
@@ -743,7 +743,7 @@ function EmailViewer({ route, navigation }: Props) {
onMomentumScrollEnd={onMomentumEnd}
onScrollToIndexFailed={(info) => {
setTimeout(() => {
listRef.current?.scrollToOffset({ offset: info.offset, animated: false });
listRef.current?.scrollToOffset({ offset: info.index * windowWidth, animated: false });
}, 50);
}}
renderItem={({ item, index }) => (