aboutsummaryrefslogtreecommitdiff
path: root/themes/default/layouts/_default
diff options
context:
space:
mode:
Diffstat (limited to 'themes/default/layouts/_default')
-rw-r--r--themes/default/layouts/_default/_markup/render-codeblock.html2
-rw-r--r--themes/default/layouts/_default/_markup/render-image.html14
-rw-r--r--themes/default/layouts/_default/home.xslt.rss.xsl6
-rw-r--r--themes/default/layouts/_default/home.xslt.sitemap.xsl9
-rw-r--r--themes/default/layouts/_default/rss.xml6
-rw-r--r--themes/default/layouts/_default/section.following.html4
-rw-r--r--themes/default/layouts/_default/single.html4
7 files changed, 23 insertions, 22 deletions
diff --git a/themes/default/layouts/_default/_markup/render-codeblock.html b/themes/default/layouts/_default/_markup/render-codeblock.html
index 85e60b2..f18f0d3 100644
--- a/themes/default/layouts/_default/_markup/render-codeblock.html
+++ b/themes/default/layouts/_default/_markup/render-codeblock.html
@@ -10,7 +10,7 @@
<a href="#{{ $id }}">{{ $type }}</a>
</language-label>
<button hidden="">
- {{ safeHTML (readFile (print (partial "function-paths.html" "static") "/icons/feather/copy.svg")) }}
+ {{ safeHTML (readFile (print (partial "function-paths.html").static "/icons/feather/copy.svg")) }}
<span>Copy</span>
</button>
</header>
diff --git a/themes/default/layouts/_default/_markup/render-image.html b/themes/default/layouts/_default/_markup/render-image.html
index 1a003fc..b98efdf 100644
--- a/themes/default/layouts/_default/_markup/render-image.html
+++ b/themes/default/layouts/_default/_markup/render-image.html
@@ -13,7 +13,7 @@
{{- $author := .Page.Section -}}
{{- $relURL := strings.TrimPrefix .Page.Site.BaseURL .Page.Permalink -}}
{{- $immutable := print ($relURL | humanize | urlize) "-" ($source | sha256 | truncate 8 "") -}}
-{{- $fileCache := print (partial "function-paths.html" "media") "/" $author "/" $immutable -}}
+{{- $fileCache := print (partial "function-paths.html").media "/" $author "/" $immutable -}}
{{- $cached := and (fileExists (print "public/" $fileCache ".webp")) (fileExists (print "public/" $fileCache (path.Ext $source))) -}}
{{- if not $cached -}}
@@ -22,7 +22,7 @@
{{- if fileExists $public -}}
{{- $local = resources.Get $public -}}
{{- with $local -}}
- {{- $local = .Content | resources.FromString (print (partial "function-paths.html" "media") "/" $author "/" (path.Base .)) -}}
+ {{- $local = .Content | resources.FromString (print (partial "function-paths.html").media "/" $author "/" (path.Base .)) -}}
{{- end -}}
{{- $source = print ("" | absURL) $source -}}
{{- else -}}
@@ -34,20 +34,20 @@
{{- $source = $404image.Permalink -}}
{{- end -}}
{{- else -}}
- {{- $cache = .Content | resources.FromString (print (partial "function-paths.html" "media") "/" $author "/" (path.Base .)) -}}
+ {{- $cache = .Content | resources.FromString (print (partial "function-paths.html").media "/" $author "/" (path.Base .)) -}}
{{- end -}}
{{- end -}}
{{- else -}}
{{- $exists = resources.Get (print "public/" $fileCache (path.Ext $source)) -}}
- {{- $exists = $exists.Content | resources.FromString (print (partial "function-paths.html" "media") "/" $author "/" (path.Base $exists)) -}}
+ {{- $exists = $exists.Content | resources.FromString (print (partial "function-paths.html").media "/" $author "/" (path.Base $exists)) -}}
{{- end -}}
{{- with $local }}
{{- $local = .Fit (print $dimensions " webp") }}
- {{- $local = $local | resources.Copy (print (partial "function-paths.html" "media") "/" $author "/" $immutable ".webp") }}
+ {{- $local = $local | resources.Copy (print (partial "function-paths.html").media "/" $author "/" $immutable ".webp") }}
{{- $srcset = $local.Permalink -}}
{{- $local = .Fit $dimensions }}
- {{- $local = $local | resources.Copy (print (partial "function-paths.html" "media") "/" $author "/" $immutable (path.Ext $local)) }}
+ {{- $local = $local | resources.Copy (print (partial "function-paths.html").media "/" $author "/" $immutable (path.Ext $local)) }}
{{- $width = $local.Width -}}
{{- $height = $local.Height -}}
{{- $colors = $local.Colors -}}
@@ -59,7 +59,7 @@
{{- $cache = $cache | resources.Copy (print $author "/media/" $immutable ".webp") }}
{{- $srcset = $cache.Permalink -}}
{{- $cache = .Fit $dimensions }}
- {{- $cache = $cache | resources.Copy (print (partial "function-paths.html" "media") "/" $author "/" $immutable (path.Ext $cache)) }}
+ {{- $cache = $cache | resources.Copy (print (partial "function-paths.html").media "/" $author "/" $immutable (path.Ext $cache)) }}
{{- $width = $cache.Width -}}
{{- $height = $cache.Height -}}
{{- $colors = $cache.Colors -}}
diff --git a/themes/default/layouts/_default/home.xslt.rss.xsl b/themes/default/layouts/_default/home.xslt.rss.xsl
index a19642d..e0c7c80 100644
--- a/themes/default/layouts/_default/home.xslt.rss.xsl
+++ b/themes/default/layouts/_default/home.xslt.rss.xsl
@@ -33,7 +33,7 @@
<xsl:attribute name="href">/</xsl:attribute>
</xsl:otherwise>
</xsl:choose>
- {{ safeHTML (readFile (print (partial "function-paths.html" "static") "/icons/feather/arrow-left.svg")) }}
+ {{ safeHTML (readFile (print (partial "function-paths.html").static "/icons/feather/arrow-left.svg")) }}
<small>Back</small>
</a>
</icon-button>
@@ -47,7 +47,7 @@
<xsl:attribute name="href">
<xsl:value-of select="/rss/channel/atom:link[@rel='next']/@href"/>
</xsl:attribute>
- {{ safeHTML (readFile (print (partial "function-paths.html" "static") "/icons/feather/arrow-right.svg")) }}
+ {{ safeHTML (readFile (print (partial "function-paths.html").static "/icons/feather/arrow-right.svg")) }}
<small>Next</small>
</a>
</icon-button>
@@ -58,7 +58,7 @@
<icon-button>
<a id="nav-middle-{{ path.Base .Identifier }}" href="{{ .URL | absURL }}">
{{ with .Identifier }}
- {{ $icon := print (partial "function-paths.html" "static") "/icons/" . ".svg" }}
+ {{ $icon := print (partial "function-paths.html").static "/icons/" . ".svg" }}
{{ safeHTML (readFile $icon) }}
{{ end }}
<small>{{ delimit (first 1 (split .Name " ")) " " }}</small>
diff --git a/themes/default/layouts/_default/home.xslt.sitemap.xsl b/themes/default/layouts/_default/home.xslt.sitemap.xsl
index a66877e..ce3fe98 100644
--- a/themes/default/layouts/_default/home.xslt.sitemap.xsl
+++ b/themes/default/layouts/_default/home.xslt.sitemap.xsl
@@ -21,7 +21,7 @@
<nav>
<icon-button>
<a onclick="window.history.go(-1); return false;" href="/">
- {{ safeHTML (readFile (print (partial "function-paths.html" "static") "/icons/feather/arrow-left.svg")) }}
+ {{ safeHTML (readFile (print (partial "function-paths.html").static "/icons/feather/arrow-left.svg")) }}
<small>Back</small>
</a>
</icon-button>
@@ -37,9 +37,10 @@
id="nav-middle-{{ path.Base .Identifier }}"
href="{{ .URL | absURL }}"
>
- {{ with .Identifier }} {{ $icon := print (partial
- "function-paths.html" "static") "/icons/" . ".svg" }} {{ safeHTML
- (readFile $icon) }} {{ end }}
+ {{ with .Identifier }}
+ {{ $icon := print (partial "function-paths.html").static "/icons/" . ".svg" }}
+ {{ safeHTML (readFile $icon) }}
+ {{ end }}
<small>{{ delimit (first 1 (split .Name " ")) " " }}</small>
</a>
</icon-button>
diff --git a/themes/default/layouts/_default/rss.xml b/themes/default/layouts/_default/rss.xml
index fb11d98..3e8e337 100644
--- a/themes/default/layouts/_default/rss.xml
+++ b/themes/default/layouts/_default/rss.xml
@@ -26,7 +26,7 @@
{{- $description = print .Site.Title " Tags: #" .Title -}}
{{- end -}}
-{{- $image := print "/" (partial "function-paths.html" "media")
+{{- $image := print "/" (partial "function-paths.html").media
"/" $author.user "/" $author.user "-profile" (path.Ext $author.picture.profile)
-}}
@@ -81,7 +81,7 @@
{{- $author = partial "function-authors-data.html" . -}}
- {{- $image = print "/" (partial "function-paths.html" "media")
+ {{- $image = print "/" (partial "function-paths.html").media
"/" $author.user "/" $author.user "-profile" (path.Ext $author.picture.profile)
-}}
@@ -93,7 +93,7 @@
{{- $atomAuthorName := or .Params.Feed.name $author.name -}}
{{- if .Params.Feed.favicon -}}
- {{- $favicon := print "/" (partial "function-paths.html" "media") "/favicon." (.Params.Feed.source | anchorize) ".png" -}}
+ {{- $favicon := print "/" (partial "function-paths.html").media "/favicon." (.Params.Feed.source | anchorize) ".png" -}}
{{- if not (fileExists (print "public/" $favicon)) -}}
{{- $favicon = "/data/media/404.png" -}}
{{- end -}}
diff --git a/themes/default/layouts/_default/section.following.html b/themes/default/layouts/_default/section.following.html
index ad3886d..7c9d990 100644
--- a/themes/default/layouts/_default/section.following.html
+++ b/themes/default/layouts/_default/section.following.html
@@ -12,7 +12,7 @@
{{- range $distinct := first 1 (where $feeds "FeedSourceLink" "eq" $source) -}}
{{- $href := or $distinct.FeedHome (print "http://" $distinct.FeedSourceDomain) -}}
- {{- $favicon := print "/" (partial "function-paths.html" "media") "/favicon." (.FeedSourceLink | anchorize) ".png" -}}
+ {{- $favicon := print "/" (partial "function-paths.html").media "/favicon." (.FeedSourceLink | anchorize) ".png" -}}
<micro-author>
<micro-card>
@@ -53,7 +53,7 @@
<a
title="Follow {{ $distinct.FeedName }}"
href="{{ $href }}">
- {{ safeHTML (readFile (print (partial "function-paths.html" "static") "/icons/feather/rss.svg")) }}
+ {{ safeHTML (readFile (print (partial "function-paths.html").static "/icons/feather/rss.svg")) }}
<span>Follow</span>
</a>
</micro-summary>
diff --git a/themes/default/layouts/_default/single.html b/themes/default/layouts/_default/single.html
index 4d5e172..9aeb728 100644
--- a/themes/default/layouts/_default/single.html
+++ b/themes/default/layouts/_default/single.html
@@ -43,13 +43,13 @@
{{- with or .Next .Prev -}}
<paginator-navigation>
<a {{ $nextInvisible | safeHTMLAttr }} href="{{ $nextHref }}" title="{{ $nextTitle }}">
- {{ safeHTML (readFile (print (partial "function-paths.html" "static") "/icons/feather/arrow-left.svg")) }}
+ {{ safeHTML (readFile (print (partial "function-paths.html").static "/icons/feather/arrow-left.svg")) }}
Newer
</a>
<a {{ $prevInvisible | safeHTMLAttr }} href="{{ $prevHref }}" title="{{ $prevTitle }}">
Older
- {{ safeHTML (readFile (print (partial "function-paths.html" "static") "/icons/feather/arrow-right.svg")) }}
+ {{ safeHTML (readFile (print (partial "function-paths.html").static "/icons/feather/arrow-right.svg")) }}
</a>
</paginator-navigation>
{{- end -}}