Skip to content

Commit 7f90fb9

Browse files
Revert "fix: issue #212 - problem width page width on mobile devices" because it breaks all other usages of the container class, e.g. the navigation bar. Instead, prevent the browser from calculating the minimum width.
1 parent ea935e9 commit 7f90fb9

File tree

3 files changed

+40
-35
lines changed

3 files changed

+40
-35
lines changed

src/css/base.css

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -118,12 +118,10 @@ body ::-webkit-scrollbar-thumb {
118118
background-color: var(--scrollbar-thumb-color);
119119
}
120120

121-
@media screen and (min-width: 1024px) {
122-
.container {
123-
display: flex;
124-
position: relative;
125-
width: 100%;
126-
max-width: 1280px;
127-
margin: 0 auto;
128-
}
121+
.container {
122+
display: flex;
123+
position: relative;
124+
width: 100%;
125+
max-width: 1280px;
126+
margin: 0 auto;
129127
}

src/css/landing.css

Lines changed: 30 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,43 @@
1-
@media screen and (min-width: 768px) {
2-
.boxes {
3-
display: flex;
4-
flex-wrap: wrap;
5-
justify-content: space-between;
6-
}
1+
.boxes {
2+
display: flex;
3+
flex-wrap: wrap;
4+
justify-content: space-between;
5+
}
76

8-
.box {
9-
flex: 0 30%;
10-
min-height: 200px;
11-
margin-bottom: 2%; /* (200-32*3)/2 */
12-
}
7+
.box {
8+
flex: 0 30%;
9+
min-height: 200px;
10+
margin-bottom: 2%; /* (200-32*3)/2 */
11+
}
1312

14-
.boxes.two-column .box {
15-
flex: 0 48%;
16-
}
13+
.boxes.two-column .box {
14+
flex: 0 48%;
15+
}
1716

18-
.box h3 {
19-
display: inline-block;
20-
}
17+
.box h3 {
18+
display: inline-block;
19+
}
2120

22-
.box div {
23-
display: inline-block;
24-
}
21+
.box div {
22+
display: inline-block;
23+
}
2524

26-
.box p {
27-
display: inline-block;
28-
}
25+
.box p {
26+
display: inline-block;
27+
}
2928

30-
.box .admonitionblock {
31-
margin-top: 2.8rem;
32-
}
29+
.box .admonitionblock {
30+
margin-top: 2.8rem;
3331
}
3432

3533
@media screen and (max-width: 1023.5px) {
3634
.box {
3735
flex: 0 47% !important;
3836
}
3937
}
38+
39+
@media screen and (max-width: 768px) {
40+
.box {
41+
flex: 0 100% !important;
42+
}
43+
}

src/css/main.css

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
main {
2+
min-width: 0; /* min-width: 0 required for flexbox to constrain overflowing elements */
3+
}
4+
15
@media screen and (max-width: 1023.5px) {
26
aside.toc.sidebar {
37
display: none;
@@ -11,7 +15,6 @@
1115
@media screen and (min-width: 1024px) {
1216
main {
1317
flex: auto;
14-
min-width: 0; /* min-width: 0 required for flexbox to constrain overflowing elements */
1518
}
1619

1720
main > .content {

0 commit comments

Comments
 (0)