Small refactor of content and using Dutch section IDs.
This commit is contained in:
parent
bdda58834c
commit
bf4d2036db
4 changed files with 28 additions and 38 deletions
|
|
@ -2,7 +2,7 @@ const highlightSectionFromHash = () =>
|
|||
{
|
||||
const { hash } = window.location;
|
||||
|
||||
if (hash === '#section-contact')
|
||||
if (hash === '#contact')
|
||||
{
|
||||
const section = document.getElementById(hash.substring(1))?.parentElement;// .closest('section');
|
||||
|
||||
|
|
@ -58,7 +58,7 @@ document.addEventListener('DOMContentLoaded', () =>
|
|||
|
||||
sections.forEach(section =>
|
||||
{
|
||||
const anchorTarget = section.querySelector('[id^="section-"]');
|
||||
const anchorTarget = section.querySelector('[id]');
|
||||
const anchorHeader = section.querySelector('h1,h2');
|
||||
|
||||
if (anchorTarget && anchorHeader)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue