builds the div for a shiny value box with a simple sparklines-like graphic

vbox_graphic(
  label = "label",
  textid = "textOutput_here",
  col = "rgba(60,130,180,0.5)",
  graph_title = "nowcast",
  value = 1:10
)

Arguments

label

The label - character of length one

textid

The value - A character vector of length one, optionally the textOutput of a reactive value if using vbox_reactive

col

Bkgd col- A character of rbg(), rgba(), or a html color name recognized in R

graph_title
  • Sparkline title, character of length one

value

the sparklines values to be plotted - a numeric vector

Value

A character vector of the div tree to be rendered in the ui of a shiny app

Examples

vbox_graphic(label = 'label',textid = 'textOutput_here',col = 'rgba(60,130,180,0.5)',
graph_title='nowcast',value=1:10)
#> Warning: Ignoring unknown parameters: fill
#> Saving 6.67 x 6.67 in image
#> <div style="border-radius: 15px;&#10;                      border-style: solid;&#10;                      border-color:transparent;&#10;            padding:0px 0px 0px 10px;&#10;            margin:0px 0px 0px 10px;&#10;            color:white;&#10;            width:230px;&#10;            height:130px;&#10;                  font-weight: 300;&#10;                  text-color:blue;&#10;                  text-align:left;&#10;                  background-color:rgba(60,130,180,0.5);&#10;            ">
#>   <div class="flexfill-container flexfill-container-row" style="display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;width:100%;height:100%;">
#>     <div class="flexfill-item" style="position:relative;-webkit-flex:1;-ms-flex:1;flex:1;width:100%;height:100%;">
#>       <div class="flexfill-item-inner" style="position:absolute;top:0;left:0;right:0;bottom:0;">
#>         <div>
#>           <h5 style="color:white;">label</h5>
#>           <h1 style="font-weight:bold;display: inline-block;vertical-align:top;color:white;">textOutput_here</h1>
#>         </div>
#>       </div>
#>     </div>
#>     <div class="flexfill-item" style="position:relative;-webkit-flex:1;-ms-flex:1;flex:1;width:100%;height:100%;">
#>       <div class="flexfill-item-inner" style="position:absolute;top:0;left:0;right:0;bottom:0;">
#>         <div>
#>           <p style="float:right;padding-top:10px;margin-right:30px;">nowcast</p>
#>           <img src="plot_value_label.png" height="70" style="float:right;padding:5px;margin:5px;"/>
#>         </div>
#>       </div>
#>     </div>
#>   </div>
#> </div>