lint passing ai prompt

This commit is contained in:
EthanShoeDev
2025-09-17 19:35:57 -04:00
parent b24d44155d
commit 07f7ce9a6f
2 changed files with 22 additions and 3 deletions

View File

@@ -42,15 +42,17 @@ function ShellDetail() {
useEffect(() => {
if (!connection) return;
const xterm = xtermRef.current;
const listenerId = connection.addChannelListener((data: ArrayBuffer) => {
// Forward bytes to terminal (no string conversion)
xtermRef.current?.write(new Uint8Array(data));
xterm?.write(new Uint8Array(data));
});
return () => {
connection.removeChannelListener(listenerId);
// Flush any buffered writes on unmount
xtermRef.current?.flush?.();
xterm?.flush?.();
};
}, [connection]);
@@ -92,13 +94,29 @@ function ShellDetail() {
<XtermJsWebView
ref={xtermRef}
style={{ flex: 1 }}
keyboardDisplayRequiresUserAction={false}
setSupportMultipleWindows={false}
overScrollMode="never"
pullToRefreshEnabled={false}
bounces={false}
setBuiltInZoomControls={false}
setDisplayZoomControls={false}
textZoom={100}
allowsLinkPreview={false}
textInteractionEnabled={false}
onRenderProcessGone={() => {
xtermRef.current?.clear?.();
}}
onContentProcessDidTerminate={() => {
xtermRef.current?.clear?.();
}}
// Optional: set initial theme/font
onLoadEnd={() => {
// Set theme bg/fg and font settings once WebView loads; the page will
// still send 'initialized' after xterm is ready.
xtermRef.current?.setTheme?.(
theme.colors.background,
theme.colors.text,
theme.colors.textPrimary,
);
xtermRef.current?.setFont?.('Menlo, ui-monospace, monospace', 14);
}}

View File

@@ -10,6 +10,7 @@ const term = new Terminal({
allowProposedApi: true,
convertEol: true,
scrollback: 10000,
cursorBlink: true,
});
const fitAddon = new FitAddon();
term.loadAddon(fitAddon);