From cc31a40b0cb53cba7f51187cb6d68076c3f54c0f Mon Sep 17 00:00:00 2001
From: David Fischer <david@konst.fish>
Date: Tue, 19 Sep 2023 16:25:51 +0000
Subject: [PATCH] feat: support changes in system theme (#484)
---
quartz/components/scripts/toc.inline.ts | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/quartz/components/scripts/toc.inline.ts b/quartz/components/scripts/toc.inline.ts
index d6cd50a..f33d8f5 100644
--- a/quartz/components/scripts/toc.inline.ts
+++ b/quartz/components/scripts/toc.inline.ts
@@ -1,5 +1,5 @@
const bufferPx = 150
-const observer = new IntersectionObserver(entries => {
+const observer = new IntersectionObserver((entries) => {
for (const entry of entries) {
const slug = entry.target.id
const tocEntryElement = document.querySelector(`a[data-for="${slug}"]`)
@@ -38,5 +38,5 @@
// update toc entry highlighting
observer.disconnect()
const headers = document.querySelectorAll("h1[id], h2[id], h3[id], h4[id], h5[id], h6[id]")
- headers.forEach(header => observer.observe(header))
+ headers.forEach((header) => observer.observe(header))
})
--
Gitblit v1.10.0