hideHeader

Summary: The `hideHeader` didn't hide the header. Fixed it!

Reviewed By: priteshrnandgaonkar

Differential Revision: D13377067

fbshipit-source-id: 105541169d46b6db1a85e99c8d93ee52f904d261
This commit is contained in:
Daniel Büchele
2018-12-14 10:09:50 -08:00
committed by Facebook Github Bot
parent 0143052f98
commit 29f6e2ed4f

View File

@@ -519,11 +519,12 @@ class ManagedTable extends React.Component<
}; };
render() { render() {
const {columns, rows, rowLineHeight} = this.props; const {columns, rows, rowLineHeight, hideHeader} = this.props;
const {columnOrder, columnSizes} = this.state; const {columnOrder, columnSizes} = this.state;
return ( return (
<Container> <Container>
{hideHeader !== true && (
<TableHead <TableHead
columnOrder={columnOrder} columnOrder={columnOrder}
onColumnOrder={this.onColumnOrder} onColumnOrder={this.onColumnOrder}
@@ -533,6 +534,7 @@ class ManagedTable extends React.Component<
columnSizes={columnSizes} columnSizes={columnSizes}
onSort={this.onSort} onSort={this.onSort}
/> />
)}
<Container> <Container>
{this.props.autoHeight ? ( {this.props.autoHeight ? (
this.props.rows.map((_, index) => this.getRow({index, style: {}})) this.props.rows.map((_, index) => this.getRow({index, style: {}}))