mirror of
https://codeberg.org/SafeTwitch/safetwitch.git
synced 2024-12-22 13:22:58 -05:00
Update locales
This commit is contained in:
parent
bad5529d84
commit
5725e84fc7
3 changed files with 20 additions and 4 deletions
11
src/i18n.ts
11
src/i18n.ts
|
@ -7,6 +7,11 @@ import fa from '@/locales/fa.json'
|
|||
import he from '@/locales/he.json'
|
||||
import ru from '@/locales/ru.json'
|
||||
import ko from '@/locales/ko.json'
|
||||
import cs from '@/locales/cs.json'
|
||||
import pl from '@/locales/pl.json'
|
||||
import it from '@/locales/it.json'
|
||||
import fr from '@/locales/fr.json'
|
||||
|
||||
|
||||
export default createI18n({
|
||||
legacy: false,
|
||||
|
@ -21,6 +26,10 @@ export default createI18n({
|
|||
'fa-IR': fa,
|
||||
'he-IL': he,
|
||||
'ru-RU': ru,
|
||||
'ko-KR': ko
|
||||
'ko-KR': ko,
|
||||
'cd-CZ': cs,
|
||||
'pl-PL': pl,
|
||||
'it-IT': it,
|
||||
'fr-FR': fr,
|
||||
}
|
||||
})
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
export const setLanguage = (selectedLanguage: string, i18n: any) => {
|
||||
// Locales and languages in arrays to match them
|
||||
const locales = ['en-US', 'es-ES', 'nl-NL', 'pt-PT', 'fa-IR', 'he-IL', 'ru-RU', 'ko-KR']
|
||||
const languages = ['English', 'Español', 'Nederlands', 'Português', 'فارسی', 'עִבְרִית', 'Русский', '한국어']
|
||||
const locales = ['en-US', 'es-ES', 'nl-NL', 'pt-PT', 'fa-IR', 'he-IL', 'ru-RU', 'ko-KR', 'cs-CZ', 'pl-PL', 'it-IT', 'fr-FR']
|
||||
const languages = ['English', 'Español', 'Nederlands', 'Português', 'فارسی', 'עִבְרִית', 'Русский', '한국어', 'Česky', 'Polski', 'Italia', 'Français']
|
||||
|
||||
const locale = locales[languages.indexOf(selectedLanguage)]
|
||||
localStorage.setItem("language", locale)
|
||||
|
@ -24,7 +24,7 @@ export function getDefaultSettings() {
|
|||
},
|
||||
language: {
|
||||
name: 'language',
|
||||
options: ['English', 'Español', 'Nederlands', 'Português', 'فارسی', 'עִבְרִית', 'Русский', '한국어'],
|
||||
options: ['English', 'Español', 'Nederlands', 'Português', 'فارسی', 'עִבְרִית', 'Русский', '한국어', 'Česky', 'Polski', 'Italia', 'Français'],
|
||||
selected: 'English',
|
||||
type: 'option'
|
||||
},
|
||||
|
|
|
@ -77,6 +77,13 @@ export default {
|
|||
</li>
|
||||
</ul>
|
||||
|
||||
<h1 class="font-bold text-3xl mt-2">{{ $t("nav.theme") }}</h1>
|
||||
<hr class="my-2" />
|
||||
<ul>
|
||||
<li v-for="theme in themeList" :key="theme.name">
|
||||
{{ theme.name }}</li>
|
||||
</ul>
|
||||
|
||||
<div class="space-x-2 mt-3">
|
||||
<button @click="save" class="bg-surface0 p-4 py-2 rounded-md">{{ $t('settings.saveButton') }}</button>
|
||||
<!-- <button @click="download" class="bg-surface0 p-4 py-2 rounded-md">Export</button>
|
||||
|
|
Loading…
Reference in a new issue