fix(datetime): respect config animated setting when paging month calendar#31227
Conversation
…ndar replace hardcoded `behavior: 'smooth'` with either `'smooth'` or `'instant'` depending on the `animated` boolean config property, defaulting to `'smooth'` closes ionic-team#30484
|
@droc101 is attempting to deploy a commit to the Ionic Team on Vercel. A member of the Team first needs to authorize it. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
ShaneK
left a comment
There was a problem hiding this comment.
Looking good, but can you add a test for this? This should be testable. Set animated: false, click the next/prev chevrons, and assert the calendar body jumps to the new scrollLeft instead of transitioning. The e2e testing config disables Ionic animations but not native scrollTo, so it won't mask this and you need an explicit case.
|
Current tests only check for the instant scroll with |
ShaneK
left a comment
There was a problem hiding this comment.
I don't know how I missed the update to this, sorry. Looks good to me, awesome work 🎉
Issue number: resolves #30484
What is the current behavior?
Paging through the month calendar in an always scrolls smoothly regardless of the
animatedproperty in global configWhat is the new behavior?
Paging will scroll instantly (no animation) if
animatedis false, otherwise the previous smooth scroll behavior persistsDoes this introduce a breaking change?