From 166bc0a5392d60522fadc7ae26f13198557b7dda Mon Sep 17 00:00:00 2001 From: Anton Gilgur Date: Thu, 22 Aug 2024 17:26:12 -0400 Subject: [PATCH] more diff reduction Signed-off-by: Anton Gilgur --- stories/dropdown.stories.tsx | 4 ++-- stories/forms.stories.tsx | 36 +++++++++++++++++---------------- stories/logs-viewer.stories.tsx | 20 +++++++++--------- 3 files changed, 31 insertions(+), 29 deletions(-) diff --git a/stories/dropdown.stories.tsx b/stories/dropdown.stories.tsx index fca312cc..f5816c4d 100644 --- a/stories/dropdown.stories.tsx +++ b/stories/dropdown.stories.tsx @@ -18,7 +18,7 @@ export const Menu = () => {
  • menu item 2
  • - ) + ); }; Menu.storyName = 'menu'; @@ -28,6 +28,6 @@ export const MenuWrapper = () => { title: 'menu item 1', action: () => window.alert('Clicked!'), }]} /> - ) + ); }; MenuWrapper.storyName = 'menu wrapper'; diff --git a/stories/forms.stories.tsx b/stories/forms.stories.tsx index a52ccaef..09cbe398 100644 --- a/stories/forms.stories.tsx +++ b/stories/forms.stories.tsx @@ -7,21 +7,23 @@ export default { title: 'Forms', }; -export const Default = () => ( -
    - {(api) => ( - -
    - -
    -
    - -
    -
    - -
    -
    - )} - -); +export const Default = () => { + return ( +
    + {(api) => ( + +
    + +
    +
    + +
    +
    + +
    +
    + )} + + ); +}; Default.storyName = 'default'; diff --git a/stories/logs-viewer.stories.tsx b/stories/logs-viewer.stories.tsx index c140856a..97175b7d 100644 --- a/stories/logs-viewer.stories.tsx +++ b/stories/logs-viewer.stories.tsx @@ -8,15 +8,15 @@ export default { }; export const Default = () => ( -
    - new Observable((observer) => { - const interval = setInterval(() => observer.next('test\n'), 1000); - return () => clearInterval(interval); - }), - shouldRepeat: () => false, - }}/> -
    +
    + new Observable((observer) => { + const interval = setInterval(() => observer.next('test\n'), 1000); + return () => clearInterval(interval); + }), + shouldRepeat: () => false, + }}/> +
    ); Default.storyName = 'default';