mirror of
https://git.sr.ht/~seirdy/seirdy.one
synced 2024-12-24 17:52:11 +00:00
25 lines
1.9 KiB
HTML
25 lines
1.9 KiB
HTML
<span {{ if (.Get "itemprop") -}}itemprop="{{- .Get "itemprop" -}}"{{- end }}
|
|
itemscope="" itemtype="https://schema.org/Person"
|
|
class="h-card vcard{{if eq (.Get "itemprop") "author"}} p-author{{end}}">
|
|
{{- if .Get "url" -}}
|
|
<a itemprop="url" href="{{- .Get "url" -}}" class="u-url url">
|
|
{{- end -}}
|
|
{{- if (.Get "avatar") -}}
|
|
{{- $avatar_img := (resources.GetRemote (.Get "avatar")).Resize "32x32" -}}
|
|
<img itemprop="image" class="u-photo photo" src="{{ $avatar_img.RelPermalink }}" alt="" width="16" height="16">
|
|
{{- end -}}
|
|
<span itemprop="name" class="p-name fn n">
|
|
{{- if (.Get "first-name") -}}<span itemprop="givenName" class="p-given-name given-name">{{- .Get "first-name" -}}</span>{{- end }}
|
|
{{- if (.Get "addl-name") }} <span itemprop="additionalName" class="p-additional-name additional-name">{{- .Get "addl-name" -}}</span>{{- end -}}
|
|
{{- if (.Get "last-name") }} <span itemprop="familyName" class="p-family-name family-name">{{- .Get "last-name" -}}</span>{{- end -}}
|
|
{{- if (.Get "nickname") -}}<span class="p-nickname nickname">{{- .Get "nickname" -}}</span>{{- end -}}
|
|
{{- if (.Get "name") -}}{{- .Get "name" -}}{{- end -}}
|
|
</span>{{- if (.Get "appendString") -}}{{- .Get "appendString" -}}{{- end -}}{{- /* Strip trailing newline: https://github.com/gohugoio/hugo/issues/1753 */ -}}
|
|
{{- if .Get "url" -}}</a>{{- end -}}{{- /* Strip trailing newline: https://github.com/gohugoio/hugo/issues/1753 */ -}}
|
|
{{- if (.Get "org") }}
|
|
from <span class="p-org org" itemprop="affiliation" itemscope="" itemtype="https://schema.org/Organization">
|
|
<a itemprop="url" class="organization-name" href="{{- .Get "org-url" -}}">
|
|
<span itemprop="name">{{- .Get "org" -}}</span>{{- /* Strip trailing newline: https://github.com/gohugoio/hugo/issues/1753 */ -}}
|
|
</a></span>
|
|
{{- end -}}
|
|
</span>{{- /* Strip trailing newline: https://github.com/gohugoio/hugo/issues/1753 */ -}}
|