import React from "react"; import { TruncatedText, BusyMessage } from "component/common.js"; class ChannelTile extends React.PureComponent { componentDidMount() { const { uri, fetchClaimCount } = this.props; fetchClaimCount(uri); } componentWillReceiveProps(nextProps) { const { uri, fetchClaimCount } = this.props; if (nextProps.uri != uri) { fetchClaimCount(uri); } } render() { const { navigate, totalItems, uri } = this.props; let onClick = () => navigate("/show", { uri }); return (

{uri}

{isNaN(totalItems) && } {totalItems > 0 && This is a channel with over {totalItems} items inside of it. } {totalItems === 0 && This is an empty channel.}
); } } export default ChannelTile;