Skip to content

Commit a089944

Browse files
Merge pull request #31 from ipcjs/perf/zh-arb
simplify arb files and correct `intl_zh.arb`
2 parents 2687089 + b114800 commit a089944

36 files changed

+85
-2973
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ Create one ARB file inside the `lib/l10n` folder for each of the locales you nee
200200

201201
2. Translate the error messages
202202

203-
Duplicate the contents of `intl_en.arb` (or any other ARB file) into your newly created ARB file, then translate the error messages by overwriting the default messages.
203+
Duplicate the contents of `intl_zh.arb` (or any other ARB file) into your newly created ARB file, then translate the error messages by overwriting the default messages.
204204

205205
3. Generate localization code
206206

l10n.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
# https://docs.flutter.dev/development/accessibility-and-localization/internationalization#adding-your-own-localized-messages
2+
# https://docs.google.com/document/d/10e0saTfAv32OZLRmONy866vnaw0I2jwL8zukykpgWBc
23
arb-dir: lib/l10n
34
template-arb-file: intl_en.arb
45
synthetic-package: false
56
output-dir: lib/localization/intl
67
output-localization-file: messages.dart
7-
output-class: FormBuilderLocalizationsImpl
8+
output-class: FormBuilderLocalizationsImpl
9+
#untranslated-messages-file: build/untranslated-messages.txt

lib/l10n/intl_ar.arb

Lines changed: 1 addition & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -1,106 +1,18 @@
11
{
2-
"@@last_modified": "2022-03-15T18:27:00.938366",
32
"@@locale": "ar",
43
"requiredErrorText": "هذا الحقل يجب ملؤه.",
5-
"@requiredErrorText": {
6-
"description": "Error Text for required validator",
7-
"type": "text",
8-
"placeholders": {}
9-
},
104
"equalErrorText": "يجب أن تكون القيمة المدخلة مساوية لـ {value}.",
11-
"@equalErrorText": {
12-
"description": "Error Text for equal validator",
13-
"type": "text",
14-
"placeholders": {
15-
"value": {}
16-
}
17-
},
185
"notEqualErrorText": "يجب أن لا تكون القيمة المدخلة مساوية لـ {value}.",
19-
"@notEqualErrorText": {
20-
"description": "Error Text for not-equal validator",
21-
"type": "text",
22-
"placeholders": {
23-
"value": {}
24-
}
25-
},
266
"minErrorText": "يجب أن لا تقل القيمة المدخلة عن {min}.",
27-
"@minErrorText": {
28-
"description": "Error Text for required field",
29-
"type": "text",
30-
"placeholders": {
31-
"min": {}
32-
}
33-
},
347
"minLengthErrorText": "يجب أن لا يقل طول القيمة المدخلة عن {minLength}.",
35-
"@minLengthErrorText": {
36-
"description": "Error Text for minLength validator",
37-
"type": "text",
38-
"placeholders": {
39-
"minLength": {}
40-
}
41-
},
428
"maxErrorText": "يجب أن لا تزيد القيمة المدخلة عن {max}.",
43-
"@maxErrorText": {
44-
"description": "Error Text for max validator",
45-
"type": "text",
46-
"placeholders": {
47-
"max": {}
48-
}
49-
},
509
"maxLengthErrorText": "يجب أن لا يزيد طول القيمة المدخلة عن {maxLength}.",
51-
"@maxLengthErrorText": {
52-
"description": "Error Text for required field",
53-
"type": "text",
54-
"placeholders": {
55-
"maxLength": {}
56-
}
57-
},
5810
"emailErrorText": "هذا الحقل يتطلب عنوان بريد إلكتروني صالح.",
59-
"@emailErrorText": {
60-
"description": "Error Text for email field",
61-
"type": "text",
62-
"placeholders": {}
63-
},
6411
"urlErrorText": "هذا الحقل يتطلب عنوان URL صالح.",
65-
"@urlErrorText": {
66-
"description": "Error Text for URL field",
67-
"type": "text",
68-
"placeholders": {}
69-
},
7012
"matchErrorText": "القيمة المدخلة لا تطابق الصيغة المطلوبة.",
71-
"@matchErrorText": {
72-
"description": "Error Text for pattern field",
73-
"type": "text",
74-
"placeholders": {}
75-
},
7613
"numericErrorText": "القيمة المدخلة ليست رقما.",
77-
"@numericErrorText": {
78-
"description": "Error Text for numeric field",
79-
"type": "text",
80-
"placeholders": {}
81-
},
8214
"integerErrorText": "القيمة المدخلة ليست رقما صحيحا.",
83-
"@integerErrorText": {
84-
"description": "Error Text for integer validator",
85-
"type": "text",
86-
"placeholders": {}
87-
},
8815
"creditCardErrorText": "القيمة المدخلة لا تصلح كرقم بطاقة إئتمانية.",
89-
"@creditCardErrorText": {
90-
"description": "Error Text for credit card field",
91-
"type": "text",
92-
"placeholders": {}
93-
},
9416
"ipErrorText": "هذا الحقل يتطلب عنوان IP صالح.",
95-
"@ipErrorText": {
96-
"description": "Error Text for IP address field",
97-
"type": "text",
98-
"placeholders": {}
99-
},
100-
"dateStringErrorText": "هذا الحقل يتطلب تاريخا صالحا.",
101-
"@dateStringErrorText": {
102-
"description": "Error Text for date string field",
103-
"type": "text",
104-
"placeholders": {}
105-
}
17+
"dateStringErrorText": "هذا الحقل يتطلب تاريخا صالحا."
10618
}

