BaseLine.tsx 562 Bytes
Newer Older
崔佳豪's avatar
崔佳豪 committed
1
import React from 'react';
2
import { LineChart } from '../index';
崔佳豪's avatar
崔佳豪 committed
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18

export default () => {
  const category = ['11-01', '11-02', '11-03', '11-04', '11-05', '11-06', '11-07'];
  const dataSource = [
    {
      name: '用水量',
      unit: 'm³',
      data: [120, 200, 150, 80, 70, 110, 130],
    },
    {
      name: '供水量',
      unit: 'm³',
      data: [1120, 1200, 1150, 1180, 1170, 1110, 1130],
    },
  ];

19 20 21 22 23
  return (
    <div style={{ height: 300 }}>
      <LineChart smooth={false} category={category} dataSource={dataSource} />
    </div>
  );
崔佳豪's avatar
崔佳豪 committed
24
};