From ec7ea4df8a2d937163e9b4ad1d55c54e96a13cf1 Mon Sep 17 00:00:00 2001 From: vapao Date: Sat, 9 Jul 2022 19:43:36 +0800 Subject: [PATCH] =?UTF-8?q?U=20=E4=BC=98=E5=8C=96=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- spug_web/src/pages/ssh/Terminal.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spug_web/src/pages/ssh/Terminal.js b/spug_web/src/pages/ssh/Terminal.js index d6d70bf..3fabfe1 100644 --- a/spug_web/src/pages/ssh/Terminal.js +++ b/spug_web/src/pages/ssh/Terminal.js @@ -42,7 +42,7 @@ function WebSSH(props) { fitPlugin.fit(); }; socket.onclose = e => { - setTimeout(() => term.write('\r\nConnection is closed.\r\n'), 200) + setTimeout(() => term.write('\r\n\r\n\x1b[31mConnection is closed.\x1b[0m\r\n'), 200) }; term.onData(data => socket.send(JSON.stringify({data}))); term.onResize(({cols, rows}) => {