<ng-container *ngFor="let field of assessment.form?.fields; let n = index">
    <ion-card *ngIf="n < assessment.form?.dimenssionscount">
        <ion-item class="ion-text-wrap">
            <ion-label>
                <h2>{{ field.dimtitle }}</h2>
                <core-format-text [text]="field.description" contextLevel="module" [contextInstanceId]="moduleId"
                    [courseId]="courseId">
                </core-format-text>
            </ion-label>
        </ion-item>
        <ion-item *ngIf="edit">
            <ion-label position="stacked">
                <span [core-mark-required]="true">
                    {{ 'addon.mod_workshop_assessment_comments.dimensioncommentfor' | translate : {'$a': field.dimtitle } }}
                </span>
            </ion-label>
            <ion-textarea [(ngModel)]="selectedValues[n].peercomment" core-auto-rows></ion-textarea>
            <core-input-errors *ngIf="fieldErrors['peercomment_' + n]" [errorText]="fieldErrors['peercomment_' + n]">
            </core-input-errors>
        </ion-item>
        <ion-item *ngIf="!edit" class="ion-text-wrap">
            <ion-label>
                <h2>{{ 'addon.mod_workshop_assessment_comments.dimensioncommentfor' | translate : {'$a': field.dimtitle } }}</h2>
                <p><core-format-text [text]="selectedValues[n].peercomment" contextLevel="module" [contextInstanceId]="moduleId"
                    [courseId]="courseId">
                </core-format-text></p>
            </ion-label>
        </ion-item>
    </ion-card>
</ng-container>
