Repository navigation
[Android] Entry: Expose SemanticProperties.Description as ContentDescription - #37276
Conversation
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/dotnet/maui/main/eng/scripts/get-maui-pr.sh | bash -s -- 37276Or
iex "& { $(irm https://raw.githubusercontent.com/dotnet/maui/main/eng/scripts/get-maui-pr.ps1) } 37276" |
|
Azure Pipelines: Successfully started running 1 pipeline(s). There may be pipelines that require an authorized user to comment /azp run to run. |
This comment has been minimized.
This comment has been minimized.
MauiBot
left a comment
There was a problem hiding this comment.
Expert Review — 3 findings
See inline comments for details.
|
|
||
| if (!string.IsNullOrEmpty(desc)) | ||
| { | ||
| newContentDescription = desc; |
There was a problem hiding this comment.
🔍 AI-Generated Review (multi-model)
[major] Accessibility / Logic and Correctness — Hoisting newContentDescription = desc above the EditText branch means an EditText node now carries BOTH ContentDescription = "desc" and the synthesized Text = "desc, text". The previous code deliberately kept ContentDescription null for EditText and encoded the description into Text (see the comment on the next line). TalkBack prefers contentDescription over text when both are populated on a node, and for editable nodes it announces the description as the label and the node text as the value. Concrete scenario: <Entry Text="Entry text" SemanticProperties.Description="Entry description"/> on API 26+ now produces label="Entry description" and value="Entry description, Entry text", i.e. the description is announced twice — or, if TalkBack suppresses the node text in favor of the content description, the user no longer hears the entered text at all. Either outcome is a user-visible accessibility regression for every EditText-backed control (Entry, Editor, SearchBar, and third-party handlers whose platform view derives from EditText), not just Entry.
The hint path compounds this: with SemanticProperties.Hint also set and API >= 26, the node now ends up with ContentDescription = desc + Text = "desc, text" + HintText = hint simultaneously (the pre-26 branch still nulls newContentDescription, so only API 26+ changes). Please state the concrete on-device TalkBack verification (announcement string before/after, API 26+ and pre-26, with and without Hint, empty vs non-empty Text) that justifies setting both fields; if the goal is only to make the description discoverable to Appium/automation queries, prefer a change scoped to that consumer rather than altering what TalkBack reads.
| { | ||
| newContentDescription = desc; | ||
|
|
||
| // Edit Text fields won't read anything for the content description |
There was a problem hiding this comment.
🔍 AI-Generated Review (multi-model)
[minor] Complexity Reduction (stale comment) — The comment "Edit Text fields won't read anything for the content description" is now directly contradicted by the line above it, which sets newContentDescription = desc precisely for EditText. If the new behavior is intended, replace this comment with the reason the description must be duplicated into both ContentDescription and Text; otherwise a future reader will re-remove one of the two assignments.
| var values = await GetValueAsync(entry, handler => | ||
| { | ||
| using var info = AccessibilityNodeInfoCompat.Obtain(); | ||
| handler.PlatformView.UpdateSemanticNodeInfo(entry, info); |
There was a problem hiding this comment.
🔍 AI-Generated Review (multi-model)
[moderate] Regression Prevention / Test Coverage — This test only exercises the single happy path (Description set, non-empty Text, no Hint) and asserts the two fields the change writes, so it cannot discriminate the regression risk introduced by the change:
- No negative/adjacent case:
Description+Hinton API 26+ is the combination where the node now ends up with ContentDescription + Text + HintText all populated; emptyText(newText = descwith ContentDescription alsodesc) is untested; the non-EditText path that previously owned this behavior is untested. Per the adjacent-scenario rule, a fix should enumerate the neighboring behaviors that were checked. - Shared-code blast radius is untested:
UpdateSemanticNodeInfois shared by all EditText-backed handlers, but only Entry is covered — Editor and SearchBar get the same behavior change with no assertion. - The test bypasses the production path. Runtime goes through
MauiAccessibilityDelegateCompat.OnInitializeAccessibilityNodeInfo(andGetSemanticPlatformElement) on a node initialized by the platform view; this calls the extension directly on a bareAccessibilityNodeInfoCompat.Obtain()node, so it validates the string formatting only and would stay green if delegate wiring or semantic-element resolution regressed. - Most importantly, the assertions cannot detect the actual defect class at stake (what TalkBack announces when both ContentDescription and Text are set) — that needs an on-device/UI-level verification or an explicit note in the PR that it was manually verified.
MauiBot
left a comment
There was a problem hiding this comment.
AI Review Summary
@devanathan-vaithiyanathan — new AI review results are available based on commit
36693c1.
🗂️ Review Sessions — click to expand
🚦 Gate — Test Before & After Fix
Gate Result: ✅ PASSED
Platform: ANDROID · Base: main · Merge base: 1749485a
| Test | Without Fix (expect FAIL) | With Fix (expect PASS) |
|---|---|---|
📱 EntryHandlerTests (SemanticDescriptionInitializesAccessibilityContentDescription) Category=Entry |
✅ FAIL — 535s | ✅ PASS — 388s |
🔴 Without fix — 📱 EntryHandlerTests (SemanticDescriptionInitializesAccessibilityContentDescription): FAIL ✅ · 535s
(no coded error found; showing last 1200 chars)
08-10 15:42:54.477 17829 18032 I DOTNET : === TEST EXECUTION SUMMARY ===
08-10 15:42:54.477 17829 18032 I DOTNET : Tests run: 1411 Passed: 188 Inconclusive: 0 Failed: 1 Ignored: 1220 Skipped: 2
fail: Non-success instrumentation exit code: 1, expected: 0
info: <<XHARNESS_RESULT_START>>
{
"version": 1,
"machineName": "runnervmtroe5",
"exitCode": 1,
"exitCodeName": "TESTS_FAILED",
"platform": "android",
"instrumentationExitCode": 1,
"device": "emulator-5554",
"deviceOsVersion": "API 30",
"architecture": "x86_64",
"files": [
{
"name": "testResults-8832fa9d3bd448af856c64d7ac1cbff9.xml",
"type": "test-results"
},
{
"name": "adb-logcat-com.microsoft.maui.core.devicetests-default.log",
"type": "logcat"
}
]
}
<<XHARNESS_RESULT_END>>
info: Attempting to remove apk 'com.microsoft.maui.core.devicetests'..
info: Successfully uninstalled com.microsoft.maui.core.devicetests
XHarness exit code: 1 (TESTS_FAILED)
Passed: 0
Failed: 1
Skipped: 0
Total: 1
Tests completed with exit code: 1
🟢 With fix — 📱 EntryHandlerTests (SemanticDescriptionInitializesAccessibilityContentDescription): PASS ✅ · 388s
(no coded error found; showing last 1200 chars)
10 15:49:24.840 18784 18983 I DOTNET : Xml file was written to the provided writer.
08-10 15:49:24.840 18784 18983 I DOTNET : === TEST EXECUTION SUMMARY ===
08-10 15:49:24.840 18784 18983 I DOTNET : Tests run: 1411 Passed: 189 Inconclusive: 0 Failed: 0 Ignored: 1220 Skipped: 2
info: <<XHARNESS_RESULT_START>>
{
"version": 1,
"machineName": "runnervmtroe5",
"exitCode": 0,
"exitCodeName": "SUCCESS",
"platform": "android",
"instrumentationExitCode": 0,
"device": "emulator-5554",
"deviceOsVersion": "API 30",
"architecture": "x86_64",
"files": [
{
"name": "testResults-cd0a24f3718e4d63a0433bba3d9b0f83.xml",
"type": "test-results"
},
{
"name": "adb-logcat-com.microsoft.maui.core.devicetests-default.log",
"type": "logcat"
}
]
}
<<XHARNESS_RESULT_END>>
info: Attempting to remove apk 'com.microsoft.maui.core.devicetests'..
info: Successfully uninstalled com.microsoft.maui.core.devicetests
XHarness exit code: 0
Passed: 1
Failed: 0
Skipped: 0
Total: 1
Tests completed successfully
📁 Fix files reverted (1 files)
src/Core/src/Platform/Android/SemanticExtensions.cs
📋 Pre-Flight — Context & Validation
PR #37276 Pre-Flight
Context
- Title:
[Android] Apply SemanticProperties.Description to Entry contentDescription - Issue: #37151,
SemanticProperties.Description is not applied to Android contentDescription for Entry - Target:
main - Platform: Android
- Problem:
UpdateSemanticNodeInfosynthesizes the semantic description into anEditTextaccessibility node'sText, but leavesContentDescriptionunset. Appium and UIAutomator therefore expose an emptycontent-desc.
Existing PR Approach
The PR moves newContentDescription = desc ahead of the EditText branch in SemanticExtensions.UpdateSemanticNodeInfo. This applies the description to ContentDescription for every view while preserving the existing EditText text synthesis ("{description}, {text}") used by TalkBack.
if (!string.IsNullOrEmpty(desc))
{
+ newContentDescription = desc;
+
if (platformView is EditText et)
{
...
}
- else
- newContentDescription = desc;
}Changed files in the squashed PR commit:
src/Core/src/Platform/Android/SemanticExtensions.cssrc/Core/tests/DeviceTests/Handlers/Entry/EntryHandlerTests.Android.cs
The added test directly creates an accessibility node, invokes UpdateSemanticNodeInfo, and asserts both:
ContentDescription == "Entry description"Text == "Entry description, Entry text"
Validation
The prior gate passed and must not be rerun:
- Without the fix: the new test failed because
ContentDescriptionwasnull. - With the fix: the new test passed.
Primary bounded command for alternative candidates:
pwsh .github/skills/run-device-tests/scripts/Run-DeviceTests.ps1 -Project Core -Platform android -TestFilter "Category=Entry"No additional mandatory regression test was enumerated for STEP 5a. Do not run an unfiltered or full test suite.
Candidate Requirements
Each candidate must replace the PR production-code fix with one genuinely different root-cause strategy, retain the PR's test, run only the targeted Entry device-test filter, perform the try-fix inline expert self-review, capture artifacts, and restore the baseline. Candidate 2 must avoid both the PR approach and candidate 1's recorded approach.
Additional Findings
- No human review or inline comments were present when pre-flight ran.
- The mechanical regression cross-reference reported no overlap with recent labeled bug-fix PRs.
- The worktree contains unrelated pre-existing modifications outside the two PR files; candidates must preserve them.
🔬 Code Review — Deep Analysis
Expert PR Evaluation
Verdict: NEEDS_CHANGES
Confidence: medium
Independent assessment
The submitted change makes every Android EditText accessibility node expose the semantic description through both ContentDescription and the existing synthesized Text. This fixes the automation-facing content-desc gap while retaining the data previously used for TalkBack.
Findings
- Major — accessibility behavior needs justification. Populating both fields can change what TalkBack announces for every
EditText-backed control, especially when text or an API 26+ hint is also present. The focused test proves the node values but not the resulting announcement. - Moderate — adjacent coverage is missing. Empty text, semantic hints, and the production accessibility-delegate path are not covered, although they exercise neighboring branches of the modified shared method.
- Minor — the adjacent comment is stale. It says editable controls do not read
ContentDescription, but the new code deliberately populates that field and should explain why both channels are retained.
Blast radius and failure-mode probing
- The code runs for all Android handlers whose platform view derives from
EditText, including Entry, Editor, SearchBar, and compatible custom handlers. - It does not add startup work, static state, subscriptions, or lifecycle state.
- Null or empty descriptions preserve the old path.
- On API levels below 26, the existing hint fallback clears
newContentDescription; on API 26 and later, description, synthesized text, and hint can all remain populated. - The trusted Gate passed: the focused test fails without the submitted fix and passes with it. Gate verification was not rerun.
The raw file:line findings are recorded in inline-findings.json.
🛠️ Try-Fix — Analysis & Comparison
Try-Fix Alternatives for PR #37276
Candidate 1 - Platform View as Source of Truth
Model: claude-opus-5
Approach: Apply Semantics.Description to the Android EditText.ContentDescription in UpdateSemantics, then mirror that platform-view value into the accessibility node from the EditText branch of UpdateSemanticNodeInfo. A helper rejects an AutomationId-derived content description. This differs from the PR's stateless node-only assignment because it makes the native platform view the source of truth for Appium/UIAutomator.
Files changed: src/Core/src/Platform/Android/SemanticExtensions.cs (+24/-0)
Result: Pass
Test: pwsh .github/skills/run-device-tests/scripts/Run-DeviceTests.ps1 -Project Core -Platform android -TestFilter "Category=Entry"
- Initial run: one regression,
Automation Id is set correctlyexpected"TestId"but got"". - Allowed focused correction: assign the platform content description only when
semantics.Descriptionis non-empty. - Retest: 1450 tests discovered, 238 passed, 0 failed; XHarness exit code 0.
Self-review: 4 findings (0 critical, 0 major, 3 moderate, 1 minor):
- A semantic description takes ownership of
content-descfrom AutomationId when both are set. - Mapper ordering can let a later AutomationId update overwrite the description.
- Clearing
Descriptionleaves a stale platform content description. - The platform assignment can promote
ImportantForAccessibilityfrom Auto to Yes.
Analysis: The approach validates the requested test and benefits raw native view-hierarchy readers, but it introduces synchronization and ownership problems between semantic-description and AutomationId mappers. The PR's stateless node-level derivation avoids those risks and is lower risk unless native-view state is explicitly required.
Artifacts:
- Narrative:
CustomAgentLogsTmp/PRState/37276/PRAgent/try-fix-1/content.md - Full diff and logs:
CustomAgentLogsTmp/PRState/37276/PRAgent/try-fix/attempt-1/
Candidate 2 - EditText-Specific Dual-Channel Node Emission
Model: gpt-5.6-sol
Approach: Keep the established split between generic controls and EditText, but make the editable-control branch explicitly emit the semantic description through both accessibility-node channels: preserve the synthesized TalkBack Text and independently populate ContentDescription. This is stateless and EditText-specific, unlike the PR's generic all-view assignment and candidate 1's platform-view synchronization.
Files changed: src/Core/src/Platform/Android/SemanticExtensions.cs (+5/-1)
Result: Pass
Test: pwsh .github/skills/run-device-tests/scripts/Run-DeviceTests.ps1 -Project Core -Platform android -TestFilter "Category=Entry"
- One implementation/test pass; no correction was needed.
- 1450 tests discovered, 238 passed, 0 failed; XHarness exit code 0.
Self-review: Clean, 0 findings.
Analysis: The stateless node-only implementation avoids candidate 1's mapper ordering, stale-state, AutomationId ownership, and accessibility-promotion risks while limiting the behavior change to editable controls. It duplicates the description assignment across the EditText and non-EditText branches, whereas the PR's generic assignment is more compact.
Artifacts:
- Narrative:
CustomAgentLogsTmp/PRState/37276/PRAgent/try-fix-2/content.md - Full diff and logs:
CustomAgentLogsTmp/PRState/37276/PRAgent/try-fix/attempt-2/
📝 PR Finalize — Recommended Title & Description
Assessment: ✏️ Recommend updating — the current metadata is accurate but the title does not follow the component-title form and the description leaves “After the fix, an Entry exposes:” incomplete while omitting the added regression test.
Recommended title
[Android] Entry: Expose SemanticProperties.Description as ContentDescription
Recommended description
### Issue Details
On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`.
### Description of Change
Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`.
The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes:
- `ContentDescription`: `Entry description`
- `Text`: `Entry description, Entry text`
Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values.
This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools.
### Issues Fixed
Fixes #37151
**Tested the behavior in the following platforms.**
- [x] Android
- [x] Windows
- [x] iOS
- [x] Mac
| Before | After |
|---------|--------|
| **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
🏁 Report — Final Recommendation
⚠️ Final Recommendation: REQUEST CHANGES
Winner: pr
The submitted PR is the strongest candidate because it is the smallest stateless fix, its trusted Gate passed, and neither passing alternative provides a concrete safety advantage. It should not be approved yet: the expert review identified unresolved TalkBack behavior risk for editable nodes that carry both ContentDescription and synthesized Text, plus a stale comment and incomplete adjacent-path coverage.
Candidate comparison
| Rank | Candidate | Validation | Assessment |
|---|---|---|---|
| 1 | pr |
Gate passed: the focused test fails without the fix and passes with it | Minimal, stateless change; preserves existing non-EditText behavior without extra state or branching. Expert accessibility concerns remain unresolved. |
| 2 | try-fix-2 |
Passed: 238 passed, 0 failed | Same effective EditText dual-channel behavior, but adds a flag and a second emission branch without reducing the TalkBack or test-coverage risk. |
| 3 | try-fix-1 |
Passed after one correction: 238 passed, 0 failed | Mutates native view state and introduces documented AutomationId ownership, mapper-ordering, stale-clear, and accessibility-importance risks. |
| 4 | pr-plus-reviewer |
Failed to compile (CS0103) |
Improves the comment and attempts broader production-path coverage, but failed required validation and therefore ranks below all passing candidates. |
Expert findings on the submitted PR
- Populating both accessibility fields may duplicate the semantic description or suppress the editable value in TalkBack; the focused node-value assertion cannot establish announcement behavior.
- Empty text, API 26+ hints, other
EditText-backed controls, and delegate wiring are not covered. - The adjacent comment contradicts the new dual-channel behavior.
The raw PR remains preferable to the alternative implementations, but the accessibility behavior should be explicitly verified and the documentation/coverage findings addressed before approval.
📱 UI Tests — ViewBaseTests
Detected UI test categories: ViewBaseTests
✅ Deep UI tests — 118 passed, 0 failed, 1 skipped across 1 category on platform-pool agent (replaces in-process counts above).
🧪 UI Test Execution Results (deep, platform pool)
| Category | Tests | Snapshot diffs |
|---|---|---|
ViewBaseTests |
118/119 (1 skipped) ✓ | — |
📎 Download drop-deep-uitests artifact (TRX + snapshot diffs) |
🧭 Next Steps — review latest findings
No alternative fix was selected for this run. Review the session findings and CI results before merging.
|
Azure Pipelines: Successfully started running 1 pipeline(s). There may be pipelines that require an authorized user to comment /azp run to run. |
There was a problem hiding this comment.
Pull request overview
This PR improves Android accessibility/automation parity by ensuring SemanticProperties.Description is surfaced via the Android accessibility node’s ContentDescription for Entry (and other views), while preserving the existing synthesized Text behavior used for editable controls.
Changes:
- Update Android
SemanticExtensions.UpdateSemanticNodeInfoto always setContentDescriptionfrom semantic description (including forEditText). - Preserve existing
EditTexttext synthesis (Text = "{desc}, {text}") for TalkBack-style announcements. - Add an Android device test validating both
ContentDescriptionand synthesizedTextfor anEntry.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/Core/src/Platform/Android/SemanticExtensions.cs | Ensures semantic description is applied to AccessibilityNodeInfoCompat.ContentDescription even for EditText, keeping existing synthesized text behavior. |
| src/Core/tests/DeviceTests/Handlers/Entry/EntryHandlerTests.Android.cs | Adds a device test to verify Entry exposes semantic description via ContentDescription and preserves synthesized node Text. |
|
/azp run |
|
Azure Pipelines: Successfully started running 3 pipeline(s). |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
…ription (#37276) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ### Issue Details On Android, `SemanticProperties.Description` was not exposed through an Entry accessibility node's `ContentDescription`. MAUI handled editable Android controls (`EditText`) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node's `Text` so TalkBack could announce it. Consequently, Appium and UIAutomator reported an empty `content-desc`. ### Description of Change Updated `SemanticExtensions.UpdateSemanticNodeInfo` to assign `SemanticProperties.Description` to the Android accessibility node's `ContentDescription` for all views, including `EditText`. The existing synthesized accessibility text for editable controls is preserved. An Entry with description `Entry description` and text `Entry text` now exposes: - `ContentDescription`: `Entry description` - `Text`: `Entry description, Entry text` Added an Android Entry device test in `EntryHandlerTests.Android.cs` that verifies both node values. This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools. ### Issues Fixed Fixes #37151 **Tested the behavior in the following platforms.** - [x] Android - [x] Windows - [x] iOS - [x] Mac | Before | After | |---------|--------| | **Android**<br> <img src="https://github.com/user-attachments/assets/6213bd4b-2289-49fe-ac22-8db2a0e4a810" width="600" height="300"> | **Android**<br> <img src="https://github.com/user-attachments/assets/4c764c7d-daa1-4f27-a8e8-aba74722c996" width="600" height="300"> |
Note
Are you waiting for the changes in this PR to be merged?
It would be very helpful if you could test the resulting artifacts from this PR and let us know in a comment if this change resolves your issue. Thank you!
Issue Details
On Android,
SemanticProperties.Descriptionwas not exposed through an Entry accessibility node'sContentDescription. MAUI handled editable Android controls (EditText) differently from controls such as Label: for Entry, the semantic description was added only to the accessibility node'sTextso TalkBack could announce it. Consequently, Appium and UIAutomator reported an emptycontent-desc.Description of Change
Updated
SemanticExtensions.UpdateSemanticNodeInfoto assignSemanticProperties.Descriptionto the Android accessibility node'sContentDescriptionfor all views, includingEditText.The existing synthesized accessibility text for editable controls is preserved. An Entry with description
Entry descriptionand textEntry textnow exposes:ContentDescription:Entry descriptionText:Entry description, Entry textAdded an Android Entry device test in
EntryHandlerTests.Android.csthat verifies both node values.This preserves the existing TalkBack-oriented text synthesis while making the semantic description available to Appium, UIAutomator, and other accessibility tools.
Issues Fixed
Fixes #37151
Tested the behavior in the following platforms.