From b5973d9036292c3783dffd174298e769cfdaa645 Mon Sep 17 00:00:00 2001 From: PopDaph Date: Tue, 3 Oct 2023 13:38:59 +0200 Subject: [PATCH] Add labels to button for tooltip --- front/components/assistant/conversation/AgentMessage.tsx | 2 ++ .../components/assistant/conversation/ConversationMessage.tsx | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/front/components/assistant/conversation/AgentMessage.tsx b/front/components/assistant/conversation/AgentMessage.tsx index 7e9dec76ba9d4..8060232e677c3 100644 --- a/front/components/assistant/conversation/AgentMessage.tsx +++ b/front/components/assistant/conversation/AgentMessage.tsx @@ -170,6 +170,7 @@ export function AgentMessage({ ? [] : [ { + label: "Copy to clipboard", icon: ClipboardIcon, onClick: () => { void navigator.clipboard.writeText( @@ -178,6 +179,7 @@ export function AgentMessage({ }, }, { + label: "Retry", icon: ArrowPathIcon, onClick: () => { void retryHandler(agentMessageToRender); diff --git a/front/components/assistant/conversation/ConversationMessage.tsx b/front/components/assistant/conversation/ConversationMessage.tsx index 939446fc105ba..fdef617e9c8d5 100644 --- a/front/components/assistant/conversation/ConversationMessage.tsx +++ b/front/components/assistant/conversation/ConversationMessage.tsx @@ -35,6 +35,7 @@ export function ConversationMessage({ name: string | null; pictureUrl?: string | null; buttons?: { + label: string; icon: ComponentType; onClick: MouseEventHandler; }[]; @@ -144,7 +145,7 @@ export function ConversationMessage({