diff --git a/packages/views/autopilots/components/autopilot-detail-page.tsx b/packages/views/autopilots/components/autopilot-detail-page.tsx index 5da9d14fe..e9e4aa095 100644 --- a/packages/views/autopilots/components/autopilot-detail-page.tsx +++ b/packages/views/autopilots/components/autopilot-detail-page.tsx @@ -314,6 +314,25 @@ function TriggerRow({ trigger, autopilotId }: { trigger: AutopilotTrigger; autop }; const Icon = isWebhook ? Webhook : isApi ? Zap : Clock; + const showWebhookUrlRow = isWebhook && webhookUrl; + + // Delete control extracted so a webhook trigger can render it inline + // with Copy / Rotate on the URL action row (where the other action + // buttons live), while schedule / api triggers — which have no URL row + // — keep it pinned to the row's top-right corner. Without this the + // trash icon visually floats above the URL action buttons because the + // outer flex uses `items-start`. + const deleteButton = ( + + ); return (
@@ -346,7 +365,7 @@ function TriggerRow({ trigger, autopilotId }: { trigger: AutopilotTrigger; autop {t(($) => $.trigger_row.next_label, { date: formatDate(trigger.next_run_at) })}
)} - {isWebhook && webhookUrl && ( + {showWebhookUrlRow && (
{webhookUrl} @@ -370,17 +389,11 @@ function TriggerRow({ trigger, autopilotId }: { trigger: AutopilotTrigger; autop > + {deleteButton}
)} - + {!showWebhookUrlRow && deleteButton} { if (!v && !deleting) setConfirmOpen(false); }}>