-
Notifications
You must be signed in to change notification settings - Fork 1
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
feat: render question tags (results, q/db-preview) #110
Conversation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, I like the way it looks!
Just a couple of notes in the review comments ;)
Here is what I would do to add the tags to our database. You can add the TheTOLProject/scripts/database.ts Lines 104 to 114 in a236da3
Then you can updated the way the entries are created: TheTOLProject/scripts/database.ts Lines 125 to 141 in a236da3
Please keep in mind that the tag cells will contain a semicolon-separated list of tags: make sure to parse them correctly and store them as an array, so that we can do some grouping in the future ;) |
@EndBug I implemented the new column in our script. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, awesome!
I just pushed a quick fix because I noticed that the tags weren't trimmed when building the db ;)
TheTOLProject/scripts/database.ts
Lines 141 to 143 in fd8666f
tags: r.tag | |
? (r.tag as string).split(';').map((s) => s.trim()) | |
: undefined |
I think I'll just merge this to main, so that we can build the dev db from there
If there are some extra fixes needed, we can open a new PR
Thanks for the great work 🔥
Implement question tags rendering in results pdf, qpreview and dbpreview pages.
At the moment, the same tags are shown for every question in every section - database/data structure changes needed to conditionally show tags.This PR is used to achieve the intended rendering style.Closes #62