hide apply&discard rotations when file is disabled

This commit is contained in:
Dan Percic 2022-03-14 18:57:38 +02:00
parent 5818acca45
commit 4cced2998f

View File

@ -647,7 +647,12 @@ export class PdfViewerComponent extends AutoUnsubscribe implements OnInit, OnCha
return; return;
} }
let elementsToDisable = [...elementsToToggle, TextPopups.ADD_RECTANGLE]; let elementsToDisable = [
...elementsToToggle,
TextPopups.ADD_RECTANGLE,
HeaderElements.APPLY_ROTATION,
HeaderElements.DISCARD_ROTATION,
];
if (isCurrentPageExcluded) { if (isCurrentPageExcluded) {
const allowedActionsWhenPageExcluded: string[] = [ const allowedActionsWhenPageExcluded: string[] = [
@ -662,6 +667,7 @@ export class PdfViewerComponent extends AutoUnsubscribe implements OnInit, OnCha
} }
this.instance.UI.disableElements(elementsToDisable); this.instance.UI.disableElements(elementsToDisable);
this._pageRotationService.discardRotation();
} }
private _getManualRedaction( private _getManualRedaction(