-
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(menu): recompute index before marking selection #5047
fix(menu): recompute index before marking selection #5047
Conversation
Codecov Report
@@ Coverage Diff @@
## master #5047 +/- ##
==========================================
+ Coverage 98.79% 99.09% +0.29%
==========================================
Files 122 122
Lines 5830 5831 +1
Branches 763 763
==========================================
+ Hits 5760 5778 +18
+ Misses 69 52 -17
Partials 1 1
Continue to review full report at Codecov.
|
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.
Thanks for the pull request!
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, need a unit test test/unit/mdc-menu/mdc-menu.test.js
(Preferably without mocks).
Fixed issues with changing menu contents in menus with selectable items. Marking selected items in a menu is deferred until the menu closes, so if the menu contents change before the callback is executed, the wrong item can be marked in the DOM.
b24675a
to
33b9554
Compare
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.
Fixed issues with changing menu contents in menus with selectable items. Marking selected items in a menu is deferred until the menu closes, so if the menu contents change before the callback is executed, the wrong item can be marked in the DOM.