Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upMediaObserver on Firefox doesn't correctly detect view-port change when maximizing window #1159
Comments
|
Same problem I have in chrome with custom media points. |
|
MediaObserver on Firefox seems to be a bit buggy in general, see first comment in #1059 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment


Bug Report
What is the expected behavior?
When maximizing a window, the media observer should detect the change in view port width and report the correct query matches.
What is the current behavior?
On Firefox (71.0 64 bit) - when maximizing the window, the media observer reports a conflicting set of query matches, with the original size reported first, as per the below example:
When resizing the window manually by clicking and dragging the edge of the window, this does not occur.
What are the steps to reproduce?
Simply add this section of code to a project and observe the printed array when maximising a window in Firefox.
What is the use-case or motivation for changing an existing behavior?
Mobile styling dependent on the observer aren't being cleared on window re-size.
Which versions of Angular, Material, OS, TypeScript, browsers are affected?
I've only tested it in Firefox (71.0 64 bit). Chrome seems to handle the window resizing fine.
The versions of angular libraries I am using are below: