🎉 Hello World
This commit is contained in:
16
layouts/_default/_markup/render-image.html
Normal file
16
layouts/_default/_markup/render-image.html
Normal file
@@ -0,0 +1,16 @@
|
||||
{{- $url := .Destination | safeURL -}}
|
||||
{{- $block := gt (len .Title) 0 -}}
|
||||
|
||||
{{- if $block -}}
|
||||
<span class="image-container"><span class="link">
|
||||
{{- end -}}
|
||||
<a target="_blank" rel="noopener noreferrer"
|
||||
href="{{- $url -}}"><img {{ if $block }}class="img"{{ end }} src="{{- $url -}}"
|
||||
alt{{- with .Text -}}="{{- . -}}" {{- end -}} /></a>
|
||||
{{- if $block -}}
|
||||
</span>
|
||||
{{- if ne .Title " " -}}
|
||||
<span class="caption"><span class="title">{{- .Title | safeHTML -}}</span></span>
|
||||
{{- end -}}
|
||||
</span>
|
||||
{{- end -}}
|
Reference in New Issue
Block a user