Skip to content
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

Menu in a fixed toolbar flips direction when window scrollY >= some px threshold #3099

Closed
yasserlens opened this issue Feb 15, 2017 · 3 comments

Comments

@yasserlens
Copy link

yasserlens commented Feb 15, 2017

Bug, feature request, or proposal:

Bug in MdMenu

What is the expected behavior?

Menu panel should respect position-x and position-y attributes. It should also be consistent, not change behavior based on window.scrollY or scrollX.

What is the current behavior?

Menu panel x-position shifts to the left when window.scrollY >= a certain threshold.

What are the steps to reproduce?

  • Menu trigger is in a fixed panel at the top of the page, positioned as follows:
    position: fixed;
    left: 0;
    top: 0;
    z-index: 10;
  • Menu panel is placed in the same container that has the trigger (not that it matters).
  • Menu appears as it should when window.scrollY = 0
  • When window.scrollY >= 169px, menu panel shifts to the left.
  • The threshold is different in the plunkr attached than in the app I have.

Providing a Plunker (or similar) is the best way to get the team to see your issue.
Plunker template: https://plnkr.co/edit/kCCCXUWd1FT5FtZwK8sP?p=preview

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

To fix it!

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

"@angular/material": "^2.0.0-beta.1",
"@angular/core": "^2.4.7",

Chrome Version 55.0.2883.95 (64-bit)
And Android Nexus 5X User Agent

Is there anything else we should know?

@crisbeto
Copy link
Member

This has been fixed by #2677 which should land in the next release. You can give it a try by running npm install https://github.com/angular/material2-builds.git.

@yasserlens
Copy link
Author

Thanks @crisbeto , I can confirm that it is fixed.

@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 Sep 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants