Description Usage Arguments Source Examples
View source: R/hover_reload_button.R
Animate a reload button and it's icon using Hover.css Note that a reload button is just a shiny::actionButton with onClick behavior to reload or refresh a web browser.
1 2 3 4 5 6 7 8 9 |
inputId |
The input slot that will be used to access the value. |
label |
The contents of the button or linkâusually a text label, but you could also use any other HTML, like an image. |
icon |
An optional icon() to appear on the button. |
button_animation |
The name of the button animation. |
icon_animation |
The name of the icon animation. |
width |
The width of the input, e.g. '400px', or '100%'; see validateCssUnit(). |
... |
Named attributes to be applied to the button or link. |
https://github.com/IanLunn/Hover
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | if (interactive()) {
library(shiny)
library(hover)
ui <- fluidPage(
use_hover(),
hover_reload_button(
inputId = "btn",
label = "hello hover!",
icon = icon("refresh"),
button_animation = "rotate",
icon_animation = "spin"
)
)
server <- function(input, output, session) {
}
shinyApp(ui, server)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.