Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/hivickylai/hugo-theme-sam.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVicky <vicky@vickylai.com>2018-06-10 23:08:20 +0300
committerVicky <vicky@vickylai.com>2018-06-10 23:08:20 +0300
commit808ddf067724353c1c5e3645fb3fd475f54e3b19 (patch)
treeca9b42bb8e9b9a3630df193aacaea9f1b77aa397
parentd3a91e107ca9382bcf077b197b36f023d99e6c00 (diff)
Fix missing ul element on list pagev2.2
+ list of posts was being rendered with only li
-rw-r--r--layouts/_default/list.html4
-rw-r--r--pug/_default/list.pug19
2 files changed, 12 insertions, 11 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index e37de05..2c0ba53 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -1,9 +1,9 @@
-{{ partial "head.html" . }}<body><div class="wrap"><div class="section" id="content"><h1>{{ .Title }}</h1><p>{{ .Content }}</p>{{ range .Data.Pages }}<li>
+{{ partial "head.html" . }}<body><div class="wrap"><div class="section" id="content"><h1>{{ .Title }}</h1><p>{{ .Content }}</p><ul>{{ range .Data.Pages }}<li>
{{ if .Params.showDate }}
{{ .Date.Format (.Site.Params.dateForm | default "Mon Jan 02, 2006")}} --
-{{ end }}<a href="{{.Permalink}}">{{.Title}}</a></li>{{ end }}</div>{{ if .Site.Params.mainMenu }}<div class="section bottom-menu"><hr/><p>{{ range first 1 .Site.Params.mainMenu }}<a href="{{ .link }}">{{ .text }}</a>{{ end }}
+{{ end }}<a href="{{.Permalink}}">{{.Title}}</a></li>{{ end }}</ul></div>{{ if .Site.Params.mainMenu }}<div class="section bottom-menu"><hr/><p>{{ range first 1 .Site.Params.mainMenu }}<a href="{{ .link }}">{{ .text }}</a>{{ end }}
{{ if ( gt ( len .Site.Params.mainMenu ) 1 ) }}
{{ range after 1 .Site.Params.mainMenu }}
&#183; <a href="{{ .link }}">{{ .text }}</a>{{ end }}
diff --git a/pug/_default/list.pug b/pug/_default/list.pug
index 91386e1..aa790f2 100644
--- a/pug/_default/list.pug
+++ b/pug/_default/list.pug
@@ -5,16 +5,17 @@ body
.section#content
h1 {{ .Title }}
p {{ .Content }}
- | {{ range .Data.Pages }}
- li
- |
- | {{ if .Params.showDate }}
- |
- | {{ .Date.Format (.Site.Params.dateForm | default "Mon Jan 02, 2006")}} --
- |
+ ul
+ | {{ range .Data.Pages }}
+ li
+ |
+ | {{ if .Params.showDate }}
+ |
+ | {{ .Date.Format (.Site.Params.dateForm | default "Mon Jan 02, 2006")}} --
+ |
+ | {{ end }}
+ a(href='{{.Permalink}}') {{.Title}}
| {{ end }}
- a(href='{{.Permalink}}') {{.Title}}
- | {{ end }}
| {{ if .Site.Params.mainMenu }}
.section.bottom-menu
hr