diff --git a/components/form/__tests__/__snapshots__/demo.test.js.snap b/components/form/__tests__/__snapshots__/demo.test.js.snap index 682d335122..498e70f8d5 100644 --- a/components/form/__tests__/__snapshots__/demo.test.js.snap +++ b/components/form/__tests__/__snapshots__/demo.test.js.snap @@ -471,6 +471,137 @@ exports[`renders ./components/form/demo/basic.md correctly 1`] = ` `; +exports[`renders ./components/form/demo/col-24-debug.md correctly 1`] = ` +
+
+
+ +
+
+
+
+ +
+
+
+
+
+
+ +
+
+
+
+ + + + + + + + +
+
+
+
+
+
+
+
+ +
+
+
+
+
+`; + exports[`renders ./components/form/demo/control-hooks.md correctly 1`] = `
{ + const onFinish = (values: any) => { + console.log('Success:', values); + }; + + const onFinishFailed = (errorInfo: any) => { + console.log('Failed:', errorInfo); + }; + + return ( + + + + + + + + + + + + +
+ ); +}; + +ReactDOM.render(, mountNode); +``` diff --git a/components/form/style/horizontal.less b/components/form/style/horizontal.less index d498a49db2..f8238982ae 100644 --- a/components/form/style/horizontal.less +++ b/components/form/style/horizontal.less @@ -9,6 +9,9 @@ } .@{form-item-prefix-cls}-control { flex: 1 1 0; + } + // https://github.com/ant-design/ant-design/issues/32980 + .@{form-item-prefix-cls}-control:not(.@{ant-prefix}-col) { // https://github.com/ant-design/ant-design/issues/32777 min-width: 0; }