feat: socket error handling

* create a new session when failed to connect to socket
* reset termnal on connect
This commit is contained in:
wancat committed 2023-10-30 23:31:58 +08:00
1 parent 9c3c6adb16
commit 252781477a
4 files changed
+39 -31

No files matched your search

+6 -2
View File
@@ -33,6 +33,10 @@ class SocketTerminal {
this.term.onData(callback)
}
focus() {
this.term.focus()
}
resizeScreen() {
this.fitAddon.fit()
}
@@ -43,8 +47,8 @@ class SocketTerminal {
this.resizeScreen()
}
clear() {
this.term.clear()
reset() {
this.term.reset()
}
}