cherrypick compare view
This commit is contained in:
parent
32723d2fc0
commit
8c44b3bfbb
@ -20,7 +20,7 @@
|
||||
min="1"
|
||||
[max]="totalPages"
|
||||
type="number"
|
||||
(change)="navigateToPage(pageInput.value)"
|
||||
(change)="navigateToPageByInput(pageInput.value)"
|
||||
class="page-number-input"
|
||||
/>
|
||||
</div>
|
||||
|
||||
@ -114,7 +114,7 @@ export class PdfViewerComponent implements OnInit, AfterViewInit, OnChanges {
|
||||
|
||||
const annotationsFromViewer = annotations.map(ann => this._getAnnotationById(ann.id));
|
||||
this.instance.annotManager.selectAnnotations(annotationsFromViewer);
|
||||
this.navigateToPage(annotations[0].pageNumber);
|
||||
// this.navigateToPage(annotations[0].pageNumber*this.paginationOffset);
|
||||
this.instance.annotManager.jumpToAnnotation(annotationsFromViewer[0]);
|
||||
}
|
||||
|
||||
@ -831,4 +831,8 @@ export class PdfViewerComponent implements OnInit, AfterViewInit, OnChanges {
|
||||
get paginationOffset() {
|
||||
return this.isCompareMode ? 2 : 1;
|
||||
}
|
||||
|
||||
navigateToPageByInput(pageNumber) {
|
||||
this.navigateToPage(pageNumber * this.paginationOffset);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user