Skip to content

Commit eaa8077

Browse files
committed
fix: UI improvements
1 parent 5c37672 commit eaa8077

File tree

4 files changed

+23
-10
lines changed

4 files changed

+23
-10
lines changed

extensions/cli/package-lock.json

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

extensions/cli/src/asciiArt.test.ts

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,26 +27,27 @@ describe("asciiArt", () => {
2727
expect(result).toBe(CONTINUE_ASCII_ART);
2828
});
2929

30-
it("should return simple text version when terminal is too narrow", () => {
30+
it("should return CN ASCII art version when terminal is too narrow", () => {
3131
// Set process.stdout.columns to simulate narrow terminal
3232
process.stdout.columns = 60;
3333

3434
const result = getDisplayableAsciiArt();
3535

36-
expect(result).toContain("CONTINUE");
37-
// expect(result).toContain("v0.0.0-dev");
36+
expect(result).toContain("██████╗");
37+
expect(result).toContain("(alpha)");
3838
expect(result).not.toBe(CONTINUE_ASCII_ART);
3939
// Should be much shorter than the full ASCII art
4040
expect(result.length).toBeLessThan(CONTINUE_ASCII_ART.length / 2);
4141
});
4242

43-
it("should return simple text version when terminal is below threshold", () => {
43+
it("should return CN ASCII art version when terminal is below threshold", () => {
4444
// Test the edge case at exactly 74 columns (below our threshold of 75)
4545
process.stdout.columns = 74;
4646

4747
const result = getDisplayableAsciiArt();
4848

49-
expect(result).toContain("CONTINUE");
49+
expect(result).toContain("██████╗");
50+
expect(result).toContain("(alpha)");
5051
expect(result).not.toBe(CONTINUE_ASCII_ART);
5152
});
5253

extensions/cli/src/asciiArt.ts

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,17 @@ ${mind.multiline(` ██████╗ ██████╗ ███╗
1212
██║ ██║ ██║██║╚██╗██║ ██║ ██║██║╚██╗██║██║ ██║██╔══╝
1313
╚██████╗╚██████╔╝██║ ╚████║ ██║ ██║██║ ╚████║╚██████╔╝███████╗
1414
╚═════╝ ╚═════╝ ╚═╝ ╚═══╝ ╚═╝ ╚═╝╚═╝ ╚═══╝ ╚═════╝ ╚══════╝`)}
15-
${d("v" + getVersion())}`;
15+
${d("v" + getVersion() + " (alpha)")}`;
16+
17+
// ASCII art for just "CN" (first two letters)
18+
const CN_ASCII_ART = `
19+
${mind.multiline(` ██████╗███╗ ██╗
20+
██╔════╝████╗ ██║
21+
██║ ██╔██╗ ██║
22+
██║ ██║╚██╗██║
23+
╚██████╗██║ ╚████║
24+
╚═════╝╚═╝ ╚═══╝`)}
25+
${d("v" + getVersion() + " (alpha)")}`;
1626

1727
// Minimum terminal width required to display ASCII art properly
1828
const MIN_WIDTH_FOR_ASCII_ART = 75;
@@ -28,8 +38,8 @@ export function getDisplayableAsciiArt(): string {
2838
return CONTINUE_ASCII_ART;
2939
}
3040

31-
// If terminal is too narrow, just show a simple version
32-
return `\n${chalk.bold.blue("CONTINUE")} ${d("v" + getVersion())}\n`;
41+
// If terminal is too narrow, show just "CN" ASCII art
42+
return CN_ASCII_ART;
3343
}
3444

3545
export const CONTINUE_LOGO_ASCII_ART = `

extensions/cli/src/ui/components/MemoizedMessage.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@ export const MemoizedMessage = memo<MemoizedMessageProps>(
2020
case "tool-start":
2121
return (
2222
<Box key={index} marginLeft={1} marginBottom={1}>
23-
<Text color="white">{message.content}</Text>
23+
{/* TODO: Change back to empty circle (○) with white color once we want to differentiate in-progress vs completed tool calls */}
24+
<Text color="green"><Text color="white"> {message.content}</Text></Text>
2425
</Box>
2526
);
2627

@@ -87,7 +88,7 @@ export const MemoizedMessage = memo<MemoizedMessageProps>(
8788

8889
return (
8990
<Box key={index} marginLeft={1} marginBottom={1}>
90-
<Text color={isUser ? "green" : "magenta"}></Text>
91+
<Text color={isUser ? "green" : "white"}></Text>
9192
<Text> </Text>
9293
{isUser ? (
9394
<Text color="gray">{message.content}</Text>

0 commit comments

Comments
 (0)