Skip to content

Row/SubRow selection not working as expected #3465

Closed

Description

@natalia-mh

Describe the bug (required)
When I select a parent row and deselect a subRow, the parent row remains checked

Provide an example via Codesandbox! (required)
https://codesandbox.io/s/react-table-grouping-selection-subrows-forked-kkftb?file=/src/makeData.js:70-79

Steps To Reproduce (required)
Steps to reproduce the behavior:

  1. Go to table
  2. Select parent row (+)
  3. Expand subRows (+)
  4. Deselect a subRow/subRows
  5. Error: The parent row remains checked

Expected behavior (Recommended)
The parent row should not be checked when subRow/subRows is/are deselected

Screenshots
image
image

Desktop (please complete the following information):

  • OS: iOS
  • Browser: chrome, safari, firefox
  • Version 7.7.1

Additional context
It does not happen if we first select the subRows and deselect them

In grouping selection, the expanded rows selection works as expected
https://codesandbox.io/s/github/tannerlinsley/react-table/tree/master/examples/kitchen-sink?from-embed=&file=/src/App.js

Activity

  1. dgattey commented on Nov 30, 2021

    @dgattey

    I just came here to report the same bug - here's another CodeSandbox reproduction of it https://codesandbox.io/s/condescending-germain-lbn07. Thanks!

  2. dgattey commented on Nov 30, 2021

    @dgattey

    Additionally, it looks like if a subrow is indeterminately selected, its parent is NOT also indeterminately selected (but should be). "company" here is the parent that should be indeterminately selected as its child is.
    image

  3. dgattey commented on Nov 30, 2021

    @dgattey

    #3106 This looks to be the same bug

  4. github-actions commented on Apr 8, 2022

    @github-actions
    Contributor

    This issue is being marked as stale (no activity in the last 14 days)

  5. github-actions commented on Apr 8, 2022

    @github-actions
    Contributor

    This issue has been detected as stale and automatically closed. It's very likely that your issue has remained here this long because it would require breaking changes to v7. React Table v8 is currently in alpha (soon beta!) and already contains bug fixes, performance improvements and architectural changes that likely address this issue.

    • If your v7 issue has been previously labeled as requiring breaking changes, please try the new v8 alpha/beta releases
    • If your v7 issue has not already been labeled as a breaking change, open a new issue.
    • If this was a v8 issue and was closed by mistake, please reopen or leave a comment below.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions