<app-common-dialog [dialogContent]="dialogContent" [dialogRef]="dialogRef">
  <ng-template #dialogContent>
    <p *ngIf="data && data.configuration" i18n>Current configuration: {{data.configuration.name}}</p>
    <div *ngIf="availableConfigurations && !availableConfigurations.length" i18n>
      No other configurations available.
    </div>
    <div *ngIf="availableConfigurations && availableConfigurations.length" [formGroup]="changeConfigurationFrom">
      <mat-form-field appFlex="90">
        <mat-label i18n>New configuration</mat-label>
        <mat-select formControlName="selectedConfiguration" placeholder="New configuration" i18n-placeholder>
          <mat-option *ngFor="let configuration of availableConfigurations" [value]="configuration.id">
            {{configuration.name}}
          </mat-option>
        </mat-select>
      </mat-form-field>
    </div>
  </ng-template>
</app-common-dialog>
