Skip to content

After selecting an option on md-select it does not adjust width while resizing window #2711

Closed
@jfletcher2

Description

@jfletcher2

Bug, feature request, or proposal:

Bug

What is the expected behavior?

Once the user selects a value on md-select and the browser window is resized the md-select element should adjust its width accordingly. md-input works fine.

What is the current behavior?

The md-select width is not adjusted correctly when the browser window is re-sized.
Full Size window:
full-size

Resized window:
resize_issue

What are the steps to reproduce?

Plunker: http://plnkr.co/edit/DiPQWnqp76znq27BmXuj?p=preview

  1. If we try resizing the preview window without choosing any options on both "Select Option 1" and "Select Option 2", it should work fine.
  2. Choose an option for "Select Option 1" and "Select Option 2" and then try to resize. The select element does not adjust its width automatically like it did when none of the options were selected.

What is the use-case or motivation for changing an existing behavior?

The field alignment for md-select is thrown off when the user tries to resize the page.

Which versions of Angular, Material, OS, browsers are affected?

Angular Material (SHA 899f190)
Browser: Chrome

Metadata

Metadata

Assignees

No one assigned

    Labels

    P4A relatively minor issue that is not relevant to core functionsarea: material/select

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions