feat: create stories for AdvisoriesContent

This commit is contained in:
RadoslavDimchev 2023-08-31 18:43:28 +03:00
parent 74f3f02c7a
commit 6facc0a366
1 changed files with 63 additions and 0 deletions

View File

@ -0,0 +1,63 @@
import type { Meta, StoryObj } from '@storybook/react'
import { withRouter } from 'storybook-addon-react-router-v6'
import AdvisoriesContent from './AdvisoriesContent'
import { advisoryTopics } from './Advisories'
const meta = {
title: 'ValidatorOnboarding/AdvisoriesContent',
component: AdvisoriesContent,
parameters: {
layout: 'centered',
},
tags: ['autodocs'],
decorators: [withRouter],
} satisfies Meta<typeof AdvisoriesContent>
export default meta
type Story = StoryObj<typeof meta>
const advisoryTopicsKeys = Object.keys(advisoryTopics)
const advisoryTopicsValues = Object.values(advisoryTopics)
export const ProofOfStake: Story = {
args: {
title: advisoryTopicsKeys[0],
content: advisoryTopicsValues[0],
},
}
export const Deposit: Story = {
args: {
title: advisoryTopicsKeys[1],
content: advisoryTopicsValues[1],
},
}
export const KeyManagement: Story = {
args: {
title: advisoryTopicsKeys[2],
content: advisoryTopicsValues[2],
},
}
export const BadBehaviour: Story = {
args: {
title: advisoryTopicsKeys[3],
content: advisoryTopicsValues[3],
},
}
export const Requirements: Story = {
args: {
title: advisoryTopicsKeys[4],
content: advisoryTopicsValues[4],
},
}
export const Risks: Story = {
args: {
title: advisoryTopicsKeys[5],
content: advisoryTopicsValues[5],
},
}