mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-05-14 07:26:52 +00:00
fix lost of siteInfo and bg-cover
This commit is contained in:
@@ -251,7 +251,7 @@ function getCategoryOptions(schema) {
|
||||
* @returns {Promise<{title,description,pageCover,icon}>}
|
||||
*/
|
||||
function getSiteInfo({ collection, block, NOTION_CONFIG, pageId }) {
|
||||
if (!collection || !block || NOTION_CONFIG || pageId) {
|
||||
if (!collection && !block) {
|
||||
return {
|
||||
title: BLOG.TITLE,
|
||||
description: BLOG.DESCRIPTION,
|
||||
@@ -267,8 +267,9 @@ function getSiteInfo({ collection, block, NOTION_CONFIG, pageId }) {
|
||||
: BLOG.DESCRIPTION
|
||||
|
||||
const pageCover = collection?.cover
|
||||
? mapImgUrl(collection?.cover, block[pageId]?.value)
|
||||
? mapImgUrl(collection?.cover, collection, 'collection')
|
||||
: BLOG.HOME_BANNER_IMAGE
|
||||
|
||||
// 用户头像压缩一下
|
||||
let icon = compressImage(
|
||||
collection?.icon
|
||||
|
||||
@@ -522,6 +522,7 @@ summary > .notion-h {
|
||||
|
||||
.notion-page {
|
||||
/* width: var(--notion-max-width); */
|
||||
width: 100% !important;
|
||||
padding-left: calc(min(12px, 8vw));
|
||||
padding-right: calc(min(12px, 8vw));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user