Subtitles
To apply subtitles to the video player, add a slot for tracks and insert HTML5 textTracks
. Make sure to set the label
and srclang
.
<Zorn Subtitles>
<slot slot="subtitles">
<track kind="subtitles" src="/subtitles/English.vtt" label="English" srclang="en" />
<track kind="subtitles" src="/subtitles/Russian.vtt" label="Russian" srclang="ru" />
</slot>
</Zorn>
When the Subtitles
option is enabled, a subtitles button will appear automatically in the control on the right side and a menu will be generated for you.