material-components / material-components/material-components-android

[MaterialButton] Missing theme attributes for `.Icon` button styles

Open
#3,506 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug Widget: Button
Dominant language
Java
Stars
17.4k
Forks
3.2k
PR merge metrics
No merged PRs in 30d

Description

**Description:** In the `MaterialComponents` and `Material3` themes, buttons can be styled using theme attributes like `?materialButtonStyle` and `? materialButtonOutlinedStyle` rather than using the explicit style references (like `@style/Widget.Material3.Button`). This allows you to customise button styles at the theme level (by setting these attributes) rather than having to change every button's `style` attribute. However, there is no theme level attributes corresponding to the `.Icon` button styles (like `@style/Widget.Material3.Button.Icon`).

**Expected behavior:** There should be attributes for the `.Icon` styles for `MaterialButton`.

**Material Library version:** 1.9.0

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the MaterialButton theme and style definitions for the MaterialComponents and Material3 themes, then compare the existing theme attributes with the `.Icon` style references described in the issue. Add the missing theme-level attributes and verify that they can customize the corresponding Icon button styles without explicit style references.

Written by the indexing model from the issue text.

Assessment

Tech stack
android
Domain
mobile
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.