Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Buttons: Use fixed size for layout #10040

Draft
wants to merge 5 commits into
base: dev
Choose a base branch
from

Conversation

danielchalmers
Copy link
Contributor

@danielchalmers danielchalmers commented Oct 15, 2024

Description

Part of #8884. Resolves #4160. Resolves #5306.

Switches from using padding, which allows the inner content to change the size, to a precise, fixed number of pixels that conforms to Material Design 2.

This can be a breaking visual change depending on how the buttons are used; for example, if they were previously allowed to stretch, they will no longer do so.

How Has This Been Tested?

visually

Type of Changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation (fix or improvement to the website or code docs)

Checklist

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

@danielchalmers danielchalmers marked this pull request as draft October 15, 2024 19:33
@danielchalmers danielchalmers changed the title wip Buttons: Switch to using a fixed size for layout Oct 15, 2024
@danielchalmers danielchalmers changed the title Buttons: Switch to using a fixed size for layout Buttons: Use fixed size for layout Oct 29, 2024
@danielchalmers
Copy link
Contributor Author

danielchalmers commented Nov 14, 2024

Default heights: Button 36.5px, Icon Button 48px.

Put both in a group (default example):

image

They don't line up due to the button no longer stretching to fix the size of the icon button.

Current:

image

Copy link

sonarcloud bot commented Nov 14, 2024

Copy link

codecov bot commented Nov 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.51%. Comparing base (000fe79) to head (2f2a28c).
Report is 100 commits behind head on dev.

Additional details and impacted files
@@            Coverage Diff             @@
##              dev   #10040       /-   ##
==========================================
  Coverage   91.05%   91.51%    0.46%     
==========================================
  Files         410      413        3     
  Lines       12522    12980      458     
  Branches     2446     2447        1     
==========================================
  Hits        11402    11879      477     
  Misses        570      557      -13     
  Partials      550      544       -6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: In progress
Development

Successfully merging this pull request may close these issues.

MudButton,different language has different height MudIconButton is half a pixel of from MudButton height
1 participant