diff --git a/archetypes/publication.md b/archetypes/publication.md index f6692abc..a0ba4ceb 100644 --- a/archetypes/publication.md +++ b/archetypes/publication.md @@ -1,17 +1,45 @@ +++ -abstract = "" -abstract_short = "" + +# Authors. Comma separated list, e.g. `["Bob Smith", "David Jones"]`. authors = [""] -image = "" -image_preview = "" -math = false + +# Publication type. +# Legend: +# 0 = Uncategorized +# 1 = Conference proceedings +# 2 = Journal +# 3 = Work in progress +# 4 = Technical report +# 5 = Book +# 6 = Book chapter +publication_types = ["0"] + +# Publication name and optional abbreviated version. publication = "" publication_short = "" + +# Abstract and optional shortened version. +abstract = "" +abstract_short = "" + +# Does this page contain LaTeX math? (true/false) +math = false + +# Featured image (optional) +image = "" + +# Featured image thumbnail (optional) +image_preview = "" + +# Is this a selected publication? (true/false) selected = false + +# Links (optional) url_pdf = "" url_code = "" url_dataset = "" url_project = "" url_slides = "" url_video = "" + +++ diff --git a/exampleSite/config.toml b/exampleSite/config.toml index 27043681..3ea65379 100644 --- a/exampleSite/config.toml +++ b/exampleSite/config.toml @@ -49,6 +49,21 @@ defaultContentLanguageInSubdir = false custom_css = [] custom_js = [] + # Publication types. + # Used to categorize publications. + # The index of the publication type in the list is used as its unique numerical identifier. + # The numeric ID is used in a publication's frontmatter to categorize it. + # The language can be edited below. + # For multi-lingual sites, copy this block to each language section at the end of this file. + publication_types = [ + 'Uncategorized', # 0 + 'Conference proceedings', # 1 + 'Journal', # 2 + 'Work in progress', # 3 + 'Technical report', # 4 + 'Book', # 5 + 'Book chapter' # 6 + ] # Social/Academic Networking # @@ -124,6 +139,12 @@ defaultContentLanguageInSubdir = false url = "#contact" weight = 6 +# Taxonomies. +[taxonomies] + tag = "tags" + category = "categories" + publication_type = "publication_types" + # Languages # Create a [languages.X] block for each language you want, where X is the language ID. diff --git a/exampleSite/content/publication/clothing-search.md b/exampleSite/content/publication/clothing-search.md index d564c327..d2806b7f 100644 --- a/exampleSite/content/publication/clothing-search.md +++ b/exampleSite/content/publication/clothing-search.md @@ -6,6 +6,7 @@ date = "2013-07-01" image = "" image_preview = "" math = true +publication_types = ["1"] publication = "In *International Conference on Multimedia and Expo Workshops (ICMEW)*, IEEE." publication_short = "In *ICMEW*" selected = true diff --git a/exampleSite/content/publication/person-re-identification.md b/exampleSite/content/publication/person-re-identification.md index 06fd7a66..d0d4be79 100644 --- a/exampleSite/content/publication/person-re-identification.md +++ b/exampleSite/content/publication/person-re-identification.md @@ -6,6 +6,7 @@ date = "2015-09-01" image = "" image_preview = "" math = true +publication_types = ["2"] publication = "In *Signal Image Technology & Internet Systems (SITIS)*, IEEE." publication_short = "" selected = false diff --git a/i18n/en.yaml b/i18n/en.yaml index 6c3f4411..a9624e2c 100644 --- a/i18n/en.yaml +++ b/i18n/en.yaml @@ -60,6 +60,9 @@ - id: publication translation: Publication +- id: publication_type + translation: Type + - id: date translation: Date @@ -72,6 +75,14 @@ - id: location translation: Location +# Filtering + +- id: filter_by_type + translation: Filter by type + +- id: filter_all + translation: All + # Project details - id: open_project_site diff --git a/layouts/publication/single.html b/layouts/publication/single.html index 11e88876..57fc3744 100644 --- a/layouts/publication/single.html +++ b/layouts/publication/single.html @@ -22,6 +22,26 @@
{{ .Params.abstract }}
+ {{ if (.Params.publication_types) and (ne (index .Params.publication_types 0) "0") }} ++ {{ i18n "filter_by_type" }}: + +
- {{ range .Pages.ByDate.Reverse }} -{{ partial "publication_links" (dict "content" . "is_list" 1) }}
-{{ partial "publication_links" (dict "content" . "is_list" 1) }}