Title: | Implement Material Design in Shiny Applications |
---|---|
Description: | Allows shiny developers to incorporate UI elements based on Google's Material design. See <https://material.io/guidelines/> for more information. |
Authors: | Eric Anderson [aut, cre], Alvin Wang [ctb, cph] (Materialize CSS library), Alan Chang [ctb, cph] (Materialize CSS library), Alex Mark [ctb, cph] (Materialize CSS library), Kevin Louie [ctb, cph] (Materialize CSS library) |
Maintainer: | Eric Anderson <[email protected]> |
License: | GPL-3 | file LICENSE |
Version: | 1.2.0.9000 |
Built: | 2025-01-30 04:22:13 UTC |
Source: | https://github.com/ericrayanderson/shinymaterial |
Close a material modal programmatically (server side).
close_material_modal(session, modal_id)
close_material_modal(session, modal_id)
session |
The session object passed to function given to shinyServer. |
modal_id |
String. The ID of the modal to open. |
## Not run: close_material_modal(session, "example_modal") ## End(Not run)
## Not run: close_material_modal(session, "example_modal") ## End(Not run)
Build a shinymaterial button. The initial value is zero, and increases by one on each press.
material_button(input_id, label, icon = NULL, depth = NULL, color = NULL)
material_button(input_id, label, icon = NULL, depth = NULL, color = NULL)
input_id |
String. The input identifier used to access the value. |
label |
String. The button text. |
icon |
String. The name of the icon. Leave empty for no icon. Visit https://materializecss.com/icons.html for a list of available icons. |
depth |
Integer. The amount of depth of the button. The value should be between 0 and 5. Leave empty for the default depth. |
color |
String. The color of the button. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. |
material_button( input_id = "example_button", label = "Button", icon = "cloud", depth = 5, color = "blue lighten-2" )
material_button( input_id = "example_button", label = "Button", icon = "cloud", depth = 5, color = "blue lighten-2" )
UI content can be placed in cards to organize items on a page.
material_card(title, ..., depth = NULL, color = NULL, divider = FALSE)
material_card(title, ..., depth = NULL, color = NULL, divider = FALSE)
title |
String. The title of the card |
... |
The UI elements to place in the card |
depth |
Integer. The amount of depth of the card. The value should be between 0 and 5. Leave empty for the default depth. |
color |
String. The color of the card background. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. |
divider |
logical. Should there be a divider element between card title and card content? |
material_card( title = "Example Card", depth = 5, shiny::tags$h5("Card Content") )
material_card( title = "Example Card", depth = 5, shiny::tags$h5("Card Content") )
Build a shinymaterial checkbox. The value is a boolean (TRUE if checked, FALSE if not checked).
material_checkbox(input_id, label, initial_value = FALSE, color = NULL)
material_checkbox(input_id, label, initial_value = FALSE, color = NULL)
input_id |
String. The input identifier used to access the value. |
label |
String. The checkbox label. |
initial_value |
Boolean. Is the checkbox initially checked? |
color |
String. The color of the check. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
## Not run: material_checkbox( input_id = "example_checkbox", label = "Checkbox", initial_value = TRUE, color = "#ef5350" ) ## End(Not run)
## Not run: material_checkbox( input_id = "example_checkbox", label = "Checkbox", initial_value = TRUE, color = "#ef5350" ) ## End(Not run)
UI content can be placed in columns to organize items on a page.
material_column(..., width = 6, offset = 0)
material_column(..., width = 6, offset = 0)
... |
The UI elements to place in the column. |
width |
Integer. The width of the column. The value should be between 1 and 12. |
offset |
Integer. The offset to the left of the column. The value should be between 0 and 11. |
material_column( width = 4, shiny::tags$h1("Column Content") )
material_column( width = 4, shiny::tags$h1("Column Content") )
Build a shinymaterial date picker.
material_date_picker(input_id, label, value = "", color = NULL)
material_date_picker(input_id, label, value = "", color = NULL)
input_id |
String. The input identifier used to access the value. |
label |
String. The date picker label. |
value |
String. The starting date (format 'mmm dd, yyyy'). |
color |
String. The date picker color. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. |
material_date_picker( input_id = "example_date_picker", label = "Date Picker", value = "Jun 02, 2006" )
material_date_picker( input_id = "example_date_picker", label = "Date Picker", value = "Jun 02, 2006" )
Give a UI element the perception of depth by creating a shadow.
material_depth(..., depth = 4)
material_depth(..., depth = 4)
... |
The UI elements to apply the depth. |
depth |
Integer. The amount of depth. The value should be between 0 and 5. A value of 0 can be used to remove depth from objects that have depth by default. |
material_depth( depth = 5, material_card(title = "Example Depth") )
material_depth( depth = 5, material_card(title = "Example Depth") )
Build a shinymaterial dropdown.
material_dropdown( input_id, label, choices = NULL, selected = NULL, multiple = NULL, color = NULL )
material_dropdown( input_id, label, choices = NULL, selected = NULL, multiple = NULL, color = NULL )
input_id |
String. The input identifier used to access the value. |
label |
String. The dropdown label. |
choices |
Named vector. The option names and underyling values. |
selected |
String. The initially selected underyling value. |
multiple |
Boolean. Can multiple items be selected? |
color |
String. The color of the dropdown choices. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
material_dropdown( input_id = "example_dropdown", label = "Drop down", choices = c( "Chicken" = "c", "Steak" = "s", "Fish" = "f" ), selected = c("c"), multiple = FALSE, color = "#ef5350" )
material_dropdown( input_id = "example_dropdown", label = "Drop down", choices = c( "Chicken" = "c", "Steak" = "s", "Fish" = "f" ), selected = c("c"), multiple = FALSE, color = "#ef5350" )
Build a shinymaterial file input.
material_file_input(input_id, label = "File", color = NULL)
material_file_input(input_id, label = "File", color = NULL)
input_id |
String. The input identifier used to access the value. |
label |
String. The file input button text. |
color |
String. The color of the file input. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
if (interactive()) { ui <- material_page( material_row( material_column( width = 12, material_file_input( input_id = "file_1", label = "file" ) ) ), material_row( material_column( width = 12, tableOutput("contents") ) ) ) server <- function(input, output) { output$contents <- renderTable({ # input$file_1 will be NULL initially. After the user selects # and uploads a file, it will be a data frame with 'name', # 'size', 'type', and 'datapath' columns. The 'datapath' # column will contain the local filenames where the data can # be found. in_file <- input$file_1 if (is.null(in_file)) return(NULL) read.csv(in_file$datapath) }) } shinyApp(ui, server) }
if (interactive()) { ui <- material_page( material_row( material_column( width = 12, material_file_input( input_id = "file_1", label = "file" ) ) ), material_row( material_column( width = 12, tableOutput("contents") ) ) ) server <- function(input, output) { output$contents <- renderTable({ # input$file_1 will be NULL initially. After the user selects # and uploads a file, it will be a data frame with 'name', # 'size', 'type', and 'datapath' columns. The 'datapath' # column will contain the local filenames where the data can # be found. in_file <- input$file_1 if (is.null(in_file)) return(NULL) read.csv(in_file$datapath) }) } shinyApp(ui, server) }
Build a shinymaterial floating button. The initial value is zero, and increases by one on each press.
material_floating_button( input_id, icon = NULL, pulse = FALSE, depth = NULL, color = NULL )
material_floating_button( input_id, icon = NULL, pulse = FALSE, depth = NULL, color = NULL )
input_id |
String. The input identifier used to access the value. |
icon |
String. The name of the icon. Leave empty for no icon. Visit https://materializecss.com/icons.html for a list of available icons. |
pulse |
Boolean. Include pulse effect. |
depth |
Integer. The amount of depth of the floating button. The value should be between 0 and 5. Leave empty for the default depth. |
color |
String. The color of the floating button. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. |
material_floating_button( input_id = "example_floating_button", icon = "mode_edit", depth = 5, color = "red lighten-3" )
material_floating_button( input_id = "example_floating_button", icon = "mode_edit", depth = 5, color = "red lighten-3" )
Build a shinymaterial input.
material_input(type, ...)
material_input(type, ...)
type |
String. The type of input to be created. |
... |
Additional arguments for the input. |
##-- switch --## material_input( type = "switch", input_id = "example_switch", off_label = "Off", on_label = "On", initial_value = TRUE )
##-- switch --## material_input( type = "switch", input_id = "example_switch", off_label = "Off", on_label = "On", initial_value = TRUE )
Put any UI object inside of a modal. The modal will open when the button is pressed.
material_modal( modal_id, button_text, title, ..., button_icon = NULL, floating_button = FALSE, button_depth = NULL, button_color = NULL, close_button_label = "Close", display_button = TRUE )
material_modal( modal_id, button_text, title, ..., button_icon = NULL, floating_button = FALSE, button_depth = NULL, button_color = NULL, close_button_label = "Close", display_button = TRUE )
modal_id |
String. The ID for the modal. Must be unique per application. |
button_text |
String. The text displayed on the modal trigger button. |
title |
String. The title of the modal window. |
... |
The UI elements to place in the modal |
button_icon |
String. The name of the icon. Visit https://materializecss.com/icons.html for a list of available icons. |
floating_button |
Boolean. Should the modal trigger button be a floating button? |
button_depth |
Integer. The amount of depth of the button. The value should be between 0 and 5. Leave empty for the default depth. |
button_color |
String. The color of the button. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. |
close_button_label |
String. The label of the modal close button. |
display_button |
Boolean. Should the button be displayed in the app? (If FALSE, open_material_modal() may be used to open the modal). |
material_modal( modal_id = "example_modal", button_text = "Modal", title = "Example Modal Title", button_color = "red lighten-3", shiny::tags$p("Modal Content") )
material_modal( modal_id = "example_modal", button_text = "Modal", title = "Example Modal Title", button_color = "red lighten-3", shiny::tags$p("Modal Content") )
Build a shinymaterial number box.
material_number_box( input_id, label, min_value, max_value, step_size = 1, initial_value, color = NULL )
material_number_box( input_id, label, min_value, max_value, step_size = 1, initial_value, color = NULL )
input_id |
String. The input identifier used to access the value. |
label |
String. The number box label. |
min_value |
Number. The minimum allowable value. |
max_value |
Number. The maximum allowable value. |
step_size |
Number. The step size of the arrow clicks. |
initial_value |
Number. The initial value. |
color |
String. The accent color of the number box. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
material_number_box( input_id = "example_number_box", label = "number box", min_value = 5, max_value = 15, initial_value = 10, step_size = 2, color = "#ef5350" )
material_number_box( input_id = "example_number_box", label = "number box", min_value = 5, max_value = 15, initial_value = 10, step_size = 2, color = "#ef5350" )
Build a shinymaterial page.
material_page( ..., title = "", nav_bar_fixed = FALSE, nav_bar_color = NULL, background_color = "grey lighten-4", font_color = NULL, include_fonts = FALSE, include_nav_bar = TRUE, include_icons = FALSE, materialize_in_www = FALSE, primary_theme_color = NULL, secondary_theme_color = NULL )
material_page( ..., title = "", nav_bar_fixed = FALSE, nav_bar_color = NULL, background_color = "grey lighten-4", font_color = NULL, include_fonts = FALSE, include_nav_bar = TRUE, include_icons = FALSE, materialize_in_www = FALSE, primary_theme_color = NULL, secondary_theme_color = NULL )
... |
The UI elements to place in the page. |
title |
String. The title of the page. |
nav_bar_fixed |
Boolean. Should the nav bar remain fixed on the screen? |
nav_bar_color |
Color of the nav bar. Leave blank for the default color. Visit https://materializecss.com/color.html for a list of available colors. |
background_color |
Page background color. Leave blank for the default color. Visit https://materializecss.com/color.html for a list of available colors. |
font_color |
String. The title font color. Leave blank for the default color. Visit https://materializecss.com/color.html for a list of available colors. Title color requires using word forms of colors (e.g. "deep-purple"). Also, lighten or darken effects do not work on title colors. |
include_fonts |
Boolean. Should the material font files be included? (This will place the font sources in a directory 'www', at the same location as the app code.) |
include_nav_bar |
Boolean. Should the material nav bar be included? |
include_icons |
Boolean. Should the material icon files be included? (This will place the font sources in a directory 'www', at the same location as the app code.) |
materialize_in_www |
Boolean. Should the app look for the materialize library in the 'www' folder? E.g. www/css/materialize.min.css & www/js/materialize.min.js (Default to FALSE - which will look in the package library folder) |
primary_theme_color |
Primary theme color (use hex code, e.g. '#e57373'). Visit https://materializecss.com/color.html for a list of material hex codes. |
secondary_theme_color |
Secondary theme color (use hex code, e.g. '#26a69a'). Visit https://materializecss.com/color.html for a list of material hex codes. |
material_page( title = "Example Title", nav_bar_fixed = TRUE, nav_bar_color = "red lighten-2", background_color = "blue lighten-4", shiny::tags$h1("Page Content") )
material_page( title = "Example Title", nav_bar_fixed = TRUE, nav_bar_color = "red lighten-2", background_color = "blue lighten-4", shiny::tags$h1("Page Content") )
Use this function to create a parallax effect in your application.
material_parallax(image_source)
material_parallax(image_source)
image_source |
String. The image file name. Place the image in a folder labeled 'www' at the same level as the application (server.R & ui.R). |
material_parallax( image_source = "example_image.jpg" )
material_parallax( image_source = "example_image.jpg" )
Build a shinymaterial password box.
material_password_box(input_id, label, color = NULL)
material_password_box(input_id, label, color = NULL)
input_id |
String. The input identifier used to access the value. |
label |
String. The password box label. |
color |
String. The accent color of the password box. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
material_password_box( input_id = "example_password_box", label = "password box", color = "#ef5350" )
material_password_box( input_id = "example_password_box", label = "password box", color = "#ef5350" )
Build a shinymaterial radio button.
material_radio_button( input_id, label, choices, selected = NULL, color = NULL, with_gap = FALSE )
material_radio_button( input_id, label, choices, selected = NULL, color = NULL, with_gap = FALSE )
input_id |
String. The input identifier used to access the value. |
label |
String. The radio button label. |
choices |
Named vector. The option names and underyling values. |
selected |
The initially selected value (if not specified then defaults to the first value). |
color |
String. The color of the radio buttons. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
with_gap |
Boolean. To create a radio button with a gap. |
material_radio_button( input_id = "example_radio_button", label = "Radio Button", choices = c( "Cake" = "c", "Pie" = "p", "Brownie" = "b" ), color = "#ef5350" )
material_radio_button( input_id = "example_radio_button", label = "Radio Button", choices = c( "Cake" = "c", "Pie" = "p", "Brownie" = "b" ), color = "#ef5350" )
UI content can be placed in a row to organize items on a page.
material_row(...)
material_row(...)
... |
The UI elements to place in the row. |
material_row( shiny::tags$h1("Row Content") )
material_row( shiny::tags$h1("Row Content") )
Build a shinymaterial slider.
material_slider( input_id, label, min_value, max_value, step_size = 1, initial_value, color = NULL )
material_slider( input_id, label, min_value, max_value, step_size = 1, initial_value, color = NULL )
input_id |
String. The input identifier used to access the value. |
label |
String. The slider label. |
min_value |
Number. The minimum value on the slider. |
max_value |
Number. The maximum value on the slider. |
step_size |
Number. The size of step in the slider. |
initial_value |
Number. The initial value of the slider. |
color |
String. The slider color. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
material_slider( input_id = "example_slider", label = "slider", min_value = 5, max_value = 15, initial_value = 10, step_size = 3, color = "#ef5350" )
material_slider( input_id = "example_slider", label = "slider", min_value = 5, max_value = 15, initial_value = 10, step_size = 3, color = "#ef5350" )
Display a preloader (spinner) while server is busy.
material_spinner_show(session, output_id)
material_spinner_show(session, output_id)
session |
The session object passed to function given to shinyServer. |
output_id |
The output id for which the spinner will be a placeholder for. |
if(interactive()){ library(shiny) library(shinymaterial) ui <- material_page( title = "Spinner Example", numericInput(inputId = "n", label = "", value = 10), plotOutput("n_plot") ) server <- function(input, output, session) { output$n_plot <- renderPlot({ #--- Show the spinner ---# material_spinner_show(session, "n_plot") #--- Simulate calculation step ---# Sys.sleep(time = 5) #--- Hide the spinner ---# material_spinner_hide(session, "n_plot") plot(1:input$n) }) } shinyApp(ui = ui, server = server) }
if(interactive()){ library(shiny) library(shinymaterial) ui <- material_page( title = "Spinner Example", numericInput(inputId = "n", label = "", value = 10), plotOutput("n_plot") ) server <- function(input, output, session) { output$n_plot <- renderPlot({ #--- Show the spinner ---# material_spinner_show(session, "n_plot") #--- Simulate calculation step ---# Sys.sleep(time = 5) #--- Hide the spinner ---# material_spinner_hide(session, "n_plot") plot(1:input$n) }) } shinyApp(ui = ui, server = server) }
Build a shinymaterial switch. The value is a boolean (TRUE if 'on', FALSE if 'off').
material_switch( input_id, off_label = "", on_label = "", initial_value = FALSE, color = NULL )
material_switch( input_id, off_label = "", on_label = "", initial_value = FALSE, color = NULL )
input_id |
String. The input identifier used to access the value. |
off_label |
String. The label for the 'off' position of the switch. |
on_label |
String. The label for the 'on' position of the switch. |
initial_value |
Boolean. Is the switch initially on? |
color |
String. The color of the switch. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
material_switch( input_id = "example_switch", off_label = "Off", on_label = "On", initial_value = TRUE, color = "#ef5350" )
material_switch( input_id = "example_switch", off_label = "Off", on_label = "On", initial_value = TRUE, color = "#ef5350" )
Use this function to place UI content within a specific tab.
material_tab_content(tab_id, ...)
material_tab_content(tab_id, ...)
tab_id |
String. The tab id in which to place the UI content. |
... |
The UI elements to place in the tab. |
material_tab_content( tab_id = "example_tab_1", shiny::tags$h1("Tab Content") )
material_tab_content( tab_id = "example_tab_1", shiny::tags$h1("Tab Content") )
Use this function to create tabs in your application.
material_tabs(tabs, color = NULL)
material_tabs(tabs, color = NULL)
tabs |
Named vector. The tab display names and corresponding tab ids. |
color |
String. The accent color of the tabs. Leave blank for the default color. Must be valid css color. |
material_tabs( tabs = c( "Example Tab 1" = "example_tab_1", "Example Tab 2" = "example_tab_2" ), color = "purple" )
material_tabs( tabs = c( "Example Tab 1" = "example_tab_1", "Example Tab 2" = "example_tab_2" ), color = "purple" )
Build a shinymaterial text box.
material_text_box(input_id, label, value = "", color = NULL, icon = NULL)
material_text_box(input_id, label, value = "", color = NULL, icon = NULL)
input_id |
String. The input identifier used to access the value. |
label |
String. The text box label. |
value |
String. Initial value. |
color |
String. The accent color of the text box. Leave empty for the default color. Visit https://materializecss.com/color.html for a list of available colors. This input requires using color hex codes, rather than the word form. E.g., "#ef5350", rather than "red lighten-1". |
icon |
String. The name of the icon. Leave empty for no icon. Visit https://materializecss.com/icons.html for a list of available icons. |
material_text_box( input_id = "example_text_box", label = "text box", icon = "search", color = "#ef5350" )
material_text_box( input_id = "example_text_box", label = "text box", icon = "search", color = "#ef5350" )
Open a material modal programmatically (server side).
open_material_modal(session, modal_id)
open_material_modal(session, modal_id)
session |
The session object passed to function given to shinyServer. |
modal_id |
String. The ID of the modal to open. |
## Not run: open_material_modal(session, "example_modal") ## End(Not run)
## Not run: open_material_modal(session, "example_modal") ## End(Not run)
This function is used within a shiny::renderUI(). The corresponding output is referenced using shiny::uiOutput().
render_material_from_server(material_ui)
render_material_from_server(material_ui)
material_ui |
shinymaterial UI element(s) |
## Only run examples in interactive R sessions if (interactive()) { ui <- material_page( uiOutput("renderedButton") ) server <- function(input, output) { output$renderedButton <- renderUI({ render_material_from_server(material_button("example_button", "Button")) }) } shinyApp(ui, server) }
## Only run examples in interactive R sessions if (interactive()) { ui <- material_page( uiOutput("renderedButton") ) server <- function(input, output) { output$renderedButton <- renderUI({ render_material_from_server(material_button("example_button", "Button")) }) } shinyApp(ui, server) }
Change the value text, icon of a material_button on the client. Allow to disable the button and then enable.
update_material_button( session, input_id, label = NULL, icon = NULL, disabled = NULL )
update_material_button( session, input_id, label = NULL, icon = NULL, disabled = NULL )
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_button. |
label |
The new label of the material_button. |
icon |
The new icon of the material_button. If not set, icon disappear. |
disabled |
NULL by default (do nothing), if TRUE the button is disable and if FALSE, enable. |
## Not run: update_material_button( session, input_id = "example_button", value = "New Text", icon = "stop", disabled = FALSE ) ## End(Not run)
## Not run: update_material_button( session, input_id = "example_button", value = "New Text", icon = "stop", disabled = FALSE ) ## End(Not run)
Change the value of a material_checkbox on the client.
update_material_checkbox(session, input_id, value = NULL)
update_material_checkbox(session, input_id, value = NULL)
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_checkbox. |
value |
Boolean. The value to set for the material_checkbox. |
## Not run: update_material_checkbox( session, input_id = "example_checkbox", value = TRUE ) ## End(Not run)
## Not run: update_material_checkbox( session, input_id = "example_checkbox", value = TRUE ) ## End(Not run)
Change the value of a material_date_picker on the client.
update_material_date_picker(session, input_id, value = NULL)
update_material_date_picker(session, input_id, value = NULL)
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_date_picker. |
value |
The value to set for the material_date_picker (format 'mmm dd, yyyy'). |
## Not run: update_material_date_picker( session, input_id = "example_date_picker", value = "Apr 10, 2012" ) ## End(Not run)
## Not run: update_material_date_picker( session, input_id = "example_date_picker", value = "Apr 10, 2012" ) ## End(Not run)
Change the value of a material_dropdown on the client.
update_material_dropdown( session, input_id, value = NULL, choices = NULL, multiple = NULL )
update_material_dropdown( session, input_id, value = NULL, choices = NULL, multiple = NULL )
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_dropdown. |
value |
The value to set for the material_dropdown. |
choices |
The choices to set for the material_dropdown. |
multiple |
Boolean. Can multiple items be selected? |
## Not run: update_material_dropdown( session, input_id = "example_dropdown", value = "New Text" ) ## End(Not run)
## Not run: update_material_dropdown( session, input_id = "example_dropdown", value = "New Text" ) ## End(Not run)
Change the value of a material_number_box on the client.
update_material_number_box(session, input_id, value = NULL)
update_material_number_box(session, input_id, value = NULL)
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_number_box. |
value |
The value to set for the material_number_box. |
## Not run: update_material_number_box( session, input_id = "example_number_box", value = 3 ) ## End(Not run)
## Not run: update_material_number_box( session, input_id = "example_number_box", value = 3 ) ## End(Not run)
Change the value of a material_password_box on the client.
update_material_password_box(session, input_id, value = NULL)
update_material_password_box(session, input_id, value = NULL)
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_password_box. |
value |
The value to set for the material_password_box. |
## Not run: update_material_password_box( session, input_id = "example_password_box", value = "New Password" ) ## End(Not run)
## Not run: update_material_password_box( session, input_id = "example_password_box", value = "New Password" ) ## End(Not run)
Change the value of a material_radio_button on the client.
update_material_radio_button(session, input_id, value = NULL)
update_material_radio_button(session, input_id, value = NULL)
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_radio_button. |
value |
The value to set for the material_radio_button. |
## Not run: update_material_radio_button( session, input_id = "example_radio_button", value = "new_value" ) ## End(Not run)
## Not run: update_material_radio_button( session, input_id = "example_radio_button", value = "new_value" ) ## End(Not run)
Change the value of a material_slider on the client.
update_material_slider(session, input_id, value = NULL)
update_material_slider(session, input_id, value = NULL)
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_slider. |
value |
The value to set for the material_slider. |
## Not run: update_material_slider( session, input_id = "example_slider", value = "new_value" ) ## End(Not run)
## Not run: update_material_slider( session, input_id = "example_slider", value = "new_value" ) ## End(Not run)
Change the value of a material_switch on the client.
update_material_switch(session, input_id, value = NULL)
update_material_switch(session, input_id, value = NULL)
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_switch. |
value |
Boolean. The value to set for the material_switch. |
## Not run: update_material_switch( session, input_id = "example_switch", value = TRUE ) ## End(Not run)
## Not run: update_material_switch( session, input_id = "example_switch", value = TRUE ) ## End(Not run)
Change the value of a material_text_box on the client.
update_material_text_box(session, input_id, value = NULL)
update_material_text_box(session, input_id, value = NULL)
session |
The session object passed to function given to shinyServer. |
input_id |
The input_id of the material_text_box. |
value |
The value to set for the material_text_box. |
## Not run: update_material_text_box( session, input_id = "example_text_box", value = "New Text" ) ## End(Not run)
## Not run: update_material_text_box( session, input_id = "example_text_box", value = "New Text" ) ## End(Not run)