Skip to content

Commit 563ee5d

Browse files
committed
feat(components, app): update Chip component for unification
update Chip component for unification. the details are below close AUTH-214
1 parent 0539980 commit 563ee5d

40 files changed

+91
-90
lines changed

app/src/atoms/InlineNotification/InlineNotification.stories.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import * as React from 'react'
2-
import { touchScreenViewport } from '../../DesignTokens/constants'
2+
import { VIEWPORT } from '@opentrons/components'
33
import { InlineNotification } from '.'
44
import type { Story, Meta } from '@storybook/react'
55

@@ -26,7 +26,7 @@ export default {
2626
defaultValue: true,
2727
},
2828
},
29-
parameters: touchScreenViewport,
29+
parameters: VIEWPORT.touchScreenViewport,
3030
} as Meta
3131

3232
const Template: Story<

app/src/atoms/ListItem/ListItem.stories.tsx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
import * as React from 'react'
2-
import { DIRECTION_COLUMN, Flex, SPACING } from '@opentrons/components'
3-
import { touchScreenViewport } from '../../DesignTokens/constants'
2+
import {
3+
DIRECTION_COLUMN,
4+
Flex,
5+
SPACING,
6+
VIEWPORT,
7+
} from '@opentrons/components'
48
import { StyledText } from '../text'
59
import { ListItem } from '.'
610
import type { Story, Meta } from '@storybook/react'
@@ -15,7 +19,7 @@ export default {
1519
},
1620
},
1721
},
18-
parameters: touchScreenViewport,
22+
parameters: VIEWPORT.touchScreenViewport,
1923
} as Meta
2024

