Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(client): move everything in root but electron to the client subfolder #1945

Merged
merged 22 commits into from
Apr 4, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update client/src/www/ui_components/app-root.js
Co-authored-by: Vinicius Fortuna <[email protected]>
  • Loading branch information
daniellacosse and fortuna authored Apr 4, 2024
commit 904fd7286f3aba1f0e87ed2a68bdd9e7312b1b22
24 changes: 11 additions & 13 deletions client/src/www/ui_components/app-root.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,21 +80,19 @@ function getBrowserLanguages() {
return [navigator.language];
}

window.OutlineI18n = {
getBestMatchingLanguage(available) {
const lookUpAvailable = makeLookUpLanguage(available);
for (const candidate of getBrowserLanguages()) {
const parts = candidate.split('-');
while (parts.length) {
const joined = parts.join('-');
const closest = lookUpAvailable(joined);
if (closest) {
return closest;
}
parts.pop();
function getBestMatchingLanguage(available) {
const lookUpAvailable = makeLookUpLanguage(available);
for (const candidate of getBrowserLanguages()) {
const parts = candidate.split('-');
while (parts.length) {
const joined = parts.join('-');
const closest = lookUpAvailable(joined);
if (closest) {
return closest;
}
parts.pop();
}
},
}
};

// Workaround:
Expand Down
Loading