Skip to content

Commit

Permalink
Merge pull request #14684 from qburst/14679--fix-placeholder-not-work…
Browse files Browse the repository at this point in the history
…ing-in-dropdown

fix: placeholder not working in dropdown
  • Loading branch information
cetincakiroglu authored Feb 1, 2024
2 parents 1ca44b6 + 4f8c4ff commit 85e36f4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/app/components/dropdown/dropdown.ts
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ export class DropdownItem {
<ng-container *ngIf="!selectedItemTemplate; else defaultPlaceholder">{{ label() === 'p-emptylabel' ? '&nbsp;' : label() }}</ng-container>
<ng-container *ngTemplateOutlet="selectedItemTemplate; context: { $implicit: selectedOption }"></ng-container>
<ng-template #defaultPlaceholder>
<span *ngIf="(modelValue() === undefined || modelValue === null) && (label() === placeholder || (label() && !placeholder))">{{ label() === 'p-emptylabel' ? '&nbsp;' : placeholder }}</span>
<span *ngIf="(modelValue() === undefined || modelValue() === null) && (label() === placeholder || (label() && !placeholder))">{{ label() === 'p-emptylabel' ? '&nbsp;' : placeholder }}</span>
</ng-template>
</span>
<input
Expand Down

0 comments on commit 85e36f4

Please sign in to comment.