From 26de844a1981ff5abfc1a57893cedb2eb4b7a33e Mon Sep 17 00:00:00 2001 From: Alex Shpak Date: Wed, 18 Aug 2021 11:12:50 +0200 Subject: #343, #165: Move lang selector to left menu --- assets/_main.scss | 67 +++++++++---------------------------------------------- 1 file changed, 10 insertions(+), 57 deletions(-) (limited to 'assets') diff --git a/assets/_main.scss b/assets/_main.scss index 4e96316..b960941 100644 --- a/assets/_main.scss +++ b/assets/_main.scss @@ -86,11 +86,11 @@ ul.pagination { .book-brand { margin-top: 0; + margin-bottom: $padding-16; img { height: 1.5em; - width: auto; - vertical-align: middle; + width: 1.5em; margin-inline-end: $padding-8; } } @@ -147,11 +147,7 @@ body[dir="rtl"] .book-menu { } .book-section-flat { - margin-bottom: $padding-16 * 2; - - &:not(:first-child) { - margin-top: $padding-16 * 2; - } + margin: $padding-16 * 2 0; > a, > span, @@ -266,62 +262,19 @@ body[dir="rtl"] .book-menu { } .book-languages { - position: relative; - overflow: visible; - - padding: $padding-16; - margin: -$padding-16; - - ul { - margin: 0; - padding: 0; - list-style: none; - - li { - white-space: nowrap; - cursor: pointer; - } - } + margin-block-end: $padding-16 * 2; - &:hover, - &:focus, - &:focus-within { - .book-languages-list { - display: block; - } + .book-icon { + height: 1em; + width: 1em; + margin-inline-end: .5em; } - .book-languages-list { - display: none; - - position: absolute; - bottom: 100%; - left: 0; - padding: $padding-8 0; - - background: var(--body-background); - box-shadow: 0 0 $padding-4 rgba(0, 0, 0, 0.1); - - li img { - opacity: 0.25; - } - - li.active img, - li:hover img { - opacity: initial; - } - - a { - color: inherit; - padding: $padding-8 $padding-16; - } + ul { + padding-inline-start: 1.5em; } } -.book-home { - padding: $padding-16; -} - // Responsive styles .book-menu-content, .book-toc-content, -- cgit v1.2.3