fix(mobile): update pager functionality to use activeViews for page selection

Signed-off-by: Innei <tukon479@gmail.com>
This commit is contained in:
Innei 2025-04-03 21:36:47 +08:00
parent f08d2033da
commit 46e5943ee8
No known key found for this signature in database
GPG Key ID: 0F62D33977F021F7
1 changed files with 2 additions and 2 deletions

View File

@ -38,10 +38,10 @@ export function PagerList({
useEffect(() => {
return EventBus.subscribe("SELECT_TIMELINE", (data) => {
if (data.manual) {
pagerRef.current?.setPage(data.view.viewId)
pagerRef.current?.setPage(activeViews.findIndex((view) => view.view === data.view.viewId))
}
})
}, [pagerRef])
}, [activeViews, pagerRef])
return (
<AnimatedPagerView