From a3d1d904d58b5a24073041ac2cea46295e33d309 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?iBug=20=E2=99=A6?= Date: Wed, 3 Jun 2020 10:17:31 +0800 Subject: [PATCH] Make sticky sidebar live well with short content (#2514) --- CHANGELOG.md | 6 ++++++ _sass/minimal-mistakes/_sidebar.scss | 2 +- docs/_docs/18-history.md | 8 +++++++- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3666af4e..1dbcdd87 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +## Unreleased + +### Enhancements + +- Make sticky sidebar live well with short content. [#2514](https://github.com/mmistakes/minimal-mistakes/pull/2514) + ## [4.19.2](https://github.com/mmistakes/minimal-mistakes/releases/tag/4.19.2) ### Enhancements diff --git a/_sass/minimal-mistakes/_sidebar.scss b/_sass/minimal-mistakes/_sidebar.scss index 342d9241..cff28c8c 100644 --- a/_sass/minimal-mistakes/_sidebar.scss +++ b/_sass/minimal-mistakes/_sidebar.scss @@ -32,7 +32,7 @@ /* calculate height of nav list viewport height - nav height - masthead x-padding */ - height: calc(100vh - #{$nav-height} - 2em); + max-height: calc(100vh - #{$nav-height} - 2em); } } diff --git a/docs/_docs/18-history.md b/docs/_docs/18-history.md index a19aea84..ed8a5009 100644 --- a/docs/_docs/18-history.md +++ b/docs/_docs/18-history.md @@ -5,10 +5,16 @@ permalink: /docs/history/ excerpt: "Change log of enhancements and bug fixes made to the theme." sidebar: nav: docs -last_modified_at: 2020-05-01T11:53:42-04:00 +last_modified_at: 2020-05-02T00:54:04+08:00 toc: false --- +## Unreleased + +### Enhancements + +- Make sticky sidebar live well with short content. [#2514](https://github.com/mmistakes/minimal-mistakes/pull/2514) + ## [4.19.2](https://github.com/mmistakes/minimal-mistakes/releases/tag/4.19.2) ### Enhancements