Merge pull request #6147 from chrisjsewell/propogate_citeref_classes

propogate cite_reference node classes to pending_xref node
This commit is contained in:
Takeshi KOMIYA 2019-03-09 15:15:05 +09:00 committed by GitHub
commit 177246a49e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -221,6 +221,8 @@ class CitationReferences(SphinxTransform):
refnode.source = citation_ref.source or citation_ref.parent.source
refnode.line = citation_ref.line or citation_ref.parent.line
refnode += nodes.Text('[' + cittext + ']')
for class_name in citation_ref.attributes.get('classes', []):
refnode['classes'].append(class_name)
citation_ref.parent.replace(citation_ref, refnode)