From 4239d3fd08666479772d19b68c98c90a1c6ddeef Mon Sep 17 00:00:00 2001 From: jakubabrzy Date: Tue, 19 Sep 2023 15:27:30 +0200 Subject: [PATCH] search improvement on mobile --- src/css/custom.css | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/src/css/custom.css b/src/css/custom.css index 5aab7356..fd48dc58 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -43,9 +43,33 @@ body { display: none; } +html[data-theme="light"] .navbar__search { + color: theme("colors.gray.700"); +} + +html[data-theme="dark"] .navbar__search { + color: theme("colors.gray.200"); +} + /* TODO: Replace with Algolia search icon */ .navbar__search-input { - @apply w-32 lg:w-48 h-10; + @apply w-32 lg:w-48 h-10 xs:pl-8; + + &:focus { + @apply xs:pl-9; + } + + &:not(:placeholder-shown) { + @apply xs:pl-9 pr-8; + + @media (max-width: 576px) { + width: 8rem !important; + } + } +} + +button[class^="searchClearButton"] { + display: block !important; } div[class^="searchHintContainer"] {