Skip to content

Commit

Permalink
Fix bad alignment of the contacts
Browse files Browse the repository at this point in the history
  • Loading branch information
caemor authored and DeveloperPaul123 committed Nov 27, 2024
1 parent 883bc73 commit 423a646
Showing 1 changed file with 44 additions and 41 deletions.
85 changes: 44 additions & 41 deletions lib.typ
Original file line number Diff line number Diff line change
Expand Up @@ -663,53 +663,56 @@
let contacts = {
set box(height: 9pt)

let separator = [#box(sym.bar.v)]

let separator = [ #box(sym.bar.v) ]
let author_list = ()

if ("phone" in author) {
author_list.push[
#phone-icon
#box[#text(author.phone)]
]
}
if ("email" in author) {
author_list.push[
#email-icon
#box[#link("mailto:" + author.email)[#author.email]]
]
}
if ("github" in author) {
author_list.push[
#github-icon
#box[#link("https://github.com/" + author.github)[#author.github]]
]
}
if ("linkedin" in author) {
author_list.push[
#linkedin-icon
#box[
#link("https://www.linkedin.com/in/" + author.linkedin)[#author.firstname #author.lastname]
]
]
}
if ("orcid" in author) {
author_list.push[
#orcid-icon
#box[#link("https://orcid.org/" + author.orcid)[#author.orcid]]
]
}
if ("website" in author) {
author_list.push[
#website-icon
#box[#link(author.website)[#author.website]]
]
}


align(right)[
#set text(
size: 8pt,
weight: "light",
style: "normal",
)
#block[
#align(horizon)[
#stack(
dir: ltr,
spacing: 0.5em,
if ("phone" in author) [
#phone-icon
#box[#text(author.phone)]
#separator
],
if ("email" in author) [
#email-icon
#box[#link("mailto:" + author.email)[#author.email]]
],
if ("github" in author) [
#separator
#github-icon
#box[#link("https://github.com/" + author.github)[#author.github]]
],
if ("linkedin" in author) [
#separator
#linkedin-icon
#box[
#link("https://www.linkedin.com/in/" + author.linkedin)[#author.firstname #author.lastname]
]
],
if ("orcid" in author) [
#separator
#orcid-icon
#box[#link("https://orcid.org/" + author.orcid)[#author.orcid]]
],
if ("website" in author) [
#separator
#website-icon
#box[#link(author.website)[#author.website]]
],
)
]
]
#author_list.join(separator)
]
}

Expand Down

0 comments on commit 423a646

Please sign in to comment.