0

https://codesandbox.io/s/competent-hill-lszyv?file=/src/App.tsx

I'm trying to hide the dropdown menu (the red box) by setting the parent container with overflow:hidden but that doesn't work, how can I achieve this?

2 Answers 2

1

Can hide it depend on open flag.

  {open && <ul className={styles.dropDownList}>
    {localesArr.map((locale, index) => {
      return (
        <li key={`${locale}-${index}`}>
          <a href="/">{locale}</a>
        </li>
      );
    })}
Sign up to request clarification or add additional context in comments.

Comments

0

I fixed by setting the container div to position:relative

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.