Skip to content

React Aria Calendar flashes previous month when initialised #9523

@thomasmoon

Description

@thomasmoon

Provide a general summary of the issue here

Hi,

I ran into an interesting bug when running Playwright tests on the calendar picker.

It calendar first loads with the last month visible and then flashes to the current month.

Happens so quickly that it's hard to catch, but it can be seen from your documentation page even:

https://react-aria.adobe.com/Calendar

React_Aria_Calendar_last_month_flashing.mp4

🤔 Expected Behavior?

It should just show the current month with no flashing.

😯 Current Behavior

Last month flashes quickly.

💁 Possible Solution

Need to check the initialization routines. Maybe the previous calendar is always included for fast switching but it should be hidden better and in my case old dates are disabled, so really wasn't expecting to see it.

🔦 Context

I encountered this in Playwright tests but after consulting the documentation, I can see that it's a general issue.

🖥️ Steps to Reproduce

  1. Go to the documentation page.
  2. Observe the flashing calendar view from the last month.

Version

react aria components 1.13.0

What browsers are you seeing the problem on?

Chrome

If other, please specify.

All browsers

What operating system are you using?

Mac OS

🧢 Your Company/Team

No response

🕷 Tracking Issue

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions