fix: form action dragging area is too large (#1628)

This commit is contained in:
Dunqing 2023-04-02 07:11:01 +08:00 committed by GitHub
parent f5171ce6e7
commit ecdd46bf83
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -13,6 +13,7 @@ export const ActionBar = observer((props: any) => {
const { designable } = useDesignable();
if (layout === 'one-column') {
return (
<DndContext>
<div style={{ display: 'flex', ...style }} {...others}>
{props.children && (
<div style={{ marginRight: 8 }}>
@ -25,6 +26,7 @@ export const ActionBar = observer((props: any) => {
)}
{render()}
</div>
</DndContext>
);
}
const hasActions = Object.keys(fieldSchema.properties ?? {}).length > 0;