We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1a4bbf3 commit b95d7c4Copy full SHA for b95d7c4
intro.js
@@ -20,6 +20,7 @@
20
var xPos = position.split(' ')[0];
21
var yPos = position.split(' ')[1];
22
var targetBoundingClientRect = $(target).get(0).getBoundingClientRect();
23
+ var oldOffset = $(element).get(0).getBoundingClientRect();
24
var newOffset = {};
25
26
xPos = xPos || 'center';
@@ -41,7 +42,7 @@
41
42
newOffset.top = targetBoundingClientRect.bottom - element.outerHeight();
43
}
44
- if(duration === 0){
45
+ if(duration === 0 || ((oldOffset.left === newOffset.left) && (oldOffset.top === newOffset.top))){
46
defer.resolve();
47
}else{
48
$(element).one('transitionend', function(){
0 commit comments