mirror of
https://github.com/Luzifer/ots.git
synced 2026-01-06 18:45:36 -05:00
Fix: Use full browser provided language tag
instead of limiting to only the primary tag Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
fde887bb6a
commit
ff91301acc
1 changed files with 1 additions and 1 deletions
|
|
@ -18,7 +18,7 @@ const cookieSet = Object.fromEntries(document.cookie.split('; ')
|
|||
.map(el => decodeURIComponent(el))))
|
||||
|
||||
const i18n = new VueI18n({
|
||||
locale: cookieSet.lang?.split(/[_-]/)[0] || navigator?.language?.split(/[_-]/)[0] || 'en',
|
||||
locale: cookieSet.lang || navigator?.language || 'en',
|
||||
fallbackLocale: 'en',
|
||||
messages,
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue