ngOfficeUIFabric / ng-officeuifabric

Office UI Fabric (https://github.com/OfficeDev/office-ui-fabric) implementation for Angular
http://ngOfficeUiFabric.com
MIT License
321 stars 68 forks source link

People Picker close event not firing #490

Closed vrndeva closed 7 years ago

vrndeva commented 7 years ago

This is the sample code: uif-person-close="removeClicked"

On my HTML: <uif-people-picker` uif-people="getUsers" ng-model="Test" uif-type="compact" uif-person-close="removeClicked" uif-selected-person-click="personClicked" data-ng-click="getSelectedGetUsersId(user)" uif-search-delay="300" placeholder="Search for people">

Showing {{asyncgetUsersResults.length}} results Search organization people

On my Controller: $scope.removeClicked = function () { alert('Remove Clicked'); }

Expected Behavior

Supposed to Call removeClicked event in the controller.

Actual Behavior

Nothing happens

vrndeva commented 7 years ago

The issue is when I add any person and click on Close after adding the person.

andrewconnell commented 7 years ago

Do you have a repo like a jsfiddle you can share to make it easier to see the issue @vrndeva ?

andrewconnell commented 7 years ago

This isn't an event we currently support... I think you're looking for the event removePersonFromSelectedPeople that we have on the scope. Refer to the source of the scope's interface for this: https://github.com/ngOfficeUIFabric/ng-officeuifabric/blob/master/src/components/peoplepicker/peoplePickerDirective.ts#L180-L220