diff --git a/components/space/__tests__/__snapshots__/demo-extend.test.ts.snap b/components/space/__tests__/__snapshots__/demo-extend.test.ts.snap index 3c3bb7c82743..7e07b5b17ca5 100644 --- a/components/space/__tests__/__snapshots__/demo-extend.test.ts.snap +++ b/components/space/__tests__/__snapshots__/demo-extend.test.ts.snap @@ -10441,7 +10441,7 @@ exports[`renders ./components/space/demo/compact-debug.tsx extend context correc class="ant-space-compact" > + +
+ + +
+ + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ Su + + Mo + + Tu + + We + + Th + + Fr + + Sa +
+
+ 30 +
+
+
+ 31 +
+
+
+ 1 +
+
+
+ 2 +
+
+
+ 3 +
+
+
+ 4 +
+
+
+ 5 +
+
+
+ 6 +
+
+
+ 7 +
+
+
+ 8 +
+
+
+ 9 +
+
+
+ 10 +
+
+
+ 11 +
+
+
+ 12 +
+
+
+ 13 +
+
+
+ 14 +
+
+
+ 15 +
+
+
+ 16 +
+
+
+ 17 +
+
+
+ 18 +
+
+
+ 19 +
+
+
+ 20 +
+
+
+ 21 +
+
+
+ 22 +
+
+
+ 23 +
+
+
+ 24 +
+
+
+ 25 +
+
+
+ 26 +
+
+
+ 27 +
+
+
+ 28 +
+
+
+ 29 +
+
+
+ 30 +
+
+
+ 1 +
+
+
+ 2 +
+
+
+ 3 +
+
+
+ 4 +
+
+
+ 5 +
+
+
+ 6 +
+
+
+ 7 +
+
+
+ 8 +
+
+
+ 9 +
+
+
+ 10 +
+
+
+ + +
+
+
+ + +
+ + +
+ + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ Su + + Mo + + Tu + + We + + Th + + Fr + + Sa +
+
+ 27 +
+
+
+ 28 +
+
+
+ 29 +
+
+
+ 30 +
+
+
+ 1 +
+
+
+ 2 +
+
+
+ 3 +
+
+
+ 4 +
+
+
+ 5 +
+
+
+ 6 +
+
+
+ 7 +
+
+
+ 8 +
+
+
+ 9 +
+
+
+ 10 +
+
+
+ 11 +
+
+
+ 12 +
+
+
+ 13 +
+
+
+ 14 +
+
+
+ 15 +
+
+
+ 16 +
+
+
+ 17 +
+
+
+ 18 +
+
+
+ 19 +
+
+
+ 20 +
+
+
+ 21 +
+
+
+ 22 +
+
+
+ 23 +
+
+
+ 24 +
+
+
+ 25 +
+
+
+ 26 +
+
+
+ 27 +
+
+
+ 28 +
+
+
+ 29 +
+
+
+ 30 +
+
+
+ 31 +
+
+
+ 1 +
+
+
+ 2 +
+
+
+ 3 +
+
+
+ 4 +
+
+
+ 5 +
+
+
+ 6 +
+
+
+ 7 +
+
+
+
+
+ + + + + + + + + +
+
+
+
+ + + + + + + + + + +
+
+ +
+
+
+
+
+
+
+
+ + + + + Select Address + +
+
+
+
+
+ +
+
+
+
+ +
+
+
+
+
+ +
+
`; diff --git a/components/space/__tests__/__snapshots__/demo.test.ts.snap b/components/space/__tests__/__snapshots__/demo.test.ts.snap index d75ecb7d9977..7810f657bdbb 100644 --- a/components/space/__tests__/__snapshots__/demo.test.ts.snap +++ b/components/space/__tests__/__snapshots__/demo.test.ts.snap @@ -2825,7 +2825,7 @@ exports[`renders ./components/space/demo/compact-debug.tsx correctly 1`] = ` class="ant-space-compact" > + + `; diff --git a/components/space/demo/compact-debug.tsx b/components/space/demo/compact-debug.tsx index f95403d0e9b2..0a4f0cec9731 100644 --- a/components/space/demo/compact-debug.tsx +++ b/components/space/demo/compact-debug.tsx @@ -11,6 +11,7 @@ import { Dropdown, Drawer, InputNumber, + DatePicker, } from 'antd'; const { Option } = Select; @@ -81,19 +82,21 @@ const App: React.FC = () => {
- setShowModal(false)}> - - -
-
- -
-
- - - - -
+ {showModal && ( + setShowModal(false)}> + + +
+
+ +
+
+ + + + +
+ )}
{ - setShowDrawer(false)} - open={showDrawer} - > - - -
-
- - - - -
+ {showDrawer && ( + setShowDrawer(false)} + open={showDrawer} + > + + +
+
+ + + + +
+ )}
+ + + + + + + + + + + + + + + ); }; diff --git a/components/style/compact-item-vertical.tsx b/components/style/compact-item-vertical.tsx index c40535e597b1..e0421b741fab 100644 --- a/components/style/compact-item-vertical.tsx +++ b/components/style/compact-item-vertical.tsx @@ -27,14 +27,14 @@ function compactItemBorderVerticalRadius(prefixCls: string): CSSObject { borderRadius: 0, }, - '&-item&-first-item': { + '&-item&-first-item:not(&-last-item)': { [`&, &${prefixCls}-sm, &${prefixCls}-lg`]: { borderEndEndRadius: 0, borderEndStartRadius: 0, }, }, - '&-item&-last-item': { + '&-item&-last-item:not(&-first-item)': { [`&, &${prefixCls}-sm, &${prefixCls}-lg`]: { borderStartStartRadius: 0, borderStartEndRadius: 0, diff --git a/components/style/compact-item.tsx b/components/style/compact-item.tsx index 3b7fae3d8fd3..8165934c8cb1 100644 --- a/components/style/compact-item.tsx +++ b/components/style/compact-item.tsx @@ -43,7 +43,7 @@ function compactItemBorderRadius(prefixCls: string, borderedElementCls?: string) borderRadius: 0, }, - '&-item&-first-item': { + '&-item:not(&-last-item)&-first-item': { [`& ${childCombinator}, &${prefixCls}-sm ${childCombinator}, &${prefixCls}-lg ${childCombinator}`]: { borderStartEndRadius: 0, @@ -51,7 +51,7 @@ function compactItemBorderRadius(prefixCls: string, borderedElementCls?: string) }, }, - '&-item&-last-item': { + '&-item:not(&-first-item)&-last-item': { [`& ${childCombinator}, &${prefixCls}-sm ${childCombinator}, &${prefixCls}-lg ${childCombinator}`]: { borderStartStartRadius: 0,