Skip to content

Commit 93a54ff

Browse files
Add support for additional language locales
1 parent 29640fc commit 93a54ff

17 files changed

+1170
-1
lines changed

api/app/Models/Forms/Form.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ class Form extends Model implements CachableAttributes
4141

4242
public const VISIBILITY = ['public', 'draft', 'closed'];
4343

44-
public const LANGUAGES = ['en', 'fr', 'hi', 'es', 'ar', 'zh', 'ja', 'bn', 'pt', 'ru', 'ur', 'pa', 'de', 'jv', 'ko', 'vi', 'te', 'mr', 'ta', 'tr'];
44+
public const LANGUAGES = ['en', 'fr', 'hi', 'es', 'ar', 'zh', 'ja', 'bn', 'pt', 'ru', 'ur', 'pa', 'de', 'jv', 'ko', 'vi', 'te', 'mr', 'ta', 'tr', 'sk', 'cs', 'eu', 'gl', 'ca', 'sv', 'pl'];
4545

4646
protected $fillable = [
4747
'workspace_id',

api/config/app.php

+7
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,13 @@
115115
'mr' => 'MR',
116116
'ta' => 'TA',
117117
'tr' => 'TR',
118+
'sk' => 'SK',
119+
'cs' => 'CS',
120+
'eu' => 'EU',
121+
'gl' => 'GL',
122+
'ca' => 'CA',
123+
'sv' => 'SV',
124+
'pl' => 'PL',
118125
],
119126

