From 7e7e7a03dc1d098664fda4449ea123efeb01c771 Mon Sep 17 00:00:00 2001 From: Simon Vieille Date: Tue, 22 Jun 2021 12:37:42 +0200 Subject: [PATCH] hide sidebar scrollbar when cursor is out --- assets/css/admin.scss | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/assets/css/admin.scss b/assets/css/admin.scss index 0d62ce8..668eeef 100644 --- a/assets/css/admin.scss +++ b/assets/css/admin.scss @@ -70,8 +70,8 @@ body { top: 0; bottom: 0; left: 0; - z-index: 100; /* Behind the navbar */ - padding: 71px 0 0; /* Height of navbar */ + z-index: 100; + padding: 71px 0 0; box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1); } @@ -81,7 +81,11 @@ body { height: calc(100vh - 71px); padding-top: .5rem; overflow-x: hidden; - overflow-y: auto; /* Scrollable contents if viewport is shorter than content. */ + overflow-y: hidden; + + &:hover { + overflow-y: auto; + } } @supports ((position: -webkit-sticky) or (position: sticky)) {