Skip to content

Commit 4a8fb57

Browse files
authored
Merge pull request #3113 from continuedev/quick-edit-4f1d
always render delete button
2 parents 5641fae + eced0d0 commit 4a8fb57

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

gui/src/components/StepContainer/ResponseActions.tsx

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,6 @@ export default function ResponseActions({
2727
(store: RootState) => store.editModeState.isInEditMode,
2828
);
2929

30-
// Only render delete button if there is more than one message
31-
const shouldRenderDelete = index !== 1;
32-
3330
if (isInEditMode) {
3431
return <EditActions index={index} item={item} />;
3532
}
@@ -46,19 +43,16 @@ export default function ResponseActions({
4643
</HeaderButtonWithToolTip>
4744
)}
4845

49-
{shouldRenderDelete && (
50-
<HeaderButtonWithToolTip text="Delete" tabIndex={-1} onClick={onDelete}>
51-
<TrashIcon className="h-3.5 w-3.5 text-gray-500" />
52-
</HeaderButtonWithToolTip>
53-
)}
46+
<HeaderButtonWithToolTip text="Delete" tabIndex={-1} onClick={onDelete}>
47+
<TrashIcon className="h-3.5 w-3.5 text-gray-500" />
48+
</HeaderButtonWithToolTip>
5449

5550
<CopyIconButton
5651
tabIndex={-1}
5752
text={stripImages(item.message.content)}
5853
clipboardIconClassName="h-3.5 w-3.5 text-gray-500"
5954
checkIconClassName="h-3.5 w-3.5 text-green-400"
6055
/>
61-
6256
<FeedbackButtons item={item} />
6357
</div>
6458
);

0 commit comments

Comments
 (0)