Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Table Column cellRenderer Not Re-Rendering Appropriately With Interactable Content (Checkbox) #3921

Open
Austint30 opened this issue Jan 14, 2020 · 1 comment

Comments

@Austint30
Copy link

Austint30 commented Jan 14, 2020

Environment

  • Package version(s): @blueprintjs/table: 3.8.2
  • Browser and OS versions: Chrome: v79.0.3945.117, Windows 10 v1903

If possible, link to a minimal repro: https://codesandbox.io/s/blueprint-interactive-cell-checkbox-bug-8vnlk?fontsize=14&hidenavigation=1&theme=dark

Steps to reproduce

  1. In the above CodeSandbox link click a checkbox in the table.
  2. Notice that the table row highlights but the Checkbox stays unchecked.
  3. Click the checkbox again and now it finally re-renders in checked state.

Actual behavior

The cellRenderer function for the checkbox Column is not being called upon state change of which rows are selected. This causes the checkbox and the row highlight to become out of sync.

EDIT: It appears that if I set the data limit to 10 records the bug goes away and works as I intended. If it's anything higher than 10 the bug reappears.

EDIT 2: Setting the renderMode to NONE also seems to fix the bug. But, I lose performance with large data sets.

Expected behavior

I expect the checkboxes to be in sync with the row highlight. The checkbox should require one click to toggle the selected state of the row.

Possible solution

I don't have a solution.

@henrywarhurst
Copy link
Contributor

@Austint30 interestingly in your repro moving down the table and selecting every row successfully selects every second row

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants