2018-07-05 15:10:39 -05:00
|
|
|
import React, { PureComponent } from 'react';
|
|
|
|
import { PanelProps } from 'app/features/dashboard/dashgrid/DataPanel';
|
2018-01-02 07:52:30 -06:00
|
|
|
|
2018-10-09 10:47:43 -05:00
|
|
|
export class Text2 extends PureComponent<PanelProps> {
|
2018-01-02 07:52:30 -06:00
|
|
|
constructor(props) {
|
|
|
|
super(props);
|
|
|
|
}
|
|
|
|
|
|
|
|
render() {
|
2018-07-05 15:10:39 -05:00
|
|
|
const { data } = this.props;
|
|
|
|
let value = 0;
|
|
|
|
|
|
|
|
if (data.length) {
|
|
|
|
value = data[0].value;
|
|
|
|
}
|
|
|
|
|
2018-10-09 10:47:43 -05:00
|
|
|
return <h2>Graph Panel! {value}</h2>;
|
2018-01-02 07:52:30 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2018-10-09 10:47:43 -05:00
|
|
|
export { Text2 as PanelComponent };
|