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

Don't show "Previous Navigation Button" on first Page of Slideshow #3

Closed
ghost opened this issue Feb 17, 2017 · 3 comments
Closed

Don't show "Previous Navigation Button" on first Page of Slideshow #3

ghost opened this issue Feb 17, 2017 · 3 comments

Comments

@ghost
Copy link

ghost commented Feb 17, 2017

Hi Alex,
thank's for this great slideshow!
Today I was wondering if it is possible to remove the "previous navigation button" from the first page of the slideshow. (And the "next navigation button" from the last page).

I was sure that this would be simple and could be done just by deleting the button from *.html part, as shown here:

	<!-- Prev Navigation -->
	<div class="fs-prev-nav">
		<!-- <label class="fs-prev-btn" for="slide-1"></label> -->
		     <label class="fs-prev-btn" for="slide-2"></label>
		     <label class="fs-prev-btn" for="slide-3"></label>
		     <label class="fs-prev-btn" for="slide-4"></label>
	</div>

But unfortunately this is not working and messes up the navigation.
Do you have an idea how to do this?

Regards Jens

@alexerlandsson
Copy link
Owner

Hi Jens,

This is something I've never thought of. The selector always goes for :nth-child so removing the buttons will just mess up the navigation as you experienced.

The only solution for now is probably hiding the buttons with css. Add a class for the buttons to hide with some nasty css:

.hide-btn {
 display: none !important;
}

As long as the buttons are still there it should not matter if they are hidden or not.

Thanks for noticing this! I have to look further into how I can solve this in a better way. I'll keep this issue open until I've investigated what I could to about it.

@ghost
Copy link
Author

ghost commented Feb 17, 2017

Hi Alex,
I tested your CSS-workaround. It works perfectly!
Thank you very much for your help and your fast reply!

Regards Jens

@alexerlandsson
Copy link
Owner

Added the option to disable continuous loop for prev/next navigation. Set variable $fs-prevnextnav-loop to false in css-fadeshow.css to hide the prev button on first slide and next button on the last slide.

This change works with or without the buttons added to the html. If they are added they will be hidden, if not they will be ignored. No no more need for a custom fix.

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

No branches or pull requests

1 participant