Skip to content

Commit

Permalink
Use full language name (en_US, etc.) instead of short (en, etc.)
Browse files Browse the repository at this point in the history
  • Loading branch information
Nitrrine committed Aug 30, 2024
1 parent ee0338a commit d9c697c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion crowdin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ files:
[
{
"source": "/html/i18n/en.json",
"translation": "/html/i18n/%two_letters_code%.json",
"translation": "/html/i18n/%locale_with_underscore%.json",
},
]
4 changes: 3 additions & 1 deletion html/alert.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ let blockedSite = {
path: "",
url: "",
};
let preferedLanguage = navigator.language.split("-")[0];
let preferedLanguage = navigator.language;

console.log(preferedLanguage);

fetch(`./i18n/${preferedLanguage}.json`)
.then((response) => response.json())
Expand Down
File renamed without changes.

0 comments on commit d9c697c

Please sign in to comment.