2021-04-23 21:59:48 +02:00
|
|
|
// @flow
|
|
|
|
import React from 'react';
|
|
|
|
import LivestreamList from 'component/livestreamList';
|
|
|
|
import Button from 'component/button';
|
|
|
|
import Page from 'component/page';
|
|
|
|
import Yrbl from 'component/yrbl';
|
|
|
|
|
|
|
|
type Props = {
|
|
|
|
user: ?User,
|
|
|
|
};
|
|
|
|
|
|
|
|
export default function LivestreamCurrentPage(props: Props) {
|
|
|
|
const { user } = props;
|
2021-08-13 05:06:12 +02:00
|
|
|
const canView = process.env.ENABLE_WIP_FEATURES || (user && user.global_mod);
|
2021-04-23 21:59:48 +02:00
|
|
|
|
|
|
|
return (
|
|
|
|
<Page>
|
|
|
|
{canView ? (
|
|
|
|
<LivestreamList />
|
|
|
|
) : (
|
|
|
|
<Yrbl
|
|
|
|
type="sad"
|
|
|
|
title={__("This page isn't quite ready")}
|
|
|
|
subtitle={__('Check back later.')}
|
|
|
|
actions={
|
|
|
|
<div className="section__actions">
|
|
|
|
<Button button="primary" navigate="/" label={__('Go Home')} />
|
|
|
|
</div>
|
|
|
|
}
|
|
|
|
/>
|
|
|
|
)}
|
|
|
|
</Page>
|
|
|
|
);
|
|
|
|
}
|