Commit 6e11c686 authored by Florent POITTEVIN's avatar Florent POITTEVIN
Browse files

fix: 1809 allow to have space in keyword

(cherry picked from commit ed4c3a1c)
parent 90db43d9
......@@ -63,6 +63,7 @@
[formControl]="fd"
[placeholderToTranslate]="labelTranslateEnum.emailSuffixes | translate"
[readonly]="readonly"
[spaceDelimiter]="false"
>
</dlcm-shared-keyword-input>
......
......@@ -252,6 +252,7 @@
<dlcm-shared-keyword-input *ngIf="getFormControl(formDefinition.keywords) as fd"
[formControl]="fd"
[spaceDelimiter]="false"
>
</dlcm-shared-keyword-input>
......
......@@ -425,6 +425,7 @@
<dlcm-shared-keyword-input *ngIf="getFormControl(formDefinition.keywords) as fd"
[formControl]="fd"
[readonly]="readonly"
[spaceDelimiter]="false"
>
</dlcm-shared-keyword-input>
......
......@@ -114,6 +114,7 @@
<dlcm-shared-keyword-input *ngIf="getFormControl(formDefinition.keywords) as fd"
[formControl]="fd"
[readonly]="readonly"
[spaceDelimiter]="false"
>
</dlcm-shared-keyword-input>
......
......@@ -65,6 +65,18 @@ export class SharedKeywordInputPresentational extends SharedAbstractPresentation
@Input()
formControl: FormControl;
_spaceDelimiter: boolean = true;
@Input()
set spaceDelimiter(value: boolean) {
this._spaceDelimiter = value;
if (!this._spaceDelimiter) {
//in case of true, delete the space delimiter from the list
const index = this.separatorKeysCodes.indexOf(SPACE);
this.separatorKeysCodes.splice(index, 1);
}
}
@Input()
appearance: MatFormFieldAppearance = this.appearanceInputMaterial;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment