Skip to content
This repository has been archived by the owner on Sep 3, 2023. It is now read-only.

Set hint on TextInputLayout #1962

Merged
merged 1 commit into from
Mar 12, 2020
Merged

Set hint on TextInputLayout #1962

merged 1 commit into from
Mar 12, 2020

Conversation

mwajeeh
Copy link
Contributor

@mwajeeh mwajeeh commented Mar 11, 2020

Set hint on TextInputLayout instead of EditText so that it animates properly when you start typing.

From documentation:

  • The hint should be set on the TextInputLayout, rather than the EditText. If a hint is specified
  • on the child EditText in XML, the TextInputLayout might still work correctly; TextInputLayout
  • will use the EditText's hint as its floating label. However, future calls to modify the hint will
  • not update TextInputLayout's hint.

Check the demo here: https://material.io/components/text-fields/

Set hint on TextInputLayout instead of EditText so that it animates properly when you start typing.

From documentation:
* The hint should be set on the TextInputLayout, rather than the EditText. If a hint is specified
 * on the child EditText in XML, the TextInputLayout might still work correctly; TextInputLayout
 * will use the EditText's hint as its floating label. However, future calls to modify the hint will
 * not update TextInputLayout's hint.
@afollestad afollestad merged commit be74a35 into afollestad:master Mar 12, 2020
@daniel-stoneuk
Copy link

Hi, when do you think a release will be created with this commit?

afollestad pushed a commit that referenced this pull request Feb 20, 2021
Set hint on TextInputLayout instead of EditText so that it animates properly when you start typing.

From documentation:
* The hint should be set on the TextInputLayout, rather than the EditText. If a hint is specified
 * on the child EditText in XML, the TextInputLayout might still work correctly; TextInputLayout
 * will use the EditText's hint as its floating label. However, future calls to modify the hint will
 * not update TextInputLayout's hint.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants