Skip to content

Commit

Permalink
Fix search sidebar width when no crate select is present
Browse files Browse the repository at this point in the history
  • Loading branch information
GuillaumeGomez committed May 2, 2019
1 parent 96d565b commit e2a2500
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/librustdoc/html/static/rustdoc.css
Original file line number Diff line number Diff line change
Expand Up @@ -658,18 +658,18 @@ a {
transition: border-color 300ms ease;
transition: border-radius 300ms ease-in-out;
transition: box-shadow 300ms ease-in-out;
width: calc(100% - 32px);
width: 100%;
}

#crate-search + .search-input {
border-radius: 0 1px 1px 0;
width: calc(100% - 32px);
}

.search-input:focus {
border-radius: 2px;
border: 0;
outline: 0;
box-shadow: 0 0 8px #078dd8;
}

.search-results .desc {
Expand Down
7 changes: 4 additions & 3 deletions src/librustdoc/html/static/themes/dark.css
Original file line number Diff line number Diff line change
Expand Up @@ -164,20 +164,21 @@ a.test-arrow {
color: #111;
background-color: #f0f0f0;
border-color: #000;
box-shadow: 0 0 0 1px #000, 0 0 0 2px transparent;
}

.search-input {
color: #111;
box-shadow: 0 0 0 1px #000, 0 0 0 2px transparent;
background-color: #f0f0f0;
box-shadow: 0 0 0 1px #000, 0 0 0 2px transparent;
}

.search-input:focus {
border-color: #008dfd;
}

#crate-search + .search-input {
box-shadow: 1px 0 0 1px #000, 0 0 0 2px transparent;
#crate-search + .search-input:focus {
box-shadow: 0 0 8px 4px #078dd8;
}

.module-item .stab {
Expand Down
8 changes: 4 additions & 4 deletions src/librustdoc/html/static/themes/light.css
Original file line number Diff line number Diff line change
Expand Up @@ -164,21 +164,21 @@ a.test-arrow {
color: #555;
background-color: white;
border-color: #e0e0e0;
box-shadow: 0px 0 0 1px #e0e0e0, 0 0 0 2px transparent;
box-shadow: 0 0 0 1px #e0e0e0, 0 0 0 2px transparent;
}

.search-input {
color: #555;
box-shadow: 0 0 0 1px #e0e0e0, 0 0 0 2px transparent;
background-color: white;
box-shadow: 0 0 0 1px #e0e0e0, 0 0 0 2px transparent;
}

.search-input:focus {
border-color: #66afe9;
}

#crate-search + .search-input {
box-shadow: 1px 0 0 1px #e0e0e0, 0 0 0 2px transparent;
#crate-search + .search-input:focus {
box-shadow: 0 0 8px #078dd8;
}

.module-item .stab {
Expand Down

0 comments on commit e2a2500

Please sign in to comment.