f7Fab | R Documentation |
f7Fab
generates a nice button to be put in f7Fabs.
updateF7Fab
changes the label of an f7Fab input on the client.
f7Fab(inputId, label, width = NULL, ..., flag = NULL)
updateF7Fab(inputId, label = NULL, session = shiny::getDefaultReactiveDomain())
inputId |
The id of the input object. |
label |
The label to set for the input object. |
width |
The width of the input, e.g. |
... |
Named attributes to be applied to the button or link. |
flag |
Additional text displayed next to the button content. Only works if f7Fabs position parameter is not starting with center-... |
session |
The Shiny session object, usually the default value will suffice. |
David Granjon, dgranjon@ymail.com
if (interactive()) {
library(shiny)
library(shinyMobile)
ui <- f7Page(
f7SingleLayout(
navbar = f7Navbar(title = "updateF7Fab"),
f7Fab("trigger", "Click me")
)
)
server <- function(input, output, session) {
observeEvent(input$trigger, {
updateF7Fab("trigger", label = "Don't click me")
})
}
shinyApp(ui, server)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.