I'm trying to remove multiselect label of selected items ,And replace it with static defaultLabel ,,
I tryed this one :
.p-multiselect-label {
visibility: collapse;
overflow: hidden;
white-space: nowrap;
}
It's remove any selected label but when the selected label is increased there is white space is increased too & i can't add defaultLabel whene there are any selectd item!
CodePudding user response:
You could override the selected items template:
<p-multiSelect #multiSelect defaultLabel="Select a city">
<ng-template pTemplate="selectedItems">
{{ multiSelect.defaultLabel }}
</ng-template>
</p-multiSelect>