Skip to content
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 cursor behavior when using table dropdown menu #134

Merged
merged 1 commit into from
Jul 22, 2021
Merged

Conversation

abeforgit
Copy link
Member

@abeforgit abeforgit commented Jul 16, 2021

I seem to have finally landed on something that works both in the dummy app and in GN.

Yes, that's an async function to close a dropdown. Yes, it waits for the next paintCycle. It's the only thing I could come up with that worked. There is just too much going on with focus changes and events and whatnot to get any sort of sensible behavior out of it (at least I cant). Maybe Sam has some more ideas, but this is the best I can do.

base branch master, together with #133 is a fix for https://binnenland.atlassian.net/browse/GN-2625

Also refactors the menu a bit with everyone's favourite pattern: contextual components!

@abeforgit abeforgit added the bug Something isn't working label Jul 16, 2021
@abeforgit abeforgit requested review from nvdk and Windvis July 16, 2021 20:32
@abeforgit abeforgit force-pushed the bugfix/toolbar-menu branch from 7033fff to 5e65a7f Compare July 16, 2021 20:42
@abeforgit abeforgit force-pushed the bugfix/toolbar-menu branch from 5e65a7f to d1ad2a9 Compare July 16, 2021 20:43
Copy link
Member

@nvdk nvdk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feels like I've approved the fix for this 10 ten times already :). don't like the paint cycle hack, but don't know a better alternative (though perhaps using embers scheduleOnce might be a bit cleaner).

It seems to be working though, so I'll merge!

@nvdk nvdk merged commit 4d293dc into master Jul 22, 2021
@nvdk nvdk deleted the bugfix/toolbar-menu branch July 22, 2021 11:45
@abeforgit
Copy link
Member Author

It feels like trying to pick the lock on an open door
it should really not be hard
but somehow it is

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants