From: Chocobozzz Date: Wed, 24 May 2023 15:35:39 +0000 (+0200) Subject: Better label for default transcoding profile X-Git-Tag: v5.2.0-rc.1~35 X-Git-Url: https://git.immae.eu/?a=commitdiff_plain;h=b99ee1b150257e0d54bde4b928dd9dc76b97ef7b;p=github%2FChocobozzz%2FPeerTube.git Better label for default transcoding profile --- diff --git a/client/src/app/+admin/config/edit-custom-config/edit-live-configuration.component.ts b/client/src/app/+admin/config/edit-custom-config/edit-live-configuration.component.ts index 50b882cb8..1d1fecf90 100644 --- a/client/src/app/+admin/config/edit-custom-config/edit-live-configuration.component.ts +++ b/client/src/app/+admin/config/edit-custom-config/edit-live-configuration.component.ts @@ -51,11 +51,11 @@ export class EditLiveConfigurationComponent implements OnInit, OnChanges { const profiles = this.serverConfig.live.transcoding.availableProfiles return profiles.map(p => { - const description = p === 'default' - ? $localize`x264, targeting maximum device compatibility` - : '' + if (p === 'default') { + return { id: p, label: $localize`Default`, description: $localize`x264, targeting maximum device compatibility` } + } - return { id: p, label: p, description } + return { id: p, label: p } }) } diff --git a/client/src/app/+admin/config/edit-custom-config/edit-vod-transcoding.component.ts b/client/src/app/+admin/config/edit-custom-config/edit-vod-transcoding.component.ts index 0a1ebe8e2..c5f4ecddb 100644 --- a/client/src/app/+admin/config/edit-custom-config/edit-vod-transcoding.component.ts +++ b/client/src/app/+admin/config/edit-custom-config/edit-vod-transcoding.component.ts @@ -46,11 +46,11 @@ export class EditVODTranscodingComponent implements OnInit, OnChanges { const profiles = this.serverConfig.transcoding.availableProfiles return profiles.map(p => { - const description = p === 'default' - ? $localize`x264, targeting maximum device compatibility` - : '' + if (p === 'default') { + return { id: p, label: $localize`Default`, description: $localize`x264, targeting maximum device compatibility` } + } - return { id: p, label: p, description } + return { id: p, label: p } }) }