Line counting in dynamically created diff headers should be more accurate
<!--IssueSummary start--> <details> <summary> Everyone can contribute. [Help move this issue forward](https://handbook.gitlab.com/handbook/marketing/developer-relations/contributor-success/community-contributors-workflows/#contributor-links) while earning points, leveling up and collecting rewards. </summary> - [Close this issue](https://contributors.gitlab.com/manage-issue?action=close&projectId=278964&issueIid=25099) </details> <!--IssueSummary end--> Currently we have the following line counting slightly inaccurate in a few places. ![Screen_Shot_2018-11-06_at_20_05_11](/uploads/b8560a779329270cba2075aa64bf7da2/Screen_Shot_2018-11-06_at_20_05_11.png) 1. When clicking on **...** (once or multiple times) we see it sticking to the `20` value This is the size of blob lines being requested and inserted in the diff lines. But if we're willing to present an accurate value (following git standards) we should calculate how many lines it has until the next match line. So if it has `6` lines before the click and we're expanding `20`, it should be `26`, not `20`. Second click, if we're expanding more `20`, it should be `46`, not `20`. 2. After leaving a comment in an expanded line and reloading the page, the backend creates top and bottom diff headers dynamically (based on comment positions), but the line counts in these headers are not accurate as well in a few scenarios This is being handled by https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/22852.
issue