import React from 'react'; import { Chart, Axis, Tooltip, Geom } from 'bizcharts'; import autoHeight from '../autoHeight'; import styles from '../index.less'; @autoHeight() export default class MiniArea extends React.Component { render() { const { height, data = [], forceFit = true, color = 'rgba(24, 144, 255, 0.2)', borderColor = '#1089ff', scale = {}, borderWidth = 2, line, xAxis, yAxis, animate = true, } = this.props; const padding = [36, 5, 30, 5]; const scaleProps = { x: { type: 'cat', range: [0, 1], ...scale.x, }, y: { min: 0, ...scale.y, }, }; const tooltip = [ 'x*y', (x, y) => ({ name: x, value: y, }), ]; const chartHeight = height + 54; return (
{height > 0 && ( {line ? ( ) : ( )} )}
); } }