2125
const ListItemTemplate: Story<React.ComponentProps<typeof ListItem>> = args => (

app/src/atoms/Snackbar/Snackbar.stories.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,17 @@ import {
77
JUSTIFY_CENTER,
88
PrimaryButton,
99
SPACING,
10+
VIEWPORT,
1011
} from '@opentrons/components'
1112
import { StyledText } from '../text'
12-
import { touchScreenViewport } from '../../DesignTokens/constants'
1313

1414
import { Snackbar } from './index'
1515
import type { Story, Meta } from '@storybook/react'
1616

1717
export default {
1818
title: 'ODD/Atoms/Snackbar',
1919
component: Snackbar,
20-
parameters: touchScreenViewport,
20+
parameters: VIEWPORT.touchScreenViewport,
2121
} as Meta
2222

2323
const DefaultTemplate: Story<React.ComponentProps<typeof Snackbar>> = args => {

app/src/atoms/SoftwareKeyboard/CustomKeyboard/CustomKeyboard.stories.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import * as React from 'react'
22
import {
3-
Flex,
43
DIRECTION_COLUMN,
4+
Flex,
55
POSITION_ABSOLUTE,
66
SPACING,
7+
VIEWPORT,
78
} from '@opentrons/components'
8-
import { touchScreenViewport } from '../../../DesignTokens/constants'
99
import { InputField } from '../../InputField'
1010
import { CustomKeyboard } from './'
1111
import '../index.css'

app/src/atoms/SoftwareKeyboard/NormalKeyboard/NormalKeyboard.stories.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import * as React from 'react'
22
import {
3-
Flex,
43
DIRECTION_COLUMN,
4+
Flex,
55
POSITION_ABSOLUTE,
66
SPACING,
7+
VIEWPORT,
78
} from '@opentrons/components'
8-
import { touchScreenViewport } from '../../../DesignTokens/constants'
99
import { InputField } from '../../InputField'
1010
import { NormalKeyboard } from '.'
1111

@@ -17,7 +17,7 @@ import type { Story, Meta } from '@storybook/react'
1717
export default {
1818
title: 'ODD/Atoms/SoftwareKeyboard/NormalKeyboard',
1919
component: NormalKeyboard,
20-
parameters: touchScreenViewport,
20+
parameters: VIEWPORT.touchScreenViewport,
2121
} as Meta
2222

2323
const Template: Story<React.ComponentProps<typeof NormalKeyboard>> = args => {

app/src/atoms/SoftwareKeyboard/Numpad/Numpad.stories.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ import {
44
DIRECTION_COLUMN,
55
POSITION_ABSOLUTE,
66
SPACING,
7+
VIEWPORT,
78
} from '@opentrons/components'
8-
import { touchScreenViewport } from '../../../DesignTokens/constants'
99
import { InputField } from '../../InputField'
1010
import { Numpad } from './'
1111
import '../index.css'
@@ -16,7 +16,7 @@ import type { Story, Meta } from '@storybook/react'
1616
export default {
1717
title: 'ODD/Atoms/SoftwareKeyboard/Numpad',
1818
component: Numpad,
19-
parameters: touchScreenViewport,
19+
parameters: VIEWPORT.touchScreenViewport,
2020
} as Meta
2121

2222
const Template: Story<React.ComponentProps<typeof Numpad>> = args => {

app/src/atoms/Toast/ODDToast.stories.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,16 @@ import {
77
POSITION_FIXED,
88
PrimaryButton,
99
SPACING,
10+
VIEWPORT,
1011
} from '@opentrons/components'
11-
import { touchScreenViewport } from '../../DesignTokens/constants'
1212
import { StyledText } from '../text'
1313
import { Toast } from '.'
1414
import type { Story, Meta } from '@storybook/react'
1515

1616
export default {
1717
title: 'ODD/Atoms/Toast',
1818
component: Toast,
19-
parameters: touchScreenViewport,
19+
parameters: VIEWPORT.touchScreenViewport,
2020
} as Meta
2121

2222
const Template: Story<React.ComponentProps<typeof Toast>> = args => {

app/src/atoms/buttons/FloatingActionButton.stories.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import * as React from 'react'
2-
import { ICON_DATA_BY_NAME } from '@opentrons/components'
3-
import { touchScreenViewport } from '../../DesignTokens/constants'
2+
import { ICON_DATA_BY_NAME, VIEWPORT } from '@opentrons/components'
43
import { FloatingActionButton } from './'
54

65
import type { Story, Meta } from '@storybook/react'
@@ -17,7 +16,7 @@ export default {
1716
},
1817
onClick: { action: 'clicked' },
1918
},
20-
parameters: touchScreenViewport,
19+
parameters: VIEWPORT.touchScreenViewport,
2120
} as Meta
2221

2322
const FloatingActionButtonTemplate: Story<

app/src/atoms/buttons/LargeButton.stories.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
import * as React from 'react'
2-
import { touchScreenViewport } from '../../DesignTokens/constants'
2+
import { VIEWPORT } from '@opentrons/components'
33
import { LargeButton } from './'
44
import type { Story, Meta } from '@storybook/react'
55

66
export default {
77
title: 'ODD/Atoms/Buttons/LargeButton',
88
argTypes: { onClick: { action: 'clicked' } },
9-
parameters: touchScreenViewport,
9+
parameters: VIEWPORT.touchScreenViewport,
1010
} as Meta
1111

1212
const LargeButtonTemplate: Story<

app/src/atoms/buttons/MediumButton.stories.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import * as React from 'react'
2-
import { ICON_DATA_BY_NAME } from '@opentrons/components'
3-
import { touchScreenViewport } from '../../DesignTokens/constants'
2+
import { ICON_DATA_BY_NAME, VIEWPORT } from '@opentrons/components'
43
import { MediumButton } from './'
54
import type { Story, Meta } from '@storybook/react'
65

@@ -29,7 +28,7 @@ export default {
2928
defaultValue: undefined,
3029
},
3130
},
32-
parameters: touchScreenViewport,
31+
parameters: VIEWPORT.touchScreenViewport,
3332
} as Meta
3433

3534
const MediumButtonTemplate: Story<

0 commit comments

Comments
 (0)