Skip to content

Commit d3bcec8

Browse files
committed
fix error on multiple echo #878
1 parent 8f34ed8 commit d3bcec8

7 files changed

+20
-10
lines changed

CHANGELOG.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,14 @@
66
* add `--line-thickness` CSS variable to cursor animation
77
* improve performance with long typing animations [#820](https://github.com/jcubic/jquery.terminal/issues/820)
88
### Bugfix
9-
* fix \t characters in ascii_table [#902](https://github.com/jcubic/jquery.terminal/issues/902)
9+
* fix `\t` characters in ascii_table [#902](https://github.com/jcubic/jquery.terminal/issues/902)
1010
* fix race condition in refresh and flush [#897](https://github.com/jcubic/jquery.terminal/issues/897)
1111
* always execute function prompt after login [#898](https://github.com/jcubic/jquery.terminal/issues/898)
1212
* fix background color in prompt [#906](https://github.com/jcubic/jquery.terminal/issues/906)
1313
* update prism code to match function Prism.highlight [#905](https://github.com/jcubic/jquery.terminal/issues/905)
1414
* fix keepWords during typing animation [#867](https://github.com/jcubic/jquery.terminal/issues/867)
1515
* fix leading spaces during animation [#825](https://github.com/jcubic/jquery.terminal/issues/825)
16+
* fix edge case of of multiple echo with `newline: false` [#878](https://github.com/jcubic/jquery.terminal/issues/878)
1617

1718
## 2.37.2
1819
### Bugfix

js/jquery.terminal-2.37.2.js

+5-2
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
*
4242
* broken image by Sophia Bai from the Noun Project (CC-BY)
4343
*
44-
* Date: Sat, 30 Dec 2023 19:15:48 +0000
44+
* Date: Wed, 31 Jan 2024 13:30:30 +0000
4545
*/
4646
/* global define, Map, BigInt */
4747
/* eslint-disable */
@@ -1709,6 +1709,9 @@
17091709
};
17101710
// -------------------------------------------------------------------------
17111711
OutputLines.prototype.get_partial = function() {
1712+
if (!this._snapshot.length) {
1713+
return [];
1714+
}
17121715
var last = this._snapshot[this._snapshot.length - 1];
17131716
return last;
17141717
};
@@ -5283,7 +5286,7 @@
52835286
// -------------------------------------------------------------------------
52845287
$.terminal = {
52855288
version: 'DEV',
5286-
date: 'Sat, 30 Dec 2023 19:15:48 +0000',
5289+
date: 'Wed, 31 Jan 2024 13:30:30 +0000',
52875290
// colors from https://www.w3.org/wiki/CSS/Properties/color/keywords
52885291
color_names: [
52895292
'transparent', 'currentcolor', 'black', 'silver', 'gray', 'white',

js/jquery.terminal-2.37.2.min.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

js/jquery.terminal-src.js

+3
Original file line numberDiff line numberDiff line change
@@ -1709,6 +1709,9 @@
17091709
};
17101710
// -------------------------------------------------------------------------
17111711
OutputLines.prototype.get_partial = function() {
1712+
if (!this._snapshot.length) {
1713+
return [];
1714+
}
17121715
var last = this._snapshot[this._snapshot.length - 1];
17131716
return last;
17141717
};

js/jquery.terminal.js

+5-2
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
*
4242
* broken image by Sophia Bai from the Noun Project (CC-BY)
4343
*
44-
* Date: Sat, 30 Dec 2023 19:15:48 +0000
44+
* Date: Wed, 31 Jan 2024 13:30:30 +0000
4545
*/
4646
/* global define, Map, BigInt */
4747
/* eslint-disable */
@@ -1709,6 +1709,9 @@
17091709
};
17101710
// -------------------------------------------------------------------------
17111711
OutputLines.prototype.get_partial = function() {
1712+
if (!this._snapshot.length) {
1713+
return [];
1714+
}
17121715
var last = this._snapshot[this._snapshot.length - 1];
17131716
return last;
17141717
};
@@ -5283,7 +5286,7 @@
52835286
// -------------------------------------------------------------------------
52845287
$.terminal = {
52855288
version: 'DEV',
5286-
date: 'Sat, 30 Dec 2023 19:15:48 +0000',
5289+
date: 'Wed, 31 Jan 2024 13:30:30 +0000',
52875290
// colors from https://www.w3.org/wiki/CSS/Properties/color/keywords
52885291
color_names: [
52895292
'transparent', 'currentcolor', 'black', 'silver', 'gray', 'white',

js/jquery.terminal.min.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

js/jquery.terminal.min.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)