Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is it possible to disable 'Skip' button? #194

Closed
cilia opened this issue Sep 10, 2013 · 22 comments
Closed

Is it possible to disable 'Skip' button? #194

cilia opened this issue Sep 10, 2013 · 22 comments
Labels

Comments

@cilia
Copy link

cilia commented Sep 10, 2013

In certain situations, I want to make sure that the users complete the tour, so an option for disabling the 'Skip' button would be nice.

Can we do this in intro.js at the moment?

@assafgelber
Copy link

I sort of accomplished this using css:

.introjs-skipbutton {
    display: none;
}

Pair that with disabling exitOnEsc and exitOnOverlayClick so only if the user manually edits your css he can skip.

@maxdeepfield
Copy link

Making .introjs-skipbutton display: none; is wrong, because this also hides "Done' button.

@assafgelber
Copy link

Aaahhh yes, didn't notice that 😌
Nice catch.

@Purus
Copy link

Purus commented Feb 14, 2014

Both skip and done buttons have same class of "introjs-button introjs-skipbutton". So just CSS can't come to our help.

@xuanlt
Copy link

xuanlt commented Aug 4, 2014

This is my way, temporary solution.

    var tour = introJs();
    tour.start();

    $('.introjs-skipbutton').hide();

    tour.onafterchange(function(){          
        if (this._introItems.length - 1 == this._currentStep || this._introItems.length == 1) {
            $('.introjs-skipbutton').show();
        } 
    });

@or9400
Copy link

or9400 commented Mar 24, 2015

Tanks xuanlt !

@dougvk
Copy link

dougvk commented Aug 7, 2015

+1, please fix this

@CanRau
Copy link

CanRau commented Mar 3, 2016

+1
would be awesome when skip and done buttons are really separate and deactivatable :-)
and for a little more neatness, could be nice to disable prevbutton on first step

hacked the plugin to disable skip button, but couldn't disable prevbutton on first step easily.. :/

Saludos, nevertheless thanks for the nice plugin!
Tried many other webguide plugins, but intro.js works the best for me!

@vana-dev
Copy link

+1

@afshinm
Copy link
Contributor

afshinm commented Mar 10, 2016

will fix it guys, thanks.

@afshinm afshinm added the bug label Mar 10, 2016
@RicardoVaranda
Copy link

+1

@delmicio
Copy link

+1 (7 months later)

@rinogo
Copy link

rinogo commented Dec 30, 2016

Having skip and done be indistinguishable from a CSS perspective makes Intro.js a lot less flexible. I'm styling the "Skip" button to be a small, unobtrusive, "x" icon. However, I want to leave the "Done" button styled similarly to the "Next" button. With the current implementation, this requires a funky workaround.

Is @waynn's solution acceptable? If so, can he/she open a PR to be accepted into master?

@rinogo
Copy link

rinogo commented Dec 30, 2016

Looks like there's already a PR - @afshinm, can you please Merge this PR?

afshinm added a commit that referenced this issue Dec 30, 2016
fixes #194 by changing the CSS class for "Done" so it's not the same as ...
@afshinm
Copy link
Contributor

afshinm commented Dec 30, 2016

Just merged that PR. I will test it myself today and will include it for the next release. Sorry for this delay.

@radumpopescu
Copy link

radumpopescu commented Jan 11, 2017

Apparently it did create a bug. I made a fix here: #675

@afshinm
Copy link
Contributor

afshinm commented Jan 11, 2017

I will have a look @radumpopescu

thanks.

@zzfScarecrow
Copy link

Please fix this....And, I have a problem, please see this,
image
Why the highlight part covered by white?

@akrako1
Copy link

akrako1 commented Oct 2, 2018

the introjs-disabled class is added to the 'previous' button on the first step, and the 'next' button on the last step. i really just wanted them hidden, so i added the below to my css. Poof! Done!

.introjs-disabled {
display: none !important;
}

@Rafaelinpsercom
Copy link

Rafaelinpsercom commented Nov 14, 2019

SOLUCIONADO CON CSS

ANGULAR
::ng-deep .introjs-skipbutton{
visibility: hidden !important;
}
::ng-deep .introjs-donebutton{
visibility: visible !important;
}

SIN ANGULAR
.introjs-skipbutton{
visibility: hidden !important;
}
.introjs-donebutton{
visibility: visible !important;
}

@ghost
Copy link

ghost commented Oct 21, 2021

+1 (a few years on)

@Arashturk
Copy link

Please fix this....And, I have a problem, please see this, image Why the highlight part covered by white?

hmmm.
you can use highlightClass attribute for this:
steps: [ { title: 'Farewell!', element: document.querySelector("#elCreateNew"), title: 'MyTitleIntro', intro: "This whole area does something.", highlightClass: "highlighted-element" }, ]

css:
.highlighted-element { border: 2px solid #3498db; background-color: rgba(52, 152, 219, 0.3); }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests