This repository has been archived by the owner on Jan 25, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(storybook): updating storybook to mdx (#164)
- Loading branch information
1 parent
1de40cd
commit c445caa
Showing
58 changed files
with
3,346 additions
and
1,653 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import * as React from 'react'; | ||
import { defaultTheme } from '@manifest-ui/themes'; | ||
import { styled } from '@manifest-ui/styled'; | ||
|
||
const StyledLink = styled('a')({ | ||
color: defaultTheme.colors.primary[500], | ||
fontSize: 'inherit', | ||
fontWeight: defaultTheme.fontWeights.normal, | ||
letterSpacing: defaultTheme.letterSpacings.normal, | ||
textDecoration: 'none', | ||
transitionDuration: defaultTheme.transitions.duration.base, | ||
transitionProperty: defaultTheme.transitions.property.colors, | ||
|
||
'&:hover:not(&:focus)': { | ||
color: defaultTheme.colors.primary[600], | ||
}, | ||
}); | ||
|
||
const ExternalLink = props => { | ||
return <StyledLink rel="nofollow,noopener,noreferrer" target="_blank" {...props} /> | ||
} | ||
|
||
export default ExternalLink; |
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,38 @@ | ||
import * as React from 'react'; | ||
import { defaultTheme } from '@manifest-ui/themes'; | ||
import ExternalLink from './ExternalLink'; | ||
import { styled } from '@manifest-ui/styled'; | ||
|
||
const StyledList = styled('p')({ | ||
color: defaultTheme.colors.emphasis.secondary, | ||
fontSize: defaultTheme.fontSizes.small, | ||
lineHeight: defaultTheme.fontSizes.medium, | ||
m: 0, | ||
py: defaultTheme.space[4], | ||
}); | ||
|
||
const Sources = props => { | ||
const { github, npm } = props; | ||
|
||
return ( | ||
<StyledList> | ||
<ExternalLink | ||
href={`https://www.github.com/project44/manifest-ui/tree/main/packages/${github}`} | ||
target="_blank" | ||
> | ||
View Source | ||
</ExternalLink> | ||
{' '} | ||
{'|'} | ||
{' '} | ||
<ExternalLink | ||
href={`https://www.npmjs.com/package/${npm}`} | ||
target="_blank" | ||
> | ||
View on NPM | ||
</ExternalLink> | ||
</StyledList> | ||
) | ||
} | ||
|
||
export default Sources; |
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 |
---|---|---|
@@ -1,4 +1,6 @@ | ||
export { default as ExternalLink } from './ExternalLink'; | ||
export { default as Props } from './Props'; | ||
export { default as Sources } from './Sources'; | ||
export { default as Story } from './Story'; | ||
|
||
export { Meta } from '@storybook/addon-docs'; | ||
export { ArgsTable, Meta } from '@storybook/addon-docs'; |
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 |
---|---|---|
@@ -1,10 +1,4 @@ | ||
import { addons } from '@storybook/addons'; | ||
import theme from './theme.js'; | ||
|
||
addons.setConfig({ | ||
isFullscreen: false, | ||
showPanel: true, | ||
panelPosition: 'bottom', | ||
isToolshown: true, | ||
theme: theme, | ||
}); | ||
addons.setConfig({ theme }); |
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,50 @@ | ||
<style type="text/css"> | ||
.sbdocs-wrapper .sbdocs-h1 { | ||
font-size: 2rem; | ||
font-weight: 400; | ||
letter-spacing: -0.02em; | ||
line-height: 2.5rem; | ||
margin-bottom: 0; | ||
padding-bottom: 16px; | ||
} | ||
|
||
.sbdocs-wrapper .sbdocs-h2 { | ||
font-weight: 400; | ||
margin-bottom: 12px; | ||
padding-bottom: 12px; | ||
} | ||
|
||
|
||
.sbdocs-wrapper .sbdocs-h2:first-of-type { | ||
padding-top: 24px; | ||
} | ||
|
||
.sbdocs-wrapper .sbdocs-h3 { | ||
font-weight: 400; | ||
margin-bottom: 0; | ||
padding-bottom: 8px; | ||
} | ||
|
||
.sbdocs-wrapper .sbdocs-preview { | ||
border: 1px solid #D5D7D9; | ||
border-radius: 4px; | ||
box-shadow: none; | ||
margin: 24px 0 32px; | ||
} | ||
|
||
.sbdocs-wrapper .docblock-source { | ||
border: 1px solid #D5D7D9; | ||
border-radius: 4px; | ||
box-shadow: none; | ||
margin: 24px 0 32px; | ||
} | ||
|
||
.docblock-argstable-head th, .docblock-argstable-body td { | ||
border-bottom: 1px solid #D5D7D9 !important; | ||
} | ||
|
||
.docblock-argstable .docblock-argstable-body { | ||
border: none !important; | ||
box-shadow: none !important; | ||
} | ||
</style> |
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,19 @@ | ||
import { ExternalLink, Meta } from '../.storybook/components'; | ||
|
||
<Meta title="Welcome" /> | ||
|
||
<p style={{ fontWeight: 500, letterSpacing: '0.04em', lineHeight: '16px', margin: 0 }}> | ||
THE PROJECT44 DESIGN SYSTEM | ||
</p> | ||
|
||
# Welcome to Manifest UI | ||
|
||
<p style={{ margin: 0 }}> | ||
This is the developer Storybook of Manifest UI. Here you can interact with the system components | ||
directly. | ||
</p> | ||
|
||
<p style={{ margin: 0 }}> | ||
To learn more about how to use components, usage, and design guidelines head over to the{' '} | ||
<ExternalLink href="https://p44design.systems">Design Systems Website</ExternalLink>. | ||
</p> |
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.
Oops, something went wrong.