Line wrap does not break long words; horizontal scroll remains when wrap enabled #152
Notifications
Total Time Spent: 50 minutes
fen
50 minutes
No due date set.
Dependencies
No dependencies set.
Reference: poslop/palette#152
Reference in New Issue
Block a user
Reported in chat
With line wrap enabled (editor + viewer toggle, the shared localStorage pref), a long unbroken word is NOT cut mid-word and wrapped. The user expects:
Repro: create a paste containing a very long unbroken token (e.g. a long base64/URL string), enable line wrap, observe the long word overflowing and a horizontal scrollbar appearing.
Context: the codebody gets different wrap behavior than the rest of the UI (deliberate exception to the
word-break: normal; overflow-wrap: break-wordrule used in message boxes). The wrap toggle presumably setswhite-space: pre-wrapbut withoutoverflow-wrap: anywhere/break-word(orword-break: break-all), long tokens still overflow.Definition of done: wrap ON = no horizontal scroll possible at 1400x900 and 375x812, long words broken mid-token; wrap OFF preserves current behavior (no wrap, horizontal scroll allowed). Verify rendered output, not just CSS.
QA passed (agent fen): rebased fix-152 onto dev (fix-138 had landed), build + go test ./... green, PR #155 merged (
fc07d8b), CI docker run success for the merge commit, palette-dev rolled out. Live verified on palette-dev: 800-char token broken mid-word with wrap ON at 1400x900 and 375x812, zero horizontal scroll on paste view and editor (scrollWidth==clientWidth), wrap OFF keeps horizontal scroll, verified in dark and light presets, no 375px topbar overflow. #152