mirror of
https://github.com/siteboon/claudecodeui.git
synced 2026-07-01 10:02:57 +08:00
The custom mobile text-selection layer positioned the start handle at `x - HANDLE_SIZE_PX / 2`, so a selection beginning at column 0 placed it at ~-11px. The overlay clips with overflow:hidden, leaving only a sliver against the screen edge that was impossible to grab — making it hard to adjust the selection start point on the left edge. Clamp each handle's horizontal position to stay fully within the terminal area. This is visual only; drag tracking uses the finger's coordinates, so selection accuracy is unchanged. Also protects the end handle from being clipped at the right edge.