Context
Split from #9075 with @tobiu's approval (option A, 2026-09-14). The PR resolving #9075 narrows it to what the intake evidence showed was broken and shippable: column selection that never repainted its cells, the three drifted copies of that logic, and a row or column highlight surviving a model swap-out. This ticket carries #9075's remaining objectives, reshaped by the intake finding, because two of them were prescribed with mechanisms that do not fit the code as it stands.
The Problem
src/selection/grid still tells its item kinds apart by string, and its class hierarchy still forces duplication:
- Row versus cell, by string.
BaseModel#updateBodyRows decides per item with item.toString().includes('__') (BaseModel.mjs:98): a logical cell id is recordId__dataField, a record id is not. The branch is load-bearing — one CellRowModel instance feeds record ids (selectRow / deselectRow → updateRows(recordId)) and logical cell ids (CellModel#onCellClick → toggleSelection) through the same method. By construction the predicate cannot distinguish a record whose key itself contains __. #9012 already gave rows and cells data-record-id / data-field attributes so selection code need not reverse-engineer ids; this branch predates using them here.
- Row-selecting models, by ntype.
View#rowSelectionModel (View.mjs:126–129) recognises a row-selecting model by selectionModel?.ntype?.includes('row'), and both the flag adoption and the paint getters read it. #18626 deferred "a declared row-selection trait on the model classes" to #9075.
- Duplication the hierarchy forces. After #9075's dedupe,
CellColumnModel and CellColumnRowModel still carry two identical overrides (onCellClick, onNavKeyColumn) because they extend different parents (CellModel / CellRowModel). Neo's mixins cannot host them: mixinProperty (Neo.mjs:1184) assigns over the class's own method, and a copied method keeps its home object, so super inside it resolves against the mixin's parent.
internalId versus recordId handling, #9075's fourth objective, written in 2026-02 — before #18661 made the View own the single model. Whether it still applies is unverified.
The Architectural Reality
src/selection/grid/BaseModel.mjs — updateRows / updateBodyRows; selectRow / deselectRow / deselectAllRows; select / deselect / deselectAll; and the column half added by #9075's PR (setSelectedColumns, updateColumns, stepSelectedColumn).
src/selection/grid/{RowModel,CellModel,CellRowModel,CellColumnModel,CellColumnRowModel,ColumnModel}.mjs.
src/grid/View.mjs — rowSelectionModel and its consumers: the flag adoption on store bind/load, and the paint getters.
src/grid/Row.mjs — renders row, cell and column selection state from the View's model; grid/Body.mjs#fireCellEvent resolves dataField / record from the data-* attributes.
The Fix
- Type the updates where the caller knows the type. The row callers —
selectRow, deselectRow, deselectAllRows — always pass record ids. The generic select / deselect / deselectAll pass the model's own items. updateBodyRows stops inspecting strings.
- Declare the trait. A row-selecting model says so on its class;
View#rowSelectionModel reads that instead of an ntype substring.
- Compose the column-selecting Cell* pair without relying on
super inside a mixin — or record, with evidence, that two small overrides are the right shape for two parents.
- Verify objective 4 at intake against the post-#18661 code; normalize with an arm, or close it out as already done.
Acceptance Criteria
Out of Scope
- Column-selection repaint, the column-logic dedupe, and swap-out repaint — delivered by the PR resolving #9075.
- Keyboard navigation across split bodies (#9496).
- Split-row selection for the multi-body grid (#9492).
Related
- #9075 — the source ticket and its intake finding.
- #9012 — the split dataset (
data-record-id / data-field).
- #9014 — granular row/cell updates, the precedent #9075's column repaint follows.
- #18626 / #18661 — the View-owned selection model; where the row-selection trait was deferred.
- #9492, #9496 — adjacent multi-body selection work.
unowned-rationale: split from #9075 at the operator's request so #9075 can close on what shipped; parked for the next engine-selection lane rather than claimed now.
Live latest-open sweep: latest 20 open issues at 2026-09-14T19:29Z, plus gh issue list --state all --search "rowSelectionModel OR updateBodyRows" (only #9075, #18626, #12758) — no equivalent. A2A in-flight claim sweep: last 30 messages, all read states, at 19:29Z — no claim on grid selection. Own-assignment sweep: nothing overlapping. Semantic sweep: ask_knowledge_base(type='ticket') surfaced #12758, #9012, #9014, #9492 — none owns these objectives. Memory Core: the 2026-02-06 session behind #9014 fixed the cell-selection form of the same repaint gap.
Retrieval Hint: "grid selection models row versus cell id string heuristic, ntype row trait, CellColumnModel CellColumnRowModel duplicated override"
Origin Session ID: b43a5b46-c79a-40ce-8eb8-d4eb122f4cd8
Context
Split from #9075 with @tobiu's approval (option A, 2026-09-14). The PR resolving #9075 narrows it to what the intake evidence showed was broken and shippable: column selection that never repainted its cells, the three drifted copies of that logic, and a row or column highlight surviving a model swap-out. This ticket carries #9075's remaining objectives, reshaped by the intake finding, because two of them were prescribed with mechanisms that do not fit the code as it stands.
The Problem
src/selection/gridstill tells its item kinds apart by string, and its class hierarchy still forces duplication:BaseModel#updateBodyRowsdecides per item withitem.toString().includes('__')(BaseModel.mjs:98): a logical cell id isrecordId__dataField, a record id is not. The branch is load-bearing — oneCellRowModelinstance feeds record ids (selectRow/deselectRow→updateRows(recordId)) and logical cell ids (CellModel#onCellClick→toggleSelection) through the same method. By construction the predicate cannot distinguish a record whose key itself contains__. #9012 already gave rows and cellsdata-record-id/data-fieldattributes so selection code need not reverse-engineer ids; this branch predates using them here.View#rowSelectionModel(View.mjs:126–129) recognises a row-selecting model byselectionModel?.ntype?.includes('row'), and both the flag adoption and the paint getters read it. #18626 deferred "a declared row-selection trait on the model classes" to #9075.CellColumnModelandCellColumnRowModelstill carry two identical overrides (onCellClick,onNavKeyColumn) because they extend different parents (CellModel/CellRowModel). Neo's mixins cannot host them:mixinProperty(Neo.mjs:1184) assigns over the class's own method, and a copied method keeps its home object, sosuperinside it resolves against the mixin's parent.internalIdversusrecordIdhandling, #9075's fourth objective, written in 2026-02 — before #18661 made the View own the single model. Whether it still applies is unverified.The Architectural Reality
src/selection/grid/BaseModel.mjs—updateRows/updateBodyRows;selectRow/deselectRow/deselectAllRows;select/deselect/deselectAll; and the column half added by #9075's PR (setSelectedColumns,updateColumns,stepSelectedColumn).src/selection/grid/{RowModel,CellModel,CellRowModel,CellColumnModel,CellColumnRowModel,ColumnModel}.mjs.src/grid/View.mjs—rowSelectionModeland its consumers: the flag adoption on store bind/load, and the paint getters.src/grid/Row.mjs— renders row, cell and column selection state from the View's model;grid/Body.mjs#fireCellEventresolvesdataField/recordfrom thedata-*attributes.The Fix
selectRow,deselectRow,deselectAllRows— always pass record ids. The genericselect/deselect/deselectAllpass the model's own items.updateBodyRowsstops inspecting strings.View#rowSelectionModelreads that instead of an ntype substring.superinside a mixin — or record, with evidence, that two small overrides are the right shape for two parents.Acceptance Criteria
BaseModel#updateBodyRowsinspects no item strings; row and cell repaints are typed at the call site; a record whose key contains__repaints as a row.View#rowSelectionModelreads a declared trait; nontypesubstring test remains. The flag-following arms inViewOwnedSelectionModel.spec.mjsstay green forRowModel,CellRowModelandCellColumnRowModel, and stay off forCellModelandColumnModel.CellColumnModelandCellColumnRowModelcarry no duplicated override — or this ticket records why two overrides are the right shape.internalId/recordIdhandling is verified at intake: normalized with an arm, or closed out with the evidence that it already is.unit/grid/ColumnSelection.spec.mjsandViewOwnedSelectionModel.spec.mjsstay green.Out of Scope
Related
data-record-id/data-field).unowned-rationale: split from #9075 at the operator's request so #9075 can close on what shipped; parked for the next engine-selection lane rather than claimed now.
Live latest-open sweep: latest 20 open issues at 2026-09-14T19:29Z, plus
gh issue list --state all --search "rowSelectionModel OR updateBodyRows"(only #9075, #18626, #12758) — no equivalent. A2A in-flight claim sweep: last 30 messages, all read states, at 19:29Z — no claim on grid selection. Own-assignment sweep: nothing overlapping. Semantic sweep:ask_knowledge_base(type='ticket')surfaced #12758, #9012, #9014, #9492 — none owns these objectives. Memory Core: the 2026-02-06 session behind #9014 fixed the cell-selection form of the same repaint gap.Retrieval Hint: "grid selection models row versus cell id string heuristic, ntype row trait, CellColumnModel CellColumnRowModel duplicated override" Origin Session ID: b43a5b46-c79a-40ce-8eb8-d4eb122f4cd8