lib/l10n/intl_bn.arb

Lines changed: 2 additions & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -1,106 +1,18 @@
11
{
2-
"@@last_modified": "2022-04-04T10:09:54.938366",
3-
"@@locale": "bn",
2+
"@@locale": "bn",
43
"requiredErrorText": "খালি রাখা যাবে না।",
5-
"@requiredErrorText": {
6-
"description": "Error Text for required validator",
7-
"type": "text",
8-
"placeholders": {}
9-
},
104
"equalErrorText": "মান {value} সমান হতে হবে।",
11-
"@equalErrorText": {
12-
"description": "Error Text for equal validator",
13-
"type": "text",
14-
"placeholders": {
15-
"value": {}
16-
}
17-
},
185
"notEqualErrorText": "মান {value} এর সমান হওয়া উচিত নয়।",
19-
"@notEqualErrorText": {
20-
"description": "Error Text for not-equal validator",
21-
"type": "text",
22-
"placeholders": {
23-
"value": {}
24-
}
25-
},
266
"minErrorText": "মান অবশ্যই {min} এর থেকে বেশি বা সমান হতে হবে।",
27-
"@minErrorText": {
28-
"description": "Error Text for required field",
29-
"type": "text",
30-
"placeholders": {
31-
"min": {}
32-
}
33-
},
347
"minLengthErrorText": "মান অবশ্যই {minLength} এর চেয়ে বেশি বা সমান সংখ্যা হতে হবে।",
35-
"@minLengthErrorText": {
36-
"description": "Error Text for minLength validator",
37-
"type": "text",
38-
"placeholders": {
39-
"minLength": {}
40-
}
41-
},
428
"maxErrorText": "মান অবশ্যই {max} এর কম বা সমান হতে হবে।",
43-
"@maxErrorText": {
44-
"description": "Error Text for max validator",
45-
"type": "text",
46-
"placeholders": {
47-
"max": {}
48-
}
49-
},
509
"maxLengthErrorText": "মান অবশ্যই {maxLength} এর থেকে কম বা সমান সংখ্যা হতে হবে।",
51-
"@maxLengthErrorText": {
52-
"description": "Error Text for required field",
53-
"type": "text",
54-
"placeholders": {
55-
"maxLength": {}
56-
}
57-
},
5810
"emailErrorText": "একটি বৈধ ইমেল আইডি প্রয়োজন।",
59-
"@emailErrorText": {
60-
"description": "Error Text for email validator",
61-
"type": "text",
62-
"placeholders": {}
63-
},
6411
"urlErrorText": "একটি বৈধ ওয়েব এড্রেস প্রয়োজন।",
65-
"@urlErrorText": {
66-
"description": "Error Text for URL validator",
67-
"type": "text",
68-
"placeholders": {}
69-
},
7012
"matchErrorText": "মান প্যাটার্নের সাথে মেলে না।",
71-
"@matchErrorText": {
72-
"description": "Error Text for pattern validator",
73-
"type": "text",
74-
"placeholders": {}
75-
},
7613
"numericErrorText": "মান অবশ্যই সংখ্যায় হতে হবে।",
77-
"@numericErrorText": {
78-
"description": "Error Text for numeric validator",
79-
"type": "text",
80-
"placeholders": {}
81-
},
8214
"integerErrorText": "মান অবশ্যই একটি পূর্ণসংখ্যা হতে হবে।",
83-
"@integerErrorText": {
84-
"description": "Error Text for integer validator",
85-
"type": "text",
86-
"placeholders": {}
87-
},
8815
"creditCardErrorText": "বৈধ ক্রেডিট কার্ড নম্বর প্রয়োজন।",
89-
"@creditCardErrorText": {
90-
"description": "Error Text for credit card validator",
91-
"type": "text",
92-
"placeholders": {}
93-
},
9416
"ipErrorText": "একটি বৈধ আইপি এড্রেস প্রয়োজন।",
95-
"@ipErrorText": {
96-
"description": "Error Text for IP address validator",
97-
"type": "text",
98-
"placeholders": {}
99-
},
100-
"dateStringErrorText": "একটি বৈধ তারিখ প্রয়োজন।",
101-
"@dateStringErrorText": {
102-
"description": "Error Text for date string validator",
103-
"type": "text",
104-
"placeholders": {}
105-
}
17+
"dateStringErrorText": "একটি বৈধ তারিখ প্রয়োজন।"
10618
}

