Skip to content

Commit

Permalink
Ajustement des rôles administratifs, d'enseignement, etc dans la page…
Browse files Browse the repository at this point in the history
… d'une personne (#614)
  • Loading branch information
Olivia206 authored Sep 27, 2024
1 parent 85d4b0d commit 78df220
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 23 deletions.
10 changes: 6 additions & 4 deletions assets/sass/_theme/sections/persons.sass
Original file line number Diff line number Diff line change
Expand Up @@ -211,11 +211,13 @@ ol.persons--list
.informations
@include grid
margin-bottom: $spacing-4
> div:first-of-type
grid-column: 1 / 9
.roles
grid-column: 9 / 13
text-align: right
grid-column: 1 / -1
.biography
grid-column: 1 / 9
+ .roles
grid-column: 9 / 13
text-align: right
.lead + div
margin-top: $spacing-4
.contacts-details ul
Expand Down
42 changes: 23 additions & 19 deletions layouts/persons/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,26 +42,30 @@
{{ end }}

<div class="informations">
<div>
{{ partial "persons/summary.html" (dict
"context" .
) }}
{{ if (partial "GetTextFromHTML" .Content) }}
<div class="rich-text">
{{ partial "PrepareHTML" .Content }}
</div>
{{ end }}
</div>
{{ range $programsForAdministrator }}
{{ $program := . }}
{{ if .Content }}
<div class="biography">
{{ partial "persons/summary.html" (dict
"context" .
) }}
{{ if (partial "GetTextFromHTML" .Content) }}
<div class="rich-text">
{{ partial "PrepareHTML" .Content }}
</div>
{{ end }}
</div>
{{ end }}
{{ if $programsForAdministrator }}
<div class="roles">
{{ range .Params.roles }}
{{ $role := .title }}
{{ if in .persons $slug }}
<p>
{{ safeHTML $role }}<br>
<a href="{{ $program.Permalink }}" class="link">{{ safeHTML $program.Title }}</a>
</p>
{{ range $programsForAdministrator }}
{{ $program := . }}
{{ range .Params.roles }}
{{ $role := .title }}
{{ if in .persons $slug }}
<p>
{{ safeHTML $role }}<br>
<a href="{{ $program.Permalink }}" class="link">{{ safeHTML $program.Title }}</a>
</p>
{{ end }}
{{ end }}
{{ end }}
</div>
Expand Down

0 comments on commit 78df220

Please sign in to comment.