mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-03-27 14:30:44 -07:00
Show model in history (#13034)
This commit is contained in:
committed by
GitHub
parent
0fcbff506e
commit
ab11b2c27f
@@ -30,6 +30,7 @@ import { getMCPServerStatus } from '@google/gemini-cli-core';
|
||||
import { ToolsList } from './views/ToolsList.js';
|
||||
import { McpStatus } from './views/McpStatus.js';
|
||||
import { ChatList } from './views/ChatList.js';
|
||||
import { ModelMessage } from './messages/ModelMessage.js';
|
||||
|
||||
interface HistoryItemDisplayProps {
|
||||
item: HistoryItem;
|
||||
@@ -117,6 +118,9 @@ export const HistoryItemDisplay: React.FC<HistoryItemDisplayProps> = ({
|
||||
)}
|
||||
{itemForDisplay.type === 'model_stats' && <ModelStatsDisplay />}
|
||||
{itemForDisplay.type === 'tool_stats' && <ToolStatsDisplay />}
|
||||
{itemForDisplay.type === 'model' && (
|
||||
<ModelMessage model={itemForDisplay.model} />
|
||||
)}
|
||||
{itemForDisplay.type === 'quit' && (
|
||||
<SessionSummaryDisplay duration={itemForDisplay.duration} />
|
||||
)}
|
||||
|
||||
21
packages/cli/src/ui/components/messages/ModelMessage.tsx
Normal file
21
packages/cli/src/ui/components/messages/ModelMessage.tsx
Normal file
@@ -0,0 +1,21 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright 2025 Google LLC
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
import type React from 'react';
|
||||
import { Text, Box } from 'ink';
|
||||
import { theme } from '../../semantic-colors.js';
|
||||
|
||||
interface ModelMessageProps {
|
||||
model: string;
|
||||
}
|
||||
|
||||
export const ModelMessage: React.FC<ModelMessageProps> = ({ model }) => (
|
||||
<Box marginLeft={3}>
|
||||
<Text color={theme.ui.comment} italic>
|
||||
responding with {model}
|
||||
</Text>
|
||||
</Box>
|
||||
);
|
||||
Reference in New Issue
Block a user