See gfngfn.github.io
for example.
Note: this Hugo theme is currently developed solely for the developer’s personal use. Feel free to use it, but please note that its functionality and appearance are subject to change.
Upcards expects the configuration to be like the following:
disableKinds = ["RSS", "taxonomy", "section"]
ignoreErrors = ["error-disable-taxonomy"]
[taxonomies]
tag = 'tags'
defaultContentLanguage = ...
[languages]
...
i.e., it expects the tag to be the sole taxonomy and the pages for taxonimies or sections to be disabled.
Defines how each tag should be rendered. This section is mandatory; all the tags must be specified in this section in your config file.
Example:
...
[languages]
[languages.en]
...
[languages.en.tagTexts]
web-design = "Web design"
latex = "LaTeX"
...
...
The prefix/suffix for displaying last modified datetimes.
Example:
...
[languages]
[languages.en]
...
lastmodPre = "(last modified: "
lastmodPost = ")"
...
The title for the Table of Contents (see also the shortcode {{< toc >}}
). Default: "Contents"
Whether text-align: justify;
is applied to the summary on each card.
The path to the thumbnail image relative to $YOUR_SITE_REPO/static
. No thumbnail image will be displayed if omitted.
Enables rendering of math formulae using KaTeX if set to true
(Default: false
). Math formulae are supposed to be written like the following:
The attractive force \\(F\\) between two point-like bodies satisfies:
```
\begin{align*}
F = G \frac{M m}{R^2}
\end{align*}
```
where \\(G\\) is the gravitational constant.
The page type ("normal"
, "slides"
, or "image"
). Default: "normal"
The path to the PDF file for slides relative to $YOUR_SITE_REPO/static
. Effective and mandatory when pageType = "slides"
.
Example:
thumbnail: "/media/thumbnail-of-your-slides.png"
pageType: "slides"
slidePath: "/media/slides.pdf"
Effective when pageType = "slides"
. Titles of presentations will be displayed on cards if this option is set. Default: false
(i.e. titles are not displayed on slide cards)
The list of paths to the image files relative to $YOUR_SITE_REPO/static
. Effective when pageType = "image"
.
Inserts the Table of Contents. The resulting listing will be shown on where {{< toc >}}
is written if the screen is relatively narrow (specifically, narrower than 1250px; e.g. smartphone screens), or on the right corner of the viewport otherwise (e.g. display devices for desktop PCs).
Displays a card of a GitHub repository by using gh-card.dev
.
Example:
{{< github-repo user="gfngfn" repo="hugo_theme_upcards" >}}
Creates a link that displays the OGP image provided by the destination page. The title, the thumbnail image, and the description of the page are automatically obtained and displayed.
A manual version of ogp-link-card
. Useful when the link requires some authentication or redirection.
Upcards depends on the following libraries:
- The Bootstrap Authors. Bootstrap v5.0.2. Licensed under MIT, 2011-2021.
- Cole Bemis. Feather. Licensed under MIT, 2013-2017.
- David DeSandro. Masonry v4.2.2. Licensed under MIT, 2022.
- Mozilla Foundation. PDF.js. Licensed under the Apache License (Version 2.0), 2022.
- Khan Academy and other contributors. KaTeX. Licensed under MIT, 2013-2020.