question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Input components (md-input, md-select, md-checkbox etc) aren't aligned in a flex container...

See original GitHub issue

… without setting align-items: center

Updated Plunk: http://plnkr.co/edit/TgFy04UErh9Xhr0A4XzK?p=preview

md-input behaves differently to md-select (and at least md-checkbox, possibly all the other “input” components) when the elements are within a “flex container”

See this plunk for an example: http://plnkr.co/edit/aLXsp8MlV2AoOkC9aEFP?p=preview

This issue might be resolved with the in-progress refactor of input?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:36
  • Comments:59 (13 by maintainers)

github_iconTop GitHub Comments

19reactions
mmalerbacommented, Aug 2, 2017

Just wanted to give a quick explanation about this and what the hold-up is. The input and select components have been maintained by two different people and over time as fixes were made to one of them in order to make it closer to the spec it didn’t necessarily translate into a fix in the other. At this point there are a lot of things missing from the select that have been added to the input (spacing that matches the material spec, error message support, ability to hire the required marker). In order to make these two components more consistent we want to refactor the select to share a lot more code with the input, but its a fairly large undertaking.

In the mean time I do recommend just adding some margin or padding to the select to make it line up with the input in your app as many here have suggested. After the refactor you should be able to remove the custom margin and have them line up to begin with.

11reactions
atul221282commented, Apr 8, 2017

show stopper for me at the moment capture

Read more comments on GitHub >

github_iconTop Results From Across the Web

Aligning items in a flex container - CSS: Cascading Style Sheets
align -content: space-evenly (not defined in the Flexbox specification). In the live example below, the flex container has a height of 400 pixels ......
Read more >
md-input-container and label not aligned - Stack Overflow
I am trying to create a filter for price, and I am stuck on aligning these elements correctly. With this code: <div formGroupName="price....
Read more >
Flex Cheatsheet
A flex container establishes a new flex formatting context for its contents. This is the same as establishing a block formatting context, except...
Read more >
A Complete Guide to Flexbox | CSS-Tricks
This complete guide explains everything about flexbox, focusing on all the different possible properties for the parent element (the flex ...
Read more >
Understanding Flexbox: Everything you need to know
Learning Flexbox may not be fun at first. It will challenge what you know ... Flex items : The children elements within a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found