microsoft / microsoft/microsoft-ui-xaml
CalendarView Selection becomes unresponsive when added as Flyout.Content
- Dominant language
- C++
- Stars
- 8.4k
- Forks
- 942
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 105
Description
### Describe the bug
When the `CalendarView` control is added as the content of a `Flyout`, its cell selection becomes unresponsive after performing a specific sequence of actions multiple times. The issue occurs when the `Flyout` is closed and reopened, and the user navigates through different calendar views using the header.
For example, opening the `Flyout` via a button click, navigating from `Month` view to `Year`, then `Decade`, and back to `Month` works correctly the first time. After closing and reopening the Flyout (displaying `Month` view), if the user navigates to the `Year` view, cells become unresponsive but navigating to `Decade` view restores cell responsiveness. The cells in the view which is first navigated when the `Flyout` is closed and then opened are unresponsive.
Sample: [CalendarIssue.zip](https://github.com/user-attachments/files/18319468/CalendarIssue.zip)
_**Note:** This issue also occurs in `CalendarDatePicker`._
### Steps to reproduce the bug
1. Open and run the attached sample.
2. Click the `Open Custom Flyout` button to open the Flyout containing the `CalendarView`.
3. Navigate from `Month` view to `Year`, then `Decade`, and back to `Month`.
4. Click outside or `Close Flyout` button to close the Flyout.
5. Reopen Flyout (which now displays the `Month` view).
6. Navigate to `Year` view and hover over the cells—notice that the cells are unresponsive.
7. Navigate to `Decade` view and hover over the cells—notice that the cells are now responsive.
### Expected behavior
All cells in the `CalendarView` across all views (`Month`, `Year`, and `Decade`) should remain responsive to mouse hover and click actions, even after reopening the `Flyout` and navigating between different views.
### Screenshots
### CalendarView ###
https://github.com/user-attachments/assets/d9e903e9-97cc-4158-984d-ed50da4835c5
### CalendarDatePicker ###
https://github.com/user-attachments/assets/87ba5ad5-503e-4999-8043-f93959ac444d
### NuGet package version
WinUI 3 - Windows App SDK 1.6.3: 1.6.241114003
### Windows version
_No response_
### Additional context
_No response_
Contributor guide
Research direction
Start by running the attached CalendarIssue.zip sample and reproduce the CalendarView behavior when hosted in Flyout.Content. Trace the CalendarView and CalendarDatePicker view transitions across Month, Year, and Decade after the Flyout is reopened. Done means cells remain responsive to hover and clicks in every view after repeated close-and-reopen cycles.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- desktop, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100