CHANGE image handling, ADD partials to reuse structure, REFACTOR
This commit is contained in:
parent
1265491dee
commit
01dcf04b8a
36 changed files with 1181 additions and 864 deletions
|
@ -1,18 +1,15 @@
|
|||
{{ define "main" }}
|
||||
{{ with .Params.image }}
|
||||
{{ if .url }}
|
||||
<img class="coverimage" src="{{ .url }}" alt="{{ .alt }}" />
|
||||
{{ else }}
|
||||
<img class="coverimage" src="{{ . }}" />
|
||||
{{ end }}
|
||||
{{ with .Params.image }}
|
||||
{{ if .url }}
|
||||
{{- partial "components/image.html" (dict "style" "coverimage" "url" .url "alt" .alt) -}}
|
||||
{{ else }}
|
||||
{{- partial "components/image.html" (dict "style" "coverimage" "url" . "alt" "Cover") -}}
|
||||
{{ end }}
|
||||
<div class="content">
|
||||
{{ with .Title }}
|
||||
<div class="title">
|
||||
<h1 class="content-title">{{ . }}</h1>
|
||||
<div class="divider"></div>
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ .Content }}
|
||||
</div>
|
||||
{{ end }}
|
||||
<div class="content">
|
||||
{{ with .Title }}
|
||||
{{ partial "components/title.html" . }}
|
||||
{{ end }}
|
||||
{{ .Content }}
|
||||
</div>
|
||||
{{ end }}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue