Skip to content

fix(ui): keep uploaded images aligned with their prompts - #147389

Merged
roboclaw-bot merged 1 commit into
mainfrom
openclaw/image-alignment-change-inquiry
Sep 13, 2026
Merged

roboclaw-bot merged 1 commit into
mainfrom
openclaw/image-alignment-change-inquiry

Conversation

@roboclaw-bot

Copy link
Copy Markdown
Collaborator

Related: #131811, #142671.

What Problem This Solves

Fixes large uploaded chat images sitting left of their right-aligned prompts, especially in Safari/WebKit.

User Impact

Uploaded images and their clickable frames line up with the prompt again. Existing preview sizes, aspect ratios, mobile containment, and multi-image galleries stay unchanged.

Why This Change Was Made

The frame's existing width limit applied only to generated images. Applying it at the shared image-frame owner prevents uploaded images from reserving invisible space beside their capped preview. This removes one production line overall.

Evidence

  • New desktop geometry cases fail on the original CSS in Chromium and WebKit; the fixed version passes all six desktop/mobile cases across local-user, peer, and assistant messages.
  • All 12 focused browser tests pass, including existing narrow-lane, tiny/tall generated-image controls, and gallery/hover coverage.
  • Changed-file checks and independent P0–P2 review completed; the review's test callback typing finding was corrected and the final review is clean.
  • WebKit desktop component captures below reproduce 80–87px gaps before → 0px after; mobile remains aligned. They use exact parent/candidate production styles and synthetic content. Full-app loopback navigation was blocked by the host browser/egress policy; these are component evidence, not a claimed end-to-end application run.

Desktop

Before After
WebKit desktop before: image gaps beside right-aligned prompts WebKit desktop after: images align with prompts

Mobile

Before After
WebKit mobile before WebKit mobile after: containment preserved

Apply the existing image-frame width limit to uploaded as well as generated images so the clickable frame cannot reserve space beyond the visible image in WebKit. Add desktop/mobile geometry coverage for user, peer, and assistant images in Chromium and WebKit.

Co-authored-by: steipete <[email protected]>
@clawsweeper

clawsweeper Bot commented Sep 13, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: S maintainer Maintainer-authored PR labels Sep 13, 2026
@roboclaw-bot
roboclaw-bot marked this pull request as ready for review September 13, 2026 20:34
@roboclaw-bot

Copy link
Copy Markdown
Collaborator Author

cc @vyctorbrzezowski — Peter asked to loop you in on the image-alignment fix. Before/after WebKit evidence and the focused regression results are in the PR body.

@clawsweeper

clawsweeper Bot commented Sep 13, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 13, 2026, 4:41 PM ET / 20:41 UTC.

ClawSweeper review

What this changes

The PR extends the existing image-frame width cap to uploaded chat images and adds Chromium/WebKit checks for alignment, proportions, and mobile containment.

Merge readiness

✅ Ready for maintainer review

This remains a useful, focused repair: current main retains the uploaded-image frame mismatch. No blocking correctness or security finding was identified, and the inspected screenshots demonstrate the intended visual improvement.

Priority: P2
Reviewed head: 48edb83581acc634dbf41551fef971dbbaa56306

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused owner-level correction with useful visual evidence and geometry regression coverage; no blocking defect was found.
Proof confidence 🐚 platinum hermit (4/6) ✨ media proof bonus Sufficient (screenshot): Inspected WebKit before/after screenshots exercise the shared production image-frame styles with large uploaded-image fixtures and visibly restore desktop prompt alignment while preserving mobile containment; this supports the narrow visual claim, not full-app upload or network behavior.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (screenshot): Inspected WebKit before/after screenshots exercise the shared production image-frame styles with large uploaded-image fixtures and visibly restore desktop prompt alignment while preserving mobile containment; this supports the narrow visual claim, not full-app upload or network behavior.
Evidence reviewed 7 items Verified production change: The introduced CSS moves the existing 400px maximum from managed frames to all image frames; managed sizing and gallery-specific sizing remain intact.
Current main still needs the repair: Fetched main still gives ordinary frames max-width: 100%, reserving the combined percentage/400px cap for managed frames.
Latest release comparison: The v2026.9.4 stylesheet also applies the 400px frame cap only to managed images; this repair is not present in the inspected latest release.
Findings None None.
Security None None.

How this fits together

The Control UI renders uploaded and generated images inside shared chat frames. Shared styles size those frames, while participant layout rules align media with the accompanying text.

