Skip to content

fix(projects): keep the case study back button on the site - #142

Open
nourshoreibah wants to merge 2 commits into
mainfrom
worktree-project-back-nav
Open

fix(projects): keep the case study back button on the site#142
nourshoreibah wants to merge 2 commits into
mainfrom
worktree-project-back-nav

Conversation

@nourshoreibah

Copy link
Copy Markdown
  • Case study back button no longer calls navigate(-1) blindly, which sent visitors off-site when they landed directly from a search result or shared link.
  • Falls back to /projects when the case study is the first entry in the history stack; otherwise still returns to the previous in-app page.

Tested locally using mock data.

nourshoreibah and others added 2 commits August 24, 2026 22:27
The back button called navigate(-1) unconditionally, so a visitor who
landed on a case study directly — from a search result or a shared link —
was sent off the site instead of into it.

Fall back to /projects when the router's history index is 0, which means
the case study is the first entry in the session and there is no earlier
in-app page to return to.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant