Skip to content

Web IDE loses location when switching between files

Summary

When reviewing an MR in the Web IDE, editor tabs do not remember their file location when switching between files. This is especially annoying when attempting to reference other files while reviewing as you have to re-find your place when you switch back to the initial file.

Steps to reproduce

  1. Create a merge request affecting multiple files with ~300+ lines in at least one file
  2. Open the Web IDE view
  3. Scroll down in one of the files
  4. Switch to another file
  5. Switch back to the original file; position is reset to top

Example Project

Project: https://gitlab.com/mrburrito/web-ide-scroll-issue

MR exhibiting behavior: mrburrito/web-ide-scroll-issue!1

What is the current bug behavior?

When switching tabs in the Web IDE, file position is reset to line 1.

What is the expected correct behavior?

File position is maintained when returning to a file that was previously viewed. If I have scrolled to line 200 in File1, that scroll position should be remembered after I've viewed File2 and returned to File1.

Output of checks

This bug happens on GitLab.com

Edited by Gordon Shankman