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

github.com/zhaohuabing/hugo-theme-cleanwhite.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--layouts/_default/list.algolia.json2
-rw-r--r--layouts/_default/single.html4
-rw-r--r--layouts/partials/head.html2
-rw-r--r--layouts/partials/header.html4
-rw-r--r--layouts/partials/page_view_counter.html2
5 files changed, 7 insertions, 7 deletions
diff --git a/layouts/_default/list.algolia.json b/layouts/_default/list.algolia.json
index 556e362..963ad07 100644
--- a/layouts/_default/list.algolia.json
+++ b/layouts/_default/list.algolia.json
@@ -3,7 +3,7 @@
{{- $section := $.Site.GetPage "section" .Section }}
{{- range .Site.AllPages -}}
{{- if or (and (.IsDescendant $section) (and (not .Draft) (not .Params.private))) $section.IsHome -}}
- {{- $.Scratch.Add "index" (dict "objectID" .UniqueID "date" .Date.UTC.Unix "description" .Description "dir" .Dir "expirydate" .ExpiryDate.UTC.Unix "fuzzywordcount" .FuzzyWordCount "keywords" .Keywords "kind" .Kind "lang" .Lang "lastmod" .Lastmod.UTC.Unix "permalink" .Permalink "publishdate" .PublishDate "readingtime" .ReadingTime "relpermalink" .RelPermalink "html" .Params.Description "title" .Title "type" .Type "url" .URL "weight" .Weight "wordcount" .WordCount "section" .Section "tags" .Params.Tags "categories" .Params.Categories "author" .Params.authors "content" .Params.Description "excerpt_html" .Params.Description "excerpt_text" .Params.Description "summary" .Summary)}}
+ {{- $.Scratch.Add "index" (dict "objectID" .File.UniqueID "date" .Date.UTC.Unix "description" .Description "dir" .File.Dir "expirydate" .ExpiryDate.UTC.Unix "fuzzywordcount" .FuzzyWordCount "keywords" .Keywords "kind" .Kind "lang" .Lang "lastmod" .Lastmod.UTC.Unix "permalink" .Permalink "publishdate" .PublishDate "readingtime" .ReadingTime "relpermalink" .RelPermalink "html" .Params.Description "title" .Title "type" .Type "url" .RelPermalink "weight" .Weight "wordcount" .WordCount "section" .Section "tags" .Params.Tags "categories" .Params.Categories "author" .Params.authors "content" .Params.Description "excerpt_html" .Params.Description "excerpt_text" .Params.Description "summary" .Summary)}}
{{- end -}}
{{- end -}}
{{- $.Scratch.Get "index" | jsonify -}}
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index 7474ea8..4c9bf3b 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -87,13 +87,13 @@
<ul class="pager">
{{ if .PrevInSection }}
<li class="previous">
- <a href="{{ .PrevInSection.URL }}" data-toggle="tooltip" data-placement="top" title="{{ .PrevInSection.Title}}">&larr;
+ <a href="{{ .PrevInSection.RelPermalink }}" data-toggle="tooltip" data-placement="top" title="{{ .PrevInSection.Title}}">&larr;
Previous Post</a>
</li>
{{ end }}
{{ if .NextInSection }}
<li class="next">
- <a href="{{ .NextInSection.URL }}" data-toggle="tooltip" data-placement="top" title="{{ .NextInSection.Title}}">Next
+ <a href="{{ .NextInSection.RelPermalink }}" data-toggle="tooltip" data-placement="top" title="{{ .NextInSection.Title}}">Next
Post &rarr;</a>
</li>
{{ end }}
diff --git a/layouts/partials/head.html b/layouts/partials/head.html
index c514346..2b6619f 100644
--- a/layouts/partials/head.html
+++ b/layouts/partials/head.html
@@ -47,7 +47,7 @@
<title>{{ if .Title }}{{ .Title }}-{{ .Site.Params.SEOTitle }}{{ else }}{{ .Site.Params.SEOTitle }}{{ end }}</title>
- <link rel="canonical" href="{{ .URL | relURL }}">
+ <link rel="canonical" href="{{ .RelPermalink }}">
<link rel="stylesheet" href="{{ "css/iDisqus.min.css" | relURL }}"/>
diff --git a/layouts/partials/header.html b/layouts/partials/header.html
index b3b1362..208024a 100644
--- a/layouts/partials/header.html
+++ b/layouts/partials/header.html
@@ -18,8 +18,8 @@
<ul id="menu-primary-items" class="menu-primary-items">
{{ $page := . }}
{{ range .Site.Menus.main }}
- <li id="menu-item" class='menu-item {{ if eq ("/") (.URL) }}menu-item-type-custom menu-item-object-custom{{ else }}menu-item-type-post_type menu-item-object-page{{ end }} {{ if $page.IsMenuCurrent "main" . }}current-menu-item current_page_item{{ end }}'>
- <a href="{{ .URL | relURL }}">{{ .Name }}</a>
+ <li id="menu-item" class='menu-item {{ if eq ("/") (.RelPermalink) }}menu-item-type-custom menu-item-object-custom{{ else }}menu-item-type-post_type menu-item-object-page{{ end }} {{ if $page.IsMenuCurrent "main" . }}current-menu-item current_page_item{{ end }}'>
+ <a href="{{ .RelPermalink }}">{{ .Name }}</a>
</li>
{{ end }}
</ul>
diff --git a/layouts/partials/page_view_counter.html b/layouts/partials/page_view_counter.html
index f4bb4ee..bc32ede 100644
--- a/layouts/partials/page_view_counter.html
+++ b/layouts/partials/page_view_counter.html
@@ -1,4 +1,4 @@
-<span id="{{ .URL }}" class="leancloud_visitors meta_data_item" data-flag-title="">
+<span id="{{ .RelPermalink }}" class="leancloud_visitors meta_data_item" data-flag-title="">
<span class="post-meta-item-icon">
<span class="octicon octicon-eye"></span>
</span>