This repository has been archived by the owner on Nov 26, 2024. It is now read-only.
generated from MetaMask/metamask-module-template
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: adding css and js token stories
- Loading branch information
1 parent
0e4c543
commit 6798d5b
Showing
9 changed files
with
334 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
import { ColorSwatch } from './ColorSwatch'; | ||
|
||
const meta: Meta<typeof ColorSwatch> = { | ||
title: 'Documentation Components/ColorSwatch', | ||
component: ColorSwatch, | ||
}; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj<typeof ColorSwatch>; | ||
|
||
export const Default: Story = { | ||
render: () => ( | ||
<ColorSwatch | ||
color="#007bff" | ||
borderColor="#ced4da" | ||
textBackgroundColor="#f8f9fa" | ||
textColor="#212529" | ||
name="Primary Default" | ||
/> | ||
), | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
docs/components/ColorSwatchGroup/ColorSwatchGroup.stories.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
import { ColorSwatchGroup } from './ColorSwatchGroup'; | ||
|
||
const meta: Meta<typeof ColorSwatchGroup> = { | ||
title: 'Documentation Components/ColorSwatchGroup', | ||
component: ColorSwatchGroup, | ||
}; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj<typeof ColorSwatchGroup>; | ||
|
||
export const Default: Story = { | ||
render: () => ( | ||
<ColorSwatchGroup | ||
swatchData={{ | ||
white: { | ||
white000: { | ||
value: '#FFFFFF', | ||
description: '(HEX: #FFFFFF)', | ||
type: 'color', | ||
}, | ||
white010: { | ||
value: '#FCFCFC', | ||
description: '(HEX: #FCFCFC)', | ||
type: 'color', | ||
}, | ||
}, | ||
}} | ||
borderColor="#ced4da" | ||
textBackgroundColor="#f8f9fa" | ||
textColor="#212529" | ||
name="Color Swatch Group" | ||
/> | ||
), | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.