Skip to content

Commit d2add09

Browse files
authored
fix: show max while picking multiple groups (#3289)
1 parent 3695be9 commit d2add09

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

packages/mgt-components/src/graph/graph.groups.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,8 @@ export const findGroups = async (
149149

150150
filterQuery = filterQuery ? `${filterQuery} and ` : '';
151151
for (const filter of filterGroups) {
152-
batch.get(filter, `/groups?$filter=${filterQuery + filter}`, validGroupQueryScopes);
152+
const fullUrl = `/groups?$filter=${filterQuery + filter}&$top=${top}`;
153+
batch.get(filter, fullUrl, validGroupQueryScopes);
153154
}
154155

155156
try {

stories/components/peoplePicker/peoplePicker.properties.stories.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,11 @@ export const pickMultipleGroups = () => html`
187187
<!-- group-type can be "any", "unified", "security", "mailenabledsecurity", "distribution" -->
188188
`;
189189

190+
export const pickMultipleGroupsShowMax = () => html`
191+
<mgt-people-picker type="group" group-type="unified,security,mailenabledsecurity" show-max="3"></mgt-people-picker>
192+
<!-- group-type can be "any", "unified", "security", "mailenabledsecurity", "distribution" -->
193+
`;
194+
190195
export const pickPeople = () => html`
191196
<mgt-people-picker type="person"></mgt-people-picker>
192197
<!-- type can be "any", "person", "group" -->

0 commit comments

Comments
 (0)