Skip to content

fix: include multiline TextView in iOS accessibility dump#294

Open
Ernest94 wants to merge 1 commit into
mobile-next:mainfrom
Ernest94:fix/ios-multiline-textinput-accessibility-dump
Open

fix: include multiline TextView in iOS accessibility dump#294
Ernest94 wants to merge 1 commit into
mobile-next:mainfrom
Ernest94:fix/ios-multiline-textinput-accessibility-dump

Conversation

@Ernest94

@Ernest94 Ernest94 commented Jul 1, 2026

Copy link
Copy Markdown

Problem

Multiline React Native TextInput components render on iOS as a UITextView, which WDA reports as XCUIElementTypeTextView. The accessibility-dump filter in devices/wda/source.go only accepted TextField (single-line UITextField), so multiline inputs were dropped from the tree entirely — making them impossible to locate (getByLabel()) or fill.

Fixes #293

Fix

Add TextView to both the acceptedTypes list and the alwaysInclude set in filterSourceElements, mirroring how TextField is handled (so it's kept even when it has no label/name yet, e.g. an auto-focused empty field).

Tests

Added two tests in source_test.go:

  • a labeled multiline TextView is included in the dump
  • an unlabeled TextView is always included

go test ./devices/wda/ passes.

🤖 Generated with Claude Code

@coderabbitai

coderabbitai Bot commented Jul 1, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 54054b13-e58b-44e6-a6bf-48f889cb8044

📥 Commits

Reviewing files that changed from the base of the PR and between d211a16 and 613c727.

📒 Files selected for processing (2)
  • devices/wda/source.go
  • devices/wda/source_test.go
🚧 Files skipped from review as they are similar to previous changes (2)
  • devices/wda/source.go
  • devices/wda/source_test.go

Walkthrough

WDA source filtering now accepts TextView elements and always includes them, including elements without labels or identifiers. Unit tests cover multiline React Native text inputs and auto-focused multiline inputs lacking identifiers.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly states the main change: including multiline TextView support in the iOS accessibility dump.
Description check ✅ Passed The description matches the code changes and explains the TextView fix and added tests.
Linked Issues check ✅ Passed The changes address #293 by adding TextView to accepted and always-include filters and covering labeled and unlabeled cases.
Out of Scope Changes check ✅ Passed No unrelated code changes are evident beyond the TextView accessibility-dump fix and its tests.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@gmegidish

Copy link
Copy Markdown
Member

@Ernest94 I only got to this now. I'm sorry. Can you please sign your commits so I can merge? Thank you!!

Multiline React Native TextInput renders as UITextView
(XCUIElementTypeTextView), which was missing from acceptedTypes so it
was dropped from the dump and could not be located or filled. Add
TextView to the accepted and always-include sets, matching TextField.

Fixes mobile-next#293

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@Ernest94 Ernest94 force-pushed the fix/ios-multiline-textinput-accessibility-dump branch from f87ffcc to 613c727 Compare July 14, 2026 15:44
@Ernest94

Copy link
Copy Markdown
Author

@gmegidish I signed the commit, thanks.

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.

iOS multiline TextInput (UITextView) missing from accessibility dump — can't locate/fill it

2 participants