Create a description block, perfect for writing statistics

descriptionBlock(
  number = NULL,
  numberColor = NULL,
  numberIcon = NULL,
  header = NULL,
  text = NULL,
  rightBorder = TRUE,
  marginBottom = FALSE
)

Arguments

number

any number.

numberColor

number color: see here for a list of valid colors https://adminlte.io/themes/AdminLTE/pages/UI/general.html.

numberIcon

number icon, if any. Expect icon.

header

bold text.

text

additional text.

rightBorder

TRUE by default. Whether to display a right border to separate two blocks. The last block on the right should not have a right border.

marginBottom

FALSE by default. Set it to TRUE when the descriptionBlock is used in a boxPad context.

Author

David Granjon, dgranjon@ymail.com

Examples

if (interactive()) { library(shiny) library(shinydashboard) library(shinydashboardPlus) shinyApp( ui = dashboardPage( dashboardHeader(), dashboardSidebar(), dashboardBody( box( solidHeader = FALSE, title = "Status summary", background = NULL, width = 4, status = "danger", footer = fluidRow( column( width = 6, descriptionBlock( number = "17%", numberColor = "green", numberIcon = icon("caret-up"), header = "$35,210.43", text = "TOTAL REVENUE", rightBorder = TRUE, marginBottom = FALSE ) ), column( width = 6, descriptionBlock( number = "18%", numberColor = "red", numberIcon = icon("caret-down"), header = "1200", text = "GOAL COMPLETION", rightBorder = FALSE, marginBottom = FALSE ) ) ) ) ), title = "Description Blocks" ), server = function(input, output) { } ) }