Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[taxonomy] Original + translated tags on bilingual site on default language #425

Closed
sebastian0119 opened this issue Mar 16, 2024 · 3 comments

Comments

@sebastian0119
Copy link

Hi there!

I am using the Typhoon theme with blog functionality, with two languages activated: Spanish (ES) as default language and English (EN) as second option.

So each post has currently two files in each directory:

spec.md
spec.en.md

where spec.md is the default file (in Spanish) and spec.en.md the translated file.

Each file has in its frontmatter something like this (extract):

  • For default files in Spanish:
---
taxonomy:
    tag: [diseño, planos, inspección]
---
  • For translated files in English:
---
taxonomy:
    tag: [design, cds, supervision]
---

When switching to English, the taxonomy list is "translated" correctly, means that it only filters the tags from all spec.en.md files.
See also the following image:
image

However, when using Spanish as the default language, all tags are duplicated, meaning that the Spanish version + the English version are listed (e.g. diseño + design or planos + cds).
Another image:
image

All the rest of translation is working well, the URL also always indicates which language is used (e.g. https://localhost:8000/es/blog/ or https://localhost:8000/en/blog/); it's just the tags.

And by the way, when being in the Spanish environment and clicking on a tag in English from the tag list (e.g. design), an empty list of posts comes up, whereas when clicking on "diseño" the correct list of posts is shown.

Any idea or suggestion is appreciated.

Grav v1.7.44
Taxonomylist v1.3.5

@sebastian0119
Copy link
Author

sebastian0119 commented Mar 17, 2024

A quick afterthought: I seems that it has something to do with the cache.

When I am on the English version and clear the cache, then all tags are fine (English only). Switching to Spanish, tags for English + Spanish come up.

The other way around is exactly the same: when I am on Spanish and clear the cache + reload the page, all tags are fine (Spanish only) and when switching to English, both versions are shown.

Right now, where this problems occurs, I am on development settings:

cache:
  enabled: true
  check:
    method: file

@sebastian0119
Copy link
Author

Seems related to getgrav/grav-plugin-taxonomylist#40

@rhukster
Copy link
Member

Yes, this is a taxonomy specific issue, not an issue with Typhoon itself. I'll pick up the conversation on the taxonomy plugin issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants