@xterm/xterm 6.1.0-beta.281 → 6.1.0-beta.283

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@xterm/xterm",
3
3
  "description": "Full xterm terminal, in your browser",
4
- "version": "6.1.0-beta.281",
4
+ "version": "6.1.0-beta.283",
5
5
  "main": "lib/xterm.js",
6
6
  "module": "lib/xterm.mjs",
7
7
  "style": "css/xterm.css",
@@ -119,5 +119,5 @@
119
119
  "ws": "^8.20.0",
120
120
  "xterm-benchmark": "^0.3.2"
121
121
  },
122
- "commit": "2fe3fd13a164f956d0c6a2365fa89feaf4366074"
122
+ "commit": "c8f11d63b5f8b01f4bccbbf4d9bd25ef19e0dfad"
123
123
  }
@@ -1072,10 +1072,6 @@ export class CoreBrowserTerminal extends CoreTerminal implements ITerminal {
1072
1072
  * Clear the entire buffer, making the prompt line the new first line.
1073
1073
  */
1074
1074
  public clear(): void {
1075
- if (this.buffer.ybase === 0 && this.buffer.y === 0) {
1076
- // Don't clear if it's already clear
1077
- return;
1078
- }
1079
1075
  this.buffer.clearAllMarkers();
1080
1076
  this.buffer.lines.set(0, this.buffer.lines.get(this.buffer.ybase + this.buffer.y)!);
1081
1077
  this.buffer.lines.length = 1;
@@ -135,9 +135,10 @@ export class SelectionModel {
135
135
  return true;
136
136
  }
137
137
 
138
- // If the selection start is trimmed, ensure the start column is 0.
138
+ // If the selection start row is trimmed away, reset to the buffer origin.
139
139
  if (this.selectionStart && this.selectionStart[1] < 0) {
140
- this.selectionStart[1] = 0;
140
+ this.selectionStart = [0, 0];
141
+ return true;
141
142
  }
142
143
  return false;
143
144
  }
@@ -704,7 +704,7 @@ export class SelectionService extends Disposable implements ISelectionService {
704
704
  if (this._activeSelectionMode !== SelectionMode.COLUMN) {
705
705
  this._model.selectionEnd[0] = this._bufferService.cols;
706
706
  }
707
- this._model.selectionEnd[1] = Math.min(buffer.ydisp + this._bufferService.rows, buffer.lines.length - 1);
707
+ this._model.selectionEnd[1] = Math.min(buffer.ydisp + this._bufferService.rows - 1, buffer.lines.length - 1);
708
708
  } else {
709
709
  if (this._activeSelectionMode !== SelectionMode.COLUMN) {
710
710
  this._model.selectionEnd[0] = 0;
@@ -6,4 +6,4 @@
6
6
  /**
7
7
  * The xterm.js version. This is updated by the publish script from package.json.
8
8
  */
9
- export const XTERM_VERSION = '6.1.0-beta.281';
9
+ export const XTERM_VERSION = '6.1.0-beta.283';