[PR #2667] [CLOSED] [GUI] serve/web: keep wide content (long URLs, code lines, wide tables) inside the viewport on narrow screens #4203

Closed
opened 2026-11-07 15:33:59 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Niko1221/Strata/pull/2667
Author: @jkir4n
Created: 10/15/2026
Status: ❌ Closed

Base: main ← Head: fix/web-narrow-screen-overflow


📝 Commits (1)

  • bcb91a1 serve/web: keep wide content (long URLs, code, wide tables) inside the viewport on narrow screens

📊 Changes

1 file changed (+3 additions, -2 deletions)

View changed files

📝 serve/web/app.css (+3 -2)

📄 Description

Area: [GUI]

Problem and result

On a narrow screen (phone), an assistant reply containing one long unbroken string (URL, code line) or a wide table stretches the chat column past the viewport: the right side is clipped and unreachable, and the page heading and composer shift with it. After the change the assistant text breaks long strings, wide tables scroll inside their own bubble, and the column stays at viewport width.

none

Approach

serve/web/app.css only, two rules:

  • .st-msg--assistant .st-bubble { width: 100%; overflow-wrap: anywhere; } — the assistant bubble now breaks long unbroken strings, matching the user bubble, which already carried overflow-wrap: anywhere.
  • .st-bubble table { … display: block; max-width: 100%; overflow-x: auto; } — wide tables scroll horizontally inside their bubble instead of widening the column.

The .view { min-width: 0 } guard from the original revision is already present on main (line 7 of this file), so this revision no longer touches it. Desktop layout is unchanged.

Validation

Passed: measured at a 390×844 viewport against 0.1.44.1 with three messages (long URL / long code line / wide table): before — chat column 752 px, bubbles 718 px, right edge 346 px off-screen; after — column 390 px, bubbles 356 px, everything on screen (the URL wraps, the code block and the table scroll inside themselves). Desktop at 1280 px: no overflow before or after, normal prose unaffected.

Failed: none observed.

Not run: not re-measured on 0.2.0-beta — the rebase re-applied the two rules onto current main, where the CSS they touch is unchanged; the measurements above are from the original 0.1.44.1 revision. No browser engine other than Chromium was tested.

Limits

Firefox and Safari not tested. overflow-wrap: anywhere permits mid-word breaks in assistant prose — accepted trade-off, and already the behaviour of user bubbles.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Niko1221/Strata/pull/2667 **Author:** [@jkir4n](https://github.com/jkir4n) **Created:** 10/15/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `fix/web-narrow-screen-overflow` --- ### 📝 Commits (1) - [`bcb91a1`](https://github.com/Niko1221/Strata/commit/bcb91a16fec702b74592b11621ebdd4db76aa875) serve/web: keep wide content (long URLs, code, wide tables) inside the viewport on narrow screens ### 📊 Changes **1 file changed** (+3 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `serve/web/app.css` (+3 -2) </details> ### 📄 Description **Area:** [GUI] ## Problem and result On a narrow screen (phone), an assistant reply containing one long unbroken string (URL, code line) or a wide table stretches the chat column past the viewport: the right side is clipped and unreachable, and the page heading and composer shift with it. After the change the assistant text breaks long strings, wide tables scroll inside their own bubble, and the column stays at viewport width. ## Related discussion none ## Approach `serve/web/app.css` only, two rules: - `.st-msg--assistant .st-bubble { width: 100%; overflow-wrap: anywhere; }` — the assistant bubble now breaks long unbroken strings, matching the user bubble, which already carried `overflow-wrap: anywhere`. - `.st-bubble table { … display: block; max-width: 100%; overflow-x: auto; }` — wide tables scroll horizontally inside their bubble instead of widening the column. The `.view { min-width: 0 }` guard from the original revision is already present on `main` (line 7 of this file), so this revision no longer touches it. Desktop layout is unchanged. ## Validation **Passed:** measured at a 390×844 viewport against 0.1.44.1 with three messages (long URL / long code line / wide table): before — chat column 752 px, bubbles 718 px, right edge 346 px off-screen; after — column 390 px, bubbles 356 px, everything on screen (the URL wraps, the code block and the table scroll inside themselves). Desktop at 1280 px: no overflow before or after, normal prose unaffected. **Failed:** none observed. **Not run:** not re-measured on 0.2.0-beta — the rebase re-applied the two rules onto current `main`, where the CSS they touch is unchanged; the measurements above are from the original 0.1.44.1 revision. No browser engine other than Chromium was tested. ## Limits Firefox and Safari not tested. `overflow-wrap: anywhere` permits mid-word breaks in assistant prose — accepted trade-off, and already the behaviour of user bubbles. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-07 15:33:59 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#4203
No description provided.