show text when no caption language is selected

This commit is contained in:
frost768 2023-04-10 22:10:11 +03:00
parent b9b0380dfe
commit 546b008b2e
2 changed files with 7 additions and 9 deletions

View File

@ -217,7 +217,7 @@ export const captionLanguages: CaptionLanguageOption[] = [
id: "none", id: "none",
englishName: "None", englishName: "None",
name: "None", name: "None",
nativeName: "None", nativeName: "No caption language selected",
}, },
{ {
id: "aa", id: "aa",

View File

@ -130,14 +130,12 @@ export default function SettingsModal(props: {
</div> </div>
<div className="flex w-full flex-col justify-center"> <div className="flex w-full flex-col justify-center">
<div className="flex aspect-video flex-col justify-end rounded bg-zinc-800"> <div className="flex aspect-video flex-col justify-end rounded bg-zinc-800">
{selectedCaptionLanguage.id !== "none" ? ( <div className="pointer-events-none flex w-full flex-col items-center transition-[bottom]">
<div className="pointer-events-none flex w-full flex-col items-center transition-[bottom]"> <CaptionCue
<CaptionCue scale={0.5}
scale={0.5} text={selectedCaptionLanguage.nativeName}
text={selectedCaptionLanguage.nativeName} />
/> </div>
</div>
) : null}
</div> </div>
</div> </div>
</div> </div>