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] - DropdownItem missing <li> tag when using href #4147

Closed
kimskovhusandersen opened this issue Nov 25, 2024 · 1 comment · Fixed by #4168
Closed

[BUG] - DropdownItem missing <li> tag when using href #4147

kimskovhusandersen opened this issue Nov 25, 2024 · 1 comment · Fixed by #4168
Assignees
Labels
📦 Scope : Components Related to the components 🐛 Type: Bug Something isn't working

Comments

@kimskovhusandersen
Copy link

NextUI Version

2.4.8

Describe the bug

When passing a value to the href property of the DropdownItem component in NextUI, the component correctly transforms into an <a> tag. However, this change results in the absence of the <li> element within the <ul>. The expected structure should wrap the <a> tag in an <li> for proper semantic HTML.

Your Example Website or App

No response

Steps to Reproduce the Bug or Issue

  • Use the DropdownItem component with the href property set to any valid URL.
  • Inspect the rendered DOM structure.
  • The <li> element is missing.
  • The DropdownItem directly renders an <a> tag inside the <ul>.

Expected behavior

The DropdownItem should render an <li> element that wraps the<a> tag, maintaining semantic HTML.

Screenshots or Videos

No response

Operating System Version

macOS

Browser

Chrome

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📦 Scope : Components Related to the components 🐛 Type: Bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants