mirror of
https://git.rwth-aachen.de/acs/public/villas/web/
synced 2025-03-09 00:00:01 +01:00
show plot legends under chart
This commit is contained in:
parent
e4470a8432
commit
aaeaef84a8
2 changed files with 5 additions and 7 deletions
|
@ -137,8 +137,6 @@ class WidgetPlotTable extends Component {
|
|||
return (
|
||||
<div className="plot-table-widget" ref="wrapper">
|
||||
<div className="content">
|
||||
<PlotLegend signals={legendSignals} />
|
||||
|
||||
<div className="table-plot-row">
|
||||
<div className="widget-table">
|
||||
{ checkBoxes.length > 0 ? (
|
||||
|
@ -150,9 +148,9 @@ class WidgetPlotTable extends Component {
|
|||
</div>
|
||||
|
||||
<div className="widget-plot">
|
||||
<Plot
|
||||
<Plot
|
||||
data={simulatorData}
|
||||
time={this.props.widget.time}
|
||||
time={this.props.widget.time}
|
||||
width={this.props.widget.width - 100}
|
||||
height={this.props.widget.height - 55}
|
||||
yMin={this.props.widget.yMin}
|
||||
|
@ -163,6 +161,7 @@ class WidgetPlotTable extends Component {
|
|||
/>
|
||||
</div>
|
||||
</div>
|
||||
<PlotLegend signals={legendSignals} />
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
|
|
@ -55,7 +55,7 @@ class WidgetPlot extends React.Component {
|
|||
if (chosenSignals.includes(signal_index)) {
|
||||
accum.push({ index: signal_index, name: model_signal.name, type: model_signal.type });
|
||||
}
|
||||
|
||||
|
||||
return accum;
|
||||
}, []);
|
||||
|
||||
|
@ -67,8 +67,6 @@ class WidgetPlot extends React.Component {
|
|||
|
||||
render() {
|
||||
return <div className="plot-widget" ref="wrapper">
|
||||
<PlotLegend signals={this.state.legend} />
|
||||
|
||||
<div className="widget-plot">
|
||||
<Plot
|
||||
data={this.state.data}
|
||||
|
@ -82,6 +80,7 @@ class WidgetPlot extends React.Component {
|
|||
yLabel={this.props.widget.ylabel}
|
||||
/>
|
||||
</div>
|
||||
<PlotLegend signals={this.state.legend} />
|
||||
</div>;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue