From af9ec90236a7ba244af4a192ee24be3956d48a72 Mon Sep 17 00:00:00 2001 From: Rob Winch Date: Thu, 27 Apr 2023 17:11:54 -0500 Subject: [PATCH] Explicit Docsearch variables --- src/css/vendor/docsearch.css | 39 ++++++++++++++++++++++++++++++++++-- 1 file changed, 37 insertions(+), 2 deletions(-) diff --git a/src/css/vendor/docsearch.css b/src/css/vendor/docsearch.css index 886d280..c0e896e 100644 --- a/src/css/vendor/docsearch.css +++ b/src/css/vendor/docsearch.css @@ -30,7 +30,42 @@ font-size: 14px; } -:root, -html.dark-theme { +/* Variables */ + +:root { + --docsearch-primary-color: var(--link-font-color: #086dc3); + --docsearch-searchbox-background: var(--body-background-color); +} + +/* Darkmode */ + +html.dark-theme, +html[data-theme='dark'] { + --docsearch-text-color: rgb(245, 246, 247); + --docsearch-container-background: rgba(9, 10, 17, 0.8); + --docsearch-modal-background: rgb(21, 23, 42); + --docsearch-modal-shadow: + inset 1px 1px 0 0 rgb(44, 46, 64), + 0 3px 8px 0 rgb(0, 3, 9); --docsearch-searchbox-background: var(--body-background-color); + --docsearch-searchbox-focus-background: var(--panel-background-color); + --docsearch-hit-color: rgb(190, 195, 201); + --docsearch-hit-shadow: none; + --docsearch-hit-background: rgb(9, 10, 17); + --docsearch-key-gradient: + linear-gradient( + -26.5deg, + rgb(86, 88, 114) 0%, + rgb(49, 53, 91) 100% + ); + --docsearch-key-shadow: + inset 0 -2px 0 0 rgb(40, 45, 85), + inset 0 0 1px 1px rgb(81, 87, 125), + 0 2px 2px 0 rgba(3, 4, 9, 0.3); + --docsearch-footer-background: rgb(30, 33, 54); + --docsearch-footer-shadow: + inset 0 1px 0 0 rgba(73, 76, 106, 0.5), + 0 -4px 8px 0 rgba(0, 0, 0, 0.2); + --docsearch-logo-color: rgb(255, 255, 255); + --docsearch-muted-color: rgb(127, 132, 151); }