mirror of
https://github.com/langgenius/webapp-conversation.git
synced 2025-12-08 17:32:27 +08:00
feat: add spanish language
This commit is contained in:
@ -2,8 +2,10 @@
|
||||
import i18n from 'i18next'
|
||||
import { initReactI18next } from 'react-i18next'
|
||||
import commonEn from './lang/common.en'
|
||||
import commonEs from './lang/common.es'
|
||||
import commonZh from './lang/common.zh'
|
||||
import appEn from './lang/app.en'
|
||||
import appEs from './lang/app.es'
|
||||
import appZh from './lang/app.zh'
|
||||
import type { Locale } from '.'
|
||||
|
||||
@ -14,6 +16,12 @@ const resources = {
|
||||
app: appEn,
|
||||
},
|
||||
},
|
||||
'es': {
|
||||
translation: {
|
||||
common: commonEs,
|
||||
app: appEs,
|
||||
},
|
||||
},
|
||||
'zh-Hans': {
|
||||
translation: {
|
||||
common: commonZh,
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
export const i18n = {
|
||||
defaultLocale: 'en',
|
||||
locales: ['en', 'zh-Hans'],
|
||||
locales: ['en', 'es', 'zh-Hans'],
|
||||
} as const
|
||||
|
||||
export type Locale = typeof i18n['locales'][number]
|
||||
|
||||
33
i18n/lang/app.es.ts
Normal file
33
i18n/lang/app.es.ts
Normal file
@ -0,0 +1,33 @@
|
||||
const translation = {
|
||||
common: {
|
||||
welcome: 'Bienvenido a usar',
|
||||
appUnavailable: 'App es inaccesible',
|
||||
appUnkonwError: 'App es inaccesible',
|
||||
},
|
||||
chat: {
|
||||
newChat: 'Nuevo chat',
|
||||
newChatDefaultName: 'Nueva conversación',
|
||||
openingStatementTitle: 'Frase de apertura',
|
||||
powerBy: 'Desarrollado por',
|
||||
prompt: 'Prompt',
|
||||
privatePromptConfigTitle: 'Ajustes de conversación',
|
||||
publicPromptConfigTitle: 'Prompt inicial',
|
||||
configStatusDes: 'Antes de comenzar, puede modificar la configuración de la conversación',
|
||||
configDisabled:
|
||||
'La configuración de la sesión anterior se ha utilizado para esta sesión.',
|
||||
startChat: 'Comenzar chat',
|
||||
privacyPolicyLeft:
|
||||
'Por favor lea la ',
|
||||
privacyPolicyMiddle:
|
||||
'política de privacidad',
|
||||
privacyPolicyRight:
|
||||
' proporcionada por el desarrollador de la aplicación.',
|
||||
},
|
||||
errorMessage: {
|
||||
valueOfVarRequired: 'El valor de las variables no puede estar vacío',
|
||||
waitForResponse:
|
||||
'Por favor espere a que la respuesta al mensaje anterior se complete.',
|
||||
},
|
||||
}
|
||||
|
||||
export default translation
|
||||
33
i18n/lang/common.es.ts
Normal file
33
i18n/lang/common.es.ts
Normal file
@ -0,0 +1,33 @@
|
||||
const translation = {
|
||||
api: {
|
||||
success: 'Éxito',
|
||||
saved: 'Guardado',
|
||||
create: 'Creado',
|
||||
},
|
||||
operation: {
|
||||
confirm: 'Confirmar',
|
||||
cancel: 'Cancelar',
|
||||
clear: 'Limpiar',
|
||||
save: 'Guardar',
|
||||
edit: 'Editar',
|
||||
refresh: 'Reiniciar',
|
||||
search: 'Buscar',
|
||||
send: 'Enviar',
|
||||
lineBreak: 'Salto de línea',
|
||||
like: 'Me gusta',
|
||||
dislike: 'No me gusta',
|
||||
ok: 'OK',
|
||||
},
|
||||
imageUploader: {
|
||||
uploadFromComputer: 'Subir desde el ordenador',
|
||||
uploadFromComputerReadError: 'La lectura de la imagen falló, por favor inténtelo de nuevo.',
|
||||
uploadFromComputerUploadError: 'Error al subir la imagen, por favor inténtelo de nuevo.',
|
||||
uploadFromComputerLimit: 'Las imágenes subidas no pueden superar los {{size}} MB',
|
||||
pasteImageLink: 'Pegar enlace de imagen',
|
||||
pasteImageLinkInputPlaceholder: 'Pegar enlace de imagen aquí',
|
||||
pasteImageLinkInvalid: 'Enlace de imagen no válido',
|
||||
imageUpload: 'Subir imagen',
|
||||
},
|
||||
}
|
||||
|
||||
export default translation
|
||||
Reference in New Issue
Block a user