Skip to content

Commit

Permalink
Release v0.2024_11_01.0
Browse files Browse the repository at this point in the history
  • Loading branch information
salif committed Nov 1, 2024
1 parent 749fd44 commit ee2362d
Show file tree
Hide file tree
Showing 4 changed files with 77 additions and 99 deletions.
62 changes: 34 additions & 28 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,9 @@ A clean and elegant blog theme for [Zola](https://www.getzola.org/). Linkita is

## Linkita features

### i18n

- `en`: English
- `bg`: Bulgarian
- `eo`: Esperanto
- i18n
- Author profiles
- Improved SEO

## Installing

Expand Down Expand Up @@ -280,17 +278,17 @@ feed = true
paginate_by = 5
```

### `extra`
### (`extra`)

| key | type | comment |
| --- | --- | --- |
| `extra.math` | boolean | Enable KaTeX math formula support globally |
| `extra.mermaid` | boolean | Enable Mermaid support globally |
| `extra.comment` | boolean | Enable comment support globally |
| `extra.title_separator` | boolean | Title Separator |
| `extra.page_info` | array of strings | |
| `extra.title_separator` | string | Title Separator |
| `extra.page_info` | array of strings | Show page date, reading time, author names |
| `extra.style` | table | The theme style config |
| `extra.profiles` | table | Profiles |
| `extra.profiles` | table | Author profiles |
| `extra.menu` | array of tables | The top menu |
| `extra.footer` | table | The page footer options |
| `extra.locales` | table | Locale codes and date formats |
Expand All @@ -299,17 +297,18 @@ paginate_by = 5

Strings in `extra.page_info` that are not one of the following, will be displayed directly in the UI:
`"date"`, `"date_updated"`, `"reading_time"`, `"word_count"`, `"authors"`.
Default `extra.page_info` value is `["date", "date_updated", "reading_time", "authors"]`.

```toml
[extra]
math = false
mermaid = false
comment = false
title_separator = " | "
page_info = ["date", "date_updated", "reading_time", "word_count", "authors"]
# page_info = ["date", "date_updated", "reading_time", "word_count", "authors"]
```

### The theme style config (`extra.style`)
### Style config (`extra.style`)

| key | type | default value | comment |
| --- | --- | --- | --- |
Expand All @@ -335,13 +334,13 @@ header_dark_color = "#27272a"
| `extra.profiles[username]` | table | |
| `extra.profiles[username].avatar_url` | string | The URL of avatar |
| `extra.profiles[username].avatar_invert` | boolean | Invert color in dark mode |
| `extra.profiles[username].name` | string | Default profile name |
| `extra.profiles[username].bio` | string | Default profile bio |
| `extra.profiles[username].name` | string | Profile name for all languages |
| `extra.profiles[username].bio` | string | Profile bio for all languages |
| `extra.profiles[username].email` | string | Profile email |
| `extra.profiles[username].url` | string | Profile website |
| `extra.profiles[username].translations` | table | Profile name and bio translations |
| `extra.profiles[username].social` | array of tables | The social icons below the profile |
| `extra.profiles[username].open_graph` | table | |
| `extra.profiles[username].open_graph` | table | Open Graph |

```toml
[extra.profiles.your_username]
Expand All @@ -351,7 +350,7 @@ avatar_invert = true
# bio = ""
```

### `extra.profiles[username].translations`
### Profile translations (`extra.profiles[username].translations`)

| key | type |
| --- | --- |
Expand All @@ -362,11 +361,11 @@ avatar_invert = true

```toml
[extra.profiles.your_username.translations.fr]
name = "Profile Name in French"
bio = "Profile Bio in French"
name = "Profile name in French"
bio = "Profile bio in French"
```

### `extra.profiles[username].social`
### Social icons `extra.profiles[username].social`

| key | type |
| --- | --- |
Expand Down Expand Up @@ -400,15 +399,14 @@ url = "$BASE_URL/atom.xml"
| `extra.profiles[username].open_graph.last_name` | string | A name inherited from a family or marriage and by which the individual is commonly known |
| `extra.profiles[username].open_graph.username` | string | A short unique string to identify them |
| `extra.profiles[username].open_graph.gender` | string | Their gender |
| `extra.profiles[username].open_graph.fediverse_username` | string | Your username if you have a Fediverse account |
| `extra.profiles[username].open_graph.fediverse_server` | string | Your Fediverse server |
| `extra.profiles[username].open_graph.fediverse_url` | string | |
| `extra.profiles[config.author].open_graph.fb_app_id` | string | Set fb:app_id |
| `extra.profiles[config.author].open_graph.fb_admins` | array of strings | Set fb:admins |
| `extra.profiles[username].open_graph.fb_app_id` | string | Set fb:app_id |
| `extra.profiles[username].open_graph.fb_admins` | array of strings | Set fb:admins |
| `extra.profiles[username].open_graph.fediverse_creator` | table | Set if you a Fediverse account |
| `extra.profiles[username].open_graph.fediverse_creator.handle` | string | Your Fediverse handle |
| `extra.profiles[username].open_graph.fediverse_creator.domain` | string | Your Fediverse instance |
| `extra.profiles[username].open_graph.fediverse_creator.url` | string | Your Fediverse account URL |

See [the Open Graph protocol](https://ogp.me/).
Some options `config.author` to a real author in the `config.toml` file,
set a neutral profile instead.

```toml
[extra.profiles.your_username.open_graph]
Expand All @@ -418,19 +416,23 @@ first_name = "Your first name"
last_name = "Your last name"
username = "Your username"
gender = "female" # or "male"

[extra.profiles.your_username.open_graph.fediverse_creator]
# Example for "@user@mastodon.social"
fediverse_username = "user"
fediverse_server = "mastodon.social"
handle = "user"
domain = "mastodon.social"
```

The following options are only allowed in the `config.author` profile.
`fb_app_id` and `fb_admins` are only allowed in the `config.author`'s profile.
In addition, `image` and `image_alt` of the profile will be used as a
fallback open graph image for all pages.

```toml
[extra.profiles.default_author.open_graph]
fb_app_id = "Your fb app ID"
fb_admins = ["YOUR_USER_ID"]
# image = ""
# image_alt = ""
```

### The top menu (`extra.menu`)
Expand All @@ -447,24 +449,28 @@ fb_admins = ["YOUR_USER_ID"]
```toml
[[extra.menu]]
url = "$BASE_URL/projects/"
# name = "Projects"
[extra.menu.names]
en = "Projects"
# fr = "Projects in French"

[[extra.menu]]
url = "$BASE_URL/archive/"
# name = "Archive"
[extra.menu.names]
en = "Archive"
# fr = "Archive in French"

[[extra.menu]]
url = "$BASE_URL/tags/"
# name = "Tags"
[extra.menu.names]
en = "Tags"
# fr = "Tags in French"

[[extra.menu]]
url = "$BASE_URL/about/"
# name = "About"
[extra.menu.names]
en = "About"
# fr = "About in French"
Expand Down
94 changes: 33 additions & 61 deletions config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,57 +7,39 @@ generate_feeds = true

# Configuration of the Markdown rendering
[markdown]
# When set to "true", all code blocks are highlighted.
highlight_code = true

# A list of directories used to search for additional `.sublime-syntax` and `.tmTheme` files.
extra_syntaxes_and_themes = []

# The theme to use for code highlighting.
# See below for list of allowed values.
highlight_theme = "monokai"

[languages.bg]
title = "Линкита"
description = "Линкита е многоезична, SEO оптимизирана, изчистена и елегантна блог тема за Zola."
# generate_feeds = true
feed_filenames = ["atom.xml"]
[[languages.bg.taxonomies]]
name = "tags"
feed = true
paginate_by = 5
[[languages.bg.taxonomies]]
name = "authors"
feed = true
paginate_by = 5
taxonomies = [
{ name = "tags", feed = true, paginate_by = 5 },
{ name = "authors", feed = true, paginate_by = 5 },
]

[languages.en]
title = "Linkita"
description = "A clean and elegant blog theme for Zola. Linkita is based on Kita and Hugo-Paper and is multilingual and SEO friendly."
generate_feeds = true
feed_filenames = ["atom.xml"]
[[languages.en.taxonomies]]
name = "tags"
feed = true
paginate_by = 5
[[languages.en.taxonomies]]
name = "authors"
feed = true
paginate_by = 5
taxonomies = [
{ name = "tags", feed = true, paginate_by = 5 },
{ name = "authors", feed = true, paginate_by = 5 },
]

[languages.eo]
title = "Linkita"
description = "Pura kaj eleganta bloga temo por Zola. Linkita baziĝas sur Kita kaj Hugo-Paper kaj estas plurlingva kaj SEO-amika."
generate_feeds = true
feed_filenames = ["atom.xml"]
[[languages.eo.taxonomies]]
name = "tags"
feed = true
paginate_by = 5
[[languages.eo.taxonomies]]
name = "authors"
feed = true
paginate_by = 5
taxonomies = [
{ name = "tags", feed = true, paginate_by = 5 },
{ name = "authors", feed = true, paginate_by = 5 },
]

[extra]
math = false
Expand All @@ -81,6 +63,11 @@ avatar_url = "icons/github.svg"
avatar_invert = true
# name = "Default Name"
# bio = "Default Bio"
social = [
{ name = "codeberg", url = "https://codeberg.org/salif/linkita" },
{ name = "github", url = "https://github.com/salif/linkita" },
{ name = "rss", url = "$BASE_URL/atom.xml" },
]

[extra.profiles.your_username.translations]
[extra.profiles.your_username.translations.en]
Expand All @@ -93,18 +80,6 @@ bio = "Линкита е многоезична, SEO оптимизирана,
name = "Linkita - Temo por Zola"
bio = "Pura kaj eleganta bloga temo por Zola. Linkita baziĝas sur Kita kaj Hugo-Paper kaj estas plurlingva kaj SEO-amika."

[[extra.profiles.your_username.social]]
name = "codeberg"
url = "https://codeberg.org/salif/linkita"

[[extra.profiles.your_username.social]]
name = "github"
url = "https://github.com/salif/linkita"

[[extra.profiles.your_username.social]]
name = "rss"
url = "$BASE_URL/atom.xml"

[extra.profiles.your_username.open_graph]
image = "images/screenshot.png"
image_alt = "A screenshot of this website"
Expand All @@ -117,39 +92,36 @@ name = "Salif"
bio = "Hi, I'm Salif"
email = "mail@salif.eu"
url = "https://salif.eu"
[extra.profiles.salif.translations]
social = [
{ name = "codeberg", url = "https://codeberg.org/salif" },
{ name = "github", url = "https://github.com/salif" },
{ name = "bluesky", url = "https://bsky.app/profile/bg.salif.eu" },
{ name = "rss", url = "$BASE_URL/authors/salif/atom.xml" },
]
[extra.profiles.salif.translations.bg]
name = "Салиф"
url = "https://salif.eu/bg/"
[extra.profiles.salif.translations.eo]
name = "Salif"
url = "https://salif.eu/eo/"
[extra.profiles.salif.open_graph]
first_name = "Salif"
last_name = "Mehmed"
username = "salif"
gender = "male"
fediverse_username = "bg.salif.eu"
fediverse_server = "bsky.brid.gy"
fediverse_url = "https://bsky.brid.gy/r/https://bsky.app/profile/bg.salif.eu"
[[extra.profiles.salif.social]]
name = "codeberg"
url = "https://codeberg.org/salif"
[[extra.profiles.salif.social]]
name = "github"
url = "https://github.com/salif"
[[extra.profiles.salif.social]]
name = "bluesky"
url = "https://bsky.app/profile/bg.salif.eu"
[[extra.profiles.salif.social]]
name = "rss"
url = "$BASE_URL/authors/salif/atom.xml"
[extra.profiles.salif.open_graph.fediverse_creator]
handle = "bg.salif.eu"
domain = "bsky.brid.gy"
url = "https://bsky.brid.gy/r/https://bsky.app/profile/bg.salif.eu"

# Kita Theme's profile
[extra.profiles.kita]
name = "Kita"
bio = "Kita - Zola Theme"
url = "https://st1020.github.io/kita/"
[[extra.profiles.kita.social]]
name = "github"
url = "https://github.com/st1020/kita"
social = [
{ name = "github", url = "https://github.com/st1020/kita" }
]

# Menu
[[extra.menu]]
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "linkita",
"version": "0.2024_10_30.0",
"version": "0.2024_11_01.0",
"description": "A clean and elegant blog theme for Zola. Linkita is based on Kita and Hugo-Paper and is multilingual and SEO friendly.",
"homepage": "https://codeberg.org/salif/linkita",
"license": "MIT",
Expand Down
18 changes: 9 additions & 9 deletions templates/partials/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -173,14 +173,14 @@
{%- if profile_data.open_graph %}
{%- set profile_og_data = profile_data.open_graph %}
{%- endif %}
{%- if profile_og_data.fediverse_username and profile_og_data.fediverse_server %}
<meta property="fediverse:creator" content="@{{ profile_og_data.fediverse_username }}@{{
profile_og_data.fediverse_server | replace(from='https://', to='') }}" />
{%- if profile_og_data.fediverse_url %}
<link rel="me" href="{{ profile_og_data.fediverse_url | safe }}" />
{%- if profile_og_data.fediverse_creator.handle and profile_og_data.fediverse_creator.domain %}
<meta property="fediverse:creator" content="@{{ profile_og_data.fediverse_creator.handle }}@{{
profile_og_data.fediverse_creator.domain | replace(from='https://', to='') }}" />
{%- if profile_og_data.fediverse_creator.url %}
<link rel="me" href="{{ profile_og_data.fediverse_creator.url | safe }}" />
{%- else %}
<link rel="me" href="https://{{ profile_og_data.fediverse_server |
replace(from='https://', to='') }}/@{{ profile_og_data.fediverse_username }}" />
<link rel="me" href="https://{{ profile_og_data.fediverse_creator.domain |
replace(from='https://', to='') }}/@{{ profile_og_data.fediverse_creator.handle }}" />
{%- endif %}
{%- endif %}
{%- endif %}
Expand Down Expand Up @@ -253,10 +253,10 @@
{%- endif %}
{%- if feed_filename is ending_with("atom.xml") %}
<link rel="alternate" type="application/atom+xml" href="{{
get_url(path=feed_filename, lang=lang) }}" title="{{ feed_title }}{{ title_separator }}Atom Feed" />
get_url(path=feed_filename, lang=lang) }}" title="{{ feed_title }}{{ title_separator }}Atom" />
{%- elif feed_filename is ending_with("rss.xml") %}
<link rel="alternate" type="application/rss+xml" href="{{
get_url(path=feed_filename, lang=lang) }}" title="{{ feed_title }}{{ title_separator }}RSS Feed" />
get_url(path=feed_filename, lang=lang) }}" title="{{ feed_title }}{{ title_separator }}RSS" />
{%- else %}
<link rel="alternate" title="{{ feed_title }}{{ title_separator }}{{ feed_filename }}" href="{{
get_url(path=feed_filename, lang=lang) }}" />
Expand Down

0 comments on commit ee2362d

Please sign in to comment.