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

[BUG] - Popup menubar not hidden when resizing browser window #99

Closed
Xinyu-Li-123 opened this issue Nov 22, 2024 · 3 comments
Closed

[BUG] - Popup menubar not hidden when resizing browser window #99

Xinyu-Li-123 opened this issue Nov 22, 2024 · 3 comments
Assignees
Labels
test required Changes needs to be tested

Comments

@Xinyu-Li-123
Copy link

Describe the bug
I'm unsure if this is a bug or intended behavior. On a post page, resizing the browser to a smaller window reveals a menu button at the bottom right. Clicking it opens a menubar in the same corner. However, resizing back to a larger window hides the menu button but leaves the menubar visible. The only way to close the menubar is to resize back to a small window and click the menu button again.

To Reproduce
The official website of hermit-v2 should be enough to reproduce the bug.

  1. Go to any webpage with a header at the bottom. For example, this page from the official website.
  2. Resize your browser window small enough to make the menu button appear in the header
  3. Click the menu button to call out the popup menubar
  4. Resize your browser window big enough to make the menu button disappear.
  5. Spot the error. You should see the popup menubar still there, and you can't close it.

Expected behavior
After step 3 above, the menubar should be hidden when the window is resized to be large, and appear when resized to be small.

Screenshots
Resized to a small window, the menu button will appear at the bottom left in the header.
Screenshot from 2024-11-22 18-37-02

Click the menu button at the bottom right, and a menubar will pop up:
Screenshot from 2024-11-22 18-52-35

Resize to a large window, and the menubar is still there:
Screenshot from 2024-11-22 18-38-17

Hugo (please complete the following information):

  • Latest hermit-V2 theme package? Yes.
    This bug should be reproducible on the official website of hermit-v2 as I tested on 2024/11/22.
@Xinyu-Li-123 Xinyu-Li-123 added the bug Something isn't working label Nov 22, 2024
@1bl4z3r
Copy link
Owner

1bl4z3r commented Nov 24, 2024

Hi @Xinyu-Li-123,

Thanks for bringing this to my attention.

This happens because the components which were active in small width screen remains active unless the page is refreshed, upon which it takes on components which are actually used in wide screen. And vice versa.

This is because I haven't touched it from original theme and to be frank I didn't test it out myself and didn't consider a viable case.

Nonetheless, I will look into this.

github-actions bot pushed a commit that referenced this issue Nov 28, 2024
@1bl4z3r 1bl4z3r added test required Changes needs to be tested and removed bug Something isn't working labels Nov 28, 2024
@1bl4z3r
Copy link
Owner

1bl4z3r commented Nov 28, 2024

Hi @Xinyu-Li-123,

I have pushed a fix. If you have time, you may test it out and report; It's working from my end, but a second opinion is always good.

@Xinyu-Li-123
Copy link
Author

Yes, it works on my side as well. Thank you for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
test required Changes needs to be tested
Projects
None yet
Development

No branches or pull requests

2 participants