retype
retype copied to clipboard
Unexpected ToC navigation when using header anchor and panel title
I noticed earlier while putting together a page (which no longer exists) that selecting an anchor on the right where one of my header titles existed brought me to a panel instead. I thought this was super odd but didn't dive too much into troubleshooting. I just spun up a new page here: https://retypetest.pages.dev/concepts/testpage which I intend on leaving up for a couple days to continue testing. Basically, you'll see that if you select the anchor on the right for "I like bananas" it will actually bring you to the panel also aptly named "I like bananas" instead of the actual header title as one might expect.
I do think panels should be configurable as headers somehow so they can also appear in the ToC (depending on whether the user wants to use them as headers or not) but if this is not specified, I wouldn't expect them to conflict with actual headers. On the flip side, when the header title was at the top of the page (above the panel), this behavior did not exist. That is, the ToC brought me to the header title, not the panel.
I am using Windows 11 and I have only tested this in Chromium-based Edge.
Adding source file here for reference so I can remove from my project.
# Testpage
## A title page
=== My very special panel
I love this panel because it's beautiful
=== It is the best panel
It is my panel, so it is the best panel.
=== I like bananas
Mostly because they have a lot of potassium, but they also look cool. Like yellow eggplants but smaller and not as thick.
===
### A subtitle page
| A column | Another column that's a little bigger |
| - | - |
| Stuff | Even more stuff |
I
Like
Big
Butts
And
I
Cannot
Lie.
### Another subtitle page
## I like bananas
Sir Mix-A-Lot. 🕺
Good catch. It's strange that we did not find this defect earlier.
We will try and fix right away and include in the next release. I will keep this thread updated with our progress.