vercel / next.js

The React Framework
https://nextjs.org
MIT License
125.69k stars 26.84k forks source link

Parallel + Intercepting Route (Modal) does not trigger Catch All route in all cases #62948

Closed steve-marmalade closed 6 months ago

steve-marmalade commented 7 months ago

Link to the code that reproduces this issue

https://github.com/marmalade-labs/modal-catchall-repro

To Reproduce

  1. Start the development server or visit: https://modal-catchall-repro.vercel.app/for-you
  2. If you click on "Open Modal", a very stripped down "modal" will appear
  3. If you click on "Profile Link", you will be sent to another page, but the "modal" will still be showing
  4. To demonstrate it's not a truly boneheaded configuration error on my part, I have also included a link to another page, Trending, which does trigger the catch-all route and close the modal.

Current vs. Expected behavior

I expect that the modal is closed when clicking on "Profile Link", just as it is when clicking on "Trending Link".

Provide environment information

Operating System:
  Platform: linux
  Arch: x64
  Version: #1 SMP PREEMPT_DYNAMIC Sun, 03 Mar 2024 00:30:36 +0000
  Available memory (MB): 31886
  Available CPU cores: 8
Binaries:
  Node: 18.18.2
  npm: 10.5.0
  Yarn: 1.22.21
  pnpm: 7.14.2
Relevant Packages:
  next: 14.2.0-canary.4 // Latest available version is detected (14.2.0-canary.4).
  eslint-config-next: N/A
  react: 18.2.0
  react-dom: 18.2.0
  typescript: 5.1.3
Next.js Config:
  output: N/A

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

App Router, Routing (next/router, next/navigation, next/link)

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

next dev (local), next start (local), Vercel (Deployed)

Additional context

https://github.com/vercel/next.js/assets/85196623/bced05e7-d1e1-4b9b-99f0-a1134ce20fbf

NEXT-2728

steve-marmalade commented 7 months ago

@ztanner - just checking on in this. I notice you added the linear: next label. Does that mean that fixing this bundler edge-case has been slotted into the next sprint?

sKopheK commented 7 months ago

can confirm that it does only work on local environment (both dev and build), but not on deployed version on vercel - slot content is still visible, but not interactive

dennis-gonzales commented 6 months ago

can replicate this issue.

my use case is same with the op where I need to use [...catchAll] to intercept routes and display the modal.

/ works with just (.) /foobar works using (.)foobar and (.)[slug] but not (.)[...catchAll]

steve-marmalade commented 6 months ago

@ztanner is a god cranking through all of the Parallel Routes issues. Just doing my part to confirm that this issue still persists in v14.2.0-canary.47 and v14.2.0-canary.48

github-actions[bot] commented 5 months ago

This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.