feat: add documantation page

This commit is contained in:
Kristofers Solo 2025-08-22 21:48:12 +03:00
parent 0986808ab3
commit 28f93156cb
Signed by: kristoferssolo
GPG Key ID: 8687F2D3EEE6F0ED
4 changed files with 89 additions and 11 deletions

View File

@ -21,8 +21,19 @@
email: "zk67890@edu.lu.lv", email: "zk67890@edu.lu.lv",
), ),
), ),
date: ( advisors: (
(
title: "Mg. dat.",
name: "Ivars Ozoliņš",
),
),
reviewer: (
name: "Jānis Ozols",
),
date: datetime(
year: 2025, year: 2025,
month: 1,
day: 1,
), ),
place: "Rīga", place: "Rīga",
bibliography: bibliography("bibliography.yml"), bibliography: bibliography("bibliography.yml"),

View File

@ -11,6 +11,7 @@
// location, and email. Everything but but the `name` and `code` is optional. // location, and email. Everything but but the `name` and `code` is optional.
authors: (), authors: (),
advisors: (), advisors: (),
reviewer: (),
// The paper's abstract. Can be omitted if you don't have one. // The paper's abstract. Can be omitted if you don't have one.
abstract: ( abstract: (
primary: ( primary: (
@ -33,11 +34,7 @@
university: "Latvijas Universitāte", university: "Latvijas Universitāte",
faculty: [Eksakto zinātņu un tehnoloģiju fakultāte\ Datorikas nodaļa], faculty: [Eksakto zinātņu un tehnoloģiju fakultāte\ Datorikas nodaļa],
thesis-type: "Bakalaura darbs", thesis-type: "Bakalaura darbs",
date: ( date: datetime.today(),
year: none,
month: none,
day: none,
),
place: none, place: none,
logo: none, logo: none,
outline-title: "SATURS", outline-title: "SATURS",
@ -253,5 +250,12 @@
// Display bibliography. // Display bibliography.
bibliography bibliography
make-documentary-page() make-documentary-page(
title,
authors,
advisors,
reviewer,
thesis-type,
date,
)
} }

View File

@ -92,7 +92,68 @@
v(0.5fr) v(0.5fr)
align(center, upper([#place #date.year])) align(center, upper([#place #date.year()]))
} }
#let make-documentary-page() = {} #let make-documentary-page(
title,
authors,
advisors,
reviewer,
thesis-type,
date,
) = {
let vspace = 1fr
set page(numbering: none)
let formatted-date = strong(date.display("[day].[month].[year]."))
heading(level: 1, outlined: false, numbering: none, "Dokumentārā lapa")
[
#thesis-type "*#title*" ir
izstrādāts Latvijas Universitātes Eksakto zinātņu un tehnoloģiju fakultātē,
Datorikas nodaļā.
#v(vspace / 3)
Ar savu parakstu apliecinu, ka darbs izstrādāts patstāvīgi, izmantoti tikai tajā
norādītie informācijas avoti un iesniegtā darba elektroniskā kopija atbilst
izdrukai un/vai recenzentam uzrādītajai darba versijai.
]
context {
set par(
first-line-indent: 1cm,
hanging-indent: 1cm,
)
v(vspace / 2)
[
#if authors.len() > 1 { "Autori: " } else { "Autors: " }
#authors.map(author => [*#author.name, #author.code*]).join(", ")
~ #formatted-date
]
v(vspace)
[
Rekomendēju darbu aizstāvēšanai\
#if advisors.len() > 0 [
Darba #if advisors.len() > 1 { "vadītāji:" } else { "vadītājs:" }
#advisors.map(advisor => [*#advisor.title #advisor.name*]).join("\n")
~ #formatted-date
]
]
v(vspace)
[Recenzents: *#reviewer.name*]
v(vspace)
[
Darbs iesniegs #formatted-date\
Kvalifikācijas darbu pārbaudījumu komisijas sekretārs (elektronisks paraksts)
]
v(vspace)
}
}

View File

@ -22,9 +22,11 @@
name: "Ivars Ozoliņš", name: "Ivars Ozoliņš",
), ),
), ),
date: ( date: datetime(
year: 2025, year: 2025,
), month: 1,
day: 1,
), // defaults to datetime.today()
place: "Rīga", place: "Rīga",
bibliography: bibliography("bibliography.yml"), bibliography: bibliography("bibliography.yml"),
abstract: ( abstract: (