Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

fix(posthog-ai): wrap the request preview in permission prompts (#111355)

Shy Alterc52f28fe8cd4
diff --git a/products/posthog_ai/frontend/components/PermissionInput.tsx b/products/posthog_ai/frontend/components/PermissionInput.tsx
index 0a2f96b6f85a..cb203582a727 100644
--- a/products/posthog_ai/frontend/components/PermissionInput.tsx
+++ b/products/posthog_ai/frontend/components/PermissionInput.tsx
@@ -81,7 +81,8 @@ function PayloadPermissionEvidence({ label, payload }: PayloadPermissionEvidence
<div className="flex flex-col gap-1 min-w-0">
{label && <div className="text-xs text-secondary font-medium">{label}</div>}
<div className={cn(showAll && 'max-h-96 overflow-y-auto')}>
- <CodeSnippet language={language} className="text-xs" compact>
+ {/* Wrapped, so the whole request is visible before approving it. The padding keeps text clear of the copy button. */}
+ <CodeSnippet language={language} className="text-xs [&_pre]:pr-9" compact wrap>
{visible}
</CodeSnippet>
</div>