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

Dropdown menu is clickable even if it's closed #1

Open
avipunes opened this issue Mar 26, 2020 · 1 comment
Open

Dropdown menu is clickable even if it's closed #1

avipunes opened this issue Mar 26, 2020 · 1 comment

Comments

@avipunes
Copy link

avipunes commented Mar 26, 2020

I tried to create a PR but I don't have permissions 😕

the issue:
https://media.giphy.com/media/PhTjbkLmtw4w59NsGY/giphy.mp4

potential solution:

.has-dropdown .dropdown {
    pointer-events: none;
}
@avipunes avipunes changed the title Dropdown menu is clickable even if is closed Dropdown menu is clickable even if it closed Mar 26, 2020
@avipunes avipunes changed the title Dropdown menu is clickable even if it closed Dropdown menu is clickable even if it's closed Mar 26, 2020
@Reshav-Paul
Copy link

another potential solution

.dropdown {
    ...
    visibility: hidden;
    transition: opacity .5s ease-out, visibility .5s;
}
.has-dropdown:focus-within .dropdown {
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants