tweak: use initial for tool short label
This commit is contained in:
@@ -32,7 +32,7 @@ const SEGMENT_LABELS: Record<TimelineSegmentType, string> = {
|
|||||||
const SEGMENT_SHORT_LABELS: Record<TimelineSegmentType, string> = {
|
const SEGMENT_SHORT_LABELS: Record<TimelineSegmentType, string> = {
|
||||||
user: "U",
|
user: "U",
|
||||||
assistant: "A",
|
assistant: "A",
|
||||||
tool: "Tool",
|
tool: "T",
|
||||||
}
|
}
|
||||||
|
|
||||||
const TOOL_FALLBACK_LABEL = "Tool Call"
|
const TOOL_FALLBACK_LABEL = "Tool Call"
|
||||||
@@ -307,7 +307,7 @@ const MessageTimeline: Component<MessageTimelineProps> = (props) => {
|
|||||||
>
|
>
|
||||||
<span class="message-timeline-label message-timeline-label-full">{segment.label}</span>
|
<span class="message-timeline-label message-timeline-label-full">{segment.label}</span>
|
||||||
<span class="message-timeline-label message-timeline-label-short">
|
<span class="message-timeline-label message-timeline-label-short">
|
||||||
{segment.type === "tool" ? (segment.label.slice(0, 4).toUpperCase()) : SEGMENT_SHORT_LABELS[segment.type]}
|
{segment.type === "tool" ? segment.label.charAt(0).toUpperCase() : SEGMENT_SHORT_LABELS[segment.type]}
|
||||||
</span>
|
</span>
|
||||||
</button>
|
</button>
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user