Open mcalmus opened 1 year ago
Can you give more info about the use case you have in mind for this? I'm not sure this really makes sense for single selection, as selecting an item always implies all other options are unselected.
I would like to use a single change method for several components to audit changes. Once the change has fired there is no way to get the previous value.
Is this a regression?
The previous version in which this bug was not present was
No response
Description
When using a MatSelectionList with multiple select mode off, selecting an item deselects the previously-selected item. If listening to changes, the options property of MatSelectionListChange only has the newly-selected value, not the previously selected value. The documentation indicates it should contain "changed" items. The one that was deselected should therefore be included.
Reproduction
Steps to reproduce:
Expected Behavior
Change count after selecting a new item should increase by 2.
Actual Behavior
Change count only increases by one
Environment