lib/l10n/intl_bs.arb

Lines changed: 1 addition & 96 deletions
Original file line numberDiff line numberDiff line change
@@ -1,114 +1,19 @@
11
{
2-
"@@last_modified": "2020-11-13T10:38:27.938366",
32
"@@locale": "bs",
43
"requiredErrorText": "Ovo polje ne smije biti prazno.",
5-
"@requiredErrorText": {
6-
"description": "Error Text for required validator",
7-
"type": "text",
8-
"placeholders": {}
9-
},
104
"equalErrorText": "Vrijednost mora biti jednaka {value}.",
11-
"@equalErrorText": {
12-
"description": "Error Text for equal validator",
13-
"type": "text",
14-
"placeholders": {
15-
"value": {}
16-
}
17-
},
185
"notEqualErrorText": "Vrijednost ne smije biti jednaka {value}.",
19-
"@notEqualErrorText": {
20-
"description": "Error Text for not-equal validator",
21-
"type": "text",
22-
"placeholders": {
23-
"value": {}
24-
}
25-
},
266
"minErrorText": "Vrijednost mora biti veća ili jednaka {min}.",
27-
"@minErrorText": {
28-
"description": "Error Text for required field",
29-
"type": "text",
30-
"placeholders": {
31-
"min": {}
32-
}
33-
},
347
"minLengthErrorText": "Vrijednost mora biti duža ili jednaka {minLength} znakova.",
35-
"@minLengthErrorText": {
36-
"description": "Error Text for minLength validator",
37-
"type": "text",
38-
"placeholders": {
39-
"minLength": {}
40-
}
41-
},
428
"maxErrorText": "Vrijednost mora biti manja ili jednaka {max}",
43-
"@maxErrorText": {
44-
"description": "Error Text for max validator",
45-
"type": "text",
46-
"placeholders": {
47-
"max": {}
48-
}
49-
},
509
"maxLengthErrorText": "Vrijednost mora biti kraća ili jednaka {maxLength} znakova.",
51-
"@maxLengthErrorText": {
52-
"description": "Error Text for required field",
53-
"type": "text",
54-
"placeholders": {
55-
"maxLength": {}
56-
}
57-
},
5810
"equalLengthErrorText": "Vrijednost mora biti duga {length} znakova.",
59-
"@equalLengthErrorText": {
60-
"description": "Error Text for required field",
61-
"type": "text",
62-
"placeholders": {
63-
"length": {}
64-
}
65-
},
6611
"emailErrorText": "Unesite validnu e-mail adresu.",
67-
"@emailErrorText": {
68-
"description": "Error Text for email validator",
69-
"type": "text",
70-
"placeholders": {}
71-
},
7212
"urlErrorText": "Unesite validnu URL adresu.",
73-
"@urlErrorText": {
74-
"description": "Error Text for URL validator",
75-
"type": "text",
76-
"placeholders": {}
77-
},
7813
"matchErrorText": "Vrijednost ne odgovara uzorku.",
79-
"@matchErrorText": {
80-
"description": "Error Text for pattern validator",
81-
"type": "text",
82-
"placeholders": {}
83-
},
8414
"numericErrorText": "Vrijednost mora biti brojčana.",
85-
"@numericErrorText": {
86-
"description": "Error Text for numeric validator",
87-
"type": "text",
88-
"placeholders": {}
89-
},
9015
"integerErrorText": "Vrijednost mora biti cijeli broj.",
91-
"@integerErrorText": {
92-
"description": "Error Text for integer validator",
93-
"type": "text",
94-
"placeholders": {}
95-
},
9616
"creditCardErrorText": "Unesite validan broj kreditne kartice.",
97-
"@creditCardErrorText": {
98-
"description": "Error Text for credit card validator",
99-
"type": "text",
100-
"placeholders": {}
101-
},
10217
"ipErrorText": "Unesite validnu IP adresu.",
103-
"@ipErrorText": {
104-
"description": "Error Text for IP address validator",
105-
"type": "text",
106-
"placeholders": {}
107-
},
108-
"dateStringErrorText": "Unesite validan datum.",
109-
"@dateStringErrorText": {
110-
"description": "Error Text for date string validator",
111-
"type": "text",
112-
"placeholders": {}
113-
}
18+
"dateStringErrorText": "Unesite validan datum."
11419
}

0 commit comments

Comments
 (0)