From 6d326f424a2d0168218760014ec8f6a598247ef3 Mon Sep 17 00:00:00 2001 From: Dunqing Date: Mon, 29 May 2023 11:22:38 +0800 Subject: [PATCH] fix(grid-card, list): display title only work on current block (#1942) --- .../client/src/schema-component/antd/form-item/FormItem.tsx | 2 +- packages/core/client/src/schema-items/GeneralSchemaItems.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/client/src/schema-component/antd/form-item/FormItem.tsx b/packages/core/client/src/schema-component/antd/form-item/FormItem.tsx index 08b114dd6..d3061818b 100644 --- a/packages/core/client/src/schema-component/antd/form-item/FormItem.tsx +++ b/packages/core/client/src/schema-component/antd/form-item/FormItem.tsx @@ -72,7 +72,7 @@ export const FormItem: any = observer((props: any) => { } } }, []); - const { showTitle = true } = props; + const showTitle = schema['x-decorator-props']?.showTitle ?? true; return ( diff --git a/packages/core/client/src/schema-items/GeneralSchemaItems.tsx b/packages/core/client/src/schema-items/GeneralSchemaItems.tsx index 3770b9a28..996b0f0c8 100644 --- a/packages/core/client/src/schema-items/GeneralSchemaItems.tsx +++ b/packages/core/client/src/schema-items/GeneralSchemaItems.tsx @@ -55,7 +55,7 @@ export const GeneralSchemaItems: React.FC<{ /> )} { fieldSchema['x-decorator-props'] = fieldSchema['x-decorator-props'] || {};