| | |
| | | const { card } = this.state |
| | | const plot = card.plot |
| | | const data = this.getdata() |
| | | let height = plot.height - 25 |
| | | |
| | | if (card.plot.title || card.search.length > 0) { |
| | | height = plot.height - 70 |
| | | } |
| | | |
| | | const chart = new Chart({ |
| | | container: card.uuid + 'canvas', |
| | | autoFit: true, |
| | | height: height |
| | | height: this.wrap.offsetHeight - 25 |
| | | }) |
| | | |
| | | chart.data(data); |
| | |
| | | <Icon type="tool" /> |
| | | </Popover> |
| | | {card.plot.title || card.search.length > 0 ? <NormalHeader config={card} updateComponent={this.updateComponent}/> : null} |
| | | <div className="canvas" id={card.uuid + 'canvas'}></div> |
| | | <div className="canvas" id={card.uuid + 'canvas'} ref={ref => this.wrap = ref}></div> |
| | | {appType !== 'mob' ? <ActionComponent type="chart" config={card} updateaction={this.updateComponent}/> : null} |
| | | </div> |
| | | ) |