Skip to content
Snippets Groups Projects
Commit af2acc78 authored by alexisben's avatar alexisben
Browse files

persons list wip

parent dbe2b3fa
No related merge requests found
......@@ -40,19 +40,34 @@ ol.persons
padding-bottom: $spacing1
padding-top: $spacing1
position: relative
p
margin-bottom: 0
transition: color 0.5s
@include icon(arrow, after)
margin-left: auto
&:hover
color: $color-accent
justify-self: end
a
@include stretched-link
@include link-hovered-underline-only
text-decoration: none
color: inherit
[itemprop="jobTitle"]
@include small
margin-top: 0
@include media-breakpoint-up(md)
align-items: baseline
display: flex
> p
[itemprop="name"]
width: col(5)
& + p
width: col(7)
[itemprop="jobTitle"]
width: col(7)
margin-left: $grid-gutter
@include media-breakpoint-down(md)
&::after
position: absolute
right: 0
top: calc(#{$spacing1} + 10px)
.avatar
@include aspect-ratio(50, 'img')
background-color: $persons-avatar-background-color
......
<li itemscope itemtype="https://schema.org/Person">
<p itemprop="name"><a href="{{ .Permalink }}">{{ partial "PrepareHTML" .Title }}</a></p>
{{- if partial "GetTextFromHTML" .Params.description_short }}
<p itemprop="jobTitle">{{- partial "PrepareHTML" .Params.description_short -}}</p>
{{ end -}}
</li>
\ No newline at end of file
<ol class="persons">
{{/* <ol class="persons">
{{ range (.Paginate (.Pages.ByParam "last_name")).Pages }}
{{ $person := site.GetPage (printf "/persons/%s" .Slug) }}
{{ with $person }}
......@@ -11,4 +11,5 @@
{{ end }}
{{ end }}
</ol>
{{ partial "commons/pagination.html" . }}
{{ partial "commons/pagination.html" . }} */}}
{{ partial "persons/list" . }}
<ol class="persons">
{{ $persons := .Pages.ByParam "last_name" }}
{{ range (.Paginate $persons).Pages }}
<li>
<p class="name"><a href="{{ .Permalink }}">{{ partial "PrepareHTML" .Title }}</a></p>
<li itemscope itemtype="https://schema.org/Person">
<p itemprop="name"><a href="{{ .Permalink }}">{{ partial "PrepareHTML" .Title }}</a></p>
{{- if partial "GetTextFromHTML" .Params.description_short }}
<p>{{- partial "PrepareHTML" .Params.description_short -}}</p>
<p itemprop="jobTitle">{{- partial "PrepareHTML" .Params.description_short -}}</p>
{{ end -}}
</li>
{{/* {{ partial "persons/list-item" . }} */}}
{{ end }}
</ol>
{{ partial "commons/pagination.html" . }}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment