small fixes
This commit is contained in:
parent
d0ae5c0466
commit
a71e15aba5
|
@ -9,10 +9,26 @@
|
||||||
background-attachment: fixed;
|
background-attachment: fixed;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: flex-end;
|
||||||
align-items: center;
|
.title_index {
|
||||||
h1 {
|
|
||||||
word-break: break-all;
|
word-break: break-all;
|
||||||
|
align-self: center;
|
||||||
|
justify-self: center;
|
||||||
|
color: var(--text-main);
|
||||||
|
background: var(--background-body);
|
||||||
|
border-radius: 10px;
|
||||||
|
text-shadow: 0px 4px 3px rgba(0,0,0,0.4),
|
||||||
|
0px 8px 13px rgba(0,0,0,0.1),
|
||||||
|
0px 18px 23px rgba(0,0,0,0.1);
|
||||||
|
}
|
||||||
|
.title {
|
||||||
|
background: var(--background-body);
|
||||||
|
word-break: break-all;
|
||||||
|
color: var(--text-main);
|
||||||
|
margin-bottom: 0;
|
||||||
|
text-shadow: 0px 4px 3px rgba(0,0,0,0.4),
|
||||||
|
0px 8px 13px rgba(0,0,0,0.1),
|
||||||
|
0px 18px 23px rgba(0,0,0,0.1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -17,13 +17,17 @@
|
||||||
{{ $what = .File.ContentBaseName }}
|
{{ $what = .File.ContentBaseName }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
{{ $title_class := safeCSS "title" }}
|
||||||
|
{{ if .IsHome }}
|
||||||
|
{{ $title_class = safeCSS "title_index" }}
|
||||||
|
{{ end }}
|
||||||
{{ $banner := printf "/images/banner/%s*" $what }}
|
{{ $banner := printf "/images/banner/%s*" $what }}
|
||||||
{{ if resources.GetMatch $banner }}
|
{{ if resources.GetMatch $banner }}
|
||||||
{{ $img = (resources.GetMatch $banner).Fill $fill }}
|
{{ $img = (resources.GetMatch $banner).Fill $fill }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ if and (resources.GetMatch $banner) (ne .Params.banner false) }}
|
{{ if and (resources.GetMatch $banner) (ne .Params.banner false) }}
|
||||||
<div style="background-image: url({{- $img.Permalink -}})" class="banner">
|
<div style="background-image: url({{- $img.Permalink -}})" class="banner">
|
||||||
<h1>{{ $title }}</h1>
|
<h1 class="{{ $title_class }}">{{ $title }}</h1>
|
||||||
{{ if eq hugo.Environment "development" }}
|
{{ if eq hugo.Environment "development" }}
|
||||||
<div>
|
<div>
|
||||||
{{ $w := (resources.GetMatch $banner).Width }}
|
{{ $w := (resources.GetMatch $banner).Width }}
|
||||||
|
@ -52,7 +56,7 @@
|
||||||
{{ else if and (.Resources.Match "banner*") (ne .Params.banner false) }}
|
{{ else if and (.Resources.Match "banner*") (ne .Params.banner false) }}
|
||||||
{{ $img = (.Resources.GetMatch "banner*").Fill $fill }}
|
{{ $img = (.Resources.GetMatch "banner*").Fill $fill }}
|
||||||
<div style="background-image:url({{- $img.Permalink -}})" class="banner">
|
<div style="background-image:url({{- $img.Permalink -}})" class="banner">
|
||||||
<h1>{{ $title }}</h1>
|
<h1 class="{{ $title_class }}">{{ $title }}</h1>
|
||||||
{{ if eq hugo.Environment "development" }}
|
{{ if eq hugo.Environment "development" }}
|
||||||
<div>
|
<div>
|
||||||
{{ $w := (index (.Resources.Match "banner*") 0).Width }}
|
{{ $w := (index (.Resources.Match "banner*") 0).Width }}
|
||||||
|
@ -81,7 +85,7 @@
|
||||||
{{ else if and (.Resources.ByType "image") (ne .Params.banner false) }}
|
{{ else if and (.Resources.ByType "image") (ne .Params.banner false) }}
|
||||||
{{ $img = (index (.Resources.ByType "image") 0).Fill $fill }}
|
{{ $img = (index (.Resources.ByType "image") 0).Fill $fill }}
|
||||||
<div style="background-image: url({{- $img.Permalink -}})" class="banner">
|
<div style="background-image: url({{- $img.Permalink -}})" class="banner">
|
||||||
<h1>{{ $title }}</h1>
|
<h1 class="{{ $title_class }}">{{ $title }}</h1>
|
||||||
{{ if eq hugo.Environment "development" }}
|
{{ if eq hugo.Environment "development" }}
|
||||||
<div>
|
<div>
|
||||||
{{ $w := (index (.Resources.ByType "image") 0).Width }}
|
{{ $w := (index (.Resources.ByType "image") 0).Width }}
|
||||||
|
@ -109,7 +113,7 @@
|
||||||
</div>
|
</div>
|
||||||
{{ else }}
|
{{ else }}
|
||||||
<div class="banner">
|
<div class="banner">
|
||||||
<h1>{{ $title }}</h1>
|
<h1 class="{{ $title_class }}">{{ $title }}</h1>
|
||||||
{{ if eq hugo.Environment "development" }}
|
{{ if eq hugo.Environment "development" }}
|
||||||
<p>
|
<p>
|
||||||
assets/images/banner/{{ $what -}}.* missing..<br>
|
assets/images/banner/{{ $what -}}.* missing..<br>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user