From bb54e978063cafc044290e795acc489133946de0 Mon Sep 17 00:00:00 2001 From: James Ritchie Date: Mon, 4 Aug 2025 13:21:30 +0100 Subject: [PATCH] Show text wrapping on code blocks (#2338) * Show text wrapping on deployment code blocks * Show textWrapping on some more CodeBlocks * Adds missing margins to the error block --- apps/webapp/app/components/runs/v3/DeploymentError.tsx | 4 +++- apps/webapp/app/components/runs/v3/PacketDisplay.tsx | 1 + .../route.tsx | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/apps/webapp/app/components/runs/v3/DeploymentError.tsx b/apps/webapp/app/components/runs/v3/DeploymentError.tsx index 517f91789..11ee62dfa 100644 --- a/apps/webapp/app/components/runs/v3/DeploymentError.tsx +++ b/apps/webapp/app/components/runs/v3/DeploymentError.tsx @@ -9,7 +9,7 @@ type DeploymentErrorProps = { export function DeploymentError({ errorData }: DeploymentErrorProps) { return ( -
+
{errorData.message && {errorData.message}} {errorData.stack && ( @@ -18,6 +18,7 @@ export function DeploymentError({ errorData }: DeploymentErrorProps) { showLineNumbers={false} code={errorData.stack} maxLines={20} + showTextWrapping /> )} {errorData.stderr && ( @@ -28,6 +29,7 @@ export function DeploymentError({ errorData }: DeploymentErrorProps) { showLineNumbers={false} code={errorData.stderr} maxLines={20} + showTextWrapping /> )} diff --git a/apps/webapp/app/components/runs/v3/PacketDisplay.tsx b/apps/webapp/app/components/runs/v3/PacketDisplay.tsx index 8e30b2df7..24a9b66b6 100644 --- a/apps/webapp/app/components/runs/v3/PacketDisplay.tsx +++ b/apps/webapp/app/components/runs/v3/PacketDisplay.tsx @@ -50,6 +50,7 @@ export function PacketDisplay({ code={data} maxLines={20} showLineNumbers={false} + showTextWrapping /> ); } diff --git a/apps/webapp/app/routes/resources.orgs.$organizationSlug.projects.$projectParam.env.$envParam.runs.$runParam.spans.$spanParam/route.tsx b/apps/webapp/app/routes/resources.orgs.$organizationSlug.projects.$projectParam.env.$envParam.runs.$runParam.spans.$spanParam/route.tsx index 846f2567b..1559b2c29 100644 --- a/apps/webapp/app/routes/resources.orgs.$organizationSlug.projects.$projectParam.env.$envParam.runs.$runParam.spans.$spanParam/route.tsx +++ b/apps/webapp/app/routes/resources.orgs.$organizationSlug.projects.$projectParam.env.$envParam.runs.$runParam.spans.$spanParam/route.tsx @@ -758,12 +758,12 @@ function RunBody({
) : tab === "context" ? (
- +
) : tab === "metadata" ? (
{run.metadata ? ( - + ) : ( No metadata set for this run. View our metadata documentation to learn more.