Sha256: af75ab967607663989aef79829dac8cd59adb70e5a24e722107193c203833cbe
Contents?: true
Size: 1.18 KB
Versions: 11
Compression:
Stored size: 1.18 KB
Contents
/* @flow */ import React from "react" import {pbChart} from "../" type LineGraphProps = { axisTitle?: String, className?: String, chartData: Array<{ name: String, data: Array<Number>, }>, gradient?: Boolean, id: String, pointStart: Number, subTitle?: String, title: String, } export default class LineGraph extends React.Component<LineGraphProps> { static defaultProps = { className: 'pb_bar_graph', gradient: false, type: 'line', } componentDidMount() { const { axisTitle, className, chartData, id, pointStart, subTitle, title, type, } = this.props new pbChart(`.${className}`, { axisTitle: axisTitle, chartData: chartData, id: id, pointStart: pointStart, subtitle: subTitle, type, title: title, }) } props: LineGraphProps render() { const { className, id } = this.props return ( <div className={className} id={id} /> ) } }
Version data entries
11 entries across 11 versions & 1 rubygems