mirror of
https://github.com/d0zingcat/nextjs-notion-starter-kit.git
synced 2026-05-13 15:09:47 +00:00
chore: fix linting
This commit is contained in:
@@ -80,8 +80,9 @@ export const NotionPage: React.FC<types.PageProps> = ({
|
||||
|
||||
if (!config.isServer) {
|
||||
// add important objects global window for easy debugging
|
||||
;(window as any).recordMap = recordMap
|
||||
;(window as any).block = block
|
||||
const g = window as any
|
||||
g.recordMap = recordMap
|
||||
g.block = block
|
||||
}
|
||||
|
||||
const siteMapPageUrl = mapPageUrl(site, recordMap, searchParams)
|
||||
@@ -205,7 +206,7 @@ export const NotionPage: React.FC<types.PageProps> = ({
|
||||
darkMode={isDarkMode}
|
||||
previewImages={site.previewImages !== false}
|
||||
showCollectionViewDropdown={false}
|
||||
showTableOfContents={true}
|
||||
showTableOfContents={showTableOfContents}
|
||||
minTableOfContentsItems={minTableOfContentsItems}
|
||||
defaultPageIcon={config.defaultPageIcon}
|
||||
defaultPageCover={config.defaultPageCover}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import React from 'react'
|
||||
|
||||
import { HTMLDivElement } from 'react-dom'
|
||||
import styles from './styles.module.css'
|
||||
|
||||
export type MappingType =
|
||||
@@ -86,16 +87,16 @@ export class ReactUtterances extends React.Component<
|
||||
}
|
||||
|
||||
if (issueMap === 'issue-number') {
|
||||
scriptElement.setAttribute('issue-number', issueNumber!.toString())
|
||||
scriptElement.setAttribute('issue-number', issueNumber.toString())
|
||||
} else if (issueMap === 'issue-term') {
|
||||
scriptElement.setAttribute('issue-term', issueTerm!)
|
||||
scriptElement.setAttribute('issue-term', issueTerm)
|
||||
} else {
|
||||
scriptElement.setAttribute('issue-term', issueMap)
|
||||
}
|
||||
|
||||
// TODO: Check current availability
|
||||
this.scriptElement = scriptElement
|
||||
this.reference.current!.appendChild(scriptElement)
|
||||
this.reference.current.appendChild(scriptElement)
|
||||
}
|
||||
|
||||
render(): React.ReactElement {
|
||||
|
||||
Reference in New Issue
Block a user