Skip to content

Commit 82725ba

Browse files
shrpnephated
authored andcommitted
Fix responsive navigation on small widths (gulpjs#72)
1 parent 49d8b35 commit 82725ba

File tree

3 files changed

+51
-23
lines changed

3 files changed

+51
-23
lines changed

css/devices.css

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,16 @@
4040
}
4141
@media screen and (max-width: 900px) {
4242
.centerdevices .computerwrapper .computer {
43-
margin: auto;
4443
width: 100%;
4544
padding: 20px;
4645
height: calc((100vw - 80px) * .75);
4746
}
4847
}
48+
@media screen and (max-width: 370px) {
49+
.centerdevices .computerwrapper .computer {
50+
padding: 15px;
51+
}
52+
}
4953
.centerdevices .iphoneipad2 .mask {
5054
height: 100%;
5155
width: 100%;

css/main.css

Lines changed: 45 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -81,26 +81,6 @@ div.logo-cli {
8181
p.paragraph {
8282
color: rgba(0, 0, 0, .5);
8383
}
84-
.logo {
85-
font-size: 30px;
86-
line-height: 30px;
87-
font-weight: 900;
88-
}
89-
@media (max-width: 420px) {
90-
.logo {
91-
font-size: 22px;
92-
}
93-
}
94-
.nav-link2,
95-
.nav-link {
96-
text-decoration: none;
97-
font-size: 18px;
98-
line-height: 30px;
99-
color: inherit;
100-
}
101-
.nav-link:not(:first-of-type) {
102-
margin-left: 20px;
103-
}
10484
.text-center {
10585
text-align: center;
10686
}
@@ -276,6 +256,40 @@ p.paragraph {
276256
.sidedevices {
277257
position: relative;
278258
}
259+
260+
/*elements*/
261+
.logo {
262+
font-size: 30px;
263+
line-height: 30px;
264+
font-weight: 900;
265+
}
266+
@media (max-width: 420px) {
267+
.logo {
268+
font-size: 22px;
269+
}
270+
}
271+
.nav-link {
272+
text-decoration: none;
273+
font-size: 18px;
274+
line-height: 30px;
275+
color: inherit;
276+
}
277+
.nav-link:not(:first-of-type) {
278+
margin-left: 20px;
279+
}
280+
@media (max-width: 370px) {
281+
.nav {
282+
padding: 0 10px;
283+
}
284+
}
285+
@media (max-width: 350px) {
286+
.nav {
287+
padding: 0;
288+
}
289+
.nav-link {
290+
font-size: 16px;
291+
}
292+
}
279293
.header {
280294
padding: 20px 0 90px 0;
281295
overflow: hidden;
@@ -291,6 +305,16 @@ p.paragraph {
291305
margin-top: 60px;
292306
}
293307
}
308+
@media (max-width: 500px) {
309+
.header .heading {
310+
margin-top: 50px;
311+
}
312+
}
313+
@media (max-width: 350px) {
314+
.header .editor-window code span {
315+
font-size: 14px;
316+
}
317+
}
294318
.ctas-button,
295319
.ctas-button-2 {
296320
display: inline-block;
@@ -358,7 +382,7 @@ p.paragraph {
358382
@media (max-width: 420px) {
359383
.editor-window code,
360384
.editor-window code span {
361-
font-size: 13pt;
385+
font-size: 16px;
362386
}
363387
}
364388
.editor-window pre {

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
<a class="logo mobile-hide">
1818
<img class="logo-img" src="img/gulp-white-text.svg">
1919
</a>
20-
<div class="mobile-col-12 spread">
20+
<div class="nav mobile-col-12 spread">
2121
<a class="nav-link" href="https://github.com/gulpjs/gulp/blob/master/docs/API.md">Docs</a>
2222
<a class="nav-link" href="http://gulpjs.com/plugins">Plugins</a>
2323
<a class="nav-link" href="https://twitter.com/gulpjs">Twitter</a>

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy