Skip to content

Commit

Permalink
fix: storybook
Browse files Browse the repository at this point in the history
  • Loading branch information
LufyCZ committed Jun 15, 2024
1 parent bee8d13 commit 6686be6
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 7 deletions.
7 changes: 4 additions & 3 deletions apps/storybook/stories/button.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
// Button.stories.ts|tsx

import type { Meta, StoryObj } from '@storybook/react'
import { Button, ButtonProps, DiscordIcon } from '@sushiswap/ui'
import { Button, ButtonProps } from '@sushiswap/ui'
import { Currency } from '@sushiswap/ui'
import { DiscordIcon } from '@sushiswap/ui/icons/DiscordIcon'
import * as React from 'react'
import { ChainId } from 'sushi/chain'
import { SUSHI } from 'sushi/currency'
Expand Down Expand Up @@ -88,8 +89,8 @@ export const Sizes = (args) => {
}

export const Loading = (args) => {
const items = [true, false].map((loading) => (
<React.Fragment key={loading}>
const items = [true, false].map((loading, i) => (
<React.Fragment key={i}>
<Button {...args} key={loading} loading={loading}>
{loading ? 'Loading' : 'Not Loading'}
</Button>
Expand Down
3 changes: 2 additions & 1 deletion apps/storybook/stories/chip.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// Chip.stories.ts|tsx

import type { Meta, StoryObj } from '@storybook/react'
import { Chip, ChipProps, DiscordIcon } from '@sushiswap/ui'
import { Chip, ChipProps } from '@sushiswap/ui'
import { DiscordIcon } from '@sushiswap/ui/icons/DiscordIcon'
import * as React from 'react'

import { ViewGroup } from '../components/View'
Expand Down
3 changes: 2 additions & 1 deletion apps/storybook/stories/iconbutton.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// IconButton.stories.ts|tsx

import type { Meta, StoryObj } from '@storybook/react'
import { DiscordIcon, IconButton, IconButtonProps } from '@sushiswap/ui'
import { IconButton, IconButtonProps } from '@sushiswap/ui'
import { DiscordIcon } from '@sushiswap/ui/icons/DiscordIcon'
import * as React from 'react'

import { ViewGroup } from '../components/View'
Expand Down
3 changes: 2 additions & 1 deletion apps/storybook/stories/list.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// List.stories.ts|tsx

import type { Meta, StoryObj } from '@storybook/react'
import { DiscordIcon, List } from '@sushiswap/ui'
import { List } from '@sushiswap/ui'
import { DiscordIcon } from '@sushiswap/ui/icons/DiscordIcon'
import * as React from 'react'

const meta = {
Expand Down
4 changes: 3 additions & 1 deletion apps/storybook/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{
"compilerOptions": {
"jsx": "react-jsx"
"jsx": "react-jsx",
"moduleResolution": "Bundler",
"module": "ESNext",
}
}

0 comments on commit 6686be6

Please sign in to comment.