leap-day icon indicating copy to clipboard operation
leap-day copied to clipboard

Table of Content Should Use Header "id"s If Possible

Open Zehua-Chen opened this issue 3 years ago • 1 comments

During the table of content generation, the current implementation would use the content of the header, transform it a little bit, and then use the transformed as the id of the header and the ref of the table of content entries.

For non-ASCII headers that have custom ids, this approach proves problematic, as no ID will be generated from the non-ASCII header, resulting in a broken table of content.

# 注意事项 {#notes}

To fix this, I think the ID of headers should be used if they are available, and we only fall back to header content otherwise.

Zehua-Chen avatar Jun 24 '21 02:06 Zehua-Chen

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jan 09 '22 01:01 stale[bot]