Skip to content
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

Add support for semantic markup in bibliographies #132

Open
frederik-elwert opened this issue Mar 30, 2023 · 3 comments
Open

Add support for semantic markup in bibliographies #132

frederik-elwert opened this issue Mar 30, 2023 · 3 comments

Comments

@frederik-elwert
Copy link

For some output formats, it is desirable to not only have a formatted bibliography, but to use semantic markup to identify parts of the bibliography (e.g., title, author, publisher, …). While pandoc supports this for JATS, it is lacking for other output formats like TEI (https://www.tei-c.org/release/doc/tei-p5-doc/en/html/ref-bibl.html) or HTML (https://schema.org/CreativeWork).

The old pandoc-citeproc processor supported this via raw content elements as an extension to CSL, which allowed citation styles to specify bits of semantic markup to be added to the output. An example for TEI using the old processor can be found here: https://github.com/frederik-elwert/teicite.

It would be desirable if either citeproc re-implements the CSL extension, or if it (or pandoc) provides an alternative solution for adding semantic markup to bibliographies.

@tarleb
Copy link
Contributor

tarleb commented Mar 30, 2023

Could it make sense to somehow preserve the names of macros by wrapping the contents in a span with the macro's name? That would make it easy to post-process the output with a filter.

@jgm
Copy link
Owner

jgm commented Mar 30, 2023

Can't do this with the current API. At the least, we'd need new methods for CiteprocOutput class, which would create a labeled Span in pandoc output.

@frederik-elwert
Copy link
Author

I’m not sure preserving the macro names would be the best thing to do, as the macro names are basically up to the style authors? I guess ideally the variable names themselves would be preserved for the different output elements like names, text etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants