Skip to content

Commit

Permalink
Restore PDF layout menu (#2605)
Browse files Browse the repository at this point in the history
  • Loading branch information
tjarls authored Jan 18, 2024
1 parent e77d1c0 commit f44ba1c
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 4 deletions.
6 changes: 3 additions & 3 deletions UI/Web/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
[backgroundColor]="backgroundColor"
[customToolbar]="multiToolbar"
[language]="user.preferences.locale"
[(scrollMode)]="scrollMode"

(pageChange)="saveProgress()"
(pdfLoadingStarts)="updateLoading(true)"
Expand Down Expand Up @@ -86,6 +87,14 @@

<div class="verticalToolbarSeparator hiddenSmallView"></div>
<pdf-toggle-secondary-toolbar></pdf-toggle-secondary-toolbar>

<pdf-single-page-mode [show]="true" [scrollMode]="scrollMode"></pdf-single-page-mode>
<pdf-vertical-scroll-mode [show]="true" [scrollMode]="scrollMode"></pdf-vertical-scroll-mode>
<pdf-horizontal-scroll [show]="true" [scrollMode]="scrollMode"></pdf-horizontal-scroll>
<pdf-wrapped-scroll-mode [show]="true" [scrollMode]="scrollMode"></pdf-wrapped-scroll-mode>
<pdf-no-spread [show]=true [scrollMode]="scrollMode"></pdf-no-spread>
<pdf-odd-spread [show]=true [scrollMode]="scrollMode"></pdf-odd-spread>
<pdf-even-spread [show]="true" [scrollMode]="scrollMode"></pdf-even-spread>
</div>

</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
OnInit, ViewChild
} from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
import { NgxExtendedPdfViewerService, PageViewModeType, ProgressBarEvent, NgxExtendedPdfViewerModule } from 'ngx-extended-pdf-viewer';
import { NgxExtendedPdfViewerService, PageViewModeType, ScrollModeType, ProgressBarEvent, NgxExtendedPdfViewerModule } from 'ngx-extended-pdf-viewer';
import { ToastrService } from 'ngx-toastr';
import { take } from 'rxjs';
import { BookService } from 'src/app/book-reader/_services/book.service';
Expand Down Expand Up @@ -89,6 +89,8 @@ export class PdfReaderComponent implements OnInit, OnDestroy {
*/
bookMode: PageViewModeType = 'multiple';

scrollMode: ScrollModeType = ScrollModeType.vertical;

constructor(private route: ActivatedRoute, private router: Router, public accountService: AccountService,
private seriesService: SeriesService, public readerService: ReaderService,
private navService: NavService, private toastr: ToastrService,
Expand Down

0 comments on commit f44ba1c

Please sign in to comment.