mirror of
https://github.com/discourse/discourse-custom-header-links.git
synced 2025-07-02 03:02:09 +00:00
Filter out links which locale is different from the html document's
This commit is contained in:
parent
faab3ef680
commit
3b99de4972
@ -47,6 +47,11 @@ export default {
|
||||
anchorAttributes.target = linkTarget;
|
||||
}
|
||||
|
||||
if (locale !== ""
|
||||
&& document.documentElement.lang
|
||||
&& document.documentElement.lang !== locale
|
||||
) { return ; }
|
||||
|
||||
headerLinks.push(
|
||||
h(
|
||||
`li.headerLink${deviceClass}${keepOnScrollClass}${localeClass}${linkClass}`,
|
||||
|
Loading…
x
Reference in New Issue
Block a user