Skip to content

Commit

Permalink
fix: updated deprecated type usage
Browse files Browse the repository at this point in the history
  • Loading branch information
oyo authored Sep 16, 2024
2 parents cbf91b7 + 557061b commit 8fa97e1
Show file tree
Hide file tree
Showing 74 changed files with 148 additions and 148 deletions.
4 changes: 2 additions & 2 deletions src/components/basic/Alert/Alert.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { Alert as Component } from '.'

export default {
Expand All @@ -30,7 +30,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args}>{args.children}</Component>

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/BaseImage/BaseImage.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { BaseImage as Component } from '.'

export default {
Expand All @@ -27,7 +27,7 @@ export default {
tags: ['autodocs'],
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Breadcrumb/Breadcrumb.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
********************************************************************************/

import { Link, Typography } from '@mui/material'
import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { Breadcrumb as Component } from '.'

export default {
Expand Down Expand Up @@ -57,7 +57,7 @@ const breadcrumbs = [
</Typography>,
]

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Button/BackButton.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import type { ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { BackButton as Component } from './BackButton'

export default {
Expand All @@ -32,7 +32,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Button/LoadMoreButton.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { LoadMoreButton as Component } from './LoadMoreButton'

export default {
Expand All @@ -28,7 +28,7 @@ export default {
argTypes: {},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Button/ScrollToTopButton.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { ScrollToTopButton as Component } from './ScrollToTopButton'

export default {
Expand All @@ -32,7 +32,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Carousel/Carousel.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import uniqueId from 'lodash/uniqueId'
import { theme } from '../../../theme'
import { Carousel as Component } from '.'
Expand All @@ -40,7 +40,7 @@ const itemsArray = [
'Element 5',
]

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => (
<Component {...args}>
Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Carousel/CarouselBox.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import uniqueId from 'lodash/uniqueId'
import { theme } from '../../../theme'
import { CarouselBox as Component } from './CarouselBox'
Expand All @@ -40,7 +40,7 @@ const itemsArray = [
'Element 5',
]

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => (
<Component {...args}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { CategoryDivider as Component } from '.'

export default {
Expand All @@ -28,7 +28,7 @@ export default {
argTypes: {},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Checkbox/Checkbox.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { Checkbox as Component } from '.'

export default {
Expand All @@ -32,7 +32,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Chip/DraggableChip.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { DraggableChip as Component } from './DraggableChip'

export default {
Expand All @@ -32,7 +32,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args}>{args.children}</Component>

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Chip/chip.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { Chip as Component } from '.'

export default {
Expand All @@ -29,7 +29,7 @@ export default {
parameters: {},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { CircularProgress as Component } from '.'

export default {
Expand All @@ -27,7 +27,7 @@ export default {
tags: ['autodocs'],
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
import HomeOutlinedIcon from '@mui/icons-material/HomeOutlined'
import SettingsOutlinedIcon from '@mui/icons-material/SettingsOutlined'
import { Box, Divider, Typography } from '@mui/material'
import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { Table } from '../StaticTable/StaticTable.stories'
import { type CustomAccordionProps } from './Item'
import { CustomAccordion as Component } from '.'
Expand All @@ -35,7 +35,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Datepicker/Datepicker.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
********************************************************************************/

import { Box } from '@mui/material'
import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { Datepicker as Component, type DateType } from '.'

export default {
Expand All @@ -29,7 +29,7 @@ export default {
argTypes: {},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => (
<Box sx={{ width: '320px' }}>
Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Dialog/Dialog.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { Button } from '../Button'
import { DialogActions } from './DialogActions'
import { DialogContent } from './DialogContent'
Expand Down Expand Up @@ -47,7 +47,7 @@ export default {
},
}

const DialogTemplate: ComponentStory<typeof Component> = (
const DialogTemplate: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => {
const { title, intro, content, helperText, ...componentArgs } = args
Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Dialog/DialogActions.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { Button } from '../Button'
import { DialogActions as Component } from './DialogActions'

Expand All @@ -28,7 +28,7 @@ export default {
tags: ['autodocs'],
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => (
<Component {...args}>
Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Dialog/DialogHeader.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { DialogHeader as Component } from './DialogHeader'

export default {
Expand All @@ -27,7 +27,7 @@ export default {
tags: ['autodocs'],
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/DropdownMenu/DropdownMenu.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
import EditIcon from '@mui/icons-material/Edit'
import FileCopyIcon from '@mui/icons-material/FileCopy'
import MenuItem from '@mui/material/MenuItem'
import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { DropdownMenu as Component } from '.'

export default {
Expand All @@ -33,7 +33,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => (
<Component {...args}>
Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Dropzone/DropArea.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { DropArea as Component } from './components/DropArea'

export default {
Expand All @@ -37,7 +37,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => <Component {...args} />

Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Dropzone/DropPreview.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { DropPreview as Component } from './components/DropPreview'
import { UploadStatus } from './types'

Expand Down Expand Up @@ -61,7 +61,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => (
<Component {...args} uploadFiles={args.placeholder ? [] : args.uploadFiles} />
Expand Down
4 changes: 2 additions & 2 deletions src/components/basic/Dropzone/DropPreviewFile.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* SPDX-License-Identifier: Apache-2.0
********************************************************************************/

import { type ComponentStory } from '@storybook/react'
import { type StoryFn } from '@storybook/react'
import { DropPreviewFile as Component } from './components/DropPreviewFile'
import { UploadStatus } from './types'

Expand Down Expand Up @@ -52,7 +52,7 @@ export default {
},
}

const Template: ComponentStory<typeof Component> = (
const Template: StoryFn<typeof Component> = (
args: React.ComponentProps<typeof Component>
) => {
const { name, size, status, progressPercent, ...props } = args
Expand Down
Loading

0 comments on commit 8fa97e1

Please sign in to comment.