Skip to content

Conversation

@danielchalmers
Copy link
Member

This adds tooltips to the icon buttons in the Color Picker to help overall accessibility. They use the same localization strings as the ARIA labels (no extra setup) and can be disabled if wanted. They are opt-out instead of opt-in as the risk should be low while the benefit in usability is noticeable.

image image

These icons (and this component) were specifically picked because the purpose may not be immediately understandable for most users, unlike standard icons like a pencil for edit, a gear for settings, a palette for the adornment, etc.

They use the default tooltip timings (instantly appears) which can be changed in MudGlobal.

Checklist:

  • The PR is submitted to the correct branch (dev).
  • My code follows the style of this project.
  • I've added relevant tests or confirmed existing ones.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds tooltips to icon buttons in the MudColorPicker component to improve accessibility and user experience. The tooltips are opt-out by default and use existing localization strings.

  • Adds a ShowTooltips property (default: true) to control tooltip display
  • Wraps icon buttons with MudTooltip components using existing localization strings
  • Updates formatting for consistency

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
MudColorPicker.razor.cs Adds ShowTooltips property to enable/disable tooltips
MudColorPicker.razor Wraps icon buttons with tooltip components and improves formatting

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@mudbot mudbot bot added accessibility Accessibility concerns (ARIA, keyboard, focus, screen readers, contrast) enhancement Request for adding a new feature or enhancing existing functionality (not fixing a defect) labels Oct 10, 2025
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces tooltips for the icon buttons in the MudColorPicker component, improving accessibility and user experience. The change is well-implemented by adding a ShowTooltips property to control their visibility, defaulting to true to make this an opt-out feature. My review found one issue: the new ShowTooltips property is missing the [Parameter] attribute, which prevents it from being configured in markup. Once this is addressed, the PR should be ready for merging.

@danielchalmers
Copy link
Member Author

Taken from #11377

Copy link
Member

@igotinfected igotinfected left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@danielchalmers danielchalmers merged commit 8c0002b into MudBlazor:dev Oct 11, 2025
6 checks passed
@danielchalmers danielchalmers deleted the color-picker-tooltips branch October 11, 2025 02:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

accessibility Accessibility concerns (ARIA, keyboard, focus, screen readers, contrast) enhancement Request for adding a new feature or enhancing existing functionality (not fixing a defect)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants