Commit graph

16 commits

Author SHA1 Message Date
Dan Stillman
e679473db1 Remove citeproc-rs
citeproc-rs is no longer maintained, and people who had enabled the
hidden pref were hitting errors.

This also drops the free() call on CSL engines, which only existed to
free the citeproc-rs wasm driver.

https://forums.zotero.org/discussion/133515/
2026-08-31 12:38:05 -04:00
Dan Stillman
dac1ad489f Update utilities submodule
Some checks are pending
CI / Detect changes (push) Waiting to run
CI / Test () (push) Blocked by required conditions
CI / Test (macOS NFS) (push) Blocked by required conditions
CI / Utilities Tests (push) Waiting to run
CI / Build, Upload (push) Waiting to run
And add test for citing date strings wrapped in double quotes

https://forums.zotero.org/discussion/133277/
2026-08-19 15:28:34 -04:00
Dan Stillman
472a0bf856 Update utilities submodule
And add a test for citing a spelled-out BCE date, which citeproc-js
rendered as AD.
2026-08-13 10:01:09 -04:00
Dan Stillman
8ac1273acb Support citing EDTF dates in the Date field and Extra
EDTF dates -- ranges ("2021/2026"), uncertain/approximate dates
("2004-06~"), and BCE dates ("-0429") -- and common equivalent notations
("1995-1996", "2021-22", "~1995", "ca. 1995", "429 BCE") are now passed
to citeproc-js as CSL date ranges, circa flags, and negative years.
Previously, such dates were mangled or dropped entirely unless entered as
CSL variables in Extra.

CSL date variables in Extra get the same parsing.

Other date handling in the client doesn't understand EDTF yet: the y/m/d
indicator in the date field doesn't reflect EDTF parsing, date searches
only match a range by its start date, and BCE dates still can't be
sorted.

Addresses #637
2026-08-12 14:11:26 -04:00
Dan Stillman
5877952954 Add accented stop-words to abbreviations word list
Accented stop-words weren't matched by the existing unaccented
entries (e.g., "fur"), so automatic journal abbreviation kept and
capitalized them: "Jahrbuch für Heimatkunde" became "Jahrb. Für
Heimatkunde" instead of "Jahrb. Heimatkunde".

https://groups.google.com/g/zotero-dev/c/uP18QEKe2JU/m/AsoGWxd9AwAJ
2026-07-20 22:52:51 -04:00
Dan Stillman
6c5d160895 Fix citing and locale selection for locales without a CSL locale
The CSL locales repository replaced locales-sr-RS.xml with script
variants, so citing with a stored or default 'sr-RS' locale loaded no
terms and failed with an et-al error. Resolve unavailable locales to
the closest available CSL locale (sr-Cyrl-RS for sr-RS) when rendering
and in locale selectors.

https://forums.zotero.org/discussion/comment/515598/#Comment_515598
2026-07-16 11:28:21 -04:00
Dan Stillman
cddf0ea237 Update citeproc.js to include Juris-M/citeproc-js#281
Fixes HTML appearing in citations after an error during citation preview

https://forums.zotero.org/discussion/132539/
2026-07-03 15:53:12 -04:00
Dan Stillman
c42f3b8174 Fix citing in Serbian locale
Fixes #5741
2026-01-26 15:14:19 -05:00
Dan Stillman
ebacb83563 Reset Zotero.locale to 'en-US' after cite test 2022-08-11 03:57:20 -04:00
Dan Stillman
2c11aadc57 Add localized string for timestamp CSL locator
Not included in the CSL locales:

https://forums.zotero.org/discussion/comment/412060/#Comment_412060
2022-08-11 02:47:46 -04:00
Dan Stillman
387e4dd958 Add CSL 1.0.2 locators and switch to CSL locales for localization
And move Page to middle of list, while still selecting by default

https://forums.zotero.org/discussion/comment/396602/#Comment_396602
2022-08-11 02:47:15 -04:00
Dan Stillman
31d095fb42 Add test for citeproc-js disambiguation hang
https://github.com/Juris-M/citeproc-js/issues/179
2021-03-29 01:41:37 -04:00
Dan Stillman
91ca6d2ba6 extraToCSL(): Fix "zoteroField[1] is undefined" on single-character field
E.g., "a:" on a line

https://forums.zotero.org/discussion/82286/new-line-in-extra-field-induces-error-during-bibliography-generation
2020-04-03 18:13:10 -04:00
Dan Stillman
da5e8c549e Convert Zotero fields in Extra to CSL fields for citeproc-js 2020-03-02 01:38:10 -05:00
Dan Stillman
cbfa4be437 Add 'Type:' to extraToCSL() test
Follow-up to #1744
2019-10-26 17:05:45 -04:00
Dan Stillman
1f320e1f5d Be more lenient about Extra field values than citeproc-js
Allow fields like "Original Date: 2018" and convert them to
"original-date: 2018" when sending to citeproc-js.

For reference:

http://citeproc-js.readthedocs.io/en/latest/csl-json/markup.html#cheater-syntax-for-odd-fields
2018-03-01 17:05:24 -05:00