asciidoctor / docbookrx

(An early version of) a DocBook to AsciiDoc converter written in Ruby.
MIT License
22 stars 49 forks source link

Convert figure element's xml:id attribute into ID anchor to enable linking to figures #59

Closed fbolton closed 11 months ago

fbolton commented 7 years ago

Previously, links to figures were broken, because no ID anchor was being generated for figures. This fix extracts the value of the xml:id attribute from the figure element and uses it to generate an anchor, [[XmlId]].

mojavelinux commented 6 years ago

This looks good. I have one request, though. Could you write the anchor as follows?

[#_sample_figure]

When there is no reftext, we want to encourage the use of the modern, shorthand syntax.

I'll also need you to rebase, if possible, since other merges introduced a conflict. Thanks!

fbolton commented 6 years ago

@mojavelinux I'll update the syntax and rebase the PR this evening. Should be ready for merging by tomorrow. Thanks for reviewing the PR!

mojavelinux commented 6 years ago

Thanks @fbolton!

After that, I'll follow up on your other PRs as well. Thank you for your contributions to improve this converter!

mojavelinux commented 6 years ago

Ping me in a comment when it's ready.