mirror of https://github.com/stashapp/stash.git
ChapterBug // Fix jump to wrong page if chapter number if (number - 1) % pagelength = 0 (#3730)
This commit is contained in:
parent
0069c48e7e
commit
0e199a525f
|
@ -466,7 +466,7 @@ export const LightboxComponent: React.FC<IProps> = ({
|
|||
function gotoPage(imageIndex: number) {
|
||||
const indexInPage = (imageIndex - 1) % pageSize;
|
||||
if (pageCallback) {
|
||||
let jumppage = Math.floor(imageIndex / pageSize) + 1;
|
||||
let jumppage = Math.floor((imageIndex - 1) / pageSize) + 1;
|
||||
if (page !== jumppage) {
|
||||
pageCallback({ page: jumppage });
|
||||
oldImages.current = images;
|
||||
|
|
Loading…
Reference in New Issue