sphinx-contrib / confluencebuilder

Confluence Markup Builder Plugin for Sphinx
BSD 2-Clause "Simplified" License
315 stars 99 forks source link

translator: avoid creating duplicate anchors #990

Closed jdknight closed 3 months ago

jdknight commented 3 months ago

When building title anchors, the title node will look at assigned name references to build anchors. Before building an anchor, the target will be resolved for the case of special targets (e.g. references to headers which use a Confluence-generated anchor target). In some scenarios, a resolved reference may repeat the same target anchor to create. This commit tweaks the process to avoid creating additional anchors of the same name, if an anchor was already created for the title node.