Skip to content

Keep iOS Connect above the keyboard when it changes height - #1078

Merged
ivanfenenko merged 1 commit into
mainfrom
fix/ios-connect-hidden-by-password-keyboard
Nov 17, 2026
Merged

ivanfenenko merged 1 commit into
mainfrom
fix/ios-connect-hidden-by-password-keyboard

Conversation

@ivanfenenko

@ivanfenenko ivanfenenko commented Nov 17, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

On iOS Add server, entering the host, then the name, then tapping the password field could leave Connect hidden behind the keyboard. It did not happen every time.

While the keyboard is up, Connect sits in the scroll content. It was scrolled into view only when focus moved or when the keyboard first appeared. Moving into the password field swaps in a keyboard of another height (no predictive bar, a Passwords bar instead). That happens after the focus scroll has already run, and the keyboard was already visible, so nothing scrolled again. How often this showed depended on the previous field's keyboard, the Passwords bar, and animation timing.

The screen now scrolls again whenever the visible keyboard changes height. The rule is ConnectionSetupKeyboardLayout.needsRescroll(oldOverlap:newOverlap:), which replaces the visibility-only trigger in ConnectionSetupView.

Checks

  • iOS and Android both covered, or the reason one is not: iOS only. Android has not been checked for the same problem.
  • Screenshots for UI changes: none yet. The local simulator would not run the app (black screen, installs timing out), so the fix has not been seen on screen.
  • Tests run: ConnectionSetupKeyboardLayoutTests (6 tests) pass.

Risks / Follow-ups

  • Needs a manual check on a device: host → name → password, with and without Passwords autofill.
  • Check whether Android Add server has the same problem.

Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

Moving from the name field to the password field swaps in a keyboard of
another height after focus has already scrolled Connect into view, so
Connect could end up behind the keys. Re-scroll whenever the visible
keyboard changes height, not only when it first appears.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated review: 1 finding(s) that 2+ of 3 passes agreed on.

Outside the diff lines:

  • ios/OpenCode Mobile/OpenCode Mobile/UI/Connection/ConnectionSetupView.swift:79 medium: Rescroll on every overlap change fights interactive keyboard dismissal

opencode pr-review · passes: muse-spark-1.3-contributor, glm-5.3-flash, deepseek-v4.1-flash · $0.017

@ivanfenenko
ivanfenenko added this pull request to the merge queue Nov 17, 2026
Merged via the queue into main with commit ecbd6e7 Nov 17, 2026
@ivanfenenko
ivanfenenko deleted the fix/ios-connect-hidden-by-password-keyboard branch November 17, 2026 08:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant