// @flow import { lazyImport } from 'util/lazyImport'; import { LIVESTREAM_EMBED_URL } from 'constants/livestream'; import { useIsMobile } from 'effects/use-screensize'; import classnames from 'classnames'; import FileTitleSection from 'component/fileTitleSection'; import LivestreamLink from 'component/livestreamLink'; import LivestreamScheduledInfo from 'component/livestreamScheduledInfo'; import React from 'react'; const LivestreamChatLayout = lazyImport(() => import('component/livestreamChatLayout' /* webpackChunkName: "chat" */)); type Props = { activeStreamUri: boolean | string, claim: ?StreamClaim, hideComments: boolean, isCurrentClaimLive: boolean, release: any, showLivestream: boolean, showScheduledInfo: boolean, uri: string, }; export default function LivestreamLayout(props: Props) { const { activeStreamUri, claim, hideComments, isCurrentClaimLive, release, showLivestream, showScheduledInfo, uri, } = props; const isMobile = useIsMobile(); if (!claim || !claim.signing_channel) return null; const { name: channelName, claim_id: channelClaimId } = claim.signing_channel; return ( <>
{showLivestream && (