// @flow import React, { Fragment } from 'react'; import MarkdownPreview from 'component/common/markdown-preview'; type Props = { description: ?string, email: ?string, website: ?string, }; const formatEmail = (email: string) => { if (email) { const protocolRegex = new RegExp('^mailto:', 'i'); const protocol = protocolRegex.exec(email); return protocol ? email : `mailto:${email}`; } return null; }; function ChannelContent(props: Props) { const { description, email, website } = props; const showAbout = description || email || website; return (
{!showAbout &&

{__('Nothing here yet')}

} {showAbout && ( {description && (
)} {email && (
)} {website && (
)}
)}
); } export default ChannelContent;