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
21.95k stars 1.7k forks source link

[MAUI] I9_Srolling_Snap points_ SnapPointsAlignment set to any value and the Items no change in position #23376

Open ninachen03 opened 1 month ago

ninachen03 commented 1 month ago

Description

Affected case: I9: Snap points.

Steps to Reproduce

  1. Deploy https://devdiv.visualstudio.com/Pkgs/_git/VS.TestAssets.Xaml?path=/Assets/Projects/ManualMauiTests to Windows.
  2. Navigate to 'I CollectionView' ->'I9 Srolling '
  3. Open Snap points page
  4. Set SnapPointsType property to Mandatory, or MandatorySingle and SnapPointsAlignment property set to any.

Actual Behavior: Items no change in position Snap

Link to public reproduction project repository

https://devdiv.visualstudio.com/Pkgs/_git/VS.TestAssets.Xaml?path=/Assets/Projects/ManualMauiTests

Version with bug

Microsoft.Maui.Controls 8.0.70-ci.net8.24325.2

Is this a regression from previous behavior?

Not a regression, The issue also repro on 8.0.61& 8.0.3

Affected platforms

iOS, Android, Windows, macOS

github-actions[bot] commented 1 month ago

Hi I'm an AI powered bot that finds similar issues based off the issue title.

Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one and thumbs upping the other issue to help us prioritize it. Thank you!

Open similar issues:

Closed similar issues:

Note: You can give me feedback by thumbs upping or thumbs downing this comment.

ninachen03 commented 1 month ago

@PureWeen As for the SnapPointsAlignment We are unable to clearly see the difference between Start/Center/End. So we change the height of Image from HeightRequest="60" to "70" (.. Views\SnapPoints\VerticalListSnapPointsPage.xaml, line 57.) Then, the result is more obvious. Image before resizing 60 Image after resizing 70 So, in addition to Windows platform having an issue, this property works fine on other platforms.

As for the SnapPointsType: After selecting MandatorySingle, the Android and iOS result are not stable, sometimes we would scroll through multiple items instead of only scrolls one item at a time. We have also tried on the physical mobile device, and the result is as expected, there is no instability.

On Windows and Mac this feature does not work, we can't scroll by dragging and dropping the mouse, can only scroll with the mouse scroll, which can scroll through multiple items. Is it because the test should be execute on a touch device?