Skip to content

Commit d9cf1f2

Browse files
authored
Rollup merge of #78084 - GuillaumeGomez:improve-mobile-display, r=jyn514,Nemo157
Greatly improve display for small mobile devices screens Fixes #78014. The biggest change being the "search bar". Instead of having everything on one line, I decided to move the search input on its own: ![Screenshot from 2020-10-18 21-54-26](https://user-images.githubusercontent.com/3050060/96378530-c863a800-118c-11eb-8e82-a43fce312b5b.png) Another change is that now, we "break words" in the listing so that they don't grow too big: ![Screenshot from 2020-10-18 21-57-17](https://user-images.githubusercontent.com/3050060/96378555-ffd25480-118c-11eb-8a71-8f116c7edd93.png) r? @jyn514
2 parents 004a3aa + 4e2c59a commit d9cf1f2

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

src/librustdoc/html/static/rustdoc.css

+35
Original file line numberDiff line numberDiff line change
@@ -1568,6 +1568,41 @@ h4 > .notable-traits {
15681568
#titles, #titles > div {
15691569
height: 73px;
15701570
}
1571+
1572+
#main > table:not(.table-display) td {
1573+
word-break: break-word;
1574+
min-width: 10%;
1575+
}
1576+
1577+
.search-container > div {
1578+
display: block;
1579+
width: calc(100% - 37px);
1580+
}
1581+
1582+
#crate-search {
1583+
width: 100%;
1584+
border-radius: 4px;
1585+
border: 0;
1586+
}
1587+
1588+
#crate-search + .search-input {
1589+
width: calc(100% + 71px);
1590+
margin-left: -36px;
1591+
}
1592+
1593+
#theme-picker, #settings-menu {
1594+
padding: 5px;
1595+
width: 31px;
1596+
height: 31px;
1597+
}
1598+
1599+
#theme-picker {
1600+
margin-top: -2px;
1601+
}
1602+
1603+
#settings-menu {
1604+
top: 7px;
1605+
}
15711606
}
15721607

15731608
h3.notable {

0 commit comments

Comments
 (0)