Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions apps/code/src/renderer/components/CodeBlock.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,7 @@ export function CodeBlock({ children, size = "1" }: CodeBlockProps) {
variant="ghost"
color="gray"
onClick={handleCopy}
style={{
transition: "opacity 0.15s",
}}
className="group-hover:!opacity-100 [&]:hover:!opacity-100 absolute top-1 right-1 cursor-pointer opacity-0"
className="absolute top-1 right-1 cursor-pointer"
aria-label="Copy code"
>
{copied ? <Check size={14} /> : <Copy size={14} />}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,15 +154,16 @@ export const AgentMessage = memo(function AgentMessage({
content={content}
componentsOverride={agentComponents}
/>
<Box className="absolute top-1 right-1 opacity-0 transition-opacity group-hover/msg:opacity-100">
<Box className="absolute top-1 left-full ml-2 opacity-0 transition-opacity group-hover/msg:opacity-100">
<Tooltip content={copied ? "Copied!" : "Copy message"}>
<IconButton
size="1"
variant="ghost"
color={copied ? "green" : "gray"}
onClick={handleCopy}
aria-label="Copy message"
>
{copied ? <Check size={12} /> : <Copy size={12} />}
{copied ? <Check size={14} /> : <Copy size={14} />}
</IconButton>
</Tooltip>
</Box>
Expand Down
Loading