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

Add sortable tables #639

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open

Add sortable tables #639

wants to merge 8 commits into from

Conversation

azdanov
Copy link
Contributor

@azdanov azdanov commented Dec 22, 2024

Another attempt at sortable table, this time I've used https://tanstack.com/table/latest

I've updated only 1 table as an example to show how it can be used in the markdown document.
I also didn't verify if LLM properly converted Markdown table into JSON 🙈

@thibaultmol
Copy link
Contributor

lgtm!

@azdanov
Copy link
Contributor Author

azdanov commented Dec 24, 2024

I've added some more changes. Like custom formatting for numbers, so 1M and 128K can be properly sorted and displayed in human readable form. Also, added custom formatting for any specified token words, like "Mistral", "Meta", etc.

@azdanov
Copy link
Contributor Author

azdanov commented Dec 24, 2024

I didn't highlight anything in the last table, the llm cost, since I didn't understand the logic behind it.

@z64
Copy link
Member

z64 commented Dec 25, 2024

What was the issue with #634 ?

@azdanov
Copy link
Contributor Author

azdanov commented Dec 25, 2024

It wasn't working correctly. On page switch all the event listeners were reset so sorting stopped working.

Also, I think tanstack is production tested and more suitable than my custom implementation.

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

Successfully merging this pull request may close these issues.

3 participants