feat(v2): hide navbar on scroll (#2055)

* feat(v2): hide navbar on scroll

* Turn on hide option

* Refactor after review
This commit is contained in:
Alexey Pyltsyn 2019-12-12 15:19:37 +03:00 committed by Yangshun Tay
parent ace93c5a14
commit 5bfa5d6579
5 changed files with 92 additions and 4 deletions

View file

@ -90,6 +90,23 @@ module.exports = {
Outbound links automatically get `target="_blank" rel="noopener noreferrer"`.
### Auto-hide sticky navbar
You can enable this cool UI feature that automatically hides the navbar when a user starts scrolling down the page, and show it again when the user scrolls up.
```js
// docusaurus/config.js
module.exports = {
...
themeConfig: {
navbar: {
hideOnScroll: true,
},
...
},
}
```
## Footer
## `CodeBlock`