From 5f869128873f8f5aed13406e2e12928f54dfb887 Mon Sep 17 00:00:00 2001 From: Pratyush Sharma <56130065+pratyush618@users.noreply.github.com> Date: Sun, 12 Jul 2026 12:42:56 +0530 Subject: [PATCH] fix(docs): stop table-cell code breaking mid-token The article-wide `overflow-wrap: anywhere` broke inline code like `str | None` character-by-character when a param table's type column was squeezed by a long description. Keep cell code on one line; wide tokens use the wrapper's scroll. --- docs/app/styles/docs.css | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/app/styles/docs.css b/docs/app/styles/docs.css index 0f5e51bb..84c7eada 100644 --- a/docs/app/styles/docs.css +++ b/docs/app/styles/docs.css @@ -847,6 +847,14 @@ body { .md-table tr td:first-child { white-space: nowrap; } +/* Inline code in cells (types like `str | None`, defaults, identifiers) must + stay on one line: the article-wide `overflow-wrap: anywhere` otherwise breaks + them character-by-character when a column is squeezed by a long description. + Genuinely wide tokens overflow into the wrapper's horizontal scroll instead. */ +.md-table td code { + white-space: nowrap; + overflow-wrap: normal; +} .md-table a { color: var(--indigo-br); border-bottom: 1px solid var(--indigo-line);