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

Menu and Popover don't close on button click #7

Closed
kengreim opened this issue Aug 30, 2023 · 3 comments · Fixed by #8
Closed

Menu and Popover don't close on button click #7

kengreim opened this issue Aug 30, 2023 · 3 comments · Fixed by #8
Assignees
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@kengreim
Copy link

Neither the HeadlessUI Menu nor Popover components are closing when their respective buttons are clicked, as tested on the examples on https://ignis.dvolper.dev/docs/components/headlessUI/. I get the same behavior on both Chrome 116.0.5845.111 and Firefox 117.0.

I think it is because the Click() functions are calling Open() only, instead of checking Menu state and toggling?

PopoverButton.Click():

MenuButton.Click():

@DavidVollmers
Copy link
Owner

Good point! I will update this as soon as possible. But probably not before tomorrow.

@DavidVollmers DavidVollmers added bug Something isn't working good first issue Good for newcomers labels Aug 30, 2023
@DavidVollmers DavidVollmers self-assigned this Aug 30, 2023
@DavidVollmers
Copy link
Owner

Reminder for myself: Adding a trailing slash to a website URL breaks the link. (Probably the static web app configuration)

DavidVollmers added a commit that referenced this issue Aug 31, 2023
@DavidVollmers DavidVollmers linked a pull request Aug 31, 2023 that will close this issue
DavidVollmers added a commit that referenced this issue Aug 31, 2023
* toggle menu, listbox and popover when clicking the button instead of just opening it

* add tests for #7
@DavidVollmers
Copy link
Owner

This is fixed in version 0.8.3.

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

Successfully merging a pull request may close this issue.

2 participants