mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-06-07 23:16:52 +00:00
Merge branch 'main' of https://github.com/tangly1024/NotionNext into feature/user-auth-clerk
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import BLOG from '@/blog.config'
|
||||
import useNotification from '@/components/Notification'
|
||||
import OpenWrite from '@/components/OpenWrite'
|
||||
import { siteConfig } from '@/lib/config'
|
||||
import { getGlobalData, getPost, getPostBlocks } from '@/lib/db/getSiteData'
|
||||
import { useGlobal } from '@/lib/global'
|
||||
@@ -95,8 +96,12 @@ const Slug = props => {
|
||||
})
|
||||
return (
|
||||
<>
|
||||
{/* 文章布局 */}
|
||||
<Layout {...props} />
|
||||
{/* 解锁密码提示框 */}
|
||||
{post?.password && post?.password !== '' && !lock && <Notification />}
|
||||
{/* 导流工具 */}
|
||||
<OpenWrite />
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ import { siteConfig } from '@/lib/config'
|
||||
import { getGlobalData, getPostBlocks } from '@/lib/db/getSiteData'
|
||||
import { generateRobotsTxt } from '@/lib/robots.txt'
|
||||
import { generateRss } from '@/lib/rss'
|
||||
import { generateSitemapXml } from '@/lib/sitemap.xml'
|
||||
import { getLayoutByTheme } from '@/themes/theme'
|
||||
import { useRouter } from 'next/router'
|
||||
|
||||
@@ -62,6 +63,8 @@ export async function getStaticProps(req) {
|
||||
generateRobotsTxt(props)
|
||||
// 生成Feed订阅
|
||||
generateRss(props)
|
||||
// 生成
|
||||
generateSitemapXml(props)
|
||||
|
||||
// 生成全文索引 - 仅在 yarn build 时执行 && process.env.npm_lifecycle_event === 'build'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user