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

26 lines
600 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-05 00:00:07 +01:00
commentsDisabled: boolean,
};
function ChannelDiscussion(props: Props) {
const { uri, linkedComment, commentsDisabled } = props;
2021-02-05 00:00:07 +01:00
if (commentsDisabled) {
return <Empty text={__('This channel has disabled comments on their page.')} />;
2021-02-04 06:45:49 +01:00
}
return (
<section className="section">
<CommentsList uri={uri} linkedComment={linkedComment} />
</section>
);
}
export default ChannelDiscussion;