Skip to content

Commit 8678858

Browse files
Merge branch 'main' into issue-48-people-pages
2 parents 23c6a83 + 7e41eb5 commit 8678858

23 files changed

+365
-126
lines changed

_quarto.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,13 @@ website:
1313
repo-url: https://github.com/lmu-osc/lmu-osc.github.io
1414
repo-actions: [edit, issue]
1515

16+
announcement:
17+
icon: info-circle
18+
dismissable: true
19+
content: "**Thanks for visiting the LMU Open Science Center--our site is still under construction for now, but we'll be live soon!**"
20+
type: primary
21+
position: below-navbar
22+
1623
navbar:
1724
title: false
1825
background: "#2b864b"
@@ -39,6 +46,7 @@ website:
3946
- open-research-cycle.qmd
4047
- text: People
4148
icon: people
49+
# href: people/overview.qmd
4250
menu:
4351
- people/overview.qmd
4452
- people/management.qmd
@@ -98,6 +106,7 @@ format:
98106
css:
99107
- https://raw.githubusercontent.com/lmu-osc/branding-resources/refs/heads/main/styles.css
100108
- custom-navbar.css
109+
- styles.css
101110
toc: true
102111
include-in-header:
103112
- file: matomo_analytics.html

boards.qmd

Lines changed: 0 additions & 3 deletions
This file was deleted.

leadership.qmd

Lines changed: 0 additions & 3 deletions
This file was deleted.

members.qmd

Lines changed: 0 additions & 3 deletions
This file was deleted.

people/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
2+
This file describes the structure of the `people/` directory.

people/_people_template.qmd

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,10 @@ publications:
4949

5050

5151
<!-- The "includes" below are templates for the different sections of the
52-
member profile pages. Each document returns an R object that contains the
53-
necessary HTML elements to render the section.
52+
member profile pages. Each document returns one or several R objects that
53+
contains the necessary HTML elements to render the section.
5454
1. You can modify these templates to change the layout or content of each section. This will change the layout of all member profiles the next time the site is built.
55+
- Make sure to keep using the HTMLtools functions like `div()`, `p()`, `img()`, etc. to create the HTML structure if you are creating an R object. Otherwise, the HTML will not render correctly--extra <a> tags will be added to your elements and this messes with spacing. Raw HTML, however, will work as expected.
5556
2. You can also create new templates for additional sections if needed.
5657
3. If you want to add some custom content for an individual member, you can do so directly in the member's .QMD file, outside of the includes. You will then need to insert the new R object containing HTML into the `profile` object below.
5758
-->

people/add_people_id.R

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
2+
3+
file2 <- c("00001_felix example 2.qmd",
4+
"00002_felix example 3.qmd",
5+
"00003_felix example 4.qmd")
6+
7+
8+
# check if file already has 5 leading digits
9+
str_detect(file2, "\\d{5}.*.qmd")
10+
11+
# create string for new max value
12+
find_and_pad_next_id <- function(files) {
13+
# Extract the numeric part from the file names
14+
ids <- str_extract(file2, "\\d{5}") %>%
15+
as.numeric()
16+
17+
# Find the maximum ID and increment it by 1
18+
next_id <- max(ids, na.rm = TRUE) + 1
19+
20+
# Format the new ID with leading zeros
21+
str_pad(as.character(next_id), width = 5, side = "left", pad = "0")
22+
}
23+
# str_extract(file2, "\\d{5}") %>%
24+
# as.numeric() %>%
25+
# {max(.) + 1} %>%
26+
# str_pad(width = 5, side = "left", pad = "0")
27+
28+
29+
# find_current_max_id(file2)
30+
31+
# files <- c(list.files("./people/profiles"), file2)
32+
33+
# untagged_files <- files[!str_detect(files, "\\d{5}.*.qmd")]
34+
35+
# find_and_pad_next_id(file2)
36+
37+
find_current_max_id <- function(files) {
38+
# Extract the numeric part from the file names
39+
ids <- str_extract(files, "\\d{5}") %>%
40+
as.numeric()
41+
42+
# Find the maximum ID
43+
if (all(is.na(ids)) | length(ids) == 0) {
44+
return(0) # If no IDs found, return 0
45+
}
46+
max(ids, na.rm = TRUE)
47+
}
48+
49+
tag_files <- function(files) {
50+
untagged_files <- files[!str_detect(files, "\\d{5}.*.qmd")]
51+
current_max_id <- find_current_max_id(files)
52+
new_labels <- vector("character", length(untagged_files))
53+
vec_position <- 0
54+
for (file in untagged_files) {
55+
vec_position <- vec_position + 1
56+
current_max_id <- current_max_id + 1
57+
new_label <- str_pad(as.character(current_max_id), width = 5, side = "left", pad = "0")
58+
new_labels[vec_position] <- paste0(new_label, "_", file)
59+
}
60+
return(new_labels)
61+
}
62+
63+
# provided a vector with existing number tags
64+
tag_files(files)
65+
66+
# bootstrap from 0 i.e. none of the # files have a 5 digit number tag
67+
files[!str_detect(files, "\\d{5}.*.qmd")] %>%
68+
tag_files()
69+
70+
71+
72+
73+
74+

