Skip to content

Commit ebc5205

Browse files
authored
fix: wrong onInteractive event when keyboard closed on iOS 26+ with attached KeyboardGestureArea (#1299)
## 📜 Description Fixed undesired `onInteractive` event during keyboard dismissal (non interactive). ## 💡 Motivation and Context It looks like on iOS 26 timings are different than on previous iOS versions and now when we detach `InvisibleAccessoryView` we may get a KVO event listener (that will report invalid keyboard frame). To avoid that I added a condition that will ignore this interactive event if you dismiss keyboard with attached `InvisibleAccessoryView`. Closes #1298 ## 📢 Changelog <!-- High level overview of important changes --> <!-- For example: fixed status bar manipulation; added new types declarations; --> <!-- If your changes don't affect one of platform/language below - then remove this platform/language --> ### iOS - use `KeyboardEventsIgnored` in KVO; ## 🤔 How Has This Been Tested? Tested manually in example project. ## 📸 Screenshots (if appropriate): |Before|After| |-------|-----| |<img width="857" height="72" alt="image" src="https://github.com/user-attachments/assets/dccaed3b-33e6-4b72-86a5-e44766808362" />|<img width="667" height="48" alt="image" src="https://github.com/user-attachments/assets/4a7a21a9-5acb-45e6-a80f-70b855f0d8f3" />| ## 📝 Checklist - [x] CI successfully passed - [x] I added new mocks and corresponding unit-tests if library API was changed
1 parent 13f58bd commit ebc5205

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

ios/observers/movement/observer/KeyboardMovementObserver+Interactive.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ extension KeyboardMovementObserver {
3030
return
3131
}
3232

33+
if KeyboardEventsIgnorer.shared.shouldIgnore {
34+
return
35+
}
36+
3337
let position = keyboardTrackingView.interactive(point: changeValue)
3438

3539
if position == KeyboardTrackingView.invalidPosition {

0 commit comments

Comments
 (0)