Skip to content

Commit

Permalink
✨ feat: add series functionality (#406)
Browse files Browse the repository at this point in the history
Co-authored-by: welpo <[email protected]>
  • Loading branch information
ZzMzaw and welpo authored Nov 7, 2024
1 parent 57a0a8e commit 0253799
Show file tree
Hide file tree
Showing 52 changed files with 1,822 additions and 73 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ tabi has a perfect score on Google's Lighthouse audit:

- [X] [Set any language as default](https://welpo.github.io/tabi/blog/faq-languages/#how-do-i-set-a-default-language-for-my-site). Set your base site to Chinese, Spanish, French, Hindi… or any [other supported language](/i18n). The theme's interface will be translated accordingly.
- [X] [Integration with remote repositories](https://welpo.github.io/tabi/blog/mastering-tabi-settings/#git-repository-integration) on GitHub, GitLab, Gitea & Codeberg for commit history and showing the site source.
- [X] [Series support](https://welpo.github.io/tabi/blog/series/) for creating sequential content like tutorials, courses, and multi-part stories.
- [X] Dark and light themes. Defaults to the OS setting, with a switcher in the navigation bar.
- [X] Thorough documentation. See [Mastering tabi Settings: A Comprehensive Guide](https://welpo.github.io/tabi/blog/mastering-tabi-settings/).
- [X] Perfect Lighthouse score (Performance, Accessibility, Best Practices and SEO).
Expand Down
10 changes: 10 additions & 0 deletions config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,16 @@ show_date = true
# "both" - Show both the original date and the last updated date.
post_listing_date = "date"

# Show "Jump to posts" link next to series' title.
# By default, the link appears automatically when a series description exceeds 2000 characters.
# Can be set at page or section levels, following the hierarchy: page > section > config. See: https://welpo.github.io/tabi/blog/mastering-tabi-settings/#settings-hierarchy
# show_jump_to_posts = true

# Determines if indexes should be increasing (false) or decreasing (true) in series' posts list.
# It has only effect if the section uses indexes metadata (which is only the case for series as of now).
# Can be set at section levels, following the hierarchy: section > config. See: https://welpo.github.io/tabi/blog/mastering-tabi-settings/#settings-hierarchy
post_listing_index_reversed = false # Defaults to false.

# DEPRECATED!
# Use Zola's built-in `bottom_footnotes = true` in the [markdown] section instead. (Available since v0.19.0)
# Adds backlinks to footnotes (loads ~500 bytes of JavaScripts).
Expand Down
Binary file not shown.
Binary file not shown.
28 changes: 28 additions & 0 deletions content/blog/mastering-tabi-settings/index.ca.md
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,34 @@ Si configures `tag_sorting = "frequency"`, s'ordenaran segons el nombre de publi

---

### Sèries

Per a una explicació detallada, consulta la [documentació de sèries](@/blog/series/index.ca.md).

#### Enllaç per saltar a les publicacions

| Pàgina | Secció | `config.toml` | Segueix la jerarquia | Requereix JavaScript |
|:------:|:-------:|:-------------:|:------------------:|:-------------------:|
||||||

Per defecte, apareix automàticament un enllaç "Salta a les publicacions" al costat del títol de la sèrie quan una sèrie té un contingut de més de 2000 caràcters:

{{ dual_theme_image(light_src="blog/series/img/jump_to_series_posts_light.webp", dark_src="blog/series/img/jump_to_series_posts_dark.webp" alt="enllaç per saltar a les publicacions de la sèrie", full_width=true) }}

Estableix `show_jump_to_posts = true` per forçar l'activació de la funció i `show_jump_to_posts = false` per desactivar-la.

#### Indexació de pàgines de sèries

| Pàgina | Secció | `config.toml` | Segueix la jerarquia | Requereix JavaScript |
|:------:|:-------:|:-------------:|:------------------:|:-------------------:|
||||||

Per defecte, les pàgines de sèries s'indexen (usant una indexació basada en 1) segons el `sort_by` de la secció de sèries.

Estableix `post_listing_index_reversed = true` per invertir aquest índex.

---

## Integració amb repositoris Git

| Pàgina | Secció | `config.toml` | Segueix la jerarquia | Requereix JavaScript |
Expand Down
28 changes: 28 additions & 0 deletions content/blog/mastering-tabi-settings/index.es.md
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,34 @@ Si configuras `tag_sorting = "frequency"`, se ordenarán según el número de pu

---

### Series

Para una explicación detallada, consulta la [documentación de series](@/blog/series/index.es.md).

#### Enlace para saltar a las publicaciones

| Página | Sección | `config.toml` | Sigue jerarquía | Requiere JavaScript |
|:------:|:-------:|:-------------:|:------------------:|:-------------------:|
||||||

Por defecto, aparece automáticamente un enlace "Saltar a publicaciones" junto al título de la serie cuando una serie tiene un contenido de más de 2000 caracteres:

{{ dual_theme_image(light_src="blog/series/img/jump_to_series_posts_light.webp", dark_src="blog/series/img/jump_to_series_posts_dark.webp" alt="enlace para saltar a las publicaciones de la serie", full_width=true) }}

Establece `show_jump_to_posts = true` para forzar la activación de la función y `show_jump_to_posts = false` para desactivarla.

#### Indexación de páginas de series

| Página | Sección | `config.toml` | Sigue la jerarquía | Requiere JavaScript |
|:------:|:-------:|:-------------:|:------------------:|:-------------------:|
||||||

Por defecto, las páginas de series se indexan (usando una indexación basada en 1) según el `sort_by` de la sección de series.

Establece `post_listing_index_reversed = true` para invertir el índice.

---

## Integración con repositorios Git

| Página | Sección | `config.toml` | Sigue la jerarquía | Requiere JavaScript |
Expand Down
28 changes: 28 additions & 0 deletions content/blog/mastering-tabi-settings/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,34 @@ Setting `tag_sorting = "frequency"` will sort them by number-of-posts (descendin

---

### Series

For a detailed explanation of the series feature, see the [series documentation](@/blog/series/index.md).

#### Jump to posts link

| Page | Section | `config.toml` | Follows Hierarchy | Requires JavaScript |
|:----:|:-------:|:-------------:|:-----------------:|:-------------------:|
||||||

By default, a "Jump to posts" link automatically appears next to the series title when a series has a content over 2000 characters:

{{ dual_theme_image(light_src="blog/series/img/jump_to_series_posts_light.webp", dark_src="blog/series/img/jump_to_series_posts_dark.webp" alt="jump to series posts link", full_width=true) }}

Set `show_jump_to_posts = true` to force the feature on and `show_jump_to_posts = false` to force it off.

#### Series pages indexation

| Page | Section | `config.toml` | Follows Hierarchy | Requires JavaScript |
|:----:|:-------:|:-------------:|:-----------------:|:-------------------:|
||||||

By default, series page are indexed (using a 1-based indexing) as per the series section `sort_by`.

Set `post_listing_index_reversed = true` to reverse this index.

---

## Git Repository Integration

| Page | Section | `config.toml` | Follows Hierarchy | Requires JavaScript |
Expand Down
Binary file not shown.
Binary file not shown.
Binary file added content/blog/series/img/series_dark.webp
Binary file not shown.
Binary file added content/blog/series/img/series_light.webp
Binary file not shown.
Binary file added content/blog/series/img/series_reversed_dark.webp
Binary file not shown.
Binary file not shown.
Loading

0 comments on commit 0253799

Please sign in to comment.