-
Notifications
You must be signed in to change notification settings - Fork 48
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
PoC sorting by binary index and municipality #632
base: staging
Are you sure you want to change the base?
PoC sorting by binary index and municipality #632
Conversation
@belanglos is attempting to deploy a commit to the Klimatbyrån Team on Vercel. A member of the Team first needs to authorize it. |
I wonder if, as an alternative to the current custom sort solution, TanStack's https://tanstack.com/table/v8/docs/guide/sorting/#multi-sorting |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Thanks for having a look @LudwikJaniuk ! For programmatically invoking the multi-sort, i.e. having the table sort by However, I've played around with multi-sort a little bit now and the interesting thing is that if I sort by |
Added another branch with user-controlled multi-sorting (shift-click): https://github.com/belanglos/klimatkollen/tree/351-multi-sorting-poc |
Shift click actually works by-default on the site as it is live: klimatkollen.se And a difference between "Upphandlingarna" and "Klimatplanerna" can be observed there too. Maybe that is the first place to start - to figure out the difference?
IMO no, because no one will guess that (and no shift on mobile). When sorting on "Ja/Nej", it makes no sense to have a "random" sort on the rest. |
I totally missed that this was the default-behaviour in Tanstack/table. Thanks for pointing that out!
I totally agree with you! |
A proof of concept for multisort if the index column contains binary data (as far as I've seen this is the case in
klimatplanerna
andupphandlingarna
).It seems to work well for
klimatplanerna
, but it does not work forupphandlingarna
and I cannot see why.