@@ -20,13 +20,11 @@ import useWinClick from './hooks/useWinClick';
20
20
import type {
21
21
ActionType ,
22
22
AlignType ,
23
- AnimationType ,
24
23
ArrowPos ,
25
24
ArrowTypeOuter ,
26
25
BuildInPlacements ,
27
- TransitionNameType ,
28
26
} from './interface' ;
29
- import { getAlignPopupClassName , getMotion } from './util' ;
27
+ import { getAlignPopupClassName } from './util' ;
30
28
31
29
export type {
32
30
ActionType ,
@@ -72,9 +70,6 @@ export interface TriggerProps {
72
70
forceRender ?: boolean ;
73
71
autoDestroy ?: boolean ;
74
72
75
- /** @deprecated Please use `autoDestroy` instead */
76
- destroyPopupOnHide ?: boolean ;
77
-
78
73
// ==================== Mask =====================
79
74
mask ?: boolean ;
80
75
maskClosable ?: boolean ;
@@ -85,15 +80,6 @@ export interface TriggerProps {
85
80
/** Set mask motion. You can ref `rc-motion` for more info. */
86
81
maskMotion ?: CSSMotionProps ;
87
82
88
- /** @deprecated Please us `popupMotion` instead. */
89
- popupTransitionName ?: TransitionNameType ;
90
- /** @deprecated Please us `popupMotion` instead. */
91
- popupAnimation ?: AnimationType ;
92
- /** @deprecated Please us `maskMotion` instead. */
93
- maskTransitionName ?: TransitionNameType ;
94
- /** @deprecated Please us `maskMotion` instead. */
95
- maskAnimation ?: AnimationType ;
96
-
97
83
// ==================== Delay ====================
98
84
mouseEnterDelay ?: number ;
99
85
mouseLeaveDelay ?: number ;
@@ -123,10 +109,6 @@ export interface TriggerProps {
123
109
// ==================== Arrow ====================
124
110
arrow ?: boolean | ArrowTypeOuter ;
125
111
126
- // ================= Deprecated ==================
127
- /** @deprecated Add `className` on `children`. Please add `className` directly instead. */
128
- className ?: string ;
129
-
130
112
// =================== Private ===================
131
113
/**
132
114
* @private Get trigger DOM node.
@@ -174,7 +156,6 @@ export function generateTrigger(
174
156
getPopupContainer,
175
157
forceRender,
176
158
autoDestroy,
177
- destroyPopupOnHide,
178
159
179
160
// Popup
180
161
popup,
@@ -200,21 +181,14 @@ export function generateTrigger(
200
181
// Motion
201
182
popupMotion,
202
183
maskMotion,
203
- popupTransitionName,
204
- popupAnimation,
205
- maskTransitionName,
206
- maskAnimation,
207
-
208
- // Deprecated
209
- className,
210
184
211
185
// Private
212
186
getTriggerDOMNode,
213
187
214
188
...restProps
215
189
} = props ;
216
190
217
- const mergedAutoDestroy = autoDestroy || destroyPopupOnHide || false ;
191
+ const mergedAutoDestroy = autoDestroy || false ;
218
192
219
193
// =========================== Mobile ===========================
220
194
const [ mobile , setMobile ] = React . useState ( false ) ;
@@ -289,21 +263,6 @@ export function generateTrigger(
289
263
) ;
290
264
} ) ;
291
265
292
- // =========================== Motion ===========================
293
- const mergePopupMotion = getMotion (
294
- prefixCls ,
295
- popupMotion ,
296
- popupAnimation ,
297
- popupTransitionName ,
298
- ) ;
299
-
300
- const mergeMaskMotion = getMotion (
301
- prefixCls ,
302
- maskMotion ,
303
- maskAnimation ,
304
- maskTransitionName ,
305
- ) ;
306
-
307
266
// ============================ Open ============================
308
267
const [ internalOpen , setInternalOpen ] = React . useState (
309
268
defaultPopupVisible || false ,
@@ -639,11 +598,6 @@ export function generateTrigger(
639
598
} ;
640
599
}
641
600
642
- // ========================= ClassName ==========================
643
- if ( className ) {
644
- cloneProps . className = classNames ( originChildProps . className , className ) ;
645
- }
646
-
647
601
// =========================== Render ===========================
648
602
const mergedChildrenProps = {
649
603
...originChildProps ,
@@ -726,8 +680,8 @@ export function generateTrigger(
726
680
// Mask
727
681
mask = { mask }
728
682
// Motion
729
- motion = { mergePopupMotion }
730
- maskMotion = { mergeMaskMotion }
683
+ motion = { popupMotion }
684
+ maskMotion = { maskMotion }
731
685
onVisibleChanged = { onVisibleChanged }
732
686
onPrepare = { onPrepare }
733
687
// Portal
0 commit comments