QueueRow.stories.jsx 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. import React from 'react';
  2. import {QueueRow} from './QueueRow';
  3. // More on default export: https://storybook.js.org/docs/react/writing-stories/introduction#default-export
  4. export default {
  5. component: QueueRow,
  6. title:'Example/QueueRow',
  7. // More on argTypes: https://storybook.js.org/docs/react/api/argtypes
  8. argTypes: {
  9. backgroundColor: {control: 'color'},
  10. },
  11. };
  12. // More on component templates: https://storybook.js.org/docs/react/writing-stories/introduction#using-args
  13. const Template = (args) => <table><QueueRow {...args} /></table>;
  14. export const Empty = Template.bind({});
  15. Empty.args = {
  16. arn: '',
  17. itemCount: '',
  18. qName: '',
  19. url: '',
  20. };
  21. export const UnqueriedNoURL = Template.bind({});
  22. UnqueriedNoURL.args = {
  23. arn: 'arn:sqs:eu-west-3:1234567890:main-queue',
  24. itemCount: '',
  25. qName: 'main-queue',
  26. url: '',
  27. };
  28. export const Unqueried = Template.bind({});
  29. Unqueried.args = {
  30. arn: 'arn:sqs:eu-west-3:1234567890:main-queue',
  31. itemCount: '',
  32. qName: 'main-queue',
  33. url: 'https://sqs.eu-west-3.amazonaws.com/1234567890/main-queue',
  34. };
  35. export const Queried = Template.bind({});
  36. Queried.args = {
  37. arn: 'arn:sqs:eu-west-3:1234567890:main-queue',
  38. itemCount: 25,
  39. qName: 'main-queue',
  40. url: 'https://sqs.eu-west-3.amazonaws.com/1234567890/main-queue',
  41. };