Squashed: fix atom feed and mobile nav

This commit is contained in:
Robert Kaussow 2018-10-13 03:32:08 +02:00
parent 7f757fbf87
commit 8f3b4c92eb
7 changed files with 45 additions and 9 deletions

View File

@ -9,11 +9,11 @@
<span class="site-header__description">Linux und Open Source Blog</span>
</div>
<div class="site-nav__mobile" onclick="toogleClass('default-menu');">
<span class="site-nav__button">Menu</span>
<div class="site-nav__mobile">
<span class="site-nav__button" onclick="toogleClass('js-site-nav');">Menu</span>
</div>
<nav class="site-nav">
<nav id="js-site-nav" class="site-nav">
<ul class="site-nav__list">
{{ $currentPage := .Permalink }}
<li><a class="site-nav__button {{- if eq $currentPage (printf "%s" .Site.BaseURL) }} is-active {{- end }}" href="{{ .Site.BaseURL }}">Blog</a></li>
@ -35,5 +35,11 @@
<link rel="stylesheet" type="text/css" href="{{ "default.min.css" | relURL }}" />
<link rel="stylesheet" type="text/css" href="{{ "_tool/fontawesome/css/all.min.css" | relURL }}" />
<script type="text/javascript">
function toogleClass(id) {
document.getElementById(id).classList.toggle("is-visible");
}
</script>
</body>
</html>

View File

@ -8,7 +8,8 @@
<name>{{.}}</name>{{ with $.Site.Author.email }}
<email>{{.}}</email>{{end}}
</author>{{end}}
<generator>Hugo -- gohugo.io</generator>{{ range .Data.Pages }}
<generator>Hugo -- gohugo.io</generator>
{{ range where .Pages "Type" "post" }}
<entry>
{{ `<title type="html"><![CDATA[` | safeHTML }}{{ .Title }}]]></title>
<link href="{{ .Permalink }}"/>
@ -19,5 +20,6 @@
<published>{{ .Date.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</published>
<updated>{{ .Lastmod.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</updated>
{{ `<content type="html"><![CDATA[` | safeHTML }}{{ .Content }}]]></content>
</entry>{{ end }}
</entry>
{{ end }}
</feed>

View File

@ -8,7 +8,8 @@
<name>{{.}}</name>{{ with $.Site.Author.email }}
<email>{{.}}</email>{{end}}
</author>{{end}}
<generator>Hugo -- gohugo.io</generator>{{ range .Data.Pages }}
<generator>Hugo -- gohugo.io</generator>
{{ range where .Pages "Type" "post" }}
<entry>
{{ `<title type="html"><![CDATA[` | safeHTML }}{{ .Title }}]]></title>
<link href="{{ .Permalink }}"/>
@ -19,5 +20,6 @@
<published>{{ .Date.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</published>
<updated>{{ .Lastmod.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</updated>
{{ `<content type="html"><![CDATA[` | safeHTML }}{{ .Content }}]]></content>
</entry>{{ end }}
</entry>
{{ end }}
</feed>

View File

@ -288,7 +288,10 @@ all and (max-width: 900px){
@media all and (max-device-width: 710px), all and (max-width: 710px){
.site-nav {
/* display: none; */
display: none;
}
.site-nav.is-visible {
display: block;
}
.site-nav__mobile,
.site-footer__button {

View File

@ -8,3 +8,12 @@
color:#FFFFFF;
text-decoration:none;
}
.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6 {
font-weight: normal;
}

View File

@ -268,6 +268,12 @@ all and (max-width:900px) {
}
@media all and (max-device-width:710px),
all and (max-width:710px) {
.site-nav {
display: none
}
.site-nav.is-visible {
display: block
}
.site-footer__button,
.site-nav__mobile {
display: block
@ -584,4 +590,12 @@ all and (max-width:710px) {
background: #0a539a;
color: #fff;
text-decoration: none
}
.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6 {
font-weight: 400
}

File diff suppressed because one or more lines are too long