Repository navigation
Description
Environment
- agent-device 0.21.36, 0.21.36-nightly.20261031.115, and
mainat035c2b6ca. - iPhone 16 on iOS 26.4, iPhone 17 and iPhone 18 Pro on iOS 27.2, and iPhone Duo on iOS 27.1 (open and closed) simulators.
- macOS with Xcode, SDK iphonesimulator 27.2.
Description
gesture swipe left-edge and right-edge do not start screen-edge gestures on iOS simulators. The touch reaches the app, but UIKit does not mark it as a screen-edge touch (UITouch._edgeType is 0). A UIScreenEdgePanGestureRecognizer stays in .possible and never calls its action.
A UINavigationController back swipe still works, but only because of the iOS 26 full-content pop gesture. With that gesture off, the screen does not pop.
It fails on every version I tested. I do not know of a version where it worked.
The start coordinate is not the cause. XCTest synthesized touches carry no edge information, even at x = 0. A hand swipe from the left edge on the iPhone Duo inner panel shows what UIKit expects. Its digitizer events carry SwipeLocked and the native swipe direction (SwipeUp on that rotated panel) on every frame, and the first move is short:
| Touch | _edgeType |
Edge recognizer | Navigation pop |
|---|---|---|---|
gesture swipe right-edge (XCTest, x = 8) |
0 | never began | no |
| XCTest swipe at x = 0.0 (viewport inset removed locally) | 0 | never began | not tested |
| Hand swipe, Duo inner panel | 4 | began when the first move was short, failed after a jump of about 150 pt | n/a |
IOHID touch, FromEdgeFlat | FromEdgeTip mask, single-display iPhone |
1 | began, changed, ended | yes |
| Same touch, Duo inner panel | 1 | never began | no |
IOHID touch, SwipeLocked and native swipe direction, first move eased in, every simulator above |
4 | began, changed, ended | yes |
Required behavior
- On an iOS simulator,
gesture swipe left-edgeandright-edgedeliver a touch that UIKit marks as a screen-edge touch. - Other gestures keep their current dispatch path.
- Physical devices keep their current behavior. Device support is out of scope until it is verified on hardware.
Completion conditions
./repro.shfrom the demo below exits0: all three cases pass.- Planner and runner tests cover the edge-preset route, and existing gesture tests pass on iOS and Android.
Dependencies
None.
Reproducible Demo
2026-11-04.1.30.10.mov
gronxb/agent-device-repro@ios-edge-swipe: a minimal UIKit app built with swiftc, with no Xcode project. It needs Xcode, a booted iPhone simulator, and agent-device on PATH.
git clone -b ios-edge-swipe https://github.com/gronxb/agent-device-repro.git
cd agent-device-repro
./repro.sh # exits 1 while any case failsThe app has one UIScreenEdgePanGestureRecognizer (edge: N counts .began) and a plain pan on the same view (pan: N) as a control. last: shows UITouch._edgeType and the recognizer states.
FAIL right-edge -> left-edge recognizer expected "edge: 1"
"edge: 0" "pan: 1" "last: touch x=8.0 edgeType=0 states=never-began(possible)"
FAIL left-edge -> right-edge recognizer expected "edge: 1"
"edge: 0" "pan: 1" "last: touch x=385.0 edgeType=0 states=never-began(possible)"
FAIL right-edge -> UINavigationController pop expected "nav root"
"nav pushed"
./repro.sh --driver probe sends the same swipes as FromEdgeFlat | FromEdgeTip HID touches. Every case passes on a single-display iPhone.
Activity
thymikee commentedon Nov 4, 2026
Triage: bug. Confirmed: edge presets are planned as ordinary XCTest swipes from 1% or 99% of the width (
packages/contracts/src/scroll-gesture.ts), and XCTest synthesized touches carry no edge type, soUIScreenEdgePanGestureRecognizercannot begin. The fix needs a new simulator touch route (IOHID digitizer events with the edge mask). Adding a dispatch route is a maintainer decision, so this is parked until then. Thanks for the_edgeTypetable and the probe driver; they narrow what that route has to send.