Description Usage Arguments Value Note Author(s) Examples
Make a dynamic carousel for use with shiny::renderUI() and shiny::uiOutput().
1 | carouselUI(slides, data.interval = 10000, data.ride = "carousel")
|
slides |
A list of HTML tag elements, e.g. |
data.interval |
Milliseconds to pause before auto advancing (numeric), or 'false' for manual advance only. |
data.ride |
Either |
HTML code with class shiny.tag
that can be passed to uiOutput
.
Adapted by JEK from https://github.com/dcurrier/carouselPanel/blob/master/carouselPanel.R
Jon Katz
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | c.slides <- lapply(1:5, function(x) div(h3(style='text-align:center;',paste('Slide', x))))
carouselUI(slides=c.slides, data.interval=5000, data.ride=FALSE)
## Not run:
/* place in www/css/styles.css: */
.carousel-indicators li {
background-color: #DDD;
background-color: rgba(70,70,70,.25);
}
.carousel-indicators .active {
background-color: #999;
}
.carousel-indicators {
bottom: 15px !important;
top: auto;
list-style: none outside none;
margin: 0;
position: absolute;
right: 70px;
z-index: 5;
}
.carousel-control {
opacity: 0.2;
border: none;
top: auto;
}
.item {
padding: 0px 17px;
}
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.