From a98deeb0bedde97a5c59651a4889c50131e1ea3f Mon Sep 17 00:00:00 2001 From: Amanda Brown Date: Tue, 10 Oct 2023 11:25:15 -0400 Subject: [PATCH] fix duplicate story label --- src/Dialog.stories.tsx | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/src/Dialog.stories.tsx b/src/Dialog.stories.tsx index c51267626d5..dc51650777e 100644 --- a/src/Dialog.stories.tsx +++ b/src/Dialog.stories.tsx @@ -1,14 +1,14 @@ -import React, {useState, useRef, useCallback} from 'react' -import {Meta} from '@storybook/react' +import React, { useState, useRef, useCallback } from 'react' +import { Meta } from '@storybook/react' -import {BaseStyles, ThemeProvider} from '.' -import {Button} from './Button' -import {Dialog, DialogWidth, DialogHeight} from './Dialog/Dialog' +import { BaseStyles, ThemeProvider } from '.' +import { Button } from './Button' +import { Dialog, DialogWidth, DialogHeight } from './Dialog/Dialog' /* Dialog Version 1? */ export default { - title: 'Components/Dialog', + title: 'Dialog', component: Dialog, decorators: [ Story => { @@ -47,22 +47,22 @@ export default { type: 'boolean', }, }, - title: {table: {disable: true}}, + title: { table: { disable: true } }, - renderHeader: {table: {disable: true}}, - renderBody: {table: {disable: true}}, - renderFooter: {table: {disable: true}}, - onClose: {table: {disable: true}}, - role: {table: {disable: true}}, - ref: {table: {disable: true}}, - key: {table: {disable: true}}, - footerButtons: {table: {disable: true}}, + renderHeader: { table: { disable: true } }, + renderBody: { table: { disable: true } }, + renderFooter: { table: { disable: true } }, + onClose: { table: { disable: true } }, + role: { table: { disable: true } }, + ref: { table: { disable: true } }, + key: { table: { disable: true } }, + footerButtons: { table: { disable: true } }, }, } as Meta const lipsum = ( -
-

+

+

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque sollicitudin mauris maximus elit sagittis, nec lobortis ligula elementum. Nam iaculis, urna nec lobortis posuere, eros urna venenatis eros, vel accumsan turpis nunc vitae enim. Maecenas et lorem lectus. Vivamus iaculis tortor eget ante placerat, nec posuere nisl tincidunt. @@ -107,7 +107,7 @@ interface DialogStoryProps { height: DialogHeight subtitle: boolean } -export const Default = ({width, height, subtitle}: DialogStoryProps) => { +export const Default = ({ width, height, subtitle }: DialogStoryProps) => { const [isOpen, setIsOpen] = useState(false) const [secondOpen, setSecondOpen] = useState(false) const buttonRef = useRef(null) @@ -127,9 +127,9 @@ export const Default = ({width, height, subtitle}: DialogStoryProps) => { width={width} height={height} footerButtons={[ - {buttonType: 'normal', content: 'Open Second Dialog', onClick: openSecondDialog}, - {buttonType: 'danger', content: 'Delete the universe', onClick: onDialogClose}, - {buttonType: 'primary', content: 'Proceed', onClick: openSecondDialog, autoFocus: true}, + { buttonType: 'normal', content: 'Open Second Dialog', onClick: openSecondDialog }, + { buttonType: 'danger', content: 'Delete the universe', onClick: onDialogClose }, + { buttonType: 'primary', content: 'Proceed', onClick: openSecondDialog, autoFocus: true }, ]} > {lipsum}