flowchart LR
  A[Uploaded or generated image] --> B[Chat image renderer]
  B --> C[Shared image frame]
  C --> D[Preview width cap]
  E[Message participant] --> F[Left or right alignment]
  D --> F
  F --> G[Image aligned with prompt]
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Source -1, Tests +85. Total +84 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 1 1 2 -1
Tests 1 86 1 +85
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 87 3 +84

Review metrics

None.

Technical review

Best possible solution:

Keep image sizing at the shared frame owner while preserving the existing gallery, aspect-ratio, and participant-alignment contracts.

Do we have a high-confidence way to reproduce the issue?

Yes: large uploaded images exercise the uncapped frame around an already capped preview, supported by current source and the supplied before/after WebKit captures. No current-main browser run was performed during this read-only review.

Is this the best way to solve the issue?

Yes: applying the existing cap at the shared frame is a narrow repair that avoids a second rendering path and preserves the smaller gallery dimensions.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against a441bd3b1efc.

Labels

Label changes:

  • add P2: This repairs a reproducible chat attachment layout defect with limited user impact and a narrow styling change.
  • add proof: sufficient: Contributor real behavior proof is sufficient. Inspected WebKit before/after screenshots exercise the shared production image-frame styles with large uploaded-image fixtures and visibly restore desktop prompt alignment while preserving mobile containment; this supports the narrow visual claim, not full-app upload or network behavior.
  • add proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence. Inspected WebKit before/after screenshots exercise the shared production image-frame styles with large uploaded-image fixtures and visibly restore desktop prompt alignment while preserving mobile containment; this supports the narrow visual claim, not full-app upload or network behavior.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.

Label justifications:

  • P2: This repairs a reproducible chat attachment layout defect with limited user impact and a narrow styling change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • proof: sufficient: Contributor real behavior proof is sufficient. Inspected WebKit before/after screenshots exercise the shared production image-frame styles with large uploaded-image fixtures and visibly restore desktop prompt alignment while preserving mobile containment; this supports the narrow visual claim, not full-app upload or network behavior.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence. Inspected WebKit before/after screenshots exercise the shared production image-frame styles with large uploaded-image fixtures and visibly restore desktop prompt alignment while preserving mobile containment; this supports the narrow visual claim, not full-app upload or network behavior.

Evidence

What I checked:

Likely related people:

  • vyctorbrzezowski: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@roboclaw-bot
roboclaw-bot merged commit 8fd2838 into main Sep 13, 2026
128 checks passed
@roboclaw-bot
roboclaw-bot deleted the openclaw/image-alignment-change-inquiry branch September 13, 2026 21:08
@roboclaw-bot

Copy link
Copy Markdown
Collaborator Author

Merged via squash.

vincentkoc added a commit to Alix-007/openclaw that referenced this pull request Sep 13, 2026
…1-prep

* commit '912ae8d96e5964dfdcdf419b79613fb941cdf0a8': (350 commits)
  fix: keep workspace preparation responsive during cleanup (openclaw#147358)
  docs: alphabetize donors and sponsors and add Red Hat logo (openclaw#147302)
  fix(plugins): retain update authority through doctor effects (openclaw#144316)
  refactor(qa): share Multipass mount retry lifecycle (openclaw#147084)
  fix(memory): emit one JSON result for command failures (openclaw#147366)
  improve(plugins): speed up cold metadata loading (openclaw#147411)
  fix(sessions): avoid duplicate work after waited child replies (openclaw#147394)
  fix(agents): retain outstanding child results in parent context (openclaw#112623)
  test: preserve native workflow loader selection (openclaw#147403)
  fix: reduce repeated work while polling session pull requests (openclaw#147373)
  test(qa): preserve task cancellation across process replacement (openclaw#147382)
  fix: prevent sidebar refresh storms during session activity (openclaw#147400)
  refactor: simplify skills CLI formatting (openclaw#147368)
  fix: prevent Git checkout certificate failures behind egress proxy (openclaw#147410)
  fix(qa): stop live threads after their process leader exits (openclaw#147386)
  refactor(release): share agent turn retry lifecycle (openclaw#147076)
  fix(ui): keep uploaded images aligned with their prompts (openclaw#147389)
  fix(fs): guard skill reads and bound worker bundle staging (openclaw#147336)
  fix(ci): restore Linux service ownership fixtures (openclaw#147398)
  fix(plugins): preserve manifest permissions when building plugins (openclaw#147393)
  ...
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 14, 2026
…7389)

Apply the existing image-frame width limit to uploaded as well as generated images so the clickable frame cannot reserve space beyond the visible image in WebKit. Add desktop/mobile geometry coverage for user, peer, and assistant images in Chromium and WebKit.

Co-authored-by: steipete <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui maintainer Maintainer-authored PR size: S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant