diff --git a/front/packages/ui/src/components/media-info.tsx b/front/packages/ui/src/components/media-info.tsx index 63716846..9b532912 100644 --- a/front/packages/ui/src/components/media-info.tsx +++ b/front/packages/ui/src/components/media-info.tsx @@ -39,14 +39,16 @@ const MediaInfoTable = ({ if (trackTable.length == 0) { return undefined; } + const singleTrack = trackTable.length == 1 return trackTable.reduce( (collected, audioTrack, index) => ({ ...collected, // If there is only one track, we do not need to show an index - [trackTable.length == 1 ? t(s) : `${t(s)} ${index + 1}`]: [ + [singleTrack ? t(s) : `${t(s)} ${index + 1}`]: [ audioTrack.displayName, - audioTrack.isDefault ? t("Default") : undefined, - audioTrack.isForced ? t("Forced") : undefined, + // Only show it if there is more than one track + (audioTrack.isDefault && !singleTrack) ? t("mediainfo.default") : undefined, + audioTrack.isForced ? t("mediainfo.forced") : undefined, audioTrack.codec, ] .filter((x) => x !== undefined) diff --git a/front/translations/en.json b/front/translations/en.json index 896bd152..846b8253 100644 --- a/front/translations/en.json +++ b/front/translations/en.json @@ -181,6 +181,8 @@ "container": "Container", "video": "Video", "audio": "Audio", - "subtitles": "Subtitles" + "subtitles": "Subtitles", + "forced": "Forced", + "default": "Default" } } diff --git a/front/translations/fr.json b/front/translations/fr.json index 6cd98e04..35e4ef80 100644 --- a/front/translations/fr.json +++ b/front/translations/fr.json @@ -181,6 +181,8 @@ "container": "Conteneur", "video": "Video", "audio": "Audio", - "subtitles": "Sous titres" + "subtitles": "Sous titres", + "forced": "Forcé", + "default": "Par Défaut" } }