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 c1bf5fe commit 1a4bbf3Copy full SHA for 1a4bbf3
intro.js
@@ -300,16 +300,19 @@
300
301
function showStep(step){
302
var _showStep = function(){
303
- var element;
+ var intro;
304
hint = hint || new Hint();
305
backdrop = backdrop || createBackdrop();
306
307
- if(isFunction(step.element)){
308
- element = step.element();
+ if(isFunction(step.intro)){
+ intro = step.intro();
309
}else{
310
- element = step.element;
+ intro = step.intro;
311
}
312
- hint.setTarget(element || $('body'));
+ if(step.element){
313
+ $(step.element).get(0).scrollIntoView();
314
+ }
315
+ hint.setTarget(step.element || $('body'));
316
hint.setPosition(step.hintPosition);
317
hint.setTooltipPosition(step.tooltipPosition);
318
hint.setContent(step.intro);
0 commit comments