From 15e3dedcee1d0830871ffc692143318a87646101 Mon Sep 17 00:00:00 2001 From: Christian Segundo Date: Thu, 25 Jul 2024 02:12:22 +0200 Subject: wip --- .../layouts/_default/_markup/render-image.html | 1 + .../hugo-PaperMod/layouts/_default/archives.html | 83 ++++++++++++++ .../hugo-PaperMod/layouts/_default/baseof.html | 27 +++++ .../hugo-PaperMod/layouts/_default/index.json | 7 ++ .../hugo-PaperMod/layouts/_default/list.html | 121 +++++++++++++++++++++ .../hugo-PaperMod/layouts/_default/rss.xml | 83 ++++++++++++++ .../hugo-PaperMod/layouts/_default/search.html | 29 +++++ .../hugo-PaperMod/layouts/_default/single.html | 65 +++++++++++ .../hugo-PaperMod/layouts/_default/terms.html | 27 +++++ 9 files changed, 443 insertions(+) create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/_markup/render-image.html create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/archives.html create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/baseof.html create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/index.json create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/list.html create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/rss.xml create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/search.html create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/single.html create mode 100644 _vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/terms.html (limited to '_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default') diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/_markup/render-image.html b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/_markup/render-image.html new file mode 100644 index 0000000..1acb87d --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/_markup/render-image.html @@ -0,0 +1 @@ +{{ .Text }} diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/archives.html b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/archives.html new file mode 100644 index 0000000..eea3fc8 --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/archives.html @@ -0,0 +1,83 @@ +{{- define "main" }} + + + +{{- $pages := where site.RegularPages "Type" "in" site.Params.mainSections }} + +{{- if site.Params.ShowAllPagesInArchive }} +{{- $pages = site.RegularPages }} +{{- end }} + +{{- range $pages.GroupByPublishDate "2006" }} +{{- if ne .Key "0001" }} +
+ {{- $year := replace .Key "0001" "" }} +

+ + {{- $year -}} + +  {{ len .Pages }} +

+ {{- range .Pages.GroupByDate "January" }} +
+

+ + {{- .Key -}} + +  {{ len .Pages }} +

+
+ {{- range .Pages }} + {{- if eq .Kind "page" }} +
+

+ {{- .Title | markdownify }} + {{- if .Draft }} + + + + + + {{- end }} +

+
+ {{- partial "post_meta.html" . -}} +
+ +
+ {{- end }} + {{- end }} +
+
+ {{- end }} +
+{{- end }} +{{- end }} + +{{- end }}{{/* end main */}} diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/baseof.html b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/baseof.html new file mode 100644 index 0000000..df611bf --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/baseof.html @@ -0,0 +1,27 @@ +{{- if lt hugo.Version "0.112.4" }} +{{- errorf "=> hugo v0.112.4 or greater is required for hugo-PaperMod to build " }} +{{- end -}} + + + + + + {{- partial "head.html" . }} + + + + {{- partialCached "header.html" . .Page -}} +
+ {{- block "main" . }}{{ end }} +
+ {{ partialCached "footer.html" . .Layout .Kind (.Param "hideFooter") (.Param "ShowCodeCopyButtons") -}} + + + diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/index.json b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/index.json new file mode 100644 index 0000000..feeb437 --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/index.json @@ -0,0 +1,7 @@ +{{- $.Scratch.Add "index" slice -}} +{{- range site.RegularPages -}} + {{- if and (not .Params.searchHidden) (ne .Layout `archives`) (ne .Layout `search`) }} + {{- $.Scratch.Add "index" (dict "title" .Title "content" .Plain "permalink" .Permalink "summary" .Summary) -}} + {{- end }} +{{- end -}} +{{- $.Scratch.Get "index" | jsonify -}} diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/list.html b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/list.html new file mode 100644 index 0000000..81aea6e --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/list.html @@ -0,0 +1,121 @@ +{{- define "main" }} + +{{- if (and site.Params.profileMode.enabled .IsHome) }} +{{- partial "index_profile.html" . }} +{{- else }} {{/* if not profileMode */}} + +{{- if not .IsHome | and .Title }} + +{{- end }} + +{{- if .Content }} +
+ {{- if not (.Param "disableAnchoredHeadings") }} + {{- partial "anchored_headings.html" .Content -}} + {{- else }}{{ .Content }}{{ end }} +
+{{- end }} + +{{- $pages := union .RegularPages .Sections }} + +{{- if .IsHome }} +{{- $pages = where site.RegularPages "Type" "in" site.Params.mainSections }} +{{- $pages = where $pages "Params.hiddenInHomeList" "!=" "true" }} +{{- end }} + +{{- $paginator := .Paginate $pages }} + +{{- if and .IsHome site.Params.homeInfoParams (eq $paginator.PageNumber 1) }} +{{- partial "home_info.html" . }} +{{- end }} + +{{- $term := .Data.Term }} +{{- range $index, $page := $paginator.Pages }} + +{{- $class := "post-entry" }} + +{{- $user_preferred := or site.Params.disableSpecial1stPost site.Params.homeInfoParams }} +{{- if (and $.IsHome (eq $paginator.PageNumber 1) (eq $index 0) (not $user_preferred)) }} +{{- $class = "first-entry" }} +{{- else if $term }} +{{- $class = "post-entry tag-entry" }} +{{- end }} + +
+ {{- $isHidden := (.Param "cover.hiddenInList") | default (.Param "cover.hidden") | default false }} + {{- partial "cover.html" (dict "cxt" . "IsSingle" false "isHidden" $isHidden) }} +
+

+ {{- .Title }} + {{- if .Draft }} + + + + + + {{- end }} +

