Skip to content

Commit 18b4d11

Browse files
bjorn3anp
authored andcommitted
Make menu fixed on larger viewports (#100)
1 parent f7bdb29 commit 18b4d11

File tree

2 files changed

+58
-24
lines changed

2 files changed

+58
-24
lines changed

front/app/styles/app.css

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,39 @@
1515
margin: 0.2%;
1616
overflow: hidden;
1717
}
18+
19+
nav {
20+
position: fixed !important;
21+
top: 0px;
22+
left: 0px;
23+
right: 0px;
24+
25+
background: white;
26+
z-index: 1000;
27+
28+
font-size: 2.4rem;
29+
line-height: 1.5;
30+
letter-spacing: -.05rem;
31+
}
32+
33+
nav h4 {
34+
margin-bottom: 0px;
35+
}
36+
37+
#title{
38+
margin-bottom: 0px;
39+
}
40+
41+
div.container {
42+
margin-top: 150px;
43+
}
44+
45+
@media all and (max-width: 680px) {
46+
nav {
47+
position: unset !important;
48+
}
49+
50+
div.container {
51+
margin-top: 0px;
52+
}
53+
}

front/app/templates/application.hbs

Lines changed: 22 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,32 @@
11
<a href="https://github.com/dikaiosune/rust-dashboard" target="_blank">
2-
<img style="position: absolute; top: 0; left: 0; border: 0;"
2+
<img style="position: absolute; top: 0; left: 0; border: 0; z-index: 2000"
33
alt="Fork me on GitHub"
44
src="https://s3.amazonaws.com/github/ribbons/forkme_left_darkblue_121621.png">
55
</a>
66

7-
<div class="container">
8-
7+
<nav class="container">
98
<h2 id="title">Rust Language Project Metrics</h2>
9+
10+
{{#link-to 'summary'}}Home{{/link-to}}
11+
&bull;
12+
{{#link-to 'fcp'}}FCPs{{/link-to}}
13+
&bull;
14+
{{#link-to 'releases'}}Nightlies{{/link-to}}
15+
&bull;
16+
{{#link-to 'issues'}}Issues{{/link-to}}
17+
&bull;
18+
{{#link-to 'prs'}}Pull Requests{{/link-to}}
19+
&bull;
20+
{{#link-to 'hot-issues'}}"Hot" Issues{{/link-to}}
21+
&bull;
22+
{{#link-to 'buildbots'}}Buildbots{{/link-to}}
23+
&bull;
24+
{{#link-to 'triage'}}Triage{{/link-to}}
25+
&bull;
26+
{{#link-to 'links'}}Useful Links{{/link-to}}
27+
</nav>
1028

11-
<h4>Sections:</h4>
12-
<h5>
13-
{{#link-to 'summary'}}Home{{/link-to}}
14-
&bull;
15-
{{#link-to 'fcp'}}FCPs{{/link-to}}
16-
&bull;
17-
{{#link-to 'releases'}}Nightlies{{/link-to}}
18-
&bull;
19-
{{#link-to 'issues'}}Issues{{/link-to}}
20-
&bull;
21-
{{#link-to 'prs'}}Pull Requests{{/link-to}}
22-
&bull;
23-
{{#link-to 'hot-issues'}}"Hot" Issues{{/link-to}}
24-
&bull;
25-
{{#link-to 'buildbots'}}Buildbots{{/link-to}}
26-
&bull;
27-
{{#link-to 'triage'}}Triage{{/link-to}}
28-
&bull;
29-
{{#link-to 'links'}}Useful Links{{/link-to}}
30-
</h5>
31-
<hr/>
29+
<div class="container">
3230

3331
{{outlet}}
3432

0 commit comments

Comments
 (0)