-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1f782f3
commit 1d4e85e
Showing
8 changed files
with
222 additions
and
130 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,27 @@ | ||
import React from 'react'; | ||
import { color, styled, typography } from '@storybook/theming'; | ||
|
||
const Code = styled.pre` | ||
line-height: 18px; | ||
padding: 11px 1rem; | ||
white-space: pre-wrap; | ||
background: rgba(0, 0, 0, 0.05); | ||
color: ${color.darkest}; | ||
border-radius: 3px; | ||
margin: 1rem 0; | ||
width: 100%; | ||
display: block; | ||
overflow: hidden; | ||
font-family: ${typography.fonts.mono}; | ||
font-size: ${typography.size.s2 - 1}px; | ||
`; | ||
|
||
interface ClipboardCodeProps { | ||
code: string; | ||
} | ||
|
||
export const ClipboardCode = ({ code, ...props }: ClipboardCodeProps) => ( | ||
<Code id="clipboard-code" {...props}> | ||
{code} | ||
</Code> | ||
); |
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 was deleted.
Oops, something went wrong.
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,39 @@ | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
import React from 'react'; | ||
import { AboutScreen } from './about'; | ||
|
||
const meta = { | ||
component: AboutScreen, | ||
title: 'Settings/AboutScreen', | ||
decorators: [ | ||
(Story) => ( | ||
<div | ||
style={{ | ||
position: 'relative', | ||
height: '100vh', | ||
width: '100vw', | ||
}} | ||
> | ||
<Story /> | ||
</div> | ||
), | ||
], | ||
} satisfies Meta<typeof AboutScreen>; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj<typeof meta>; | ||
|
||
export const Default: Story = { | ||
args: { | ||
current: { | ||
version: '7.0.1', | ||
}, | ||
}, | ||
parameters: { | ||
design: { | ||
type: 'figma', | ||
url: 'https://www.figma.com/file/ur4kydUbRqdDyfoZWzdiIw/Storybook-app?type=design&node-id=9564-120444&mode=design&t=0TPINZFpwgFQFQeX-4', | ||
}, | ||
}, | ||
}; |
Oops, something went wrong.