Skip to content

Commit a62ed2e

Browse files
fix(web): code blocks scroll inside the transcript column (CL-8509) (#924)
1 parent 861c6ba commit a62ed2e

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

apps/web/src/chat/styles.css

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -963,6 +963,9 @@
963963
border-radius: var(--ui-radius-sm, 0.25rem);
964964
padding: 0.05rem 0.3rem;
965965
font-size: 0.85em;
966+
/* An unbroken token (a long path, hash, URL) wraps inside the message
967+
column instead of pushing it wider. */
968+
overflow-wrap: anywhere;
966969
}
967970

968971
.chat-md-code-block {
@@ -971,6 +974,9 @@
971974
background: var(--muted, color-mix(in srgb, var(--foreground) 8%, transparent));
972975
border-radius: var(--ui-radius-sm, 0.25rem);
973976
overflow-x: auto;
977+
/* The block itself never grows past its flex column ancestors; a long
978+
unbroken line scrolls inside this box instead. */
979+
max-width: 100%;
974980
font-size: 0.85em;
975981
}
976982

0 commit comments

Comments
 (0)