elk/config/i18n.ts

64 lines
943 B
TypeScript
Raw Permalink Normal View History

2023-01-09 20:20:26 +00:00
import { ref } from 'vue'
2023-01-09 20:20:26 +00:00
interface LocaleObjectData {
code: string
name: string
dir?: 'ltr' | 'rtl'
}
2023-01-09 20:20:26 +00:00
export const defaultLocale = 'en-US'
export const locale = ref(defaultLocale)
export const locales: LocaleObjectData[] = [
{
code: 'en-US',
name: 'English (US)',
},
{
code: 'en-GB',
name: 'English (UK)',
},
{
code: 'de-DE',
name: 'Deutsch',
},
{
code: 'zh-CN',
name: '简体中文',
},
2022-12-31 04:07:11 +00:00
{
code: 'zh-TW',
name: '繁体中文',
},
{
code: 'ja-JP',
name: '日本語',
},
2023-01-04 20:10:09 +00:00
{
code: 'nl-NL',
name: 'Nederlands',
},
{
code: 'es-ES',
name: 'Español',
},
{
code: 'fr-FR',
name: 'Français',
},
{
code: 'uk-UA',
name: 'Українська',
},
2022-12-14 21:19:38 +00:00
{
code: 'cs-CZ',
name: 'Česky',
},
2023-01-09 20:20:26 +00:00
{
code: 'ar-EG',
name: 'العربية',
2023-01-09 20:20:26 +00:00
dir: 'rtl' as const,
},
2023-01-09 20:20:26 +00:00
].sort((a, b) => a.code.localeCompare(b.code))