Wrap the sortable table into an info card

This commit is contained in:
Himanshu Mishra
2020-04-22 12:32:35 +09:00
parent da14cdf84e
commit c5b9feed54
@@ -17,13 +17,14 @@
import React from 'react';
import TrendLine from '.';
import SortableTable from 'components/SortableTable';
import InfoCard from 'layout/InfoCard';
export default {
title: 'TrendLine',
component: TrendLine,
};
const containerStyle = { width: 1000, padding: 20 };
const containerStyle = { width: 600 };
const data = [
{
@@ -57,7 +58,7 @@ const data = [
];
const columns = [
{ id: 'stock', label: 'Stock name' },
{ id: 'stock', label: 'Stock' },
{ id: 'day', label: 'Day' },
{ id: 'week', label: 'Week' },
{ id: 'month', label: 'Month' },
@@ -65,9 +66,9 @@ const columns = [
];
export const Default = () => (
<div style={containerStyle}>
<InfoCard style={containerStyle} title="Trends over time">
<SortableTable data={data} columns={columns} />
</div>
</InfoCard>
);
export const TrendingMix = () => (