120127
/*

api/resources/lang/ca/validation.php

+121
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
<?php
2+
3+
return [
4+
'accepted' => 'El camp :attribute ha de ser acceptat.',
5+
'active_url' => 'El camp :attribute no és una URL vàlida.',
6+
'after' => 'El camp :attribute ha de ser una data posterior a :date.',
7+
'after_or_equal' => 'El camp :attribute ha de ser una data posterior o igual a :date.',
8+
'alpha' => 'El camp :attribute només pot contenir lletres.',
9+
'alpha_dash' => 'El camp :attribute només pot contenir lletres, números, guions i guions baixos.',
10+
'alpha_num' => 'El camp :attribute només pot contenir lletres i números.',
11+
'array' => 'El camp :attribute ha de ser un array.',
12+
'before' => 'El camp :attribute ha de ser una data anterior a :date.',
13+
'before_or_equal' => 'El camp :attribute ha de ser una data anterior o igual a :date.',
14+
'between' => [
15+
'numeric' => 'El camp :attribute ha d\'estar entre :min i :max.',
16+
'file' => 'El camp :attribute ha de tenir entre :min i :max kilobytes.',
17+
'string' => 'El camp :attribute ha de tenir entre :min i :max caràcters.',
18+
'array' => 'El camp :attribute ha de tenir entre :min i :max elements.',
19+
],
20+
'boolean' => 'El camp :attribute ha de ser verdader o fals.',
21+
'confirmed' => 'La confirmació del camp :attribute no coincideix.',
22+
'date' => 'El camp :attribute no és una data vàlida.',
23+
'date_equals' => 'El camp :attribute ha de ser una data igual a :date.',
24+
'date_format' => 'El camp :attribute no concorda amb el format :format.',
25+
'different' => 'Els camps :attribute i :other han de ser diferents.',
26+
'digits' => 'El camp :attribute ha de tenir :digits dígits.',
27+
'digits_between' => 'El camp :attribute ha de tenir entre :min i :max dígits.',
28+
'dimensions' => 'El camp :attribute té dimensions d\'imatge no vàlides.',
29+
'distinct' => 'El camp :attribute té un valor duplicat.',
30+
'email' => 'El camp :attribute ha de ser una adreça de correu electrònic vàlida.',
31+
'ends_with' => 'El camp :attribute ha d\'acabar amb un dels següents valors: :values',
32+
'exists' => 'El camp :attribute seleccionat no és vàlid.',
33+
'file' => 'El camp :attribute ha de ser un arxiu.',
34+
'filled' => 'El camp :attribute ha de tenir un valor.',
35+
'gt' => [
36+
'numeric' => 'El camp :attribute ha de ser més gran que :value.',
37+
'file' => 'El camp :attribute ha de ser més gran que :value kilobytes.',
38+
'string' => 'El camp :attribute ha de tenir més de :value caràcters.',
39+
'array' => 'El camp :attribute ha de tenir més de :value elements.',
40+
],
41+
'gte' => [
42+
'numeric' => 'El camp :attribute ha de ser més gran o igual que :value.',
43+
'file' => 'El camp :attribute ha de ser més gran o igual que :value kilobytes.',
44+
'string' => 'El camp :attribute ha de tenir :value caràcters o més.',
45+
'array' => 'El camp :attribute ha de tenir :value elements o més.',
46+
],
47+
'image' => 'El camp :attribute ha de ser una imatge.',
48+
'in' => 'El camp :attribute seleccionat no és vàlid.',
49+
'in_array' => 'El camp :attribute no existeix a :other.',
50+
'integer' => 'El camp :attribute ha de ser un nombre enter.',
51+
'ip' => 'El camp :attribute ha de ser una adreça IP vàlida.',
52+
'ipv4' => 'El camp :attribute ha de ser una adreça IPv4 vàlida.',
53+
'ipv6' => 'El camp :attribute ha de ser una adreça IPv6 vàlida.',
54+
'json' => 'El camp :attribute ha de ser una cadena JSON vàlida.',
55+
'lt' => [
56+
'numeric' => 'El camp :attribute ha de ser menor que :value.',
57+
'file' => 'El camp :attribute ha de ser menor que :value kilobytes.',
58+
'string' => 'El camp :attribute ha de tenir menys de :value caràcters.',
59+
'array' => 'El camp :attribute ha de tenir menys de :value elements.',
60+
],
61+
'lte' => [
62+
'numeric' => 'El camp :attribute ha de ser menor o igual que :value.',
63+
'file' => 'El camp :attribute ha de ser menor o igual que :value kilobytes.',
64+
'string' => 'El camp :attribute ha de tenir :value caràcters o menys.',
65+
'array' => 'El camp :attribute no pot tenir més de :value elements.',
66+
],
67+
'max' => [
68+
'numeric' => 'El camp :attribute no pot ser més gran que :max.',
69+
'file' => 'El camp :attribute no pot ser més gran que :max kilobytes.',
70+
'string' => 'El camp :attribute no pot tenir més de :max caràcters.',
71+
'array' => 'El camp :attribute no pot tenir més de :max elements.',
72+
],
73+
'mimes' => 'El camp :attribute ha de ser un arxiu de tipus: :values.',
74+
'mimetypes' => 'El camp :attribute ha de ser un arxiu de tipus: :values.',
75+
'min' => [
76+
'numeric' => 'El camp :attribute ha de ser almenys :min.',
77+
'file' => 'El camp :attribute ha de tenir almenys :min kilobytes.',
78+
'string' => 'El camp :attribute ha de tenir almenys :min caràcters.',
79+
'array' => 'El camp :attribute ha de tenir almenys :min elements.',
80+
],
81+
'multiple_of' => 'El camp :attribute ha de ser múltiple de :value',
82+
'not_in' => 'El camp :attribute seleccionat no és vàlid.',
83+
'not_regex' => 'El format del camp :attribute no és vàlid.',
84+
'numeric' => 'El camp :attribute ha de ser un número.',
85+
'password' => 'La contrasenya és incorrecta.',
86+
'present' => 'El camp :attribute ha d\'estar present.',
87+
'regex' => 'El format del camp :attribute no és vàlid.',
88+
'required' => 'El camp :attribute és obligatori.',
89+
'required_if' => 'El camp :attribute és obligatori quan :other és :value.',
90+
'required_unless' => 'El camp :attribute és obligatori a menys que :other estigui en :values.',
91+
'required_with' => 'El camp :attribute és obligatori quan :values està present.',
92+
'required_with_all' => 'El camp :attribute és obligatori quan :values estan presents.',
93+
'required_without' => 'El camp :attribute és obligatori quan :values no està present.',
94+
'required_without_all' => 'El camp :attribute és obligatori quan cap dels :values estan presents.',
95+
'same' => 'Els camps :attribute i :other han de coincidir.',
96+
'size' => [
97+
'numeric' => 'El camp :attribute ha de ser :size.',
98+
'file' => 'El camp :attribute ha de tenir :size kilobytes.',
99+
'string' => 'El camp :attribute ha de tenir :size caràcters.',
100+
'array' => 'El camp :attribute ha de contenir :size elements.',
101+
],
102+
'starts_with' => 'El camp :attribute ha de començar amb un dels següents valors: :values',
103+
'string' => 'El camp :attribute ha de ser una cadena de caràcters.',
104+
'timezone' => 'El camp :attribute ha de ser una zona horària vàlida.',
105+
'unique' => 'El valor del camp :attribute ja està en ús.',
106+
'uploaded' => 'El camp :attribute ha fallat en pujar.',
107+
'url' => 'El format del camp :attribute no és vàlid.',
108+
'uuid' => 'El camp :attribute ha de ser un UUID vàlid.',
109+
110+
'custom' => [
111+
'attribute-name' => [
112+
'rule-name' => 'custom-message',
113+
],
114+
],
115+
116+
'attributes' => [],
117+
118+
'invalid_json' => 'Entrada no vàlida. Corregeix-la i torna-ho a provar.',
119+
'invalid_captcha' => 'CAPTCHA no vàlid. Corregeix-lo i torna-ho a provar.',
120+
'complete_captcha' => 'Si us plau, completa el CAPTCHA.',
121+
];

api/resources/lang/cs/validation.php

+121
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
<?php
2+
3+
return [
4+
'accepted' => ':attribute musí být přijat.',
5+
'active_url' => ':attribute není platná URL adresa.',
6+
'after' => ':attribute musí být datum po :date.',
7+
'after_or_equal' => ':attribute musí být datum po nebo rovno :date.',
8+
'alpha' => ':attribute může obsahovat pouze písmena.',
9+
'alpha_dash' => ':attribute může obsahovat pouze písmena, číslice, pomlčky a podtržítka.',
10+
'alpha_num' => ':attribute může obsahovat pouze písmena a číslice.',
11+
'array' => ':attribute musí být pole.',
12+
'before' => ':attribute musí být datum před :date.',
13+
'before_or_equal' => ':attribute musí být datum před nebo rovno :date.',
14+
'between' => [
15+
'numeric' => ':attribute musí být mezi :min a :max.',
16+
'file' => ':attribute musí být mezi :min a :max kilobajty.',
17+
'string' => ':attribute musí být mezi :min a :max znaky.',
18+
'array' => ':attribute musí obsahovat :min až :max položek.',
19+
],
20+
'boolean' => ':attribute musí být true nebo false.',
21+
'confirmed' => 'Potvrzení :attribute se neshoduje.',
22+
'date' => ':attribute není platné datum.',
23+
'date_equals' => ':attribute musí být datum rovno :date.',
24+
'date_format' => ':attribute neodpovídá formátu :format.',
25+
'different' => ':attribute a :other se musí lišit.',
26+
'digits' => ':attribute musí být :digits číslic.',
27+
'digits_between' => ':attribute musí být mezi :min a :max číslicemi.',
28+
'dimensions' => ':attribute má neplatné rozměry obrázku.',
29+
'distinct' => ':attribute má duplicitní hodnotu.',
30+
'email' => ':attribute musí být platná e-mailová adresa.',
31+
'ends_with' => ':attribute musí končit jednou z následujících hodnot: :values',
32+
'exists' => 'Vybraný :attribute je neplatný.',
33+
'file' => ':attribute musí být soubor.',
34+
'filled' => ':attribute musí mít hodnotu.',
35+
'gt' => [
36+
'numeric' => ':attribute musí být větší než :value.',
37+
'file' => ':attribute musí být větší než :value kilobytů.',
38+
'string' => ':attribute musí být delší než :value znaků.',
39+
'array' => ':attribute musí obsahovat více než :value položek.',
40+
],
41+
'gte' => [
42+
'numeric' => ':attribute musí být větší nebo rovno :value.',
43+
'file' => ':attribute musí být větší nebo rovno :value kilobytů.',
44+
'string' => ':attribute musí být delší nebo rovno :value znaků.',
45+
'array' => ':attribute musí obsahovat :value nebo více položek.',
46+
],
47+
'image' => ':attribute musí být obrázek.',
48+
'in' => 'Vybraný :attribute je neplatný.',
49+
'in_array' => ':attribute neexistuje v :other.',
50+
'integer' => ':attribute musí být celé číslo.',
51+
'ip' => ':attribute musí být platná IP adresa.',
52+
'ipv4' => ':attribute musí být platná IPv4 adresa.',
53+
'ipv6' => ':attribute musí být platná IPv6 adresa.',
54+
'json' => ':attribute musí být platný JSON řetězec.',
55+
'lt' => [
56+
'numeric' => ':attribute musí být menší než :value.',
57+
'file' => ':attribute musí být menší než :value kilobytů.',
58+
'string' => ':attribute musí být kratší než :value znaků.',
59+
'array' => ':attribute musí obsahovat méně než :value položek.',
60+
],
61+
'lte' => [
62+
'numeric' => ':attribute musí být menší nebo rovno :value.',
63+
'file' => ':attribute musí být menší nebo rovno :value kilobytů.',
64+
'string' => ':attribute musí být kratší nebo rovno :value znaků.',
65+
'array' => ':attribute nesmí obsahovat více než :value položek.',
66+
],
67+
'max' => [
68+
'numeric' => ':attribute nesmí být větší než :max.',
69+
'file' => ':attribute nesmí být větší než :max kilobytů.',
70+
'string' => ':attribute nesmí být delší než :max znaků.',
71+
'array' => ':attribute nesmí obsahovat více než :max položek.',
72+
],
73+
'mimes' => ':attribute musí být soubor typu: :values.',
74+
'mimetypes' => ':attribute musí být soubor typu: :values.',
75+
'min' => [
76+
'numeric' => ':attribute musí být alespoň :min.',
77+
'file' => ':attribute musí být alespoň :min kilobytů.',
78+
'string' => ':attribute musí být alespoň :min znaků.',
79+
'array' => ':attribute musí obsahovat alespoň :min položek.',
80+
],
81+
'multiple_of' => ':attribute musí být násobkem :value',
82+
'not_in' => 'Vybraný :attribute je neplatný.',
83+
'not_regex' => 'Formát :attribute je neplatný.',
84+
'numeric' => ':attribute musí být číslo.',
85+
'password' => 'Heslo je nesprávné.',
86+
'present' => ':attribute musí být přítomen.',
87+
'regex' => 'Formát :attribute je neplatný.',
88+
'required' => ':attribute je povinné pole.',
89+
'required_if' => ':attribute je povinné, když :other je :value.',
90+
'required_unless' => ':attribute je povinné, pokud :other není v :values.',
91+
'required_with' => ':attribute je povinné, když je přítomno :values.',
92+
'required_with_all' => ':attribute je povinné, když jsou přítomny :values.',
93+
'required_without' => ':attribute je povinné, když není přítomno :values.',
94+
'required_without_all' => ':attribute je povinné, když není přítomna žádná z :values.',
95+
'same' => ':attribute a :other se musí shodovat.',
96+
'size' => [
97+
'numeric' => ':attribute musí být :size.',
98+
'file' => ':attribute musí mít :size kilobytů.',
99+
'string' => ':attribute musí mít :size znaků.',
100+
'array' => ':attribute musí obsahovat :size položek.',
101+
],
102+
'starts_with' => ':attribute musí začínat jednou z následujících hodnot: :values',
103+
'string' => ':attribute musí být řetězec.',
104+
'timezone' => ':attribute musí být platné časové pásmo.',
105+
'unique' => ':attribute již byl použit.',
106+
'uploaded' => 'Nahrávání :attribute se nezdařilo.',
107+
'url' => 'Formát :attribute je neplatný.',
108+
'uuid' => ':attribute musí být platné UUID.',
109+
110+
'custom' => [
111+
'attribute-name' => [
112+
'rule-name' => 'custom-message',
113+
],
114+
],
115+
116+
'attributes' => [],
117+
118+
'invalid_json' => 'Neplatný vstup. Opravte jej a zkuste to znovu.',
119+
'invalid_captcha' => 'Neplatná CAPTCHA. Opravte ji a zkuste to znovu.',
120+
'complete_captcha' => 'Prosím, vyplňte CAPTCHA.',
121+
];

0 commit comments

Comments
 (0)