Closed dmenne closed 3 years ago
I'm currently reworking the package as you might be able to tell. Things will change.
Right now this is what I would suggest: docs
library(shiny)
library(tippy)
ui <- fluidPage(
useTippy(),
h5("plot tooltip", class = "tip"),
p("Another tooltip", class = "tip"),
tippyThis(
".tip",
"This is indeed a tooltip"
),
actionButton("disable", "Disable"),
actionButton("enable", "Enable")
)
server <- function(input, output) {
observeEvent(input$disable, {
tippy_disable()
});
observeEvent(input$enable, {
tippy_enable()
})
}
shinyApp(ui, server)
Any feedback is welcome.
Perfect. Not yet in the docs, though
For advanced users, tooltips sometimes get into the way, so I usually provide a "Hide All Tooltips" checkbox. This can be done with CSS, but a simple documented function would be nice to have.