question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Input component placeholder and label collide

See original GitHub issue
  • Visit https://react-materialize.github.io/#/forms
  • Click the first name field and enter some text
  • Backspace and remove the text
  • Tab or click another field to make first name field lose focus
  • Notice that the placeholder and label are now rendered on top of each other (see screenshot) screen shot 2017-10-12 at 11 04 44 pm

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (1 by maintainers)

github_iconTop GitHub Comments

13reactions
alexgsummercommented, Oct 18, 2017

I found a potential solution that you guys might be able to use. From materialize-css documentation:

“If you are having trouble with the labels overlapping pre-filled content, Try adding class=“active” to the label.”

1reaction
chhailengcommented, Oct 4, 2018

I’m using MDB and I used $(inputselector).val(newvalue).trigger("change"); It solved the problem above 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to show both label and placeholder in material-ui TextField
In Material-UI (MUI) TextField, we can have both a label and a placeholder, but when the ...
Read more >
How to create fancy jumping text input labels - Bootcamp
Once the text input gains focus, the placeholder label jumps up on top and zooms out. It now serves as a reminder of...
Read more >
How to transition placeholder text into a label in React ...
Step 1: Put the label and input inside a container div · Empty state: Sitting in the middle of the input field, acting...
Read more >
On forms, is inline placeholder text better than a label outside ...
The major problem with inline placeholder text is after filling out a number of fields, it is difficult or sometimes impossible to determine ......
Read more >
How to Build a Sign Up Form with Floating Labels and ...
As you can see in the above image, when an input within the form gains focus, its label floats to the top and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found