How to set the primeNG dropdown width to stretch 100% inside its container?
It seems to have fixed element.style and the .ui-dropdown{ width: 100% } override does not work.
How to set the primeNG dropdown width to stretch 100% inside its container?
It seems to have fixed element.style and the .ui-dropdown{ width: 100% } override does not work.
"autoWidth" did not work for me, I just did this in my CSS:
You should be editing a class in a primeng.min.css file as below,
then Dropdownlist should take size of biggest option.
You should be writing in a css file using the mentioned class as below,
Set it to be
!important
LIVE DEMO
In my case I used autoWidth = false and set style attrribute like below
I found to use the Responsive approach and apply .ui-fluid style with Grid CSS at container while p-dropdown should have the [autoWidth]="false" attribute.
Example: