Skip to content

Commit ef971f8

Browse files
committed
Fix team accordion issue
1 parent f737172 commit ef971f8

File tree

4 files changed

+15
-17
lines changed

4 files changed

+15
-17
lines changed

content/english/about/teams.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,8 +93,8 @@ team:
9393
name: Mackenzie Jorgensen PhD
9494
bio: |
9595
Postdoctoral Research Fellow, Northumbria University
96-
accordion_content: ""
9796
linkedIn: "https://www.linkedin.com/in/mackenzie-j-447763142"
97+
accordion_content: ""
9898
- image: /images/people/KProrokovic.jpeg
9999
name: Krsto Proroković
100100
bio: |
@@ -114,7 +114,9 @@ team:
114114
linkedIn: "https://www.linkedin.com/in/joelpersson"
115115
accordion_content: ""
116116
- title: Team software development
117-
content: Part-time team working on software development, among others working on Algorithm Audit's tools and website
117+
content: >-
118+
Part-time team working on software development, among others working on
119+
Algorithm Audit's tools and website
118120
icon: fas fa-code
119121
id: team-SD
120122
team_members:
@@ -174,7 +176,8 @@ team:
174176
Postdoctoral researcher AI, Media and Democracy Lab, University of
175177
Amsterdam
176178
linkedIn: "https://www.linkedin.com/in/laurens-naudts-9a935729"
177-
accordion_content: ""
179+
accordion_content: |
180+
TEST
178181
- title: Executive team
179182
content: Full-time team coordinating the different activities of Algorithm Audit
180183
icon: fas fa-users
@@ -185,14 +188,16 @@ team:
185188
bio: |
186189
Director-board member
187190
linkedIn: "https://www.linkedin.com/in/jfparie/"
191+
accordion_content: ""
188192
- image: /images/people/YRemmits.jpg
189193
name: Ylja Remmits
190194
bio: |
191195
Head of Projects
192196
linkedIn: "https://www.linkedin.com/in/ylja-remmits-21185188"
197+
accordion_content: ""
193198
---
194199

195-
{{< about_AA id="about" >}}
200+
{{< about_AA >}}
196201

197202
{{< team index="5" >}}
198203

layouts/shortcodes/team.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,20 @@ <h3 class="pl-3">{{ .title | markdownify }}
1717
</h3>
1818

1919
{{ end }}
20-
20+
{{ $accordion_team_id := .id }}
2121
<!-- team members -->
2222
<div class="container-team mt-4">
2323
<p>{{ .content | markdownify }}</p>
2424
<div class="row">
25-
{{ range .team_members }}
26-
{{ if .accordion_id}}
25+
{{ range $memberIndex, $teamMember := .team_members }}
26+
{{ if .accordion_content }}
2727
<script>
2828
docReady(function () {
29-
new Accordion('#accordion_area_team_{{.accordion_id}}');
29+
new Accordion('#accordion_area_team_{{$accordion_team_id}}_{{$memberIndex}}');
3030
});
3131
</script>
3232
{{ end }}
33-
<div class="col-md-6 col-12 team-member p-3 " id="accordion_area_team_{{.accordion_id}}">
33+
<div class="col-md-6 col-12 team-member p-3 " id="accordion_area_team_{{$accordion_team_id}}_{{$memberIndex}}">
3434
<div class="row {{if .accordion_content}}ac{{end}}" style="border:none;">
3535
<div class="col-3">
3636
<img src="{{ .image | relURL }}" width="100%;" style="border-radius: 20px;">

tina/collections/shared/page/building_blocks.ts

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -648,13 +648,6 @@ const building_blocks: TinaField[] = [
648648
description:
649649
"If this field is filled, an accordion will be created to show more information",
650650
},
651-
{
652-
type: "string",
653-
name: "accordion_id",
654-
label: "Accordion ID",
655-
description:
656-
"Unique identifier needed to make the accordion work, e.g. use the person's name without spaces and include the team section in it, e.g. coreTeamJohnDoe",
657-
},
658651
],
659652
},
660653
],

tina/tina-lock.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)