Skip to content

Commit

Permalink
Rollup merge of rust-lang#92610 - GuillaumeGomez:css-class-instead-of…
Browse files Browse the repository at this point in the history
…-inline-style, r=jsha

Create CSS class instead of using inline style for search results

I saw this change in the update you proposed in rust-lang#92404. :)

r? `@jsha`
  • Loading branch information
matthiaskrgr authored Jan 6, 2022
2 parents dc6079c + 26edfc9 commit 7b6c940
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions src/librustdoc/html/static/css/rustdoc.css
Original file line number Diff line number Diff line change
Expand Up @@ -545,6 +545,10 @@ nav.sub {
position: relative;
}

.search-loading {
text-align: center;
}

#results > table {
width: 100%;
table-layout: fixed;
Expand Down
4 changes: 2 additions & 2 deletions src/librustdoc/html/static/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -289,8 +289,8 @@ function hideThemeButtonState() {
var params = searchState.getQueryStringParams();
if (params.search !== undefined) {
var search = searchState.outputElement();
search.innerHTML = "<h3 style=\"text-align: center;\">" +
searchState.loadingText + "</h3>";
search.innerHTML = "<h3 class=\"search-loading\">" +
searchState.loadingText + "</h3>";
searchState.showResults(search);
loadSearch();
}
Expand Down

0 comments on commit 7b6c940

Please sign in to comment.