mutedBox.stories.js 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. import React from 'react';
  2. import {withInfo} from '@storybook/addon-info';
  3. import MutedBox from 'app/components/mutedBox';
  4. export default {
  5. title: 'UI/Muted Box',
  6. };
  7. export const Default = withInfo('Default')(() => <MutedBox statusDetails={{}} />);
  8. Default.story = {
  9. name: 'default',
  10. };
  11. export const IgnoreUntil = withInfo('Ignore until timestamp')(() => (
  12. <MutedBox statusDetails={{ignoreUntil: '2017-06-21T19:45:10Z'}} />
  13. ));
  14. IgnoreUntil.story = {
  15. name: 'ignoreUntil',
  16. };
  17. export const IgnoreCount = withInfo('Ignore until "count"')(() => (
  18. <MutedBox statusDetails={{ignoreCount: 100}} />
  19. ));
  20. IgnoreCount.story = {
  21. name: 'ignoreCount',
  22. };
  23. export const IgnoreCountWIgnoreWindow = withInfo('Ignore count with window')(() => (
  24. <MutedBox statusDetails={{ignoreCount: 100, ignoreWindow: 1}} />
  25. ));
  26. IgnoreCountWIgnoreWindow.story = {
  27. name: 'ignoreCount w/ ignoreWindow',
  28. };
  29. export const IgnoreUserCount = withInfo('Ignore user count')(() => (
  30. <MutedBox statusDetails={{ignoreUserCount: 100}} />
  31. ));
  32. IgnoreUserCount.story = {
  33. name: 'ignoreUserCount',
  34. };
  35. export const IgnoreUserCountWIgnoreUserWindow = withInfo(
  36. 'Ignore user count with window'
  37. )(() => <MutedBox statusDetails={{ignoreUserCount: 100, ignoreUserWindow: 1}} />);
  38. IgnoreUserCountWIgnoreUserWindow.story = {
  39. name: 'ignoreUserCount w/ ignoreUserWindow',
  40. };