-
Notifications
You must be signed in to change notification settings - Fork 8
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
Focus the context menu after the position is set #25
Focus the context menu after the position is set #25
Conversation
This fixes the jump of the table when the context menu was opened in a scrolled table. Previously, the focus was set on a context menu positioned in the top left corner of the table which forced the browser to scroll the position to the top left corner. Then, the position of the context menu was correctly set, but the scroll position was already changed. Now, the context menu is positioned correctly first and only then can it be focused. Related to camunda/camunda-modeler#1433
5ebb4c3
to
0f7708f
Compare
Thank you 🦊 |
c144f27
to
0f7708f
Compare
I looked more into this and it seems that the Firefox test failure is caused by a bug in the browser. Even with Firefox 70 the test fails. On the other hand, the bug is gone when tested manually. |
If that is the case we could exclude the failing spec on Firefox. This should be a rare thing to do. And please document it / link to related issues you've found along with the skip. |
Firefox inconsistently fires focus events which causes the tests to fail but in real usage autofocus works correctly. Cf. #25 and linked sources
2672e39
to
f29287d
Compare
Firefox inconsistently fires focus events which causes the tests to fail but in real usage autofocus works correctly. Cf. #25 and linked sources
f29287d
to
6e21af2
Compare
@philippfromme Firefox will no more test the cases where it failed to focus correctly. Please feel free to review now. |
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.
👏
This fixes the jump of the table when the context menu was opened
in a scrolled table. Previously, the focus was set on a context menu
positioned in the top left corner of the table which forced the browser
to scroll the position to the top left corner. Then, the position
of the context menu was correctly set, but the scroll position
was already changed.
Now, the context menu is positioned correctly first and only then
can it be focused.
Related to camunda/camunda-modeler#1433