+
+ {{- if (ne (.Param "hideSummary") true) }} +
+

{{ .Summary | plainify | htmlUnescape }}{{ if .Truncated }}...{{ end }}

+
+ {{- end }} + {{- if not (.Param "hideMeta") }} + + {{- end }} + +
+{{- end }} + +{{- if gt $paginator.TotalPages 1 }} + +{{- end }} + +{{- end }}{{/* end profileMode */}} + +{{- end }}{{- /* end main */ -}} diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/rss.xml b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/rss.xml new file mode 100644 index 0000000..fed8ae9 --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/rss.xml @@ -0,0 +1,83 @@ +{{- /* Deprecate site.Author.email in favor of site.Params.author.email */}} +{{- $authorEmail := "" }} +{{- with site.Params.author }} + {{- if reflect.IsMap . }} + {{- with .email }} + {{- $authorEmail = . }} + {{- end }} + {{- end }} +{{- else }} + {{- with site.Author.email }} + {{- $authorEmail = . }} + {{- warnf "The author key in site configuration is deprecated. Use params.author.email instead." }} + {{- end }} +{{- end }} + +{{- /* Deprecate site.Author.name in favor of site.Params.author.name */}} +{{- $authorName := "" }} +{{- with site.Params.author }} + {{- if reflect.IsMap . }} + {{- with .name }} + {{- $authorName = . }} + {{- end }} + {{- else }} + {{- $authorName = . }} + {{- end }} +{{- else }} + {{- with site.Author.name }} + {{- $authorName = . }} + {{- warnf "The author key in site configuration is deprecated. Use params.author.name instead." }} + {{- end }} +{{- end }} + +{{- $pctx := . }} +{{- if .IsHome }}{{ $pctx = site }}{{ end }} +{{- $pages := slice }} +{{- if or $.IsHome $.IsSection }} +{{- $pages = $pctx.RegularPages }} +{{- else }} +{{- $pages = $pctx.Pages }} +{{- end }} +{{- $limit := site.Config.Services.RSS.Limit }} +{{- if ge $limit 1 }} +{{- $pages = $pages | first $limit }} +{{- end }} +{{- printf "" | safeHTML }} + + + {{ if eq .Title site.Title }}{{ site.Title }}{{ else }}{{ with .Title }}{{ . }} on {{ end }}{{ site.Title }}{{ end }} + {{ .Permalink }} + Recent content {{ if ne .Title site.Title }}{{ with .Title }}in {{ . }} {{ end }}{{ end }}on {{ site.Title }} + {{- with site.Params.images }} + + {{ site.Title }} + {{ index . 0 | absURL }} + {{ index . 0 | absURL }} + + {{- end }} + Hugo -- {{ hugo.Version }} + {{ site.Language.LanguageCode }}{{ with $authorEmail }} + {{.}}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with $authorEmail }} + {{ . }}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with site.Copyright }} + {{ . | markdownify | plainify | strings.TrimPrefix "© " }}{{ end }}{{ if not .Date.IsZero }} + {{ (index $pages.ByLastmod.Reverse 0).Lastmod.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}{{ end }} + {{- with .OutputFormats.Get "RSS" }} + {{ printf "" .Permalink .MediaType | safeHTML }} + {{- end }} + {{- range $pages }} + {{- if and (ne .Layout `search`) (ne .Layout `archives`) }} + + {{ .Title }} + {{ .Permalink }} + {{ .PublishDate.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }} + {{- with $authorEmail }}{{ . }}{{ with $authorName }} ({{ . }}){{ end }}{{ end }} + {{ .Permalink }} + {{ with .Description | html }}{{ . }}{{ else }}{{ .Summary | html }}{{ end -}} + {{- if and site.Params.ShowFullTextinRSS .Content }} + {{ (printf "" .Content) | safeHTML }} + {{- end }} + + {{- end }} + {{- end }} + + diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/search.html b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/search.html new file mode 100644 index 0000000..bb7d436 --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/search.html @@ -0,0 +1,29 @@ +{{- define "main" }} + + + + + +{{- end }}{{/* end main */}} diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/single.html b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/single.html new file mode 100644 index 0000000..19a624f --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/single.html @@ -0,0 +1,65 @@ +{{- define "main" }} + +
+
+ {{ partial "breadcrumbs.html" . }} +

+ {{ .Title }} + {{- if .Draft }} + + + + + + {{- end }} +

+ {{- if .Description }} +
+ {{ .Description }} +
+ {{- end }} + {{- if not (.Param "hideMeta") }} + + {{- end }} +
+ {{- $isHidden := (.Param "cover.hiddenInSingle") | default (.Param "cover.hidden") | default false }} + {{- partial "cover.html" (dict "cxt" . "IsSingle" true "isHidden" $isHidden) }} + {{- if (.Param "ShowToc") }} + {{- partial "toc.html" . }} + {{- end }} + + {{- if .Content }} +
+ {{- if not (.Param "disableAnchoredHeadings") }} + {{- partial "anchored_headings.html" .Content -}} + {{- else }}{{ .Content }}{{ end }} +
+ {{- end }} + + + + {{- if (.Param "comments") }} + {{- partial "comments.html" . }} + {{- end }} +
+ +{{- end }}{{/* end main */}} diff --git a/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/terms.html b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/terms.html new file mode 100644 index 0000000..6fd2654 --- /dev/null +++ b/_vendor/github.com/adityatelange/hugo-PaperMod/layouts/_default/terms.html @@ -0,0 +1,27 @@ +{{- define "main" }} + +{{- if .Title }} + +{{- end }} + + + +{{- end }}{{/* end main */ -}} -- cgit v1.2.3