Select all (rows) checkbox in table resets sorting
See original GitHub issue- I have searched the issues of this repository and believe that this is not a duplicate.
Version
3.10.0
Environment
MacOS 10.13.6, Chrome 69.0.3497.100 (64-bit)
Reproduction link
https://codepen.io/hon2a/pen/NOpQwx?&editors=001
Steps to reproduce
- Create a
Tablewith both column sorting and row selection. - Sort the table by some sortable column.
- Click on the “Select all” checkbox in the top left corner of the table to select all rows at once.
What is expected?
All rows are selected and the current sorting is retained.
What is actually happening?
Rows are selected, but the sorting is lost (reset). Additionally, when the “Select all” checkbox is hovered over, a “Sort” tooltip is shown, which shouldn’t be there.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:7 (2 by maintainers)
Top Results From Across the Web
TH element with (Select All) Checkbox and TableSorter
The issue is that since I have the tablesorter js on the table it will select or deselect all of the rows but...
Read more >Best practice for sorting and being able to "check all" in a table ...
You can use the Check All / Select All button just above or below the table which will enable the user to select...
Read more >Sorting by selected rows when using checkboxes for selection ...
Hi all, I have a table where the user can select rows with a checkbox column. Then, I also want to be able...
Read more >Table - Ant Design
Rows can be selectable by making first column as a selectable column. You can use rowSelection.type to set selection type. Default is checkbox...
Read more >Add a Total row to a table - Microsoft Support
Training: In Microsoft Excel, select the Design tab and then select the Total Row checkbox to add a Total Row. You can also...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Hi @hon2a , The root cause of this issue is that code not check column is sortable when click the header. So I ref it to the commit.
Tooltip update is here: https://github.com/ant-design/ant-design/commit/f1d1d87de08eadaa00f3d4c3c302f16e77ea8020
checking if columnKey isn’t a
selection-columnbefore changing state might be a temporary fix