fix(selectors): honor a published editable fact in matching and is editable

Merged
TH
1mo ago
+70-2

Summary

isNodeEditable now lets an explicit editable fact decide both editable= selector matching and is editable. Without the fact, type inference is unchanged; a disabled node is still never editable. Fix is in the one owner (packages/selectors/src/internal/node.ts), plus a note in website/docs/docs/selectors.md. 5 files touched, no scope expansion.

agent-device is editable 'label="Mobile"'   # Android Spinner publishing editable: true

Closes #3530

Validation

Tested commit: 60eb25cdb. pnpm check:affected --run passed.

New unit tests cover a custom view with editable: true, a text field with editable: false, a disabled field, and the fact absent. The three fact-driven tests fail on origin/main's node.ts and pass with the fix.

Live, Android emulator via ADB (android-helper backend 0.21.27-dev), Contacts "Create contact" screen, whose "Mobile" Spinner publishes editable: true:

commandbase 46dae0f2ehead 60eb25cdb
is editable 'label="Mobile"'COMMAND_FAILED ... editable:falsePassed: is editable
is exists 'label="Mobile" editable=true'failsPassed
is exists 'label="Mobile" editable=false'Passedfails

Known gap, outside this package: fill's "not a text input" warning in src/commands/interaction/runtime/interactions.ts still uses isFillableType, not the fact.

šŸ¤– Generated with Claude Code