From 7629c02a9a3bd0bdaad1c26d774be754910ef033 Mon Sep 17 00:00:00 2001 From: Lunny Xiao Date: Fri, 7 Aug 2026 16:15:16 +0000 Subject: [PATCH] Fix missing scrollbar in API search results (#480) Fixes #257 Co-authored-by: Lunny Xiao --- src/css/custom.css | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/src/css/custom.css b/src/css/custom.css index 1956f9d6..43a3def9 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -118,6 +118,26 @@ height: calc(100vh - 70px) !important; } +/* Redoc's own `SearchResultsBox` styles are broken by a stray `}` after the + `background-color` interpolation, so every declaration after it (including + `max-height`) is dropped. Without a height limit the results box grows to the + full result list height, perfect-scrollbar sees no overflow and renders no + scrollbar, and the sidebar (overflow: hidden) clips the results. + Restore the intended styles until it is fixed upstream. + Upstream PR to fix this is: https://github.com/Redocly/redoc/pull/2819 +*/ +.redocusaurus [role='search'] [data-role='search:results'] { + min-height: 150px; + max-height: 250px; + line-height: 1.4; + font-size: 0.9em; +} + +.redocusaurus [role='search'] [data-role='search:results'] label { + padding-top: 6px; + padding-bottom: 6px; +} + .gt-hidden { display: none; }