Composer reply buttons are overlapping and unusable on mobile
Composer reply buttons overlapping
Looking at the screenshot: in the reply composer's control row, the "Ask Claude" label text is painted ~75px to the right of its checkbox, directly on top of the "+ Image" button, while Model/Kind/Post wrap fine below. So it's not the row wrapping that's broken — it's the .ask-claude label / attach button layout on iOS Safari.
Plan:
- Rebuild the exact
form.compose .rowmarkup +globals.cssin a static harness and screenshot it at iPhone width in WebKit (and Chromium) to pin down which rule misbehaves. - Fix in
app/globals.css(and wrap the label text in a<span>incomposer.tsx/new-thread-form.tsxif needed so the text is a real flex item rather than an anonymous one). - Verify with a screenshot, commit, push
thread/e988ed07.
threadide@d8fb645What was wrong
The screenshot is the pre-fix rendering of the bug from PR #1 (f7c6cda, merged 4 min before this report) — most likely the deploy hadn't propagated or the phone had cached CSS. The geometry matches exactly:
form.compose input { width: 100% … }also hit the Ask Claude checkbox, so its layout box became ~90px wide inside the label.- iOS Safari paints a checkbox at native size at the left of its box no matter how wide the box is, so what you see is a small tick on the left and the "Ask Claude" text pushed one label-width to the right, painted over "+ Image" (whose position was computed from the label's intrinsic width).
- Model/Kind/Post wrapped fine; only the label/attach pair was broken.
What I changed (threadide/app/globals.css)
PR #1 already excluded [type=checkbox]; I made it structurally impossible to recur:
- The text-field chrome now matches only text-like inputs:
form.compose input:where(:not([type]), [type="text"], [type="url"], [type="email"], [type="search"], [type="password"]). Every text input in the app is type-less, so nothing else changes; radios/ranges/file inputs added later can't inheritwidth:100%either. - Kept the
.ask-claude input[type=checkbox]size pin and documented the iOS painting behaviour next to it.
Verification
- Chromium @ 390px (screenshot attached): label is 97px wide, checkbox 16px at x=16, "+ Image" at x=121, no overlap; Kind wraps to line 2, Post & run is a full-width thumb target.
- Caveat: Chromium doesn't reproduce the original drift (it shrinks the cyclic-percentage checkbox instead of painting it native-size), and WebKit can't run in this sandbox, so the iOS explanation is from the layout math, not a device repro. If you still see the overlap on the deployed build after this lands, please hard-refresh and re-screenshot.
Follow-up worth a separate thread (not done here)
The textarea/inputs use font: inherit = 15px; iOS Safari auto-zooms the page when focusing any field under 16px, which is another annoyance in the mobile composer. Bumping compose fields to 16px on max-width: 560px would fix it.
Diff · 1 files
--- a/threadide/app/globals.css
+++ b/threadide/app/globals.css
@@ -69,7 +69,10 @@
form.compose textarea { width: 100%; min-height: 110px; ... }
-form.compose input:not([type="checkbox"]) { width: 100%; padding: 8px 10px; border-radius: 8px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font: inherit; margin-bottom: 8px; }
+/* Text-field chrome for compose forms. Scoped to text-like inputs on purpose: this used to be a bare
+ `form.compose input` and it swallowed the Ask Claude checkbox (width:100% → label text painted over
+ the next control on iOS) and would do the same to any radio/range/file input added later. */
+form.compose input:where(:not([type]), [type="text"], [type="url"], [type="email"], [type="search"], [type="password"]) { width: 100%; padding: 8px 10px; border-radius: 8px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font: inherit; margin-bottom: 8px; }
form.compose .row { display: flex; flex-wrap: wrap; align-items: center; margin-top: 8px; gap: 8px; row-gap: 10px; }
@@ -108,3 +111,4 @@
-/* Beats the generic form.compose text-input rule: the checkbox must stay 16px so the label hugs it. */
+/* Pinned size + no margin so the label hugs the box. iOS paints checkboxes at native size no matter what
+ the layout box is, so any stray width here shows up as the label text drifting away from the tick. */
.ask-claude input[type="checkbox"] { flex: none; width: 16px; height: 16px; margin: 0; padding: 0; accent-color: var(--accent); }
