mirror of
https://github.com/welpo/tabi.git
synced 2025-10-10 23:38:53 +02:00
Merge branch 'welpo:main' into main
This commit is contained in:
commit
939747742b
23 changed files with 984 additions and 402 deletions
24
config.toml
24
config.toml
|
@ -427,3 +427,27 @@ avatar = true
|
|||
voting = true
|
||||
page_author_hashes = "" # hash (or list of hashes) of the author.
|
||||
lazy_loading = true # Loads when the comments are in the viewport (using the Intersection Observer API).
|
||||
|
||||
# h-card configuration
|
||||
# Will identify you on the indieweb (see https://microformats.org/wiki/h-card)
|
||||
[extra.hcard]
|
||||
# Enable home page h-card.
|
||||
# enable = true
|
||||
# Add your email to the card if extra.email is set and not encoded.
|
||||
# with_mail = true
|
||||
# Add your social links ('socials' config) to the card.
|
||||
# with_social_links = true
|
||||
# Homepage url. Defaults to the value of 'base_url'.
|
||||
# homepage = "https://myhomepage.net"
|
||||
# avatar = "img/profile.webp"
|
||||
# Display name, default to the value of 'author'.
|
||||
# full_name = "John Doe"
|
||||
# Small bio, as shown on social media profiles.
|
||||
# biography = "Fond of the indieweb"
|
||||
#
|
||||
# You can add any property from https://microformats.org/wiki/h-card#Properties
|
||||
# Make sure to replace all '-' characters by '_'
|
||||
# Examples:
|
||||
# p_nickname = "nickname"
|
||||
# p_locality = "Bordeaux"
|
||||
# p_country_name = "France"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
+++
|
||||
title = "Lost in Translation? Explora les capacitats multilingües de tabi"
|
||||
date = 2023-09-12
|
||||
updated = 2024-08-18
|
||||
updated = 2025-04-02
|
||||
description = "Descobreix com tabi t'ajuda a connectar amb una audiència global gràcies a les seves funcions multilingües. Aprèn a canviar la llengua per defecte, afegir més llengües i aportar les teves pròpies traduccions."
|
||||
|
||||
[taxonomies]
|
||||
|
@ -30,6 +30,7 @@ tabi admet les següents llengües:
|
|||
- Coreà
|
||||
- Espanyol
|
||||
- Estonià
|
||||
- Finès
|
||||
- Francès
|
||||
- Hindi
|
||||
- Italià
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
+++
|
||||
title = "¿Lost in Translation? Explora las capacidades multilingües de tabi"
|
||||
date = 2023-09-12
|
||||
updated = 2024-08-18
|
||||
updated = 2025-04-02
|
||||
description = "Descubre cómo tabi te ayuda a conectar con una audiencia global gracias a sus funciones multilingües. Aprende a cambiar el idioma por defecto, añadir más idiomas y aportar tus propias traducciones."
|
||||
|
||||
[taxonomies]
|
||||
|
@ -30,6 +30,7 @@ tabi admite los siguientes idiomas:
|
|||
- Coreano
|
||||
- Español
|
||||
- Estonio
|
||||
- Finlandés
|
||||
- Francés
|
||||
- Hindi
|
||||
- Inglés
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
+++
|
||||
title = "Lost in Translation? Not with tabi's Multilingual Capabilities"
|
||||
date = 2023-09-12
|
||||
updated = 2024-03-01
|
||||
updated = 2025-04-02
|
||||
description = "Master the art of serving a global audience through tabi's built-in multilingual features. Learn how to change the default language, add multilingual support, and contribute your own translations."
|
||||
|
||||
[taxonomies]
|
||||
|
@ -29,6 +29,7 @@ tabi supports the following languages:
|
|||
- Chinese (Traditional)
|
||||
- English
|
||||
- Estonian
|
||||
- Finnish
|
||||
- French
|
||||
- German
|
||||
- Hindi
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
+++
|
||||
title = "Domina la configuració de tabi: guia completa"
|
||||
date = 2023-09-18
|
||||
updated = 2025-02-16
|
||||
updated = 2025-04-05
|
||||
description = "Descobreix les múltiples maneres en què pots personalitzar tabi."
|
||||
|
||||
[taxonomies]
|
||||
|
@ -1007,6 +1007,26 @@ Per a més informació, consulta la [pàgina de documentació de CSP](@/blog/sec
|
|||
|
||||
---
|
||||
|
||||
## Indieweb
|
||||
|
||||
### h-card representativa
|
||||
|
||||
| Pàgina | Secció | `config.toml` | Segueix la jerarquia | Requereix JavaScript |
|
||||
| :--: | :-----: | :-----------: | :---------------: | :-----------------: |
|
||||
| ❌ | ❌ | ✅ | ❌ | ❌ |
|
||||
|
||||
Per defecte, tabi afegeix una h-card representativa [h-card](https://microformats.org/wiki/h-card) **oculta** a la pàgina d'inici. Tot i que és invisible per als visitants, està disponible per als analitzadors de microformats. Pots comprovar la validesa de la targeta amb l'eina [Indiewebify.me](https://indiewebify.me/validate-h-card/).
|
||||
|
||||
Per desactivar l'h-card, estableix `enable = false` a la secció `[extra.hcard]` de `config.toml`.
|
||||
|
||||
L'h-card predeterminada inclou el teu nom, l'URL del lloc web i els enllaços a les xarxes socials.
|
||||
|
||||
Pots establir una imatge de perfil i una petita biografia amb els paràmetres `avatar` i `biography`.
|
||||
|
||||
Totes les altres [propietats h-card](https://microformats.org/wiki/h-card#Properties) es poden afegir llistant-les a la secció `[extra.hcard]` del fitxer de configuració. Simplement substitueix tots els caràcters `-` per `_`.
|
||||
|
||||
---
|
||||
|
||||
[^1]: Si estàs utilitzant un repositori Git remot, potser voldràs automatitzar el procés d'actualització del camp `updated`. Aquí tens una guia per a això: [Zola Git Hook: actualitzant les dates de les publicacions](https://osc.garden/ca/blog/zola-date-git-hook/).
|
||||
|
||||
[^2]: Per a codificar el teu correu electrònic en base64 pots utilitzar [eines en línia](https://www.base64encode.org/) o, al teu terminal, executar: `printf 'mail@example.com' | base64`
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
+++
|
||||
title = "Domina la configuración de tabi: guía completa"
|
||||
date = 2023-09-18
|
||||
updated = 2025-02-16
|
||||
updated = 2025-04-05
|
||||
description = "Descubre las múltiples maneras en que puedes personalizar tabi."
|
||||
|
||||
[taxonomies]
|
||||
|
@ -1008,6 +1008,26 @@ Para obtener más información, consulta la [página de documentación de CSP](@
|
|||
|
||||
---
|
||||
|
||||
## Indieweb
|
||||
|
||||
### h-card representativa
|
||||
|
||||
| Página | Sección | `config.toml` | Sigue Jerarquía | Requiere JavaScript |
|
||||
| :--: | :-----: | :-----------: | :---------------: | :-----------------: |
|
||||
| ❌ | ❌ | ✅ | ❌ | ❌ |
|
||||
|
||||
Por defecto, tabi añade una [h-card](https://microformats.org/wiki/h-card) representativa **oculta** a la página de inicio. Aunque es invisible para los visitantes, está disponible para los analizadores de microformatos. Puedes comprobar la validez de la tarjeta con la herramienta [Indiewebify.me](https://indiewebify.me/validate-h-card/).
|
||||
|
||||
Para desactivar la h-card, establece `enable = false` en la sección `[extra.hcard]` de `config.toml`.
|
||||
|
||||
La h-card predeterminada incluye tu nombre, la URL del sitio web y los enlaces a redes sociales.
|
||||
|
||||
Puedes establecer una imagen de perfil y una pequeña biografía con los ajustes `avatar` y `biography`.
|
||||
|
||||
Todas las demás [propiedades de h-card](https://microformats.org/wiki/h-card#Properties) se pueden añadir listándolas en la sección `[extra.hcard]` del archivo de configuración. Simplemente reemplaza todos los caracteres `-` por `_`.
|
||||
|
||||
---
|
||||
|
||||
[^1]: Si estás utilizando un repositorio Git remoto, es posible que quieras automatizar el proceso de actualización del campo `updated`. Aquí tienes una guía para eso: [Zola Git Hook: actualizando las fechas de las publicaciones](https://osc.garden/es/blog/zola-date-git-hook/).
|
||||
|
||||
[^2]: Para codificar tu correo electrónico en base64 puedes utilizar [herramientas en línea](https://www.base64encode.org/) o, en tu terminal, ejecutar: `printf 'mail@example.com' | base64`
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
+++
|
||||
title = "Mastering tabi Settings: A Comprehensive Guide"
|
||||
date = 2023-09-18
|
||||
updated = 2025-02-16
|
||||
updated = 2025-04-04
|
||||
description = "Discover the many ways you can customise your tabi site."
|
||||
|
||||
[taxonomies]
|
||||
|
@ -113,7 +113,7 @@ The description is regular Markdown content, set outside the front matter.
|
|||
|
||||
#### Listing Recent Posts
|
||||
|
||||
To show posts on your main page, you first need to decide where these posts will be served from: the root path (`/`) or a subdirectory (e.g., `/blog`).
|
||||
To show posts on your main page, you first need to decide where these posts will be served from: the root path (`/`) or a subdirectory (e.g., `/blog`).
|
||||
|
||||
**Option A: Serve posts from the root path (`/`)**
|
||||
|
||||
|
@ -1018,6 +1018,26 @@ See the [CSP documentation page](@/blog/security/index.md) for more information.
|
|||
|
||||
---
|
||||
|
||||
## Indieweb
|
||||
|
||||
### Representative h-card
|
||||
|
||||
| Page | Section | `config.toml` | Follows Hierarchy | Requires JavaScript |
|
||||
| :--: | :-----: | :-----------: | :---------------: | :-----------------: |
|
||||
| ❌ | ❌ | ✅ | ❌ | ❌ |
|
||||
|
||||
By default, tabi adds a **hidden** representative [h-card](https://microformats.org/wiki/h-card) to the homepage. While invisible to visitors, it's available to microformat parsers. You can check the validity of the card with the [Indiewebify.me](https://indiewebify.me/validate-h-card/) tool.
|
||||
|
||||
To disable the h-card, set `enable = false` in the `[extra.hcard]` section of `config.toml`.
|
||||
|
||||
The default h-card includes your name, website url and social media links.
|
||||
|
||||
You can set a profile picture and a small bio with the `avatar` and `biography` settings.
|
||||
|
||||
All other [h-card properties](https://microformats.org/wiki/h-card#Properties) can be added by listing them under the `[extra.hcard]`section of the config file. Simply replace all `-` characters by `_`.
|
||||
|
||||
---
|
||||
|
||||
[^1]: If you're using a remote Git repository, you might want to automate the process of updating the `updated` field. Here's a guide for that: [Zola Git Pre-Commit Hook: Updating Post Dates](https://osc.garden/blog/zola-date-git-hook/).
|
||||
|
||||
[^2]: To encode your email in base64 you can use [online tools](https://www.base64encode.org/) or, on your terminal, run: `printf 'mail@example.com' | base64`.
|
||||
|
|
99
i18n/fi.toml
Normal file
99
i18n/fi.toml
Normal file
|
@ -0,0 +1,99 @@
|
|||
language_name = "suomi" # Shown in language picker for multi-language sites.
|
||||
date_locale = "fi_FI"
|
||||
full_stop = "." # Used at the end of a sentence.
|
||||
|
||||
# Menu items.
|
||||
# Should match the names in config.extra.menu and config.extra.footer_menu.
|
||||
blog = "blogi"
|
||||
archive = "arkisto"
|
||||
tags = "tunnisteet"
|
||||
projects = "projektit"
|
||||
diagrams = "kaaviot"
|
||||
about = "minusta"
|
||||
contact = "yhteystiedot"
|
||||
privacy = "tietosuojakäytäntö"
|
||||
site_statistics = "tilastot"
|
||||
sitemap = "sivustokartta"
|
||||
|
||||
# Search.
|
||||
search = "Hae"
|
||||
search_icon_title = "Paina $SHORTCUT avataksesi haun" # $SHORTCUT will be replaced with the actual keyboard shortcut.
|
||||
clear_search = "Tyhjennä haku" # Title of the X icon next to search input.
|
||||
zero_results = "Ei tuloksia"
|
||||
one_results = "$NUMBER tulos" # "1 result"
|
||||
many_results = "$NUMBER tulosta" # "3 results"
|
||||
|
||||
# Navigation.
|
||||
# Some will prefer artikkeli (=article) instead of julkaisu (=publication), but this is more general
|
||||
pinned = "Kiinnitetty"
|
||||
jump_to_posts = "Siirry julkaisuihin"
|
||||
read_more = "Lue lisää"
|
||||
one_posts = "$NUMBER julkaisu"
|
||||
many_posts = "$NUMBER julkaisua" # "3 posts"
|
||||
prev = "Edellinen" # As in "Previous" page.
|
||||
next = "Seuraava" # As in "Next" page.
|
||||
of = "/" # E.g. Page 1 "of" 3
|
||||
all_posts = "Kaikki julkaisut"
|
||||
all_tags = "Kaikki tunnisteet"
|
||||
all_projects = "Kaikki projektit"
|
||||
featured_projects = "Esittelyprojektit"
|
||||
language_selection = "Kielivalinta"
|
||||
toggle_mode = "Vaihda $MODE" # $MODE will be replaced by a value (or both) below. Literally "Change $MODE"
|
||||
# The declension assumes that both values are used. e.g. "Change dark mode" wouldn't work and would need the "to" preposition
|
||||
# It also omits the "mode" word: "Change dark/light mode" instead of "Change dark mode/light mode"
|
||||
dark = "tumma"
|
||||
light = "vaalea tila"
|
||||
reset_mode = "Palauta oletustilaan"
|
||||
|
||||
# Quick navigation buttons.
|
||||
toggle_toc = "Sisällysluettelo päälle/pois"
|
||||
go_to_top = "Siirry sivun alkuun"
|
||||
go_to_comments = "Siirry kommenttiosioon"
|
||||
|
||||
# Post metadata.
|
||||
by_author = "Kirjoittanut $AUTHOR" # $AUTHOR will be replaced by the author(s). Literally "Written by $AUTHOR"
|
||||
author_separator = ", " # For multiple authors. Ensure spacing where necessary.
|
||||
author_conjunction = " ja " # For multiple authors. Ensure spacing where necessary.
|
||||
draft = "LUONNOS"
|
||||
zero_min_read = "<1 min. lukuaika"
|
||||
one_min_read = "$NUMBER min. lukuaika"
|
||||
many_min_read = "$NUMBER min. lukuaika"
|
||||
zero_words = "Ei sanoja"
|
||||
one_words = "$NUMBER sana"
|
||||
many_words = "$NUMBER sanaa"
|
||||
last_updated_on = "Päivitetty $DATE"
|
||||
see_changes = "Katso muutokset"
|
||||
|
||||
# Post body.
|
||||
table_of_contents = "Sisällysluettelo"
|
||||
load_comments = "Lataa kommentit"
|
||||
|
||||
# Copy code block button.
|
||||
copied = "Kopioitu!"
|
||||
copy_code_to_clipboard = "Kopioi koodi leikepöydälle"
|
||||
|
||||
# Footer: Powered by Zola and tabi.
|
||||
powered_by = "Pyörii ohjelmilla" # "Works using the software"
|
||||
and = "&"
|
||||
site_source = "Sivuston lähdekoodi"
|
||||
|
||||
# 404 error.
|
||||
# https://welpo.github.io/tabi/404.html
|
||||
page_missing = "Pyytämääsi sivua ei löydy"
|
||||
translation_missing = "tai sitä ei ole vielä käännetty kielellesi"
|
||||
check_url = "Tarkista URL-osoitteesta mahdolliset virheet tai"
|
||||
go_home = "palaa etusivulle"
|
||||
|
||||
# For multilingual quote shortcode.
|
||||
# https://welpo.github.io/tabi/blog/shortcodes/#multilingual-quotes
|
||||
show_original_quote = "Näytä alkuperäinen lainaus"
|
||||
show_translation = "Näytä käännös"
|
||||
open_quotation_mark = "“"
|
||||
close_quotation_mark = "”"
|
||||
|
||||
# Translations for stylised Atom feed.
|
||||
# https://welpo.github.io/tabi/atom.xml
|
||||
# Must contain "About Feeds"; it will become a link.
|
||||
about_feeds = "Tämä on verkkosyöte, joka tunnetaan myös nimellä Atom-syöte. Tilaa kopioimalla URL-osoite osoitepalkista uutislukijaasi. Käy sivulla About Feeds saadaksesi lisätietoja ja aloittaakeksi. Se on ilmaista."
|
||||
visit_the_site = "Vieraile sivustolla"
|
||||
recent_posts = "Viimeisimmät julkaisut"
|
|
@ -85,30 +85,21 @@ a {
|
|||
// External link styles with `external_links_class = "external"`.
|
||||
main {
|
||||
--external-link-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cg fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M11 5h-6v14h14v-6'/%3E%3Cpath d='M13 11l7 -7'/%3E%3Cpath d='M21 3h-6M21 3v6'/%3E%3C/g%3E%3C/svg%3E");
|
||||
a.external:not(:has(img, svg, video, picture, figure)) {
|
||||
display: inline-block;
|
||||
padding-inline-end: 0.9em;
|
||||
}
|
||||
|
||||
a.external:not(:has(img, svg, video, picture, figure))::after {
|
||||
-webkit-mask-image: var(--external-link-icon);
|
||||
-webkit-mask-size: 100% 100%;
|
||||
display: inline-block;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
mask-image: var(--external-link-icon);
|
||||
mask-size: 100% 100%;
|
||||
margin-inline-start: 0.2em;
|
||||
inset-inline-end: 0;
|
||||
vertical-align: -0.05em;
|
||||
margin-inline-start: 0.1em;
|
||||
background-color: currentColor;
|
||||
width: 0.8em;
|
||||
height: 0.8em;
|
||||
content: '';
|
||||
-webkit-mask-image: var(--external-link-icon);
|
||||
-webkit-mask-size: 100% 100%;
|
||||
}
|
||||
|
||||
&:dir(rtl) a.external:not(:has(img, svg, video, picture, figure))::after {
|
||||
transform: translateY(-50%) rotate(-90deg);
|
||||
transform: rotate(-90deg);
|
||||
}
|
||||
|
||||
.meta a.external:not(:has(img, svg, video, picture, figure))::after {
|
||||
|
|
|
@ -81,7 +81,14 @@ get_latest_version_github() {
|
|||
|
||||
get_local_mermaid_version() {
|
||||
local version
|
||||
# Old format.
|
||||
version=$(grep -o '[A-Za-z]\+t="[0-9]\+\.[0-9]\+\.[0-9]\+"' "$MERMAID_PATH" | grep -o '[0-9]\+\.[0-9]\+\.[0-9]\+' || true)
|
||||
|
||||
# New format.
|
||||
if [ -z "$version" ]; then
|
||||
version=$(grep -o 'version:"[0-9]\+\.[0-9]\+\.[0-9]\+"' "$MERMAID_PATH" | grep -o '[0-9]\+\.[0-9]\+\.[0-9]\+' || true)
|
||||
fi
|
||||
|
||||
if [ -z "$version" ]; then
|
||||
exit_with_message "Could not detect local Mermaid.js version"
|
||||
fi
|
||||
|
|
2
static/js/katex.min.js
vendored
2
static/js/katex.min.js
vendored
File diff suppressed because one or more lines are too long
1015
static/js/mermaid.min.js
vendored
1015
static/js/mermaid.min.js
vendored
File diff suppressed because one or more lines are too long
2
static/katex.min.css
vendored
2
static/katex.min.css
vendored
File diff suppressed because one or more lines are too long
75
templates/partials/hcard.html
Normal file
75
templates/partials/hcard.html
Normal file
|
@ -0,0 +1,75 @@
|
|||
{%- set hcard = config.extra.hcard -%}
|
||||
|
||||
{% set full_name = config.author %}
|
||||
{% if hcard.full_name %}
|
||||
{% set full_name = hcard.full_name %}
|
||||
{% endif %}
|
||||
|
||||
{%- set homepage = config.base_url -%}
|
||||
{% if hcard.homepage %}
|
||||
{%- set homepage = hcard.homepage -%}
|
||||
{% endif %}
|
||||
|
||||
{% if hcard.enable %}
|
||||
<div class="h-card hidden">
|
||||
<div>
|
||||
{%- if hcard.avatar -%}
|
||||
<img
|
||||
class="u-photo"
|
||||
src="{{ get_url(path=hcard.avatar) }}"
|
||||
width="200"
|
||||
height="200"
|
||||
alt="{{ full_name }}"
|
||||
/>
|
||||
{%- endif -%}
|
||||
|
||||
<span class="p-name" rel="me">{{ full_name }}</span>
|
||||
|
||||
{% if hcard.p_nickname %}
|
||||
( <span class="p-nickname">{{ hcard.p_nickname }}</span> )
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{% if hcard.biography %}
|
||||
<p class="p-note">{{ hcard.biography }}</p>
|
||||
{% endif %}
|
||||
|
||||
{# links #}
|
||||
<div>
|
||||
{%- if hcard.with_mail and config.extra.email and not config.extra.encode_plaintext_email -%}
|
||||
<span>
|
||||
<a class="u-email" href="mailto:{{ config.extra.email | safe }}">email</a>
|
||||
</span> -
|
||||
{%- endif -%}
|
||||
|
||||
<span>
|
||||
<a class="u-url u-id" href="{{ homepage }}">homepage</a>
|
||||
</span> -
|
||||
|
||||
{%- if hcard.with_social_links and config.extra.socials %}
|
||||
{% for social in config.extra.socials %}
|
||||
<span>
|
||||
<a class="p-url" rel="me" href="{{ social.url | safe }}">{{ social.name }}</a>
|
||||
</span> -
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{# additional properties #}
|
||||
{% set dl_started = false %}
|
||||
{% for key, value in hcard %}
|
||||
{% if key not in ['enable', 'with_mail', 'with_social_links', 'homepage', 'full_name', 'avatar', 'biography', 'p_nickname'] %}
|
||||
{% if not dl_started %}
|
||||
<dl>
|
||||
{% set_global dl_started = true %}
|
||||
{% endif %}
|
||||
<dt>{{ key | replace(from="p_", to="") | replace(from="u_", to="") | replace(from="dt_", to="") | replace(from="_", to=" ") | capitalize }}</dt>
|
||||
<dd class="{{ key | replace(from="_", to="-") }}">{{ value }}</dd>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% if dl_started %}
|
||||
</dl>
|
||||
{% endif %}
|
||||
|
||||
</div>
|
||||
{% endif %}
|
|
@ -1,4 +1,7 @@
|
|||
{#- Setup -#}
|
||||
{% if not config.title %}
|
||||
{{ throw(message="ERROR: No `title` set in `config.toml`. tabi requires a title to function.") }}
|
||||
{% endif %}
|
||||
{%- set prefix = config.title | safe -%}
|
||||
{%- set custom_separator = config.extra.separator | default(value="•") -%}
|
||||
{%- set separator = " " ~ custom_separator ~ " " -%}
|
||||
|
|
|
@ -24,6 +24,9 @@
|
|||
{%- endif -%}
|
||||
|
||||
<main {% if more_than_one_section_shown %}class="{{ first_section }}-first"{% endif %}>
|
||||
{%- if config.extra.hcard %}
|
||||
{%- include "partials/hcard.html" -%}
|
||||
{% endif -%}
|
||||
{%- if section.extra.header %}
|
||||
{%- include "partials/home_banner.html" -%}
|
||||
{%- elif section.content -%}
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
{#- Fallback to absolute path if relative path doesn't work -#}
|
||||
{%- if not meta -%}
|
||||
{%- set meta = get_image_metadata(path=src, allow_missing=true) -%}
|
||||
{%- set image_url = get_url(path=src) -%}
|
||||
{%- set image_url = get_url(path=src, cachebust=true) -%}
|
||||
{%- else -%}
|
||||
{%- set image_url = get_url(path=relative_path) -%}
|
||||
{%- set image_url = get_url(path=relative_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
|
|
@ -16,9 +16,9 @@
|
|||
{%- set relative_light_path = colocated_path ~ light_src -%}
|
||||
{%- set light_meta = get_image_metadata(path=relative_light_path, allow_missing=true) -%}
|
||||
{%- if not light_meta -%}
|
||||
{%- set light_image_url = get_url(path=light_src) -%}
|
||||
{%- set light_image_url = get_url(path=light_src, cachebust=true) -%}
|
||||
{%- else -%}
|
||||
{%- set light_image_url = get_url(path=relative_light_path) -%}
|
||||
{%- set light_image_url = get_url(path=relative_light_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
@ -29,9 +29,9 @@
|
|||
{%- set relative_dark_path = colocated_path ~ dark_src -%}
|
||||
{%- set dark_meta = get_image_metadata(path=relative_dark_path, allow_missing=true) -%}
|
||||
{%- if not dark_meta -%}
|
||||
{%- set dark_image_url = get_url(path=dark_src) -%}
|
||||
{%- set dark_image_url = get_url(path=dark_src, cachebust=true) -%}
|
||||
{%- else -%}
|
||||
{%- set dark_image_url = get_url(path=relative_dark_path) -%}
|
||||
{%- set dark_image_url = get_url(path=relative_dark_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
{#- Fallback to absolute path if relative path doesn't work -#}
|
||||
{%- if not meta -%}
|
||||
{%- set meta = get_image_metadata(path=src, allow_missing=true) -%}
|
||||
{%- set image_url = get_url(path=src) -%}
|
||||
{%- set image_url = get_url(path=src, cachebust=true) -%}
|
||||
{%- else %}
|
||||
{%- set image_url = get_url(path=relative_path) -%}
|
||||
{%- set image_url = get_url(path=relative_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
|
|
@ -21,9 +21,9 @@
|
|||
{%- set relative_default_path = colocated_path ~ default_src -%}
|
||||
{%- set default_meta = get_image_metadata(path=relative_default_path, allow_missing=true) -%}
|
||||
{%- if not default_meta -%}
|
||||
{%- set default_image_url = get_url(path=default_src) -%}
|
||||
{%- set default_image_url = get_url(path=default_src, cachebust=true) -%}
|
||||
{%- else -%}
|
||||
{%- set default_image_url = get_url(path=relative_default_path) -%}
|
||||
{%- set default_image_url = get_url(path=relative_default_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
@ -34,9 +34,9 @@
|
|||
{%- set relative_hovered_path = colocated_path ~ hovered_src -%}
|
||||
{%- set hovered_meta = get_image_metadata(path=relative_hovered_path, allow_missing=true) -%}
|
||||
{%- if not hovered_meta -%}
|
||||
{%- set hovered_image_url = get_url(path=hovered_src) -%}
|
||||
{%- set hovered_image_url = get_url(path=hovered_src, cachebust=true) -%}
|
||||
{%- else -%}
|
||||
{%- set hovered_image_url = get_url(path=relative_hovered_path) -%}
|
||||
{%- set hovered_image_url = get_url(path=relative_hovered_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
|
|
@ -25,9 +25,9 @@
|
|||
{%- set relative_default_path = colocated_path ~ default_src -%}
|
||||
{%- set default_meta = get_image_metadata(path=relative_default_path, allow_missing=true) -%}
|
||||
{%- if not default_meta -%}
|
||||
{%- set default_image_url = get_url(path=default_src) -%}
|
||||
{%- set default_image_url = get_url(path=default_src, cachebust=true) -%}
|
||||
{%- else -%}
|
||||
{%- set default_image_url = get_url(path=relative_default_path) -%}
|
||||
{%- set default_image_url = get_url(path=relative_default_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
@ -38,9 +38,9 @@
|
|||
{%- set relative_toggled_path = colocated_path ~ toggled_src -%}
|
||||
{%- set toggled_meta = get_image_metadata(path=relative_toggled_path, allow_missing=true) -%}
|
||||
{%- if not toggled_meta -%}
|
||||
{%- set toggled_image_url = get_url(path=toggled_src) -%}
|
||||
{%- set toggled_image_url = get_url(path=toggled_src, cachebust=true) -%}
|
||||
{%- else -%}
|
||||
{%- set toggled_image_url = get_url(path=relative_toggled_path) -%}
|
||||
{%- set toggled_image_url = get_url(path=relative_toggled_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
{#- Fallback to absolute path if relative path doesn't work -#}
|
||||
{%- if not meta -%}
|
||||
{%- set meta = get_image_metadata(path=src, allow_missing=true) -%}
|
||||
{%- set image_url = get_url(path=src) -%}
|
||||
{%- set image_url = get_url(path=src, cachebust=true) -%}
|
||||
{%- else %}
|
||||
{%- set image_url = get_url(path=relative_path) -%}
|
||||
{%- set image_url = get_url(path=relative_path, cachebust=true) -%}
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
|
||||
|
|
24
theme.toml
24
theme.toml
|
@ -375,3 +375,27 @@ custom_subset = true
|
|||
# voting = true
|
||||
# page_author_hashes = "" # hash (or list of hashes) of the author.
|
||||
# lazy_loading = true # Loads when the comments are in the viewport (using the Intersection Observer API).
|
||||
|
||||
# h-card configuration
|
||||
# Will identify you on the indieweb (see https://microformats.org/wiki/h-card)
|
||||
[extra.hcard]
|
||||
# Enable home page h-card.
|
||||
enable = true
|
||||
# Add your email to the card if extra.email is set and not encoded.
|
||||
# with_mail = true
|
||||
# Add your social links ('socials' config) to the card.
|
||||
with_social_links = true
|
||||
# Homepage url. Defaults to the value of 'base_url'.
|
||||
# homepage = "https://myhomepage.net"
|
||||
# avatar = "img/profile.webp"
|
||||
# Display name, default to the value of 'author'.
|
||||
# full_name = "John Doe"
|
||||
# Small bio, as shown on social media profiles.
|
||||
# biography = "Fond of the indieweb"
|
||||
#
|
||||
# You can add any property from https://microformats.org/wiki/h-card#Properties
|
||||
# Make sure to replace all '-' characters by '_'
|
||||
# Examples:
|
||||
# p_nickname = "nickname"
|
||||
# p_locality = "Bordeaux"
|
||||
# p_country_name = "France"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue