Browse Source

better design for single template

new-gallery
max.mehl 2 years ago
parent
commit
c32b0237a7
Signed by: mxmehl GPG Key ID: 2704E4AB371E2E92
  1. 37
      themes/hugo-sustain/layouts/_default/single.html
  2. 5
      themes/hugo-sustain/static/css/custom.css

37
themes/hugo-sustain/layouts/_default/single.html

@ -8,15 +8,34 @@
<div class="container {{ replace (.LinkTitle | lower) " " "_" }}"> <!-- add link title add class -->
<h1>{{ .Title }}</h1>
{{ if ne .Params.page true }}
<div>
<p class="categories">
{{ .Date.Format "2 January 2006" }}
&nbsp;&nbsp;
{{ range .Params.tags }}
<a class="label label-success" href="/tags/{{ lower . }}">{{ . }}</a>
{{ end }}
</p>
</div>
<div class="metadata-page">
<div class="row vertical-align">
<div class="col-xs-3 col-md-2 text-right">
<em>Date:</em>
</div>
<div class="col-xs-9 col-md-10">
{{ .Date.Format "2 January 2006" }}
</div>
</div>
<div class="row vertical-align">
<div class="col-xs-3 col-md-2 text-right">
<em>Tags:</em>
</div>
<div class="col-xs-9 col-md-10">
{{ range .Params.tags }}
<a class="label label-success" href="/tags/{{ lower . }}">{{ . }}</a>
{{- end -}}
</div>
</div>
<div class="row vertical-align">
<div class="col-xs-3 col-md-2 text-right">
<em>RSS Feed:</em>
</div>
<div class="col-xs-9 col-md-10">
<span class="article-rss"><a class="label label-rss" href="/index.xml" title="RSS Feed"><i class="fa fa-rss" aria-hidden="true"></i> Subscribe</a></span>
</div>
</div>
</div>
{{ end }}
<div class="panel panel-default">
<div class="panel-body">

5
themes/hugo-sustain/static/css/custom.css

@ -21,9 +21,12 @@ div.footer {
color: #FFF;
}
.container a.label-rss {
background-color: rgba(242, 101, 34, 0.9);
background-color: rgba(242, 101, 34, 0.8);
color: #FFF;
}
.container a.label-rss:hover {
background-color: rgba(242, 101, 34, 1);
}
.container h1 {
font-weight: bold;
color: #0D76EC;

Loading…
Cancel
Save