Skip to content

Commit

Permalink
1,375th Commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Shyam-Chen committed Feb 18, 2024
1 parent 66c1c54 commit f77649d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,15 @@ watch(
if (_language) {
lang.value = _language;
document.documentElement.lang = _language;
return;
}
const found = langs.value.find((item) => item.startsWith(val) || val.startsWith(item));
if (found) {
lang.value = found;
document.documentElement.lang = found;
return;
}
}
Expand Down
1 change: 1 addition & 0 deletions src/layouts/baseline/Baseline.vue
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ const languageOptions = [
function changeLang(lang: string) {
localer.lang.value = lang;
document.documentElement.lang = lang;
localStorage.setItem('language', lang);
}
</script>
Expand Down

0 comments on commit f77649d

Please sign in to comment.