fix(projects): keep the case study back button on the site - #142
Open
nourshoreibah wants to merge 2 commits into
Open
fix(projects): keep the case study back button on the site#142nourshoreibah wants to merge 2 commits into
nourshoreibah wants to merge 2 commits into
Conversation
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>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
navigate(-1)blindly, which sent visitors off-site when they landed directly from a search result or shared link./projectswhen 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.