unoplatform / uno

Build Mobile, Desktop and WebAssembly apps with C# and XAML. Today. Open source and professionally supported.
https://platform.uno
Apache License 2.0
8.76k stars 706 forks source link

[CalendarView] Significant Gap Appears in Calendar When when reaching end of calendar #17635

Open jhanvi03 opened 1 month ago

jhanvi03 commented 1 month ago

Current behavior

After selecting a day at the end of the calendar and switching back to the year view, a large gap is present, disrupting the user experience and causing visual inconsistencies.

https://github.com/user-attachments/assets/250d6ff2-c146-4643-b912-27e8a7d80a7b

Screenshot 2024-07-22 at 11 39 45 AM

Expected behavior

The calendar should smoothly transition between month and year views without any large gaps or layout issues.

How to reproduce it (as minimally and precisely as possible)

Steps to Reproduce:

  1. Open Gallery in any of the web browser
  2. Navigate to Menu -> UI Components -> CalenderView
  3. In the calendar reach to end of years
  4. Select a day
  5. Go back to years
  6. Observe the huge blank gap.

Workaround

No response

Works on UWP/WinUI

None

Environment

No response

NuGet package version(s)

No response

Affected platforms

WebAssembly

IDE

No response

IDE version

No response

Relevant plugins

No response

Anything else we need to know?

No response

rajamatt commented 1 month ago

Findings so far: happening on Skia & Wasm, looks like we need to add some logic surrounding BringDisplayDateintoView(), more precisely the ScrollToDate(date) method should probably take in a date that would prevent this behavior from occuring altogether.