Skip to content
This repository was archived by the owner on May 24, 2022. It is now read-only.

Fix #280: form field focus on input on component mount#323

Merged
amaury1093 merged 14 commits intomasterfrom
yj-focus-formfield
Jan 3, 2019
Merged

Fix #280: form field focus on input on component mount#323
amaury1093 merged 14 commits intomasterfrom
yj-focus-formfield

Conversation

@pmespresso
Copy link
Contributor

@pmespresso pmespresso commented Dec 25, 2018

#280

  • refactor fether-ui to be a class component to focus on input on componentDidMount()
  • refactor its props

@pmespresso pmespresso changed the title WIP: Form field focus on input on component mount Form field focus on input on component mount Dec 26, 2018
@pmespresso pmespresso changed the title Form field focus on input on component mount Fix #280: form field focus on input on component mount Dec 27, 2018
@amaury1093
Copy link
Collaborator

There's a prop called autoFocus, on <input>. I think adding that as prop in <FetherForm.Field> inside AccountName is enough?

Copy link
Collaborator

@amaury1093 amaury1093 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See my PR #328, I think there's an easier way to achieve this.

Copy link
Collaborator

@Tbaut Tbaut left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That works well!
Tested on JSON import and export.

Copy link
Collaborator

@amaury1093 amaury1093 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@amaury1093 amaury1093 merged commit a6aae1d into master Jan 3, 2019
@amaury1093 amaury1093 deleted the yj-focus-formfield branch January 3, 2019 10:26
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants