Skip to content

Diff list auto scroll to current file

  • Please check this box if this contribution uses AI-generated content (including content generated by GitLab Duo features) as outlined in the GitLab DCO & CLA. As a benefit of being a GitLab Community Contributor, you can request access to GitLab Duo.

What does this MR do and why?

When there are too many changed files, it's difficult to match the files being viewed with the files in the file tree. So, I made it so that when you click on the file being viewed on the right, the file tree on the left will scroll to it.

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 录屏2024-10-07_11.17.37 After 录屏2024-10-07_11.18.43

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Create a repo and touch multi files like 1.txt, 2.txt and so on.
  2. Create a new branch and push it to remote
  3. Create a merge request
  4. Check merge request "Changes"
  5. Click file you are viewing on the right, and file tree on the left will scroll to it.
Edited by gang huang

Merge request reports

Loading