generated from nl-design-system/example
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add react logo story and css logo story to storybook
- Loading branch information
1 parent
b53f6f8
commit 2f3fc05
Showing
2 changed files
with
74 additions
and
12 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
/* @license CC0-1.0 */ | ||
|
||
import readme from '@frameless/components-css/logo/README.md?raw'; | ||
import { Logo } from '@frameless/components-react/src/Logo'; | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
|
||
import '@frameless/components-css/logo/index.scss'; | ||
|
||
// adds Logo to Storybook | ||
const meta = { | ||
title: 'React Component/Logo', | ||
|
||
id: 'react-logo', | ||
|
||
component: Logo, | ||
|
||
argTypes: { | ||
children: { | ||
name: 'Content', | ||
|
||
description: 'Logo', | ||
|
||
type: { | ||
name: 'string', | ||
required: true, | ||
}, | ||
|
||
defaultValue: '', | ||
}, | ||
}, | ||
|
||
args: {}, | ||
|
||
tags: ['autodocs'], | ||
|
||
parameters: { | ||
docs: { | ||
description: { | ||
component: readme, | ||
}, | ||
}, | ||
}, | ||
} satisfies Meta<typeof Logo>; | ||
|
||
export default meta; | ||
|
||
// defines that this (part of the) story is documentation | ||
type Story = StoryObj<typeof meta>; | ||
|
||
// adds Frameless Logo section to Logo in Storybook | ||
export const Default: Story = { | ||
name: 'Frameless Logo', // in sidenav shows Frameless logo below Docs | ||
args: {}, | ||
parameters: {}, | ||
}; | ||
// |