mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Fix lint
This commit is contained in:
parent
a7df7ad720
commit
21152040ec
3 changed files with 12 additions and 13 deletions
|
@ -123,8 +123,8 @@ export class BookPlayer {
|
|||
|
||||
onTouchStart(e) {
|
||||
// TODO: depending on the event this can be the document or the rendition itself
|
||||
let rendition = this._rendition || this;
|
||||
let book = rendition.book;
|
||||
const rendition = this._rendition || this;
|
||||
const book = rendition.book;
|
||||
|
||||
// check that the event is from the book or the document
|
||||
if (!book || this._loaded === false) return;
|
||||
|
@ -132,7 +132,8 @@ export class BookPlayer {
|
|||
// epubjs stores pages off the screen or something for preloading
|
||||
// get the modulus of the touch event to account for the increased width
|
||||
if (!e.touches || e.touches.length === 0) return;
|
||||
let touch = e.touches[0].clientX % dom.getWindowSize().innerWidth;
|
||||
|
||||
const touch = e.touches[0].clientX % dom.getWindowSize().innerWidth;
|
||||
if (touch < dom.getWindowSize().innerWidth / 2) {
|
||||
book.package.metadata.direction === 'rtl' ? rendition.next() : rendition.prev();
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue