-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Description
Description
This sub-issue tracks a platform-specific problem on iOS when IsGrouped is set to True and the ItemsSource is set to ObservableCollection. The GroupHeaderTemplate and GroupFooterTemplate are incorrectly applied to every individual item in the collection.
This issue was previously not identifiable on iOS because of #28509 where GroupHeaderTemplate and GroupFooterTemplate were not visible. After fixing this #28509, this issue will occur on iOS also.
Steps to Reproduce
- Run the attached sample IsGroupedSample.2.zip
- Select ItemSource= Observablecollection or List , IsGrouped= true, Select GroupHeaderTemplate and GroupFooterTemplate .
- Observe the behavior of the CollectionView.
Expected Behaviour:
-
The GroupHeaderTemplate and GroupFooterTemplate should only be applied when the ItemsSource is a grouped collection.
-
When using a flat ObservableCollection, only the individual items should be displayed, without any group headers or footers.
-
The GroupHeaderTemplate and GroupFooterTemplate should not be applied to individual items in the ObservableCollection.
Actual Behaviour:
The GroupHeaderTemplate and GroupFooterTemplate are incorrectly applied to each item in the flat ObservableCollection, resulting in multiple headers and footers—one for every item—even though the data is not grouped.
Link to public reproduction project repository
No response
Version with bug
9.0.60 SR6
Is this a regression from previous behavior?
Not sure, did not test other versions
Last version that worked well
No response
Affected platforms
iOS, macOS
Affected platform versions
No response
Did you find any workaround?
No response