1234567891011121314151617181920212223242526272829303132333435363738 |
- import React from 'react';
- import {QueueRow} from './QueueRow';
- import {TableRows} from "./TableRows";
- import {Empty, Queried, Unqueried, UnqueriedNoURL} from './QueueRow.stories';
- // More on default export: https://storybook.js.org/docs/react/writing-stories/introduction#default-export
- export default {
- component: TableRows,
- title: 'Example/TableRows',
- // More on argTypes: https://storybook.js.org/docs/react/api/argtypes
- argTypes: {
- backgroundColor: {control: 'color'},
- },
- };
- // More on component templates: https://storybook.js.org/docs/react/writing-stories/introduction#using-args
- const Template = (args) => <TableRows {...args} />;
- var allRows = {
- Empty,
- Unqueried,
- UnqueriedNoURL,
- Queried,
- };
- export var rows = Object.keys(allRows).map((rowKey, index) => {
- const rowArgs = allRows[rowKey].args
- return <QueueRow key={index}
- arn={rowArgs.arn}
- itemCount={rowArgs.itemCount}
- qName={rowArgs.qName}
- url={rowArgs.url}
- >{index}</QueueRow>
- });
- export const AllRowsKinds = Template.bind({});
- AllRowsKinds.args = {rows};
|