add year of study to document info
This commit is contained in:
@@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
// document info
|
// document info
|
||||||
title, author, author_gender, supervisor, consultant, study_programme, study_branch,
|
title, author, author_gender, supervisor, consultant, study_programme, study_branch,
|
||||||
abstract_content, acknowledgement_content, keywords,
|
year_of_study, abstract_content, acknowledgement_content, keywords,
|
||||||
|
|
||||||
content
|
content
|
||||||
) = {
|
) = {
|
||||||
@@ -49,7 +49,7 @@
|
|||||||
|
|
||||||
mainpage(
|
mainpage(
|
||||||
faculty_id, language, "bp", title, author, supervisor, consultant, study_programme,
|
faculty_id, language, "bp", title, author, supervisor, consultant, study_programme,
|
||||||
study_branch,
|
study_branch, year_of_study,
|
||||||
);
|
);
|
||||||
assignment(language, assignment_document);
|
assignment(language, assignment_document);
|
||||||
default_styling(false, faculty_color, {
|
default_styling(false, faculty_color, {
|
||||||
|
@@ -12,8 +12,8 @@
|
|||||||
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, consultant, study_programme, study_branch, abstract,
|
title, author, author_gender, supervisor, consultant, study_programme, study_branch,
|
||||||
acknowledgement, keywords,
|
year_of_study, abstract, acknowledgement, keywords,
|
||||||
|
|
||||||
// content
|
// content
|
||||||
content,
|
content,
|
||||||
@@ -42,6 +42,7 @@
|
|||||||
consultant,
|
consultant,
|
||||||
study_programme,
|
study_programme,
|
||||||
study_branch,
|
study_branch,
|
||||||
|
year_of_study,
|
||||||
abstract,
|
abstract,
|
||||||
acknowledgement,
|
acknowledgement,
|
||||||
keywords,
|
keywords,
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
#import "../theme.typ": faculty_logotype, tul_logomark, faculty_color
|
#import "../theme.typ": faculty_logotype, tul_logomark, faculty_color
|
||||||
#import "../lang.typ": get_lang_item
|
#import "../lang.typ": get_lang_item
|
||||||
#import "../utils.typ": is_none, assert_dict_has
|
#import "../utils.typ": is_none, assert_dict_has, map_none
|
||||||
|
|
||||||
#let base_font = "Inter";
|
#let base_font = "Inter";
|
||||||
#let mono_font = "Noto Sans Mono";
|
#let mono_font = "Noto Sans Mono";
|
||||||
@@ -119,7 +119,7 @@
|
|||||||
faculty_id,
|
faculty_id,
|
||||||
language,
|
language,
|
||||||
document_type,
|
document_type,
|
||||||
title, author, supervisor, consultant, study_programme, study_branch,
|
title, author, supervisor, consultant, study_programme, study_branch, year_of_study,
|
||||||
) = {
|
) = {
|
||||||
let info_name_value_padding = 5em;
|
let info_name_value_padding = 5em;
|
||||||
let info_name_min_width = 10em;
|
let info_name_min_width = 10em;
|
||||||
@@ -141,11 +141,12 @@
|
|||||||
// other info
|
// other info
|
||||||
// [field_name, field_value, bold]
|
// [field_name, field_value, bold]
|
||||||
let info_fields = (
|
let info_fields = (
|
||||||
("study_programme", study_programme, false),
|
|
||||||
("study_branch", study_branch, false),
|
|
||||||
("author", author, true),
|
("author", author, true),
|
||||||
("supervisor", person_info(supervisor, "supervisor"), false),
|
("supervisor", person_info(supervisor, "supervisor"), false),
|
||||||
("consultant", person_info(consultant, "consultant"), false),
|
("consultant", person_info(consultant, "consultant"), false),
|
||||||
|
("study_programme", study_programme, false),
|
||||||
|
("study_branch", study_branch, false),
|
||||||
|
("year_of_study", map_none(year_of_study, (v) => str(v) + "."), 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) => {
|
||||||
@@ -180,7 +181,7 @@
|
|||||||
faculty_id,
|
faculty_id,
|
||||||
language,
|
language,
|
||||||
document_type,
|
document_type,
|
||||||
title, author, supervisor, consultant, study_programme, study_branch
|
title, author, supervisor, consultant, study_programme, study_branch, year_of_study,
|
||||||
) = {
|
) = {
|
||||||
import "../utils.typ": has_all_none, map_none
|
import "../utils.typ": has_all_none, map_none
|
||||||
let nonetype = type(none);
|
let nonetype = type(none);
|
||||||
@@ -195,7 +196,7 @@
|
|||||||
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, consultant, 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)), year_of_study,
|
||||||
);
|
);
|
||||||
v(5em);
|
v(5em);
|
||||||
}, bottom);
|
}, bottom);
|
||||||
|
@@ -18,15 +18,18 @@
|
|||||||
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, consultant, study_programme, study_branch, abstract_content,
|
title, author, _, supervisor, consultant, study_programme, study_branch, year_of_study,
|
||||||
_, keywords,
|
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, consultant, study_programme, study_branch);
|
mainpage(
|
||||||
|
faculty_id, language, none, title, author, supervisor, consultant, study_programme,
|
||||||
|
study_branch, year_of_study,
|
||||||
|
);
|
||||||
default_styling(true, faculty_color, {
|
default_styling(true, faculty_color, {
|
||||||
toc(language);
|
toc(language);
|
||||||
tablelist(language);
|
tablelist(language);
|
||||||
|
@@ -6,6 +6,7 @@
|
|||||||
"consultant": "Konzultant práce",
|
"consultant": "Konzultant práce",
|
||||||
"study_programme": "Studijní program",
|
"study_programme": "Studijní program",
|
||||||
"study_branch": "Studijní obor",
|
"study_branch": "Studijní obor",
|
||||||
|
"year_of_study": "Ročník",
|
||||||
|
|
||||||
"bp": "Bakalářská práce",
|
"bp": "Bakalářská práce",
|
||||||
|
|
||||||
@@ -56,6 +57,7 @@
|
|||||||
"consultant": "Consultant",
|
"consultant": "Consultant",
|
||||||
"study_programme": "Study programme",
|
"study_programme": "Study programme",
|
||||||
"study_branch": "Study branch",
|
"study_branch": "Study branch",
|
||||||
|
"year_of_study": "Year of study",
|
||||||
|
|
||||||
"bp": "Bachelor thesis",
|
"bp": "Bachelor thesis",
|
||||||
|
|
||||||
|
@@ -46,7 +46,8 @@
|
|||||||
|
|
||||||
// document info
|
// document info
|
||||||
title: none, keywords: none, abstract: none, acknowledgement: none, author: none,
|
title: none, keywords: none, abstract: none, acknowledgement: none, author: none,
|
||||||
author_gender: none, supervisor: none, consultant: none, programme: none, branch: none,
|
author_gender: none, supervisor: none, consultant: none, programme: none,
|
||||||
|
branch: none, year_of_study: none,
|
||||||
|
|
||||||
// links
|
// links
|
||||||
assignment: none, citations: "citations.bib",
|
assignment: none, citations: "citations.bib",
|
||||||
@@ -81,6 +82,7 @@
|
|||||||
programme, "dictionary[string : string] | none", "study programme argument"
|
programme, "dictionary[string : string] | none", "study programme argument"
|
||||||
);
|
);
|
||||||
assert_type_signature(branch, "dictionary[string : string] | none", "study branch argument");
|
assert_type_signature(branch, "dictionary[string : string] | none", "study branch argument");
|
||||||
|
assert_type_signature(year_of_study, "integer | none", "year of study");
|
||||||
assert_type_signature(assignment, "string | none", "assignment document argument");
|
assert_type_signature(assignment, "string | none", "assignment document argument");
|
||||||
assert_type_signature(citations, "string", "citations file argument");
|
assert_type_signature(citations, "string", "citations file argument");
|
||||||
|
|
||||||
@@ -100,7 +102,7 @@
|
|||||||
templates.at(style)(
|
templates.at(style)(
|
||||||
lang, faculty, document, citations, assignment,
|
lang, faculty, document, citations, assignment,
|
||||||
title, author, author_gender, supervisor, consultant,
|
title, author, author_gender, supervisor, consultant,
|
||||||
programme, branch, abstract, acknowledgement, keywords, content
|
programme, branch, year_of_study, abstract, acknowledgement, keywords, content
|
||||||
);
|
);
|
||||||
|
|
||||||
import "prototyping.typ": assert_release_ready
|
import "prototyping.typ": assert_release_ready
|
||||||
|
Reference in New Issue
Block a user