diff --git a/packages/web-react/src/components/Pill/demo/Pill.tsx b/packages/web-react/src/components/Pill/demo/Pill.tsx deleted file mode 100644 index 45fd66970c..0000000000 --- a/packages/web-react/src/components/Pill/demo/Pill.tsx +++ /dev/null @@ -1,14 +0,0 @@ -import React, { ElementType } from 'react'; -import { ComponentStory } from '@storybook/react'; -import Pill from '../Pill'; -import { SpiritPillProps } from '../../../types'; - -const Story: ComponentStory = (args: SpiritPillProps) => ( - -); - -Story.args = { - children: '3', -}; - -export default Story; diff --git a/packages/web-react/src/components/Pill/demo/PillColors.tsx b/packages/web-react/src/components/Pill/demo/PillColors.tsx index 4ecb6f6020..fc2e54aaa1 100644 --- a/packages/web-react/src/components/Pill/demo/PillColors.tsx +++ b/packages/web-react/src/components/Pill/demo/PillColors.tsx @@ -1,27 +1,21 @@ import React from 'react'; +import { ActionColors, EmotionColors } from '../../../constants'; import Pill from '../Pill'; -// @see: https://github.com/storybookjs/storybook/issues/8104#issuecomment-932310244 -// eslint-disable-next-line @typescript-eslint/no-unused-vars -const Story = (props: unknown) => ( - <> -
- 3 - 3 - 3 - 3 -
-
- 333 - 333 -
-
- 3 - 3 - 3 - 3 -
- -); +const PillColors = () => { + const actionColors = Object.values(ActionColors); + const emotionColors = Object.values(EmotionColors); + const colors = [...actionColors, 'selected', 'unselected', ...emotionColors]; -export default Story; + return ( + <> + {colors.map((color) => ( + + 3 + + ))} + + ); +}; + +export default PillColors; diff --git a/packages/web-react/src/components/Pill/demo/PillLongText.tsx b/packages/web-react/src/components/Pill/demo/PillLongText.tsx new file mode 100644 index 0000000000..496192733b --- /dev/null +++ b/packages/web-react/src/components/Pill/demo/PillLongText.tsx @@ -0,0 +1,6 @@ +import React from 'react'; +import Pill from '../Pill'; + +const PillLongText = () => 333; + +export default PillLongText; diff --git a/packages/web-react/src/components/Pill/demo/index.tsx b/packages/web-react/src/components/Pill/demo/index.tsx index 54738aa55d..b1f67797c8 100644 --- a/packages/web-react/src/components/Pill/demo/index.tsx +++ b/packages/web-react/src/components/Pill/demo/index.tsx @@ -1,16 +1,16 @@ import React from 'react'; import ReactDOM from 'react-dom/client'; import DocsSection from '../../../../docs/DocsSections'; -import Pill from './Pill'; import PillColors from './PillColors'; +import PillLongText from './PillLongText'; ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render( - - - + + + , );