dotnet / maui

.NET MAUI is the .NET Multi-platform App UI, a framework for building native device applications spanning mobile, tablet, and desktop.
https://dot.net/maui
MIT License
22.28k stars 1.76k forks source link

CollectionView can't scroll to the last item when TabBar and NavigationBar are visible #25474

Open lszl84 opened 1 month ago

lszl84 commented 1 month ago

Description

Here's a simple app with a tab bar, navigation bar and a basic collection view. The app is based on maui-samples.

As you can see in the video, you can't scroll to make the last item fully visible.

Code:

https://github.com/lszl84/maui-scroll-bug.git

Video:

https://github.com/user-attachments/assets/e9dd97be-352c-4735-a88a-408ff4bb790f

Steps to Reproduce

  1. Open attached BegginersTask project (https://github.com/lszl84/maui-scroll-bug.git) on an iPhone or simulator
  2. Add some item
  3. Tap on the item to go to the details screen
  4. try scrolling

Link to public reproduction project repository

https://github.com/lszl84/maui-scroll-bug.git

Version with bug

8.0.82 SR8.2

Is this a regression from previous behavior?

No, this is something new

Last version that worked well

No response

Affected platforms

iOS

Affected platform versions

iOS 17.6.1, iOS 18

Did you find any workaround?

wrapping the CollectionView in ScrollView seems to help, but that's a bad solution according to https://github.com/dotnet/maui/issues/23895

Relevant log output

No response

PureWeen commented 1 month ago

Might be fixed by https://github.com/dotnet/maui/pull/25315