-
Notifications
You must be signed in to change notification settings - Fork 6.7k
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): overriding pointer-events style #21666
fix(cdk/overlay): overriding pointer-events style #21666
Conversation
We set `pointer-events: auto` on the overlay when it is attached and then `none` while it's detaching which ends up overriding any other styles the user might have. These changes reset to `''` instead. Fixes angular#21656.
@@ -368,7 +368,7 @@ export class OverlayRef implements PortalOutlet, OverlayReference { | |||
|
|||
/** Toggles the pointer events for the overlay pane element. */ | |||
private _togglePointerEvents(enablePointer: boolean) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was debating renaming this at the same time to _disablePointerEvents
since it never really does enable them anymore, it just disables or defaults...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO "toggle" still makes sense since the default is for them to be enabled.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The default is in a css class though, this code really doesn't know and shouldn't care what that default is. Just my opinion though 🤷
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
We set `pointer-events: auto` on the overlay when it is attached and then `none` while it's detaching which ends up overriding any other styles the user might have. These changes reset to `''` instead. Fixes angular#21656.
We set `pointer-events: auto` on the overlay when it is attached and then `none` while it's detaching which ends up overriding any other styles the user might have. These changes reset to `''` instead. Fixes angular#21656.
We set `pointer-events: auto` on the overlay when it is attached and then `none` while it's detaching which ends up overriding any other styles the user might have. These changes reset to `''` instead. Fixes angular#21656.
We set `pointer-events: auto` on the overlay when it is attached and then `none` while it's detaching which ends up overriding any other styles the user might have. These changes reset to `''` instead. Fixes angular#21656.
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. |
We set
pointer-events: auto
on the overlay when it is attached and thennone
while it's detaching which ends up overriding any other styles the user might have. These changes reset to''
instead.Fixes #21656.