This repository was archived by the owner on Jan 6, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 763
This repository was archived by the owner on Jan 6, 2025. It is now read-only.
Sub-Pixel calculation issue #1001
Copy link
Copy link
Closed
Labels
P5Low-priority issue that needs considerationLow-priority issue that needs considerationdiscussionFurther discussion with the team is needed before proceedingFurther discussion with the team is needed before proceedinghas prA PR has been created to address this issueA PR has been created to address this issuehelp wantedThe team would appreciate a PR from the community to address this issueThe team would appreciate a PR from the community to address this issue
Milestone
Description
Bug Report
What is the expected behavior?
No problems caused by subpixel calculations by browsers.
What is the current behavior?
If the browser ends up with the width of the viewport set to something like 1279.5px then neither the md nor the lg breakpoints match.
What are the steps to reproduce?
Here's a codepen showing the issue using basic CSS but same applies to this library: https://codepen.io/anon/pen/VqoGXP
What is the use-case or motivation for changing an existing behavior?
This really starts to apply to higher density screens with scaling turned of (such as a 2160p monitor with Windows set to 150% scaling and using 2 browsers on each half of the screen).
Which versions of Angular, Material, OS, TypeScript, browsers are affected?
All.
Is there anything else we should know?
The fix is pretty simple, just add .9999
to the end of all the pixel values that are 1px less than the next break point (e.g. the md breakpoint max-width would be set to 1279.9999px).
Metadata
Metadata
Assignees
Labels
P5Low-priority issue that needs considerationLow-priority issue that needs considerationdiscussionFurther discussion with the team is needed before proceedingFurther discussion with the team is needed before proceedinghas prA PR has been created to address this issueA PR has been created to address this issuehelp wantedThe team would appreciate a PR from the community to address this issueThe team would appreciate a PR from the community to address this issue