Jacky Zhao
2024-03-18 daa8796554dea41d6fbf81f4eccea58153a4e850
quartz/components/renderPage.tsx
@@ -118,11 +118,12 @@
              // skip until we find the blockref that matches
              if (el.properties?.id === blockRef) {
                startIdx = i
                startDepth = Number(el.tagName.substring(1))
                startDepth = depth
              }
            } else if (depth <= startDepth) {
              // looking for new header that is same level or higher
              endIdx = i
              break
            }
          }
@@ -209,7 +210,7 @@
    </div>
  )
  const lang = componentData.frontmatter?.lang ?? cfg.locale?.split("-")[0] ?? "en"
  const lang = componentData.fileData.frontmatter?.lang ?? cfg.locale?.split("-")[0] ?? "en"
  const doc = (
    <html lang={lang}>
      <Head {...componentData} />