@eureca/eureca-ui
Version:
UI component library of Eureca's user and admin apps
62 lines (56 loc) • 1.14 kB
JavaScript
import React from 'react';
import { withKnobs } from '@storybook/addon-knobs';
import { CronogramTable } from '..';
import { Box } from '@material-ui/core';
const tableData = [
{
description: 'Início das inscrições',
deadline: new Date(21, 4, 25),
phase: 'Online',
show: true,
id: 1,
},
{
description: 'Presencial em SP',
deadline: new Date(22, 0, 25),
phase: 'Presencial',
show: true,
id: 2,
},
{
description: 'Início do estágio',
deadline: new Date(22, 1, 14),
phase: 'Geral',
show: true,
id: 3,
},
];
const phaseOptions = [
{
id: 1,
label: 'Online',
value: 'Online',
},
{
id: 2,
label: 'Presencial',
value: 'Presencial',
},
{
id: 3,
label: 'Geral',
value: 'Geral',
},
];
export default { title: 'Originals/Cronogram Table', decorators: [withKnobs], includeStories: [] };
export function CronogramTableStory() {
return (
<Box p={3}>
<CronogramTable
initialData={tableData}
phaseOptions={phaseOptions}
onChange={data => console.log('Data: ', data)}
/>
</Box>
);
}