Skip to content

Commit da180b6

Browse files
amrutha95Amrutha Srinivasan
andauthored
Fixed people picker search (#635)
Co-authored-by: Amrutha Srinivasan <[email protected]>
1 parent 1820ff7 commit da180b6

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

packages/mgt/src/components/mgt-people-picker/mgt-people-picker.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -668,7 +668,7 @@ export class MgtPeoplePicker extends MgtTemplatedComponent {
668668
this.fireCustomEvent('selectionChanged', this.selectedPeople);
669669
}
670670

671-
if (input) {
671+
if (input && !this.groupId) {
672672
people = [];
673673
if (this.type === PersonType.person || this.type === PersonType.any) {
674674
try {
@@ -703,6 +703,8 @@ export class MgtPeoplePicker extends MgtTemplatedComponent {
703703
// nop
704704
}
705705
}
706+
} else if (input && this.groupId) {
707+
people = this._groupPeople;
706708
}
707709
}
708710

@@ -843,6 +845,8 @@ export class MgtPeoplePicker extends MgtTemplatedComponent {
843845
highlight = displayName.slice(highlightLocation, highlightLocation + userInputLength);
844846
last = displayName.slice(highlightLocation + userInputLength, displayName.length);
845847
}
848+
} else {
849+
first = displayName;
846850
}
847851

848852
return html`

0 commit comments

Comments
 (0)