bs4Stars | R Documentation |
Create a block of stars (ideal for rating)
bs4Stars(value, max = 5, color = "warning") starBlock(value, max = 5, color = "warning")
value |
Current value. Should be positive and lower or equal to max. |
max |
Maximum number of stars by block. |
color |
Star color. Valid colors are listed below:
|
David Granjon, dgranjon@ymail.com
if(interactive()){ library(shiny) library(bs4Dash) shinyApp( ui = dashboardPage( dashboardHeader(), dashboardSidebar(), dashboardBody( box( title = "Star example", starBlock(5), starBlock(5, color = "fuchsia"), starBlock(1, color = "danger"), starBlock(3, color = "secondary") ) ), title = "starBlock" ), server = function(input, output) { } ) }
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.