Open wout opened 2 years ago
Language is indeed correct only for the active tab: If the French tab is active and you choose "Visit this page in French" it will correctly open the French page. If the English tab is active and you use "Visit this page in French" from dropdown in the French tab, it will open the English page.
I'm not sure to understand, can you provide a way to reproduce ? What's your config line that breaks it ? I guess the plugin uses a hardcoded URL, maybe it needs to be hooked to a panel variable that contains the right config ?
Closing until more information is available, feel free to reopen.
This happens when languages have custom domains or paths. The Path or domain for the currently selected language is used in the menu.
Ok, so you referring to Different domains for each language. Language Specific urls might be affected too. The issue is that the previewUrl always links to the active language url/domain.
Indeed, in such a setup, the Kirby Panel doesn't know about the other translation URL, serving the current model previewUrl. It seems that Kirby only sends the previewUrl for the current language, so this extra information should be send manually as prop
or computed
.
Should be fixed now, I didn't test in-depth so there might be some bugs.
Thanks! I didn't have time to recheck, but will hopefully be able to test the fix in coming days.
I'm using a dedicated hostname per language. The
Visit this page in ...
always link to the hostname of the currently selected language.