codeep 1.0.82 → 1.0.83
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/app.js
CHANGED
|
@@ -164,10 +164,16 @@ export const App = () => {
|
|
|
164
164
|
}
|
|
165
165
|
}, [notification, notificationDuration]);
|
|
166
166
|
// Clear terminal and input when opening command-triggered modals (not session-picker or permission)
|
|
167
|
+
// Also force stdout to flush to ensure screen clears before render
|
|
167
168
|
useEffect(() => {
|
|
168
169
|
const commandModals = ['help', 'status', 'sessions', 'sessions-delete', 'model', 'protocol', 'language', 'settings', 'provider', 'search', 'export', 'logout'];
|
|
169
170
|
if (commandModals.includes(screen)) {
|
|
170
|
-
|
|
171
|
+
// Clear screen and reset cursor
|
|
172
|
+
stdout?.write('\x1b[2J\x1b[3J\x1b[H\x1b[0;0H');
|
|
173
|
+
// Force flush
|
|
174
|
+
if (stdout && 'moveCursor' in stdout) {
|
|
175
|
+
stdout.moveCursor(0, -999); // Move cursor way up
|
|
176
|
+
}
|
|
171
177
|
setClearInputTrigger(prev => prev + 1); // Clear input to remove command text and suggestions
|
|
172
178
|
}
|
|
173
179
|
}, [screen, stdout]);
|
|
@@ -1318,10 +1324,10 @@ export const App = () => {
|
|
|
1318
1324
|
return (_jsx(ProjectPermission, { projectPath: projectPath, onComplete: handlePermissionComplete }));
|
|
1319
1325
|
}
|
|
1320
1326
|
if (screen === 'help') {
|
|
1321
|
-
return (_jsxs(Box, { flexDirection: "column",
|
|
1327
|
+
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Help, {}), _jsx(Text, { children: "Press Escape to close" })] }));
|
|
1322
1328
|
}
|
|
1323
1329
|
if (screen === 'status') {
|
|
1324
|
-
return (_jsxs(Box, { flexDirection: "column",
|
|
1330
|
+
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Status, {}), _jsx(Text, { children: "Press Escape to close" })] }));
|
|
1325
1331
|
}
|
|
1326
1332
|
if (screen === 'session-picker') {
|
|
1327
1333
|
return (_jsx(SessionPicker, { projectPath: projectPath, onSelect: (loadedMessages, sessionName) => {
|
|
@@ -1407,7 +1413,7 @@ export const App = () => {
|
|
|
1407
1413
|
const actionColor = change.action === 'delete' ? 'red' : change.action === 'edit' ? 'yellow' : 'green';
|
|
1408
1414
|
const actionLabel = change.action === 'delete' ? 'DELETE' : change.action === 'edit' ? 'EDIT' : 'CREATE';
|
|
1409
1415
|
return (_jsxs(Text, { children: ["\u2022 ", _jsxs(Text, { color: actionColor, children: ["[", actionLabel, "]"] }), " ", change.path, change.action !== 'delete' && change.content.includes('\n') && ` (${change.content.split('\n').length} lines)`] }, i));
|
|
1410
|
-
}), _jsx(Text, { children: " " }), _jsxs(Text, { children: ["Apply changes? ", _jsx(Text, { color: "#f02a30", bold: true, children: "[Y/n]" })] }), _jsx(Text, { color: "
|
|
1416
|
+
}), _jsx(Text, { children: " " }), _jsxs(Text, { children: ["Apply changes? ", _jsx(Text, { color: "#f02a30", bold: true, children: "[Y/n]" })] }), _jsx(Text, { color: "cyan", children: "Press Y to apply, N or Esc to reject" })] })), notification && (_jsx(Box, { justifyContent: "center", children: _jsx(Text, { color: "cyan", children: notification }) })), _jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: "#f02a30", children: '─'.repeat(Math.max(20, stdout?.columns || 80)) }), _jsx(Box, { paddingX: 1, children: _jsx(ChatInput, { onSubmit: handleSubmit, disabled: isLoading || isAgentRunning || pendingFileChanges.length > 0, history: inputHistory, clearTrigger: clearInputTrigger }) }), _jsx(Text, { color: "#f02a30", children: '─'.repeat(Math.max(20, stdout?.columns || 80)) })] }), _jsxs(Box, { flexDirection: "column", children: [_jsx(Box, { children: _jsxs(Text, { children: [_jsx(Text, { color: "#f02a30", bold: true, children: "Ctrl+V" }), _jsx(Text, { children: " Paste " }), _jsx(Text, { color: "#f02a30", bold: true, children: "Ctrl+L" }), _jsx(Text, { children: " Clear " }), _jsx(Text, { color: "#f02a30", bold: true, children: "Esc" }), _jsx(Text, { children: " Cancel " }), _jsx(Text, { color: "#f02a30", bold: true, children: "\u2191\u2193" }), _jsx(Text, { children: " History " }), _jsx(Text, { color: "#f02a30", bold: true, children: "/help" }), _jsx(Text, { children: " Commands" })] }) }), _jsx(Box, { children: config.get('agentMode') === 'on' ? (hasWriteAccess && projectContext ? (_jsx(Text, { color: "green", children: "Agent: ON \u2713" })) : (_jsx(Text, { color: "yellow", children: "Agent: ON (no permission - use /grant)" }))) : (_jsx(Text, { color: "cyan", children: "Agent: Manual (use /agent)" })) })] })] }));
|
|
1411
1417
|
};
|
|
1412
1418
|
// Model selection component
|
|
1413
1419
|
const ModelSelect = ({ onClose, notify }) => {
|
|
@@ -40,7 +40,7 @@ export const AgentProgress = ({ isRunning, iteration, maxIterations, actions, cu
|
|
|
40
40
|
deleted: actions.filter(a => a.type === 'delete' && a.result === 'success').length,
|
|
41
41
|
};
|
|
42
42
|
const totalFileChanges = fileChanges.created + fileChanges.modified + fileChanges.deleted;
|
|
43
|
-
return (_jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: dryRun ? 'yellow' : '#f02a30', paddingX: 1, marginY: 1, children: [_jsx(Box, { children: isRunning ? (_jsxs(_Fragment, { children: [_jsxs(Text, { color: dryRun ? 'yellow' : '#f02a30', children: ["[", SPINNER_FRAMES[spinnerFrame], "]"] }), _jsxs(Text, { color: dryRun ? 'yellow' : '#f02a30', bold: true, children: [' ', dryRun ? 'DRY RUN' : 'AGENT', ' '] }), _jsx(Text, { color: "
|
|
43
|
+
return (_jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: dryRun ? 'yellow' : '#f02a30', paddingX: 1, marginY: 1, children: [_jsx(Box, { children: isRunning ? (_jsxs(_Fragment, { children: [_jsxs(Text, { color: dryRun ? 'yellow' : '#f02a30', children: ["[", SPINNER_FRAMES[spinnerFrame], "]"] }), _jsxs(Text, { color: dryRun ? 'yellow' : '#f02a30', bold: true, children: [' ', dryRun ? 'DRY RUN' : 'AGENT', ' '] }), _jsx(Text, { color: "cyan", children: "|" }), _jsxs(Text, { color: "cyan", children: [" step ", iteration] }), _jsx(Text, { color: "cyan", children: " | " }), actionCounts.reads > 0 && _jsxs(Text, { color: "blue", children: [actionCounts.reads, "R "] }), actionCounts.writes > 0 && _jsxs(Text, { color: "green", children: [actionCounts.writes, "W "] }), actionCounts.edits > 0 && _jsxs(Text, { color: "yellow", children: [actionCounts.edits, "E "] }), actionCounts.commands > 0 && _jsxs(Text, { color: "magenta", children: [actionCounts.commands, "C "] }), actionCounts.searches > 0 && _jsxs(Text, { color: "cyan", children: [actionCounts.searches, "S "] }), actions.length === 0 && _jsx(Text, { color: "cyan", children: "0 actions" })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { color: "green", bold: true, children: "[DONE] " }), _jsx(Text, { children: "Agent completed" }), _jsx(Text, { color: "cyan", children: " | " }), _jsxs(Text, { color: "white", children: [actions.length, " actions"] })] })) }), isRunning && currentAction && (_jsxs(Box, { marginTop: 1, children: [_jsx(Text, { color: "white", bold: true, children: "Now: " }), _jsxs(Text, { color: getActionColor(currentAction.type), children: [getActionLabel(currentAction.type), " "] }), _jsx(Text, { color: "white", children: formatTarget(currentAction.target) })] })), _jsx(Text, { color: "cyan", children: '─'.repeat(50) }), recentActions.length > 1 && (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: "cyan", dimColor: true, children: "Recent:" }), recentActions.slice(0, -1).map((action, i) => (_jsx(ActionItem, { action: action }, i)))] })), isRunning && totalFileChanges > 0 && (_jsxs(Box, { marginTop: 1, children: [_jsx(Text, { color: "cyan", children: "Changes: " }), fileChanges.created > 0 && _jsxs(Text, { color: "green", children: ["+", fileChanges.created, " "] }), fileChanges.modified > 0 && _jsxs(Text, { color: "yellow", children: ["~", fileChanges.modified, " "] }), fileChanges.deleted > 0 && _jsxs(Text, { color: "red", children: ["-", fileChanges.deleted] })] })), isRunning && currentThinking && (_jsx(Box, { marginTop: 1, children: _jsxs(Text, { color: "cyan", wrap: "truncate-end", children: ["> ", currentThinking.slice(0, 80), currentThinking.length > 80 ? '...' : ''] }) })), isRunning && (_jsxs(Box, { marginTop: 1, children: [_jsx(Text, { color: "cyan", children: "Press " }), _jsx(Text, { color: "#f02a30", children: "Esc" }), _jsx(Text, { color: "cyan", children: " to stop" })] })), !isRunning && totalFileChanges > 0 && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsx(Text, { bold: true, children: "File Changes:" }), fileChanges.created > 0 && (_jsxs(Text, { color: "green", children: [" + ", fileChanges.created, " file(s) created"] })), fileChanges.modified > 0 && (_jsxs(Text, { color: "yellow", children: [" ~ ", fileChanges.modified, " file(s) modified"] })), fileChanges.deleted > 0 && (_jsxs(Text, { color: "red", children: [" - ", fileChanges.deleted, " file(s) deleted"] }))] }))] }));
|
|
44
44
|
};
|
|
45
45
|
// Get file extension for language detection
|
|
46
46
|
const getFileExtension = (filename) => {
|
|
@@ -195,10 +195,10 @@ export const LiveCodeStream = ({ actions, isRunning, terminalWidth = 80 }) => {
|
|
|
195
195
|
const hasMoreLines = visibleLineCount < totalLines;
|
|
196
196
|
// Calculate line width based on terminal width (same as agent box)
|
|
197
197
|
const lineWidth = Math.max(20, terminalWidth);
|
|
198
|
-
return (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [_jsx(Text, { color: actionColor, children: '─'.repeat(lineWidth) }), _jsxs(Text, { children: [_jsxs(Text, { color: actionColor, bold: true, children: [actionLabel, " "] }), _jsx(Text, { color: "white", bold: true, children: filename }), _jsxs(Text, { color: "
|
|
198
|
+
return (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [_jsx(Text, { color: actionColor, children: '─'.repeat(lineWidth) }), _jsxs(Text, { children: [_jsxs(Text, { color: actionColor, bold: true, children: [actionLabel, " "] }), _jsx(Text, { color: "white", bold: true, children: filename }), _jsxs(Text, { color: "cyan", children: [" \u2022 ", langLabel, " \u2022 "] }), _jsx(Text, { color: "cyan", children: visibleLineCount }), _jsxs(Text, { color: "cyan", children: ["/", totalLines, " lines"] }), hasMoreLines && _jsx(Text, { color: "yellow", children: " \u25BC streaming..." })] }), linesToShow.map((line, i) => {
|
|
199
199
|
const lineNum = i + 1;
|
|
200
|
-
return (_jsxs(Text, { children: [_jsxs(Text, { color: "
|
|
201
|
-
}), hasMoreLines && (_jsxs(Text, { color: "
|
|
200
|
+
return (_jsxs(Text, { children: [_jsxs(Text, { color: "cyan", dimColor: true, children: [String(lineNum).padStart(4, ' '), " \u2502", ' '] }), _jsx(Text, { color: getCodeColor(line, ext), children: line.slice(0, 80) }), line.length > 80 && _jsx(Text, { color: "cyan", children: "\u2026" })] }, `line-${i}`));
|
|
201
|
+
}), hasMoreLines && (_jsxs(Text, { color: "cyan", dimColor: true, children: [' ', "\u2502 ... ", totalLines - visibleLineCount, " more lines loading..."] })), _jsx(Text, { color: actionColor, children: '─'.repeat(lineWidth) })] }));
|
|
202
202
|
};
|
|
203
203
|
// Helper functions for action display
|
|
204
204
|
const getActionColor = (type) => {
|
|
@@ -255,7 +255,7 @@ const ActionItem = ({ action }) => {
|
|
|
255
255
|
return _jsx(Text, { color: "yellow", children: "\u00B7" });
|
|
256
256
|
}
|
|
257
257
|
};
|
|
258
|
-
return (_jsxs(Text, { children: [getStatusIndicator(), ' ', _jsx(Text, { color: getActionColor(action.type), children: getActionLabel(action.type).padEnd(10) }), ' ', _jsx(Text, { color: "
|
|
258
|
+
return (_jsxs(Text, { children: [getStatusIndicator(), ' ', _jsx(Text, { color: getActionColor(action.type), children: getActionLabel(action.type).padEnd(10) }), ' ', _jsx(Text, { color: "cyan", children: formatTarget(action.target) })] }));
|
|
259
259
|
};
|
|
260
260
|
export const AgentSummary = ({ success, iterations, actions, error, aborted, }) => {
|
|
261
261
|
const filesWritten = actions.filter(a => a.type === 'write' && a.result === 'success');
|
|
@@ -266,7 +266,7 @@ export const AgentSummary = ({ success, iterations, actions, error, aborted, })
|
|
|
266
266
|
const errors = actions.filter(a => a.result === 'error');
|
|
267
267
|
const hasFileChanges = filesWritten.length > 0 || filesEdited.length > 0 ||
|
|
268
268
|
filesDeleted.length > 0 || dirsCreated.length > 0;
|
|
269
|
-
return (_jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: success ? 'green' : aborted ? 'yellow' : 'red', padding: 1, marginY: 1, children: [_jsxs(Box, { children: [success ? (_jsx(Text, { color: "green", bold: true, children: "[OK] Agent completed" })) : aborted ? (_jsx(Text, { color: "yellow", bold: true, children: "[--] Agent stopped" })) : (_jsx(Text, { color: "red", bold: true, children: "[!!] Agent failed" })), _jsxs(Text, { color: "
|
|
269
|
+
return (_jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: success ? 'green' : aborted ? 'yellow' : 'red', padding: 1, marginY: 1, children: [_jsxs(Box, { children: [success ? (_jsx(Text, { color: "green", bold: true, children: "[OK] Agent completed" })) : aborted ? (_jsx(Text, { color: "yellow", bold: true, children: "[--] Agent stopped" })) : (_jsx(Text, { color: "red", bold: true, children: "[!!] Agent failed" })), _jsxs(Text, { color: "cyan", children: [" | ", iterations, " iterations | ", actions.length, " actions"] })] }), error && (_jsxs(Text, { color: "red", children: ["Error: ", error] })), hasFileChanges && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "cyan", children: '─'.repeat(40) }), _jsx(Text, { bold: true, children: "Changes:" }), filesWritten.length > 0 && (_jsxs(Box, { flexDirection: "column", children: [_jsxs(Text, { color: "green", children: ["+ Created (", filesWritten.length, "):"] }), filesWritten.map((f, i) => (_jsxs(Text, { color: "green", children: [" ", f.target] }, i)))] })), filesEdited.length > 0 && (_jsxs(Box, { flexDirection: "column", children: [_jsxs(Text, { color: "yellow", children: ["~ Modified (", filesEdited.length, "):"] }), filesEdited.map((f, i) => (_jsxs(Text, { color: "yellow", children: [" ", f.target] }, i)))] })), filesDeleted.length > 0 && (_jsxs(Box, { flexDirection: "column", children: [_jsxs(Text, { color: "red", children: ["- Deleted (", filesDeleted.length, "):"] }), filesDeleted.map((f, i) => (_jsxs(Text, { color: "red", children: [" ", f.target] }, i)))] })), dirsCreated.length > 0 && (_jsxs(Text, { color: "blue", children: ["+ ", dirsCreated.length, " director(ies) created"] }))] })), commandsRun.length > 0 && (_jsxs(Text, { color: "magenta", children: [commandsRun.length, " command(s) executed"] })), errors.length > 0 && (_jsxs(Text, { color: "red", children: [errors.length, " error(s) occurred"] }))] }));
|
|
270
270
|
};
|
|
271
271
|
export const ChangesList = ({ actions }) => {
|
|
272
272
|
const writes = actions.filter(a => a.type === 'write' && a.result === 'success');
|
|
@@ -275,7 +275,7 @@ export const ChangesList = ({ actions }) => {
|
|
|
275
275
|
const mkdirs = actions.filter(a => a.type === 'mkdir' && a.result === 'success');
|
|
276
276
|
const totalChanges = writes.length + edits.length + deletes.length + mkdirs.length;
|
|
277
277
|
if (totalChanges === 0) {
|
|
278
|
-
return (_jsx(Box, { children: _jsx(Text, { color: "
|
|
278
|
+
return (_jsx(Box, { children: _jsx(Text, { color: "cyan", children: "No file changes in current session" }) }));
|
|
279
279
|
}
|
|
280
|
-
return (_jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: "cyan", padding: 1, children: [_jsxs(Text, { color: "cyan", bold: true, children: ["Session Changes (", totalChanges, " total)"] }), _jsx(Text, { color: "
|
|
280
|
+
return (_jsxs(Box, { flexDirection: "column", borderStyle: "round", borderColor: "cyan", padding: 1, children: [_jsxs(Text, { color: "cyan", bold: true, children: ["Session Changes (", totalChanges, " total)"] }), _jsx(Text, { color: "cyan", children: '─'.repeat(40) }), writes.length > 0 && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsxs(Text, { color: "green", bold: true, children: ["Created (", writes.length, "):"] }), writes.map((w, i) => (_jsxs(Text, { children: [" + ", w.target] }, i)))] })), edits.length > 0 && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsxs(Text, { color: "yellow", bold: true, children: ["Modified (", edits.length, "):"] }), edits.map((e, i) => (_jsxs(Text, { children: [" ~ ", e.target] }, i)))] })), deletes.length > 0 && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsxs(Text, { color: "red", bold: true, children: ["Deleted (", deletes.length, "):"] }), deletes.map((d, i) => (_jsxs(Text, { children: [" - ", d.target] }, i)))] })), mkdirs.length > 0 && (_jsxs(Box, { flexDirection: "column", marginTop: 1, children: [_jsxs(Text, { color: "blue", bold: true, children: ["Directories (", mkdirs.length, "):"] }), mkdirs.map((m, i) => (_jsxs(Text, { children: [" + ", m.target, "/"] }, i)))] }))] }));
|
|
281
281
|
};
|
package/dist/components/Input.js
CHANGED
|
@@ -320,12 +320,12 @@ export const ChatInput = ({ onSubmit, disabled, history = [], clearTrigger = 0 }
|
|
|
320
320
|
// Render input with cursor
|
|
321
321
|
const renderInput = () => {
|
|
322
322
|
if (!value) {
|
|
323
|
-
return _jsx(Text, { color: "
|
|
323
|
+
return _jsx(Text, { color: "cyan", children: "Type a message or /command..." });
|
|
324
324
|
}
|
|
325
325
|
const before = value.slice(0, cursorPos);
|
|
326
326
|
const cursor = value[cursorPos] || ' ';
|
|
327
327
|
const after = value.slice(cursorPos + 1);
|
|
328
328
|
return (_jsxs(Text, { children: [before, _jsx(Text, { backgroundColor: "white", color: "black", children: cursor }), after] }));
|
|
329
329
|
};
|
|
330
|
-
return (_jsxs(Box, { flexDirection: "column", children: [value === '/' && (_jsx(Box, { marginBottom: 1, children: _jsx(Text, { color: "
|
|
330
|
+
return (_jsxs(Box, { flexDirection: "column", children: [value === '/' && (_jsx(Box, { marginBottom: 1, children: _jsx(Text, { color: "cyan", dimColor: true, children: "Type command name (e.g., help, status, settings) or type /help to see all commands" }) })), suggestions.length > 0 && (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [suggestions.map((s, i) => (_jsxs(Text, { children: [i === selectedIndex ? _jsx(Text, { color: "#f02a30", children: "\u25B8 " }) : ' ', _jsx(Text, { color: i === selectedIndex ? '#f02a30' : undefined, bold: i === selectedIndex, children: s.cmd }), _jsxs(Text, { color: i === selectedIndex ? undefined : 'gray', children: [" - ", s.desc] })] }, s.cmd))), _jsx(Text, { color: "cyan", dimColor: true, children: "\u2191\u2193 navigate \u2022 Tab complete \u2022 Esc cancel" })] })), pasteInfo && (_jsx(Box, { borderStyle: "round", borderColor: "green", paddingX: 1, marginBottom: 1, flexDirection: "column", children: _jsxs(Text, { children: [_jsx(Text, { color: "green", bold: true, children: "\uD83D\uDCCB " }), _jsx(Text, { color: "white", bold: true, children: pasteInfo.chars }), _jsx(Text, { color: "cyan", children: " chars" }), pasteInfo.lines > 1 && (_jsxs(_Fragment, { children: [_jsx(Text, { color: "cyan", children: " \u2022 " }), _jsx(Text, { color: "white", bold: true, children: pasteInfo.lines }), _jsx(Text, { color: "cyan", children: " lines" })] })), _jsx(Text, { color: "cyan", dimColor: true, children: " (Enter send \u2022 Esc cancel)" })] }) })), _jsxs(Box, { children: [_jsx(Text, { color: "#f02a30", bold: true, children: '> ' }), disabled ? (_jsx(Text, { color: "yellow", children: "Agent working... (Esc to stop)" })) : (renderInput())] })] }));
|
|
331
331
|
};
|
|
@@ -46,7 +46,7 @@ export const LogoutPicker = ({ onLogout, onLogoutAll, onCancel }) => {
|
|
|
46
46
|
}
|
|
47
47
|
});
|
|
48
48
|
if (providers.length === 0) {
|
|
49
|
-
return (_jsxs(Box, { flexDirection: "column", padding: 1, children: [_jsx(Text, { color: "yellow", children: "No providers configured." }), _jsx(Text, { color: "
|
|
49
|
+
return (_jsxs(Box, { flexDirection: "column", padding: 1, children: [_jsx(Text, { color: "yellow", children: "No providers configured." }), _jsx(Text, { color: "cyan", children: "Press Escape to go back." })] }));
|
|
50
50
|
}
|
|
51
51
|
return (_jsxs(Box, { flexDirection: "column", padding: 1, children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: "cyan", children: "Select provider to logout:" }) }), _jsx(Box, { flexDirection: "column", marginBottom: 1, children: options.map((option, index) => {
|
|
52
52
|
const isSelected = index === selectedIndex;
|
|
@@ -57,5 +57,5 @@ export const LogoutPicker = ({ onLogout, onLogoutAll, onCancel }) => {
|
|
|
57
57
|
if (option.type === 'cancel')
|
|
58
58
|
color = isSelected ? 'blue' : 'gray';
|
|
59
59
|
return (_jsxs(Box, { children: [_jsxs(Text, { color: color, bold: isSelected, children: [prefix, option.label] }), option.isCurrent && (_jsx(Text, { color: "cyan", children: " (current)" }))] }, option.id));
|
|
60
|
-
}) }), _jsx(Box, { marginTop: 1, children: _jsx(Text, { color: "
|
|
60
|
+
}) }), _jsx(Box, { marginTop: 1, children: _jsx(Text, { color: "cyan", children: "\u2191\u2193 Navigate Enter Select Esc Cancel" }) })] }));
|
|
61
61
|
};
|
|
@@ -27,7 +27,7 @@ export const MessageView = memo(({ role, content }) => {
|
|
|
27
27
|
: content;
|
|
28
28
|
// Replace multiple newlines with single space for cleaner display
|
|
29
29
|
const cleanContent = displayContent.replace(/\n+/g, ' ').replace(/\s+/g, ' ').trim();
|
|
30
|
-
return (_jsxs(Box, { marginY: 1, flexDirection: "column", children: [_jsxs(Text, { wrap: "wrap", children: [_jsx(Text, { color: "#f02a30", bold: true, children: '> ' }), _jsx(Text, { children: cleanContent })] }), isLong && (_jsxs(Text, { color: "
|
|
30
|
+
return (_jsxs(Box, { marginY: 1, flexDirection: "column", children: [_jsxs(Text, { wrap: "wrap", children: [_jsx(Text, { color: "#f02a30", bold: true, children: '> ' }), _jsx(Text, { children: cleanContent })] }), isLong && (_jsxs(Text, { color: "cyan", dimColor: true, children: [" (", content.length, " characters total)"] }))] }));
|
|
31
31
|
}
|
|
32
32
|
if (role === 'system') {
|
|
33
33
|
return (_jsx(Box, { marginY: 1, justifyContent: "center", children: _jsx(Text, { italic: true, children: content }) }));
|
|
@@ -151,7 +151,7 @@ const SyntaxLine = memo(({ line, language }) => {
|
|
|
151
151
|
while (remaining.length > 0) {
|
|
152
152
|
// Comments
|
|
153
153
|
if (remaining.startsWith('//') || remaining.startsWith('#')) {
|
|
154
|
-
parts.push(_jsx(Text, { color: "
|
|
154
|
+
parts.push(_jsx(Text, { color: "cyan", children: remaining }, key++));
|
|
155
155
|
break;
|
|
156
156
|
}
|
|
157
157
|
// Multi-line string/docstring
|
|
@@ -83,6 +83,6 @@ export const SessionPicker = ({ onSelect, onNewSession, projectPath }) => {
|
|
|
83
83
|
const prefix = isSelected ? '→ ' : ' ';
|
|
84
84
|
const name = truncateName(session.name);
|
|
85
85
|
const meta = `${session.messageCount} msg, ${formatRelativeTime(session.createdAt)}`;
|
|
86
|
-
return (_jsxs(Box, { children: [_jsxs(Text, { color: isSelected ? 'green' : 'white', bold: isSelected, children: [prefix, name] }), _jsxs(Text, { color: "
|
|
87
|
-
}) }), _jsxs(Box, { marginTop: 1, borderStyle: "single", borderColor: "gray", paddingX: 1, children: [_jsx(Text, { color: "yellow", children: "[N]" }), _jsx(Text, { children: " New session" })] }), _jsxs(Box, { marginTop: 1, children: [_jsx(Text, { color: "
|
|
86
|
+
return (_jsxs(Box, { children: [_jsxs(Text, { color: isSelected ? 'green' : 'white', bold: isSelected, children: [prefix, name] }), _jsxs(Text, { color: "cyan", children: [" (", meta, ")"] })] }, session.name));
|
|
87
|
+
}) }), _jsxs(Box, { marginTop: 1, borderStyle: "single", borderColor: "gray", paddingX: 1, children: [_jsx(Text, { color: "yellow", children: "[N]" }), _jsx(Text, { children: " New session" })] }), _jsxs(Box, { marginTop: 1, children: [_jsx(Text, { color: "cyan", children: "\u2191\u2193 Navigate " }), _jsx(Text, { color: "cyan", children: "Enter Select " }), _jsx(Text, { color: "cyan", children: "N New " }), _jsx(Text, { color: "cyan", children: "Esc New" })] })] }));
|
|
88
88
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codeep",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.83",
|
|
4
4
|
"description": "AI-powered coding assistant built for the terminal. Multiple LLM providers, project-aware context, and a seamless development workflow.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|