Navigation | Overlay |
---|---|
t Navigate files | h Toggle hits |
y Change url to tip of branch | m Toggle misses |
b / v Jump to prev/next hit line | p Toggle partial |
z / x Jump to prev/next missed or partial line | 1..9 Toggle flags |
shift + o Open current page in GitHub | a Toggle all on |
/ or ? Show keyboard shortcuts dialog | c Toggle context lines or commits |
1 |
import React from 'react' |
|
2 |
import * as Rsg from 'react-styleguidist' |
|
3 |
import PropTypes from 'prop-types' |
|
4 |
import Markdown from 'rsg-components/Markdown' |
|
5 |
import Styled from 'rsg-components/Styled' |
|
6 |
|
|
7 |
const styles = ({ fontFamily, fontSize, color }: Rsg.Theme) => ({ |
|
8 |
root: { |
|
9 |
display: 'block', |
|
10 |
color: color.light, |
|
11 |
fontFamily: fontFamily.base, |
|
12 |
fontSize: fontSize.small |
|
13 |
}
|
|
14 |
})
|
|
15 |
|
|
16 |
interface StyleguideFooterRendererProps { |
|
17 |
classes: Record<string, string> |
|
18 |
homepageUrl: string |
|
19 |
}
|
|
20 |
|
|
21 |
export const StyleguideFooterRenderer: React.FC<StyleguideFooterRendererProps> = ({ |
|
22 |
classes, |
|
23 |
homepageUrl
|
|
24 |
}) => { |
|
25 |
return ( |
|
26 |
<footer className={classes.root}> |
|
27 |
<Markdown text={`Generated with [Vue Styleguidist](${homepageUrl})`} /> |
|
28 |
</footer> |
|
29 |
)
|
|
30 |
}
|
|
31 |
|
|
32 |
StyleguideFooterRenderer.propTypes = { |
|
33 |
classes: PropTypes.objectOf(PropTypes.string.isRequired).isRequired, |
|
34 |
homepageUrl: PropTypes.string.isRequired |
|
35 |
}
|
|
36 |
|
|
37 |
export default Styled<StyleguideFooterRendererProps>(styles)(StyleguideFooterRenderer) |
Read our documentation on viewing source code .