feat: Redesign CLI welcome screen and improve visual consistency

This commit is contained in:
tanzhenxin 2026-01-16 11:48:31 +08:00
parent ff5ea3c6d7
commit b804b1f48a
81 changed files with 1474 additions and 1342 deletions

View file

@ -18,14 +18,14 @@ export const ContextUsageDisplay = ({
terminalWidth: number;
}) => {
const percentage = promptTokenCount / tokenLimit(model);
const percentageLeft = ((1 - percentage) * 100).toFixed(0);
const percentageUsed = (percentage * 100).toFixed(1);
const label = terminalWidth < 100 ? '%' : '% context left';
const label = terminalWidth < 100 ? '% used' : '% context used';
return (
<Text color={theme.text.secondary}>
({percentageLeft}
{label})
{percentageUsed}
{label}
</Text>
);
};