mirror of https://github.com/grafana/grafana
parent
40d7ba1e6a
commit
eca3824e2d
@ -1,9 +1,22 @@ |
|||||||
|
import React from 'react'; |
||||||
|
|
||||||
import { storiesOf } from '@storybook/react'; |
import { storiesOf } from '@storybook/react'; |
||||||
import TableInputCSV from './TableInputCSV'; |
import TableInputCSV, { ParseResults } from './TableInputCSV'; |
||||||
import { withFullSizeStory } from '../../utils/storybook/withFullSizeStory'; |
//import { withFullSizeStory } from '../../utils/storybook/withFullSizeStory';
|
||||||
|
|
||||||
const TableInputStories = storiesOf('UI/Table/Input', module); |
const TableInputStories = storiesOf('UI/Table/Input', module); |
||||||
|
|
||||||
TableInputStories.add('default', () => { |
TableInputStories.add('default', () => { |
||||||
return withFullSizeStory(TableInputCSV, {}); |
//return withFullSizeStory(TableInputCSV, {});
|
||||||
|
return ( |
||||||
|
<div> |
||||||
|
<TableInputCSV |
||||||
|
width={'90%'} |
||||||
|
height={'90vh'} |
||||||
|
onTableParsed={(results: ParseResults) => { |
||||||
|
console.log('GOT', results); |
||||||
|
}} |
||||||
|
/> |
||||||
|
</div> |
||||||
|
); |
||||||
}); |
}); |
||||||
|
|||||||
@ -1,17 +1,18 @@ |
|||||||
.gf-table-input-wrap { |
.gf-table-input-csv { |
||||||
width: 100%; |
position: relative; |
||||||
} |
} |
||||||
|
|
||||||
.gf-table-input-wrap textarea { |
.gf-table-input-csv textarea { |
||||||
height: 100%; |
height: 100%; |
||||||
width: 100%; |
width: 100%; |
||||||
resize: none; |
resize: none; |
||||||
} |
} |
||||||
|
|
||||||
.gf-table-input-wrap footer { |
.gf-table-input-csv footer { |
||||||
position: absolute; |
position: absolute; |
||||||
bottom: 20px; |
bottom: 20px; |
||||||
right: 20px; |
right: 20px; |
||||||
border: 2px solid #222; |
border: 1px solid #222; |
||||||
background: #ccc; |
background: #ccc; |
||||||
|
padding: 4px 10px; |
||||||
} |
} |
||||||
|
|||||||
Loading…
Reference in new issue