Skip to content

Move the composer strips out of the pop-out drag region - #74611

Merged
OutThisLife merged 1 commit into
mainfrom
bb/composer-strips-outside
Jul 30, 2026
Merged

OutThisLife merged 1 commit into
mainfrom
bb/composer-strips-outside

Conversation

@OutThisLife

Copy link
Copy Markdown
Contributor

Summary

The micro-action pills, the status stack, and the composer.underside strip all rendered inside the composer root. The pop-out drag region is an absolute inset-0 child of that root, so everything alongside it was inside the grab area by construction — hovering a pill hatched the composer, and a press landing between two badges started a peel-out drag.

That was getting patched at the gesture rather than the structure: a composer-no-drag exclusion in gestureTargetOk, a matching guard on the double-click toggle, and a strip juggling z-index and pointer-events to climb back over a region painting on top of it. Each fix traded away a bit of the vertical band the composer is actually grabbed by.

This adds a dock column that owns the composer's position and stacks its children in flow, bottom-anchored:

composer-dock
├── micro-action strip
├── status stack
├── composer            ← drag region lives in here, and only here
└── underside strip

The strips are siblings of the composer rather than children, so landing in the grab area is impossible instead of excluded. gestureTargetOk and the double-click handler revert to their pre-existing form, and the shared strip constant drops to a bare flex row.

Two things fall out of the move:

Alignment stops needing a magic number. The strips sat in different containing blocks — one in the stack's absolute lane resolving against the root's padding box, one in the root's content box — and the root carries padding-inline: 5px for the grab margin. That was the 5px the pills hung left by, and the pl-[0.3125rem] in #73741 was compensating for it. One parent and a shared px-[5px] line both strips up with the surface directly.

The status stack stops measuring itself. It published --status-stack-measured-height only because it was out of flow and the composer's measurement couldn't see it. As a dock child it's covered by the dock's own height, so the var, its ResizeObserver effect, and the detached-node cleanup that effect needed all go — thread clearance now reads one number instead of summing two. Note this also removes surface-var-lifecycle.test.tsx: it guarded a real regression (a stale clearance written to :root from a detached node), but the mechanism it tested no longer exists, and the bug class is now structurally unreachable.

Net −139 lines.

Test plan

  • tsc --noEmit clean, eslint 0 errors
  • 28 files / 221 tests pass (vitest run src/app/chat/composer src/app/chat/surface-vars.test.ts from apps/desktop)
  • Pills, status stack, and underside all verified outside the composer root
  • Pills, underside chip, and composer surface share one left edge with no compensating padding
  • Composer still drags and double-click-to-float still works from the margin around the surface, with the full vertical band intact
  • Pills remain above the status card and the billing banner

The micro-action pills, the status stack, and the underside strip all
rendered inside the composer root. The pop-out drag region is an
`absolute inset-0` child of that root, so everything alongside it was
inside the grab area by construction — hovering a pill hatched the
composer and a press between two badges started a peel-out drag.

That was being patched at the gesture instead of the structure: a
`composer-no-drag` exclusion in gestureTargetOk, a matching guard on the
double-click toggle, and a strip that juggled z-index and pointer-events
to climb back over a region painting on top of it.

Introduce a dock column that owns the composer's position and stacks its
children in flow, bottom-anchored:

    composer-dock
    ├── micro-action strip
    ├── status stack
    ├── composer            <- drag region lives in here, and only here
    └── underside strip

The strips are siblings of the composer rather than children, so landing
in the grab area is impossible rather than excluded. gestureTargetOk and
the double-click handler go back to what they were, and the shared strip
constant drops to a bare flex row.

Two things fall out of the move:

Alignment stops needing a magic number. The strips sat in different
containing blocks — one in the stack's absolute lane resolving against
the root's padding box, one in the root's content box — and the root
carries `padding-inline: 5px` for the grab margin, which is the 5px the
pills hung left by. One parent and a shared `px-[5px]` line both strips
up with the surface directly.

The stack stops measuring itself. It published
--status-stack-measured-height only because it was out of flow and the
composer's measurement couldn't see it. As a dock child it's covered by
the dock's own height, so the var, the ResizeObserver effect, and the
detached-node cleanup it needed all go, and thread clearance reads one
number instead of summing two.
@alt-glitch alt-glitch added type/bug Something isn't working P3 Low — cosmetic, nice to have comp/desktop Electron desktop app (apps/desktop/*) needs-decision Awaiting maintainer decision before any implementation labels Jul 30, 2026
@github-actions

github-actions Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

૮ >ﻌ< ა ci review

ran on e17d058

ℹ️ Info

Desktop E2E visual evidence · View test artifacts · View job

1 visual diff.

inline evidence is publishing...

@OutThisLife
OutThisLife merged commit eefcc09 into main Jul 30, 2026
36 checks passed
@OutThisLife
OutThisLife deleted the bb/composer-strips-outside branch July 30, 2026 06:05
randlee pushed a commit to randlee/hermes-agent that referenced this pull request Aug 11, 2026
…trips-outside

Move the composer strips out of the pop-out drag region
33hodl pushed a commit to 33hodl/hermes-agent that referenced this pull request Aug 12, 2026
…trips-outside

Move the composer strips out of the pop-out drag region
prmartinow pushed a commit to prmartinow/hermes-agent that referenced this pull request Aug 26, 2026
…trips-outside

Move the composer strips out of the pop-out drag region
melon-xf added a commit to melon-xf/hermes-agent that referenced this pull request Sep 3, 2026
…trips-outside

Move the composer strips out of the pop-out drag region
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/desktop Electron desktop app (apps/desktop/*) needs-decision Awaiting maintainer decision before any implementation P3 Low — cosmetic, nice to have type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants