Abbreviation issues with diacritics
Hi,
I'm using the Word plugin with MEDLINE abbreviations. However, I noticed that the journal "Archiv für mikroskopische Anatomie" has been abbreviated to "Arch. Für Mikrosk. Anat." (note the surplus "Für").
This led me to a journey through the source code and I found this function:
https://github.com/zotero/zotero/blob/master/chrome/content/zotero/xpcom/cite.js#L482-L487
Unfortunately, that function doesn't properly normalize "für" to "fur". I tested this by adding a custom abbreviations.json to my zotero data folder and it only abbreviated the journal name properly when the key had "für".
Of course, having a custom abbreviations.json works for now. But is this the intended behavior or should the normalizeKey function also handle diacritics?
I found this post which may be helpful for normalizing keys: https://stackoverflow.com/questions/990904/remove-accents-diacritics-in-a-string-in-javascript/37511463
Thanks!
I'm using the Word plugin with MEDLINE abbreviations. However, I noticed that the journal "Archiv für mikroskopische Anatomie" has been abbreviated to "Arch. Für Mikrosk. Anat." (note the surplus "Für").
This led me to a journey through the source code and I found this function:
https://github.com/zotero/zotero/blob/master/chrome/content/zotero/xpcom/cite.js#L482-L487
Unfortunately, that function doesn't properly normalize "für" to "fur". I tested this by adding a custom abbreviations.json to my zotero data folder and it only abbreviated the journal name properly when the key had "für".
Of course, having a custom abbreviations.json works for now. But is this the intended behavior or should the normalizeKey function also handle diacritics?
I found this post which may be helpful for normalizing keys: https://stackoverflow.com/questions/990904/remove-accents-diacritics-in-a-string-in-javascript/37511463
Thanks!
So the question is perhaps better phrased as: should normalizeKey remove diacritics, or should there also be an entry to remove "für" in abbreviations.json?
German conjunctions: https://wortwuchs.net/grammatik/konjunktion/liste/
I could put those together if it helps. Does it make sense to add all?