Add styling on links

This commit is contained in:
2024-08-04 17:41:39 +02:00
commit d35c46078f
533 changed files with 1299486 additions and 0 deletions
.gitattributes.gitignore
archetypes
assets
content
hugo.toml
static/assets
ansible
as8298
asr9006
asr920
bucketlist
clearfog
colo
coloclue-ipng
coloclue-loadtest
coloclue-vpp
css
debian-vpp
dwdm.png
fiber7-litexchange
fiber7-x
fitlet2
freebsd-vpp
freeix
fs-switch
geofeed
gowin-n305
ipng-frontends
lab
logo
main.scss
mastodon
minima-social-icons.svg
mlxsw
mpls-core
nat64
netgate-6100
network
oem-switch
pcengines-apu6
pdf
pdu19.png
pixelfed
r86s
sixxs-sunset
smtp
supermicro.png
syslog-telegram
vpp-babel
vpp-ixp-gateway
vpp-mpls
vpp-ospf
vpp-papi
vpp-proto
vpp-stats
vpp
vppcfg
themes/hugo-theme-notrack

@ -0,0 +1,32 @@
<figure class="image-shortcode{{ with .Get "class" }} {{ . }}{{ end }}
{{- with .Get "wide" }}{{- if eq . "true" }} wide{{ end -}}{{ end -}}
{{- with .Get "frame" }}{{- if eq . "true" }} frame{{ end -}}{{ end -}}
{{- with .Get "float" }} {{ . }}{{ end -}}"
style="
{{- with .Get "width" }}width: {{ . }};{{ end -}}
{{- with .Get "height" }}height: {{ . }};{{ end -}}">
{{- if .Get "link" -}}
<a href="{{ .Get "link" }}"{{ with .Get "target" }} target="{{ . }}"{{ end }}{{ with .Get "rel" }} rel="{{ . }}"{{ end }}>
{{- end }}
<img src="{{ .Get "src" | relURL }}"
{{- if or (.Get "alt") (.Get "caption") }}
alt="{{ with .Get "alt" }}{{ . }}{{ else }}{{ .Get "caption" | markdownify| plainify }}{{ end }}"
{{- end -}}
/> <!-- Closing img tag -->
{{- if .Get "link" }}</a>{{ end -}}
{{- if or (or (.Get "title") (.Get "caption")) (.Get "attr") -}}
<figcaption>
{{ with (.Get "title") -}}
<h4>{{ . }}</h4>
{{- end -}}
{{- if or (.Get "caption") (.Get "attr") -}}<p>
{{- .Get "caption" | markdownify -}}
{{- with .Get "attrlink" }}
<a href="{{ . }}">
{{- end -}}
{{- .Get "attr" | markdownify -}}
{{- if .Get "attrlink" }}</a>{{ end }}</p>
{{- end }}
</figcaption>
{{- end }}
</figure>