LearnNewsExamplesConnect
Frontmatter
assigneesneo-opus-grace
createdAtNov 9, 2026, 2:43 AM
updatedAtNov 9, 2026, 10:12 AM
githubUrlhttps://github.com/neomjs/neo/issues/20641
authorneo-opus-grace
commentsCount2
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtNov 9, 2026, 10:12 AM
milestonev13.4

A group header drag slides its neighbours and carries its column cells

Closed v13.4.0/archive-v13-4-0-chunk-5 enhancementaigrid
neo-opus-grace
neo-opus-grace commented on Nov 9, 2026, 2:43 AM

Context

The operator's manual retest of examples/grid/headerGroups on dev (36e14fa4ac, after #20630) found that a group header drag works but feels unlike every other drag in the product. The recording shows Q2 dragged after Q3. The proxy is the bare "Q2" label bar, the headers and columns underneath stay put until the release, and then everything jumps at once.

A leaf column drag, a tab drag and an ungrouped header drag all behave differently: the dragged item's neighbours slide aside live as it passes them, and a column drag's proxy carries the column's body cells. The operator: "for tabs as well as non-grouped headers, the not dragged headers slide then drag-moving. this part is missing. also, when dragging a column header, … the drag proxy includes column cells. missing too."

The Problem

#20627 asked for a drop-time design, and #20630 shipped it: "the group row and the leaf row re-project once on drop". The slot logic is right (never inside another group, never out of its region, scrolled or not). What it lacks is the feedback the leaf drag gives: a live preview of the new order, and a proxy that shows what is moving.

The Architectural Reality

  • Leaf drag: src/draggable/grid/header/toolbar/SortZone.mjs, extending src/draggable/container/SortZone.mjs. onDragMove calls switchItems once the pointer crosses a neighbour's threshold; that's the live slide. The header zone builds its proxy with the column's body cells cloned in (body.getColumnCells(dataField), the proxy-cell block around lines 161–231). Groups are already respected there: a leaf stays inside its group, and a release outside it parks (isOutsideGroup, setReorderParked).
  • Group drag: src/grid/header/GroupRow.mjs runs its own gesture on the base Neo.draggable.DragZone, with useProxyWrapper: false. The proxy is the cloned group cell. The slot comes from GroupRow.getGroupDropOrder over GroupRow.getUnits. The commit is columns.move per leaf, then grid.Container#onColumnsMutate, then Toolbar#measureAfterUpdate. The zone registers under the row, and the cells turn draggable only once that registration lands.

The Fix

The group drag gets the leaf drag's feedback, without a second gesture engine:

  1. Live preview. While a group cell drags, its run of leaves moves as one block among the region's top-level units. A neighbouring unit (a group, or an ungrouped column) slides aside when the block passes its centre, with the leaf zone's switch animation. The group row re-projects with the leaves.
  2. Proxy payload. The proxy shows the group cell over its leaf headers and their body cells, the way a leaf proxy shows its column.
  3. Commit = preview. The release keeps the previewed order with no second jump. Escape slides everything back.

Reuse before adding: either give the header SortZone a unit mode that switches a run of items, or extract its switch and cell-proxy code into helpers that both drags call. GroupRow.getUnits / getGroupDropOrder keep owning which slots are legal.

Acceptance Criteria

  • Dragging Q3 toward Q2 slides Q2's leaves and body columns aside live once Q3's proxy passes Q2's centre. The release commits that order with no further movement (e2e on examples/grid/headerGroups: mid-drag, Q2's first leaf header has moved right by Q3's width before the release).
  • The group proxy shows the group cell, its leaf headers and their rendered body cells (e2e: mid-drag, the proxy holds Jul, Aug and Sep header buttons and the first row's Jul cell value).
  • The existing #20627 contract holds: never inside another group, never out of its region, scrolled grids, Escape mid-drag restoring the original order (the HeaderGroups e2e group arms keep passing).
  • A leaf drag, in a group or ungrouped, is unchanged (the HeaderGroups leaf arms keep passing).
  • The operator's manual pass on examples/grid/headerGroups accepts the gesture.

Out of Scope

  • A leaf proxy leaving its group's extent, and the extra slide that follows: #20626 (PR #20632; evidence with Vega and Sophie).
  • The demo's themes: #20635 (draft #20638).

Related

  • #20627 (closed, the drop-time design) and PR #20630 (merged at 36e14fa4ac).
  • #20626 / PR #20632.
  • Scope: surfaced in #20630's manual acceptance pass. 13.4 blocker. The operator (2026-11-09): "we do not want to rush a release. quality matters."
  • Base: #20632 (ffa5c47ecf) reworked the header SortZone's group edge (groupOverflow, moveToGroupEdge). This work builds on that, never on the pre-#20632 zone.

Live latest-open + closed sweep: I read the latest 20 open issues and ran a closed search ("group header drag") at 2026-11-09T01:45Z; #20627's scope was read. A2A in-flight sweep: Sophie (01:41Z) leaves the group gesture with me. Memory Core sweep: no earlier live-preview attempt for group drags. Own assignments: none open. No equivalent ticket found.

Retrieval Hint: "group header drag live slide proxy column cells parity with leaf SortZone"

Origin Session ID: c09810ef-873c-475b-94b9-7e0d31089f2d

tobiu referenced in commit e77582c - "feat(grid): a group header drag slides its neighbours and carries its columns (#20641) (#20644) on Nov 9, 2026, 10:12 AM
tobiu closed this issue on Nov 9, 2026, 10:12 AM
tobiu referenced in commit 5788bef - "feat(examples): add Header Groups theme controls (#20635) (#20638) on Nov 9, 2026, 10:38 AM