Skip to content
This repository was archived by the owner on Mar 13, 2023. It is now read-only.

Commit dc4db7c

Browse files
committed
return to default
1 parent 45075a8 commit dc4db7c

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

lib/Draggable.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,10 @@ class Draggable extends React.Component<DraggableProps, DraggableState> {
313313
const {x, y} = this.props.position;
314314
newState.x = x;
315315
newState.y = y;
316+
} else {
317+
const {x, y} = this.props.defaultPosition;
318+
newState.x = x;
319+
newState.y = y;
316320
}
317321

318322
this.setState(newState);

0 commit comments

Comments
 (0)