You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug: [vue] weird behaviour for ion-input focus within ion-modal #30013
I have searched for existing issues that already report this problem, without success.
Ionic Framework Version
v8.x
Current Behavior
I have created ion-modal and used the modelController to present the model (just copied the code from here,
the Modal.vue contains multiple ion-input and is triggered as
when setting the initialBreakpoint the focus randomly moves the ion-inputs within the modal, when removing completely the initialBreakpoint it works fine.
see attached video
Screen.Recording.2024-11-12.at.22.13.57.mov
Expected Behavior
moving between the ion-inputs should be smooth and focus should be set accordingly.
This is fixed on the latest release: I verified it on 9.0.6. In a modal that opens partway up the screen, scroll assist thinks every input sits under the keyboard, so it waits up to a second before completing focus. In older versions, when that wait ended it moved focus back to the input it was handling, even if you had already tapped a different one. That's why focus seemed to jump randomly. The fix shipped in 8.7.17 with the scroll assist focus fix.
Upgrade to 8.7.17 or later, or to 9.x.
If you can't upgrade yet, turning off scroll assist avoids it:
One thing to note separately: initialBreakpoint needs breakpoints set too (for example breakpoints: [0, 0.5, 1]). Without it, the modal opens halfway but isn't a real sheet, so there's no drag gesture or handle.
Closing this since it's resolved in current releases.
Activity
thetaPC commentedon Sep 30, 2026
Thanks for the report, and sorry for the delay.
This is fixed on the latest release: I verified it on 9.0.6. In a modal that opens partway up the screen, scroll assist thinks every input sits under the keyboard, so it waits up to a second before completing focus. In older versions, when that wait ended it moved focus back to the input it was handling, even if you had already tapped a different one. That's why focus seemed to jump randomly. The fix shipped in 8.7.17 with the scroll assist focus fix.
One thing to note separately:
initialBreakpointneedsbreakpointsset too (for examplebreakpoints: [0, 0.5, 1]). Without it, the modal opens halfway but isn't a real sheet, so there's no drag gesture or handle.Closing this since it's resolved in current releases.