diff options
Diffstat (limited to 'client/src/app/shared/shared-forms')
-rw-r--r-- | client/src/app/shared/shared-forms/dynamic-form-field.component.html | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/client/src/app/shared/shared-forms/dynamic-form-field.component.html b/client/src/app/shared/shared-forms/dynamic-form-field.component.html index c358cb119..8e9ef5355 100644 --- a/client/src/app/shared/shared-forms/dynamic-form-field.component.html +++ b/client/src/app/shared/shared-forms/dynamic-form-field.component.html | |||
@@ -1,10 +1,16 @@ | |||
1 | <div [formGroup]="form"> | 1 | <div [formGroup]="form"> |
2 | <label *ngIf="setting.type !== 'input-checkbox'" [attr.for]="setting.name" [innerHTML]="setting.label"></label> | 2 | <label *ngIf="setting.label" [attr.for]="setting.name" [innerHTML]="setting.label"></label> |
3 | 3 | ||
4 | <div *ngIf="setting.descriptionHTML" class="label-small-info" [innerHTML]="setting.descriptionHTML"></div> | 4 | <div *ngIf="setting.descriptionHTML" class="label-small-info" [innerHTML]="setting.descriptionHTML"></div> |
5 | 5 | ||
6 | <input *ngIf="setting.type === 'input'" type="text" [id]="setting.name" [formControlName]="setting.name" /> | 6 | <input *ngIf="setting.type === 'input'" type="text" [id]="setting.name" [formControlName]="setting.name" /> |
7 | 7 | ||
8 | <div *ngIf="setting.type === 'select'" class="peertube-select-container"> | ||
9 | <select [id]="setting.name" [formControlName]="setting.name" class="form-control"> | ||
10 | <option *ngFor="let option of setting.options" [value]="option.value">{{ option.label }}</option> | ||
11 | </select> | ||
12 | </div> | ||
13 | |||
8 | <my-input-toggle-hidden *ngIf="setting.type === 'input-password'" [formControlName]="setting.name" [inputId]="setting.name"></my-input-toggle-hidden> | 14 | <my-input-toggle-hidden *ngIf="setting.type === 'input-password'" [formControlName]="setting.name" [inputId]="setting.name"></my-input-toggle-hidden> |
9 | 15 | ||
10 | <textarea *ngIf="setting.type === 'input-textarea'" type="text" [id]="setting.name" [formControlName]="setting.name"></textarea> | 16 | <textarea *ngIf="setting.type === 'input-textarea'" type="text" [id]="setting.name" [formControlName]="setting.name"></textarea> |
@@ -32,6 +38,8 @@ | |||
32 | [labelInnerHTML]="setting.label" | 38 | [labelInnerHTML]="setting.label" |
33 | ></my-peertube-checkbox> | 39 | ></my-peertube-checkbox> |
34 | 40 | ||
41 | <div *ngIf="setting.type === 'html'" [innerHTML]="setting.html"></div> | ||
42 | |||
35 | <div *ngIf="formErrors[setting.name]" class="form-error"> | 43 | <div *ngIf="formErrors[setting.name]" class="form-error"> |
36 | {{ formErrors[setting.name] }} | 44 | {{ formErrors[setting.name] }} |
37 | </div> | 45 | </div> |