lbry-desktop/ui/component/channelDiscussion/view.jsx

26 lines
577 B
React
Raw Normal View History

// @flow
import React from 'react';
import CommentsList from 'component/commentsList';
2021-02-04 06:45:49 +01:00
import Empty from 'component/common/empty';
type Props = {
uri: string,
linkedComment: ?any,
2021-02-04 06:45:49 +01:00
tags: Array<string>,
};
function ChannelDiscussion(props: Props) {
2021-02-04 06:45:49 +01:00
const { uri, linkedComment, tags } = props;
2021-02-04 06:45:49 +01:00
if (tags.includes('disable_comments')) {
return <Empty text={__('Comments are disabled here.')} />;
}
return (
<section className="section">
<CommentsList uri={uri} linkedComment={linkedComment} />
</section>
);
}
export default ChannelDiscussion;