@tangle-network/sandbox-ui 0.23.4 → 0.24.0
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/dist/{chunk-AG7QDC2Q.js → chunk-77WVVJA4.js} +118 -35
- package/dist/hooks.d.ts +19 -9
- package/dist/hooks.js +1 -1
- package/dist/index.js +1 -1
- package/dist/pages.d.ts +56 -2
- package/dist/pages.js +832 -649
- package/dist/terminal.d.ts +7 -1
- package/dist/terminal.js +5 -3
- package/package.json +1 -1
package/dist/terminal.d.ts
CHANGED
|
@@ -39,8 +39,14 @@ interface TerminalViewProps {
|
|
|
39
39
|
prompt?: string;
|
|
40
40
|
/** Whether the terminal tab is currently active and visible. */
|
|
41
41
|
isActive?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Stable id reused across remounts so the sidecar restores the same
|
|
44
|
+
* PTY session instead of spawning a fresh shell. Omit for a new
|
|
45
|
+
* session per mount.
|
|
46
|
+
*/
|
|
47
|
+
connectionId?: string;
|
|
42
48
|
}
|
|
43
49
|
declare const DEFAULT_TERMINAL_THEME: TerminalTheme;
|
|
44
|
-
declare function TerminalView({ apiUrl, token, theme, title, subtitle, isActive, }: TerminalViewProps): react_jsx_runtime.JSX.Element;
|
|
50
|
+
declare function TerminalView({ apiUrl, token, theme, title, subtitle, isActive, connectionId, }: TerminalViewProps): react_jsx_runtime.JSX.Element;
|
|
45
51
|
|
|
46
52
|
export { DEFAULT_TERMINAL_THEME, type TerminalTheme, TerminalView, type TerminalViewProps };
|
package/dist/terminal.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
usePtySession
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-77WVVJA4.js";
|
|
4
4
|
|
|
5
5
|
// src/terminal/terminal-view.tsx
|
|
6
6
|
import "@xterm/xterm/css/xterm.css";
|
|
@@ -39,7 +39,8 @@ function TerminalView({
|
|
|
39
39
|
theme,
|
|
40
40
|
title = "Terminal",
|
|
41
41
|
subtitle = "Connected to PTY session",
|
|
42
|
-
isActive = true
|
|
42
|
+
isActive = true,
|
|
43
|
+
connectionId
|
|
43
44
|
}) {
|
|
44
45
|
const resolvedTheme = useMemo(
|
|
45
46
|
() => ({ ...DEFAULT_TERMINAL_THEME, ...theme }),
|
|
@@ -65,7 +66,8 @@ function TerminalView({
|
|
|
65
66
|
const { isConnected, error, sendCommand, resizeTerminal, reconnect } = usePtySession({
|
|
66
67
|
apiUrl,
|
|
67
68
|
token,
|
|
68
|
-
onData
|
|
69
|
+
onData,
|
|
70
|
+
connectionId
|
|
69
71
|
});
|
|
70
72
|
useEffect(() => {
|
|
71
73
|
if (!containerRef.current) return;
|
package/package.json
CHANGED