-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Citations are being ignored if they are in sidebar, quotes #17
Comments
The new AST based processor does not yet handle sidebar or quotes. I will add them and make a new release. Thanks for reporting. |
It seems From implementation point of view, I can substitute the citation with proper texts (but without hyperlinks). But I personally does not agree with the usage. If citations in quotes is really necessary, I would suggest put citations in the block title, instead of block attributes. For example: .A Space Odyssey cite:[Clarke_2001_1968]
[quote.epigraph, 'Arthur C. Clarke', 2001: A Space Odyssey]
This is the quote content. If citations in block titles are wanted, I can implement them. |
Actually, If we consider popular style guides they usually put quote citations at the bottom, for example MLA suggestions here https://owl.english.purdue.edu/owl/resource/747/03/ or Chicago style here http://www.lmu.edu/Assets/Academic+Affairs+Division/Academic+Resource+Center/Chicago+Style+Quoting+and+Paraphrasing+Spring+2011.pdf Also block attributes has the feature of being more than plain text. For example I use Here I mention Dan Allen @mojavelinux if he can give comment on Asciidoc style for quotes and attributes. |
While this certainly works, it's definitely far outside the spirit of AsciiDoc. AsciiDoc should declare the semantic information and an extension should sort how how to display, format and style it. |
@mojavelinux , Thanks for the comment, just any other comment on the placement of citations in quotations? |
I think we should follow the style guides as much as possible. |
Technologically, one can write things like @shahryareiv, from the provided style guides, I would propose something like the following for quoting: This is the famous quotes by Arthur C. Clarke (cite:[Clarke_2001_1968]):
[quote]
____
The content of the quote
____ The idea is to leave the quote body clean and add bibtex citations into the surrounding contexts, so readers can focus on the quote content first and refer to the source only if necessary. |
I am still considering whether to support citations in block titles/captions and section titles. The latter is considered a bad practice in the latex community. But it might be useful if one want to explain in more detail the contents of the block (such as figures, tables, etc.). Any comments? @mojavelinux @shahryareiv |
The example you mentioned above from the Asciidoctor manual, also populates attribute block:
I agree with you that leaving
About the Latex, I guess there is a problem with "moving arguments" and they need to do One more thing, is that we should find a way to defer these types of considerations to a center, i.e. asciidoctor core development. There might be other similar conversations in other extension development groups and we cannot unify them together. So extension development should be freed by converting anything/anywhere while asciidoctor prohibits the wrong practices in the first step. |
Now I understand the use case. Although one can write the citation texts directly in the attributes like above, one may want it produced automatically, and may need it linked with the bibliography further. I experimented hyperlinks in quote attributes and asciidoctor converts them into markups before calling my extension. This means hyperlinks are eventually supported in quote attributes by asciidoctor. So it is possible for asciidoctor-bibtex to support hyperlinking citations in attributes to its bibliography item. The implementation is not staightforward, but I will add them anyway. |
Note that the core idea of asciidoctor-bibtex is bring bibtex to asciidoctor while adhering to asciidoctor's sematics. So citations in block attributes are only considered if asciidoctor supports inline macros in block attributes. So are there any rules for inline macros in block attributes? Does it support inline macros? Or in a restricted way? If so, what macros are allowed? @mojavelinux |
I tried to implement the feature and it turned out that I have to do it specially for quote block and convert the link to html in my extension. Even after all these tricks, the hyperlink still does not work in asciidoctor-pdf (however, it works correctly in the html backend). The code now lives in the cite-in-prose branch. It works only for citetitle in prose blocks. For example: [quote, 'Arthur C. Clarke', A Space Odyssey (cite:[guo2009])]
____
This is a quote.
____
== Bibliography
bibliography::[] |
This feature request does not follow the sematics of quote blocks, so I am still considering whether to merge it into master and make a new release. Please use the code in |
Thank! I just wonder if this limitation (citations in block quotes and also side-notes) also applies to "asciidoc -> asciidoc" transfer mode? I have used asciidoc-bib in "asciidoc -> asciidoc" mode before and it does not care about the placement of citations. Does asciidoctor-bib shares that piece or it has its own implementation? |
No. The asciidoc to asciidoc mode uses text substitution instead of AST However, since the spirit of asciidoctor-bibtex is to respect the semantics 2016年10月31日星期一,Shahryar notifications@github.com 写道:
Zhang YANG (杨章) Associate Professor, Ph.D. |
Citation are being ignored if they reside in a sidebar or quote. For the quote, this:
[quote.epigraph, 'Arthur C. Clarke cite:[Clarke_2001_1968]', 2001: A Space Odyssey]
does not get translated, so a quotation cannot get its source identified.
The text was updated successfully, but these errors were encountered: