Skip to content

Commit c5d20cd

Browse files
committed
Add no nav option, stub out docs pages
1 parent 7de6e52 commit c5d20cd

7 files changed

Lines changed: 35 additions & 19 deletions

File tree

src/components/layout.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { Twitter, GitHub } from 'react-feather'
88
import Nav from '../nav.mdx'
99
import SEO from './seo'
1010

11-
export default ({ children, _frontmatter: { title } = {} }) => (
11+
export default ({ children, _frontmatter: { title, noNav } = {} }) => (
1212
<Styled.root>
1313
<SEO title={title} />
1414
<Global
@@ -146,7 +146,7 @@ export default ({ children, _frontmatter: { title } = {} }) => (
146146
}
147147
}}
148148
>
149-
<Nav />
149+
{noNav ? null : <Nav />}
150150
</Box>
151151
<Box
152152
as="aside"

src/nav.mdx

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
- [Getting started](/getting-started)
2-
- [Blocks library](/blocks)
3-
- [Controls](/docs/controls)
1+
- [Getting started](/getting-started/)
2+
- [Blocks library](/blocks/)
3+
- [Controls](/docs/controls/)
44
- [Guides](/guides)
5-
- [Custom blocks](/guides/writing-a-custom-block)
6-
- [About](/about)
7-
- [Vision](/vision)
8-
- [Advanced](/advanced)
9-
- [How it works](/docs/advanced/how-it-works)
10-
- [Transforms](/docs/advanced/transforms)
11-
- [Queries](/docs/advanced/queries)
12-
- [Blocks docs generation](/docs/advanced/blocks-docs-generation)
5+
- [Custom blocks](/guides/writing-a-custom-block/)
6+
- [About](/about/)
7+
- [Vision](/vision/)
8+
- [Advanced](/advanced/)
9+
- [How it works](/docs/advanced/how-it-works/)
10+
- [Transforms](/docs/advanced/transforms/)
11+
- [Queries](/docs/advanced/queries/)
12+
- [Blocks docs generation](/docs/advanced/blocks-docs-generation/)

src/pages/docs/advanced/index.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export default Layout
1010
If you're a contributor and want to begin learning about
1111
the interals, you're in the right place.
1212

13-
- [How it works](/docs/advanced/how-it-works)
14-
- [Transforms](/docs/advanced/transforms)
15-
- [Queries](/docs/advanced/queries)
16-
- [Blocks docs generation](/docs/advanced/blocks-docs-generation)
13+
- [How it works](/docs/advanced/how-it-works/)
14+
- [Transforms](/docs/advanced/transforms/)
15+
- [Queries](/docs/advanced/queries/)
16+
- [Blocks docs generation](/docs/advanced/blocks-docs-generation/)

src/pages/docs/guides/index.mdx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
title: Guides
3+
---
4+
5+
# Guides
6+
7+
- [Write a custom block](/guides/write-a-custom-block/)

src/pages/docs/definitions/block.mdx renamed to src/pages/docs/guides/write-a-custom-block.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
---
2-
title: Block definition
2+
title: Write a custom block
33
---
44

55
import Layout from '../../../components/layout'
66
export default Layout
77

8-
# Block definition
8+
# Write a custom block
99

1010
A Block is a component that the editor can control. It's typically a
1111
component that has pre-made styles and accepts a few props for changing

src/pages/docs/index.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
22
title: Docs
3+
noNav: true
34
---
45

56
import Layout from '../../components/layout'

src/pages/getting-started.mdx

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
title: Getting started
3+
---
4+
5+
import Layout from '../components/layout'
6+
export default Layout
7+
8+
# Getting started

0 commit comments

Comments
 (0)