inst/examples-shiny/build-a-box/R/shuffleButton.R

iconButton <- function(
  id,
  label,
  class = NULL,
  icon = "shuffle",
  icon_title = "Random",
  ...
) {
  tags$button(
    id = id,
    class = "btn btn-default action-button",
    class = class,
    bsicons::bs_icon("shuffle", title = "Random"),
    label
  )
}

shuffleButton <- function(id, label, class = NULL) {
  iconButton(id, label, class = c("shuffle-button", class))
}

Try the bslib package in your browser

Any scripts or data that you put into this service are public.

bslib documentation built on Sept. 11, 2024, 7:49 p.m.