fix
This commit is contained in:
7
layouts/_default/index.json
Normal file
7
layouts/_default/index.json
Normal file
@ -0,0 +1,7 @@
|
||||
{{ $dateFormat := default "Mon Jan 2, 2006" (index .Site.Params "date_format") }}
|
||||
{{ $utcFormat := "2006-01-02T15:04:05Z07:00" }}
|
||||
{{- $.Scratch.Add "index" slice -}}
|
||||
{{- range .Site.RegularPages -}}
|
||||
{{- $.Scratch.Add "index" (dict "title" .Title "tags" .Params.tags "description" .Description "categories" .Params.categories "contents" .Plain "href" .Permalink "utc_time" (.Date.Format $utcFormat) "formated_time" (.Date.Format $dateFormat)) -}}
|
||||
{{- end -}}
|
||||
{{- $.Scratch.Get "index" | jsonify -}}
|
20
layouts/_default/list.html
Normal file
20
layouts/_default/list.html
Normal file
@ -0,0 +1,20 @@
|
||||
{{ partial "head.html" . }}
|
||||
{{ partial "navbar.html" . }}
|
||||
{{ partial "header.html" . }}
|
||||
<div id="container">
|
||||
<div class="outer">
|
||||
<div id="blog-archives" class="category">
|
||||
<ul class="cp_list">
|
||||
{{ range .Data.Pages.Reverse }}
|
||||
<li>
|
||||
<a href="{{.Permalink}}">{{.Title}}</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{ partial "footer" . }}
|
||||
</body>
|
||||
</html>
|
19
layouts/_default/single.html
Normal file
19
layouts/_default/single.html
Normal file
@ -0,0 +1,19 @@
|
||||
{{ partial "head.html" . }}
|
||||
{{ partial "navbar.html" . }}
|
||||
{{ partial "header.html" . }}
|
||||
|
||||
{{ $s := path.Dir (.Permalink | relURL) }}
|
||||
{{ $t := index (split $s "/") 2 }}
|
||||
{{ $o := index (split $s "/") 1 }}
|
||||
|
||||
{{ if eq $t "img" }}
|
||||
{{ partial "img.html" . }}
|
||||
{{ else }}
|
||||
{{ .Content }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
{{ partial "footer.html" . }}
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user