🎉 Hello World

This commit is contained in:
2020-03-03 18:56:59 +01:00
commit 94877013bd
55 changed files with 1479 additions and 0 deletions

View 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 -}}

View File

@@ -0,0 +1,5 @@
{{- $url := .Destination | safeURL -}}
{{- $text := .Text | safeHTML -}}
<a href="{{- $url -}}"
{{- with .Title -}}title="{{- . -}}"{{- end -}}
{{- if strings.HasPrefix $url "http" -}}target="_blank"{{- end -}}>{{- $text -}}</a>