-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Fix(cdk/overlay) : adaptation of clientRect according to the zoom level #20467
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
Fix(cdk/overlay) : adaptation of clientRect according to the zoom level #20467
Conversation
Fixed a bug on the cdk/overlay that was incorrectly positioned when the parent element contained a zoom level different from 1. The zoom level is applied on the bottom, left and top properties in order to adapt the positioning. Fixes angular#10924
I think it's a bad idea to use the css "zoom" property since it's not standard but maybe the people who commented the ticket need it for a reason I don't know. I wonder if they would be better off using |
@Gwe-n yeah, I'm not sure we'd want to add handling for this since the property is non-standard, having now looked at the original issue more closely. Adding this support increases the complexity of the code and would require corresponding tests. |
To add to what was said above, we'd basically have to do it for all places where |
I don't think there's a problem with the browser zoom on this subject, am I wrong? |
Ah sorry, I think I misremembered #10924 for being about the native browser zoom. I just double-checked it and it works fine. |
@Gwe-n This happens also with |
@nlevari If I take the initial problem with the stackblitz example, and apply a https://stackblitz.com/edit/cdk-overlay-zoom-fugydj But maybe I didn't understand the whole problem. If you also have the issue with transform, can you provide a sample code? Thank you. (are you sure we are talking about the same problem? because I have the impression that you are talking about applying a scale to the body) |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Fixed a bug on the cdk/overlay that was incorrectly positioned when the parent element contained a zoom level different from 1. The zoom level is applied on the bottom, left and top properties in order to adapt the positioning.
Fixes #10924