import * as React from 'react'; import classNames from 'classnames'; interface IProps { children?: React.ReactNode; title?: string; marginTop?: boolean; } export class ListHeader extends React.PureComponent { render() { const classes = classNames( 'sd-list-header', {'sd-list-header--m-top': this.props.marginTop}, ); return (
{!this.props.title ? null : ( {this.props.title} )} {this.props.children}
); } }