Fix broken 'Show file contents' button in Rapid Diffs
What does this MR do and why?
This MR fixes broken 'Show file contents' button in Rapid Diffs. This button was not working because the API returned exactly the same collapsed file. In order to fix this we'll apply a boring solution and just show 'View file' button instead. This could be improved in the future with the new API that could send a full blob.
It also changes the behaviour of 'View file' links, now they always open in a new tab.
Screenshots or screen recordings
| Before | After |
|---|---|
| CleanShot_2025-11-04_at_13.03.29_2x | CleanShot_2025-11-04_at_13.01.03_2x |
How to set up and validate locally
- Create a branch with renamed file
- Compare that branch to the origin on compare revisions page
- Observe 'View file' link to appear
- Click that link
- Observe the full blob view of the renamed file