Closed haxtibal closed 2 months ago
I'm not yet sure if it's correct to set the replaced value not only to id
, but also to data-uid
and data-anchor
. Will have to check how these data attributes are used.
It should be a safe step forward. Using the opportunity, I added a small e2e test to exercise this behavior. Thanks for contributing!
Whitespaces are valid in StrictDoc UIDs, but are not valid in HTML element ids. Therefore we have to sanitize them during HTML export. This was already done in most places, but not for anchor IDs in rst fragments. In consequence referencing links couldn't find their target.
This adds whitespace to dash replacement for rst-for-html anchors. It reuses LinkRenderer for consistent results.
Fixes #1916.