- Adds
countryCode
property.
- Adds Android namespace and other minor improvements.
- Upgrades to Android project (pre 1.12). Thank you @vergardan.
- Fixes Sint Marteen code (#20).
- Adds a method to get a
List
with all country's details (#16). Thank you @wizlif.
- Updates gradle to 5.4.1. (#15)
- Updates to null safety. Thank you @AntonyLeons.
- Adds new codes from Netherlands Antilles dissolution (#5). Thanks @comESK.
- Fixes dial code for Shqipëria.
- Sets default
Locale
to en-US whenever a device hasn't a default locale set (typically will happen only on iOS simulators).
- Updates assert to also validate that
countryCode
is notnull
.
- Added
localizedName
property toCountryDetails
. This allows you to display any country name base on aLocale
language. Must be set when doingCountryCodes.init(locale)
, defaults to device's language. - Updated Android
compileSdkVersion
to 29 andminSdkVersion
to 21; - Updated example app;
Exposes device Locale
(language and country code) instead of country only.
Updates dialCode()
to receive the [locale] optionally instead of explictly null
in order to retrieve the device's region dial code.
Replaces FutureOr<Locale>
with Locale
to make it explicitly synchronous when invoking getDeviceLocale()
Exposes device's Locale
through getDeviceLocale()
method.
Updates README
- Adds default
locale
from device region when not provided. For this to work, please callCountryCodes.init()
before invoking other methods. - Overall minor improvements.
Format
Adds license (MIT)
Initial release. Provides access to DialCodeFormatter
for TextFormField
s, alpha2Code
, dialCode
and name
.