grip icon indicating copy to clipboard operation
grip copied to clipboard

Bugfix: Titles with accents (example: Spanish) was not working

Open skrosoft opened this issue 5 months ago • 0 comments

Markdown titles that contains accents (example: in Spanish) has an encoded location.hash.

To make the scrollDown working in that cases, you need to use decodeURIComponent, in the other case the element will not be found and scrollDown will not occur.

An example with the title "Configuración" ("Configuration" in Spanish)

Configuración

location.hash:
"#2-configuraci%C3%B3n"
# the letter "ó" is encoded

But the element ID has the accent without the encoding:

Captura de pantalla 2024-09-12 a la(s) 10 12 03

skrosoft avatar Sep 12 '24 13:09 skrosoft