Skip to content

fix(material/list): use flexbox to size mat-line elements (#19809) #19819

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

Merged
merged 1 commit into from
Jul 11, 2020

Conversation

swseverance
Copy link
Contributor

  • use flex: auto instead of width: 100% to allow .mat-list-text element to take up the available space

stackblitz demonstrating issue

Before
image

After
image

@swseverance swseverance requested a review from jelbourn as a code owner July 1, 2020 11:57
@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Jul 1, 2020
@jelbourn
Copy link
Member

jelbourn commented Jul 1, 2020

Seems okay at first glance, but we'll have to see if this causes any visual diffs inside Google (this process can be pretty slow)

Can you expand on the commit message? Saying "fix layout bug" doesn't really provide enough information about what this change does and why. The format would be something like

fix(material/list): use flexbox to size mat-line elements

<explanation here about why `flex: auto` is better than `width: 100%`>

@jelbourn jelbourn added the P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent label Jul 1, 2020
)

Use `flex: auto` instead of `width: 100%` to size `.mat-list-text` elements. using `width: 100%` can lead to `.mat-list-text` sibling elements shrinking and having their content overflow.
@swseverance swseverance changed the title fix(mat-line): fix layout bug (#19809) fix(material/list): use flexbox to size mat-line elements (#19809) Jul 1, 2020
@swseverance
Copy link
Contributor Author

@jelbourn thanks. I updated the commit message.

Copy link
Member

@jelbourn jelbourn left a comment

Choose a reason for hiding this comment

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

LGTM

@jelbourn jelbourn added lgtm action: merge The PR is ready for merge by the caretaker target: patch This PR is targeted for the next patch release labels Jul 2, 2020
@mmalerba mmalerba merged commit 998bb18 into angular:master Jul 11, 2020
mmalerba pushed a commit that referenced this pull request Jul 11, 2020
…19819)

Use `flex: auto` instead of `width: 100%` to size `.mat-list-text` elements. using `width: 100%` can lead to `.mat-list-text` sibling elements shrinking and having their content overflow.
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Aug 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker cla: yes PR author has agreed to Google's Contributor License Agreement P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants