keep hidden annotations hidden

This commit is contained in:
Dan Percic 2023-08-18 11:22:08 +03:00
parent f25c7ac3e7
commit d049335309
2 changed files with 10 additions and 12 deletions

View File

@ -461,9 +461,7 @@ export class FilePreviewScreenComponent
tap(annotations => this.deleteAnnotations(...annotations)),
);
const currentPage$ = this.pdf.currentPage$.pipe(tap(() => this._annotationManager.showHidden()));
const currentPageIfNotHighlightsView$ = combineLatest([currentPage$, this._viewModeService.viewMode$]).pipe(
const currentPageIfNotHighlightsView$ = combineLatest([this.pdf.currentPage$, this._viewModeService.viewMode$]).pipe(
filter(([, viewMode]) => viewMode !== ViewModes.TEXT_HIGHLIGHTS),
map(([page]) => page),
);

View File

@ -1,16 +1,16 @@
import { Injectable } from '@angular/core';
import { Core } from '@pdftron/webviewer';
import { hexToRgb } from '@utils/functions';
import { AnnotationWrapper } from '@models/file/annotation.wrapper';
import { UserPreferenceService } from '@users/user-preference.service';
import { RedactionLogService } from '@services/files/redaction-log.service';
import { IRectangle, ISectionRectangle, SuperTypes } from '@red/domain';
import { PdfViewer } from './pdf-viewer.service';
import { REDAnnotationManager } from './annotation-manager.service';
import { List } from '@iqser/common-ui/lib/utils';
import { REDDocumentViewer } from './document-viewer.service';
import { AnnotationWrapper } from '@models/file/annotation.wrapper';
import { Core } from '@pdftron/webviewer';
import { IRectangle, ISectionRectangle, SuperTypes } from '@red/domain';
import { DefaultColorsService } from '@services/entity-services/default-colors.service';
import { RedactionLogService } from '@services/files/redaction-log.service';
import { UserPreferenceService } from '@users/user-preference.service';
import { hexToRgb } from '@utils/functions';
import { BoundingBox, Table } from '../../file-preview/services/tables.service';
import { REDAnnotationManager } from './annotation-manager.service';
import { REDDocumentViewer } from './document-viewer.service';
import { PdfViewer } from './pdf-viewer.service';
import Annotation = Core.Annotations.Annotation;
import Quad = Core.Math.Quad;