excluded file btn fix

This commit is contained in:
Timo Bejan 2022-01-17 15:08:29 +02:00
parent 3de6f6d652
commit 7ddcb23fc9
2 changed files with 2 additions and 2 deletions

View File

@ -159,7 +159,7 @@ export class FileActionsComponent extends AutoUnsubscribe implements OnDestroy,
ariaExpanded: this._excludedPagesService?.shown$,
showDot: !!this.file.excludedPages?.length,
icon: 'red:exclude-pages',
show: !!this._excludedPagesService,
show: !!this._excludedPagesService && !this.file.excluded,
},
{
type: ActionTypes.circleBtn,

View File

@ -97,7 +97,7 @@ export class PermissionsService {
// TODO: Remove '?', after we make sure file is loaded before page
canPerformAnnotationActions(file: File): boolean {
return (file?.isUnderReview || file?.isUnderApproval) && this.isFileAssignee(file);
return !file.excluded && (file?.isUnderReview || file?.isUnderApproval) && this.isFileAssignee(file);
}
canUndoApproval(file: File | File[]): boolean {