From 5afa52bc7dee683f25f437dddf338dbc6ad32eb8 Mon Sep 17 00:00:00 2001 From: Guillaume Gomez Date: Fri, 21 May 2021 16:39:03 +0200 Subject: [PATCH] Fix search results display --- src/librustdoc/html/static/rustdoc.css | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/src/librustdoc/html/static/rustdoc.css b/src/librustdoc/html/static/rustdoc.css index 6d581108836ef..173256e979e55 100644 --- a/src/librustdoc/html/static/rustdoc.css +++ b/src/librustdoc/html/static/rustdoc.css @@ -768,16 +768,29 @@ a { display: block; } -.search-results a { +.search-results > a { /* A little margin ensures the browser's outlining of focused links has room to display. */ margin-left: 2px; margin-right: 2px; display: block; } -.result-name { +.search-results > a > div { + display: flex; +} + +.search-results > a > div > div { + min-width: 50%; + max-width: 50%; width: 50%; - float: left; +} + +.result-name { + padding-right: 10px; +} + +.result-name > span { + display: inline-block; } tr.result span.primitive::after {