fix(chat): restore table vertical scroll and cell word wrapping - #248
Open
mrohan-sq wants to merge 1 commit into
Open
fix(chat): restore table vertical scroll and cell word wrapping#248mrohan-sq wants to merge 1 commit into
mrohan-sq wants to merge 1 commit into
Conversation
The table scroll container had overflow-y: hidden, which clipped rows below Streamdown's 300px max-height with no way to scroll. This was worsened by PR block#207 (smaller wrapping headers → narrower columns → taller body rows). Long unbreakable strings in td cells also caused horizontal overflow instead of wrapping. - Change overflow-y: hidden → auto on the table scroll container - Add overflow-wrap: break-word to td cells - Update tests to match
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Tables in chat responses were cutting off text. Two CSS issues combined to cause this:
overflow-y: hiddenon the table scroll container overrode Streamdown's defaultoverflow-y: auto, completely disabling vertical scrolling. Combined with Streamdown's defaultmaxHeight: 300px, any table taller than 300px had its bottom rows clipped with no way to scroll.No
overflow-wrapontdcells — long unbreakable strings (URLs, file paths, code identifiers) caused horizontal overflow instead of wrapping within cells.PR #207 (smaller wrapping headers) made this worse: wrapping headers narrow columns → body text wraps more → rows get taller → more content falls below the 300px cutoff.
Changes
overflow-y: hidden→overflow-y: autoon the table scroll container (globals.css)overflow-wrap: break-wordtotdcells (globals.css)globals.streamdown-table.test.tsto assert the new behaviorRelated issue
none found
Testing