Skip to content

Commit

Permalink
use filename hash, not index, to reference images in detail view
Browse files Browse the repository at this point in the history
  • Loading branch information
githubmonkey authored and kc0bfv committed Nov 11, 2021
1 parent 221e1eb commit 8e85d32
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions layouts/partials/sect_and_img_content.html
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@
{{- $column := $.Scratch.Get $st_name }}
<div class="flexcol">
{{- range $column }}

{{- $filename := path.Base .image.Name }}
<article class="thumb">
{{- if (eq .type "sect") }}
<a href="{{ .link }}" class="link" tabindex="0"><img src="{{ .thumb.RelPermalink }}" alt="{{ .title }}" /></a>
Expand All @@ -149,9 +149,9 @@ <h2>{{ .title }}</h2>
<a class="gallery-item" phototitle="{{ .phototitle }}"
description="{{ .description }}"
gallery_index="{{ .index }}"
id="image_number_{{ .index }}"
id="{{ md5 $filename }}"
downloadable="{{ cond $downloadable "true" "false" }}"
orig_name="{{ path.Base .image.Name }}"
orig_name="{{ $filename }}"
href="{{ .full.RelPermalink }}">
<img src="{{ .thumb.RelPermalink }}"
{{ with .alt }} alt="{{ . }}"{{ end }}>
Expand Down

0 comments on commit 8e85d32

Please sign in to comment.