Skip to content
This repository has been archived by the owner on Sep 5, 2024. It is now read-only.

fix(input): remove 2px left padding on inputs #11421

Closed
wants to merge 1 commit into from

Conversation

codymikol
Copy link
Contributor

@codymikol codymikol commented Aug 19, 2018

remove 2px of padding-left from input boxes as this does not follow the material design spec

Fixes #10105

PR Checklist

Please check that your PR fulfills the following requirements:

  • The commit message follows our guidelines
  • Tests for the changes have been added or this is not a bug fix / enhancement
  • Docs have been added, updated, or were not required

PR Type

What kind of change does this PR introduce?

[x] Bugfix
[ ] Enhancement
[ ] Documentation content changes
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Infrastructure changes
[ ] Other... Please describe:

What is the current behavior?

Currently input boxes have 2px of padding-left. The material design spec has no left padding.

before_fix

According to the original material design spec only top and bottom padding should exist on input fields.

spec

Issue Number: #10105

What is the new behavior?

The 2px of left padding have been removed.

after_fix

Does this PR introduce a breaking change?

[x] Yes
[ ] No

This will change the styling of input components, although a minor change, anyone who has styled specifically around this may need to make minor changes to their own styles.

Other information

It does not seem that autocomplete or datepicker have this extra padding and they don't seem to be using the modified class. It seems that the only affected component will be input and all the other components are following the spec.

remove 2px of padding-left from input boxes as this does not follow the material design spec

Fixes angular#10105
@googlebot googlebot added the cla: yes PR author has signed Google's CLA: https://opensource.google.com/docs/cla/ label Aug 19, 2018
@Splaktar Splaktar self-assigned this Aug 29, 2018
@Splaktar Splaktar self-requested a review August 29, 2018 01:42
@Splaktar Splaktar added needs: review This PR is waiting on review from the team ui: CSS - Breaking Change P4: minor Minor issues. May not be fixed without community contributions. labels Aug 29, 2018
@Splaktar Splaktar added this to the 1.2.0 milestone Aug 29, 2018
Copy link
Member

@Splaktar Splaktar left a comment

Choose a reason for hiding this comment

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

LGTM. Can you please add a before and after screenshot? Also a screenshot from the MD spec to compare against would be helpful.

Thank you!

@Splaktar Splaktar added pr: lgtm This PR has been approved by the reviewer type: spec alignment For issues related to aligning with the Material Design Spec and removed needs: review This PR is waiting on review from the team labels Aug 29, 2018
@codymikol
Copy link
Contributor Author

@Splaktar Added screenshots to the PR for documentation

@Splaktar Splaktar added P3: important Important issues that really should be fixed when possible. and removed P4: minor Minor issues. May not be fixed without community contributions. labels May 28, 2020
Splaktar added a commit that referenced this pull request May 28, 2020
@Splaktar
Copy link
Member

I found some addition cases that this does not cover with both md-input and md-select. I've posted PR #11921 that covers them. I think that it also handles RTL/LTR a little better.

@Splaktar Splaktar removed the pr: lgtm This PR has been approved by the reviewer label May 28, 2020
Splaktar added a commit that referenced this pull request Jun 29, 2020
Fixes #10105. Closes #11421.

BREAKING CHANGE: `md-input` and `md-select` inside of `md-input-container`s have been updated to use indentation that is consistent with the spec (aligned to the left in LTR and the right in RTL). This may cause some minor layout issues in apps that depended upon the previous `2px` padding inside of `md-input-container`.
Splaktar added a commit that referenced this pull request Jun 29, 2020
Fixes #10105. Closes #11421.

BREAKING CHANGE: `md-input` and `md-select` inside of `md-input-container`s have been updated to use indentation that is consistent with the spec (aligned to the left in LTR and the right in RTL). This may cause some minor layout issues in apps that depended upon the previous `2px` padding inside of `md-input-container`.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
- Breaking Change cla: yes PR author has signed Google's CLA: https://opensource.google.com/docs/cla/ P3: important Important issues that really should be fixed when possible. type: spec alignment For issues related to aligning with the Material Design Spec ui: CSS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

input: indentation different from the Material Design spec
3 participants