Fix blob overflow menu permalink shortcut does not get triggered
What does this MR do and why?
This happens when user navigate to the blob page from repository page. This feature was originally added in !181901 (merged) and is behind the blob_overflow_menu feature flag.
References
Please include cross links to any resources that are relevant to this MR. This will give reviewers and future readers helpful context to give an efficient review of the changes introduced.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
| Before | After |
|---|---|
How to set up and validate locally
- Enable
blob_overflow_menuand enableblob_repository_vue_header_appfeature flag
Feature.enable(:blob_overflow_menu)
Feature.enable(:blob_repository_vue_header_app)
- Go to a directory
- Go to a file
- The copied link (when flag is on) and the url in the search bar (when flag is off) should match
- This should work when viewing a file with:
- A branch
- A commit (Select Code > Commits > Select a commit > View file)
- A tag
- In all situations, the last selected line number should be append to the end of the link
- Press
yshould work the same as clicking the dropdown item - Blame button remains in the header and should not be impacted by this change
Related to #452305 (closed)
Edited by Chaoyue Zhao