]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/commitdiff
Use server config to display supported videos ext
authorChocobozzz <me@florianbigard.com>
Tue, 27 Apr 2021 07:24:36 +0000 (09:24 +0200)
committerChocobozzz <me@florianbigard.com>
Tue, 27 Apr 2021 07:24:36 +0000 (09:24 +0200)
client/src/app/+admin/config/edit-custom-config/edit-vod-transcoding.component.html
client/src/app/+admin/config/edit-custom-config/edit-vod-transcoding.component.ts

index 1c5d6a9b4a9161fd233418e77a93576053273c6b..048f7908d1f069589edbe7d605e0bdae643c5b62 100644 (file)
@@ -51,7 +51,7 @@
                     i18n-labelText labelText="Allow additional extensions"
                   >
                     <ng-container ngProjectAs="description">
-                      <span i18n>Allows users to upload .mkv, .mov, .avi, .wmv, .flv, .f4v, .3g2, .3gp, .mts, .m2ts, .mxf, or .nut videos.</span>
+                      <span i18n>Allows users to upload {{ additionalVideoExtensions }} videos.</span>
                     </ng-container>
                   </my-peertube-checkbox>
                 </div>
index a2dc3e52a18275e92534f513ce93bf355e01841d..b017dd08cb60b45413cebd5718c2bcfabf165576 100644 (file)
@@ -20,6 +20,8 @@ export class EditVODTranscodingComponent implements OnInit, OnChanges {
   transcodingProfiles: SelectOptionsItem[] = []
   resolutions: ResolutionOption[] = []
 
+  additionalVideoExtensions = ''
+
   constructor (
     private configService: ConfigService,
     private editConfigurationService: EditConfigurationService
@@ -35,6 +37,8 @@ export class EditVODTranscodingComponent implements OnInit, OnChanges {
   ngOnChanges (changes: SimpleChanges) {
     if (changes['serverConfig']) {
       this.transcodingProfiles = this.buildAvailableTranscodingProfile()
+
+      this.additionalVideoExtensions = this.serverConfig.video.file.extensions.join(' ')
     }
   }