Material: fixed body when open md-select!?

Created on 27 Sep 2016  路  8Comments  路  Source: angular/material

Hi,
How to set disableParentScroll in md-select?
I don`t want disable Scroll in body!

demo invalid

Most helpful comment

I'll give this a +1, but will also add some context of my own:

I have a fixed-position sidebar that stays in view as a user scrolls. As soon as an <md-menu> is clicked (or <md-select>, as noted by @smahdi ), however, because the <body> tag is set to a fixed position, it breaks the positioning of all other fixed-position elements on the page (including my sidebar).

If the reasoning for fixing the <body> position on open is to prevent scroll, I would strongly encourage using a different approach (hidden overflow, for example), as to not break other parts of the layout that rely on fixed positioning.

All 8 comments

issu

I don`t want disable Scroll in body!
please

I'll give this a +1, but will also add some context of my own:

I have a fixed-position sidebar that stays in view as a user scrolls. As soon as an <md-menu> is clicked (or <md-select>, as noted by @smahdi ), however, because the <body> tag is set to a fixed position, it breaks the positioning of all other fixed-position elements on the page (including my sidebar).

If the reasoning for fixing the <body> position on open is to prevent scroll, I would strongly encourage using a different approach (hidden overflow, for example), as to not break other parts of the layout that rely on fixed positioning.

+1
I found this problem, too.
I have my md-select in the right-top conner of the page, and the page has a horizontal scroll bar.
When I open the md-select, the page will scroll to the most left side because of the fixed body position.
How can I make the body do not have a fixed position when open md-select?

@smahdi: I'm curious why you closed this issue; has Angular Material released a fix? If not, could you re-open the issue, as there are a number of us who have also experienced this?

I didn't see this issue before i wrote mine, but it seems to be something close
my issue : #10633

Did anyone found a solution for this?

i am getting this issue , my paretn div position is fixed and i am using md-select inside the parent div . when i click on md-slect the select options will open on top of the page why ?

Thank you for taking the time to submit this issue and sorry for the delay in responding. However it does not follow our required issue template. We need a CodePen demo to be able to debug and fix the issue.

There are also a number of other duplicate issues that are filed that have more complete information and a demo. So I'm going to close this one and work on a fix in one of those other issues.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

robertmesserle picture robertmesserle  路  3Comments

buzybee83 picture buzybee83  路  3Comments

kasajian picture kasajian  路  3Comments

nikhildev picture nikhildev  路  3Comments

Dona278 picture Dona278  路  3Comments