tablesort icon indicating copy to clipboard operation
tablesort copied to clipboard

data-sort-order attr no longer supported

Open chinanderm opened this issue 7 years ago • 4 comments

At some point since commit 036e2f9 back on December 10, 2015, the support for data-sort-order on a

to override the global sort order config option has been removed. Is there a new way to do this?

Downloading the source as of commit 036e2f9 allows <th data-sort-order="asc">...</th>, for example, to a click on that header to override a global option sort order of "descending".

Can this please be restored?

chinanderm avatar Feb 13 '18 21:02 chinanderm

Any update on that?

FlashJunior avatar Dec 26 '18 08:12 FlashJunior

Gentle bump

colinodell avatar Mar 08 '20 14:03 colinodell

just bumped into this as well. Made a tiny pull request #184

zevero avatar Mar 09 '20 23:03 zevero

From the sources, it seems that this attribute has been superseded by aria-sort="[ascending|descending]". But due to a bug at initialization, this attribute is reversed... So if you want to have a column sorted in the descending order by default, for the time being you must do: <th data-sort-default aria-sort="ascending">.

arkanovicz avatar Jan 20 '24 09:01 arkanovicz