Skip to content

Add lightweight styling resources for AppBarButton width - #11622

Open
Niels Laute (niels9001) wants to merge 1 commit into
mainfrom
user/niels9001/9403-appbarbutton-width-resources
Open

Add lightweight styling resources for AppBarButton width#11622
Niels Laute (niels9001) wants to merge 1 commit into
mainfrom
user/niels9001/9403-appbarbutton-width-resources

Conversation

@niels9001

Copy link
Copy Markdown
Collaborator

Replaces #11590 so the head branch is owned by this repository.

Fixes

Fixes #9403

PR Type

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no API changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

Description

Current Behavior

The default 68px width of AppBarButton and AppBarToggleButton is fixed in their styles and cannot be changed through lightweight styling resources.

New Behavior

Adds AppBarButtonWidth and AppBarToggleButtonWidth resources, both defaulting to 68px in the regular and perf2026 styles. Overflow buttons remain auto-sized, and a locally set Width continues to take precedence. API and rendered-width coverage verify default, resource-overridden, overflow, and local-width behavior.

Customer Impact

Apps can adjust command button widths through lightweight styling without replacing the control templates.

Regression Potential

  • Low risk — isolated change, limited scope
  • Medium risk — touches shared components or public APIs
  • High risk — architectural or breaking API change

The new resources preserve the current defaults and precedence rules.

How Has This Been Tested?

  • I have performed a self-review of my own code
  • I have added tests to cover my changes
  • Existing tests pass locally

The product controls, core XAML, theme XBF, resource satellites, test app, and test project were previously built. The focused tests built and were discovered; execution was blocked by an activation failure also reproduced on the unchanged baseline.

Screenshots (if appropriate)

Not applicable.

Add overridable width resources for AppBarButton and AppBarToggleButton while preserving auto-sized overflow and local Width precedence.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 8ab4ed7c-df52-4775-bc59-85ca7fbd5ec4
@niels9001
Niels Laute (niels9001) requested a review from a team as a code owner August 25, 2026 08:02
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@microsoft-github-policy-service microsoft-github-policy-service Bot added the needs-triage Issue needs to be triaged by the area owners label Aug 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-triage Issue needs to be triaged by the area owners

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Proposal: Make DefaultAppBarButtonStyle.Width a resource or a property

1 participant