@xterm/xterm 6.1.0-beta.275 → 6.1.0-beta.277

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.275",
4
+ "version": "6.1.0-beta.277",
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": "64718444e2c27a4e005afbaab7993c52975c14e7"
122
+ "commit": "0c8271db4998a9ac5a164714e8b5054b444b3f31"
123
123
  }
@@ -100,6 +100,7 @@ export class CharacterJoinerService implements ICharacterJoinerService {
100
100
 
101
101
  const ranges: [number, number][] = [];
102
102
  const lineStr = line.translateToString(true);
103
+ const trimmedLength = line.getTrimmedLength();
103
104
 
104
105
  // Because some cells can be represented by multiple javascript characters,
105
106
  // we track the cell and the string indexes separately. This allows us to
@@ -111,7 +112,7 @@ export class CharacterJoinerService implements ICharacterJoinerService {
111
112
  let rangeAttrFG = line.getFg(0);
112
113
  let rangeAttrBG = line.getBg(0);
113
114
 
114
- for (let x = 0; x < line.getTrimmedLength(); x++) {
115
+ for (let x = 0; x < trimmedLength; x++) {
115
116
  line.loadCell(x, this._workCell);
116
117
 
117
118
  if (this._workCell.getWidth() === 0) {
@@ -147,7 +148,7 @@ export class CharacterJoinerService implements ICharacterJoinerService {
147
148
  }
148
149
 
149
150
  // Process any trailing ranges.
150
- if (this._bufferService.cols - rangeStartColumn > 1) {
151
+ if (trimmedLength - rangeStartColumn > 1) {
151
152
  const joinedRanges = this._getJoinedRanges(
152
153
  lineStr,
153
154
  rangeStartStringIndex,
@@ -216,7 +217,8 @@ export class CharacterJoinerService implements ICharacterJoinerService {
216
217
  return;
217
218
  }
218
219
 
219
- for (let x = startCol; x < this._bufferService.cols; x++) {
220
+ const trimmedLength = line.getTrimmedLength();
221
+ for (let x = startCol; x < trimmedLength; x++) {
220
222
  const width = line.getWidth(x);
221
223
  const length = line.getString(x).length || WHITESPACE_CELL_CHAR.length;
222
224
 
@@ -264,7 +266,7 @@ export class CharacterJoinerService implements ICharacterJoinerService {
264
266
  // If there is still a range left at the end, it must extend all the way to
265
267
  // the end of the line.
266
268
  if (currentRange) {
267
- currentRange[1] = this._bufferService.cols;
269
+ currentRange[1] = trimmedLength;
268
270
  }
269
271
  }
270
272
 
@@ -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.275';
9
+ export const XTERM_VERSION = '6.1.0-beta.277';