-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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(drawer): Remove list item children to be included in click target. #3480
Conversation
All 353 screenshot tests passed for commit 809750e vs. |
packages/mdc-drawer/common.scss
Outdated
@@ -89,6 +89,12 @@ | |||
.mdc-list-divider { | |||
margin: 3px 0 4px 0; | |||
} | |||
|
|||
// Prevents list item children to be included in click target. |
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.
Prevents list item children from being included in the click target.
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
All 353 screenshot tests passed for commit 32cf901 vs. |
All 357 screenshot tests passed for commit 1772a34 vs. |
All 357 screenshot tests passed for commit c2027a9 vs. |
material-components#3480) (cherry picked from commit cc3ae2f)
Since #3460 adds additional wrapper element to text label inside list item it might be included as click target. In this change, drawer removes the pointer events from list item children including
__text
&__graphic
so click event always originates fromlist-item
instead of its children.The long-term solution would be to have a custom event for MDC List that drawer & menu can listen to.