style: hide save as image button when not chart

This commit is contained in:
ysandler 2020-08-08 00:26:22 -05:00 committed by Joshua Shoemaker
parent a8633bdc70
commit 95fecf31c9

View File

@ -52,7 +52,7 @@ class ChartViewer extends Component {
return (
<div className='ChartViewer'>
{this.renderChart()}
<Button onClick={this.saveChart}>Save As Image</Button>
{ this.state.chart ? <Button onClick={this.saveChart}>Save As Image</Button> : '' }
</div>
)
}