From 06198af1c0ac92f2e9d4cb5b22618e6d96c560ed Mon Sep 17 00:00:00 2001 From: LiuJiaNan <15703339975@163.com> Date: Tue, 28 Oct 2025 13:33:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96FormItemsRenderer=E5=92=8CMap?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/FormBuilder/FormItemsRenderer.js | 4 ++-- components/Map/index.js | 10 ++++------ 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/components/FormBuilder/FormItemsRenderer.js b/components/FormBuilder/FormItemsRenderer.js index 65b1d70..8897ba6 100644 --- a/components/FormBuilder/FormItemsRenderer.js +++ b/components/FormBuilder/FormItemsRenderer.js @@ -263,8 +263,8 @@ const FormItemsRenderer = ({ {options.map((option, index) => { // 列数 const itemSpan = option.render === FORM_ITEM_RENDER_ENUM.DIVIDER ? 24 : option.span ?? span; - const itemLabelCol = option.labelCol ? option.labelCol : (itemSpan === 24 ? { span: labelCol.span / 2 } : labelCol); - const itemWrapperCol = option.wrapperCol ? option.wrapperCol : { span: 24 - itemLabelCol.span }; + const itemLabelCol = option.labelCol ?? (itemSpan === 24 ? { span: labelCol.span / 2 } : labelCol); + const itemWrapperCol = option.wrapperCol ?? { span: 24 - itemLabelCol.span }; // 使用 style 控制显示/隐藏 const style = collapse && index >= 3 ? { display: "none" } : undefined; diff --git a/components/Map/index.js b/components/Map/index.js index 45bdd2f..b9205c3 100644 --- a/components/Map/index.js +++ b/components/Map/index.js @@ -35,16 +35,14 @@ const Map = (props) => { -
- + +
- - - -
+
+