diff options
Diffstat (limited to 'client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html')
-rw-r--r-- | client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html | 58 |
1 files changed, 37 insertions, 21 deletions
diff --git a/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html b/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html index e0361fbfd..09539fa92 100644 --- a/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html +++ b/client/src/app/+admin/config/edit-custom-config/edit-custom-config.component.html | |||
@@ -362,10 +362,13 @@ | |||
362 | 362 | ||
363 | <div [ngClass]="{ 'disabled-checkbox-extra': !isSignupEnabled() }" class="mt-3"> | 363 | <div [ngClass]="{ 'disabled-checkbox-extra': !isSignupEnabled() }" class="mt-3"> |
364 | <label i18n for="signupLimit">Signup limit</label> | 364 | <label i18n for="signupLimit">Signup limit</label> |
365 | <input | 365 | <div class="number-with-unit"> |
366 | type="number" min="-1" id="signupLimit" class="form-control" | 366 | <input |
367 | formControlName="limit" [ngClass]="{ 'input-error': formErrors['signup.limit'] }" | 367 | type="number" min="-1" id="signupLimit" class="form-control" |
368 | > | 368 | formControlName="limit" [ngClass]="{ 'input-error': formErrors['signup.limit'] }" |
369 | > | ||
370 | <span i18n>{form.value['signup']['limit'], plural, =1 {user} other {users}}</span> | ||
371 | </div> | ||
369 | <div *ngIf="formErrors.signup.limit" class="form-error">{{ formErrors.signup.limit }}</div> | 372 | <div *ngIf="formErrors.signup.limit" class="form-error">{{ formErrors.signup.limit }}</div> |
370 | <small *ngIf="form.value['signup']['limit'] === -1" class="text-muted">Signup won't be limited to a fixed number of users.</small> | 373 | <small *ngIf="form.value['signup']['limit'] === -1" class="text-muted">Signup won't be limited to a fixed number of users.</small> |
371 | </div> | 374 | </div> |
@@ -743,22 +746,29 @@ | |||
743 | 746 | ||
744 | <div class="form-group" [ngClass]="{ 'disabled-checkbox-extra': !isLiveEnabled() }"> | 747 | <div class="form-group" [ngClass]="{ 'disabled-checkbox-extra': !isLiveEnabled() }"> |
745 | <label i18n for="liveMaxInstanceLives">Max lives created on your instance (-1 for "unlimited")</label> | 748 | <label i18n for="liveMaxInstanceLives">Max lives created on your instance (-1 for "unlimited")</label> |
746 | <input type="number" name="liveMaxInstanceLives" formControlName="maxInstanceLives" /> | 749 | <div class="number-with-unit"> |
750 | <input type="number" name="liveMaxInstanceLives" formControlName="maxInstanceLives" /> | ||
751 | <span i18n>{form.value['live']['maxInstanceLives'], plural, =1 {live} other {lives}}</span> | ||
752 | </div> | ||
747 | </div> | 753 | </div> |
748 | 754 | ||
749 | <div class="form-group" [ngClass]="{ 'disabled-checkbox-extra': !isLiveEnabled() }"> | 755 | <div class="form-group" [ngClass]="{ 'disabled-checkbox-extra': !isLiveEnabled() }"> |
750 | <label i18n for="liveMaxUserLives">Max lives created per user (-1 for "unlimited")</label> | 756 | <label i18n for="liveMaxUserLives">Max lives created per user (-1 for "unlimited")</label> |
751 | <input type="number" name="liveMaxUserLives" formControlName="maxUserLives" /> | 757 | <div class="number-with-unit"> |
758 | <input type="number" name="liveMaxUserLives" formControlName="maxUserLives" /> | ||
759 | <span i18n>{form.value['live']['maxUserLives'], plural, =1 {live} other {lives}}</span> | ||
760 | </div> | ||
752 | </div> | 761 | </div> |
753 | 762 | ||
754 | <div class="form-group" [ngClass]="{ 'disabled-checkbox-extra': !isLiveEnabled() }"> | 763 | <div class="form-group" [ngClass]="{ 'disabled-checkbox-extra': !isLiveEnabled() }"> |
755 | <label i18n for="liveMaxDuration">Max live duration</label> | 764 | <label i18n for="liveMaxDuration">Max live duration</label> |
756 | <div class="peertube-select-container"> | 765 | <div class="peertube-select-container"> |
757 | <select id="liveMaxDuration" formControlName="maxDuration" class="form-control"> | 766 | <ng-select |
758 | <option *ngFor="let liveMaxDurationOption of liveMaxDurationOptions" [value]="liveMaxDurationOption.value"> | 767 | labelForId="liveMaxDuration" [items]="liveMaxDurationOptions" formControlName="maxDuration" |
759 | {{ liveMaxDurationOption.label }} | 768 | bindLabel="label" bindValue="value" |
760 | </option> | 769 | [clearable]="false" |
761 | </select> | 770 | [searchable]="false" |
771 | ></ng-select> | ||
762 | </div> | 772 | </div> |
763 | </div> | 773 | </div> |
764 | 774 | ||
@@ -780,7 +790,7 @@ | |||
780 | <div class="peertube-select-container"> | 790 | <div class="peertube-select-container"> |
781 | <select id="liveTranscodingThreads" formControlName="threads" class="form-control"> | 791 | <select id="liveTranscodingThreads" formControlName="threads" class="form-control"> |
782 | <option *ngFor="let transcodingThreadOption of transcodingThreadOptions" [value]="transcodingThreadOption.value"> | 792 | <option *ngFor="let transcodingThreadOption of transcodingThreadOptions" [value]="transcodingThreadOption.value"> |
783 | {{ transcodingThreadOption.label }} | 793 | {{ transcodingThreadOption.label }} {transcodingThreadOption.value, plural, =0 {} =1 {thread} other {threads}} |
784 | </option> | 794 | </option> |
785 | </select> | 795 | </select> |
786 | </div> | 796 | </div> |
@@ -922,7 +932,7 @@ | |||
922 | <div class="peertube-select-container"> | 932 | <div class="peertube-select-container"> |
923 | <select id="transcodingThreads" formControlName="threads" class="form-control"> | 933 | <select id="transcodingThreads" formControlName="threads" class="form-control"> |
924 | <option *ngFor="let transcodingThreadOption of transcodingThreadOptions" [value]="transcodingThreadOption.value"> | 934 | <option *ngFor="let transcodingThreadOption of transcodingThreadOptions" [value]="transcodingThreadOption.value"> |
925 | {{ transcodingThreadOption.label }} | 935 | {{ transcodingThreadOption.label }} {transcodingThreadOption.value, plural, =0 {} =1 {thread} other {threads}} |
926 | </option> | 936 | </option> |
927 | </select> | 937 | </select> |
928 | </div> | 938 | </div> |
@@ -968,19 +978,25 @@ | |||
968 | <ng-container formGroupName="cache"> | 978 | <ng-container formGroupName="cache"> |
969 | <div class="form-group" formGroupName="previews"> | 979 | <div class="form-group" formGroupName="previews"> |
970 | <label i18n for="cachePreviewsSize">Number of previews to keep in cache</label> | 980 | <label i18n for="cachePreviewsSize">Number of previews to keep in cache</label> |
971 | <input | 981 | <div class="number-with-unit"> |
972 | type="number" min="0" id="cachePreviewsSize" class="form-control" | 982 | <input |
973 | formControlName="size" [ngClass]="{ 'input-error': formErrors['cache.previews.size'] }" | 983 | type="number" min="0" id="cachePreviewsSize" class="form-control" |
974 | > | 984 | formControlName="size" [ngClass]="{ 'input-error': formErrors['cache.previews.size'] }" |
985 | > | ||
986 | <span i18n>{form.value['cache']['previews']['size'], plural, =1 {cached image} other {cached images}}</span> | ||
987 | </div> | ||
975 | <div *ngIf="formErrors.cache.previews.size" class="form-error">{{ formErrors.cache.previews.size }}</div> | 988 | <div *ngIf="formErrors.cache.previews.size" class="form-error">{{ formErrors.cache.previews.size }}</div> |
976 | </div> | 989 | </div> |
977 | 990 | ||
978 | <div class="form-group" formGroupName="captions"> | 991 | <div class="form-group" formGroupName="captions"> |
979 | <label i18n for="cacheCaptionsSize">Number of video captions to keep in cache</label> | 992 | <label i18n for="cacheCaptionsSize">Number of video captions to keep in cache</label> |
980 | <input | 993 | <div class="number-with-unit"> |
981 | type="number" min="0" id="cacheCaptionsSize" class="form-control" | 994 | <input |
982 | formControlName="size" [ngClass]="{ 'input-error': formErrors['cache.captions.size'] }" | 995 | type="number" min="0" id="cacheCaptionsSize" class="form-control" |
983 | > | 996 | formControlName="size" [ngClass]="{ 'input-error': formErrors['cache.captions.size'] }" |
997 | > | ||
998 | <span i18n>{form.value['cache']['captions']['size'], plural, =1 {cached image} other {cached images}}</span> | ||
999 | </div> | ||
984 | <div *ngIf="formErrors.cache.captions.size" class="form-error">{{ formErrors.cache.captions.size }}</div> | 1000 | <div *ngIf="formErrors.cache.captions.size" class="form-error">{{ formErrors.cache.captions.size }}</div> |
985 | </div> | 1001 | </div> |
986 | </ng-container> | 1002 | </ng-container> |