Floating label with placeholder #11508
Labels
Type: Enhancement
Issue contains an enhancement related to a specific component. Additional functionality has been add
Milestone
I'm submitting a ...
Plunkr Case (Bug Reports)
https://stackblitz.com/edit/github-hfaqbo?file=src%2Fapp%2Fapp.component.ts
Current behavior
PrimeNG Input with floating label and placeholder cause overlapping text
Expected behavior
The placeholder should only show up as soon as the Input field got focus and the floating label moved upside the input field.
I accomplished this behaviour with a workaround by adjusting the CSS as you can see here:
https://stackblitz.com/edit/github-hfaqbo-iv54jr?file=src%2Fapp%2Fapp.component.css,src%2Fstyles.scss,src%2Fapp%2Fapp.component.ts
What is the motivation / use case for changing the behavior?
It's a common practice to use floating labels in combination with placeholders.
Browser:
Tested on Chrome/Edge/Firefox
Language: TypeScript 4.6.4
Node (for AoT issues):
node --version
= 16.4.2The text was updated successfully, but these errors were encountered: