This repository was archived by the owner on May 10, 2018. It is now read-only.
Added 2 small features: Docking to an element and autohiding the indicators#176
Open
doukasd wants to merge 4 commits into
Open
Added 2 small features: Docking to an element and autohiding the indicators#176doukasd wants to merge 4 commits into
doukasd wants to merge 4 commits into
Conversation
…nally intended if there is no dock attribute set.
…e to the original ones better.
Owner
|
Thanks for reporting and sorry for the delay. Do you see any real world use case for the auto-hide attribute to be observed ? i guess it could be a simple boolean that conditionally adds (or not) the indicator when initializing the carousel ? |
Author
|
The use that I saw was not to show the indicators when there is only 1 image in the carousel. You can see it in action on my website (http://doukasd.com/) for projects that only have one thumbnail the indicators are not shown. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
First of all, big thanks for this component, saved me a ton of time and was almost exactly what I was looking for.
For my needs, the carousel needed to be inside a container with a hidden overflow, therefore the indicators were getting lost as they are at the bottom and just adding a padding would not work as the inner size of the container was not fixed. So I added an optional attribute that allows you to specify an element to dock the indicator to.
Also added the option to autohide the indicators; that is to show them only if there are only 2 or more slides in the carousel.
I think the changes are pretty unobtrusive (sorry changing the background color by 0.2 :) )
It is all documented in the readme and the code if quite straightforward and documented. You can see how it all works here: http://doukasd.com/
Cheers,
Dimitris