Skip to content

Commit 11b435f

Browse files
committed
style(client): normalize font-size across markdown children in message cells
All markdown-emitted elements inside .feed-detail.is-message now inherit the container's font-size (16px) instead of the browser's UA defaults. Previously: - h1-h6 rendered at 2em/1.5em/... (huge in a feed row) - code used 0.92em (shrunken inline) Headings are also set inline with margin 0 so prompts like '# Question' don't break the row flow. Added a blockquote rule for the same reason. Other child elements fall through the universal selector.
1 parent d0c0a3c commit 11b435f

1 file changed

Lines changed: 29 additions & 2 deletions

File tree

client/src/components/ActivityFeed.css

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -306,13 +306,34 @@
306306
/* Markdown rendering inside message cells: keep everything inline so the
307307
detail flows as a single line group. `p` is already stripped via a
308308
fragment renderer in ActivityRow, but guard the rest so lists/code
309-
blocks don't blow up the row height. */
309+
blocks don't blow up the row height. Every child element inherits
310+
the container's font-size so markdown ('**', '#', '`') doesn't
311+
balloon headings or shrink inline code. */
312+
.feed-detail.is-message *,
313+
.feed-detail.is-message h1,
314+
.feed-detail.is-message h2,
315+
.feed-detail.is-message h3,
316+
.feed-detail.is-message h4,
317+
.feed-detail.is-message h5,
318+
.feed-detail.is-message h6 {
319+
font-size: inherit;
320+
line-height: inherit;
321+
}
322+
.feed-detail.is-message h1,
323+
.feed-detail.is-message h2,
324+
.feed-detail.is-message h3,
325+
.feed-detail.is-message h4,
326+
.feed-detail.is-message h5,
327+
.feed-detail.is-message h6 {
328+
margin: 0;
329+
font-weight: bold;
330+
display: inline;
331+
}
310332
.feed-detail.is-message code {
311333
background: rgba(255, 255, 255, 0.08);
312334
padding: 0 4px;
313335
border-radius: 3px;
314336
font-family: 'Fira Code', ui-monospace, monospace;
315-
font-size: 0.92em;
316337
}
317338
.feed-detail.is-message pre {
318339
margin: 4px 0;
@@ -337,6 +358,12 @@
337358
}
338359
.feed-detail.is-message strong { color: #fff; }
339360
.feed-detail.is-message em { color: #d8d0b8; }
361+
.feed-detail.is-message blockquote {
362+
margin: 0;
363+
padding-left: 8px;
364+
border-left: 2px solid rgba(255, 255, 255, 0.2);
365+
opacity: 0.85;
366+
}
340367

341368
/* === Group (By Agent) === */
342369
.feed-group {

0 commit comments

Comments
 (0)