5.1.0 (2024-02-06)
- style conflict with tailwindCss (88e3eb1)
5.0.0 (2023-08-23)
- update state on country change (266b5e9)
- add CountrySelect component (2df22e1)
- provide convenient event listeners instead of onChange (eee54b4)
- simplify component props (49390c7)
- package has been rewritten
- simplified event listeners
- value state is now controlled from inside the component
- no need to configure bundler for image imports anymore
- the select component is hidden if no country is provided
- a select is used instead of a button that opens a menu, this results in better accessibility
5.0.0-pre-release.1 (2023-08-23)
- update state on country change (266b5e9)
- add CountrySelect component (2df22e1)
- provide convenient event listeners instead of onChange (eee54b4)
- simplify component props (49390c7)
- package has been rewritten
- simplified event listeners
- value state is now controlled from inside the component
- no need to configure bundler for image imports anymore
- the select component is hidden if no country is provided
- a select is used instead of a button that opens a menu, this results in better accessibility
4.0.0 (2022-02-20)
- bump version to major (d2845df)
- I mistakenly added an 's' to BREAKING CHANGE in the last fix commit.
3.1.1 (2022-02-20)
- update dependencies (cc6d3b1)
3.1.0 (2021-02-15)
- typescript: make properties of countryDisplayNames optional (9d426ce)
- proptypes: accept only string values in countryDisplayNames (1dae4d6)
3.0.0 (2021-02-05)
- sprite: images are external to the js bundle (8aec39b)
- sprite: two versions are available, for normal and retina displays (438872b)
- sprite: the user is now responsible for processing any import/require to the sprite image using a bundler like webpack
2.2.0 (2021-01-29)
- menubutton: removed dropdown arrow from the menu button (f55f474)
- menubutton: the flag is now nested in an IconButton instead of a normal button (7293431)
2.1.0 (2021-01-02)
- added missing TextField's value prop (e45db21)
- menu: added support for basic keyboard navigation (2eddd72)
- menu: improved accessibility (a72d040)
- menu: items are less dense (18e47fa)
2.0.0 (2020-12-23)
onChange
now receives a data object instead of the change event (3cc83d6)
- The object passed to
onChange
has the following properties:formattedValue
: The formatted value for the selected country. Extracted from the input value.phoneNumber
: An instance of the PhoneNumber class, orundefined
if no valid phone number could be parsed from the input value.event
: The original event that triggered theonChange
handler.
1.0.1 (2020-12-23)
- added missing flags (6058858)
- props:
value
,error
andcountry
can now be passed to the component (3081b42) - props: country is now optional (28ba593)
-
props: the user is now responsible for controlling the input.
-
onChange
receives the original input change event but with the additional propertiescurrentTarget.formattedValue
, andphoneNumber
if a valid phone number is extracted from the input's value. -
onCountrySelect
receives a data object with the properties:country
: the selected country.formattedValue
: the formatted value for the selected country.phoneNumber
: a PhoneNumber instance if a valid phone number was extracted from the input's value.
-