Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CSS - Padding all around the dropdown list

Unable to have padding all around (top, bottom, left, right) a p-dropdown inside a p-table

Code...

<td>
    <p-dropdown name="country" [options]="countries" [(ngModel)]="applicant.country" placeholder="select country"
        (onChange)="getStatebyCountry(applicant.country,$event)" #country="ngModel" required>
    </p-dropdown>
</td>

Functionally its working fine, just its border is stick to column walls.

How to introduce padding all around a p-dropdown in p-table ?


1 Answers

It should be a matter of adding a padding css rule to style this element. Try adding code such as this to your stylesheet. I have added !important, since you may have other styles which could override this.

td {
  padding: 5px !important;
}
like image 89
Michael Dalton Avatar answered Dec 02 '25 17:12

Michael Dalton