Skip to content

Conversation

@sean-perkins
Copy link
Contributor

Pull request checklist

Please check if your PR fulfills the following requirements:

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)
  • Build (npm run build) was run locally and any changes were pushed
  • Lint (npm run lint) has passed locally and any fixes were made for failures

Pull request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

What is the current behavior?

The next/previous buttons in the datetime is offset by 2 months. This is because the intersection observer is pre-maturely firing twice, during the re-render of the navigation to the desired month.

Issue Number: #24712

What is the new behavior?

The intersection observer is disconnected before the state update/re-render and re-attached after the render and scroll offset has completed. This allows the swipe gesture behavior to operate correctly and fixes the issue for next/previous button to navigate to the desired month (1 month offset).

Does this introduce a breaking change?

  • Yes
  • No

Other information

@sean-perkins sean-perkins requested a review from a team February 3, 2022 22:40
@github-actions github-actions bot added the package: core @ionic/core package label Feb 3, 2022
@sean-perkins sean-perkins requested a review from a team February 4, 2022 15:25
@Manishatah
Copy link

Hi Guys,
I am on v 6.1.2 and the issue still persists.
@amandaejohnston @sean-perkins

@averyjohnston
Copy link
Contributor

@Manishatah If the issue still occurs on the latest version of Ionic (currently 7.5.1), please open a new issue and include a code reproduction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

package: core @ionic/core package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants