Skip to content

Commit b18d352

Browse files
feat: add spanish locale (#13)
* Feature: add spanish locate * Properties name and file format corrections * Spanish translation correction Co-authored-by: Andreas Bichinger <andreas.bichinger@gmail.com>
1 parent 11660b0 commit b18d352

File tree

3 files changed

+76
-2
lines changed

3 files changed

+76
-2
lines changed

core/src/locale/es.js

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
export default {
2+
'*': {
3+
prefix: 'todos los',
4+
suffix: '',
5+
text: 'Desconocido',
6+
'*': {
7+
empty: { text: 'todos los {{ field.id }}' },
8+
value: { text: '{{ val.text }}' },
9+
range: { text: '{{ start.text }}-{{ end.text }}' },
10+
everyX: { text: 'todos/as {{ every.value }}' }
11+
},
12+
month: {
13+
'*': { prefix: 'en' },
14+
empty: { text: 'todos los meses' },
15+
value: { text: '{{ val.alt }}' },
16+
range: { text: '{{ start.alt }}-{{ end.alt }}' }
17+
},
18+
day: {
19+
'*': { prefix: 'en' },
20+
empty: { text: 'todos los días' },
21+
value: { text: 'los días {{ val.alt }}' }
22+
},
23+
dayOfWeek: {
24+
'*': { prefix: 'de' },
25+
empty: { text: 'todos los días de la semana' },
26+
value: { text: 'los {{ val.alt }}' },
27+
range: { text: '{{ start.alt }}-{{ end.alt }}' }
28+
},
29+
hour: {
30+
'*': { prefix: 'a' },
31+
empty: { text: 'todas las horas' },
32+
value: { text: 'las {{ val.text }}' }
33+
},
34+
minute: {
35+
'*': { prefix: ':' },
36+
empty: { text: 'todos los minutos' }
37+
}
38+
},
39+
minute: {
40+
prefix: 'todos los',
41+
text: 'minutos'
42+
},
43+
hour: {
44+
prefix: 'todas las',
45+
text: 'horas',
46+
minute: {
47+
'*': {
48+
prefix: 'a los',
49+
suffix: 'minutos'
50+
},
51+
empty: { text: 'todos', prefix: 'a', suffix: 'los minutos' }
52+
}
53+
},
54+
day: {
55+
text: 'Días'
56+
},
57+
week: {
58+
text: 'Semanas'
59+
},
60+
month: {
61+
text: 'Meses',
62+
dayOfWeek: {
63+
'*': { prefix: 'y' }
64+
}
65+
},
66+
year: {
67+
text: 'años',
68+
dayOfWeek: {
69+
'*': { prefix: 'y' }
70+
}
71+
}
72+
}

core/src/locale/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,14 @@ import util from '../util'
33
import de from './de'
44
import en from './en'
55
import pt from './pt'
6+
import es from './es'
67
const { genItems, pad, traverse } = util
78

89
const locales = {
910
en,
1011
de,
11-
pt
12+
pt,
13+
es
1214
}
1315

1416
class Locale {

docs/src/.vuepress/components/cron-demo.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ export default {
6666
}
6767
]
6868
69-
const locales = ['en', 'de', 'pt']
69+
const locales = ['en', 'de', 'pt', 'es']
7070
7171
const flavor = flavors[0]
7272

0 commit comments

Comments
 (0)