You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Row Selection: Incorrect Parent Row Selection Behavior with Nested Data #6049
The row selection behavior for parent rows with subRows is inconsistent and incorrect in certain scenarios. The parent row selection state does not properly reflect the selection state of its children, leading to unexpected behavior where:
1. Parent becomes unchecked when all children are selected 2. Parent becomes checked when all children are unchecked
Expected vs Actual Behavior
Expected Behavior
Parent should be checked: Only when ALL child rows are selected
Parent should be indeterminate: When SOME (but not all) child rows are selected
Parent should be unchecked: When NO child rows are selected
Actual Behavior
The parent selection state becomes inverted in certain sequences of selection/deselection operations.
Steps to Reproduce
Let's say we have 4 rows, where one is a parent and 3 are subrows
Scenario 1: Parent becomes unchecked when all children are selected
Initial State: All rows unchecked
Check one subrow (id: "1.1") → Parent becomes indeterminate (correct)
Check another subrow (id: "1.2") → Parent remains indeterminate (correct)
BUG: Check the last subrow (id: "1.3") → Parent becomes unchecked instead of checked
Expected: Parent should be checked since all children are selected Actual: Parent shows as unchecked despite all children being selected
Scenario 2: Parent becomes checked when all children are unchecked
Initial State: All rows unchecked
Check parent row (id: "1") → All subrows get selected (correct)
Uncheck one subrow (id: "1.1") → Parent becomes indeterminate (correct)
Uncheck another subrow (id: "1.2") → Parent remains indeterminate (correct)
BUG: Uncheck the last subrow (id: "1.3") → Parent becomes checked instead of unchecked
Expected: Parent should be unchecked since no children are selected Actual: Parent shows as checked despite all children being unchecked
Additional Context
This behavior is inconsistent with standard UI patterns found in most tree/hierarchical selection components, where parent selection state should always accurately reflect the aggregate state of its children.
@tannerlinsley
You have great logical component, but this issue is really huge problem of the TS Table for usage with Tree/TreeList components.
Could you publish a solution, if it already exists, or increase the importance of the task.
Thanks.
Activity
urrri-redis commentedon Sep 2, 2025
@tannerlinsley
You have great logical component, but this issue is really huge problem of the TS Table for usage with Tree/TreeList components.
Could you publish a solution, if it already exists, or increase the importance of the task.
Thanks.
fix: honor selection rules in select-all paths, add deselectParents o…