Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

dashboardBadge

AdminLTE2 badge


Description

Create a badge. It may be inserted in any element like inside a actionButton or a dashboardSidebar.

Usage

dashboardBadge(..., color)

Arguments

...

Any html text element.

color

label color. See below:

  • light-blue (primary status): #3c8dbc.

  • red (danger status): #dd4b39.

  • green (success status): #00a65a.

  • aqua (info status): #00c0ef.

  • yellow (warning status): #f39c12.

  • blue: #0073b7.

  • navy: #001F3F.

  • teal: #39CCCC.

  • olive: #3D9970.

  • lime: #01FF70.

  • orange: #FF851B.

  • fuchsia: #F012BE.

  • purple: #605ca8.

  • maroon: #D81B60.

  • black: #111.

  • gray: #d2d6de.

Author(s)

David Granjon, dgranjon@ymail.com

Examples

if (interactive()) {
 library(shiny)
 library(shinydashboard)
 library(shinydashboardPlus)
 
 shinyApp(
  ui = dashboardPage(
    dashboardHeader(),
    dashboardSidebar(),
    dashboardBody(
     dashboardBadge("Badge 1", color = "blue"),
     actionButton(
      inputId = "badge", 
      label = "Hello", 
      icon = NULL, 
      width = NULL, 
      dashboardBadge(1, color = "orange")
     )
    )
  ),
  server = function(input, output) { }
 )
}

shinydashboardPlus

Add More 'AdminLTE2' Components to 'shinydashboard'

v2.0.1
GPL (>= 2) | file LICENSE
Authors
David Granjon [aut, cre], RinteRface [cph], Almasaeed Studio [ctb, cph] (AdminLTE2 theme for Bootstrap 3), Guang Yang [ctb, cph] (ygdashboard original template), Winston Chang [ctb, cph] (Functions from shinydashboard), Victor Perrier [ctb] (improved the shinydashboardPlusGallery)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.