mirror of
https://github.com/Sped0n/bridget.git
synced 2026-04-21 05:29:31 -07:00
add height and width to image elements
This commit is contained in:
@@ -16,11 +16,11 @@
|
|||||||
{{ $images := $gallery.Resources.ByType "image" }}
|
{{ $images := $gallery.Resources.ByType "image" }}
|
||||||
{{ $index := len $images }}
|
{{ $index := len $images }}
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
document.body.setAttribute('featuredPicNum', {{$index}})
|
document.body.setAttribute('featuredPicNum', {{ $index }})
|
||||||
</script>
|
</script>
|
||||||
{{ range $images }}
|
{{ range $images }}
|
||||||
{{ $index = sub $index 1}}
|
{{ $index = sub $index 1}}
|
||||||
<img class="image" data-index="{{ $index }}" data-status="inactive" src="{{ .RelPermalink }}"/>
|
<img class="image" data-index="{{ $index }}" data-status="inactive" src="{{ .RelPermalink }}" height="{{ .Height }}" width="{{ .Width }}"/>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user