tycono 0.1.96-beta.10 → 0.1.96-beta.11
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/package.json +1 -1
- package/src/tui/app.tsx +13 -13
package/package.json
CHANGED
package/src/tui/app.tsx
CHANGED
|
@@ -57,6 +57,19 @@ export const App: React.FC = () => {
|
|
|
57
57
|
// System messages (command feedback displayed in stream area)
|
|
58
58
|
const [systemMessages, setSystemMessages] = useState<StreamLine[]>([]);
|
|
59
59
|
|
|
60
|
+
// Terminal full height with resize tracking
|
|
61
|
+
const [termHeight, setTermHeight] = useState(process.stdout.rows || 30);
|
|
62
|
+
|
|
63
|
+
useEffect(() => {
|
|
64
|
+
const onResize = () => {
|
|
65
|
+
setTermHeight(process.stdout.rows || 30);
|
|
66
|
+
};
|
|
67
|
+
process.stdout.on('resize', onResize);
|
|
68
|
+
return () => {
|
|
69
|
+
process.stdout.off('resize', onResize);
|
|
70
|
+
};
|
|
71
|
+
}, []);
|
|
72
|
+
|
|
60
73
|
const addSystemMessage = useCallback((text: string, color: string = 'yellow') => {
|
|
61
74
|
setSystemMessages(prev => {
|
|
62
75
|
const next = [...prev, { id: ++sysLineId, text, color }];
|
|
@@ -216,19 +229,6 @@ export const App: React.FC = () => {
|
|
|
216
229
|
);
|
|
217
230
|
}
|
|
218
231
|
|
|
219
|
-
// Terminal full height with resize tracking
|
|
220
|
-
const [termHeight, setTermHeight] = useState(process.stdout.rows || 30);
|
|
221
|
-
|
|
222
|
-
useEffect(() => {
|
|
223
|
-
const onResize = () => {
|
|
224
|
-
setTermHeight(process.stdout.rows || 30);
|
|
225
|
-
};
|
|
226
|
-
process.stdout.on('resize', onResize);
|
|
227
|
-
return () => {
|
|
228
|
-
process.stdout.off('resize', onResize);
|
|
229
|
-
};
|
|
230
|
-
}, []);
|
|
231
|
-
|
|
232
232
|
return (
|
|
233
233
|
<Box flexDirection="column" height={termHeight}>
|
|
234
234
|
{/* Status Bar — always shown */}
|