Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FormPhoneInput: Remove LinkedStateMixin #5554

Merged
merged 3 commits into from
May 24, 2016

Conversation

ockham
Copy link
Contributor

@ockham ockham commented May 24, 2016

This is obsolete, since FormPhoneInput doesn't use the this.linkState() method provided by the mixin, but instead handles the relavant logic itself in its countryValueLink and phoneValueLink objects -- very much like the textbook example, https://facebook.github.io/react/docs/two-way-binding-helpers.html#reactlink-without-linkedstatemixin

Also, LinkedStateMixin is deprecated as of React 15, so it's a good thing to remove it.

Additionally, this PR changes the initial value of the FormFields example' FormPhoneInput to a valid format (cf p6jOYE-sc-p2).

Code QA:

  • Verify that my above claim is true :-) (no reference to this.linkState() in FormPhoneInput)

To test:

ockham added 2 commits May 24, 2016 15:49
This is obsolete, since FormPhoneInput doesn't use the `this.linkState()` method provided by the mixin, but instead handles the relavant logic itself in its `countryValueLink` and `phoneValueLink` objects -- very much like the textbook example, https://facebook.github.io/react/docs/two-way-binding-helpers.html#reactlink-without-linkedstatemixin

Also, LinkedStateMixin is [deprecated](https://facebook.github.io/react/blog/2016/04/07/react-v15.html#new-deprecations-introduced-with-a-warning) as of React 15, so it's a good thing to remove it.
@ockham ockham added [Feature Group] Appearance & Themes Features related to the appearance of sites. [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. Components labels May 24, 2016
@ockham ockham self-assigned this May 24, 2016
@ockham ockham changed the title FormPhoneInput: Remove LinkedStateMixin FormPhoneInput: Remove LinkedStateMixin May 24, 2016
@ockham ockham removed the [Feature Group] Appearance & Themes Features related to the appearance of sites. label May 24, 2016
Hyphens aren't allowed by the field.
@ockham
Copy link
Contributor Author

ockham commented May 24, 2016

/cc @gwwar @aduth for review

@gwwar
Copy link
Contributor

gwwar commented May 24, 2016

👍 Verified that updating a phone number and phone validation still works. The example also now matches what we see on the phone update form.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants