mirror of
https://github.com/futurepress/epub.js.git
synced 2025-10-05 15:32:55 +02:00
Fix spine first & last
This commit is contained in:
parent
c6631d10b7
commit
b7640a1d7d
1 changed files with 3 additions and 2 deletions
|
@ -214,11 +214,12 @@ class Spine {
|
|||
|
||||
do {
|
||||
let next = this.get(index);
|
||||
|
||||
if (next && next.linear) {
|
||||
return next;
|
||||
}
|
||||
index += 1;
|
||||
} while (index < this.spineItems.length-1) ;
|
||||
} while (index < this.spineItems.length) ;
|
||||
}
|
||||
|
||||
last() {
|
||||
|
@ -230,7 +231,7 @@ class Spine {
|
|||
return prev;
|
||||
}
|
||||
index -= 1;
|
||||
} while (index > 0);
|
||||
} while (index >= 0);
|
||||
}
|
||||
|
||||
destroy() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue