typst / hayagriva

Rusty bibliography management.
Apache License 2.0
289 stars 44 forks source link

Incorrect Finnish bibliography string for multiple pages in a reference #161

Open SeSodesa opened 1 month ago

SeSodesa commented 1 month ago

Description

According to the Finnish Center for Domestic Languages (Kotimaisten kielten keskus), when a bibliography item contains information on a page range, the page number prefix should be s. instead of ss., regardless of whether the reference contains multiple pages or not (source). This is in contrast to the English page range field, where the page range field prefix of a bibliography entry is p., when the reference refers to a single page, and pp. if there are multiple pages:

Lähdeluetteloon merkitään yleensä artikkelien sivunumerot. Merkinnässä voi käyttää tai olla käyttämättä lyhennettä s.:

When text language is Finnish, the page range field of bibliography entries should conform to the above guideline, which is currently not the case, as can be seen in the below image:

Screenshot from 2024-05-12 09-50-48

Use Case

The output of Finnish bibliographies would conform to the official Finnish guidelines.

SeSodesa commented 1 month ago

I might fix this myself, but I cannot seem to find where bibliography entry fields are localized.

SeSodesa commented 1 month ago

A temporary solution might be to provide a CSL localisation for the language as seen here: https://docs.citationstyles.org/en/stable/specification.html?highlight=pages#locale-files-structure. But is it enough to give something like this via the bibliography style argument without defining all strings, and let typst fill in the missing strings from the defaults?

SeSodesa commented 1 month ago

Maybe it would make most sense to change the default Finnish localisation in the CSL repository, of the compact binary localisation files in this repository are generated from those? I am specifically referring to these lines in the locales-fi-FI.xml file on the CSL repo: https://github.com/citation-style-language/locales/blob/e631a52dcea396be20d031b6456e91dba7772224/locales-fi-FI.xml#L421-L424.