diff --git a/quartz/components/scripts/popover.inline.ts b/quartz/components/scripts/popover.inline.ts index 86cc88582..e07205bc8 100644 --- a/quartz/components/scripts/popover.inline.ts +++ b/quartz/components/scripts/popover.inline.ts @@ -91,7 +91,7 @@ async function mouseEnterHandler( normalizeRelativeURLs(html, targetUrl) // prepend all IDs inside popovers to prevent duplicates html.querySelectorAll("[id]").forEach((el) => { - const targetID = `popover-internal-${el.id}` + const targetID = `popover-${el.id}` el.id = targetID }) const elts = [...html.getElementsByClassName("popover-hint")] @@ -106,7 +106,7 @@ async function mouseEnterHandler( document.body.appendChild(popoverElement) if (hash !== "") { - const targetAnchor = `#popover-internal-${hash.slice(1)}` + const targetAnchor = `#popover-${hash.slice(1)}` const heading = popoverInner.querySelector(targetAnchor) as HTMLElement | null if (heading) { // leave ~12px of buffer when scrolling to a heading