File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -110,7 +110,7 @@ export interface CSSMotionState {
110110 prevProps ?: CSSMotionProps ;
111111}
112112
113- export function isRefConsume ( children ?: CSSMotionProps [ 'children' ] ) {
113+ export function isRefNotConsumed ( children ?: CSSMotionProps [ 'children' ] ) {
114114 return children ?. length < 2 ;
115115}
116116
@@ -257,7 +257,7 @@ export function genCSSMotion(config: CSSMotionConfig) {
257257 return motionChildren ;
258258 } , [ idRef . current ] ) as React . ReactElement ;
259259
260- if ( isRefConsume ( children ) && supportNodeRef ( returnNode ) ) {
260+ if ( isRefNotConsumed ( children ) && supportNodeRef ( returnNode ) ) {
261261 const originNodeRef = getNodeRef ( returnNode ) ;
262262
263263 if ( originNodeRef !== nodeRef ) {
Original file line number Diff line number Diff line change 11/* eslint react/prop-types: 0 */
22import * as React from 'react' ;
33import type { CSSMotionProps } from './CSSMotion' ;
4- import OriginCSSMotion , { isRefConsume } from './CSSMotion' ;
4+ import OriginCSSMotion , { isRefNotConsumed } from './CSSMotion' ;
55import type { KeyObject } from './util/diff' ;
66import {
77 diffKeys ,
@@ -178,7 +178,7 @@ export function genCSSMotionList(
178178 }
179179 } }
180180 >
181- { isRefConsume ( children )
181+ { isRefNotConsumed ( children )
182182 ? props =>
183183 ( children as ChildrenWithoutRef ) ( {
184184 ...props ,
You can’t perform that action at this time.
0 commit comments