bs4Dash (version 0.5.0)

bs4UserCard: AdminLTE3 widget user card

Description

Create widget user card

Usage

bs4UserCard(
  ...,
  type = NULL,
  src = NULL,
  elevation = NULL,
  imageElevation = NULL,
  status = c("primary", "warning", "danger", "info", "success"),
  title = NULL,
  subtitle = NULL,
  width = 6
)

Arguments

...

Footer content.

type

User card type. Either NULL or 2.

src

User image url or path.

elevation

User card elevation (numeric). NULL by default.

imageElevation

User card image elevation (numeric). NULL by default.

status

User card color. "primary", "warning", "danger", "info" or "success".

title

User card title.

subtitle

User card subtitle.

width

The width of the card, using the Bootstrap grid system.

Examples

Run this code
# NOT RUN {
if(interactive()){
 library(shiny)
 library(bs4Dash)
 
 shiny::shinyApp(
   ui = bs4DashPage(
     navbar = bs4DashNavbar(),
     sidebar = bs4DashSidebar(),
     controlbar = bs4DashControlbar(),
     footer = bs4DashFooter(),
     title = "test",
     body = bs4DashBody(
      fluidRow(
      bs4UserCard(
        src = "https://adminlte.io/themes/AdminLTE/dist/img/user1-128x128.jpg",
        status = "info",
        title = "User card type 1",
        subtitle = "a subtitle here",
        elevation = 4,
        "Any content here"
       ),
       bs4UserCard(
        type = 2,
        src = "https://adminlte.io/themes/AdminLTE/dist/img/user7-128x128.jpg",
        status = "success",
        imageElevation = 4,
        title = "User card type 2",
        subtitle = "a subtitle here",
        bs4ProgressBar(
         value = 5,
         striped = FALSE,
         status = "info"
         ),
        bs4ProgressBar(
          value = 5,
          striped = TRUE,
          status = "warning",
          width = "20%"
        )
       )
      )
     )
   ),
   server = function(input, output) {}
 )
}

# }

Run the code above in your browser using DataLab