diff --git a/projects/common/element-components/dropdown.component.ts b/projects/common/element-components/dropdown.component.ts index 2ecf91a14d6fe2f05f65c251302c693f92359bc6..4754e776853f60661cef78055938b68480fe6443 100644 --- a/projects/common/element-components/dropdown.component.ts +++ b/projects/common/element-components/dropdown.component.ts @@ -20,7 +20,7 @@ import { DropdownElement } from '../classes/dropdownElement'; <mat-select (focusin)="onFocusin.emit()" [formControl]="elementFormControl"> <mat-option *ngIf="elementModel.allowUnset" value=""></mat-option> - <mat-option *ngFor="let option of elementModel.options" [value]="option"> + <mat-option *ngFor="let option of elementModel.options; let i = index" [value]="i"> {{option}} </mat-option> </mat-select> diff --git a/projects/common/element-components/radio-button-group.component.ts b/projects/common/element-components/radio-button-group.component.ts index a1575ccc5186cf9863cfda6112eadff2389bb226..b1bb428692d3abcf03aa02c7212f44098a3a984f 100644 --- a/projects/common/element-components/radio-button-group.component.ts +++ b/projects/common/element-components/radio-button-group.component.ts @@ -23,8 +23,7 @@ import { RadioButtonGroupElement } from '../classes/radioButtonGroupElement'; [style.margin-bottom.px]="25" [fxLayout]="elementModel.alignment" [formControl]="elementFormControl"> - <mat-radio-button *ngFor="let option of elementModel.options" - [value]="option"> + <mat-radio-button *ngFor="let option of elementModel.options; let i = index" [value]="i"> {{option}} </mat-radio-button> <mat-error *ngIf="elementFormControl.errors && elementFormControl.touched" diff --git a/projects/editor/src/app/components/unit-view/page-view/properties/element-properties.component.html b/projects/editor/src/app/components/unit-view/page-view/properties/element-properties.component.html index 5bfa5e3ad5d0023757ff16840b7e0327a3ea54e6..ad721af34f28afa0f2347a504fc8793f63904b37 100644 --- a/projects/editor/src/app/components/unit-view/page-view/properties/element-properties.component.html +++ b/projects/editor/src/app/components/unit-view/page-view/properties/element-properties.component.html @@ -127,7 +127,7 @@ <mat-select [value]="combinedProperties.value" (selectionChange)="updateModel('value', $event.value)"> <mat-option>undefiniert</mat-option> - <mat-option *ngFor="let option of $any(combinedProperties).options" [value]="option"> + <mat-option *ngFor="let option of $any(combinedProperties).options; let i = index" [value]="i"> {{option}} </mat-option> </mat-select>