-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Component: p-Dropdown placeholder/values not displayed #14695
Comments
Same issue, noticed after updating to 17.5 |
Same issue here, works as expected on 17.4.0 but it's broken on 17.5.0 |
Also doesn't work with reactive forms, when you set fromcontrol value it doesn't display it |
Same error. |
Surprise: it does not work in my project, but it does work in Stackblitz. |
same issue after upgrading to primeng version 17.5.0, |
Hello everyone, Example :
Ts:
|
yikes this is so bad |
Unfortunately, all of my inputs are already utilizing reactive form controls, so that fix doesn't work for me 😞 |
Hi, Thanks a lot for letting me know, the issue is fixed now. |
@cetincakiroglu The issue should be closed when the version is released, not when the commit is merged to master branch. |
Works now on the latest release. Thank you! |
Hi, this is no longer working in 17.7, should I raise a new issue? |
same issue facing in Primeng 17.18.9. using formControl/ngModel doesn't set value in dropdown textbox after selecting value. edit: solved by: #14094 |
Still broken in 17.18.11. though adding a placeholder "fixes" the problem |
The issue appears to be a problem where the bound input (ngModel) is an empty string (""). The placeholder will only display if the bound input is undefined. html<p-dropdown [(ngModel)]="dropdownString" [editable]="true" placeholder="Dropdown String"> componentexport class AutocompleteDropdownDemoComponent implements OnInit { selectedCountry: any; |
Describe the bug
When using p-dropdown, we've noticed that some of the dropdowns when a value is not selected end up with a short height with no placeholder value set. The weird thing is that not all p-dropdowns are affected -- it's quite random on how it is chosen.
Screen.Recording.2024-02-01.at.10.48.59.PM.mov
Screen.Recording.2024-02-01.at.10.56.22.PM.mov
Environment
I'm expecting the dropdown to either display the current value or the placeholder.
Reproducer
https://stackblitz.com/edit/github-lobmlu?file=src%2Fapp%2Fapp.component.html
Angular version
17.1.1
PrimeNG version
17.4.0 & 17.5.0
Build / Runtime
Angular CLI App
Language
TypeScript
Node version (for AoT issues node --version)
18.19.0
Browser(s)
Brave Version 1.62.153 Chromium: 121.0.6167.85
Steps to reproduce the behavior
No response
Expected behavior
I expected the dropdown to either show the placeholder value or the active value
The text was updated successfully, but these errors were encountered: