Compare commits
2 Commits
2e300ded3c
...
a0c75deba0
Author | SHA1 | Date | |
---|---|---|---|
![]() |
a0c75deba0 | ||
![]() |
1a7418d2cd |
@@ -2,8 +2,9 @@
|
|||||||
|
|
||||||
#show: tultemplate2.with(
|
#show: tultemplate2.with(
|
||||||
title: (cs: "Návod na použití Typst TUL šablony"),
|
title: (cs: "Návod na použití Typst TUL šablony"),
|
||||||
author: "Ondřej Mekina, Matěj Žucha",
|
author: "Ondřej Mekina",
|
||||||
supervisor: "Ondřej Mekina",
|
supervisor: "Ondřej Mekina",
|
||||||
|
consultant: "Matěj Žucha"
|
||||||
)
|
)
|
||||||
|
|
||||||
= Lehký úvod do Typstu a této šablony
|
= Lehký úvod do Typstu a této šablony
|
||||||
|
@@ -18,7 +18,7 @@
|
|||||||
faculty_id, faculty_color, language, assignment_document, citation_file,
|
faculty_id, faculty_color, language, assignment_document, citation_file,
|
||||||
|
|
||||||
// document info
|
// document info
|
||||||
title, author, author_gender, supervisor, study_programme, study_branch, abstract_content,
|
title, author, author_gender, supervisor, consultant, study_programme, study_branch, abstract_content,
|
||||||
keywords,
|
keywords,
|
||||||
|
|
||||||
content
|
content
|
||||||
@@ -41,7 +41,7 @@
|
|||||||
assert_not_none(author_gender, "author gender");
|
assert_not_none(author_gender, "author gender");
|
||||||
}
|
}
|
||||||
|
|
||||||
mainpage(faculty_id, language, "bp", title, author, supervisor, study_programme, study_branch);
|
mainpage(faculty_id, language, "bp", title, author, supervisor, consultant, study_programme, study_branch);
|
||||||
assignment(language, assignment_document);
|
assignment(language, assignment_document);
|
||||||
default_styling(false, faculty_color, {
|
default_styling(false, faculty_color, {
|
||||||
disclaimer(language, faculty_id, "bp", author, author_gender);
|
disclaimer(language, faculty_id, "bp", author, author_gender);
|
||||||
|
@@ -12,7 +12,7 @@
|
|||||||
language, faculty_id, document_type, citation_file, assignment_document,
|
language, faculty_id, document_type, citation_file, assignment_document,
|
||||||
|
|
||||||
// document info
|
// document info
|
||||||
title, author, author_gender, supervisor, study_programme, study_branch, abstract, keywords,
|
title, author, author_gender, supervisor, consultant, study_programme, study_branch, abstract, keywords,
|
||||||
|
|
||||||
// content
|
// content
|
||||||
content,
|
content,
|
||||||
@@ -38,6 +38,7 @@
|
|||||||
author,
|
author,
|
||||||
author_gender,
|
author_gender,
|
||||||
supervisor,
|
supervisor,
|
||||||
|
consultant,
|
||||||
study_programme,
|
study_programme,
|
||||||
study_branch,
|
study_branch,
|
||||||
abstract,
|
abstract,
|
||||||
|
@@ -96,7 +96,7 @@
|
|||||||
faculty_id,
|
faculty_id,
|
||||||
language,
|
language,
|
||||||
document_type,
|
document_type,
|
||||||
title, author, supervisor, study_programme, study_branch,
|
title, author, supervisor, consultant, study_programme, study_branch,
|
||||||
) = {
|
) = {
|
||||||
let info_name_value_padding = 5em;
|
let info_name_value_padding = 5em;
|
||||||
let info_name_min_width = 10em;
|
let info_name_min_width = 10em;
|
||||||
@@ -121,6 +121,7 @@
|
|||||||
("study_branch", study_branch, false),
|
("study_branch", study_branch, false),
|
||||||
("author", author, true),
|
("author", author, true),
|
||||||
("supervisor", supervisor, false),
|
("supervisor", supervisor, false),
|
||||||
|
("consultant", consultant, false),
|
||||||
)
|
)
|
||||||
context {
|
context {
|
||||||
let max_field_name_width = calc.max(..info_fields.map((v) => {
|
let max_field_name_width = calc.max(..info_fields.map((v) => {
|
||||||
@@ -155,13 +156,13 @@
|
|||||||
faculty_id,
|
faculty_id,
|
||||||
language,
|
language,
|
||||||
document_type,
|
document_type,
|
||||||
title, author, supervisor, study_programme, study_branch
|
title, author, supervisor, consultant, study_programme, study_branch
|
||||||
) = {
|
) = {
|
||||||
import "../utils.typ": has_all_none, map_none
|
import "../utils.typ": has_all_none, map_none
|
||||||
let nonetype = type(none);
|
let nonetype = type(none);
|
||||||
page({
|
page({
|
||||||
if has_all_none((
|
if has_all_none((
|
||||||
document_type, title, author, supervisor, study_programme,
|
document_type, title, author, supervisor, consultant, study_programme,
|
||||||
)) {
|
)) {
|
||||||
place(center + horizon, align(left, faculty_logotype(faculty_id, language)));
|
place(center + horizon, align(left, faculty_logotype(faculty_id, language)));
|
||||||
} else {
|
} else {
|
||||||
@@ -169,7 +170,7 @@
|
|||||||
align({
|
align({
|
||||||
info(
|
info(
|
||||||
faculty_id, language, document_type, map_none(title, (v) => v.at(language)),
|
faculty_id, language, document_type, map_none(title, (v) => v.at(language)),
|
||||||
author, supervisor, map_none(study_programme, (v) => v.at(language)),
|
author, supervisor, consultant, map_none(study_programme, (v) => v.at(language)),
|
||||||
map_none(study_branch, (v) => v.at(language)),
|
map_none(study_branch, (v) => v.at(language)),
|
||||||
);
|
);
|
||||||
v(5em);
|
v(5em);
|
||||||
|
@@ -17,14 +17,14 @@
|
|||||||
faculty_id, faculty_color, language, assignment_document, citation_file,
|
faculty_id, faculty_color, language, assignment_document, citation_file,
|
||||||
|
|
||||||
// document info
|
// document info
|
||||||
title, author, _, supervisor, study_programme, study_branch, abstract_content, keywords,
|
title, author, _, supervisor, consultant, study_programme, study_branch, abstract_content, keywords,
|
||||||
|
|
||||||
content
|
content
|
||||||
) = {
|
) = {
|
||||||
assert_not_none(title, "title");
|
assert_not_none(title, "title");
|
||||||
assert_dict_has((language,), title, "title");
|
assert_dict_has((language,), title, "title");
|
||||||
|
|
||||||
mainpage(faculty_id, language, none, title, author, supervisor, study_programme, study_branch);
|
mainpage(faculty_id, language, none, title, author, supervisor, consultant, study_programme, study_branch);
|
||||||
default_styling(true, faculty_color, {
|
default_styling(true, faculty_color, {
|
||||||
toc(language);
|
toc(language);
|
||||||
abbrlist(language);
|
abbrlist(language);
|
||||||
|
@@ -3,6 +3,7 @@
|
|||||||
"author": "Autor",
|
"author": "Autor",
|
||||||
"authors": "Autoři",
|
"authors": "Autoři",
|
||||||
"supervisor": "Vedoucí práce",
|
"supervisor": "Vedoucí práce",
|
||||||
|
"consultant": "Konzultant práce",
|
||||||
"study_programme": "Studijní program",
|
"study_programme": "Studijní program",
|
||||||
"study_branch": "Studijní obor",
|
"study_branch": "Studijní obor",
|
||||||
|
|
||||||
@@ -47,6 +48,7 @@
|
|||||||
"author": "Author",
|
"author": "Author",
|
||||||
"authors": "Authors",
|
"authors": "Authors",
|
||||||
"supervisor": "Supervisor",
|
"supervisor": "Supervisor",
|
||||||
|
"consultant": "Consultant",
|
||||||
"study_programme": "Study programme",
|
"study_programme": "Study programme",
|
||||||
"study_branch": "Study branch",
|
"study_branch": "Study branch",
|
||||||
|
|
||||||
|
@@ -41,7 +41,7 @@
|
|||||||
|
|
||||||
// document info
|
// document info
|
||||||
title: none, keywords: none, abstract: none, author: none, author_gender: none,
|
title: none, keywords: none, abstract: none, author: none, author_gender: none,
|
||||||
supervisor: none, programme: none, branch: none,
|
supervisor: none, consultant: none, programme: none, branch: none,
|
||||||
|
|
||||||
// links
|
// links
|
||||||
assignment: none, citations: "citations.bib",
|
assignment: none, citations: "citations.bib",
|
||||||
@@ -64,6 +64,7 @@
|
|||||||
assert_type_signature(author, "string | none", "author argument");
|
assert_type_signature(author, "string | none", "author argument");
|
||||||
assert_type_signature(author_gender, "string | none", "author gender argument");
|
assert_type_signature(author_gender, "string | none", "author gender argument");
|
||||||
assert_type_signature(supervisor, "string | none", "supervisor argument");
|
assert_type_signature(supervisor, "string | none", "supervisor argument");
|
||||||
|
assert_type_signature(consultant, "string | none", "consultant argument");
|
||||||
assert_type_signature(
|
assert_type_signature(
|
||||||
programme, "dictionary[string : string] | none", "study programme argument"
|
programme, "dictionary[string : string] | none", "study programme argument"
|
||||||
);
|
);
|
||||||
@@ -86,8 +87,8 @@
|
|||||||
// template call
|
// template call
|
||||||
templates.at(style)(
|
templates.at(style)(
|
||||||
lang, faculty, document, citations, assignment,
|
lang, faculty, document, citations, assignment,
|
||||||
title, author, author_gender, supervisor, programme, branch, abstract, keywords,
|
title, author, author_gender, supervisor, consultant,
|
||||||
content
|
programme, branch, abstract, keywords, content
|
||||||
);
|
);
|
||||||
|
|
||||||
import "prototyping.typ": assert_release_ready
|
import "prototyping.typ": assert_release_ready
|
||||||
|
Reference in New Issue
Block a user