Skip to content

Commit d0a8b14

Browse files
authored
Make steps appear in TOC in Versioning and Product Switching pages (#224)
1 parent db21b66 commit d0a8b14

File tree

2 files changed

+16
-12
lines changed

2 files changed

+16
-12
lines changed

fern/products/docs/pages/navigation/products.mdx

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ Each product can contain its own distinct versions, tabs, sections, pages, and A
2626

2727
## Add Products to Your Docs
2828

29-
<Steps>
30-
### Define your products
29+
<Steps toc={true}>
30+
<Step title="Define your products">
3131

3232
Create a `products` folder inside of your `fern` folder. To specify a product's contents and navigational structure, add a `.yml` file to the `products` folder for each product.
3333
Make sure to include the `navigation` and `tabs` properties, if applicable.
@@ -83,8 +83,8 @@ tabs:
8383
```
8484
</CodeBlock>
8585
</CodeBlocks>
86-
87-
### Add your product configuration
86+
</Step>
87+
<Step title="Add your product configuration">
8888
8989
To define a product, add an item to the `products` list in `docs.yml`, specifying the `display-name` and `path`.
9090

@@ -110,8 +110,8 @@ products:
110110
subtitle: Product B subtitle # optional
111111
```
112112
</CodeBlock>
113-
114-
### Add versioning to your products (optional)
113+
</Step>
114+
<Step title="Add versioning to your products (optional)">
115115

116116
You can optionally add versions to a product. Versioned and unversioned products can live next to each other in your site. Each version of a single product has its own `yml` file.
117117

@@ -165,9 +165,11 @@ products:
165165
</CodeBlock>
166166

167167
For more information on setting up versioned products, follow our [versioning docs](/docs/navigation/versions).
168+
</Step>
169+
<Step title="Remove extra navigation from docs.yml">
168170

169-
### Remove extra `navigation` from `docs.yml`
170171
If your `docs.yml` file includes a `navigation` field or a `tabs` field, be sure to remove. Those fields should now belong in the product-specific `.yml` files.
172+
</Step>
171173
</Steps>
172174

173175
## Customizing Selector Styling

fern/products/docs/pages/navigation/versions.mdx

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ Each version of your docs can contain its own distinct tabs, sections, pages, an
1111

1212
**To add versions to your docs:**
1313

14-
<Steps>
15-
### Define your versions
14+
<Steps toc={true}>
15+
<Step title="Define your versions">
1616

1717
Create a `versions` folder inside of your `fern` folder. To specify the contents of each version, add a `.yml` file to the `versions` folder to define the navigational structure of that version. Make sure to include the `navigation` and `tabs` properties, if applicable.
1818

@@ -79,8 +79,8 @@ tabs:
7979
</CodeBlocks>
8080
8181
<Note>You can also have multiple products, some versioned and some unversioned. For more information on setting up multiple products, follow our [product switching docs](/docs/navigation/products).</Note>
82-
83-
### Add your version configuration
82+
</Step>
83+
<Step title="Add your version configuration">
8484
8585
To define a version, in `docs.yml`, add an item to the `versions` list, specifying the `display-name` and `path`.
8686

@@ -104,7 +104,9 @@ versions:
104104
path: ./versions/v2-1.yml
105105
```
106106
</CodeBlock>
107+
</Step>
108+
<Step title="Remove extra navigation from docs.yml">
107109

108-
### Remove extra `navigation` from `docs.yml`
109110
If your `docs.yml` file includes a `navigation` field or a `tabs` field, be sure to remove. Those fields should now belong in the version-specific `.yml` files.
111+
</Step>
110112
</Steps>

0 commit comments

Comments
 (0)