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 e3ed6c6 commit 957a7c4Copy full SHA for 957a7c4
src/enjoyhint.js
@@ -147,9 +147,15 @@ var EnjoyHint = function (configs) {
147
148
that.clear();
149
}, 250);
150
-
151
- $(document.body).scrollTop(step_data.selector, step_data.scrollAnimationSpeed || 250, {offset: -100});
152
+
+ //$(document.body).scrollTop(step_data.selector, step_data.scrollAnimationSpeed || 250, {offset: -100});
153
+ var elemToScroll = document.querySelector(step_data.selector);
154
+ if(elemToScroll){
155
+ let {x, y} = elemToScroll.getClientRects();
156
+ window.scrollTo(x, y);
157
+ }
158
159
setTimeout(function () {
160
161
var $element = $(step_data.selector);
0 commit comments