-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WinUI] [UIKit] CollectionView Items do not resize if the inner content changes. #13451
Comments
We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process. |
Verified this issue with 17.6 Preview (17.6 build 1539). Can repro on macOS with sample project. |
I believe I'm experiencing the same issue here. It seems to work with android. The link has a link to a reproduction repo. |
Is there some kind of workaround? |
Is there an update on this? I've seen that there is a fix incoming for a similar issue regarding the header here, but this is more related to the items. |
Is there a way to force the whole outer cell of the collection view to redraw via triggering invalidation as shown in the workaround that @Pughgramming pointed out? [Update] I did try invalidating the whole collection view using the following code:
But this did not seem to work either. Any help on how to fix this would be much appreciated. Thanks. |
In our case we're loading images asynchronously, so the cell resizes only once the images have been populated. The only workaround is to rotate the device so that the cell is redrawn. I've just updated to 8.0.60 but the issue remains. |
Yeah, I did the same thing for our application. and its still not working either. Here is a link to a repo that I am using to reproduce this problem on iOS, btw: https://github.com/Baraiboapex/Armory2/tree/master/Armory2 It would be great if this could be fixed so that we can release our application. |
Does anybody know of any libraries that can be used in place of this? I'm just wondering. Maybe this won't be such a show stopper if we can find something. |
Description
If you modify an existing CollectionView item on iOS, Catalyst, or WinUI the outer cell does not resize to reflect the new content. This should similar, if not the same, as #12118, but with a simple reproduction step (If that's the case, IMO, I would close that issue and redirect it to this one, since it's broader in scope).
For WinUI in my sample, the content doesn't directly overlap, rather there are gaps present between the cells as you add or remove them. With enough changes of the inner cells and their orders, you can cause the contents to overlap.
repro.mp4
Steps to Reproduce
Link to public reproduction project repository
https://github.com/drasticactions/MauiRepros/tree/main/MauiCollectionViewResize
Version with bug
7.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
iOS, Windows, macOS
Affected platform versions
All affected platform versions.
Did you find any workaround?
Somehow force the window or control to resize. On Windows/Mac you can resize the window, but that's not possible on iPhone.
For WinUI, ListView does not seem to suffer from this overlap issue, and it spaces its items correctly between them. On iOS/Catalyst the cells still don't resize, but adding a new one causes the previous cells to resize, "fixing" the issue.
Relevant log output
No response
The text was updated successfully, but these errors were encountered: