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

Navigation breaks after login when visiting a collection link #8920

Closed
SensoryDavide opened this issue Oct 29, 2024 · 4 comments · Fixed by #8990
Closed

Navigation breaks after login when visiting a collection link #8920

SensoryDavide opened this issue Oct 29, 2024 · 4 comments · Fixed by #8990
Assignees

Comments

@SensoryDavide
Copy link

Describe the Bug

I found an odd issue with the navigation while trying to customise it. This also happens with a clean installation and the default navigation component.

Slightly related, but not part of this bug: I also noticed the navigation constantly re-rendering when navigating between pages which makes it flicker often and is overall annoying to deal with when customising.

Link to the code that reproduces this issue

https://next-payload-3-0-test.vercel.app

Reproduction Steps

  • Open a direct link to a collection in an icognito tab - simulating a first visit when not logged in (For example: /admin/collections/mycollection?limit=10)
  • You'll see the login form
  • After logging in, on the first load, the redirect logic seems to not work as intended as the navigation is broken, only showing one item. This does not happen when I visit /admin in an icognito tab

Which area(s) are affected? (Select all that apply)

area: ui

Environment Info

Node.js v22.9.0

Binaries:
Node: 20.18.0
npm: 10.8.2
Yarn: N/A
pnpm: 9.5.0
Relevant Packages:
payload: 3.0.0-beta.117
Operating System:
Platform: darwin
Arch: arm64
Version: Darwin Kernel Version 24.0.0: Mon Aug 12 20:52:12 PDT 2024; root:xnu-11215.1.10~2/RELEASE_ARM64_T6020
Available memory (MB): 16384
Available CPU cores: 10

@SensoryDavide SensoryDavide added status: needs-triage Possible bug which hasn't been reproduced yet v3 labels Oct 29, 2024
@paulpopus
Copy link
Contributor

Can you share the repo behind that host please? Couldn't log in and it would be helpful to see the exact config

@SensoryDavide
Copy link
Author

SensoryDavide commented Oct 30, 2024

@paulpopus That's the URL for your Payload 3 Demo at https://github.com/payloadcms/payload-3.0-demo - It's really just as an example, as you can do this on any install. I just tried this on a 100% fresh install via npx create-payload-app@beta -t blank without any config changes. I think some of the redirect logic after login is broken. If I open http://localhost:3001/admin/collections/users?limit=10 in an incognito tab, I don't get redirected to that link after logging in and the navigation only shows the Media collection.

@JessChowdhury JessChowdhury self-assigned this Oct 30, 2024
@github-actions github-actions bot removed the status: needs-triage Possible bug which hasn't been reproduced yet label Oct 30, 2024
DanRibbens pushed a commit that referenced this issue Nov 8, 2024
Closes #8920 - login form does not redirect after form submit.

In `handleAuthRedirect` the route parameter was unintentionally getting
overwritten.
Copy link
Contributor

This issue has been automatically locked.
Please open a new issue if this issue persists with any additional detail.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 10, 2024
@github-actions github-actions bot unlocked this conversation Nov 11, 2024
Copy link
Contributor

🚀 This is included in version v3.0.0-beta.127

@github-actions github-actions bot locked and limited conversation to collaborators Nov 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants