Skip to content

feat: add enhanced element detection and mobile_tap_element tool#216

Open
jpsim wants to merge 1 commit into
mobile-next:mainfrom
jpsim:feat-add-enhanced-element-detection-and-mobile_tap_element-tool
Open

feat: add enhanced element detection and mobile_tap_element tool#216
jpsim wants to merge 1 commit into
mobile-next:mainfrom
jpsim:feat-add-enhanced-element-detection-and-mobile_tap_element-tool

Conversation

@jpsim
Copy link
Copy Markdown

@jpsim jpsim commented Oct 12, 2025

Improve element detection to include interactive elements without visible text,
and add convenient tool to find and tap elements by query.

Android enhancements:

  • Add clickable, focusable, enabled, selected, package fields to UiAutomatorXmlNode
  • Include clickable/focusable elements (buttons, icons, views) in element detection
  • Change default element type from 'text' to 'element' for more accurate categorization

New mobile_tap_element tool:

  • Search for elements by text, label, name, value, or identifier
  • Case-insensitive matching
  • Provides helpful errors when no match or multiple matches found
  • Automatically taps center of matching element
  • Works on both iOS and Android

Co-Authored-By: @benlmyers

Improve element detection to include interactive elements without visible text,
and add convenient tool to find and tap elements by query.

Android enhancements:
- Add clickable, focusable, enabled, selected, package fields to UiAutomatorXmlNode
- Include clickable/focusable elements (buttons, icons, views) in element detection
- Change default element type from 'text' to 'element' for more accurate categorization

New mobile_tap_element tool:
- Search for elements by text, label, name, value, or identifier
- Case-insensitive matching
- Provides helpful errors when no match or multiple matches found
- Automatically taps center of matching element
- Works on both iOS and Android

Co-Authored-By: Ben Myers <benl.myers01@gmail.com>
@gmegidish
Copy link
Copy Markdown
Member

@jpsim hey, I understand the top part of the pull request. Same from @benlmyers . I haven't merged because I haven't been able to reproduce a problem with an app. I need to allocate time to write a sample app that doesn't work with the current code. As for the _tap_element, is it to save time? or does it solve other issues for you? Can you please explain the need for another tool? (tools cost context :P )

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