Replies: 1 comment 1 reply
-
I'm successfully using Papermod for a multilingual website, both available in French and in English, and the menus are correctly translated. Here is the full content of the file
and here is the full content of
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
Thank you for this beautiful Theme !
I am developing a multisite and multilingual with Hugo and PaperMod. I experience some issues in translating the menu. For exemple, I want to add an about page but when I switch to the French version of the site, from the home page, the menu bar still show about and not À propos. The problem is similar with the href which is still /about/ and not /a-propos/, and the Title.
I have deeply red the Hugo multilingual documentation and here’s what is my configuration and what I understand of the problem so far:
about
identifierhugo-PaperMod/layouts/partials/header.html
Line 133 in 4a924ce
{{- or (T .Identifier) .Name | safeHTML -}}
and now the menu is rendering correctly in French, but of course not the href and title.I don't know if my issue is more related to Hugo or PaperMod, but I don't always have the same problem with other themes. Maybe they are just not building the menu with the same structure.
I'm not the only one with this problem :
#967 (comment)
Thank you for your help.
If I can help or do other tests let me know.
Edit:
To make it work as intended I had to change :
https://github.com/adityatelange/hugo-PaperMod/blob/4a924cef54081b61530a30bd69d442ae95f16561/layouts/partials/header.html#L129C20-L129C49
to
href="{{ ($.Site.GetPage .Identifier).Permalink | absLangURL }}
Beta Was this translation helpful? Give feedback.
All reactions