Random thought on followup …
Frank Bennett <@Frank_Bennett> writes:
As some of know, in my own python implementation I’ve been using an internal
model that is essentially an HTML subset + RDFa. The idea is to dump this as
is to get round-trippable output.
But this isn’t going to be for everyone. Still, it would help make output
smarter if at least processors output links where appropriate.
To be a little more specific, in order of importance:
- if there’s an HTTP URL in the output, wrap it in an a element
- if there’s a DOI in the output, wrap it in an a element, but use a
link value with a base of ‘http://dx.doi.org/’ so it resolves
- on in-text citations, link to the respective anchor in the
contents on hover?)
I agree that processors should be able to output active links and
internal links in HTML output. As you say, it should probably be
optional to include the links, in case an application or user wants
the output unadorned, but it’s definitely a good idea, and I’d be in
favor of including it as a recommendation in the spec.
I do not have any strong opinion on the subject. I happen to prefer
unadorned output, but implementing what Bruce is suggesting would be
easy in citeproc-hs. I too would prefer to make it an option, but that
is not trivial for the pandoc side, and so I need to see what the pandoc
users think about it. Maybe it could be the pandoc default behavior (it
would be trivial to write a script which post-process the pandoc output
to remove the links).
In many ways, citations work like footnotes. So just as pandoc
produces id anchors and bi-directional links for footnotes, it could
do the same for citations. So lightweight, something like:
[the bib reference]
You then also have enough structure for additional styling, or
With RDFa, you can also think about:
… where the citations becomes nodes in a graph.