From c1aa4b4d2ddf9775270bce00fbc4510f914f9cdf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mikkel=20T=C3=B8nder?= <71938724+Mikkel-T@users.noreply.github.com> Date: Fri, 1 Oct 2021 21:09:10 +0200 Subject: [PATCH] docs: Improvements to language select and theme toggle (#1473) --- docs/src/components/Header/LanguageSelect.css | 28 +++---------------- .../RightSidebar/ThemeToggleButton.css | 1 + 2 files changed, 5 insertions(+), 24 deletions(-) diff --git a/docs/src/components/Header/LanguageSelect.css b/docs/src/components/Header/LanguageSelect.css index 5411e50dc..f7b42c1e7 100644 --- a/docs/src/components/Header/LanguageSelect.css +++ b/docs/src/components/Header/LanguageSelect.css @@ -20,6 +20,10 @@ transition-timing-function: ease-out; transition-duration: 0.2s; transition-property: border-color, color; + background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e"); + background-position: 97%; + background-repeat: no-repeat; + background-size: 1.5em 1.5em; -webkit-font-smoothing: antialiased; -webkit-appearance: none; } @@ -39,32 +43,8 @@ pointer-events: none; } -.language-select-wrapper::before, -.language-select-wrapper::after { - position: absolute; - top: 18px; - content: ''; - width: 8px; - height: 1px; - background: var(--theme-text-light); -} -.language-select-wrapper::before { - right: 10px; - transform: rotate(45deg); -} -.language-select-wrapper::after { - right: 5px; - transform: rotate(-45deg); -} - @media (min-width: 50em) { .language-select { width: 100%; } - .language-select-wrapper::before { - right: 16px; - } - .language-select-wrapper::after { - right: 11px; - } } diff --git a/docs/src/components/RightSidebar/ThemeToggleButton.css b/docs/src/components/RightSidebar/ThemeToggleButton.css index 7de231d1b..b0f1b535b 100644 --- a/docs/src/components/RightSidebar/ThemeToggleButton.css +++ b/docs/src/components/RightSidebar/ThemeToggleButton.css @@ -19,6 +19,7 @@ align-items: center; justify-content: center; opacity: 0.5; + cursor: pointer; } .theme-toggle .checked {