diff --git a/apps/storybook-react-native/.storybook/storybook.requires.js b/apps/storybook-react-native/.storybook/storybook.requires.js index 3e8e33307..44f5a58dd 100644 --- a/apps/storybook-react-native/.storybook/storybook.requires.js +++ b/apps/storybook-react-native/.storybook/storybook.requires.js @@ -84,6 +84,7 @@ const getStories = () => { "./../../packages/design-system-react-native/src/components/temp-components/TextOrChildren/TextOrChildren.stories.tsx": require("../../../packages/design-system-react-native/src/components/temp-components/TextOrChildren/TextOrChildren.stories.tsx"), "./../../packages/design-system-react-native/src/components/Text/Text.stories.tsx": require("../../../packages/design-system-react-native/src/components/Text/Text.stories.tsx"), "./../../packages/design-system-react-native/src/components/TextButton/TextButton.stories.tsx": require("../../../packages/design-system-react-native/src/components/TextButton/TextButton.stories.tsx"), + "./stories/Backgrounds.stories.tsx": require("../stories/Backgrounds.stories.tsx"), "./stories/WalletHome.stories.tsx": require("../stories/WalletHome.stories.tsx"), }; }; diff --git a/apps/storybook-react-native/stories/Backgrounds.stories.tsx b/apps/storybook-react-native/stories/Backgrounds.stories.tsx new file mode 100644 index 000000000..7aeb4b5af --- /dev/null +++ b/apps/storybook-react-native/stories/Backgrounds.stories.tsx @@ -0,0 +1,120 @@ +import { + Box, + BoxAlignItems, + BoxBackgroundColor, + BoxFlexDirection, + Icon, + IconColor, + IconName, + Text, + TextButton, + TextColor, + TextVariant, + Button, + ButtonVariant, +} from '@metamask/design-system-react-native'; +import { useTailwind } from '@metamask/design-system-twrnc-preset'; +import type { Meta, StoryObj } from '@storybook/react'; +import React from 'react'; +import { ScrollView } from 'react-native'; + +const meta: Meta = { + title: 'Examples/Backgrounds', + component: () => null, +}; + +export default meta; +type Story = StoryObj; + +const ButtonComponents = () => ( + + + + + Text Button + +); + +const TextComponents = () => ( + <> + Text & Icon Colors + + + + Text Default and Icon Default + + + + + Text Alternative and Icon Alternative + + + + + Text Muted and Icon Muted + + + +); + +const Backgrounds: React.FC = () => { + const tw = useTailwind(); + return ( + + + {/* Background Default */} + + Background Default + + + {/* Background Section */} + + Background Section + + + + {/* Background Subsection */} + + Background Subsection + + + + + + + + ); +}; + +export const Default: Story = { + render: () => , +}; diff --git a/apps/storybook-react/stories/Backgrounds.stories.tsx b/apps/storybook-react/stories/Backgrounds.stories.tsx new file mode 100644 index 000000000..4433c4e6e --- /dev/null +++ b/apps/storybook-react/stories/Backgrounds.stories.tsx @@ -0,0 +1,114 @@ +import { + Box, + BoxAlignItems, + BoxBackgroundColor, + BoxFlexDirection, + Icon, + IconColor, + IconName, + Text, + TextColor, + TextVariant, + Button, + ButtonVariant, + TextButton, +} from '@metamask/design-system-react'; +import type { Meta, StoryObj } from '@storybook/react'; +import React from 'react'; + +const meta: Meta = { + title: 'Examples/Backgrounds', + component: () => null, +}; + +export default meta; +type Story = StoryObj; + +const ButtonComponents = () => ( + + + + + Text Button + +); + +const TextComponents = () => ( + <> + Text & Icon Colors + + + + Text Default and Icon Default + + + + + Text Alternative and Icon Alternative + + + + + Text Muted and Icon Muted + + + +); + +const Backgrounds: React.FC = () => { + return ( + + {/* Background Default */} + + Background Default + + + + {/* Background Section */} + + Background Section + + + {/* Background Subsection */} + + Background Subsection + + + + + + + ); +}; + +export const Default: Story = { + render: () => , +};