nextui-org / nextui

🚀 Beautiful, fast and modern React UI library.
https://nextui.org
MIT License
21.58k stars 1.41k forks source link

[BUG] - Listbox Item href causes full reload (regression) #3784

Open TheCodeDestroyer opened 1 week ago

TheCodeDestroyer commented 1 week ago

NextUI Version

2.4.8

Describe the bug

When navigating via Listbox it causes full page reload. This seemed to be an issue in v2.4.0, but supposedly was fixed in "@nextui-org/link": "0.0.0-canary-20240529193819". Initial issue: #3105

Your Example Website or App

https://codesandbox.io/p/devbox/nextjs-ui-46j3v2

Steps to Reproduce the Bug or Issue

You can clearly see that the links on the left (using listbox) reload the whole page, while the links on left (using Link) only do it clientside

Expected behavior

As a user I want the ListboxItem links to properly use client side navigation if NextUIProvider is properly defined

Screenshots or Videos

No response

Operating System Version

macOS

Browser

Chrome

wingkwong commented 1 week ago

suggest to revisit after RA version bump. I think there's something changed internally on their side.

TheCodeDestroyer commented 1 week ago

suggest to revisit after RA version bump. I think there's something changed internally on their side.

@wingkwong pardon my ignorance, but which lib is RA?

wingkwong commented 1 week ago

React Aria. NextUI is built on top of it.

hardchor commented 3 days ago

Updating @react-aria/utils to 3.25.2 fixed it for me.

My package.json:

{
...
  "resolutions": {
    "@react-aria/utils": "^3.25.2"
  },
}

NB: This might be a yarn-specific feature, check how to override transitive dependencies in your favourite package manager (e.g. overrides in npm)