tippyTheme: Theme

View source: R/theme.R

tippyThemeR Documentation

Theme

Description

Convenience function to create a theme.

Usage

tippyTheme(
  name,
  box_bg = "black",
  box_color = "white",
  box_font_size = "12px",
  arrow_color = box_bg,
  content_bg = box_bg,
  content_color = box_color,
  content_font_size = box_font_size
)

Arguments

name

Name of theme.

box_bg, box_color, content_bg, content_color

Background and text color respectively.

box_font_size, content_font_size

Size of the font.

arrow_color

Color of the arrow (if enabled).

Examples

library(shiny)

ui <- fluidPage(
  useTippy(),
  tippyTheme("myTheme", box_bg = "darkred"),
  h5("plot tooltip", id = "plotTip"),
  tippyThis(
    "plotTip",
    "Hello world",
    theme = "myTheme"
  )
)

server <- function(input, output) {}

if(FALSE){
  shinyApp(ui, server)
}


JohnCoene/tippy documentation built on April 16, 2023, 2:37 p.m.