fix(ui): align multi-file patch icon spacing
This commit is contained in:
@@ -2228,23 +2228,12 @@ const ToolPartContent: React.FC<ToolPartProps> = ({
|
|||||||
<div className={cn('flex gap-1.5', isMultiFileApplyPatch ? 'w-full min-w-0 flex-wrap items-center gap-x-2 gap-y-0.5' : 'items-center flex-shrink-0')}>
|
<div className={cn('flex gap-1.5', isMultiFileApplyPatch ? 'w-full min-w-0 flex-wrap items-center gap-x-2 gap-y-0.5' : 'items-center flex-shrink-0')}>
|
||||||
{isMultiFileApplyPatch ? (
|
{isMultiFileApplyPatch ? (
|
||||||
<>
|
<>
|
||||||
<Button
|
<div className="flex h-5 flex-shrink-0 items-center gap-1.5">
|
||||||
variant="ghost"
|
|
||||||
size="xs"
|
|
||||||
className="gap-1.5 normal-case"
|
|
||||||
aria-expanded={isExpanded}
|
|
||||||
aria-label={displayName}
|
|
||||||
title={displayName}
|
|
||||||
onClick={(event) => {
|
|
||||||
event.stopPropagation();
|
|
||||||
onToggle(part.id);
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<span className="relative h-3.5 w-3.5 flex-shrink-0">
|
<span className="relative h-3.5 w-3.5 flex-shrink-0">
|
||||||
<span className={cn(
|
<span className={cn(
|
||||||
'absolute inset-0 flex items-center justify-center transition-opacity',
|
'absolute inset-0 flex items-center justify-center transition-opacity',
|
||||||
isExpanded ? 'opacity-0' : 'group-hover/tool:opacity-0',
|
isExpanded ? 'opacity-0' : 'group-hover/tool:opacity-0',
|
||||||
)}>
|
)} style={iconStyle}>
|
||||||
{getToolIcon(normalizedPartTool || part.tool)}
|
{getToolIcon(normalizedPartTool || part.tool)}
|
||||||
</span>
|
</span>
|
||||||
<Icon
|
<Icon
|
||||||
@@ -2263,7 +2252,7 @@ const ToolPartContent: React.FC<ToolPartProps> = ({
|
|||||||
>
|
>
|
||||||
{displayName}
|
{displayName}
|
||||||
</MinDurationShineText>
|
</MinDurationShineText>
|
||||||
</Button>
|
</div>
|
||||||
<ApplyPatchFileButtons
|
<ApplyPatchFileButtons
|
||||||
metadata={metadata}
|
metadata={metadata}
|
||||||
animate={animateTailText}
|
animate={animateTailText}
|
||||||
|
|||||||
Reference in New Issue
Block a user