mentions ui fix

This commit is contained in:
CITE\spapacharalampous 2024-07-16 12:48:46 +03:00
parent 2283f95a5f
commit 210e3bb552
2 changed files with 16 additions and 5 deletions

View File

@ -6,6 +6,7 @@ import { AnnotationDialogComponent } from './annotation-dialog.component';
import { AutoCompleteModule } from '@app/library/auto-complete/auto-complete.module';
import { TextAreaWithMentionsComponent } from '../components/text-area-with-mentions.component';
import { NgxMentionsModule } from 'ngx-mentions';
import { OverlayModule } from '@angular/cdk/overlay';
@NgModule({
imports: [
@ -14,6 +15,7 @@ import { NgxMentionsModule } from 'ngx-mentions';
FormattingModule,
AutoCompleteModule,
NgxMentionsModule,
OverlayModule,
],
declarations: [
AnnotationDialogComponent,

View File

@ -26,10 +26,19 @@
</mat-form-field>
<ng-template #menuTemplate
let-selectChoice="selectChoice">
<ngx-text-input-autocomplete-menu *ngIf="choices" [choices]="choices"
[getDisplayLabel]="getDisplayLabel"
(selectChoice)="selectChoice($event)">
</ngx-text-input-autocomplete-menu>
let-selectChoice="selectChoice"
>
<div cdkOverlayOrigin #trigger="cdkOverlayOrigin">
<ng-template
cdkConnectedOverlay
[cdkConnectedOverlayOrigin]="trigger"
cdkConnectedOverlayOpen="true"
>
<ngx-text-input-autocomplete-menu *ngIf="choices" [choices]="choices"
[getDisplayLabel]="getDisplayLabel"
(selectChoice)="selectChoice($event)">
</ngx-text-input-autocomplete-menu>
</ng-template>
</div>
</ng-template>
</div>