Skip to content

Conversation

@SkinnnyJay
Copy link
Contributor

Fix: iOS TextField gray overlay when running on macOS with Increase Contrast disabled

This PR fixes issue #515, where text becomes invisible in the message input field when the iOS app is running on macOS with the "Increase Contrast" accessibility setting disabled. The fix adds iOS-specific modifiers to prevent the gray overlay from appearing on text fields.

Changes

  • Added .autocorrectionDisabled(true) modifier to prevent predictive text overlay
  • Added .focusEffectDisabled() modifier to disable the system focus effect
  • Wrapped these modifiers in #if os(iOS) to ensure they only apply to the iOS build

Testing

  • Verified the fix works on iOS apps running on macOS with "Increase Contrast" disabled
  • Confirmed no regressions in native macOS app functionality
  • All tests pass successfully

@SkinnnyJay
Copy link
Contributor Author

@jackjackbits just a heads up: we’ve seen 5+ reports of this issue tied to how the app is bundled and delivered via the App Store, which ends up serving it as an iOS build.

@jackjackbits
Copy link
Collaborator

but why are we turning off autocorrection for people? that would be unexpected behavior.

@SkinnnyJay
Copy link
Contributor Author

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

@SkinnnyJay SkinnnyJay marked this pull request as draft September 30, 2025 07:55
@SkinnnyJay
Copy link
Contributor Author

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Issue: When the iOS app is downloaded from the Mac App Store and run on
Apple Silicon Macs, a gray overlay appears over TextField components when
Increase Contrast accessibility setting is disabled.

Reproduction:
1. Download bitchat iOS app from Mac App Store
2. Run on Apple Silicon Mac
3. Disable 'Increase Contrast' in System Settings > Accessibility > Display
4. Focus on text input field - gray overlay appears

Fix: Use ProcessInfo.processInfo.isiOSAppOnMac runtime detection to disable
autocorrection only when iOS app runs on macOS. This targets the exact
environment where the issue occurs while preserving normal autocorrection
behavior for iPhone/iPad users.

Addresses code review feedback about incorrect conditional compilation.
@SkinnnyJay
Copy link
Contributor Author

@codex review round 3

@chatgpt-codex-connector
Copy link

Codex Review: Didn't find any major issues. Nice work!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

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.

2 participants