people/management.qmd

Lines changed: 1 addition & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -11,93 +11,4 @@ listing:
1111
---
1212

1313
::: {#management}
14-
:::
15-
16-
17-
<!--
18-
```{=html}
19-
20-
21-
22-
23-
24-
<div class="card mb-3">
25-
<h4 class="card-header">
26-
Managing Director of Open Science Center
27-
</h4>
28-
<div class="row g-0">
29-
<div class="col-md-3 d-flex justify-content-center align-items-center">
30-
<a href="people/felix_example.qmd">
31-
<img src="/people/images/felix.jpeg" class="profile-image" alt="...">
32-
</a>
33-
</div>
34-
<div class="col-md-1 d-flex flex-row flex-md-column justify-content-center align-items-center gap-3">
35-
<a href="https://linkedin.com" target="_blank" class="d-inline-block" aria-label="LinkedIn">
36-
<i class="fa-brands fa-linkedin fa-2xl" aria-hidden="true"></i>
37-
</a>
38-
<a href="https://github.com" target="_blank" class="d-inline-block" aria-label="GitHub">
39-
<i class="fa-brands fa-github fa-2xl" aria-hidden="true"></i>
40-
</a>
41-
<a href="https://bluesky.com" target="_blank" class="d-inline-block" aria-label="Bluesky">
42-
<i class="fa-brands fa-bluesky fa-2xl" aria-hidden="true"></i>
43-
</a>
44-
<a href="https://orcid.org" target="_blank" class="d-inline-block" aria-label="ORCID">
45-
<i class="fa-brands fa-orcid fa-2xl" aria-hidden="true"></i>
46-
</a>
47-
</div>
48-
<div class="col-md-8">
49-
<div class="card-body">
50-
<h4 class="card-title" >Felix Schönbrodt</h4>
51-
<div class="d-flex justify-content-between align-items-center">
52-
<h5 class="card-subtitle mb-0">Prof. Dr.</h5>
53-
<h5 class="mb-0">LMU Psychology</h5>
54-
</div>
55-
<p class="card-text">Professor at the Department of Psychology, Ludwig-Maximilians-Universität München, Germany. Managing director of the LMU Open Science Center and board member of the META-REP priority program ("A meta-scientific research program to analyse and optimise replicability in the behavioral, social, and cognitive Sciences"). Interested in Open Science, Metascience, implicit motives, machine learning, responsible research assessment (CoARA), solarpunk, piano, and cooking.</p>
56-
<a href="people/felix_example.qmd" class="btn btn-primary">Read More!</a>
57-
58-
</div>
59-
</div>
60-
</div>
61-
</div>
62-
63-
64-
<div class="card mb-3">
65-
<h4 class="card-header">
66-
Scientific Coordinator
67-
</h4>
68-
<div class="row g-0">
69-
<div class="col-md-3 d-flex justify-content-center align-items-center">
70-
<a href="people/malika_ihle.qmd">
71-
<img src="/people/images/malika.jpeg" class="profile-image" alt="...">
72-
</a>
73-
</div>
74-
<div class="col-md-1 d-flex flex-row flex-md-column justify-content-center align-items-center gap-3">
75-
<a href="https://linkedin.com" target="_blank" class="d-inline-block" aria-label="LinkedIn">
76-
<i class="fa-brands fa-linkedin fa-2xl" aria-hidden="true"></i>
77-
</a>
78-
<a href="https://github.com" target="_blank" class="d-inline-block" aria-label="GitHub">
79-
<i class="fa-brands fa-github fa-2xl" aria-hidden="true"></i>
80-
</a>
81-
<a href="https://bluesky.com" target="_blank" class="d-inline-block" aria-label="Bluesky">
82-
<i class="fa-brands fa-bluesky fa-2xl" aria-hidden="true"></i>
83-
</a>
84-
<a href="https://orcid.org" target="_blank" class="d-inline-block" aria-label="ORCID">
85-
<i class="fa-brands fa-orcid fa-2xl" aria-hidden="true"></i>
86-
</a>
87-
</div>
88-
<div class="col-md-8">
89-
<div class="card-body">
90-
<h4 class="card-title" >Malika Ihle</h4>
91-
<div class="d-flex justify-content-between align-items-center">
92-
<h5 class="card-subtitle mb-0">Dr.</h5>
93-
<h5 class="mb-0">LMU OSC</h5>
94-
</div>
95-
<p class="card-text">Malika Ihle is the LMU Open Science Center Coordinator, supporting the scientific board in developing a comprehensive approach to open research that extends across all disciplines, using both bottom-up and top-down strategies. Her role is to provide peer-to-peer training and develop an open research curriculum, coordinate grassroots initiatives and organise various events such as seminars and conferences, support meta-research collaborations, liaise with local, national (e.g. the German Reproducibility Network (GRN)), and international stakeholders to inform the design of incentives and policies, and co-develop a strategic plan to make the LMU Open Science Center a sustainable entity.</p>
96-
<a href="people/felix_example.qmd" class="btn btn-primary">Read More!</a>
97-
98-
</div>
99-
</div>
100-
</div>
101-
</div>
102-
103-
``` -->
14+
:::

people/members.qmd

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,61 @@ listing:
1111
---
1212

1313
::: {#members}
14+
=======
15+
format:
16+
html:
17+
toc: true
18+
toc-depth: 1
19+
css:
20+
- people.css
21+
page-layout: full
22+
include-in-header:
23+
- text: |
24+
<script src="../assets/javascript/display_name_hover.js" defer></script>
25+
title: "Members"
26+
editor: source
27+
repo-actions: false
28+
listing:
29+
- id: lmu-individual-listing
30+
categories: true
31+
contents: profiles
32+
template: people-listing.ejs
33+
include:
34+
membertype: "lmu-individual"
35+
- id: associated-member-listing
36+
contents: profiles
37+
template: people-listing.ejs
38+
include:
39+
membertype: "associate"
40+
- id: fellow-listing
41+
contents: profiles
42+
template: people-listing.ejs
43+
include:
44+
membertype: fellow
45+
- id: previous-member-listing
46+
contents: profiles
47+
template: people-listing.ejs
48+
include:
49+
membertype: "former"
50+
---
51+
52+
53+
54+
55+
56+
# LMU Members
57+
::: {#lmu-individual-listing}
58+
:::
59+
60+
# Associated Members
61+
::: {#associated-member-listing}
62+
:::
63+
64+
# Fellows
65+
::: {#fellow-listing}
66+
:::
67+
68+
69+
## Previous Members
70+
::: {#previous-member-listing}
1471
:::

people/overview.qmd

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
---
22
title: "Overview"
3-
---
3+
---
4+
5+
This page will have some graphics and information about how many members we have, how many are active, etc. It will also link to the leadership, staff, etc. pages

0 commit comments

Comments
 (0)