From 46a671fb7f8301dffe147ef6ef597b15879528f2 Mon Sep 17 00:00:00 2001 From: Trang Le Date: Mon, 4 Jul 2022 14:53:58 +0700 Subject: [PATCH] feat: support bodyClassName when omitting fullPage --- packages/react-notion-x/src/block.tsx | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/packages/react-notion-x/src/block.tsx b/packages/react-notion-x/src/block.tsx index 258eb7d84..83963efed 100644 --- a/packages/react-notion-x/src/block.tsx +++ b/packages/react-notion-x/src/block.tsx @@ -261,22 +261,21 @@ export const Block: React.FC = (props) => { page_full_width && 'notion-full-width', page_small_text && 'notion-small-text', blockId, - className, - bodyClassName + className )} >
{pageHeader} +
+ {(block.type === 'collection_view_page' || + (block.type === 'page' && + block.parent_table === 'collection')) && ( + + )} - {(block.type === 'collection_view_page' || - (block.type === 'page' && - block.parent_table === 'collection')) && ( - - )} - - {block.type !== 'collection_view_page' && children} - + {block.type !== 'collection_view_page' && children} +
{pageFooter} )