-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
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
[TextField] value overlays floatingLabelText #3738
Comments
Thanks for the detailed report. Could you test your example with 0.15.0-alpha.2 and let us know if it still occurs? Not suggesting that it's been fixed, just that a lot has changed since 0.14.4!) |
I can reproduce it in 0.15.0-alpha.2 |
I'm experiencing the same issue with hintText instead of floatingLabelText using 0.150-alpha2 and altjs. Will post back if I discover anything useful. |
We have been porting the component on the next branch. We reimplemented it from the ground-up. While we haven't tested it, I think that the issue is most likely fixed on that branch. Hence, I'm closing it. |
Has this been fixed? I'm using [email protected] and still seeing this issue with text boxes. The example above is very close to what I'm doing. |
@rwlaschin Do you have a reproduction? |
+1 with @genyded - having long hintText wrapping and overlapping the floating label. |
I set up a create-react-app with a basic repro of the issue: https://github.com/ericf89/material-ui-label-bug When we want something like this: 😄 I actually found a work around while setting this up, and maybe a possible pointer to the real issue? Here's the example component: Notice that the text fields initial value is |
@ericf89 Thanks for the feedback! Here is the warning you have if using a native input:
I'm gonna try to improve the warning system on Material-UI side. |
Well, there is no warning with a textarea. I'm gonna fix the issue then :). |
I know that this may sounds strange ,but I had the same problem and initializing value of select component with an empty string instead of an undefined or null , solved the problem. |
Should this issue be reopened? I'm still experiencing it using 1.4.2 |
Problem Description
I am able to get the value of a TextField to overlay the floatingLabelText. I dug into it, and it looks like all the proper events are firing and the proper value for the css transition property is being passed into the html input field, where at that point React takes over. Nevertheless, I am not sure if this is a Material-UI issue, a React issue, or a Chrome issue.
I have created an example that mimics what my application is doing. I can only get this to happen when I use Redux. You will see in my example that I have a setTimeout in componentDidMount. Adding this, causes the display issue to occur. In my contrived example, removing this, or increasing the time significantly will cause the issue to not occur. In my actual application, I do not have a setTimeout like this.
All I can deduce at this point is that the usage of Redux (and perhaps other Fluxish tools) do something to mess with the timing of when React gets its state updates and in this case can't keep up?
I can only reproduce this in the Chrome version listed below. It is not an issue in FF 44.0. Others have reported problems in Chrome with autofill. This issue sounds similar, but the process to get it to occur does not involve autofill. If it is something to do with async and timing, then maybe they are related?
Versions
Example
The text was updated successfully, but these errors were encountered: