mirror of
https://github.com/p-stream/p-stream.git
synced 2026-05-13 12:30:57 +00:00
hide auto subtitle option if there are no subs
This commit is contained in:
parent
cb504ccf55
commit
afebab301f
1 changed files with 17 additions and 15 deletions
|
|
@ -533,21 +533,23 @@ export function CaptionsView({
|
||||||
{t("player.menus.subtitles.offChoice")}
|
{t("player.menus.subtitles.offChoice")}
|
||||||
</CaptionOption>
|
</CaptionOption>
|
||||||
|
|
||||||
{/* Enable subtitles option */}
|
{/* Automatically select subtitles option */}
|
||||||
<CaptionOption
|
{captions.length > 0 && (
|
||||||
onClick={() => handleRandomSelect()}
|
<CaptionOption
|
||||||
selected={!!selectedCaptionId}
|
onClick={() => handleRandomSelect()}
|
||||||
loading={isRandomSelecting}
|
selected={!!selectedCaptionId}
|
||||||
>
|
loading={isRandomSelecting}
|
||||||
<div className="flex flex-col">
|
>
|
||||||
{t("player.menus.subtitles.autoSelectChoice")}
|
<div className="flex flex-col">
|
||||||
{selectedCaptionId && (
|
{t("player.menus.subtitles.autoSelectChoice")}
|
||||||
<span className="text-video-context-type-secondary text-xs">
|
{selectedCaptionId && (
|
||||||
{t("player.menus.subtitles.autoSelectDifferentChoice")}
|
<span className="text-video-context-type-secondary text-xs">
|
||||||
</span>
|
{t("player.menus.subtitles.autoSelectDifferentChoice")}
|
||||||
)}
|
</span>
|
||||||
</div>
|
)}
|
||||||
</CaptionOption>
|
</div>
|
||||||
|
</CaptionOption>
|
||||||
|
)}
|
||||||
|
|
||||||
{/* Custom upload option */}
|
{/* Custom upload option */}
|
||||||
<CustomCaptionOption />
|
<CustomCaptionOption />
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue