diff --git a/ui/component/viewers/videoViewer/internal/videojs.jsx b/ui/component/viewers/videoViewer/internal/videojs.jsx index 037eadeb8..122601171 100644 --- a/ui/component/viewers/videoViewer/internal/videojs.jsx +++ b/ui/component/viewers/videoViewer/internal/videojs.jsx @@ -56,6 +56,8 @@ type Props = { autoplay: boolean, autoplaySetting: boolean, claimId: ?string, + title: ?string, + channelName: ?string, embedded: boolean, internalFeatureEnabled: ?boolean, isAudio: boolean, @@ -123,6 +125,8 @@ export default React.memo(function VideoJs(props: Props) { autoplay, autoplaySetting, claimId, + title, + channelName, embedded, internalFeatureEnabled, // for people on the team to test new features internally isAudio, @@ -163,7 +167,10 @@ export default React.memo(function VideoJs(props: Props) { // the true fix here is to fix the m3u8 file, see: https://github.com/lbryio/lbry-desktop/pull/6315 controlBar: { subsCapsButton: false }, techOrder: ['chromecast', 'html5'], - chromecast: { requestTitleFn: (src) => '' }, + chromecast: { + requestTitleFn: (src) => title || '', + requestSubtitleFn: (src) => channelName || '', + }, }; const { detectFileType, createVideoPlayerDOM } = functions({ source, sourceType, videoJsOptions, isAudio }); diff --git a/ui/component/viewers/videoViewer/view.jsx b/ui/component/viewers/videoViewer/view.jsx index 1beca2ba9..e5bb2d121 100644 --- a/ui/component/viewers/videoViewer/view.jsx +++ b/ui/component/viewers/videoViewer/view.jsx @@ -112,6 +112,7 @@ function VideoViewer(props: Props) { const adApprovedChannelIds = homepageData ? getAllIds(homepageData) : []; const claimId = claim && claim.claim_id; const channelClaimId = claim && claim.signing_channel && claim.signing_channel.claim_id; + const channelName = claim && claim.signing_channel && claim.signing_channel.name; const isAudio = contentType.includes('audio'); const forcePlayer = FORCE_CONTENT_TYPE_PLAYER.includes(contentType); const { @@ -477,6 +478,8 @@ function VideoViewer(props: Props) { autoplay={!embedded || autoplayIfEmbedded} autoplaySetting={autoplayNext} claimId={claimId} + title={claim && ((claim.value && claim.value.title) || claim.name)} + channelName={channelName} userId={userId} allowPreRoll={!authenticated} // TODO: pull this into ads functionality so it's self contained internalFeatureEnabled={internalFeature}