ListBox: preventDefault on list items causes undesired behavior
Describe the bug
I have a ListBox with items that contain inputs:
After upgrading to PrimeNg 17, I noticed that those inputs on the listbox items become unusable.
Debugging the PrimeNg source code, I found that you added a
preventDefault to the listbox <ul> element on the (keydown) event.
- https://github.com/primefaces/primeng/blob/17.18.9/src/app/components/listbox/listbox.ts#L153
- https://github.com/primefaces/primeng/blob/17.18.9/src/app/components/listbox/listbox.ts#L1072
This is the root cause of my issue.
Environment
Windows, Chrome browser
Reproducer
https://stackblitz.com/edit/qtf5t1?file=src%2Fapp%2Flistbox-template-demo.html
Angular version
18.2.2
PrimeNG version
17.18.9
Build / Runtime
Angular CLI App
Language
TypeScript
Node version (for AoT issues node --version)
18.20.4
Browser(s)
Chrome 127
Steps to reproduce the behavior
Add inputs to ListBox items Try to type on those inputs (keydown events will be prevented)
Expected behavior
I should be able to type on inputs inside ListBox items
any updates?
I am also seeing this issue.
Any updates on this one?
@mertsincan
This is starting to be a problem. It's been broken for all of v18 and possibly v17. Is there a fix in the works for v19 anytime soon?
@cagataycivici
Would it be possible to assign this issue to someone else?