Skip to content

Commit c0e2b55

Browse files
authored
Merge pull request #812 from vlad0337187/patch-1
fix(lib.minimap): scroll by drag if scrollPastEnd
2 parents 2eedb48 + 6787ffb commit c0e2b55

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/minimap.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -647,7 +647,8 @@ export default class Minimap {
647647
* @returns {number} The height of the minimap
648648
*/
649649
getHeight() {
650-
return this.textEditor.getScreenLineCount() * this.getLineHeight()
650+
const additionalHeight = this.scrollPastEnd ? this.textEditor.getRowsPerPage() : 0
651+
return (this.textEditor.getScreenLineCount() + additionalHeight) * this.getLineHeight()
651652
}
652653

653654
/**

0 commit comments

Comments
 (0)