2021-12-19 19:08:54 +01:00
|
|
|
import Popout from '../popout.js'
|
|
|
|
import Highlight from './highlight.js'
|
|
|
|
import YouTube from './youtube.js'
|
|
|
|
import DesignIterator from './design-iterator.js'
|
|
|
|
import Figure from './figure.js'
|
|
|
|
import ReadMore from './read-more.js'
|
2021-12-24 17:13:48 +01:00
|
|
|
import Example from './example/index.js'
|
|
|
|
import examples from '@freesewing/examples'
|
|
|
|
import rendertest from '@freesewing/rendertest'
|
|
|
|
import tutorial from '@freesewing/tutorial'
|
2021-12-19 19:08:54 +01:00
|
|
|
|
|
|
|
|
|
|
|
const mdxCustomComponents = {
|
|
|
|
// Custom components
|
|
|
|
DesignIterator,
|
2021-12-24 17:13:48 +01:00
|
|
|
Example: props => <Example
|
|
|
|
{...props}
|
|
|
|
patterns={{examples, rendertest, tutorial}}
|
|
|
|
>{props.children}</Example>,
|
2021-12-19 19:08:54 +01:00
|
|
|
Fixme: props => <Popout {...props} fixme />,
|
|
|
|
Link: props => <Popout {...props} link />,
|
|
|
|
Note: props => <Popout {...props} note />,
|
|
|
|
ReadMore,
|
|
|
|
Related: props => <Popout {...props} related />,
|
|
|
|
Tip: props => <Popout {...props} tip />,
|
|
|
|
Warning: props => <Popout {...props} warning />,
|
|
|
|
YouTube,
|
|
|
|
pre: props => <Highlight {...props} />,
|
|
|
|
//code: props => <Highlight {...props} tag='code'/>,
|
2021-12-22 18:16:26 +01:00
|
|
|
// TODO: Handle PatternPage component
|
|
|
|
PatternPage: props => (
|
|
|
|
<Popout {...props} fixme>
|
|
|
|
<p>
|
|
|
|
The PatternPage component is not yet implemented.
|
|
|
|
<br />
|
|
|
|
Below are the props:
|
|
|
|
</p>
|
|
|
|
<pre>{JSON.stringify(props, null ,2)}</pre>
|
|
|
|
</Popout>
|
|
|
|
),
|
|
|
|
|
2021-12-19 19:08:54 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
export default mdxCustomComponents
|
|
|
|
|