solid-router
solid-router copied to clipboard
HTML anchors with unicode id hash could not trigger page jump
Describe the bug
When using Unicode characters such as Chinese or Japanese as the id of the title, the anchor tag cannot trigger a page jump, ascii characters work well.
Your Example Website or App
https://stackblitz.com/edit/solidjs-templates-exqpxd?file=src%2FApp.tsx
Steps to Reproduce the Bug or Issue
- Click the
你好世界
heading anchor in the page; - the page does not have any actions;
- Click the
Hello World
heading anchor in the page; - the page automatically scrolling to the heading position;
- Click the
僕はダメなんだ
heading anchor in the page; - page returns to the top unexpectedly.
Expected behavior
All the anchors should make the page scrolling to the corresponding heading.
Screenshots or Videos
No response
Platform
- OS: Linux
- Browser: Microsoft Edge
- Version: 124.0.2478.109
Additional context
there are two event listeners on the anchor tag, delete them could makes the functionality works as expected.