1
0
Fork 0

Refactor video edition

This commit is contained in:
Chocobozzz 2021-12-29 10:20:33 +01:00
parent 3c065fe3b3
commit 087fc5dade
No known key found for this signature in database
GPG key ID: 583A612D890159BE

View file

@ -1,6 +1,12 @@
<div class="video-edit" [formGroup]="form"> <div class="video-edit" [formGroup]="form">
<div ngbNav #nav="ngbNav" class="nav-tabs"> <div ngbNav #nav="ngbNav" class="nav-tabs">
<ng-template #pluginSettingTemplate let-pluginSetting>
<div class="form-group" [hidden]="isPluginFieldHidden(pluginSetting)">
<my-dynamic-form-field [form]="pluginDataFormGroup" [formErrors]="formErrors['pluginData']" [setting]="pluginSetting.commonOptions"></my-dynamic-form-field>
</div>
</ng-template>
<ng-container ngbNavItem> <ng-container ngbNavItem>
<a ngbNavLink i18n>Basic info</a> <a ngbNavLink i18n>Basic info</a>
@ -146,12 +152,10 @@
</ng-template> </ng-template>
</my-peertube-checkbox> </my-peertube-checkbox>
<ng-container ngbNavItem *ngIf="getPluginsFields('main').length !== 0"> <ng-container
*ngFor="let pluginSetting of getPluginsFields('main')"
<div *ngFor="let pluginSetting of getPluginsFields('main')" class="form-group" [hidden]="isPluginFieldHidden(pluginSetting)"> [ngTemplateOutlet]="pluginSettingTemplate" [ngTemplateOutletContext]="{ $implicit: pluginSetting }"
<my-dynamic-form-field [form]="pluginDataFormGroup" [formErrors]="formErrors['pluginData']" [setting]="pluginSetting.commonOptions"></my-dynamic-form-field> >
</div>
</ng-container> </ng-container>
</div> </div>
</div> </div>
@ -353,9 +357,11 @@
<div class="row plugin-settings"> <div class="row plugin-settings">
<div class="col-md-12 col-xl-8"> <div class="col-md-12 col-xl-8">
<div *ngFor="let pluginSetting of getPluginsFields('plugin-settings')" class="form-group" [hidden]="isPluginFieldHidden(pluginSetting)"> <ng-container
<my-dynamic-form-field [form]="pluginDataFormGroup" [formErrors]="formErrors['pluginData']" [setting]="pluginSetting.commonOptions"></my-dynamic-form-field> *ngFor="let pluginSetting of getPluginsFields('plugin-settings')"
</div> [ngTemplateOutlet]="pluginSettingTemplate" [ngTemplateOutletContext]="{ $implicit: pluginSetting }"
>
</ng-container>
</div> </div>
</div> </div>