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

possible to specify an element trigger sorting other than default TH? #208

Open
capturedghosts opened this issue Sep 8, 2020 · 0 comments

Comments

@capturedghosts
Copy link

capturedghosts commented Sep 8, 2020

This is probably something exceedingly simple, but I'd like to trigger sorting on click of the title of the <th> only (maybe wrapped in a span?), as I have a second, more granular filtering mechanism in each <th> as well, and I don't want to sort when a user clicks on the icon that triggers my second filtering popup.

As written, the script sorts on-click anywhere within the <th>, and I'd like to prevent that from happening when clicking on the blue icon within the <th> below:

Untitled

And because the icon and dropdown are children of the <th>, clicking on anything inside the dropdown also sorts the table. I've tried using .not() with no success.

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

1 participant