wip: add basic version of a personal website link
This commit is contained in:
119
lib.typ
119
lib.typ
@@ -28,6 +28,7 @@
|
|||||||
#let email-icon = box(fa-icon("envelope", fill: color-darknight))
|
#let email-icon = box(fa-icon("envelope", fill: color-darknight))
|
||||||
#let birth-icon = box(fa-icon("cake", fill: color-darknight))
|
#let birth-icon = box(fa-icon("cake", fill: color-darknight))
|
||||||
#let homepage-icon = box(fa-icon("home", fill: color-darknight))
|
#let homepage-icon = box(fa-icon("home", fill: color-darknight))
|
||||||
|
#let website-icon = box(fa-icon("globe", fill: color-darknight))
|
||||||
|
|
||||||
/// Helpers
|
/// Helpers
|
||||||
|
|
||||||
@@ -114,7 +115,7 @@
|
|||||||
/// -> none
|
/// -> none
|
||||||
#let github-link(github-path) = {
|
#let github-link(github-path) = {
|
||||||
set box(height: 11pt)
|
set box(height: 11pt)
|
||||||
|
|
||||||
align(right + horizon)[
|
align(right + horizon)[
|
||||||
#fa-icon("github", fill: color-darkgray) #link(
|
#fa-icon("github", fill: color-darkgray) #link(
|
||||||
"https://github.com/" + github-path,
|
"https://github.com/" + github-path,
|
||||||
@@ -133,7 +134,7 @@
|
|||||||
body
|
body
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Right section of a tertiaty headers.
|
/// Right section of a tertiaty headers.
|
||||||
/// - body (content): The body of the right header
|
/// - body (content): The body of the right header
|
||||||
#let tertiary-right-header(body) = {
|
#let tertiary-right-header(body) = {
|
||||||
set text(
|
set text(
|
||||||
@@ -176,7 +177,7 @@
|
|||||||
|
|
||||||
/// Resume template that is inspired by the Awesome CV Latex template by posquit0. This template can loosely be considered a port of the original Latex template.
|
/// Resume template that is inspired by the Awesome CV Latex template by posquit0. This template can loosely be considered a port of the original Latex template.
|
||||||
///
|
///
|
||||||
/// The original template: https://github.com/posquit0/Awesome-CV
|
/// The original template: https://github.com/posquit0/Awesome-CV
|
||||||
///
|
///
|
||||||
/// - author (content): Structure that takes in all the author's information
|
/// - author (content): Structure that takes in all the author's information
|
||||||
/// - date (string): The date the resume was created
|
/// - date (string): The date the resume was created
|
||||||
@@ -198,14 +199,14 @@
|
|||||||
if type(accent-color) == "string" {
|
if type(accent-color) == "string" {
|
||||||
accent-color = rgb(accent-color)
|
accent-color = rgb(accent-color)
|
||||||
}
|
}
|
||||||
|
|
||||||
let lang_data = toml("lang.toml")
|
let lang_data = toml("lang.toml")
|
||||||
|
|
||||||
set document(
|
set document(
|
||||||
author: author.firstname + " " + author.lastname,
|
author: author.firstname + " " + author.lastname,
|
||||||
title: "resume",
|
title: "resume",
|
||||||
)
|
)
|
||||||
|
|
||||||
set text(
|
set text(
|
||||||
font: font,
|
font: font,
|
||||||
lang: language,
|
lang: language,
|
||||||
@@ -213,28 +214,33 @@
|
|||||||
fill: color-darkgray,
|
fill: color-darkgray,
|
||||||
fallback: true,
|
fallback: true,
|
||||||
)
|
)
|
||||||
|
|
||||||
set page(
|
set page(
|
||||||
paper: "a4",
|
paper: "a4",
|
||||||
margin: (left: 15mm, right: 15mm, top: 10mm, bottom: 10mm),
|
margin: (left: 15mm, right: 15mm, top: 10mm, bottom: 10mm),
|
||||||
footer: if show-footer [#__resume_footer(author, language, lang_data, date)] else [],
|
footer: if show-footer [#__resume_footer(
|
||||||
|
author,
|
||||||
|
language,
|
||||||
|
lang_data,
|
||||||
|
date,
|
||||||
|
)] else [],
|
||||||
footer-descent: 0pt,
|
footer-descent: 0pt,
|
||||||
)
|
)
|
||||||
|
|
||||||
// set paragraph spacing
|
// set paragraph spacing
|
||||||
show par: set block(
|
show par: set block(
|
||||||
above: 0.75em,
|
above: 0.75em,
|
||||||
below: 0.75em,
|
below: 0.75em,
|
||||||
)
|
)
|
||||||
set par(justify: true)
|
set par(justify: true)
|
||||||
|
|
||||||
set heading(
|
set heading(
|
||||||
numbering: none,
|
numbering: none,
|
||||||
outlined: false,
|
outlined: false,
|
||||||
)
|
)
|
||||||
|
|
||||||
show heading.where(level: 1): it => [
|
show heading.where(level: 1): it => [
|
||||||
|
|
||||||
#set block(
|
#set block(
|
||||||
above: 1em,
|
above: 1em,
|
||||||
below: 1em,
|
below: 1em,
|
||||||
@@ -243,7 +249,7 @@
|
|||||||
size: 16pt,
|
size: 16pt,
|
||||||
weight: "regular",
|
weight: "regular",
|
||||||
)
|
)
|
||||||
|
|
||||||
#align(left)[
|
#align(left)[
|
||||||
#let color = if colored-headers {
|
#let color = if colored-headers {
|
||||||
accent-color
|
accent-color
|
||||||
@@ -253,9 +259,9 @@
|
|||||||
#text[#strong[#text(color)[#it.body.text]]]
|
#text[#strong[#text(color)[#it.body.text]]]
|
||||||
#box(width: 1fr, line(length: 100%))
|
#box(width: 1fr, line(length: 100%))
|
||||||
]
|
]
|
||||||
|
|
||||||
]
|
]
|
||||||
|
|
||||||
show heading.where(level: 2): it => {
|
show heading.where(level: 2): it => {
|
||||||
set text(
|
set text(
|
||||||
color-darkgray,
|
color-darkgray,
|
||||||
@@ -265,7 +271,7 @@
|
|||||||
)
|
)
|
||||||
it.body
|
it.body
|
||||||
}
|
}
|
||||||
|
|
||||||
show heading.where(level: 3): it => {
|
show heading.where(level: 3): it => {
|
||||||
set text(
|
set text(
|
||||||
size: 10pt,
|
size: 10pt,
|
||||||
@@ -273,7 +279,7 @@
|
|||||||
)
|
)
|
||||||
smallcaps[#it.body]
|
smallcaps[#it.body]
|
||||||
}
|
}
|
||||||
|
|
||||||
let name = {
|
let name = {
|
||||||
align(center)[
|
align(center)[
|
||||||
#pad(bottom: 5pt)[
|
#pad(bottom: 5pt)[
|
||||||
@@ -296,7 +302,7 @@
|
|||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
let positions = {
|
let positions = {
|
||||||
set text(
|
set text(
|
||||||
accent-color,
|
accent-color,
|
||||||
@@ -311,7 +317,7 @@
|
|||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
let address = {
|
let address = {
|
||||||
set text(
|
set text(
|
||||||
size: 9pt,
|
size: 9pt,
|
||||||
@@ -323,12 +329,12 @@
|
|||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
let contacts = {
|
let contacts = {
|
||||||
set box(height: 9pt)
|
set box(height: 9pt)
|
||||||
|
|
||||||
let separator = box(width: 5pt)
|
let separator = box(width: 5pt)
|
||||||
|
|
||||||
align(center)[
|
align(center)[
|
||||||
#set text(
|
#set text(
|
||||||
size: 9pt,
|
size: 9pt,
|
||||||
@@ -384,11 +390,16 @@
|
|||||||
#orcid-icon
|
#orcid-icon
|
||||||
#box[#link("https://orcid.org/" + author.orcid)[#author.orcid]]
|
#box[#link("https://orcid.org/" + author.orcid)[#author.orcid]]
|
||||||
]
|
]
|
||||||
|
#if ("website" in author) [
|
||||||
|
#separator
|
||||||
|
#website-icon
|
||||||
|
#box[#link(author.website)[#author.website]]
|
||||||
|
]
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
name
|
name
|
||||||
positions
|
positions
|
||||||
address
|
address
|
||||||
@@ -396,7 +407,7 @@
|
|||||||
body
|
body
|
||||||
}
|
}
|
||||||
|
|
||||||
/// The base item for resume entries.
|
/// The base item for resume entries.
|
||||||
/// This formats the item for the resume entries. Typically your body would be a bullet list of items. Could be your responsibilities at a company or your academic achievements in an educational background section.
|
/// This formats the item for the resume entries. Typically your body would be a bullet list of items. Could be your responsibilities at a company or your academic achievements in an educational background section.
|
||||||
/// - body (content): The body of the resume entry
|
/// - body (content): The body of the resume entry
|
||||||
#let resume-item(body) = {
|
#let resume-item(body) = {
|
||||||
@@ -433,7 +444,7 @@
|
|||||||
} else {
|
} else {
|
||||||
title-content = title
|
title-content = title
|
||||||
}
|
}
|
||||||
|
|
||||||
pad[
|
pad[
|
||||||
#justified-header(title-content, location)
|
#justified-header(title-content, location)
|
||||||
#if description != "" or date != "" [
|
#if description != "" or date != "" [
|
||||||
@@ -469,7 +480,7 @@
|
|||||||
#let resume-skill-item(category, items) = {
|
#let resume-skill-item(category, items) = {
|
||||||
set block(below: 0.65em)
|
set block(below: 0.65em)
|
||||||
set pad(top: 2pt)
|
set pad(top: 2pt)
|
||||||
|
|
||||||
pad[
|
pad[
|
||||||
#grid(
|
#grid(
|
||||||
columns: (20fr, 80fr),
|
columns: (20fr, 80fr),
|
||||||
@@ -494,7 +505,7 @@
|
|||||||
|
|
||||||
/// ---- Coverletter ----
|
/// ---- Coverletter ----
|
||||||
|
|
||||||
/// Cover letter template that is inspired by the Awesome CV Latex template by posquit0. This template can loosely be considered a port of the original Latex template.
|
/// Cover letter template that is inspired by the Awesome CV Latex template by posquit0. This template can loosely be considered a port of the original Latex template.
|
||||||
/// This coverletter template is designed to be used with the resume template.
|
/// This coverletter template is designed to be used with the resume template.
|
||||||
/// - author (content): Structure that takes in all the author's information
|
/// - author (content): Structure that takes in all the author's information
|
||||||
/// - profile-picture (image): The profile picture of the author. This will be cropped to a circle and should be square in nature.
|
/// - profile-picture (image): The profile picture of the author. This will be cropped to a circle and should be square in nature.
|
||||||
@@ -514,15 +525,15 @@
|
|||||||
if type(accent-color) == "string" {
|
if type(accent-color) == "string" {
|
||||||
accent-color = rgb(accent-color)
|
accent-color = rgb(accent-color)
|
||||||
}
|
}
|
||||||
|
|
||||||
// language data
|
// language data
|
||||||
let lang_data = toml("lang.toml")
|
let lang_data = toml("lang.toml")
|
||||||
|
|
||||||
set document(
|
set document(
|
||||||
author: author.firstname + " " + author.lastname,
|
author: author.firstname + " " + author.lastname,
|
||||||
title: "cover-letter",
|
title: "cover-letter",
|
||||||
)
|
)
|
||||||
|
|
||||||
set text(
|
set text(
|
||||||
font: font,
|
font: font,
|
||||||
lang: language,
|
lang: language,
|
||||||
@@ -530,26 +541,31 @@
|
|||||||
fill: color-darkgray,
|
fill: color-darkgray,
|
||||||
fallback: true,
|
fallback: true,
|
||||||
)
|
)
|
||||||
|
|
||||||
set page(
|
set page(
|
||||||
paper: "a4",
|
paper: "a4",
|
||||||
margin: (left: 15mm, right: 15mm, top: 10mm, bottom: 10mm),
|
margin: (left: 15mm, right: 15mm, top: 10mm, bottom: 10mm),
|
||||||
footer: if show-footer [#__coverletter_footer(author, language, date, lang_data)] else [],
|
footer: if show-footer [#__coverletter_footer(
|
||||||
|
author,
|
||||||
|
language,
|
||||||
|
date,
|
||||||
|
lang_data,
|
||||||
|
)] else [],
|
||||||
footer-descent: 0pt,
|
footer-descent: 0pt,
|
||||||
)
|
)
|
||||||
|
|
||||||
// set paragraph spacing
|
// set paragraph spacing
|
||||||
show par: set block(
|
show par: set block(
|
||||||
above: 0.75em,
|
above: 0.75em,
|
||||||
below: 0.75em,
|
below: 0.75em,
|
||||||
)
|
)
|
||||||
set par(justify: true)
|
set par(justify: true)
|
||||||
|
|
||||||
set heading(
|
set heading(
|
||||||
numbering: none,
|
numbering: none,
|
||||||
outlined: false,
|
outlined: false,
|
||||||
)
|
)
|
||||||
|
|
||||||
show heading: it => [
|
show heading: it => [
|
||||||
#set block(
|
#set block(
|
||||||
above: 1em,
|
above: 1em,
|
||||||
@@ -559,13 +575,13 @@
|
|||||||
size: 16pt,
|
size: 16pt,
|
||||||
weight: "regular",
|
weight: "regular",
|
||||||
)
|
)
|
||||||
|
|
||||||
#align(left)[
|
#align(left)[
|
||||||
#text[#strong[#text(accent-color)[#it.body.text]]]
|
#text[#strong[#text(accent-color)[#it.body.text]]]
|
||||||
#box(width: 1fr, line(length: 100%))
|
#box(width: 1fr, line(length: 100%))
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
|
||||||
let name = {
|
let name = {
|
||||||
align(right)[
|
align(right)[
|
||||||
#pad(bottom: 5pt)[
|
#pad(bottom: 5pt)[
|
||||||
@@ -584,12 +600,12 @@
|
|||||||
#text(accent-color, weight: "thin")[#author.firstname]
|
#text(accent-color, weight: "thin")[#author.firstname]
|
||||||
#text(weight: "bold")[#author.lastname]
|
#text(weight: "bold")[#author.lastname]
|
||||||
]
|
]
|
||||||
|
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
let positions = {
|
let positions = {
|
||||||
set text(
|
set text(
|
||||||
accent-color,
|
accent-color,
|
||||||
@@ -604,7 +620,7 @@
|
|||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
let address = {
|
let address = {
|
||||||
set text(
|
set text(
|
||||||
size: 9pt,
|
size: 9pt,
|
||||||
@@ -617,12 +633,12 @@
|
|||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
let contacts = {
|
let contacts = {
|
||||||
set box(height: 9pt)
|
set box(height: 9pt)
|
||||||
|
|
||||||
let separator = [#box(sym.bar.v)]
|
let separator = [#box(sym.bar.v)]
|
||||||
|
|
||||||
align(right)[
|
align(right)[
|
||||||
#set text(
|
#set text(
|
||||||
size: 8pt,
|
size: 8pt,
|
||||||
@@ -659,13 +675,18 @@
|
|||||||
#separator
|
#separator
|
||||||
#orcid-icon
|
#orcid-icon
|
||||||
#box[#link("https://orcid.org/" + author.orcid)[#author.orcid]]
|
#box[#link("https://orcid.org/" + author.orcid)[#author.orcid]]
|
||||||
],
|
],
|
||||||
|
if ("website" in author) [
|
||||||
|
#separator
|
||||||
|
#website-icon
|
||||||
|
#box[#link(author.website)[#author.website]]
|
||||||
|
],
|
||||||
)
|
)
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
let letter-heading = {
|
let letter-heading = {
|
||||||
grid(
|
grid(
|
||||||
columns: (1fr, 2fr),
|
columns: (1fr, 2fr),
|
||||||
@@ -688,7 +709,7 @@
|
|||||||
],
|
],
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
let letter-conclusion = {
|
let letter-conclusion = {
|
||||||
align(bottom)[
|
align(bottom)[
|
||||||
#pad(bottom: 2em)[
|
#pad(bottom: 2em)[
|
||||||
@@ -704,7 +725,7 @@
|
|||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
// actual content
|
// actual content
|
||||||
letter-heading
|
letter-heading
|
||||||
body
|
body
|
||||||
@@ -726,7 +747,7 @@
|
|||||||
][
|
][
|
||||||
#text(weight: "light", style: "italic", size: 9pt)[#date]
|
#text(weight: "light", style: "italic", size: 9pt)[#date]
|
||||||
]
|
]
|
||||||
|
|
||||||
#pad(top: 0.65em, bottom: 0.65em)[
|
#pad(top: 0.65em, bottom: 0.65em)[
|
||||||
#text(weight: "regular", fill: color-gray, size: 9pt)[
|
#text(weight: "regular", fill: color-gray, size: 9pt)[
|
||||||
#smallcaps[#entity-info.name] \
|
#smallcaps[#entity-info.name] \
|
||||||
@@ -743,7 +764,7 @@
|
|||||||
/// - dear (string): optional field for redefining the "dear" variable
|
/// - dear (string): optional field for redefining the "dear" variable
|
||||||
#let letter-heading(job-position: "", addressee: "", dear: "") = {
|
#let letter-heading(job-position: "", addressee: "", dear: "") = {
|
||||||
let lang_data = toml("lang.toml")
|
let lang_data = toml("lang.toml")
|
||||||
|
|
||||||
// TODO: Make this adaptable to content
|
// TODO: Make this adaptable to content
|
||||||
underline(evade: false, stroke: 0.5pt, offset: 0.3em)[
|
underline(evade: false, stroke: 0.5pt, offset: 0.3em)[
|
||||||
#text(weight: "bold", size: 12pt)[Job Application for #job-position]
|
#text(weight: "bold", size: 12pt)[Job Application for #job-position]
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
#import "@preview/modern-cv:0.5.0": *
|
#import "@preview/modern-cv:0.7.0": *
|
||||||
|
|
||||||
#show: coverletter.with(
|
#show: coverletter.with(
|
||||||
author: (
|
author: (
|
||||||
@@ -10,6 +10,7 @@
|
|||||||
github: "DeveloperPaul123",
|
github: "DeveloperPaul123",
|
||||||
linkedin: "John Smith",
|
linkedin: "John Smith",
|
||||||
address: "111 Example St. Apt. 111, Example City, EX 11111",
|
address: "111 Example St. Apt. 111, Example City, EX 11111",
|
||||||
|
website: "https://www.github.com/DeveloperPaul123",
|
||||||
positions: (
|
positions: (
|
||||||
"Software Engineer",
|
"Software Engineer",
|
||||||
"Full Stack Developer",
|
"Full Stack Developer",
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
#import "@preview/modern-cv:0.6.0": *
|
#import "@preview/modern-cv:0.7.0": *
|
||||||
|
|
||||||
#show: resume.with(
|
#show: resume.with(
|
||||||
author: (
|
author: (
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "modern-cv"
|
name = "modern-cv"
|
||||||
version = "0.6.0"
|
version = "0.7.0"
|
||||||
compiler = "0.11.0"
|
compiler = "0.11.0"
|
||||||
entrypoint = "lib.typ"
|
entrypoint = "lib.typ"
|
||||||
authors = ["Paul Tsouchlos <https://github.com/DeveloperPaul123>"]
|
authors = ["Paul Tsouchlos <https://github.com/DeveloperPaul123>"]
|
||||||
|
|||||||
Reference in New Issue
Block a user