Annotated numbered bibliography
I'm trying to create a style which adds annotations to a numbered referencing style.
Specifically, I want to Zotero to print the Extra field where this is populated when using a numbered style such as the Nature.
I've tried to follow the guidance here: https://www.zotero.org/support/dev/citation_styles/style_editing_step-by-step and searching the forum I know that the specific code that I need to insert into edited version of the Nature style is:
Playing around in the style editor I can coerce Zotero to print the contents of Extra at the end of the relevant bibliography item. For example:
1. Cadet, J. L., Bisagno, V. & Milroy, C. M. Neuropathology of substance use disorders. Acta Neuropathologica 127, 91–107 (2014) ★★★.
Where ★★★ is what is inside of Extra. To achieve that I placed the instruction to print the contents of Extra just before the last
How can I get Zotero to place the contents of Extra (the starts) in a new line, the way it does for APA and Chicago annotated bibliography styles? I assume I'm missing something obvious but can't figure out what I need to edit.
Specifically, I want to Zotero to print the Extra field where this is populated when using a numbered style such as the Nature.
I've tried to follow the guidance here: https://www.zotero.org/support/dev/citation_styles/style_editing_step-by-step and searching the forum I know that the specific code that I need to insert into edited version of the Nature style is:
<text variable="note" display="block"/>
Playing around in the style editor I can coerce Zotero to print the contents of Extra at the end of the relevant bibliography item. For example:
1. Cadet, J. L., Bisagno, V. & Milroy, C. M. Neuropathology of substance use disorders. Acta Neuropathologica 127, 91–107 (2014) ★★★.
Where ★★★ is what is inside of Extra. To achieve that I placed the instruction to print the contents of Extra just before the last
</group>
tag.How can I get Zotero to place the contents of Extra (the starts) in a new line, the way it does for APA and Chicago annotated bibliography styles? I assume I'm missing something obvious but can't figure out what I need to edit.
There is a few examples here: https://docs.citationstyles.org/en/stable/specification.html#display
Usually you not only set the block on that one group/variable, but also need to set another display setting on the rest of the output.
@damnation thanks for the link. I'm struggling to understand what I am missing in my
<bibliography>
code for it to be throwing a validation error. Any thoughts? Am I way off base with how I'm approaching this? Biblio code in full below:<bibliography et-al-min="6" et-al-use-first="1" second-field-align="flush" entry-spacing="0" line-spacing="2">
<layout suffix=".">
<text variable="citation-number" suffix="."/>
<group delimiter=" ">
<text macro="author" suffix="."/>
<text macro="title" suffix="."/>
<choose>
<if type="chapter paper-conference" match="any">
<text term="in"/>
</if>
</choose>
<text macro="container-title"/>
<text macro="editor"/>
<text macro="volume"/>
<text variable="page"/>
<text macro="issuance"/>
<text macro="access"/>
</group>
</layout>
<group>
<text variable="note" display="indent"/>
</group>
</bibliography>
Moved it above layout but am now back to the contents of Extra printed in line as opposed to a new line :/
<bibliography et-al-min="6" et-al-use-first="1" second-field-align="flush" entry-spacing="0" line-spacing="2">
<layout suffix=".">
<text variable="citation-number" suffix="."/>
<group delimiter=" ">
<text macro="author" suffix="."/>
<text macro="title" suffix="."/>
<choose>
<if type="chapter paper-conference" match="any">
<text term="in"/>
</if>
</choose>
<text macro="container-title"/>
<text macro="editor"/>
<text macro="volume"/>
<text variable="page"/>
<text macro="issuance"/>
<text macro="access"/>
</group>
<text variable="note" display="indent"/>
</layout>
</bibliography>
Try something like this:
<bibliography et-al-min="6" et-al-use-first="1" entry-spacing="0" line-spacing="2">
<layout suffix=".">
<text variable="citation-number" suffix="." display="left-margin"/>
<group delimiter=" " display="block">
<text macro="author" suffix="."/>
<text macro="title" suffix="."/>
<choose>
<if type="chapter paper-conference" match="any">
<text term="in"/>
</if>
</choose>
<text macro="container-title"/>
<text macro="editor"/>
<text macro="volume"/>
<text variable="page"/>
<text macro="issuance"/>
<text macro="access"/>
</group>
<text variable="note"/>
<group/>
</layout>
</bibliography>
When I format a few random citations into a bibliography in Word the result is getting close to what I want to achieve. The contents of Extra is inserted after a soft line break, but is then followed by another soft line break and a period.
Am I right in thinking that this is caused by
<layout suffix=".">
wanting to place a period at what should be the end of the bibliographic entry, which is now confused by the annotation being thrown in?Any easy way to get this period back to where it rightfully belongs (which in this style is after "access")?
This also leaves me with a new problem of having lost
second-field-align="flush"
, so the numbering and indentation of the items is not as it should be.As a note, I had to add display="block" to display the annotating info with a line break, otherwise it was displayed in line:
<text variable="note" display="block"/>
.You can remove the period from layout and add it to the first group, that'll put it after the access macro.