Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

287
Views
How to open menu with hover in Next.js css module?

This is the element in the navbar:

<div className={styles.menu}>
  <button
    className={"a_4"}
    style={{
      color: "white",
      backgroundColor: "transparent",
      borderWidth: "0px",
      cursor: "pointer",
    }}
  >
    {userName}
  </button>
  <Menu />
</div>

I have a style for it, to handle hover:

.menu:hover .menuContainer {
  display: block;
}

and here is have the <Menu>

function Menu() {
  const dispatch = useAppDispatch();
  return (
    <div className={styles.menuContainer}>
      <ul>
        <li className={styles.menuItem}>
          <Link href={"/hu"}>
            <a className={"a_5"}>Profil</a>
          </Link>
        </li>

The problem, hover not open menu. Why? How to fix?

Menu container normally is invisible:

.menuContainer {
  display: none;
  position: absolute;
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!