Add MAUI SemanticProperties to inspector properties panel#150
Open
Add MAUI SemanticProperties to inspector properties panel#150
Conversation
Add a new 'Accessibility' group to the Visual Tree inspector's properties panel that queries and displays MAUI's SemanticProperties attached properties: - SemanticProperties.Description (text editor) - SemanticProperties.Hint (text editor) - SemanticProperties.HeadingLevel (enum: None, Level1-Level9) Also enrich DevFlowElementInfo model with optional semantic fields (semanticDescription, semanticHint, semanticHeadingLevel) so agents can include them in tree data. When present, these are shown in a dedicated Accessibility section in the Element identity panel. Properties gracefully degrade - they only appear when the agent returns non-null values. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The DevFlow inspector's Visual Tree properties panel shows Appearance, Layout, Behavior, and Transform groups but has no visibility into accessibility metadata. This makes it harder to verify that
SemanticPropertiesare correctly set on MAUI elements during development.Approach
Adds a new Accessibility property group that queries MAUI's
SemanticPropertiesattached properties via the DevFlow agent's property API:SemanticProperties.Description-- descriptive text for screen readers (text editor)SemanticProperties.Hint-- hint about what happens on interaction (text editor)SemanticProperties.HeadingLevel-- heading level enum (None, Level1--Level9)These are registered in the
PropertyRegistryalongside existing common properties, so they're fetched automatically when an element is selected. The "Accessibility" group appears between Behavior and Transform in the panel ordering.Additionally, enriches the
DevFlowElementInfomodel with optionalsemanticDescription,semanticHint, andsemanticHeadingLevelfields. When a MauiDevFlow agent includes these in tree data, they're displayed in a dedicated section in the Element identity area with a universal-access icon.Graceful degradation
Properties with null values are already filtered out by the existing
Where(p => p.Value != null)pipeline, so if the connected agent doesn't support attached property queries, the Accessibility section simply won't appear -- no errors, no empty groups.