Skip to content

Commit

Permalink
Remove scroll bar when setting fixed dimensions to dynamic
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyriar committed Nov 5, 2021
1 parent cedaa04 commit 9419cdc
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1621,7 +1621,11 @@ export class TerminalInstance extends Disposable implements ITerminalInstance {
return;
}
this._fixedRows = this._parseFixedDimension(rows);
this._addScrollbar();
if (this._fixedRows || this._fixedCols) {
this._addScrollbar();
} else {
this._removeScrollbar();
}
this._resize();
this.focus();
}
Expand Down Expand Up @@ -1696,6 +1700,7 @@ export class TerminalInstance extends Disposable implements ITerminalInstance {
}
this._horizontalScrollbar.setScrollDimensions({
width: this.xterm.raw.element.clientWidth,
// TODO: Use const/property for padding
scrollWidth: this._fixedCols * charWidth + 30
});
this._horizontalScrollbar.getDomNode().style.paddingBottom = '16px';
Expand Down

0 comments on commit 9419cdc

Please sign in to comment.