references dialog wip

This commit is contained in:
Edi Cziszter 2022-01-05 15:24:46 +02:00
parent 73662cecfe
commit 7ce34ca329
7 changed files with 11 additions and 9 deletions

View File

@ -38,6 +38,7 @@ export class AnnotationActionsComponent implements OnChanges {
@Input() alwaysVisible: boolean;
@Input() @Required() file!: File;
@Output() annotationsChanged = new EventEmitter<AnnotationWrapper>();
@Output() seeReferences = new EventEmitter<boolean>();
annotationPermissions: AnnotationPermissions;
constructor(
@ -157,7 +158,6 @@ export class AnnotationActionsComponent implements OnChanges {
}
openAnnotationReferencesDialog(): void {
const data = {};
this._dialogService.openDialog('seeAnnotationReferences', null, data, async () => {});
this.seeReferences.emit(true);
}
}

View File

@ -1,4 +1,4 @@
<section class="dialog">
<section class="dialog references-dialog">
<div class="dialog-header heading-l">X REFERENCES</div>
<iqser-circle-button class="dialog-close" icon="iqser:close" mat-dialog-close></iqser-circle-button>
</section>

View File

@ -1,5 +1,5 @@
import { Component } from '@angular/core';
import { BaseDialogComponent } from '../../../../../../../../../../libs/common-ui/src';
import { BaseDialogComponent } from '@iqser/common-ui';
@Component({
selector: 'redaction-annotation-references-dialog',

View File

@ -50,6 +50,7 @@
<redaction-annotation-actions
(annotationsChanged)="annotationsChanged.emit($event)"
(seeReferences)="seeReferences.emit($event)"
*ngIf="selectedAnnotations?.length > 0"
[alwaysVisible]="true"
[annotations]="selectedAnnotations"

View File

@ -60,6 +60,7 @@ export class FileWorkloadComponent {
@Output() readonly deselectAnnotations = new EventEmitter<AnnotationWrapper[]>();
@Output() readonly selectPage = new EventEmitter<number>();
@Output() readonly annotationsChanged = new EventEmitter<AnnotationWrapper>();
@Output() readonly seeReferences = new EventEmitter<boolean>();
displayedPages: number[] = [];
pagesPanelActive = true;
readonly displayedAnnotations$: Observable<Map<number, AnnotationWrapper[]>>;

View File

@ -24,8 +24,7 @@ type DialogType =
| 'removeAnnotations'
| 'resizeAnnotation'
| 'forceRedaction'
| 'manualAnnotation'
| 'seeAnnotationReferences';
| 'manualAnnotation';
@Injectable()
export class DossiersDialogService extends DialogService<DialogType> {
@ -69,9 +68,6 @@ export class DossiersDialogService extends DialogService<DialogType> {
component: ManualAnnotationDialogComponent,
dialogConfig: { autoFocus: true },
},
seeAnnotationReferences: {
component: AnnotationReferencesDialogComponent,
},
};
constructor(protected readonly _dialog: MatDialog) {