-
Notifications
You must be signed in to change notification settings - Fork 11
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 user customization, documentation, and benchmark #37
Conversation
Thanks for your work, I am on holiday currently. I will review when I get back. |
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.
Overall, a welcomed refactor. I look forward to hearing from you about the specific points mentioned in the review. I don't claim to hold the truth here; I am open to discussion about how glossarium should evolve
Hello @slashformotion, thanks for the review! I I answered your comments above! hopefully that answered your questions. About the evolution of glossarium,
I can imagine a subsequent PR to add different styles other than the default one like glossaries and glossaries-extra to have an easy switch, see https://www.dickimaw-books.com/gallery/glossaries-styles/. |
I will fix the merge conflicts and merge locally if you don't want to rebase. |
I'll take a look tomorrow and rebase, thanks! |
@quachpas if you are interested in glossarium development, please join this discord server https://discord.gg/K3sdEGZd . |
I personally dislike using Discord for software dev ... I'd rather not join. Is there no plan to just use GitHub? or a dev mailing list? |
I don't have a strong opinion on where the discussions around software dev should happen. We could use the discussion feature on github. I have never used mailing lists so there's that |
Maybe we can open a pinned issue "Roadmap 0.5.0" where people can discuss? |
Should be good to go @slashformotion |
Hello there!
I've been sitting on my fork of glossarium and decided to finally do something :). Thanks for all the amazing work you've done.
I realize I've written quite a bit, but I'll summarise below and I am obviously open to feedback!
Summary
print-glossary
function into multiple parts in order to expose a user customization interface. See documentation below for details (or the code).just benchmark
using https://github.com/sharkdp/hyperfineDetails
Details
user-
(I haven't found anything better yet). If someone has a better idea, please share!default-
desc
todescription
: I feel like the more attributes we add, the less clear it will be for the user which shorthand is supposed to be which ... IMO we should strive to write complete names, although that's up to debate.enable-group-pagebreak
by user customizationuser-group-break
. The default behaviour is() => []
(nothing). Users can specify which break they want in this wayprint-glossary(..., user-group-break: pagebreak)
orcolbreak
or any() => content
default-print-reference
andmake-glossary
) of the formkey:pl
to reference plural forms directly.gls-key
,gls-short
, etc.glossarium_version
to expose the package version to the user and in error messages. Added to tbump.__error_message(msg, kind)
withkind
specific error types to dispatch error messages__get_entry_with_key
with try/panic loop__is_first_or_long
,__has_attribute
,has-long
,has-longplural
, etc.__link_and_label
default-print-glossary
andcount-refs
)level: n+1
instead oflevel: 2
just build-examples
, thenfind
fails as it does not find files to delete. Fixed by removing thefind -delete
.tests/debug.typ
to help in debugging during development.benchmark
This PR reduces performance. I am not sure how it scales with large glossaries. I don't think it's a huge issue as of now, as typst is just ... blazing fast.
Details
This branch
typst compile --root . examples/full-example/main.typ
typst compile --root . examples/groups/groups.typ
typst compile --root . examples/import-terms-from-yaml-file/main.typ
typst compile --root . examples/plural-example/main.typ
v0.4.0
typst compile --root . examples/full-example/main.typ
typst compile --root . examples/groups/groups.typ
typst compile --root . examples/import-terms-from-yaml-file/main.typ
typst compile --root . examples/plural-example/main.typ