From 5dde72ae8ee740e5cc8eb07f52a049e1bca6303d Mon Sep 17 00:00:00 2001 From: quirkyvar Date: Thu, 3 Sep 2020 13:40:21 +0800 Subject: [PATCH] fix: compat legal props (#1007) --- packages/antd/src/components/FormMegaLayout/index.tsx | 1 + packages/next/src/components/FormMegaLayout/index.tsx | 1 + 2 files changed, 2 insertions(+) diff --git a/packages/antd/src/components/FormMegaLayout/index.tsx b/packages/antd/src/components/FormMegaLayout/index.tsx index fc544a5bffc..849fbe8a254 100644 --- a/packages/antd/src/components/FormMegaLayout/index.tsx +++ b/packages/antd/src/components/FormMegaLayout/index.tsx @@ -17,6 +17,7 @@ const computeAttr = (propAttr, layoutAttr, defaultValue) => { const StyledLayoutItem = styled((props) => { const { className, grid, children, addonBefore, addonAfter, labelAlign, ...others } = props const formItemProps = pickFormItemProps(others) + formItemProps.style = props.style || {} const cls = classnames({ [className]: true, 'mega-layout-item': true, diff --git a/packages/next/src/components/FormMegaLayout/index.tsx b/packages/next/src/components/FormMegaLayout/index.tsx index dfb8a62c1ed..e67309a4d4e 100644 --- a/packages/next/src/components/FormMegaLayout/index.tsx +++ b/packages/next/src/components/FormMegaLayout/index.tsx @@ -17,6 +17,7 @@ const computeAttr = (propAttr, layoutAttr, defaultValue) => { const StyledLayoutItem = styled((props) => { const { className, grid, children, addonBefore, addonAfter, labelAlign, ...others } = props const formItemProps = pickFormItemProps(others) + formItemProps.style = props.style || {} const cls = classnames({ [className]: true, 'mega-layout-item': true,