mirror of
https://github.com/jbowdre/virtuallypotato.git
synced 2024-11-21 22:42:19 +00:00
reference old_content label in localization file
This commit is contained in:
parent
189f70e790
commit
30b34cf0b3
2 changed files with 12 additions and 9 deletions
|
@ -34,5 +34,8 @@ other = "Query is too short"
|
||||||
[type_to_search]
|
[type_to_search]
|
||||||
other = "Type to search"
|
other = "Type to search"
|
||||||
|
|
||||||
[old_content]
|
[old_content_label]
|
||||||
|
other = "Technology keeps moving but this post has not."
|
||||||
|
|
||||||
|
[old_content_note]
|
||||||
other = "What you're about to read hasn't been updated in more than a year. The information may be out of date. Drop a comment below if you find something that needs updating."
|
other = "What you're about to read hasn't been updated in more than a year. The information may be out of date. Drop a comment below if you find something that needs updating."
|
|
@ -1,7 +1,7 @@
|
||||||
{{- define "main" }}
|
{{- define "main" }}
|
||||||
{{- $s := .Site.Params }}
|
{{- $s := .Site.Params }}
|
||||||
{{- $p := .Params }}
|
{{- $p := .Params }}
|
||||||
{{- $ageDays := div (sub now.Unix .Date.Unix) 86400 }}
|
{{- $ageDays := div (sub now.Unix .Date.Unix) 86400 -}}
|
||||||
{{- $scratch := newScratch }}
|
{{- $scratch := newScratch }}
|
||||||
{{- if isset $p "image" }}
|
{{- if isset $p "image" }}
|
||||||
{{- $scratch.Set "image" $p.image }}
|
{{- $scratch.Set "image" $p.image }}
|
||||||
|
@ -15,14 +15,14 @@
|
||||||
{{- $t := .Title }}
|
{{- $t := .Title }}
|
||||||
<h1 class="post_title">{{ $t }}</h1>
|
<h1 class="post_title">{{ $t }}</h1>
|
||||||
{{- partial "post-meta" . }}
|
{{- partial "post-meta" . }}
|
||||||
{{ with .Param "lastmod" }}
|
{{- with .Param "lastmod" -}}
|
||||||
{{ $ageDays = div (sub now.Unix .Unix) 86400 }}
|
{{- $ageDays = div (sub now.Unix .Unix) 86400 -}}
|
||||||
{{ end }}
|
{{- end -}}
|
||||||
{{ if gt $ageDays 365 }}
|
{{- if gt $ageDays 365 -}}
|
||||||
<div class="notices info"><div class="label">Technology keeps moving but this post has not.</div>
|
<div class="notices info"><div class="label">{{- T "old_content_label" -}}</div>
|
||||||
<i>{{ T "old_content" }}</i>
|
<i>{{- T "old_content_note" -}}</i>
|
||||||
</div>
|
</div>
|
||||||
{{ end }}
|
{{- end -}}
|
||||||
{{- partial "image-feature" . }}
|
{{- partial "image-feature" . }}
|
||||||
{{ if and (gt .WordCount 400 ) (gt (len .TableOfContents) 180) ($s.toc) }}
|
{{ if and (gt .WordCount 400 ) (gt (len .TableOfContents) 180) ($s.toc) }}
|
||||||
<div class="post_toc">
|
<div class="post_toc">
|
||||||
|
|
Loading…
Reference in a new issue