load first page on read manga (#76)
This commit is contained in:
@@ -87,8 +87,9 @@ export default function HorizontalPager(props: IReaderProps) {
|
||||
};
|
||||
|
||||
useEffect(() => {
|
||||
// scroll last read page into view after first mount
|
||||
pagesRef.current[curPage]?.scrollIntoView({ inline: 'center' });
|
||||
}, [settings.readerType]);
|
||||
}, [pagesRef.current.length]);
|
||||
|
||||
useEffect(() => {
|
||||
selfRef.current?.addEventListener('mousedown', dragControl);
|
||||
|
||||
Reference in New Issue
Block a user