Skip to content

Commit

Permalink
Add Korean (#245)
Browse files Browse the repository at this point in the history
* Add Korean

* Updated Readme.md & CHANGELOG.md & Version 9.2.5

* Pub upgrade flutter_country_selector to v1.0.11
  • Loading branch information
Oh-Kang94 committed May 31, 2024
1 parent ec7f403 commit 5b11e92
Show file tree
Hide file tree
Showing 5 changed files with 46 additions and 3 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
## [9.2.5]
- added Korean localization messages

## [9.2.4]
- upgrade metadata
- Do not preload flags by default anymore. Use [PhoneFormField.preloadFlags()] to preload flags
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,7 @@ This package uses the `flutter_country_selector` package under the hood, which e
- hi
- hu
- it
- ko
- nb
- nl
- pt
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import 'phone_field_localization_impl_fr.dart';
import 'phone_field_localization_impl_hi.dart';
import 'phone_field_localization_impl_hu.dart';
import 'phone_field_localization_impl_it.dart';
import 'phone_field_localization_impl_ko.dart';
import 'phone_field_localization_impl_ku.dart';
import 'phone_field_localization_impl_nb.dart';
import 'phone_field_localization_impl_nl.dart';
Expand Down Expand Up @@ -123,6 +124,7 @@ abstract class PhoneFieldLocalizationImpl {
Locale('hi'),
Locale('hu'),
Locale('it'),
Locale('ko'),
Locale('ku'),
Locale('nb'),
Locale('nl'),
Expand Down Expand Up @@ -207,6 +209,7 @@ class _PhoneFieldLocalizationImplDelegate
'hi',
'hu',
'it',
'ko',
'ku',
'nb',
'nl',
Expand All @@ -216,7 +219,7 @@ class _PhoneFieldLocalizationImplDelegate
'tr',
'uk',
'uz',
'zh'
'zh',
].contains(locale.languageCode);

@override
Expand Down Expand Up @@ -248,6 +251,8 @@ PhoneFieldLocalizationImpl lookupPhoneFieldLocalizationImpl(Locale locale) {
return PhoneFieldLocalizationImplHu();
case 'it':
return PhoneFieldLocalizationImplIt();
case 'ko':
return PhoneFieldLocalizationImplKo();
case 'ku':
return PhoneFieldLocalizationImplKu();
case 'nb':
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import 'phone_field_localization_impl.dart';

/// The translations for Italian (`ko`).
class PhoneFieldLocalizationImplKo extends PhoneFieldLocalizationImpl {
PhoneFieldLocalizationImplKo([super.locale = 'ko']);

@override
String get invalidPhoneNumber => '올바른 번호가 아닙니다.';

@override
String get invalidCountry => '올바른 국가가 아닙니다.';

@override
String get invalidMobilePhoneNumber => '올바른 핸드폰 번호가 아닙니다.';

@override
String get invalidFixedLinePhoneNumber => '올바른 전화 번호가 아닙니다.';

@override
String get requiredPhoneNumber => '전화번호를 입력해 주세요';

@override
String selectACountrySemanticLabel(String countryName, String dialCode) {
return '국가를 선택해주세요. 현재 국가는: $countryName $dialCode';
}

@override
String get phoneNumber => '핸드폰 번호';

@override
String currentValueSemanticLabel(String currentValue) {
return '현재 값: $currentValue';
}
}
4 changes: 2 additions & 2 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: phone_form_field
description: Flutter phone input integrated with flutter internationalization
version: 9.2.4
version: 9.2.5
homepage: https://github.com/cedvdb/phone_form_field

environment:
Expand All @@ -14,7 +14,7 @@ dependencies:
sdk: flutter
intl: ">=0.18.0 <=1.0.0"

flutter_country_selector: ^1.0.9
flutter_country_selector: ^1.0.11
circle_flags: ^5.0.0
phone_numbers_parser: ^8.2.2

Expand Down

0 comments on commit 5b11e92

Please sign in to comment.