chore(glossy): release version 0.4.0
## New features:
**Articles with `a`/`an` modifier**
Now you can include articles using this new modifier. The articles may
be defined in your dictionary entry (fields `artcile`, and
`longarticle`). But, if you don't define them, Glossy will do a
reasonably good job at guessing them.
This modifier is also allowed before the term. For example, you might
have this term:
```yaml
www: Worldwide Web
```
And you could display it with an article by any of these:
```typst
@a:www
@an:www
@www:a
@www:an
```
These, `a` and `an` are exactly equivalent. They're just provided for
your convenience. Use either or both.
The `a`/`an` modifier works with all modifiers except `pl` and
`def`/`desc`.
If you want to define custom articles for your terms, do so like this:
```typst
#let glossary = (
rf: (
short: "RF",
article: "an",
long: "radio frequency",
longarticle: "a",
)
uts: (
short: "UTS",
article: "a",
long: "untranslatable string",
longarticle: "an",
)
)
```
But again, in most cases (for English) you shouldn't need to because
Glossy should usually get it right.
Fixes [#12](https://github.com/swaits/typst-collection/issues/12).
## Other changes:
- added test which exhausts all reference options
- added panic if 'def'/'desc' used when no `description` field exists
- significantly improved the (English) pluralizer function
- `__gls()` function refactored, cleaned up
- removed a rogue PDF
## Contributors:
- [@eltos](https://github.com/eltos)
- [@theRealProHacker](https://github.com/theRealProHacker)
This commit is contained in:
3 files changed
+3
-3
No files matched your search
+1
-1
@@ -41,7 +41,7 @@ different goals:
|
||||
### Import the package
|
||||
|
||||
```typst
|
||||
#import "@preview/glossy:0.3.0": *
|
||||
#import "@preview/glossy:0.4.0": *
|
||||
```
|
||||
|
||||
### Defining Glossary Terms
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
short: "TPS",
|
||||
long: "test procedure specification",
|
||||
description: "A document on how to run all the test procedures"),
|
||||
unused: "Unused term, which shouldn't print in the glossary."
|
||||
unused: "Unused term, which shouldn't print in the glossary."
|
||||
)
|
||||
|
||||
#show: init-glossary.with(myGlossary, show-term: (body) => [#emph(body)])
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "glossy"
|
||||
version = "0.3.0"
|
||||
version = "0.4.0"
|
||||
entrypoint = "lib.typ"
|
||||
authors = ["Stephen Waits <steve@waits.net>"]
|
||||
license = "MIT"
|
||||
|
||||
Reference in new issue
Block a user