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

github.com/chipzoller/hugo-clarity.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIvan Boothe <git@rootwork.org>2022-05-11 02:48:06 +0300
committerIvan Boothe <git@rootwork.org>2022-05-11 02:48:06 +0300
commit06c99c96e25a932e2190586cbc8f8ccf2f09da06 (patch)
treec8f629a1e33534a038af77675452e78cf1d55075
parent4cf61c2be83779c718d34704938bb8424290c765 (diff)
correct path for theme images
Signed-off-by: Ivan Boothe <git@rootwork.org>
-rw-r--r--layouts/_default/single.html2
-rw-r--r--layouts/partials/image.html2
2 files changed, 2 insertions, 2 deletions
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index 2cfeca6..2935179 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -16,7 +16,7 @@
{{- partial "post-meta" . }}
{{- with .Params.featureImage -}}
<div class="post_featured">
- {{- partial "image" (dict "file" . "alt" $p.featureImageAlt "cap" $p.featureImageCap "type" "featured" "Page" $.Page) }}
+ {{- partial "image" (dict "file" $p.featureImage "alt" $p.featureImageAlt "cap" $p.featureImageCap "type" "featured" "Page" $.Page) }}
</div>
{{- end -}}
{{ if $p.toc }}
diff --git a/layouts/partials/image.html b/layouts/partials/image.html
index 62d4d6d..2f7b4ef 100644
--- a/layouts/partials/image.html
+++ b/layouts/partials/image.html
@@ -41,7 +41,7 @@
{{- end -}}
{{- else -}}
{{- $scratch.Add "classes" " image_internal" -}}
- {{ $file = (path.Join "/" $file) }}
+ {{ $file = (path.Clean $file) }}
{{- if eq $bundle true -}}
{{ $image = .Resources.GetMatch $file }}
{{- end -}}