diff --git a/komga-webui/src/views/BookReader.vue b/komga-webui/src/views/BookReader.vue index 79b659667..2bdfc691d 100644 --- a/komga-webui/src/views/BookReader.vue +++ b/komga-webui/src/views/BookReader.vue @@ -240,6 +240,24 @@

Click or press next again
to exit the reader.

+ + +
This book has specific reading direction set.
+
Reading direction has been set to {{ readingDirs.find(x => x.value === readingDirection).text }}. +
+
This only applies to this book and will not overwrite your settings.
+ + Dismiss + +
@@ -279,6 +297,7 @@ export default Vue.extend({ jumpToNextBook: false, jumpToPreviousBook: false, jumpConfirmationDelay: 3000, + snackReadingDirection: false, pages: [] as PageDto[], supportedMediaTypes: ['image/jpeg', 'image/png', 'image/gif'], convertTo: 'jpeg', @@ -320,7 +339,6 @@ export default Vue.extend({ }, async mounted () { window.addEventListener('keydown', this.keyPressed) - this.setup(this.bookId, Number(this.$route.query.page)) this.loadFromCookie(cookieReadingDirection, (v) => { this.readingDirection = v @@ -341,6 +359,8 @@ export default Vue.extend({ this.backgroundColor = v } }) + + this.setup(this.bookId, Number(this.$route.query.page)) }, destroyed () { window.removeEventListener('keydown', this.keyPressed) @@ -518,6 +538,15 @@ export default Vue.extend({ this.goToFirst() } + switch (this.book.metadata.readingDirection) { + case ReadingDirection.LEFT_TO_RIGHT: + case ReadingDirection.RIGHT_TO_LEFT: + // bypass setter so cookies aren't set + this.settings.readingDirection = this.book.metadata.readingDirection + this.snackReadingDirection = true + break + } + try { this.siblingNext = await this.$komgaBooks.getBookSiblingNext(bookId) } catch (e) {